@fugood/bricks-cli 2.26.0-beta.38 → 2.26.0-beta.39
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/1010.js +1 -1
- package/lib/1708.js +2 -2
- package/lib/2486.js +1 -1
- package/lib/6818.js +1 -1
- package/lib/7294.js +2 -2
- package/lib/7511.js +1 -1
- package/lib/831.js +1 -1
- package/lib/9439.js +5 -1
- package/lib/index.js +5 -5
- package/lib/lib.js +138 -138
- package/package.json +5 -5
package/lib/lib.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import{createRequire as e}from"node:module";let t=e(import.meta.url);import a from"conf";var r,i,n={68089(e,t,a){var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};let i=a(24434),n=r(a(3680)),p=r(a(9873)),o=n.default("agent-base");function s(){let{stack:e}=Error();return"string"==typeof e&&e.split("\n").some(e=>-1!==e.indexOf("(https.js:")||-1!==e.indexOf("node:https:"))}function d(e,t){return new d.Agent(e,t)}var l=d||(d={});class u extends i.EventEmitter{constructor(e,t){super();let a=t;"function"==typeof e?this.callback=e:e&&(a=e),this.timeout=null,a&&"number"==typeof a.timeout&&(this.timeout=a.timeout),this.maxFreeSockets=1,this.maxSockets=1,this.maxTotalSockets=1/0,this.sockets={},this.freeSockets={},this.requests={},this.options={}}get defaultPort(){return"number"==typeof this.explicitDefaultPort?this.explicitDefaultPort:s()?443:80}set defaultPort(e){this.explicitDefaultPort=e}get protocol(){return"string"==typeof this.explicitProtocol?this.explicitProtocol:s()?"https:":"http:"}set protocol(e){this.explicitProtocol=e}callback(e,t,a){throw Error('"agent-base" has no default implementation, you must subclass and override `callback()`')}addRequest(e,t){let a=Object.assign({},t);"boolean"!=typeof a.secureEndpoint&&(a.secureEndpoint=s()),null==a.host&&(a.host="localhost"),null==a.port&&(a.port=a.secureEndpoint?443:80),null==a.protocol&&(a.protocol=a.secureEndpoint?"https:":"http:"),a.host&&a.path&&delete a.path,delete a.agent,delete a.hostname,delete a._defaultAgent,delete a.defaultPort,delete a.createConnection,e._last=!0,e.shouldKeepAlive=!1;let r=!1,i=null,n=a.timeout||this.timeout,d=t=>{e._hadError||(e.emit("error",t),e._hadError=!0)},l=e=>{r||(null!==i&&(clearTimeout(i),i=null),d(e))},u=t=>{if(!r){if(null!=i&&(clearTimeout(i),i=null),t&&"function"==typeof t.addRequest){o("Callback returned another Agent instance %o",t.constructor.name),t.addRequest(e,a);return}if(t){t.once("free",()=>{this.freeSocket(t,a)}),e.onSocket(t);return}d(Error(`no Duplex stream was returned to agent-base for \`${e.method} ${e.path}\``))}};if("function"!=typeof this.callback)return void d(Error("`callback` is not defined"));this.promisifiedCallback||(this.callback.length>=3?(o("Converting legacy callback function to promise"),this.promisifiedCallback=p.default(this.callback)):this.promisifiedCallback=this.callback),"number"==typeof n&&n>0&&(i=setTimeout(()=>{i=null,r=!0;let e=Error(`A "socket" was not created for HTTP request before ${n}ms`);e.code="ETIMEOUT",d(e)},n)),"port"in a&&"number"!=typeof a.port&&(a.port=Number(a.port));try{o("Resolving socket for %o request: %o",a.protocol,`${e.method} ${e.path}`),Promise.resolve(this.promisifiedCallback(e,a)).then(u,l)}catch(e){Promise.reject(e).catch(l)}}freeSocket(e,t){o("Freeing socket %o %o",e.constructor.name,t),e.destroy()}destroy(){o("Destroying agent %o",this.constructor.name)}}l.Agent=u,l.prototype=l.Agent.prototype,e.exports=d},9873(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return function(t,a){return new Promise((r,i)=>{e.call(this,t,a,(e,t)=>{e?i(e):r(t)})})}}},20124(e,t,a){let r;t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;let a="color: "+this.color;t.splice(1,0,a,"color: inherit");let r=0,i=0;t[0].replace(/%[a-zA-Z%]/g,e=>{"%%"!==e&&(r++,"%c"===e&&(i=r))}),t.splice(i,0,a)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")||t.storage.getItem("DEBUG")}catch(e){}return!e&&"u">typeof process&&"env"in process&&(e=process.env.DEBUG),e},t.useColors=function(){let e;return"u">typeof window&&!!window.process&&("renderer"===window.process.type||!!window.process.__nwjs)||!("u">typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("u">typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"u">typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"u">typeof navigator&&navigator.userAgent&&(e=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt(e[1],10)>=31||"u">typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},t.storage=function(){try{return localStorage}catch(e){}}(),r=!1,t.destroy=()=>{r||(r=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))},t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.log=console.debug||console.log||(()=>{}),e.exports=a(27891)(t);let{formatters:i}=e.exports;i.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}},27891(e,t,a){e.exports=function(e){function t(e){let a,i,n,p=null;function o(...e){if(!o.enabled)return;let r=Number(new Date);o.diff=r-(a||r),o.prev=a,o.curr=r,a=r,e[0]=t.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let i=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,(a,r)=>{if("%%"===a)return"%";i++;let n=t.formatters[r];if("function"==typeof n){let t=e[i];a=n.call(o,t),e.splice(i,1),i--}return a}),t.formatArgs.call(o,e),(o.log||t.log).apply(o,e)}return o.namespace=e,o.useColors=t.useColors(),o.color=t.selectColor(e),o.extend=r,o.destroy=t.destroy,Object.defineProperty(o,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==p?p:(i!==t.namespaces&&(i=t.namespaces,n=t.enabled(e)),n),set:e=>{p=e}}),"function"==typeof t.init&&t.init(o),o}function r(e,a){let r=t(this.namespace+(void 0===a?":":a)+e);return r.log=this.log,r}function i(e,t){let a=0,r=0,i=-1,n=0;for(;a<e.length;)if(r<t.length&&(t[r]===e[a]||"*"===t[r]))"*"===t[r]?(i=r,n=a):a++,r++;else{if(-1===i)return!1;r=i+1,a=++n}for(;r<t.length&&"*"===t[r];)r++;return r===t.length}return t.debug=t,t.default=t,t.coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){let e=[...t.names,...t.skips.map(e=>"-"+e)].join(",");return t.enable(""),e},t.enable=function(e){for(let a of(t.save(e),t.namespaces=e,t.names=[],t.skips=[],("string"==typeof e?e:"").trim().replace(/\s+/g,",").split(",").filter(Boolean)))"-"===a[0]?t.skips.push(a.slice(1)):t.names.push(a)},t.enabled=function(e){for(let a of t.skips)if(i(e,a))return!1;for(let a of t.names)if(i(e,a))return!0;return!1},t.humanize=a(27250),t.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(e).forEach(a=>{t[a]=e[a]}),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){let a=0;for(let t=0;t<e.length;t++)a=(a<<5)-a+e.charCodeAt(t)|0;return t.colors[Math.abs(a)%t.colors.length]},t.enable(t.load()),t}},3680(e,t,a){"u"<typeof process||"renderer"===process.type||!0===process.browser||process.__nwjs?e.exports=a(20124):e.exports=a(85038)},85038(e,t,a){let r=a(52018),i=a(39023);t.init=function(e){e.inspectOpts={};let a=Object.keys(t.inspectOpts);for(let r=0;r<a.length;r++)e.inspectOpts[a[r]]=t.inspectOpts[a[r]]},t.log=function(...e){return process.stderr.write(i.formatWithOptions(t.inspectOpts,...e)+"\n")},t.formatArgs=function(a){let{namespace:r,useColors:i}=this;if(i){let t=this.color,i="\x1b[3"+(t<8?t:"8;5;"+t),n=` ${i};1m${r} \u001B[0m`;a[0]=n+a[0].split("\n").join("\n"+n),a.push(i+"m+"+e.exports.humanize(this.diff)+"\x1b[0m")}else a[0]=(t.inspectOpts.hideDate?"":new Date().toISOString()+" ")+r+" "+a[0]},t.save=function(e){e?process.env.DEBUG=e:delete process.env.DEBUG},t.load=function(){return process.env.DEBUG},t.useColors=function(){return"colors"in t.inspectOpts?!!t.inspectOpts.colors:r.isatty(process.stderr.fd)},t.destroy=i.deprecate(()=>{},"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."),t.colors=[6,2,3,4,5,1];try{let e=a(35600);e&&(e.stderr||e).level>=2&&(t.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221])}catch(e){}t.inspectOpts=Object.keys(process.env).filter(e=>/^debug_/i.test(e)).reduce((e,t)=>{let a=t.substring(6).toLowerCase().replace(/_([a-z])/g,(e,t)=>t.toUpperCase()),r=process.env[t];return r=!!/^(yes|on|true|enabled)$/i.test(r)||!/^(no|off|false|disabled)$/i.test(r)&&("null"===r?null:Number(r)),e[a]=r,e},{}),e.exports=a(27891)(t);let{formatters:n}=e.exports;n.o=function(e){return this.inspectOpts.colors=this.useColors,i.inspect(e,this.inspectOpts).split("\n").map(e=>e.trim()).join(" ")},n.O=function(e){return this.inspectOpts.colors=this.useColors,i.inspect(e,this.inspectOpts)}},94370(e,t,a){a.r(t),a.d(t,{default:()=>y,disableExperimentalFragmentVariables:()=>h,disableFragmentWarnings:()=>m,enableExperimentalFragmentVariables:()=>f,gql:()=>u,resetCaches:()=>c});var r,i=a(85608),n=a(20186),p=new Map,o=new Map,s=!0,d=!1;function l(e){return e.replace(/[\s,]+/g," ").trim()}function u(e){for(var t=[],a=1;a<arguments.length;a++)t[a-1]=arguments[a];"string"==typeof e&&(e=[e]);var r=e[0];return t.forEach(function(t,a){t&&"Document"===t.kind?r+=t.loc.source.body:r+=t,r+=e[a+1]}),function(e){var t=l(e);if(!p.has(t)){var a,r,u,c,m,f=(0,n.qg)(e,{experimentalFragmentVariables:d,allowLegacyFragmentVariables:d});if(!f||"Document"!==f.kind)throw Error("Not a valid GraphQL document.");p.set(t,((c=new Set((a=new Set,r=[],f.definitions.forEach(function(e){if("FragmentDefinition"===e.kind){var t,i=e.name.value,n=l((t=e.loc).source.body.substring(t.start,t.end)),p=o.get(i);p&&!p.has(n)?s&&console.warn("Warning: fragment with name "+i+" already exists.\ngraphql-tag enforces all fragment names across your application to be unique; read more about\nthis in the docs: http://dev.apollodata.com/core/fragments.html#unique-names"):p||o.set(i,p=new Set),p.add(n),a.has(n)||(a.add(n),r.push(e))}else r.push(e)}),u=(0,i.__assign)((0,i.__assign)({},f),{definitions:r})).definitions)).forEach(function(e){e.loc&&delete e.loc,Object.keys(e).forEach(function(t){var a=e[t];a&&"object"==typeof a&&c.add(a)})}),(m=u.loc)&&(delete m.startToken,delete m.endToken),u))}return p.get(t)}(r)}function c(){p.clear(),o.clear()}function m(){s=!1}function f(){d=!0}function h(){d=!1}var v=u;(r=u||(u={})).gql=v,r.resetCaches=c,r.disableFragmentWarnings=m,r.enableExperimentalFragmentVariables=f,r.disableExperimentalFragmentVariables=h,u.default=u;let y=u},56071(e){e.exports=(e,t=process.argv)=>{let a=e.startsWith("-")?"":1===e.length?"-":"--",r=t.indexOf(a+e),i=t.indexOf("--");return -1!==r&&(-1===i||r<i)}},35646(e,t,a){var r=this&&this.__awaiter||function(e,t,a,r){return new(a||(a=Promise))(function(i,n){function p(e){try{s(r.next(e))}catch(e){n(e)}}function o(e){try{s(r.throw(e))}catch(e){n(e)}}function s(e){var t;e.done?i(e.value):((t=e.value)instanceof a?t:new a(function(e){e(t)})).then(p,o)}s((r=r.apply(e,t||[])).next())})},i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});let n=i(a(69278)),p=i(a(64756)),o=i(a(87016)),s=i(a(42613)),d=i(a(3680)),l=a(68089),u=i(a(36981)),c=d.default("https-proxy-agent:agent");class m extends l.Agent{constructor(e){var t;let a;if(!(a="string"==typeof e?o.default.parse(e):e))throw Error("an HTTP(S) proxy server `host` and `port` must be specified!");c("creating new HttpsProxyAgent instance: %o",a),super(a);let r=Object.assign({},a);this.secureProxy=a.secureProxy||"string"==typeof(t=r.protocol)&&/^https:?$/i.test(t),r.host=r.hostname||r.host,"string"==typeof r.port&&(r.port=parseInt(r.port,10)),!r.port&&r.host&&(r.port=this.secureProxy?443:80),!this.secureProxy||"ALPNProtocols"in r||(r.ALPNProtocols=["http 1.1"]),r.host&&r.path&&(delete r.path,delete r.pathname),this.proxy=r}callback(e,t){return r(this,void 0,void 0,function*(){var a,r;let i,{proxy:o,secureProxy:d}=this;d?(c("Creating `tls.Socket`: %o",o),i=p.default.connect(o)):(c("Creating `net.Socket`: %o",o),i=n.default.connect(o));let l=Object.assign({},o.headers),m=`${t.host}:${t.port}`,h=`CONNECT ${m} HTTP/1.1\r
|
|
2
2
|
`;o.auth&&(l["Proxy-Authorization"]=`Basic ${Buffer.from(o.auth).toString("base64")}`);let{host:v,port:y,secureEndpoint:g}=t;for(let e of(a=y,((r=g)||80!==a)&&(!r||443!==a)&&(v+=`:${y}`),l.Host=v,l.Connection="close",Object.keys(l)))h+=`${e}: ${l[e]}\r
|
|
3
3
|
`;let _=u.default(i);i.write(`${h}\r
|
|
4
|
-
`);let{statusCode:b,buffered:w}=yield _;if(200===b){if(e.once("socket",f),t.secureEndpoint){c("Upgrading socket connection to TLS");let e=t.servername||t.host;return p.default.connect(Object.assign(Object.assign({},function(e,...t){let a,r={};for(a in e)t.includes(a)||(r[a]=e[a]);return r}(t,"host","hostname","path","port")),{socket:i,servername:e}))}return i}i.destroy();let E=new n.default.Socket({writable:!1});return E.readable=!0,e.once("socket",e=>{c("replaying proxy buffer for failed request"),s.default(e.listenerCount("data")>0),e.push(w),e.push(null)}),E})}}function f(e){e.resume()}t.default=m},64007(e,t,a){var r;let i=(this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}})(a(35646));function n(e){return new i.default(e)}(r=n||(n={})).HttpsProxyAgent=i.default,r.prototype=i.default.prototype,e.exports=n},36981(e,t,a){var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});let i=r(a(3680)).default("https-proxy-agent:parse-proxy-response");t.default=function(e){return new Promise((t,a)=>{let r=0,n=[];function p(){let a=e.read();a?function(e){n.push(e),r+=e.length;let a=Buffer.concat(n,r);if(-1===a.indexOf("\r\n\r\n")){i("have not received end of HTTP headers yet..."),p();return}let o=a.toString("ascii",0,a.indexOf("\r\n")),s=+o.split(" ")[1];i("got proxy server response: %o",o),t({statusCode:s,buffered:a})}(a):e.once("readable",p)}function o(e){i("onclose had error %o",e)}function s(){i("onend")}e.on("error",function t(r){e.removeListener("end",s),e.removeListener("error",t),e.removeListener("close",o),e.removeListener("readable",p),i("onerror %o",r),a(r)}),e.on("close",o),e.on("end",s),p()})}},65650(e,t,a){e.exports=a(78942).Symbol},65111(e){e.exports=function(e,t){for(var a=-1,r=null==e?0:e.length,i=Array(r);++a<r;)i[a]=t(e[a],a,e);return i}},44187(e){e.exports=function(e,t,a,r){var i=-1,n=null==e?0:e.length;for(r&&n&&(a=e[++i]);++i<n;)a=t(a,e[i],i,e);return a}},39546(e){var t=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;e.exports=function(e){return e.match(t)||[]}},87379(e,t,a){var r=a(65650),i=a(8870),n=a(29005),p=r?r.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":p&&p in Object(e)?i(e):n(e)}},51035(e){e.exports=function(e){return function(t){return null==e?void 0:e[t]}}},52291(e,t,a){var r=a(65650),i=a(65111),n=a(53142),p=a(51187),o=1/0,s=r?r.prototype:void 0,d=s?s.toString:void 0;e.exports=function e(t){if("string"==typeof t)return t;if(n(t))return i(t,e)+"";if(p(t))return d?d.call(t):"";var a=t+"";return"0"==a&&1/t==-o?"-0":a}},93640(e,t,a){var r=a(44187),i=a(45881),n=a(39850),p=RegExp("['’]","g");e.exports=function(e){return function(t){return r(n(i(t).replace(p,"")),e,"")}}},69968(e,t,a){e.exports=a(51035)({À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"})},74967(e){e.exports="object"==typeof global&&global&&global.Object===Object&&global},8870(e,t,a){var r=a(65650),i=Object.prototype,n=i.hasOwnProperty,p=i.toString,o=r?r.toStringTag:void 0;e.exports=function(e){var t=n.call(e,o),a=e[o];try{e[o]=void 0;var r=!0}catch(e){}var i=p.call(e);return r&&(t?e[o]=a:delete e[o]),i}},15813(e){var t=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;e.exports=function(e){return t.test(e)}},29005(e){var t=Object.prototype.toString;e.exports=function(e){return t.call(e)}},78942(e,t,a){var r=a(74967),i="object"==typeof self&&self&&self.Object===Object&&self;e.exports=r||i||Function("return this")()},10482(e){var t="\\ud800-\\udfff",a="\\u2700-\\u27bf",r="a-z\\xdf-\\xf6\\xf8-\\xff",i="A-Z\\xc0-\\xd6\\xd8-\\xde",n="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\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",p="['’]",o="["+n+"]",s="["+r+"]",d="[^"+t+n+"\\d+"+a+r+i+"]",l="(?:\\ud83c[\\udde6-\\uddff]){2}",u="[\\ud800-\\udbff][\\udc00-\\udfff]",c="["+i+"]",m="(?:"+s+"|"+d+")",f="(?:"+c+"|"+d+")",h="(?:"+p+"(?:d|ll|m|re|s|t|ve))?",v="(?:"+p+"(?:D|LL|M|RE|S|T|VE))?",y="(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?",g="[\\ufe0e\\ufe0f]?",_="(?:\\u200d(?:"+["[^"+t+"]",l,u].join("|")+")"+g+y+")*",b="(?:"+["["+a+"]",l,u].join("|")+")"+(g+y+_),w=RegExp([c+"?"+s+"+"+h+"(?="+[o,c,"$"].join("|")+")",f+"+"+v+"(?="+[o,c+m,"$"].join("|")+")",c+"?"+m+"+"+h,c+"+"+v,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])|\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])|\\d+",b].join("|"),"g");e.exports=function(e){return e.match(w)||[]}},45881(e,t,a){var r=a(69968),i=a(95243),n=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,p=RegExp("[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]","g");e.exports=function(e){return(e=i(e))&&e.replace(n,r).replace(p,"")}},53142(e){e.exports=Array.isArray},80547(e){e.exports=function(e){return null!=e&&"object"==typeof e}},51187(e,t,a){var r=a(87379),i=a(80547);e.exports=function(e){return"symbol"==typeof e||i(e)&&"[object Symbol]"==r(e)}},10750(e,t,a){e.exports=a(93640)(function(e,t,a){return e+(a?"-":"")+t.toLowerCase()})},95243(e,t,a){var r=a(52291);e.exports=function(e){return null==e?"":r(e)}},39850(e,t,a){var r=a(39546),i=a(15813),n=a(95243),p=a(10482);e.exports=function(e,t,a){return(e=n(e),void 0===(t=a?void 0:t))?i(e)?p(e):r(e):e.match(t)||[]}},27250(e){function t(e,t,a,r){return Math.round(e/a)+" "+r+(t>=1.5*a?"s":"")}e.exports=function(e,a){a=a||{};var r,i,n,p,o=typeof e;if("string"===o&&e.length>0){var s=e;if(!((s=String(s)).length>100)){var d=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(s);if(d){var l=parseFloat(d[1]);switch((d[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*l;case"weeks":case"week":case"w":return 6048e5*l;case"days":case"day":case"d":return 864e5*l;case"hours":case"hour":case"hrs":case"hr":case"h":return 36e5*l;case"minutes":case"minute":case"mins":case"min":case"m":return 6e4*l;case"seconds":case"second":case"secs":case"sec":case"s":return 1e3*l;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return l;default:break}}}return}if("number"===o&&isFinite(e)){return a.long?(i=Math.abs(r=e))>=864e5?t(r,i,864e5,"day"):i>=36e5?t(r,i,36e5,"hour"):i>=6e4?t(r,i,6e4,"minute"):i>=1e3?t(r,i,1e3,"second"):r+" ms":(p=Math.abs(n=e))>=864e5?Math.round(n/864e5)+"d":p>=36e5?Math.round(n/36e5)+"h":p>=6e4?Math.round(n/6e4)+"m":p>=1e3?Math.round(n/1e3)+"s":n+"ms"}throw Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},27549(e,t,a){e.exports=function(e,t){var r=[function(e,t,a){e.exports=a(34)},function(e,t,a){var r=a(29)("wks"),i=a(33),n=a(2).Symbol,p="function"==typeof n;(e.exports=function(e){return r[e]||(r[e]=p&&n[e]||(p?n:i)("Symbol."+e))}).store=r},function(e,t){var a=e.exports="u">typeof window&&window.Math==Math?window:"u">typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=a)},function(e,t,a){var r=a(9);e.exports=function(e){if(!r(e))throw TypeError(e+" is not an object!");return e}},function(e,t,a){e.exports=!a(24)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(e,t,a){var r=a(12),i=a(17);e.exports=a(4)?function(e,t,a){return r.f(e,t,i(1,a))}:function(e,t,a){return e[t]=a,e}},function(e,t){var a=e.exports={version:"2.4.0"};"number"==typeof __e&&(__e=a)},function(e,t,a){var r=a(14);e.exports=function(e,t,a){if(r(e),void 0===t)return e;switch(a){case 1:return function(a){return e.call(t,a)};case 2:return function(a,r){return e.call(t,a,r)};case 3:return function(a,r,i){return e.call(t,a,r,i)}}return function(){return e.apply(t,arguments)}}},function(e,t){var a={}.hasOwnProperty;e.exports=function(e,t){return a.call(e,t)}},function(e,t){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},function(e,t){e.exports={}},function(e,t){var a={}.toString;e.exports=function(e){return a.call(e).slice(8,-1)}},function(e,t,a){var r=a(3),i=a(26),n=a(32),p=Object.defineProperty;t.f=a(4)?Object.defineProperty:function(e,t,a){if(r(e),t=n(t,!0),r(a),i)try{return p(e,t,a)}catch(e){}if("get"in a||"set"in a)throw TypeError("Accessors not supported!");return"value"in a&&(e[t]=a.value),e}},function(e,t,a){var r=a(42),i=a(15);e.exports=function(e){return r(i(e))}},function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},function(e,t){e.exports=function(e){if(void 0==e)throw TypeError("Can't call method on "+e);return e}},function(e,t,a){var r=a(9),i=a(2).document,n=r(i)&&r(i.createElement);e.exports=function(e){return n?i.createElement(e):{}}},function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},function(e,t,a){var r=a(12).f,i=a(8),n=a(1)("toStringTag");e.exports=function(e,t,a){e&&!i(e=a?e:e.prototype,n)&&r(e,n,{configurable:!0,value:t})}},function(e,t,a){var r=a(29)("keys"),i=a(33);e.exports=function(e){return r[e]||(r[e]=i(e))}},function(e,t){var a=Math.ceil,r=Math.floor;e.exports=function(e){return isNaN(e*=1)?0:(e>0?r:a)(e)}},function(e,t,a){var r=a(11),i=a(1)("toStringTag"),n="Arguments"==r(function(){return arguments}()),p=function(e,t){try{return e[t]}catch(e){}};e.exports=function(e){var t,a,o;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(a=p(t=Object(e),i))?a:n?r(t):"Object"==(o=r(t))&&"function"==typeof t.callee?"Arguments":o}},function(e,t){e.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(e,t,a){var r=a(2),i=a(6),n=a(7),p=a(5),o="prototype",s=function(e,t,a){var d,l,u,c=e&s.F,m=e&s.G,f=e&s.S,h=e&s.P,v=e&s.B,y=e&s.W,g=m?i:i[t]||(i[t]={}),_=g[o],b=m?r:f?r[t]:(r[t]||{})[o];for(d in m&&(a=t),a)(l=!c&&b&&void 0!==b[d])&&d in g||(u=l?b[d]:a[d],g[d]=m&&"function"!=typeof b[d]?a[d]:v&&l?n(u,r):y&&b[d]==u?function(e){var t=function(t,a,r){if(this instanceof e){switch(arguments.length){case 0:return new e;case 1:return new e(t);case 2:return new e(t,a)}return new e(t,a,r)}return e.apply(this,arguments)};return t[o]=e[o],t}(u):h&&"function"==typeof u?n(Function.call,u):u,h&&((g.virtual||(g.virtual={}))[d]=u,e&s.R&&_&&!_[d]&&p(_,d,u)))};s.F=1,s.G=2,s.S=4,s.P=8,s.B=16,s.W=32,s.U=64,s.R=128,e.exports=s},function(e,t){e.exports=function(e){try{return!!e()}catch(e){return!0}}},function(e,t,a){e.exports=a(2).document&&document.documentElement},function(e,t,a){e.exports=!a(4)&&!a(24)(function(){return 7!=Object.defineProperty(a(16)("div"),"a",{get:function(){return 7}}).a})},function(e,t,a){"use strict";var r=a(28),i=a(23),n=a(57),p=a(5),o=a(8),s=a(10),d=a(45),l=a(18),u=a(52),c=a(1)("iterator"),m=!([].keys&&"next"in[].keys()),f="keys",h="values",v=function(){return this};e.exports=function(e,t,a,y,g,_,b){d(a,t,y);var w,E,T,N=function(e){if(!m&&e in D)return D[e];switch(e){case f:case h:return function(){return new a(this,e)}}return function(){return new a(this,e)}},S=t+" Iterator",O=g==h,I=!1,D=e.prototype,A=D[c]||D["@@iterator"]||g&&D[g],k=A||N(g),x=g?O?N("entries"):k:void 0,C="Array"==t&&D.entries||A;if(C&&(T=u(C.call(new e)))!==Object.prototype&&(l(T,S,!0),r||o(T,c)||p(T,c,v)),O&&A&&A.name!==h&&(I=!0,k=function(){return A.call(this)}),(!r||b)&&(m||I||!D[c])&&p(D,c,k),s[t]=k,s[S]=v,g)if(w={values:O?k:N(h),keys:_?k:N(f),entries:x},b)for(E in w)E in D||n(D,E,w[E]);else i(i.P+i.F*(m||I),t,w);return w}},function(e,t){e.exports=!0},function(e,t,a){var r=a(2),i="__core-js_shared__",n=r[i]||(r[i]={});e.exports=function(e){return n[e]||(n[e]={})}},function(e,t,a){var r,i,n,p=a(7),o=a(41),s=a(25),d=a(16),l=a(2),u=l.process,c=l.setImmediate,m=l.clearImmediate,f=l.MessageChannel,h=0,v={},y="onreadystatechange",g=function(){var e=+this;if(v.hasOwnProperty(e)){var t=v[e];delete v[e],t()}},_=function(e){g.call(e.data)};c&&m||(c=function(e){for(var t=[],a=1;arguments.length>a;)t.push(arguments[a++]);return v[++h]=function(){o("function"==typeof e?e:Function(e),t)},r(h),h},m=function(e){delete v[e]},"process"==a(11)(u)?r=function(e){u.nextTick(p(g,e,1))}:f?(n=(i=new f).port2,i.port1.onmessage=_,r=p(n.postMessage,n,1)):l.addEventListener&&"function"==typeof postMessage&&!l.importScripts?(r=function(e){l.postMessage(e+"","*")},l.addEventListener("message",_,!1)):r=y in d("script")?function(e){s.appendChild(d("script"))[y]=function(){s.removeChild(this),g.call(e)}}:function(e){setTimeout(p(g,e,1),0)}),e.exports={set:c,clear:m}},function(e,t,a){var r=a(20),i=Math.min;e.exports=function(e){return e>0?i(r(e),0x1fffffffffffff):0}},function(e,t,a){var r=a(9);e.exports=function(e,t){var a,i;if(!r(e))return e;if(t&&"function"==typeof(a=e.toString)&&!r(i=a.call(e))||"function"==typeof(a=e.valueOf)&&!r(i=a.call(e))||!t&&"function"==typeof(a=e.toString)&&!r(i=a.call(e)))return i;throw TypeError("Can't convert object to primitive value")}},function(e,t){var a=0,r=Math.random();e.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++a+r).toString(36))}},function(e,t,a){"use strict";function r(e){return(0,s.createHash)("sha256").update(e).digest("hex")}function i(e){switch(d){case"darwin":return e.split("IOPlatformUUID")[1].split("\n")[0].replace(/\=|\s+|\"/gi,"").toLowerCase();case"win32":return e.toString().split("REG_SZ")[1].replace(/\r+|\n+|\s+/gi,"").toLowerCase();case"linux":case"freebsd":return e.toString().replace(/\r+|\n+|\s+/gi,"").toLowerCase();default:throw Error("Unsupported platform: "+process.platform)}}Object.defineProperty(t,"__esModule",{value:!0});var n,p=(n=a(35))&&n.__esModule?n:{default:n};t.machineIdSync=function(e){var t=i((0,o.execSync)(l[d]).toString());return e?t:r(t)},t.machineId=function(e){return new p.default(function(t,a){return(0,o.exec)(l[d],{},function(n,p,o){if(n)return a(Error("Error while obtaining machine id: "+n.stack));var s=i(p.toString());return t(e?s:r(s))})})};var o=a(70),s=a(71),d=process.platform,l={darwin:"ioreg -rd1 -c IOPlatformExpertDevice",win32:{native:"%windir%\\System32",mixed:"%windir%\\sysnative\\cmd.exe /c %windir%\\System32"}["win32"!==process.platform?"":"ia32"===process.arch&&process.env.hasOwnProperty("PROCESSOR_ARCHITEW6432")?"mixed":"native"]+"\\REG.exe QUERY HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Cryptography /v MachineGuid",linux:"( cat /var/lib/dbus/machine-id /etc/machine-id 2> /dev/null || hostname ) | head -n 1 || :",freebsd:"kenv -q smbios.system.uuid || sysctl -n kern.hostuuid"}},function(e,t,a){e.exports={default:a(36),__esModule:!0}},function(e,t,a){a(66),a(68),a(69),a(67),e.exports=a(6).Promise},function(e,t){e.exports=function(){}},function(e,t){e.exports=function(e,t,a,r){if(!(e instanceof t)||void 0!==r&&r in e)throw TypeError(a+": incorrect invocation!");return e}},function(e,t,a){var r=a(13),i=a(31),n=a(62);e.exports=function(e){return function(t,a,p){var o,s=r(t),d=i(s.length),l=n(p,d);if(e&&a!=a){for(;d>l;)if((o=s[l++])!=o)return!0}else for(;d>l;l++)if((e||l in s)&&s[l]===a)return e||l||0;return!e&&-1}}},function(e,t,a){var r=a(7),i=a(44),n=a(43),p=a(3),o=a(31),s=a(64),d={},l={},t=e.exports=function(e,t,a,u,c){var m,f,h,v,y=c?function(){return e}:s(e),g=r(a,u,t?2:1),_=0;if("function"!=typeof y)throw TypeError(e+" is not iterable!");if(n(y)){for(m=o(e.length);m>_;_++)if((v=t?g(p(f=e[_])[0],f[1]):g(e[_]))===d||v===l)return v}else for(h=y.call(e);!(f=h.next()).done;)if((v=i(h,g,f.value,t))===d||v===l)return v};t.BREAK=d,t.RETURN=l},function(e,t){e.exports=function(e,t,a){var r=void 0===a;switch(t.length){case 0:return r?e():e.call(a);case 1:return r?e(t[0]):e.call(a,t[0]);case 2:return r?e(t[0],t[1]):e.call(a,t[0],t[1]);case 3:return r?e(t[0],t[1],t[2]):e.call(a,t[0],t[1],t[2]);case 4:return r?e(t[0],t[1],t[2],t[3]):e.call(a,t[0],t[1],t[2],t[3])}return e.apply(a,t)}},function(e,t,a){var r=a(11);e.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==r(e)?e.split(""):Object(e)}},function(e,t,a){var r=a(10),i=a(1)("iterator"),n=Array.prototype;e.exports=function(e){return void 0!==e&&(r.Array===e||n[i]===e)}},function(e,t,a){var r=a(3);e.exports=function(e,t,a,i){try{return i?t(r(a)[0],a[1]):t(a)}catch(t){var n=e.return;throw void 0!==n&&r(n.call(e)),t}}},function(e,t,a){"use strict";var r=a(49),i=a(17),n=a(18),p={};a(5)(p,a(1)("iterator"),function(){return this}),e.exports=function(e,t,a){e.prototype=r(p,{next:i(1,a)}),n(e,t+" Iterator")}},function(e,t,a){var r=a(1)("iterator"),i=!1;try{var n=[7][r]();n.return=function(){i=!0},Array.from(n,function(){throw 2})}catch(e){}e.exports=function(e,t){if(!t&&!i)return!1;var a=!1;try{var n=[7],p=n[r]();p.next=function(){return{done:a=!0}},n[r]=function(){return p},e(n)}catch(e){}return a}},function(e,t){e.exports=function(e,t){return{value:t,done:!!e}}},function(e,t,a){var r=a(2),i=a(30).set,n=r.MutationObserver||r.WebKitMutationObserver,p=r.process,o=r.Promise,s="process"==a(11)(p);e.exports=function(){var e,t,a,d=function(){var r,i;for(s&&(r=p.domain)&&r.exit();e;){i=e.fn,e=e.next;try{i()}catch(r){throw e?a():t=void 0,r}}t=void 0,r&&r.enter()};if(s)a=function(){p.nextTick(d)};else if(n){var l=!0,u=document.createTextNode("");new n(d).observe(u,{characterData:!0}),a=function(){u.data=l=!l}}else if(o&&o.resolve){var c=o.resolve();a=function(){c.then(d)}}else a=function(){i.call(r,d)};return function(r){var i={fn:r,next:void 0};t&&(t.next=i),e||(e=i,a()),t=i}}},function(e,t,a){var r=a(3),i=a(50),n=a(22),p=a(19)("IE_PROTO"),o=function(){},s="prototype",d=function(){var e,t=a(16)("iframe"),r=n.length;for(t.style.display="none",a(25).appendChild(t),t.src="javascript:",(e=t.contentWindow.document).open(),e.write("<script>document.F=Object<\/script>"),e.close(),d=e.F;r--;)delete d[s][n[r]];return d()};e.exports=Object.create||function(e,t){var a;return null!==e?(o[s]=r(e),a=new o,o[s]=null,a[p]=e):a=d(),void 0===t?a:i(a,t)}},function(e,t,a){var r=a(12),i=a(3),n=a(54);e.exports=a(4)?Object.defineProperties:function(e,t){i(e);for(var a,p=n(t),o=p.length,s=0;o>s;)r.f(e,a=p[s++],t[a]);return e}},function(e,t,a){var r=a(55),i=a(17),n=a(13),p=a(32),o=a(8),s=a(26),d=Object.getOwnPropertyDescriptor;t.f=a(4)?d:function(e,t){if(e=n(e),t=p(t,!0),s)try{return d(e,t)}catch(e){}if(o(e,t))return i(!r.f.call(e,t),e[t])}},function(e,t,a){var r=a(8),i=a(63),n=a(19)("IE_PROTO"),p=Object.prototype;e.exports=Object.getPrototypeOf||function(e){return r(e=i(e),n)?e[n]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?p:null}},function(e,t,a){var r=a(8),i=a(13),n=a(39)(!1),p=a(19)("IE_PROTO");e.exports=function(e,t){var a,o=i(e),s=0,d=[];for(a in o)a!=p&&r(o,a)&&d.push(a);for(;t.length>s;)r(o,a=t[s++])&&(~n(d,a)||d.push(a));return d}},function(e,t,a){var r=a(53),i=a(22);e.exports=Object.keys||function(e){return r(e,i)}},function(e,t){t.f=({}).propertyIsEnumerable},function(e,t,a){var r=a(5);e.exports=function(e,t,a){for(var i in t)a&&e[i]?e[i]=t[i]:r(e,i,t[i]);return e}},function(e,t,a){e.exports=a(5)},function(e,t,a){var r=a(9),i=a(3),n=function(e,t){if(i(e),!r(t)&&null!==t)throw TypeError(t+": can't set as prototype!")};e.exports={set:Object.setPrototypeOf||("__proto__"in{}?function(e,t,r){try{(r=a(7)(Function.call,a(51).f(Object.prototype,"__proto__").set,2))(e,[]),t=!(e instanceof Array)}catch(e){t=!0}return function(e,a){return n(e,a),t?e.__proto__=a:r(e,a),e}}({},!1):void 0),check:n}},function(e,t,a){"use strict";var r=a(2),i=a(6),n=a(12),p=a(4),o=a(1)("species");e.exports=function(e){var t="function"==typeof i[e]?i[e]:r[e];p&&t&&!t[o]&&n.f(t,o,{configurable:!0,get:function(){return this}})}},function(e,t,a){var r=a(3),i=a(14),n=a(1)("species");e.exports=function(e,t){var a,p=r(e).constructor;return void 0===p||void 0==(a=r(p)[n])?t:i(a)}},function(e,t,a){var r=a(20),i=a(15);e.exports=function(e){return function(t,a){var n,p,o=String(i(t)),s=r(a),d=o.length;return s<0||s>=d?e?"":void 0:(n=o.charCodeAt(s))<55296||n>56319||s+1===d||(p=o.charCodeAt(s+1))<56320||p>57343?e?o.charAt(s):n:e?o.slice(s,s+2):(n-55296<<10)+(p-56320)+65536}}},function(e,t,a){var r=a(20),i=Math.max,n=Math.min;e.exports=function(e,t){return(e=r(e))<0?i(e+t,0):n(e,t)}},function(e,t,a){var r=a(15);e.exports=function(e){return Object(r(e))}},function(e,t,a){var r=a(21),i=a(1)("iterator"),n=a(10);e.exports=a(6).getIteratorMethod=function(e){if(void 0!=e)return e[i]||e["@@iterator"]||n[r(e)]}},function(e,t,a){"use strict";var r=a(37),i=a(47),n=a(10),p=a(13);e.exports=a(27)(Array,"Array",function(e,t){this._t=p(e),this._i=0,this._k=t},function(){var e=this._t,t=this._k,a=this._i++;return!e||a>=e.length?(this._t=void 0,i(1)):"keys"==t?i(0,a):"values"==t?i(0,e[a]):i(0,[a,e[a]])},"values"),n.Arguments=n.Array,r("keys"),r("values"),r("entries")},function(e,t){},function(e,t,a){"use strict";var r,i,n,p=a(28),o=a(2),s=a(7),d=a(21),l=a(23),u=a(9),c=(a(3),a(14)),m=a(38),f=a(40),h=(a(58).set,a(60)),v=a(30).set,y=a(48)(),g="Promise",_=o.TypeError,b=o.process,w=o[g],b=o.process,E="process"==d(b),T=function(){},N=!!function(){try{var e=w.resolve(1),t=(e.constructor={})[a(1)("species")]=function(e){e(T,T)};return(E||"function"==typeof PromiseRejectionEvent)&&e.then(T)instanceof t}catch(e){}}(),S=function(e,t){return e===t||e===w&&t===n},O=function(e){var t;return!(!u(e)||"function"!=typeof(t=e.then))&&t},I=function(e){return S(w,e)?new D(e):new i(e)},D=i=function(e){var t,a;this.promise=new e(function(e,r){if(void 0!==t||void 0!==a)throw _("Bad Promise constructor");t=e,a=r}),this.resolve=c(t),this.reject=c(a)},A=function(e){try{e()}catch(e){return{error:e}}},k=function(e,t){if(!e._n){e._n=!0;var a=e._c;y(function(){for(var r=e._v,i=1==e._s,n=0;a.length>n;)!function(t){var a,n,p=i?t.ok:t.fail,o=t.resolve,s=t.reject,d=t.domain;try{p?(i||(2==e._h&&R(e),e._h=1),!0===p?a=r:(d&&d.enter(),a=p(r),d&&d.exit()),a===t.promise?s(_("Promise-chain cycle")):(n=O(a))?n.call(a,o,s):o(a)):s(r)}catch(e){s(e)}}(a[n++]);e._c=[],e._n=!1,t&&!e._h&&x(e)})}},x=function(e){v.call(o,function(){var t,a,r,i=e._v;if(C(e)&&(t=A(function(){E?b.emit("unhandledRejection",i,e):(a=o.onunhandledrejection)?a({promise:e,reason:i}):(r=o.console)&&r.error&&r.error("Unhandled promise rejection",i)}),e._h=E||C(e)?2:1),e._a=void 0,t)throw t.error})},C=function(e){if(1==e._h)return!1;for(var t,a=e._a||e._c,r=0;a.length>r;)if((t=a[r++]).fail||!C(t.promise))return!1;return!0},R=function(e){v.call(o,function(){var t;E?b.emit("rejectionHandled",e):(t=o.onrejectionhandled)&&t({promise:e,reason:e._v})})},V=function(e){var t=this;t._d||(t._d=!0,(t=t._w||t)._v=e,t._s=2,t._a||(t._a=t._c.slice()),k(t,!0))},F=function(e){var t,a=this;if(!a._d){a._d=!0,a=a._w||a;try{if(a===e)throw _("Promise can't be resolved itself");(t=O(e))?y(function(){var r={_w:a,_d:!1};try{t.call(e,s(F,r,1),s(V,r,1))}catch(e){V.call(r,e)}}):(a._v=e,a._s=1,k(a,!1))}catch(e){V.call({_w:a,_d:!1},e)}}};N||(w=function(e){m(this,w,g,"_h"),c(e),r.call(this);try{e(s(F,this,1),s(V,this,1))}catch(e){V.call(this,e)}},(r=function(e){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1}).prototype=a(56)(w.prototype,{then:function(e,t){var a=I(h(this,w));return a.ok="function"!=typeof e||e,a.fail="function"==typeof t&&t,a.domain=E?b.domain:void 0,this._c.push(a),this._a&&this._a.push(a),this._s&&k(this,!1),a.promise},catch:function(e){return this.then(void 0,e)}}),D=function(){var e=new r;this.promise=e,this.resolve=s(F,e,1),this.reject=s(V,e,1)}),l(l.G+l.W+!N*l.F,{Promise:w}),a(18)(w,g),a(59)(g),n=a(6)[g],l(l.S+!N*l.F,g,{reject:function(e){var t=I(this);return(0,t.reject)(e),t.promise}}),l(l.S+l.F*(p||!N),g,{resolve:function(e){if(e instanceof w&&S(e.constructor,this))return e;var t=I(this);return(0,t.resolve)(e),t.promise}}),l(l.S+!(N&&a(46)(function(e){w.all(e).catch(T)}))*l.F,g,{all:function(e){var t=this,a=I(t),r=a.resolve,i=a.reject,n=A(function(){var a=[],n=0,p=1;f(e,!1,function(e){var o=n++,s=!1;a.push(void 0),p++,t.resolve(e).then(function(e){s||(s=!0,a[o]=e,--p||r(a))},i)}),--p||r(a)});return n&&i(n.error),a.promise},race:function(e){var t=this,a=I(t),r=a.reject,i=A(function(){f(e,!1,function(e){t.resolve(e).then(a.resolve,r)})});return i&&r(i.error),a.promise}})},function(e,t,a){"use strict";var r=a(61)(!0);a(27)(String,"String",function(e){this._t=String(e),this._i=0},function(){var e,t=this._t,a=this._i;return a>=t.length?{value:void 0,done:!0}:(e=r(t,a),this._i+=e.length,{value:e,done:!1})})},function(e,t,a){a(65);for(var r=a(2),i=a(5),n=a(10),p=a(1)("toStringTag"),o=["NodeList","DOMTokenList","MediaList","StyleSheetList","CSSRuleList"],s=0;s<5;s++){var d=o[s],l=r[d],u=l&&l.prototype;u&&!u[p]&&i(u,p,d),n[d]=n.Array}},function(e,t){e.exports=a(35317)},function(e,t){e.exports=a(76982)}];function i(e){if(n[e])return n[e].exports;var t=n[e]={exports:{},id:e,loaded:!1};return r[e].call(t.exports,t,t.exports,i),t.loaded=!0,t.exports}var n={};return i.m=r,i.c=n,i.p="",i(0)}(a(35317),a(76982))},35600(e,t,a){let r,i=a(70857),n=a(52018),p=a(56071),{env:o}=process;function s(e,t={}){var a;return 0!==(a=function(e,{streamIsTTY:t,sniffFlags:a=!0}={}){let n=function(){if("FORCE_COLOR"in o)return"true"===o.FORCE_COLOR?1:"false"===o.FORCE_COLOR?0:0===o.FORCE_COLOR.length?1:Math.min(Number.parseInt(o.FORCE_COLOR,10),3)}();void 0!==n&&(r=n);let s=a?r:n;if(0===s)return 0;if(a){if(p("color=16m")||p("color=full")||p("color=truecolor"))return 3;if(p("color=256"))return 2}if(e&&!t&&void 0===s)return 0;let d=s||0;if("dumb"===o.TERM)return d;if("win32"===process.platform){let e=i.release().split(".");return Number(e[0])>=10&&Number(e[2])>=10586?Number(e[2])>=14931?3:2:1}if("CI"in o)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE","DRONE"].some(e=>e in o)||"codeship"===o.CI_NAME?1:d;if("TEAMCITY_VERSION"in o)return+!!/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(o.TEAMCITY_VERSION);if("truecolor"===o.COLORTERM)return 3;if("TERM_PROGRAM"in o){let e=Number.parseInt((o.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(o.TERM_PROGRAM){case"iTerm.app":return e>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(o.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(o.TERM)||"COLORTERM"in o?1:d}(e,{streamIsTTY:e&&e.isTTY,...t}))&&{level:a,hasBasic:!0,has256:a>=2,has16m:a>=3}}p("no-color")||p("no-colors")||p("color=false")||p("color=never")?r=0:(p("color")||p("colors")||p("color=true")||p("color=always"))&&(r=1),e.exports={supportsColor:s,stdout:s({isTTY:n.isatty(1)}),stderr:s({isTTY:n.isatty(2)})}},23246(e,t,a){var r=a(24876),i=a(91749),n={TRANSITIONAL:0,NONTRANSITIONAL:1};function p(e){return e.split("\0").map(function(e){return e.normalize("NFC")}).join("\0")}function o(e){for(var t=0,a=i.length-1;t<=a;){var r=Math.floor((t+a)/2),n=i[r];if(n[0][0]<=e&&n[0][1]>=e)return n;n[0][0]>e?a=r-1:t=r+1}return null}var s=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g;function d(e){return e.replace(s,"_").length}var l=/[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08E4-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B62\u0B63\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0C00-\u0C03\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D01-\u0D03\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D82\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EB9\u0EBB\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F\u109A-\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u180B-\u180D\u18A9\u1920-\u192B\u1930-\u193B\u19B0-\u19C0\u19C8\u19C9\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F\u1AB0-\u1ABE\u1B00-\u1B04\u1B34-\u1B44\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BE6-\u1BF3\u1C24-\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF2-\u1CF4\u1CF8\u1CF9\u1DC0-\u1DF5\u1DFC-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA880\uA881\uA8B4-\uA8C4\uA8E0-\uA8F1\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9E5\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2D]|\uD800[\uDDFD\uDEE0\uDF76-\uDF7A]|\uD802[\uDE01-\uDE03\uDE05\uDE06\uDE0C-\uDE0F\uDE38-\uDE3A\uDE3F\uDEE5\uDEE6]|\uD804[\uDC00-\uDC02\uDC38-\uDC46\uDC7F-\uDC82\uDCB0-\uDCBA\uDD00-\uDD02\uDD27-\uDD34\uDD73\uDD80-\uDD82\uDDB3-\uDDC0\uDE2C-\uDE37\uDEDF-\uDEEA\uDF01-\uDF03\uDF3C\uDF3E-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF57\uDF62\uDF63\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDCB0-\uDCC3\uDDAF-\uDDB5\uDDB8-\uDDC0\uDE30-\uDE40\uDEAB-\uDEB7]|\uD81A[\uDEF0-\uDEF4\uDF30-\uDF36]|\uD81B[\uDF51-\uDF7E\uDF8F-\uDF92]|\uD82F[\uDC9D\uDC9E]|\uD834[\uDD65-\uDD69\uDD6D-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD83A[\uDCD0-\uDCD6]|\uDB40[\uDD00-\uDDEF]/;e.exports.toASCII=function(e,t,a,i){var s=function e(t,a,i){var s=function(e,t,a){for(var r=!1,i="",p=d(e),s=0;s<p;++s){var l=e.codePointAt(s),u=o(l);switch(u[1]){case"disallowed":r=!0,i+=String.fromCodePoint(l);break;case"ignored":break;case"mapped":i+=String.fromCodePoint.apply(String,u[2]);break;case"deviation":a===n.TRANSITIONAL?i+=String.fromCodePoint.apply(String,u[2]):i+=String.fromCodePoint(l);break;case"valid":i+=String.fromCodePoint(l);break;case"disallowed_STD3_mapped":t?(r=!0,i+=String.fromCodePoint(l)):i+=String.fromCodePoint.apply(String,u[2]);break;case"disallowed_STD3_valid":t&&(r=!0),i+=String.fromCodePoint(l)}}return{string:i,error:r}}(t,a,i);s.string=p(s.string);for(var u=s.string.split("."),c=0;c<u.length;++c)try{var m=function(t){"xn--"===t.substr(0,4)&&(t=r.toUnicode(t),n.NONTRANSITIONAL);var a=!1;(p(t)!==t||"-"===t[3]&&"-"===t[4]||"-"===t[0]||"-"===t[t.length-1]||-1!==t.indexOf(".")||0===t.search(l))&&(a=!0);for(var i=d(t),s=0;s<i;++s){var u=o(t.codePointAt(s));if(e===n.TRANSITIONAL&&"valid"!==u[1]||e===n.NONTRANSITIONAL&&"valid"!==u[1]&&"deviation"!==u[1]){a=!0;break}}return{label:t,error:a}}(u[c]);u[c]=m.label,s.error=s.error||m.error}catch(e){s.error=!0}return{string:u.join("."),error:s.error}}(e,t,a),u=s.string.split(".");if(u=u.map(function(e){try{return r.toASCII(e)}catch(t){return s.error=!0,e}}),i){var c=u.slice(0,u.length-1).join(".").length;(c.length>253||0===c.length)&&(s.error=!0);for(var m=0;m<u.length;++m)if(u.length>63||0===u.length){s.error=!0;break}}return s.error?null:u.join(".")},e.exports.PROCESSING_OPTIONS=n},98706(e,t,a){let r=a(78323);t.implementation=class{constructor(e){let t=e[0],a=e[1],i=null;if(void 0!==a&&"failure"===(i=r.basicURLParse(a)))throw TypeError("Invalid base URL");let n=r.basicURLParse(t,{baseURL:i});if("failure"===n)throw TypeError("Invalid URL");this._url=n}get href(){return r.serializeURL(this._url)}set href(e){let t=r.basicURLParse(e);if("failure"===t)throw TypeError("Invalid URL");this._url=t}get origin(){return r.serializeURLOrigin(this._url)}get protocol(){return this._url.scheme+":"}set protocol(e){r.basicURLParse(e+":",{url:this._url,stateOverride:"scheme start"})}get username(){return this._url.username}set username(e){r.cannotHaveAUsernamePasswordPort(this._url)||r.setTheUsername(this._url,e)}get password(){return this._url.password}set password(e){r.cannotHaveAUsernamePasswordPort(this._url)||r.setThePassword(this._url,e)}get host(){let e=this._url;return null===e.host?"":null===e.port?r.serializeHost(e.host):r.serializeHost(e.host)+":"+r.serializeInteger(e.port)}set host(e){this._url.cannotBeABaseURL||r.basicURLParse(e,{url:this._url,stateOverride:"host"})}get hostname(){return null===this._url.host?"":r.serializeHost(this._url.host)}set hostname(e){this._url.cannotBeABaseURL||r.basicURLParse(e,{url:this._url,stateOverride:"hostname"})}get port(){return null===this._url.port?"":r.serializeInteger(this._url.port)}set port(e){r.cannotHaveAUsernamePasswordPort(this._url)||(""===e?this._url.port=null:r.basicURLParse(e,{url:this._url,stateOverride:"port"}))}get pathname(){return this._url.cannotBeABaseURL?this._url.path[0]:0===this._url.path.length?"":"/"+this._url.path.join("/")}set pathname(e){this._url.cannotBeABaseURL||(this._url.path=[],r.basicURLParse(e,{url:this._url,stateOverride:"path start"}))}get search(){return null===this._url.query||""===this._url.query?"":"?"+this._url.query}set search(e){let t=this._url;if(""===e){t.query=null;return}let a="?"===e[0]?e.substring(1):e;t.query="",r.basicURLParse(a,{url:t,stateOverride:"query"})}get hash(){return null===this._url.fragment||""===this._url.fragment?"":"#"+this._url.fragment}set hash(e){if(""===e){this._url.fragment=null;return}let t="#"===e[0]?e.substring(1):e;this._url.fragment="",r.basicURLParse(t,{url:this._url,stateOverride:"fragment"})}toJSON(){return this.href}}},76447(e,t,a){let r=a(36151),i=a(4887),n=a(98706),p=i.implSymbol;function o(t){if(!this||this[p]||!(this instanceof o))throw TypeError("Failed to construct 'URL': Please use the 'new' operator, this DOM object constructor cannot be called as a function.");if(arguments.length<1)throw TypeError("Failed to construct 'URL': 1 argument required, but only "+arguments.length+" present.");let a=[];for(let e=0;e<arguments.length&&e<2;++e)a[e]=arguments[e];a[0]=r.USVString(a[0]),void 0!==a[1]&&(a[1]=r.USVString(a[1])),e.exports.setup(this,a)}o.prototype.toJSON=function(){if(!this||!e.exports.is(this))throw TypeError("Illegal invocation");let t=[];for(let e=0;e<arguments.length&&e<0;++e)t[e]=arguments[e];return this[p].toJSON.apply(this[p],t)},Object.defineProperty(o.prototype,"href",{get(){return this[p].href},set(e){e=r.USVString(e),this[p].href=e},enumerable:!0,configurable:!0}),o.prototype.toString=function(){if(!this||!e.exports.is(this))throw TypeError("Illegal invocation");return this.href},Object.defineProperty(o.prototype,"origin",{get(){return this[p].origin},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"protocol",{get(){return this[p].protocol},set(e){e=r.USVString(e),this[p].protocol=e},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"username",{get(){return this[p].username},set(e){e=r.USVString(e),this[p].username=e},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"password",{get(){return this[p].password},set(e){e=r.USVString(e),this[p].password=e},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"host",{get(){return this[p].host},set(e){e=r.USVString(e),this[p].host=e},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"hostname",{get(){return this[p].hostname},set(e){e=r.USVString(e),this[p].hostname=e},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"port",{get(){return this[p].port},set(e){e=r.USVString(e),this[p].port=e},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"pathname",{get(){return this[p].pathname},set(e){e=r.USVString(e),this[p].pathname=e},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"search",{get(){return this[p].search},set(e){e=r.USVString(e),this[p].search=e},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"hash",{get(){return this[p].hash},set(e){e=r.USVString(e),this[p].hash=e},enumerable:!0,configurable:!0}),e.exports={is:e=>!!e&&e[p]instanceof n.implementation,create(e,t){let a=Object.create(o.prototype);return this.setup(a,e,t),a},setup(e,t,a){a||(a={}),a.wrapper=e,e[p]=new n.implementation(t,a),e[p][i.wrapperSymbol]=e},interface:o,expose:{Window:{URL:o},Worker:{URL:o}}}},44044(e,t,a){t.k=a(76447).interface,a(78323).serializeURL,a(78323).serializeURLOrigin,a(78323).basicURLParse,a(78323).setTheUsername,a(78323).setThePassword,a(78323).serializeHost,a(78323).serializeInteger,a(78323).parseURL},78323(e,t,a){let r=a(24876),i=a(23246),n={ftp:21,file:null,gopher:70,http:80,https:443,ws:80,wss:443},p=Symbol("failure");function o(e){return r.ucs2.decode(e).length}function s(e,t){let a=e[t];return isNaN(a)?void 0:String.fromCodePoint(a)}function d(e){return e>=48&&e<=57}function l(e){return e>=65&&e<=90||e>=97&&e<=122}function u(e){return d(e)||e>=65&&e<=70||e>=97&&e<=102}function c(e){return"."===e||"%2e"===e.toLowerCase()}function m(e){return 2===e.length&&l(e.codePointAt(0))&&(":"===e[1]||"|"===e[1])}function f(e){return void 0!==n[e]}function h(e){return f(e.scheme)}function v(e){let t=e.toString(16).toUpperCase();return 1===t.length&&(t="0"+t),"%"+t}function y(e){return e<=31||e>126}let g=new Set([32,34,35,60,62,63,96,123,125]);function _(e){return y(e)||g.has(e)}let b=new Set([47,58,59,61,64,91,92,93,94,124]);function w(e){return _(e)||b.has(e)}function E(e,t){let a=String.fromCodePoint(e);if(t(e)){let e=new Buffer(a),t="";for(let a=0;a<e.length;++a)t+=v(e[a]);return t}return a}function T(e,t){if("["===e[0])return"]"!==e[e.length-1]?p:function(e){let t=[0,0,0,0,0,0,0,0],a=0,i=null,n=0;if(58===(e=r.ucs2.decode(e))[n]){if(58!==e[n+1])return p;n+=2,i=++a}for(;n<e.length;){if(8===a)return p;if(58===e[n]){if(null!==i)return p;++n,i=++a;continue}let r=0,o=0;for(;o<4&&u(e[n]);)r=16*r+parseInt(s(e,n),16),++n,++o;if(46===e[n]){if(0===o||(n-=o,a>6))return p;let r=0;for(;void 0!==e[n];){let i=null;if(r>0)if(46!==e[n]||!(r<4))return p;else++n;if(!d(e[n]))return p;for(;d(e[n]);){let t=parseInt(s(e,n));if(null===i)i=t;else{if(0===i)return p;i=10*i+t}if(i>255)return p;++n}t[a]=256*t[a]+i,(2==++r||4===r)&&++a}if(4!==r)return p;break}if(58===e[n]){if(void 0===e[++n])return p}else if(void 0!==e[n])return p;t[a]=r,++a}if(null!==i){let e=a-i;for(a=7;0!==a&&e>0;){let r=t[i+e-1];t[i+e-1]=t[a],t[a]=r,--a,--e}}else if(null===i&&8!==a)return p;return t}(e.substring(1,e.length-1));if(!t){var a=e;if(-1!==a.search(/\u0000|\u0009|\u000A|\u000D|\u0020|#|\/|:|\?|@|\[|\\|\]/))return p;let t="",i=r.ucs2.decode(a);for(let e=0;e<i.length;++e)t+=E(i[e],y);return t}let n=function(e){let t=new Buffer(e),a=[];for(let e=0;e<t.length;++e)37!==t[e]?a.push(t[e]):37===t[e]&&u(t[e+1])&&u(t[e+2])?(a.push(parseInt(t.slice(e+1,e+3).toString(),16)),e+=2):a.push(t[e]);return new Buffer(a).toString()}(e),o=i.toASCII(n,!1,i.PROCESSING_OPTIONS.NONTRANSITIONAL,!1);if(null===o||-1!==o.search(/\u0000|\u0009|\u000A|\u000D|\u0020|#|%|\/|:|\?|@|\[|\\|\]/))return p;let l=function(e){let t=e.split(".");if(""===t[t.length-1]&&t.length>1&&t.pop(),t.length>4)return e;let a=[];for(let r of t){if(""===r)return e;let t=function(e){let t=10;return(e.length>=2&&"0"===e.charAt(0)&&"x"===e.charAt(1).toLowerCase()?(e=e.substring(2),t=16):e.length>=2&&"0"===e.charAt(0)&&(e=e.substring(1),t=8),""===e)?0:(10===t?/[^0-9]/:16===t?/[^0-9A-Fa-f]/:/[^0-7]/).test(e)?p:parseInt(e,t)}(r);if(t===p)return e;a.push(t)}for(let e=0;e<a.length-1;++e)if(a[e]>255)return p;if(a[a.length-1]>=Math.pow(256,5-a.length))return p;let r=a.pop(),i=0;for(let e of a)r+=e*Math.pow(256,3-i),++i;return r}(o);return"number"==typeof l||l===p?l:o}function N(e){if("number"==typeof e){let t="",a=e;for(let e=1;e<=4;++e)t=String(a%256)+t,4!==e&&(t="."+t),a=Math.floor(a/256);return t}return e instanceof Array?"["+function(e){let t="",a=function(e){let t=null,a=1,r=null,i=0;for(let n=0;n<e.length;++n)0!==e[n]?(i>a&&(t=r,a=i),r=null,i=0):(null===r&&(r=n),++i);return i>a&&(t=r,a=i),{idx:t,len:a}}(e).idx,r=!1;for(let i=0;i<=7;++i)if(!r||0!==e[i]){if(r&&(r=!1),a===i){t+=0===i?"::":":",r=!0;continue}t+=e[i].toString(16),7!==i&&(t+=":")}return t}(e)+"]":e}function S(e){var t;let a=e.path;0===a.length||"file"===e.scheme&&1===a.length&&(t=a[0],/^[A-Za-z]:$/.test(t))||a.pop()}function O(e){return""!==e.username||""!==e.password}function I(e,t,a,i,n){if(this.pointer=0,this.input=e,this.base=t||null,this.encodingOverride=a||"utf-8",this.stateOverride=n,this.url=i,this.failure=!1,this.parseError=!1,!this.url){this.url={scheme:"",username:"",password:"",host:null,port:null,path:[],query:null,fragment:null,cannotBeABaseURL:!1};let e=this.input.replace(/^[\u0000-\u001F\u0020]+|[\u0000-\u001F\u0020]+$/g,"");e!==this.input&&(this.parseError=!0),this.input=e}let o=this.input.replace(/\u0009|\u000A|\u000D/g,"");for(o!==this.input&&(this.parseError=!0),this.input=o,this.state=n||"scheme start",this.buffer="",this.atFlag=!1,this.arrFlag=!1,this.passwordTokenSeenFlag=!1,this.input=r.ucs2.decode(this.input);this.pointer<=this.input.length;++this.pointer){let e=this.input[this.pointer],t=isNaN(e)?void 0:String.fromCodePoint(e),a=this["parse "+this.state](e,t);if(a){if(a===p){this.failure=!0;break}}else break}}I.prototype["parse scheme start"]=function(e,t){if(l(e))this.buffer+=t.toLowerCase(),this.state="scheme";else{if(this.stateOverride)return this.parseError=!0,p;this.state="no scheme",--this.pointer}return!0},I.prototype["parse scheme"]=function(e,t){if(l(e)||d(e)||43===e||45===e||46===e)this.buffer+=t.toLowerCase();else if(58===e){if(this.stateOverride&&(h(this.url)&&!f(this.buffer)||!h(this.url)&&f(this.buffer)||(O(this.url)||null!==this.url.port)&&"file"===this.buffer||"file"===this.url.scheme&&(""===this.url.host||null===this.url.host))||(this.url.scheme=this.buffer,this.buffer="",this.stateOverride))return!1;"file"===this.url.scheme?((47!==this.input[this.pointer+1]||47!==this.input[this.pointer+2])&&(this.parseError=!0),this.state="file"):h(this.url)&&null!==this.base&&this.base.scheme===this.url.scheme?this.state="special relative or authority":h(this.url)?this.state="special authority slashes":47===this.input[this.pointer+1]?(this.state="path or authority",++this.pointer):(this.url.cannotBeABaseURL=!0,this.url.path.push(""),this.state="cannot-be-a-base-URL path")}else{if(this.stateOverride)return this.parseError=!0,p;this.buffer="",this.state="no scheme",this.pointer=-1}return!0},I.prototype["parse no scheme"]=function(e){return null===this.base||this.base.cannotBeABaseURL&&35!==e?p:(this.base.cannotBeABaseURL&&35===e?(this.url.scheme=this.base.scheme,this.url.path=this.base.path.slice(),this.url.query=this.base.query,this.url.fragment="",this.url.cannotBeABaseURL=!0,this.state="fragment"):("file"===this.base.scheme?this.state="file":this.state="relative",--this.pointer),!0)},I.prototype["parse special relative or authority"]=function(e){return 47===e&&47===this.input[this.pointer+1]?(this.state="special authority ignore slashes",++this.pointer):(this.parseError=!0,this.state="relative",--this.pointer),!0},I.prototype["parse path or authority"]=function(e){return 47===e?this.state="authority":(this.state="path",--this.pointer),!0},I.prototype["parse relative"]=function(e){return this.url.scheme=this.base.scheme,isNaN(e)?(this.url.username=this.base.username,this.url.password=this.base.password,this.url.host=this.base.host,this.url.port=this.base.port,this.url.path=this.base.path.slice(),this.url.query=this.base.query):47===e?this.state="relative slash":63===e?(this.url.username=this.base.username,this.url.password=this.base.password,this.url.host=this.base.host,this.url.port=this.base.port,this.url.path=this.base.path.slice(),this.url.query="",this.state="query"):35===e?(this.url.username=this.base.username,this.url.password=this.base.password,this.url.host=this.base.host,this.url.port=this.base.port,this.url.path=this.base.path.slice(),this.url.query=this.base.query,this.url.fragment="",this.state="fragment"):h(this.url)&&92===e?(this.parseError=!0,this.state="relative slash"):(this.url.username=this.base.username,this.url.password=this.base.password,this.url.host=this.base.host,this.url.port=this.base.port,this.url.path=this.base.path.slice(0,this.base.path.length-1),this.state="path",--this.pointer),!0},I.prototype["parse relative slash"]=function(e){return h(this.url)&&(47===e||92===e)?(92===e&&(this.parseError=!0),this.state="special authority ignore slashes"):47===e?this.state="authority":(this.url.username=this.base.username,this.url.password=this.base.password,this.url.host=this.base.host,this.url.port=this.base.port,this.state="path",--this.pointer),!0},I.prototype["parse special authority slashes"]=function(e){return 47===e&&47===this.input[this.pointer+1]?(this.state="special authority ignore slashes",++this.pointer):(this.parseError=!0,this.state="special authority ignore slashes",--this.pointer),!0},I.prototype["parse special authority ignore slashes"]=function(e){return 47!==e&&92!==e?(this.state="authority",--this.pointer):this.parseError=!0,!0},I.prototype["parse authority"]=function(e,t){if(64===e){this.parseError=!0,this.atFlag&&(this.buffer="%40"+this.buffer),this.atFlag=!0;let e=o(this.buffer);for(let t=0;t<e;++t){let e=this.buffer.codePointAt(t);if(58===e&&!this.passwordTokenSeenFlag){this.passwordTokenSeenFlag=!0;continue}let a=E(e,w);this.passwordTokenSeenFlag?this.url.password+=a:this.url.username+=a}this.buffer=""}else if(isNaN(e)||47===e||63===e||35===e||h(this.url)&&92===e){if(this.atFlag&&""===this.buffer)return this.parseError=!0,p;this.pointer-=o(this.buffer)+1,this.buffer="",this.state="host"}else this.buffer+=t;return!0},I.prototype["parse hostname"]=I.prototype["parse host"]=function(e,t){if(this.stateOverride&&"file"===this.url.scheme)--this.pointer,this.state="file host";else if(58!==e||this.arrFlag)if(isNaN(e)||47===e||63===e||35===e||h(this.url)&&92===e){if(--this.pointer,h(this.url)&&""===this.buffer)return this.parseError=!0,p;if(this.stateOverride&&""===this.buffer&&(O(this.url)||null!==this.url.port))return this.parseError=!0,!1;let e=T(this.buffer,h(this.url));if(e===p)return p;if(this.url.host=e,this.buffer="",this.state="path start",this.stateOverride)return!1}else 91===e?this.arrFlag=!0:93===e&&(this.arrFlag=!1),this.buffer+=t;else{if(""===this.buffer)return this.parseError=!0,p;let e=T(this.buffer,h(this.url));if(e===p)return p;if(this.url.host=e,this.buffer="",this.state="port","hostname"===this.stateOverride)return!1}return!0},I.prototype["parse port"]=function(e,t){if(d(e))this.buffer+=t;else{if(!(isNaN(e)||47===e||63===e||35===e||h(this.url)&&92===e)&&!this.stateOverride)return this.parseError=!0,p;if(""!==this.buffer){let e=parseInt(this.buffer);if(e>65535)return this.parseError=!0,p;this.url.port=e===n[this.url.scheme]?null:e,this.buffer=""}if(this.stateOverride)return!1;this.state="path start",--this.pointer}return!0};let D=new Set([47,92,63,35]);I.prototype["parse file"]=function(e){if(this.url.scheme="file",47===e||92===e)92===e&&(this.parseError=!0),this.state="file slash";else if(null!==this.base&&"file"===this.base.scheme)if(isNaN(e))this.url.host=this.base.host,this.url.path=this.base.path.slice(),this.url.query=this.base.query;else if(63===e)this.url.host=this.base.host,this.url.path=this.base.path.slice(),this.url.query="",this.state="query";else if(35===e)this.url.host=this.base.host,this.url.path=this.base.path.slice(),this.url.query=this.base.query,this.url.fragment="",this.state="fragment";else{var t;this.input.length-this.pointer-1!=0&&(t=this.input[this.pointer+1],l(e)&&(58===t||124===t))&&(!(this.input.length-this.pointer-1>=2)||D.has(this.input[this.pointer+2]))?this.parseError=!0:(this.url.host=this.base.host,this.url.path=this.base.path.slice(),S(this.url)),this.state="path",--this.pointer}else this.state="path",--this.pointer;return!0},I.prototype["parse file slash"]=function(e){if(47===e||92===e)92===e&&(this.parseError=!0),this.state="file host";else{if(null!==this.base&&"file"===this.base.scheme){var t;2===(t=this.base.path[0]).length&&l(t.codePointAt(0))&&":"===t[1]?this.url.path.push(this.base.path[0]):this.url.host=this.base.host}this.state="path",--this.pointer}return!0},I.prototype["parse file host"]=function(e,t){if(isNaN(e)||47===e||92===e||63===e||35===e)if(--this.pointer,!this.stateOverride&&m(this.buffer))this.parseError=!0,this.state="path";else if(""===this.buffer){if(this.url.host="",this.stateOverride)return!1;this.state="path start"}else{let e=T(this.buffer,h(this.url));if(e===p)return p;if("localhost"===e&&(e=""),this.url.host=e,this.stateOverride)return!1;this.buffer="",this.state="path start"}else this.buffer+=t;return!0},I.prototype["parse path start"]=function(e){return h(this.url)?(92===e&&(this.parseError=!0),this.state="path",47!==e&&92!==e&&--this.pointer):this.stateOverride||63!==e?this.stateOverride||35!==e?void 0!==e&&(this.state="path",47!==e&&--this.pointer):(this.url.fragment="",this.state="fragment"):(this.url.query="",this.state="query"),!0},I.prototype["parse path"]=function(e){if(isNaN(e)||47===e||h(this.url)&&92===e||!this.stateOverride&&(63===e||35===e)){var t;if((h(this.url)&&92===e&&(this.parseError=!0),".."===(t=(t=this.buffer).toLowerCase())||"%2e."===t||".%2e"===t||"%2e%2e"===t)?(S(this.url),47===e||h(this.url)&&92===e||this.url.path.push("")):c(this.buffer)&&47!==e&&!(h(this.url)&&92===e)?this.url.path.push(""):c(this.buffer)||("file"===this.url.scheme&&0===this.url.path.length&&m(this.buffer)&&(""!==this.url.host&&null!==this.url.host&&(this.parseError=!0,this.url.host=""),this.buffer=this.buffer[0]+":"),this.url.path.push(this.buffer)),this.buffer="","file"===this.url.scheme&&(void 0===e||63===e||35===e))for(;this.url.path.length>1&&""===this.url.path[0];)this.parseError=!0,this.url.path.shift();63===e&&(this.url.query="",this.state="query"),35===e&&(this.url.fragment="",this.state="fragment")}else 37!==e||u(this.input[this.pointer+1])&&u(this.input[this.pointer+2])||(this.parseError=!0),this.buffer+=E(e,_);return!0},I.prototype["parse cannot-be-a-base-URL path"]=function(e){return 63===e?(this.url.query="",this.state="query"):35===e?(this.url.fragment="",this.state="fragment"):(isNaN(e)||37===e||(this.parseError=!0),37!==e||u(this.input[this.pointer+1])&&u(this.input[this.pointer+2])||(this.parseError=!0),isNaN(e)||(this.url.path[0]=this.url.path[0]+E(e,y))),!0},I.prototype["parse query"]=function(e,t){if(isNaN(e)||!this.stateOverride&&35===e){h(this.url)&&"ws"!==this.url.scheme&&"wss"!==this.url.scheme||(this.encodingOverride="utf-8");let t=new Buffer(this.buffer);for(let e=0;e<t.length;++e)t[e]<33||t[e]>126||34===t[e]||35===t[e]||60===t[e]||62===t[e]?this.url.query+=v(t[e]):this.url.query+=String.fromCodePoint(t[e]);this.buffer="",35===e&&(this.url.fragment="",this.state="fragment")}else 37!==e||u(this.input[this.pointer+1])&&u(this.input[this.pointer+2])||(this.parseError=!0),this.buffer+=t;return!0},I.prototype["parse fragment"]=function(e){return isNaN(e)||(0===e?this.parseError=!0:(37!==e||u(this.input[this.pointer+1])&&u(this.input[this.pointer+2])||(this.parseError=!0),this.url.fragment+=E(e,y))),!0},e.exports.serializeURL=function(e,t){let a=e.scheme+":";if(null!==e.host?(a+="//",(""!==e.username||""!==e.password)&&(a+=e.username,""!==e.password&&(a+=":"+e.password),a+="@"),a+=N(e.host),null!==e.port&&(a+=":"+e.port)):null===e.host&&"file"===e.scheme&&(a+="//"),e.cannotBeABaseURL)a+=e.path[0];else for(let t of e.path)a+="/"+t;return null!==e.query&&(a+="?"+e.query),t||null===e.fragment||(a+="#"+e.fragment),a},e.exports.serializeURLOrigin=function(t){switch(t.scheme){case"blob":try{return e.exports.serializeURLOrigin(e.exports.parseURL(t.path[0]))}catch(e){return"null"}case"ftp":case"gopher":case"http":case"https":case"ws":case"wss":var a;let r;return r=(a={scheme:t.scheme,host:t.host,port:t.port}).scheme+"://"+N(a.host),null!==a.port&&(r+=":"+a.port),r;case"file":return"file://";default:return"null"}},e.exports.basicURLParse=function(e,t){void 0===t&&(t={});let a=new I(e,t.baseURL,t.encodingOverride,t.url,t.stateOverride);return a.failure?"failure":a.url},e.exports.setTheUsername=function(e,t){e.username="";let a=r.ucs2.decode(t);for(let t=0;t<a.length;++t)e.username+=E(a[t],w)},e.exports.setThePassword=function(e,t){e.password="";let a=r.ucs2.decode(t);for(let t=0;t<a.length;++t)e.password+=E(a[t],w)},e.exports.serializeHost=N,e.exports.cannotHaveAUsernamePasswordPort=function(e){return null===e.host||""===e.host||e.cannotBeABaseURL||"file"===e.scheme},e.exports.serializeInteger=function(e){return String(e)},e.exports.parseURL=function(t,a){return void 0===a&&(a={}),e.exports.basicURLParse(t,{baseURL:a.baseURL,encodingOverride:a.encodingOverride})}},4887(e){e.exports.wrapperSymbol=Symbol("wrapper"),e.exports.implSymbol=Symbol("impl")},36151(e){var t={};function a(e,t){!t.unsigned&&--e;let a=t.unsigned?0:-Math.pow(2,e),r=Math.pow(2,e)-1,i=t.moduloBitLength?Math.pow(2,t.moduloBitLength):Math.pow(2,e),n=t.moduloBitLength?Math.pow(2,t.moduloBitLength-1):Math.pow(2,e-1);return function(e,p){p||(p={});let o=+e;if(p.enforceRange){if(!Number.isFinite(o))throw TypeError("Argument is not a finite number");if((o=(o<0?-1:1)*Math.floor(Math.abs(o)))<a||o>r)throw TypeError("Argument is not in byte range");return o}if(!isNaN(o)&&p.clamp){var s;return(o=(s=o)%1==.5&&(1&s)==0?Math.floor(s):Math.round(s))<a&&(o=a),o>r&&(o=r),o}if(!Number.isFinite(o)||0===o)return 0;if(o=(o<0?-1:1)*Math.floor(Math.abs(o))%i,!t.unsigned&&o>=n)return o-i;if(t.unsigned){if(o<0)o+=i;else if(-0===o)return 0}return o}}e.exports=t,t.void=function(){},t.boolean=function(e){return!!e},t.byte=a(8,{unsigned:!1}),t.octet=a(8,{unsigned:!0}),t.short=a(16,{unsigned:!1}),t["unsigned short"]=a(16,{unsigned:!0}),t.long=a(32,{unsigned:!1}),t["unsigned long"]=a(32,{unsigned:!0}),t["long long"]=a(32,{unsigned:!1,moduloBitLength:64}),t["unsigned long long"]=a(32,{unsigned:!0,moduloBitLength:64}),t.double=function(e){let t=+e;if(!Number.isFinite(t))throw TypeError("Argument is not a finite floating-point value");return t},t["unrestricted double"]=function(e){let t=+e;if(isNaN(t))throw TypeError("Argument is NaN");return t},t.float=t.double,t["unrestricted float"]=t["unrestricted double"],t.DOMString=function(e,t){return(t||(t={}),t.treatNullAsEmptyString&&null===e)?"":String(e)},t.ByteString=function(e,t){let a,r=String(e);for(let e=0;void 0!==(a=r.codePointAt(e));++e)if(a>255)throw TypeError("Argument is not a valid bytestring");return r},t.USVString=function(e){let t=String(e),a=t.length,r=[];for(let e=0;e<a;++e){let i=t.charCodeAt(e);if(i<55296||i>57343)r.push(String.fromCodePoint(i));else if(56320<=i&&i<=57343)r.push(String.fromCodePoint(65533));else if(e===a-1)r.push(String.fromCodePoint(65533));else{let a=t.charCodeAt(e+1);if(56320<=a&&a<=57343){let t=1023&i,n=1023&a;r.push(String.fromCodePoint(65536+1024*t+n)),++e}else r.push(String.fromCodePoint(65533))}}return r.join("")},t.Date=function(e,t){if(!(e instanceof Date))throw TypeError("Argument is not a Date object");if(!isNaN(e))return e},t.RegExp=function(e,t){return e instanceof RegExp||(e=new RegExp(e)),e}},42613(e){e.exports=t("assert")},35317(e){e.exports=t("child_process")},76982(e){e.exports=t("crypto")},24434(e){e.exports=t("events")},69278(e){e.exports=t("net")},70857(e){e.exports=t("os")},24876(e){e.exports=t("punycode")},64756(e){e.exports=t("tls")},52018(e){e.exports=t("tty")},87016(e){e.exports=t("url")},39023(e){e.exports=t("util")},54506(e,t,a){Object.defineProperty(t,"__esModule",{value:!0});var r,i=a(85608),n=a(70916),p=a(4232),o=a(28876),s=a(55888),d=a(5437),l=a(94037),u=a(53570),c=a(60837),m=a(44592),f=a(39283),h=a(36869),v=a(25979),y=a(19371),g=a(94370),_=s&&"object"==typeof s&&"default"in s?s.default:s;function b(e){return null!==e&&"object"==typeof e}var w=Object.prototype.hasOwnProperty,E=function(e,t,a){return this.merge(e[a],t[a])},T=function(){function e(e){void 0===e&&(e=E),this.reconciler=e,this.isObject=b,this.pastCopies=new Set}return e.prototype.merge=function(e,t){for(var a=this,r=[],n=2;n<arguments.length;n++)r[n-2]=arguments[n];return b(t)&&b(e)?(Object.keys(t).forEach(function(n){if(w.call(e,n)){var p=e[n];if(t[n]!==p){var o=a.reconciler.apply(a,i.__spreadArray([e,t,n],r,!1));o!==p&&((e=a.shallowCopyForMerge(e))[n]=o)}}else(e=a.shallowCopyForMerge(e))[n]=t[n]}),e):t},e.prototype.shallowCopyForMerge=function(e){return b(e)&&!this.pastCopies.has(e)&&(e=Array.isArray(e)?e.slice(0):i.__assign({__proto__:Object.getPrototypeOf(e)},e),this.pastCopies.add(e)),e},e}();function N(e){return!!e&&e<7}function S(e){return!!e.directives&&e.directives.some(O)}function O(e){return"nonreactive"===e.name.value}t.NetworkStatus=void 0,(r=t.NetworkStatus||(t.NetworkStatus={}))[r.loading=1]="loading",r[r.setVariables=2]="setVariables",r[r.fetchMore=3]="fetchMore",r[r.refetch=4]="refetch",r[r.poll=6]="poll",r[r.ready=7]="ready",r[r.error=8]="error";var I=Object.assign,D=Object.hasOwnProperty,A=function(e){function a(t){var r=t.queryManager,n=t.queryInfo,p=t.options,o=this,s=a.inactiveOnCreation.getValue();(o=e.call(this,function(e){s&&(r.queries.set(o.queryId,n),s=!1);try{var t=e._subscription._observer;t&&!t.error&&(t.error=k)}catch(e){}var a=!o.observers.size;o.observers.add(e);var i=o.last;return i&&i.error?e.error&&e.error(i.error):i&&i.result&&e.next&&e.next(o.maskResult(i.result)),a&&o.reobserve().catch(function(){}),function(){o.observers.delete(e)&&!o.observers.size&&o.tearDownQuery()}})||this).observers=new Set,o.subscriptions=new Set,o.dirty=!1,o.queryInfo=n,o.queryManager=r,o.waitForOwnResult=C(p.fetchPolicy),o.isTornDown=!1,o.subscribeToMore=o.subscribeToMore.bind(o),o.maskResult=o.maskResult.bind(o);var l=r.defaultOptions.watchQuery,u=(void 0===l?{}:l).fetchPolicy,c=void 0===u?"cache-first":u,m=p.fetchPolicy,f=void 0===m?c:m,h=p.initialFetchPolicy,v=void 0===h?"standby"===f?c:f:h;o.options=i.__assign(i.__assign({},p),{initialFetchPolicy:v,fetchPolicy:f}),o.queryId=n.queryId||r.generateQueryId();var y=d.getOperationDefinition(o.query);return o.queryName=y&&y.name&&y.name.value,o}return i.__extends(a,e),Object.defineProperty(a.prototype,"query",{get:function(){return this.lastQuery||this.options.query},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"variables",{get:function(){return this.options.variables},enumerable:!1,configurable:!0}),a.prototype.result=function(){var e=this;return new Promise(function(t,a){var r={next:function(a){t(a),e.observers.delete(r),e.observers.size||e.queryManager.removeQuery(e.queryId),setTimeout(function(){i.unsubscribe()},0)},error:a},i=e.subscribe(r)})},a.prototype.resetDiff=function(){this.queryInfo.resetDiff()},a.prototype.getCurrentFullResult=function(e){void 0===e&&(e=!0);var a=this.getLastResult(!0),r=this.queryInfo.networkStatus||a&&a.networkStatus||t.NetworkStatus.ready,n=i.__assign(i.__assign({},a),{loading:N(r),networkStatus:r}),p=this.options.fetchPolicy,o=void 0===p?"cache-first":p;if(C(o)||this.queryManager.getDocumentInfo(this.query).hasForcedResolvers);else if(this.waitForOwnResult)this.queryInfo.updateWatch();else{var d=this.queryInfo.getDiff();(d.complete||this.options.returnPartialData)&&(n.data=d.result),s.equal(n.data,{})&&(n.data=void 0),d.complete?(delete n.partial,d.complete&&n.networkStatus===t.NetworkStatus.loading&&("cache-first"===o||"cache-only"===o)&&(n.networkStatus=t.NetworkStatus.ready,n.loading=!1)):n.partial=!0,n.networkStatus===t.NetworkStatus.ready&&(n.error||n.errors)&&(n.networkStatus=t.NetworkStatus.error),!1===globalThis.__DEV__||d.complete||this.options.partialRefetch||n.loading||n.data||n.error||x(d.missing)}return e&&this.updateLastResult(n),n},a.prototype.getCurrentResult=function(e){return void 0===e&&(e=!0),this.maskResult(this.getCurrentFullResult(e))},a.prototype.isDifferentFromLastResult=function(e,t){if(!this.last)return!0;var a,r,n,p,o,l=this.queryManager.getDocumentInfo(this.query),u=this.queryManager.dataMasking,c=u?l.nonReactiveQuery:this.query;return(u||l.hasNonreactiveDirective?(a=this.last.result,r=this.variables,n=a.data,p=i.__rest(a,["data"]),o=e.data,!(_(p,i.__rest(e,["data"]))&&function e(t,a,r,i){if(a===r)return!0;var n=new Set;return t.selections.every(function(t){if(n.has(t)||(n.add(t),!d.shouldInclude(t,i.variables)||S(t)))return!0;if(d.isField(t)){var p=d.resultKeyNameFromField(t),o=a&&a[p],s=r&&r[p],l=t.selectionSet;if(!l)return _(o,s);var u=Array.isArray(o),c=Array.isArray(s);if(u!==c)return!1;if(u&&c){var m=o.length;if(s.length!==m)return!1;for(var f=0;f<m;++f)if(!e(l,o[f],s[f],i))return!1;return!0}return e(l,o,s,i)}var h=d.getFragmentFromSelection(t,i.fragmentMap);if(h)return!!S(h)||e(h.selectionSet,a,r,i)})}(d.getMainDefinition(c).selectionSet,n,o,{fragmentMap:d.createFragmentMap(d.getFragmentDefinitions(c)),variables:r}))):!s.equal(this.last.result,e))||t&&!s.equal(this.last.variables,t)},a.prototype.getLast=function(e,t){var a=this.last;if(a&&a[e]&&(!t||s.equal(a.variables,this.variables)))return a[e]},a.prototype.getLastResult=function(e){return this.getLast("result",e)},a.prototype.getLastError=function(e){return this.getLast("error",e)},a.prototype.resetLastResults=function(){delete this.last,this.isTornDown=!1},a.prototype.resetQueryStoreErrors=function(){this.queryManager.resetErrors(this.queryId)},a.prototype.refetch=function(e){var a,r={pollInterval:0};if("no-cache"===this.options.fetchPolicy?r.fetchPolicy="no-cache":r.fetchPolicy="network-only",!1!==globalThis.__DEV__&&e&&D.call(e,"variables")){var p=d.getQueryDefinition(this.query),o=p.variableDefinitions;o&&o.some(function(e){return"variables"===e.variable.name.value})||!1===globalThis.__DEV__||n.invariant.warn(21,e,(null==(a=p.name)?void 0:a.value)||p)}return e&&!s.equal(this.options.variables,e)&&(r.variables=this.options.variables=i.__assign(i.__assign({},this.options.variables),e)),this.queryInfo.resetLastWrite(),this.reobserve(r,t.NetworkStatus.refetch)},a.prototype.fetchMore=function(e){var a=this,r=i.__assign(i.__assign({},e.query?e:i.__assign(i.__assign(i.__assign(i.__assign({},this.options),{query:this.options.query}),e),{variables:i.__assign(i.__assign({},this.options.variables),e.variables)})),{fetchPolicy:"no-cache"});r.query=this.transformDocument(r.query);var p=this.queryManager.generateQueryId();this.lastQuery=e.query?this.transformDocument(this.options.query):r.query;var o=this.queryInfo,s=o.networkStatus;o.networkStatus=t.NetworkStatus.fetchMore,r.notifyOnNetworkStatusChange&&this.observe();var d=new Set,l=null==e?void 0:e.updateQuery,u="no-cache"!==this.options.fetchPolicy;return u||n.invariant(l,22),this.queryManager.fetchQuery(p,r,t.NetworkStatus.fetchMore).then(function(n){if(a.queryManager.removeQuery(p),o.networkStatus===t.NetworkStatus.fetchMore&&(o.networkStatus=s),u)a.queryManager.cache.batch({update:function(t){var i=e.updateQuery;i?t.updateQuery({query:a.query,variables:a.variables,returnPartialData:!0,optimistic:!1},function(e){return i(e,{fetchMoreResult:n.data,variables:r.variables})}):t.writeQuery({query:r.query,variables:r.variables,data:n.data})},onWatchUpdated:function(e){d.add(e.query)}});else{var c=a.getLast("result"),m=l(c.data,{fetchMoreResult:n.data,variables:r.variables});a.reportResult(i.__assign(i.__assign({},c),{networkStatus:s,loading:N(s),data:m}),a.variables)}return a.maskResult(n)}).finally(function(){u&&!d.has(a.query)&&a.reobserveCacheFirst()})},a.prototype.subscribeToMore=function(e){var t=this,a=this.queryManager.startGraphQLSubscription({query:e.document,variables:e.variables,context:e.context}).subscribe({next:function(a){var r=e.updateQuery;r&&t.updateQuery(function(e,t){return r(e,i.__assign({subscriptionData:a},t))})},error:function(t){e.onError?e.onError(t):!1!==globalThis.__DEV__&&n.invariant.error(23,t)}});return this.subscriptions.add(a),function(){t.subscriptions.delete(a)&&a.unsubscribe()}},a.prototype.setOptions=function(e){return this.reobserve(e)},a.prototype.silentSetOptions=function(e){var t=d.compact(this.options,e||{});I(this.options,t)},a.prototype.setVariables=function(e){return s.equal(this.variables,e)?this.observers.size?this.result():Promise.resolve():(this.options.variables=e,this.observers.size)?this.reobserve({fetchPolicy:this.options.initialFetchPolicy,variables:e},t.NetworkStatus.setVariables):Promise.resolve()},a.prototype.updateQuery=function(e){var t=this.queryManager,a=t.cache.diff({query:this.options.query,variables:this.variables,returnPartialData:!0,optimistic:!1}),r=a.result,i=a.complete,n=e(r,{variables:this.variables,complete:!!i,previousData:r});n&&(t.cache.writeQuery({query:this.options.query,data:n,variables:this.variables}),t.broadcastQueries())},a.prototype.startPolling=function(e){this.options.pollInterval=e,this.updatePolling()},a.prototype.stopPolling=function(){this.options.pollInterval=0,this.updatePolling()},a.prototype.applyNextFetchPolicy=function(e,t){if(t.nextFetchPolicy){var a=t.fetchPolicy,r=void 0===a?"cache-first":a,i=t.initialFetchPolicy,n=void 0===i?r:i;"standby"===r||("function"==typeof t.nextFetchPolicy?t.fetchPolicy=t.nextFetchPolicy(r,{reason:e,options:t,observable:this,initialFetchPolicy:n}):"variables-changed"===e?t.fetchPolicy=n:t.fetchPolicy=t.nextFetchPolicy)}return t.fetchPolicy},a.prototype.fetch=function(e,t,a){var r=this.queryManager.getOrCreateQuery(this.queryId);return r.setObservableQuery(this),this.queryManager.fetchConcastWithInfo(r,e,t,a)},a.prototype.updatePolling=function(){var e=this;if(!this.queryManager.ssrMode){var a=this.pollingInfo,r=this.options.pollInterval;if(!r||!this.hasObservers()){a&&(clearTimeout(a.timeout),delete this.pollingInfo);return}if(!a||a.interval!==r){n.invariant(r,24),(a||(this.pollingInfo={})).interval=r;var i=function(){var a,r;e.pollingInfo&&(N(e.queryInfo.networkStatus)||(null==(r=(a=e.options).skipPollAttempt)?void 0:r.call(a))?p():e.reobserve({fetchPolicy:"no-cache"===e.options.initialFetchPolicy?"no-cache":"network-only"},t.NetworkStatus.poll).then(p,p))},p=function(){var t=e.pollingInfo;t&&(clearTimeout(t.timeout),t.timeout=setTimeout(i,t.interval))};p()}}},a.prototype.updateLastResult=function(e,t){void 0===t&&(t=this.variables);var a=this.getLastError();return a&&this.last&&!s.equal(t,this.last.variables)&&(a=void 0),this.last=i.__assign({result:this.queryManager.assumeImmutableResults?e:d.cloneDeep(e),variables:t},a?{error:a}:null)},a.prototype.reobserveAsConcast=function(e,a){var r=this;this.isTornDown=!1;var n=a===t.NetworkStatus.refetch||a===t.NetworkStatus.fetchMore||a===t.NetworkStatus.poll,p=this.options.variables,o=this.options.fetchPolicy,l=d.compact(this.options,e||{}),c=n?l:I(this.options,l),m=this.transformDocument(c.query);this.lastQuery=m,!n&&(this.updatePolling(),e&&e.variables&&!s.equal(e.variables,p)&&"standby"!==c.fetchPolicy&&(c.fetchPolicy===o||"function"==typeof c.nextFetchPolicy)&&(this.applyNextFetchPolicy("variables-changed",c),void 0===a&&(a=t.NetworkStatus.setVariables))),this.waitForOwnResult&&(this.waitForOwnResult=C(c.fetchPolicy));var f=function(){r.concast===y&&(r.waitForOwnResult=!1)},h=c.variables&&i.__assign({},c.variables),v=this.fetch(c,a,m),y=v.concast,g=v.fromLink,_={next:function(e){s.equal(r.variables,h)&&(f(),r.reportResult(e,h))},error:function(e){s.equal(r.variables,h)&&(u.isApolloError(e)||(e=new u.ApolloError({networkError:e})),f(),r.reportError(e,h))}};return n||!g&&this.concast||(this.concast&&this.observer&&this.concast.removeObserver(this.observer),this.concast=y,this.observer=_),y.addObserver(_),y},a.prototype.reobserve=function(e,t){return d.preventUnhandledRejection(this.reobserveAsConcast(e,t).promise.then(this.maskResult))},a.prototype.resubscribeAfterError=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var a=this.last;this.resetLastResults();var r=this.subscribe.apply(this,e);return this.last=a,r},a.prototype.observe=function(){this.reportResult(this.getCurrentFullResult(!1),this.variables)},a.prototype.reportResult=function(e,t){var a=this.getLastError(),r=this.isDifferentFromLastResult(e,t);(a||!e.partial||this.options.returnPartialData)&&this.updateLastResult(e,t),(a||r)&&d.iterateObserversSafely(this.observers,"next",this.maskResult(e))},a.prototype.reportError=function(e,a){var r=i.__assign(i.__assign({},this.getLastResult()),{error:e,errors:e.graphQLErrors,networkStatus:t.NetworkStatus.error,loading:!1});this.updateLastResult(r,a),d.iterateObserversSafely(this.observers,"error",this.last.error=e)},a.prototype.hasObservers=function(){return this.observers.size>0},a.prototype.tearDownQuery=function(){this.isTornDown||(this.concast&&this.observer&&(this.concast.removeObserver(this.observer),delete this.concast,delete this.observer),this.stopPolling(),this.subscriptions.forEach(function(e){return e.unsubscribe()}),this.subscriptions.clear(),this.queryManager.stopQuery(this.queryId),this.observers.clear(),this.isTornDown=!0)},a.prototype.transformDocument=function(e){return this.queryManager.transform(e)},a.prototype.maskResult=function(e){return e&&"data"in e?i.__assign(i.__assign({},e),{data:this.queryManager.maskOperation({document:this.query,data:e.data,fetchPolicy:this.options.fetchPolicy,id:this.queryId})}):e},a.prototype.resetNotifications=function(){this.cancelNotifyTimeout(),this.dirty=!1},a.prototype.cancelNotifyTimeout=function(){this.notifyTimeout&&(clearTimeout(this.notifyTimeout),this.notifyTimeout=void 0)},a.prototype.scheduleNotify=function(){var e=this;!this.dirty&&(this.dirty=!0,this.notifyTimeout||(this.notifyTimeout=setTimeout(function(){return e.notify()},0)))},a.prototype.notify=function(){this.cancelNotifyTimeout(),this.dirty&&("cache-only"==this.options.fetchPolicy||"cache-and-network"==this.options.fetchPolicy||!N(this.queryInfo.networkStatus))&&(this.queryInfo.getDiff().fromOptimisticTransaction?this.observe():this.reobserveCacheFirst()),this.dirty=!1},a.prototype.reobserveCacheFirst=function(){var e=this.options,t=e.fetchPolicy,a=e.nextFetchPolicy;return"cache-and-network"===t||"network-only"===t?this.reobserve({fetchPolicy:"cache-first",nextFetchPolicy:function(e,r){return(this.nextFetchPolicy=a,"function"==typeof this.nextFetchPolicy)?this.nextFetchPolicy(e,r):t}}):this.reobserve()},a.inactiveOnCreation=new c.Slot,a}(d.Observable);function k(e){!1!==globalThis.__DEV__&&n.invariant.error(25,e.message,e.stack)}function x(e){!1!==globalThis.__DEV__&&e&&!1!==globalThis.__DEV__&&n.invariant.debug(26,e)}function C(e){return"network-only"===e||"no-cache"===e||"standby"===e}d.fixObservableSubclass(A);var R=new(d.canUseWeakMap?WeakMap:Map);function V(e,t){var a=e[t];"function"==typeof a&&(e[t]=function(){return R.set(e,(R.get(e)+1)%1e15),a.apply(this,arguments)})}var F=function(){function e(e,t){void 0===t&&(t=e.generateQueryId()),this.queryId=t,this.document=null,this.lastRequestId=1,this.stopped=!1,this.observableQuery=null;var a=this.cache=e.cache;R.has(a)||(R.set(a,0),V(a,"evict"),V(a,"modify"),V(a,"reset"))}return e.prototype.init=function(e){var a=e.networkStatus||t.NetworkStatus.loading;return this.variables&&this.networkStatus!==t.NetworkStatus.loading&&!s.equal(this.variables,e.variables)&&(a=t.NetworkStatus.setVariables),s.equal(e.variables,this.variables)||(this.lastDiff=void 0,this.cancel()),Object.assign(this,{document:e.document,variables:e.variables,networkError:null,graphQLErrors:this.graphQLErrors||[],networkStatus:a}),e.observableQuery&&this.setObservableQuery(e.observableQuery),e.lastRequestId&&(this.lastRequestId=e.lastRequestId),this},e.prototype.resetDiff=function(){this.lastDiff=void 0},e.prototype.getDiff=function(){var e=this.getDiffOptions();if(this.lastDiff&&s.equal(e,this.lastDiff.options))return this.lastDiff.diff;this.updateWatch(this.variables);var t=this.observableQuery;if(t&&"no-cache"===t.options.fetchPolicy)return{complete:!1};var a=this.cache.diff(e);return this.updateLastDiff(a,e),a},e.prototype.updateLastDiff=function(e,t){this.lastDiff=e?{diff:e,options:t||this.getDiffOptions()}:void 0},e.prototype.getDiffOptions=function(e){var t;return void 0===e&&(e=this.variables),{query:this.document,variables:e,returnPartialData:!0,optimistic:!0,canonizeResults:null==(t=this.observableQuery)?void 0:t.options.canonizeResults}},e.prototype.setDiff=function(e){var t,a,r=this.lastDiff&&this.lastDiff.diff;!(e&&!e.complete&&(null==(t=this.observableQuery)?void 0:t.getLastError()))&&(this.updateLastDiff(e),s.equal(r&&r.result,e&&e.result)||null==(a=this.observableQuery)||a.scheduleNotify())},e.prototype.setObservableQuery=function(e){e!==this.observableQuery&&(this.observableQuery=e,e&&(e.queryInfo=this))},e.prototype.stop=function(){var e;if(!this.stopped){this.stopped=!0,null==(e=this.observableQuery)||e.resetNotifications(),this.cancel();var t=this.observableQuery;t&&t.stopPolling()}},e.prototype.cancel=function(){var e;null==(e=this.cancelWatch)||e.call(this),this.cancelWatch=void 0},e.prototype.updateWatch=function(e){var t=this;void 0===e&&(e=this.variables);var a=this.observableQuery;if(!a||"no-cache"!==a.options.fetchPolicy){var r=i.__assign(i.__assign({},this.getDiffOptions(e)),{watcher:this,callback:function(e){return t.setDiff(e)}});this.lastWatch&&s.equal(r,this.lastWatch)||(this.cancel(),this.cancelWatch=this.cache.watch(this.lastWatch=r))}},e.prototype.resetLastWrite=function(){this.lastWrite=void 0},e.prototype.shouldWrite=function(e,t){var a=this.lastWrite;return!(a&&a.dmCount===R.get(this.cache)&&s.equal(t,a.variables)&&s.equal(e.data,a.result.data))},e.prototype.markResult=function(e,t,a,r){var i,n=this,p=new d.DeepMerger,o=d.isNonEmptyArray(e.errors)?e.errors.slice(0):[];if(null==(i=this.observableQuery)||i.resetNotifications(),"incremental"in e&&d.isNonEmptyArray(e.incremental)){var l=d.mergeIncrementalData(this.getDiff().result,e);e.data=l}else if("hasNext"in e&&e.hasNext){var u=this.getDiff();e.data=p.merge(u.result,e.data)}this.graphQLErrors=o,"no-cache"===a.fetchPolicy?this.updateLastDiff({result:e.data,complete:!0},this.getDiffOptions(a.variables)):0!==r&&($(e,a.errorPolicy)?this.cache.performTransaction(function(i){if(n.shouldWrite(e,a.variables))i.writeQuery({query:t,data:e.data,variables:a.variables,overwrite:1===r}),n.lastWrite={result:e,variables:a.variables,dmCount:R.get(n.cache)};else if(n.lastDiff&&n.lastDiff.diff.complete){e.data=n.lastDiff.diff.result;return}var p=n.getDiffOptions(a.variables),o=i.diff(p);!n.stopped&&s.equal(n.variables,a.variables)&&n.updateWatch(a.variables),n.updateLastDiff(o,p),o.complete&&(e.data=o.result)}):this.lastWrite=void 0)},e.prototype.markReady=function(){return this.networkError=null,this.networkStatus=t.NetworkStatus.ready},e.prototype.markError=function(e){var a;return this.networkStatus=t.NetworkStatus.error,this.lastWrite=void 0,null==(a=this.observableQuery)||a.resetNotifications(),e.graphQLErrors&&(this.graphQLErrors=e.graphQLErrors),e.networkError&&(this.networkError=e.networkError),e},e}();function $(e,t){void 0===t&&(t="none");var a="ignore"===t||"all"===t,r=!d.graphQLResultHasError(e);return!r&&a&&e.data&&(r=!0),r}var P=Object.prototype.hasOwnProperty,L=Object.create(null),j=function(){function e(e){var t=this;this.clientAwareness={},this.queries=new Map,this.fetchCancelFns=new Map,this.transformCache=new d.AutoCleanedWeakCache(d.cacheSizes["queryManager.getDocumentInfo"]||2e3),this.queryIdCounter=1,this.requestIdCounter=1,this.mutationIdCounter=1,this.inFlightLinkObservables=new m.Trie(!1),this.noCacheWarningsByQueryId=new Set;var a=new d.DocumentTransform(function(e){return t.cache.transformDocument(e)},{cache:!1});this.cache=e.cache,this.link=e.link,this.defaultOptions=e.defaultOptions,this.queryDeduplication=e.queryDeduplication,this.clientAwareness=e.clientAwareness,this.localState=e.localState,this.ssrMode=e.ssrMode,this.assumeImmutableResults=e.assumeImmutableResults,this.dataMasking=e.dataMasking;var r=e.documentTransform;this.documentTransform=r?a.concat(r).concat(a):a,this.defaultContext=e.defaultContext||Object.create(null),(this.onBroadcast=e.onBroadcast)&&(this.mutationStore=Object.create(null))}return e.prototype.stop=function(){var e=this;this.queries.forEach(function(t,a){e.stopQueryNoBroadcast(a)}),this.cancelPendingFetches(n.newInvariantError(27))},e.prototype.cancelPendingFetches=function(e){this.fetchCancelFns.forEach(function(t){return t(e)}),this.fetchCancelFns.clear()},e.prototype.mutate=function(e){return i.__awaiter(this,arguments,void 0,function(e){var t,a,r,p,o,s,l,c=e.mutation,m=e.variables,f=e.optimisticResponse,h=e.updateQueries,v=e.refetchQueries,y=void 0===v?[]:v,g=e.awaitRefetchQueries,_=void 0!==g&&g,b=e.update,w=e.onQueryUpdated,E=e.fetchPolicy,T=void 0===E?(null==(s=this.defaultOptions.mutate)?void 0:s.fetchPolicy)||"network-only":E,N=e.errorPolicy,S=void 0===N?(null==(l=this.defaultOptions.mutate)?void 0:l.errorPolicy)||"none":N,O=e.keepRootFields,I=e.context;return i.__generator(this,function(e){switch(e.label){case 0:if(n.invariant(c,28),n.invariant("network-only"===T||"no-cache"===T,29),t=this.generateMutationId(),c=this.cache.transformForLink(this.transform(c)),a=this.getDocumentInfo(c).hasClientExports,m=this.getVariables(c,m),!a)return[3,2];return[4,this.localState.addExportedVariables(c,m,I)];case 1:m=e.sent(),e.label=2;case 2:return r=this.mutationStore&&(this.mutationStore[t]={mutation:c,variables:m,loading:!0,error:null}),p=f&&this.markMutationOptimistic(f,{mutationId:t,document:c,variables:m,fetchPolicy:T,errorPolicy:S,context:I,updateQueries:h,update:b,keepRootFields:O}),this.broadcastQueries(),o=this,[2,new Promise(function(e,a){return d.asyncMap(o.getObservableFromLink(c,i.__assign(i.__assign({},I),{optimisticResponse:p?f:void 0}),m,{},!1),function(e){if(d.graphQLResultHasError(e)&&"none"===S)throw new u.ApolloError({graphQLErrors:d.getGraphQLErrorsFromResult(e)});r&&(r.loading=!1,r.error=null);var a=i.__assign({},e);return"function"==typeof y&&(y=y(a)),"ignore"===S&&d.graphQLResultHasError(a)&&delete a.errors,o.markMutationResult({mutationId:t,result:a,document:c,variables:m,fetchPolicy:T,errorPolicy:S,context:I,update:b,updateQueries:h,awaitRefetchQueries:_,refetchQueries:y,removeOptimistic:p?t:void 0,onQueryUpdated:w,keepRootFields:O})}).subscribe({next:function(a){o.broadcastQueries(),"hasNext"in a&&!1!==a.hasNext||e(i.__assign(i.__assign({},a),{data:o.maskOperation({document:c,data:a.data,fetchPolicy:T,id:t})}))},error:function(e){r&&(r.loading=!1,r.error=e),p&&o.cache.removeOptimistic(t),o.broadcastQueries(),a(e instanceof u.ApolloError?e:new u.ApolloError({networkError:e}))}})})]}})})},e.prototype.markMutationResult=function(e,t){var a=this;void 0===t&&(t=this.cache);var r=e.result,n=[],p="no-cache"===e.fetchPolicy;if(!p&&$(r,e.errorPolicy)){if(d.isExecutionPatchIncrementalResult(r)||n.push({result:r.data,dataId:"ROOT_MUTATION",query:e.document,variables:e.variables}),d.isExecutionPatchIncrementalResult(r)&&d.isNonEmptyArray(r.incremental)){var o,s,l,u,c,m=t.diff({id:"ROOT_MUTATION",query:this.getDocumentInfo(e.document).asQuery,variables:e.variables,optimistic:!1,returnPartialData:!0}),f=void 0;m.result&&(o=m.result,s=r,u=o,c=new T,"incremental"in s&&Array.isArray(l=s.incremental)&&l.length>0&&s.incremental.forEach(function(e){for(var t=e.data,a=e.path,r=a.length-1;r>=0;--r){var i=a[r],n=isNaN(+i)?{}:[];n[i]=t,t=n}u=c.merge(u,t)}),f=u),void 0!==f&&(r.data=f,n.push({result:f,dataId:"ROOT_MUTATION",query:e.document,variables:e.variables}))}var h=e.updateQueries;h&&this.queries.forEach(function(e,i){var p=e.observableQuery,o=p&&p.queryName;if(o&&P.call(h,o)){var s=h[o],l=a.queries.get(i),u=l.document,c=l.variables,m=t.diff({query:u,variables:c,returnPartialData:!0,optimistic:!1}),f=m.result;if(m.complete&&f){var v=s(f,{mutationResult:r,queryName:u&&d.getOperationName(u)||void 0,queryVariables:c});v&&n.push({result:v,dataId:"ROOT_QUERY",query:u,variables:c})}}})}if(n.length>0||(e.refetchQueries||"").length>0||e.update||e.onQueryUpdated||e.removeOptimistic){var v=[];if(this.refetchQueries({updateCache:function(t){p||n.forEach(function(e){return t.write(e)});var o=e.update,s=!d.isExecutionPatchResult(r)||d.isExecutionPatchIncrementalResult(r)&&!r.hasNext;if(o){if(!p){var l=t.diff({id:"ROOT_MUTATION",query:a.getDocumentInfo(e.document).asQuery,variables:e.variables,optimistic:!1,returnPartialData:!0});l.complete&&("incremental"in(r=i.__assign(i.__assign({},r),{data:l.result}))&&delete r.incremental,"hasNext"in r&&delete r.hasNext)}s&&o(t,r,{context:e.context,variables:e.variables})}p||e.keepRootFields||!s||t.modify({id:"ROOT_MUTATION",fields:function(e,t){var a=t.fieldName,r=t.DELETE;return"__typename"===a?e:r}})},include:e.refetchQueries,optimistic:!1,removeOptimistic:e.removeOptimistic,onQueryUpdated:e.onQueryUpdated||null}).forEach(function(e){return v.push(e)}),e.awaitRefetchQueries||e.onQueryUpdated)return Promise.all(v).then(function(){return r})}return Promise.resolve(r)},e.prototype.markMutationOptimistic=function(e,t){var a=this,r="function"==typeof e?e(t.variables,{IGNORE:L}):e;return r!==L&&(this.cache.recordOptimisticTransaction(function(e){try{a.markMutationResult(i.__assign(i.__assign({},t),{result:{data:r}}),e)}catch(e){!1!==globalThis.__DEV__&&n.invariant.error(e)}},t.mutationId),!0)},e.prototype.fetchQuery=function(e,t,a){return this.fetchConcastWithInfo(this.getOrCreateQuery(e),t,a).concast.promise},e.prototype.getQueryStore=function(){var e=Object.create(null);return this.queries.forEach(function(t,a){e[a]={variables:t.variables,networkStatus:t.networkStatus,networkError:t.networkError,graphQLErrors:t.graphQLErrors}}),e},e.prototype.resetErrors=function(e){var t=this.queries.get(e);t&&(t.networkError=void 0,t.graphQLErrors=[])},e.prototype.transform=function(e){return this.documentTransform.transformDocument(e)},e.prototype.getDocumentInfo=function(e){var t=this.transformCache;if(!t.has(e)){var a={hasClientExports:d.hasClientExports(e),hasForcedResolvers:this.localState.shouldForceResolvers(e),hasNonreactiveDirective:d.hasDirectives(["nonreactive"],e),nonReactiveQuery:d.addNonReactiveToNamedFragments(e),clientQuery:this.localState.clientQuery(e),serverQuery:d.removeDirectivesFromDocument([{name:"client",remove:!0},{name:"connection"},{name:"nonreactive"},{name:"unmask"}],e),defaultVars:d.getDefaultValues(d.getOperationDefinition(e)),asQuery:i.__assign(i.__assign({},e),{definitions:e.definitions.map(function(e){return"OperationDefinition"===e.kind&&"query"!==e.operation?i.__assign(i.__assign({},e),{operation:"query"}):e})})};t.set(e,a)}return t.get(e)},e.prototype.getVariables=function(e,t){return i.__assign(i.__assign({},this.getDocumentInfo(e).defaultVars),t)},e.prototype.watchQuery=function(e){var t=this.transform(e.query);void 0===(e=i.__assign(i.__assign({},e),{variables:this.getVariables(t,e.variables)})).notifyOnNetworkStatusChange&&(e.notifyOnNetworkStatusChange=!1);var a=new F(this),r=new A({queryManager:this,queryInfo:a,options:e});return r.lastQuery=t,A.inactiveOnCreation.getValue()||this.queries.set(r.queryId,a),a.init({document:t,observableQuery:r,variables:r.variables}),r},e.prototype.query=function(e,t){var a=this;void 0===t&&(t=this.generateQueryId()),n.invariant(e.query,30),n.invariant("Document"===e.query.kind,31),n.invariant(!e.returnPartialData,32),n.invariant(!e.pollInterval,33);var r=this.transform(e.query);return this.fetchQuery(t,i.__assign(i.__assign({},e),{query:r})).then(function(n){return n&&i.__assign(i.__assign({},n),{data:a.maskOperation({document:r,data:n.data,fetchPolicy:e.fetchPolicy,id:t})})}).finally(function(){return a.stopQuery(t)})},e.prototype.generateQueryId=function(){return String(this.queryIdCounter++)},e.prototype.generateRequestId=function(){return this.requestIdCounter++},e.prototype.generateMutationId=function(){return String(this.mutationIdCounter++)},e.prototype.stopQueryInStore=function(e){this.stopQueryInStoreNoBroadcast(e),this.broadcastQueries()},e.prototype.stopQueryInStoreNoBroadcast=function(e){var t=this.queries.get(e);t&&t.stop()},e.prototype.clearStore=function(e){return void 0===e&&(e={discardWatches:!0}),this.cancelPendingFetches(n.newInvariantError(34)),this.queries.forEach(function(e){e.observableQuery?e.networkStatus=t.NetworkStatus.loading:e.stop()}),this.mutationStore&&(this.mutationStore=Object.create(null)),this.cache.reset(e)},e.prototype.getObservableQueries=function(e){var t=this;void 0===e&&(e="active");var a=new Map,r=new Map,p=new Map,o=new Set;return Array.isArray(e)&&e.forEach(function(e){if("string"==typeof e)r.set(e,e),p.set(e,!1);else if(d.isDocumentNode(e)){var a=d.print(t.transform(e));r.set(a,d.getOperationName(e)),p.set(a,!1)}else d.isNonNullObject(e)&&e.query&&o.add(e)}),this.queries.forEach(function(t,r){var i=t.observableQuery,n=t.document;if(i){if("all"===e)return void a.set(r,i);var o=i.queryName;if("standby"===i.options.fetchPolicy||"active"===e&&!i.hasObservers())return;("active"===e||o&&p.has(o)||n&&p.has(d.print(n)))&&(a.set(r,i),o&&p.set(o,!0),n&&p.set(d.print(n),!0))}}),o.size&&o.forEach(function(e){var r=d.makeUniqueId("legacyOneTimeQuery"),p=t.getOrCreateQuery(r).init({document:e.query,variables:e.variables}),o=new A({queryManager:t,queryInfo:p,options:i.__assign(i.__assign({},e),{fetchPolicy:"network-only"})});n.invariant(o.queryId===r),p.setObservableQuery(o),a.set(r,o)}),!1!==globalThis.__DEV__&&p.size&&p.forEach(function(e,t){if(!e){var a=r.get(t);a?!1!==globalThis.__DEV__&&n.invariant.warn(35,a):!1!==globalThis.__DEV__&&n.invariant.warn(36)}}),a},e.prototype.reFetchObservableQueries=function(e){var t=this;void 0===e&&(e=!1);var a=[];return this.getObservableQueries(e?"all":"active").forEach(function(r,i){var n=r.options.fetchPolicy;r.resetLastResults(),(e||"standby"!==n&&"cache-only"!==n)&&a.push(r.refetch()),(t.queries.get(i)||r.queryInfo).setDiff(null)}),this.broadcastQueries(),Promise.all(a)},e.prototype.startGraphQLSubscription=function(e){var t=this,a=e.query,r=e.variables,i=e.fetchPolicy,n=e.errorPolicy,p=void 0===n?"none":n,o=e.context,s=void 0===o?{}:o,l=e.extensions,c=void 0===l?{}:l;a=this.transform(a),r=this.getVariables(a,r);var m=function(e){return t.getObservableFromLink(a,s,e,c).map(function(r){"no-cache"!==i&&($(r,p)&&t.cache.write({query:a,result:r.data,dataId:"ROOT_SUBSCRIPTION",variables:e}),t.broadcastQueries());var n=d.graphQLResultHasError(r),o=u.graphQLResultHasProtocolErrors(r);if(n||o){var s={};if(n&&(s.graphQLErrors=r.errors),o&&(s.protocolErrors=r.extensions[u.PROTOCOL_ERRORS_SYMBOL]),"none"===p||o)throw new u.ApolloError(s)}return"ignore"===p&&delete r.errors,r})};if(this.getDocumentInfo(a).hasClientExports){var f=this.localState.addExportedVariables(a,r,s).then(m);return new d.Observable(function(e){var t=null;return f.then(function(a){return t=a.subscribe(e)},e.error),function(){return t&&t.unsubscribe()}})}return m(r)},e.prototype.stopQuery=function(e){this.stopQueryNoBroadcast(e),this.broadcastQueries()},e.prototype.stopQueryNoBroadcast=function(e){this.stopQueryInStoreNoBroadcast(e),this.removeQuery(e)},e.prototype.removeQuery=function(e){var t;this.fetchCancelFns.delete(e),this.queries.has(e)&&(null==(t=this.queries.get(e))||t.stop(),this.queries.delete(e))},e.prototype.broadcastQueries=function(){this.onBroadcast&&this.onBroadcast(),this.queries.forEach(function(e){var t;return null==(t=e.observableQuery)?void 0:t.notify()})},e.prototype.getLocalState=function(){return this.localState},e.prototype.getObservableFromLink=function(e,t,a,r,n){var o,s,u=this;void 0===n&&(n=null!=(o=null==t?void 0:t.queryDeduplication)?o:this.queryDeduplication);var c=this.getDocumentInfo(e),m=c.serverQuery,f=c.clientQuery;if(m){var h=this.inFlightLinkObservables,v=this.link,y={query:m,variables:a,operationName:d.getOperationName(m)||void 0,context:this.prepareContext(i.__assign(i.__assign({},t),{forceFetch:!n})),extensions:r};if(t=y.context,n){var g=d.print(m),_=l.canonicalStringify(a),b=h.lookup(g,_);if(!(s=b.observable)){var w=new d.Concast([p.execute(v,y)]);s=b.observable=w,w.beforeNext(function e(t,a){"next"===t&&"hasNext"in a&&a.hasNext?w.beforeNext(e):h.remove(g,_)})}}else s=new d.Concast([p.execute(v,y)])}else s=new d.Concast([d.Observable.of({data:{}})]),t=this.prepareContext(t);return f&&(s=d.asyncMap(s,function(e){return u.localState.runResolvers({document:f,remoteResult:e,context:t,variables:a})})),s},e.prototype.getResultsFromLink=function(e,a,r){var i=e.lastRequestId=this.generateRequestId(),n=this.cache.transformForLink(r.query);return d.asyncMap(this.getObservableFromLink(n,r.context,r.variables),function(p){var o=d.getGraphQLErrorsFromResult(p),s=o.length>0,l=r.errorPolicy;if(i>=e.lastRequestId){if(s&&"none"===l)throw e.markError(new u.ApolloError({graphQLErrors:o}));e.markResult(p,n,r,a),e.markReady()}var c={data:p.data,loading:!1,networkStatus:t.NetworkStatus.ready};return s&&"none"===l&&(c.data=void 0),s&&"ignore"!==l&&(c.errors=o,c.networkStatus=t.NetworkStatus.error),c},function(t){var a=u.isApolloError(t)?t:new u.ApolloError({networkError:t});throw i>=e.lastRequestId&&e.markError(a),a})},e.prototype.fetchConcastWithInfo=function(e,a,r,i){var n,p,o=this;void 0===r&&(r=t.NetworkStatus.loading),void 0===i&&(i=a.query);var s=this.getVariables(i,a.variables),l=this.defaultOptions.watchQuery,u=a.fetchPolicy,c=void 0===u?l&&l.fetchPolicy||"cache-first":u,m=a.errorPolicy,f=void 0===m?l&&l.errorPolicy||"none":m,h=a.returnPartialData,v=a.notifyOnNetworkStatusChange,y=a.context,g=Object.assign({},a,{query:i,variables:s,fetchPolicy:c,errorPolicy:f,returnPartialData:void 0!==h&&h,notifyOnNetworkStatusChange:void 0!==v&&v,context:void 0===y?{}:y}),_=function(t){g.variables=t;var i=o.fetchQueryByPolicy(e,g,r);return"standby"!==g.fetchPolicy&&i.sources.length>0&&e.observableQuery&&e.observableQuery.applyNextFetchPolicy("after-fetch",a),i},b=function(){return o.fetchCancelFns.delete(e.queryId)};if(this.fetchCancelFns.set(e.queryId,function(e){b(),setTimeout(function(){return n.cancel(e)})}),this.getDocumentInfo(g.query).hasClientExports)n=new d.Concast(this.localState.addExportedVariables(g.query,g.variables,g.context).then(_).then(function(e){return e.sources})),p=!0;else{var w=_(g.variables);p=w.fromLink,n=new d.Concast(w.sources)}return n.promise.then(b,b),{concast:n,fromLink:p}},e.prototype.refetchQueries=function(e){var t=this,a=e.updateCache,r=e.include,i=e.optimistic,n=void 0!==i&&i,p=e.removeOptimistic,o=void 0===p?n?d.makeUniqueId("refetchQueries"):void 0:p,s=e.onQueryUpdated,l=new Map;r&&this.getObservableQueries(r).forEach(function(e,a){l.set(a,{oq:e,lastDiff:(t.queries.get(a)||e.queryInfo).getDiff()})});var u=new Map;return a&&this.cache.batch({update:a,optimistic:n&&o||!1,removeOptimistic:o,onWatchUpdated:function(e,t,a){var r=e.watcher instanceof F&&e.watcher.observableQuery;if(r){if(s){l.delete(r.queryId);var i=s(r,t,a);return!0===i&&(i=r.refetch()),!1!==i&&u.set(r,i),i}null!==s&&l.set(r.queryId,{oq:r,lastDiff:a,diff:t})}}}),l.size&&l.forEach(function(e,a){var r,i=e.oq,n=e.lastDiff,p=e.diff;s&&(p||(p=t.cache.diff(i.queryInfo.getDiffOptions())),r=s(i,p,n)),s&&!0!==r||(r=i.refetch()),!1!==r&&u.set(i,r),a.indexOf("legacyOneTimeQuery")>=0&&t.stopQueryNoBroadcast(a)}),o&&this.cache.removeOptimistic(o),u},e.prototype.maskOperation=function(e){var t,a,r,i=e.document,p=e.data;if(!1!==globalThis.__DEV__){var o=e.fetchPolicy,s=e.id,l=null==(t=d.getOperationDefinition(i))?void 0:t.operation,u=(null!=(a=null==l?void 0:l[0])?a:"o")+s;!this.dataMasking||"no-cache"!==o||d.isFullyUnmaskedOperation(i)||this.noCacheWarningsByQueryId.has(u)||(this.noCacheWarningsByQueryId.add(u),!1!==globalThis.__DEV__&&n.invariant.warn(37,null!=(r=d.getOperationName(i))?r:"Unnamed ".concat(null!=l?l:"operation")))}return this.dataMasking?f.maskOperation(p,i,this.cache):p},e.prototype.maskFragment=function(e){var t=e.data,a=e.fragment,r=e.fragmentName;return this.dataMasking?f.maskFragment(t,a,this.cache,r):t},e.prototype.fetchQueryByPolicy=function(e,a,r){var n=this,p=a.query,o=a.variables,l=a.fetchPolicy,u=a.refetchWritePolicy,c=a.errorPolicy,m=a.returnPartialData,f=a.context,h=a.notifyOnNetworkStatusChange,v=e.networkStatus;e.init({document:p,variables:o,networkStatus:r});var y=function(){return e.getDiff()},g=function(a,r){void 0===r&&(r=e.networkStatus||t.NetworkStatus.loading);var l=a.result;!1===globalThis.__DEV__||m||s.equal(l,{})||x(a.missing);var u=function(e){return d.Observable.of(i.__assign({data:e,loading:N(r),networkStatus:r},a.complete?null:{partial:!0}))};return l&&n.getDocumentInfo(p).hasForcedResolvers?n.localState.runResolvers({document:p,remoteResult:{data:l},context:f,variables:o,onlyRunForcedResolvers:!0}).then(function(e){return u(e.data||void 0)}):"none"===c&&r===t.NetworkStatus.refetch&&Array.isArray(a.missing)?u(void 0):u(l)},_="no-cache"===l?0:r===t.NetworkStatus.refetch&&"merge"!==u?1:2,b=function(){return n.getResultsFromLink(e,_,{query:p,variables:o,context:f,fetchPolicy:l,errorPolicy:c})},w=h&&"number"==typeof v&&v!==r&&N(r);switch(l){default:case"cache-first":var E=y();if(E.complete)return{fromLink:!1,sources:[g(E,e.markReady())]};if(m||w)return{fromLink:!0,sources:[g(E),b()]};return{fromLink:!0,sources:[b()]};case"cache-and-network":var E=y();if(E.complete||m||w)return{fromLink:!0,sources:[g(E),b()]};return{fromLink:!0,sources:[b()]};case"cache-only":return{fromLink:!1,sources:[g(y(),e.markReady())]};case"network-only":if(w)return{fromLink:!0,sources:[g(y()),b()]};return{fromLink:!0,sources:[b()]};case"no-cache":if(w)return{fromLink:!0,sources:[g(e.getDiff()),b()]};return{fromLink:!0,sources:[b()]};case"standby":return{fromLink:!1,sources:[]}}},e.prototype.getOrCreateQuery=function(e){return e&&!this.queries.has(e)&&this.queries.set(e,new F(this,e)),this.queries.get(e)},e.prototype.prepareContext=function(e){void 0===e&&(e={});var t=this.localState.prepareContext(e);return i.__assign(i.__assign(i.__assign({},this.defaultContext),t),{clientAwareness:this.clientAwareness})},e}(),M=function(){function e(e){var t=e.cache,a=e.client,r=e.resolvers,i=e.fragmentMatcher;this.selectionsToResolveCache=new WeakMap,this.cache=t,a&&(this.client=a),r&&this.addResolvers(r),i&&this.setFragmentMatcher(i)}return e.prototype.addResolvers=function(e){var t=this;this.resolvers=this.resolvers||{},Array.isArray(e)?e.forEach(function(e){t.resolvers=d.mergeDeep(t.resolvers,e)}):this.resolvers=d.mergeDeep(this.resolvers,e)},e.prototype.setResolvers=function(e){this.resolvers={},this.addResolvers(e)},e.prototype.getResolvers=function(){return this.resolvers||{}},e.prototype.runResolvers=function(e){return i.__awaiter(this,arguments,void 0,function(e){var t=e.document,a=e.remoteResult,r=e.context,n=e.variables,p=e.onlyRunForcedResolvers,o=void 0!==p&&p;return i.__generator(this,function(e){return t?[2,this.resolveDocument(t,a.data,r,n,this.fragmentMatcher,o).then(function(e){return i.__assign(i.__assign({},a),{data:e.result})})]:[2,a]})})},e.prototype.setFragmentMatcher=function(e){this.fragmentMatcher=e},e.prototype.getFragmentMatcher=function(){return this.fragmentMatcher},e.prototype.clientQuery=function(e){return d.hasDirectives(["client"],e)&&this.resolvers?e:null},e.prototype.serverQuery=function(e){return d.removeClientSetsFromDocument(e)},e.prototype.prepareContext=function(e){var t=this.cache;return i.__assign(i.__assign({},e),{cache:t,getCacheKey:function(e){return t.identify(e)}})},e.prototype.addExportedVariables=function(e){return i.__awaiter(this,arguments,void 0,function(e,t,a){return void 0===t&&(t={}),void 0===a&&(a={}),i.__generator(this,function(r){return e?[2,this.resolveDocument(e,this.buildRootValueFromCache(e,t)||{},this.prepareContext(a),t).then(function(e){return i.__assign(i.__assign({},t),e.exportedVariables)})]:[2,i.__assign({},t)]})})},e.prototype.shouldForceResolvers=function(e){var t=!1;return h.visit(e,{Directive:{enter:function(e){if("client"===e.name.value&&e.arguments&&(t=e.arguments.some(function(e){return"always"===e.name.value&&"BooleanValue"===e.value.kind&&!0===e.value.value})))return h.BREAK}}}),t},e.prototype.buildRootValueFromCache=function(e,t){return this.cache.diff({query:d.buildQueryFromSelectionSet(e),variables:t,returnPartialData:!0,optimistic:!1}).result},e.prototype.resolveDocument=function(e,t){return i.__awaiter(this,arguments,void 0,function(e,t,a,r,n,p){var o,s,l,u,c,m,f,h,v,y;return void 0===a&&(a={}),void 0===r&&(r={}),void 0===n&&(n=function(){return!0}),void 0===p&&(p=!1),i.__generator(this,function(g){return o=d.getMainDefinition(e),s=d.getFragmentDefinitions(e),l=d.createFragmentMap(s),u=this.collectSelectionsToResolve(o,l),m=(c=o.operation)?c.charAt(0).toUpperCase()+c.slice(1):"Query",f=this,h=f.cache,v=f.client,y={fragmentMap:l,context:i.__assign(i.__assign({},a),{cache:h,client:v}),variables:r,fragmentMatcher:n,defaultOperationType:m,exportedVariables:{},selectionsToResolve:u,onlyRunForcedResolvers:p},[2,this.resolveSelectionSet(o.selectionSet,!1,t,y).then(function(e){return{result:e,exportedVariables:y.exportedVariables}})]})})},e.prototype.resolveSelectionSet=function(e,t,a,r){return i.__awaiter(this,void 0,void 0,function(){var p,o,s,l,u,c=this;return i.__generator(this,function(m){return p=r.fragmentMap,o=r.context,s=r.variables,l=[a],u=function(e){return i.__awaiter(c,void 0,void 0,function(){var u,c;return i.__generator(this,function(i){return(t||r.selectionsToResolve.has(e))&&d.shouldInclude(e,s)?d.isField(e)?[2,this.resolveField(e,t,a,r).then(function(t){var a;void 0!==t&&l.push(((a={})[d.resultKeyNameFromField(e)]=t,a))})]:(d.isInlineFragment(e)?u=e:(u=p[e.name.value],n.invariant(u,19,e.name.value)),u&&u.typeCondition&&(c=u.typeCondition.name.value,r.fragmentMatcher(a,c,o)))?[2,this.resolveSelectionSet(u.selectionSet,t,a,r).then(function(e){l.push(e)})]:[2]:[2]})})},[2,Promise.all(e.selections.map(u)).then(function(){return d.mergeDeepArray(l)})]})})},e.prototype.resolveField=function(e,t,a,r){return i.__awaiter(this,void 0,void 0,function(){var n,p,o,s,u,c,m,f,h,v=this;return i.__generator(this,function(i){return a?(n=r.variables,s=(p=e.name.value)!==(o=d.resultKeyNameFromField(e)),c=Promise.resolve(u=a[o]||a[p]),(!r.onlyRunForcedResolvers||this.shouldForceResolvers(e))&&(m=a.__typename||r.defaultOperationType,(f=this.resolvers&&this.resolvers[m])&&(h=f[s?p:o])&&(c=Promise.resolve(l.cacheSlot.withValue(this.cache,h,[a,d.argumentsObjectFromField(e,n),r.context,{field:e,fragmentMap:r.fragmentMap}])))),[2,c.then(function(a){if(void 0===a&&(a=u),e.directives&&e.directives.forEach(function(e){"export"===e.name.value&&e.arguments&&e.arguments.forEach(function(e){"as"===e.name.value&&"StringValue"===e.value.kind&&(r.exportedVariables[e.value.value]=a)})}),!e.selectionSet||null==a)return a;var i,n,p=null!=(n=null==(i=e.directives)?void 0:i.some(function(e){return"client"===e.name.value}))&&n;return Array.isArray(a)?v.resolveSubSelectedArray(e,t||p,a,r):e.selectionSet?v.resolveSelectionSet(e.selectionSet,t||p,a,r):void 0})]):[2,null]})})},e.prototype.resolveSubSelectedArray=function(e,t,a,r){var i=this;return Promise.all(a.map(function(a){return null===a?null:Array.isArray(a)?i.resolveSubSelectedArray(e,t,a,r):e.selectionSet?i.resolveSelectionSet(e.selectionSet,t,a,r):void 0}))},e.prototype.collectSelectionsToResolve=function(e,t){var a=function(e){return!Array.isArray(e)},r=this.selectionsToResolveCache;return function e(i){if(!r.has(i)){var p=new Set;r.set(i,p),h.visit(i,{Directive:function(e,t,r,i,n){"client"===e.name.value&&n.forEach(function(e){a(e)&&h.isSelectionNode(e)&&p.add(e)})},FragmentSpread:function(r,i,o,s,d){var l=t[r.name.value];n.invariant(l,20,r.name.value);var u=e(l);u.size>0&&(d.forEach(function(e){a(e)&&h.isSelectionNode(e)&&p.add(e)}),p.add(r),u.forEach(function(e){p.add(e)}))}})}return r.get(i)}(e)},e}(),U=Symbol.for("apollo.cacheSize"),B=i.__assign({},n.global[U]),q={},Q=!1!==globalThis.__DEV__?function(){var e,t,a,r,n;if(!1===globalThis.__DEV__)throw Error("only supported in development mode");return{limits:Object.fromEntries(Object.entries({parser:1e3,canonicalStringify:1e3,print:2e3,"documentTransform.cache":2e3,"queryManager.getDocumentInfo":2e3,"PersistedQueryLink.persistedQueryHashes":2e3,"fragmentRegistry.transform":2e3,"fragmentRegistry.lookup":1e3,"fragmentRegistry.findFragmentSpreads":4e3,"cache.fragmentQueryDocuments":1e3,"removeTypenameFromVariables.getVariableDefinitions":2e3,"inMemoryCache.maybeBroadcastWatch":5e3,"inMemoryCache.executeSelectionSet":5e4,"inMemoryCache.executeSubSelectedArray":1e4}).map(function(e){var t=e[0],a=e[1];return[t,B[t]||a]})),sizes:i.__assign({print:null==(e=q.print)?void 0:e.call(q),parser:null==(t=q.parser)?void 0:t.call(q),canonicalStringify:null==(a=q.canonicalStringify)?void 0:a.call(q),links:function e(t){var a;return t?i.__spreadArray(i.__spreadArray([null==(a=null==t?void 0:t.getMemoryInternals)?void 0:a.call(t)],e(null==t?void 0:t.left),!0),e(null==t?void 0:t.right),!0).filter(Y):[]}(this.link),queryManager:{getDocumentInfo:this.queryManager.transformCache.size,documentTransforms:(function e(t){var a,r;return t?i.__spreadArray(i.__spreadArray([(r=a=null==t?void 0:t.performWork)&&"dirtyKey"in r?a.size:void 0],e(null==t?void 0:t.left),!0),e(null==t?void 0:t.right),!0).filter(Y):[]})(this.queryManager.documentTransform).map(function(e){return{cache:e}})}},null==(n=(r=this.cache).getMemoryInternals)?void 0:n.call(r))}}:void 0;function Y(e){return null!=e}var G=!1,z=function(){function e(e){var t,a=this;if(this.resetStoreCallbacks=[],this.clearStoreCallbacks=[],!e.cache)throw n.newInvariantError(16);var r=e.uri,s=e.credentials,d=e.headers,l=e.cache,u=e.documentTransform,c=e.ssrMode,m=void 0!==c&&c,f=e.ssrForceFetchDelay,h=void 0===f?0:f,v=e.connectToDevTools,y=e.queryDeduplication,g=void 0===y||y,_=e.defaultOptions,b=e.defaultContext,w=e.assumeImmutableResults,E=void 0===w?l.assumeImmutableResults:w,T=e.resolvers,N=e.typeDefs,S=e.fragmentMatcher,O=e.name,I=e.version,D=e.devtools,A=e.dataMasking,k=e.link;k||(k=r?new o.HttpLink({uri:r,credentials:s,headers:d}):p.ApolloLink.empty()),this.link=k,this.cache=l,this.disableNetworkFetches=m||h>0,this.queryDeduplication=g,this.defaultOptions=_||Object.create(null),this.typeDefs=N,this.devtoolsConfig=i.__assign(i.__assign({},D),{enabled:null!=(t=null==D?void 0:D.enabled)?t:v}),void 0===this.devtoolsConfig.enabled&&(this.devtoolsConfig.enabled=!1!==globalThis.__DEV__),h&&setTimeout(function(){return a.disableNetworkFetches=!1},h),this.watchQuery=this.watchQuery.bind(this),this.query=this.query.bind(this),this.mutate=this.mutate.bind(this),this.watchFragment=this.watchFragment.bind(this),this.resetStore=this.resetStore.bind(this),this.reFetchObservableQueries=this.reFetchObservableQueries.bind(this),this.version="3.13.8",this.localState=new M({cache:l,client:this,resolvers:T,fragmentMatcher:S}),this.queryManager=new j({cache:this.cache,link:this.link,defaultOptions:this.defaultOptions,defaultContext:b,documentTransform:u,queryDeduplication:g,ssrMode:m,dataMasking:!!A,clientAwareness:{name:O,version:I},localState:this.localState,assumeImmutableResults:E,onBroadcast:this.devtoolsConfig.enabled?function(){a.devToolsHookCb&&a.devToolsHookCb({action:{},state:{queries:a.queryManager.getQueryStore(),mutations:a.queryManager.mutationStore||{}},dataWithOptimisticResults:a.cache.extract(!0)})}:void 0}),this.devtoolsConfig.enabled&&this.connectToDevTools()}return e.prototype.connectToDevTools=function(){if("u">typeof window){var e=window,t=Symbol.for("apollo.devtools");(e[t]=e[t]||[]).push(this),e.__APOLLO_CLIENT__=this,!G&&!1!==globalThis.__DEV__&&(G=!0,window.document&&window.top===window.self&&/^(https?|file):$/.test(window.location.protocol)&&setTimeout(function(){if(!window.__APOLLO_DEVTOOLS_GLOBAL_HOOK__){var e=window.navigator,t=e&&e.userAgent,a=void 0;"string"==typeof t&&(t.indexOf("Chrome/")>-1?a="https://chrome.google.com/webstore/detail/apollo-client-developer-t/jdkknkkbebbapilgoeccciglkfbmbnfm":t.indexOf("Firefox/")>-1&&(a="https://addons.mozilla.org/en-US/firefox/addon/apollo-developer-tools/")),a&&!1!==globalThis.__DEV__&&n.invariant.log("Download the Apollo DevTools for a better development experience: %s",a)}},1e4))}},Object.defineProperty(e.prototype,"documentTransform",{get:function(){return this.queryManager.documentTransform},enumerable:!1,configurable:!0}),e.prototype.stop=function(){this.queryManager.stop()},e.prototype.watchQuery=function(e){return this.defaultOptions.watchQuery&&(e=d.mergeOptions(this.defaultOptions.watchQuery,e)),this.disableNetworkFetches&&("network-only"===e.fetchPolicy||"cache-and-network"===e.fetchPolicy)&&(e=i.__assign(i.__assign({},e),{fetchPolicy:"cache-first"})),this.queryManager.watchQuery(e)},e.prototype.query=function(e){return this.defaultOptions.query&&(e=d.mergeOptions(this.defaultOptions.query,e)),n.invariant("cache-and-network"!==e.fetchPolicy,17),this.disableNetworkFetches&&"network-only"===e.fetchPolicy&&(e=i.__assign(i.__assign({},e),{fetchPolicy:"cache-first"})),this.queryManager.query(e)},e.prototype.mutate=function(e){return this.defaultOptions.mutate&&(e=d.mergeOptions(this.defaultOptions.mutate,e)),this.queryManager.mutate(e)},e.prototype.subscribe=function(e){var t=this,a=this.queryManager.generateQueryId();return this.queryManager.startGraphQLSubscription(e).map(function(r){return i.__assign(i.__assign({},r),{data:t.queryManager.maskOperation({document:e.query,data:r.data,fetchPolicy:e.fetchPolicy,id:a})})})},e.prototype.readQuery=function(e,t){return void 0===t&&(t=!1),this.cache.readQuery(e,t)},e.prototype.watchFragment=function(e){var t;return this.cache.watchFragment(i.__assign(i.__assign({},e),((t={})[Symbol.for("apollo.dataMasking")]=this.queryManager.dataMasking,t)))},e.prototype.readFragment=function(e,t){return void 0===t&&(t=!1),this.cache.readFragment(e,t)},e.prototype.writeQuery=function(e){var t=this.cache.writeQuery(e);return!1!==e.broadcast&&this.queryManager.broadcastQueries(),t},e.prototype.writeFragment=function(e){var t=this.cache.writeFragment(e);return!1!==e.broadcast&&this.queryManager.broadcastQueries(),t},e.prototype.__actionHookForDevTools=function(e){this.devToolsHookCb=e},e.prototype.__requestRaw=function(e){return p.execute(this.link,e)},e.prototype.resetStore=function(){var e=this;return Promise.resolve().then(function(){return e.queryManager.clearStore({discardWatches:!1})}).then(function(){return Promise.all(e.resetStoreCallbacks.map(function(e){return e()}))}).then(function(){return e.reFetchObservableQueries()})},e.prototype.clearStore=function(){var e=this;return Promise.resolve().then(function(){return e.queryManager.clearStore({discardWatches:!0})}).then(function(){return Promise.all(e.clearStoreCallbacks.map(function(e){return e()}))})},e.prototype.onResetStore=function(e){var t=this;return this.resetStoreCallbacks.push(e),function(){t.resetStoreCallbacks=t.resetStoreCallbacks.filter(function(t){return t!==e})}},e.prototype.onClearStore=function(e){var t=this;return this.clearStoreCallbacks.push(e),function(){t.clearStoreCallbacks=t.clearStoreCallbacks.filter(function(t){return t!==e})}},e.prototype.reFetchObservableQueries=function(e){return this.queryManager.reFetchObservableQueries(e)},e.prototype.refetchQueries=function(e){var t=this.queryManager.refetchQueries(e),a=[],r=[];t.forEach(function(e,t){a.push(t),r.push(e)});var i=Promise.all(r);return i.queries=a,i.results=r,i.catch(function(e){!1!==globalThis.__DEV__&&n.invariant.debug(18,e)}),i},e.prototype.getObservableQueries=function(e){return void 0===e&&(e="active"),this.queryManager.getObservableQueries(e)},e.prototype.extract=function(e){return this.cache.extract(e)},e.prototype.restore=function(e){return this.cache.restore(e)},e.prototype.addResolvers=function(e){this.localState.addResolvers(e)},e.prototype.setResolvers=function(e){this.localState.setResolvers(e)},e.prototype.getResolvers=function(){return this.localState.getResolvers()},e.prototype.setLocalStateFragmentMatcher=function(e){this.localState.setFragmentMatcher(e)},e.prototype.setLink=function(e){this.link=this.queryManager.link=e},Object.defineProperty(e.prototype,"defaultContext",{get:function(){return this.queryManager.defaultContext},enumerable:!1,configurable:!0}),e}();for(var H in!1!==globalThis.__DEV__&&(z.prototype.getMemoryInternals=Q),y.setVerbosity(!1!==globalThis.__DEV__?"log":"silent"),t.DocumentTransform=d.DocumentTransform,t.Observable=d.Observable,t.isReference=d.isReference,t.makeReference=d.makeReference,t.mergeOptions=d.mergeOptions,t.ApolloCache=l.ApolloCache,t.Cache=l.Cache,t.InMemoryCache=l.InMemoryCache,t.MissingFieldError=l.MissingFieldError,t.defaultDataIdFromObject=l.defaultDataIdFromObject,t.makeVar=l.makeVar,t.ApolloError=u.ApolloError,t.isApolloError=u.isApolloError,t.fromError=v.fromError,t.fromPromise=v.fromPromise,t.throwServerError=v.throwServerError,t.toPromise=v.toPromise,t.setLogVerbosity=y.setVerbosity,t.disableExperimentalFragmentVariables=g.disableExperimentalFragmentVariables,t.disableFragmentWarnings=g.disableFragmentWarnings,t.enableExperimentalFragmentVariables=g.enableExperimentalFragmentVariables,t.gql=g.gql,t.resetCaches=g.resetCaches,t.ApolloClient=z,t.ObservableQuery=A,t.isNetworkRequestSettled=function(e){return 7===e||8===e},p)"default"===H||t.hasOwnProperty(H)||(t[H]=p[H]);for(var H in o)"default"===H||t.hasOwnProperty(H)||(t[H]=o[H])},78549(e,t,a){var r=a(85608),i=a(4232),n=a(5437);t.o=function(e){return new i.ApolloLink(function(t,a){var i=r.__rest(t,[]);return new n.Observable(function(r){var n,p=!1;return Promise.resolve(i).then(function(a){return e(a,t.getContext())}).then(t.setContext).then(function(){p||(n=a(t).subscribe({next:r.next.bind(r),error:r.error.bind(r),complete:r.complete.bind(r)}))}).catch(r.error.bind(r)),function(){p=!0,n&&n.unsubscribe()}})})}},66442(e){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var a=0,r=Array(t);a<t;a++)r[a]=e[a];return r},e.exports.__esModule=!0,e.exports.default=e.exports},3634(e){e.exports=function(e){if(Array.isArray(e))return e},e.exports.__esModule=!0,e.exports.default=e.exports},65372(e){e.exports=function(e){if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e},e.exports.__esModule=!0,e.exports.default=e.exports},99436(e){function t(e,t,a,r,i,n,p){try{var o=e[n](p),s=o.value}catch(e){return void a(e)}o.done?t(s):Promise.resolve(s).then(r,i)}e.exports=function(e){return function(){var a=this,r=arguments;return new Promise(function(i,n){var p=e.apply(a,r);function o(e){t(p,i,n,o,s,"next",e)}function s(e){t(p,i,n,o,s,"throw",e)}o(void 0)})}},e.exports.__esModule=!0,e.exports.default=e.exports},5018(e){e.exports=function(e,t){if(!(e instanceof t))throw TypeError("Cannot call a class as a function")},e.exports.__esModule=!0,e.exports.default=e.exports},57301(e,t,a){var r=a(37399),i=a(69893);e.exports=function(e,t,a){if(r())return Reflect.construct.apply(null,arguments);var n=[null];n.push.apply(n,t);var p=new(e.bind.apply(e,n));return a&&i(p,a.prototype),p},e.exports.__esModule=!0,e.exports.default=e.exports},44668(e,t,a){var r=a(56347);function i(e,t){for(var a=0;a<t.length;a++){var i=t[a];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,r(i.key),i)}}e.exports=function(e,t,a){return t&&i(e.prototype,t),a&&i(e,a),Object.defineProperty(e,"prototype",{writable:!1}),e},e.exports.__esModule=!0,e.exports.default=e.exports},30409(e){function t(a){return e.exports=t=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},e.exports.__esModule=!0,e.exports.default=e.exports,t(a)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},40906(e,t,a){var r=a(69893);e.exports=function(e,t){if("function"!=typeof t&&null!==t)throw TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&r(e,t)},e.exports.__esModule=!0,e.exports.default=e.exports},39833(e){e.exports=function(e){try{return -1!==Function.toString.call(e).indexOf("[native code]")}catch(t){return"function"==typeof e}},e.exports.__esModule=!0,e.exports.default=e.exports},37399(e){function t(){try{var a=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(e.exports=t=function(){return!!a},e.exports.__esModule=!0,e.exports.default=e.exports)()}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},96525(e){e.exports=function(e,t){var a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var r,i,n,p,o=[],s=!0,d=!1;try{if(n=(a=a.call(e)).next,0===t){if(Object(a)!==a)return;s=!1}else for(;!(s=(r=n.call(a)).done)&&(o.push(r.value),o.length!==t);s=!0);}catch(e){d=!0,i=e}finally{try{if(!s&&null!=a.return&&(p=a.return(),Object(p)!==p))return}finally{if(d)throw i}}return o}},e.exports.__esModule=!0,e.exports.default=e.exports},5523(e){e.exports=function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.__esModule=!0,e.exports.default=e.exports},67996(e,t,a){var r=a(51112);e.exports=function(e,t){if(null==e)return{};var a,i,n=r(e,t);if(Object.getOwnPropertySymbols){var p=Object.getOwnPropertySymbols(e);for(i=0;i<p.length;i++)a=p[i],-1===t.indexOf(a)&&({}).propertyIsEnumerable.call(e,a)&&(n[a]=e[a])}return n},e.exports.__esModule=!0,e.exports.default=e.exports},51112(e){e.exports=function(e,t){if(null==e)return{};var a={};for(var r in e)if(({}).hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;a[r]=e[r]}return a},e.exports.__esModule=!0,e.exports.default=e.exports},63315(e,t,a){var r=a(14319).default,i=a(65372);e.exports=function(e,t){if(t&&("object"==r(t)||"function"==typeof t))return t;if(void 0!==t)throw TypeError("Derived constructors may only return object or undefined");return i(e)},e.exports.__esModule=!0,e.exports.default=e.exports},69893(e){function t(a,r){return e.exports=t=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},e.exports.__esModule=!0,e.exports.default=e.exports,t(a,r)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},68832(e,t,a){var r=a(3634),i=a(96525),n=a(78243),p=a(5523);e.exports=function(e,t){return r(e)||i(e,t)||n(e,t)||p()},e.exports.__esModule=!0,e.exports.default=e.exports},23878(e,t,a){var r=a(14319).default;e.exports=function(e,t){if("object"!=r(e)||!e)return e;var a=e[Symbol.toPrimitive];if(void 0!==a){var i=a.call(e,t||"default");if("object"!=r(i))return i;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)},e.exports.__esModule=!0,e.exports.default=e.exports},56347(e,t,a){var r=a(14319).default,i=a(23878);e.exports=function(e){var t=i(e,"string");return"symbol"==r(t)?t:t+""},e.exports.__esModule=!0,e.exports.default=e.exports},14319(e){function t(a){return e.exports=t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.__esModule=!0,e.exports.default=e.exports,t(a)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},78243(e,t,a){var r=a(66442);e.exports=function(e,t){if(e){if("string"==typeof e)return r(e,t);var a=({}).toString.call(e).slice(8,-1);return"Object"===a&&e.constructor&&(a=e.constructor.name),"Map"===a||"Set"===a?Array.from(e):"Arguments"===a||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a)?r(e,t):void 0}},e.exports.__esModule=!0,e.exports.default=e.exports},59410(e,t,a){var r=a(30409),i=a(69893),n=a(39833),p=a(57301);function o(t){var a="function"==typeof Map?new Map:void 0;return e.exports=o=function(e){if(null===e||!n(e))return e;if("function"!=typeof e)throw TypeError("Super expression must either be null or a function");if(void 0!==a){if(a.has(e))return a.get(e);a.set(e,t)}function t(){return p(e,arguments,r(this).constructor)}return t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),i(t,e)},e.exports.__esModule=!0,e.exports.default=e.exports,o(t)}e.exports=o,e.exports.__esModule=!0,e.exports.default=e.exports},42495(e,t,a){a.d(t,{k:()=>h});var r=a(85608),i=a(60837),n=a(2904),p=a(555),o=a(3777),s=a(36054),d=a(30671),l=a(54019),u=a(44114),c=a(55427),m=a(70916),f=a(62959),h=function(){function e(){this.assumeImmutableResults=!1,this.getFragmentDoc=(0,i.wrap)(n.ct,{max:p.v["cache.fragmentQueryDocuments"]||1e3,cache:l.l})}return e.prototype.lookupFragment=function(e){return null},e.prototype.batch=function(e){var t,a=this,r="string"==typeof e.optimistic?e.optimistic:!1===e.optimistic?null:void 0;return this.performTransaction(function(){return t=e.update(a)},r),t},e.prototype.recordOptimisticTransaction=function(e,t){this.performTransaction(e,t)},e.prototype.transformDocument=function(e){return e},e.prototype.transformForLink=function(e){return e},e.prototype.identify=function(e){},e.prototype.gc=function(){return[]},e.prototype.modify=function(e){return!1},e.prototype.readQuery=function(e,t){return void 0===t&&(t=!!e.optimistic),this.read((0,r.__assign)((0,r.__assign)({},e),{rootId:e.id||"ROOT_QUERY",optimistic:t}))},e.prototype.watchFragment=function(e){var t,a=this,i=e.fragment,n=e.fragmentName,p=e.from,l=e.optimistic,u=(0,r.__rest)(e,["fragment","fragmentName","from","optimistic"]),h=this.getFragmentDoc(i,n),v=void 0===p||"string"==typeof p?p:this.identify(p),y=!!e[Symbol.for("apollo.dataMasking")];if(!1!==globalThis.__DEV__){var g=n||(0,o.E4)(i).name.value;v||!1===globalThis.__DEV__||m.invariant.warn(1,g)}var _=(0,r.__assign)((0,r.__assign)({},u),{returnPartialData:!0,id:v,query:h,optimistic:void 0===l||l});return new s.c(function(p){return a.watch((0,r.__assign)((0,r.__assign)({},_),{immediate:!0,callback:function(o){var s=y?(0,f.z)(o.result,i,a,n):o.result;if(!(t&&(0,c.a)(h,{data:t.result},{data:s},e.variables))){var l={data:s,complete:!!o.complete};o.missing&&(l.missing=(0,d.IM)(o.missing.map(function(e){return e.missing}))),t=(0,r.__assign)((0,r.__assign)({},o),{result:s}),p.next(l)}}}))})},e.prototype.readFragment=function(e,t){return void 0===t&&(t=!!e.optimistic),this.read((0,r.__assign)((0,r.__assign)({},e),{query:this.getFragmentDoc(e.fragment,e.fragmentName),rootId:e.id,optimistic:t}))},e.prototype.writeQuery=function(e){var t=e.id,a=e.data,i=(0,r.__rest)(e,["id","data"]);return this.write(Object.assign(i,{dataId:t||"ROOT_QUERY",result:a}))},e.prototype.writeFragment=function(e){var t=e.id,a=e.data,i=e.fragment,n=e.fragmentName,p=(0,r.__rest)(e,["id","data","fragment","fragmentName"]);return this.write(Object.assign(p,{query:this.getFragmentDoc(i,n),dataId:t,result:a}))},e.prototype.updateQuery=function(e,t){return this.batch({update:function(a){var i=a.readQuery(e),n=t(i);return null==n?i:(a.writeQuery((0,r.__assign)((0,r.__assign)({},e),{data:n})),n)}})},e.prototype.updateFragment=function(e,t){return this.batch({update:function(a){var i=a.readFragment(e),n=t(i);return null==n?i:(a.writeFragment((0,r.__assign)((0,r.__assign)({},e),{data:n})),n)}})},e}();!1!==globalThis.__DEV__&&(h.prototype.getMemoryInternals=u.tQ)},84673(e,t,a){var r;a.d(t,{l:()=>r}),r||(r={})},65702(e,t,a){a.d(t,{Z:()=>i});var r=a(85608),i=function(e){function t(a,r,i,n){var p,o=e.call(this,a)||this;if(o.message=a,o.path=r,o.query=i,o.variables=n,Array.isArray(o.path)){o.missing=o.message;for(var s=o.path.length-1;s>=0;--s)(p={})[o.path[s]]=o.missing,o.missing=p}else o.missing=o.path;return o.__proto__=t.prototype,o}return(0,r.__extends)(t,e),t}(Error)},94037(e,t,a){a.r(t),a.d(t,{fieldNameFromStoreName:()=>d.iJ,makeVar:()=>u.UT,canonicalStringify:()=>o.M,cacheSlot:()=>u.bl,isReference:()=>p.A_,MissingFieldError:()=>n.Z,EntityStore:()=>s.D_,Cache:()=>i.l,Policies:()=>c.l,InMemoryCache:()=>l.D,ApolloCache:()=>r.k,defaultDataIdFromObject:()=>d.or,makeReference:()=>p.WU,createFragmentRegistry:()=>_}),a(70916);var r=a(42495),i=a(84673),n=a(65702),p=a(28907),o=a(44214),s=a(83906),d=a(35207),l=a(7068),u=a(777),c=a(92610),m=a(85608),f=a(90424),h=a(60837),v=a(3777),y=a(555),g=a(54019);function _(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return new(b.bind.apply(b,(0,m.__spreadArray)([void 0],e,!1)))}var b=function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.registry=Object.create(null),this.resetCaches(),e.length&&this.register.apply(this,e)}return e.prototype.register=function(){for(var e=this,t=[],a=0;a<arguments.length;a++)t[a]=arguments[a];var r=new Map;return t.forEach(function(e){(0,v.zK)(e).forEach(function(e){r.set(e.name.value,e)})}),r.forEach(function(t,a){t!==e.registry[a]&&(e.registry[a]=t,e.invalidate(a))}),this},e.prototype.invalidate=function(e){},e.prototype.resetCaches=function(){var t=e.prototype;this.invalidate=(this.lookup=(0,h.wrap)(t.lookup.bind(this),{makeCacheKey:function(e){return e},max:y.v["fragmentRegistry.lookup"]||1e3})).dirty,this.transform=(0,h.wrap)(t.transform.bind(this),{cache:g.l,max:y.v["fragmentRegistry.transform"]||2e3}),this.findFragmentSpreads=(0,h.wrap)(t.findFragmentSpreads.bind(this),{cache:g.l,max:y.v["fragmentRegistry.findFragmentSpreads"]||4e3})},e.prototype.lookup=function(e){return this.registry[e]||null},e.prototype.transform=function(e){var t=this,a=new Map;(0,v.zK)(e).forEach(function(e){a.set(e.name.value,e)});var r=new Set,i=function(e){a.has(e)||r.add(e)},n=function(e){return Object.keys(t.findFragmentSpreads(e)).forEach(i)};n(e);var p=[],o=Object.create(null);if(r.forEach(function(e){var r=a.get(e);if(r)n(o[e]=r);else{p.push(e);var i=t.lookup(e);i&&n(o[e]=i)}}),p.length){var s=[];p.forEach(function(e){var t=o[e];t&&s.push(t)}),s.length&&(e=(0,m.__assign)((0,m.__assign)({},e),{definitions:e.definitions.concat(s)}))}return e},e.prototype.findFragmentSpreads=function(e){var t=Object.create(null);return(0,f.YR)(e,{FragmentSpread:function(e){t[e.name.value]=e}}),t},e}()},83906(e,t,a){a.d(t,{$7:()=>S,D_:()=>_,M2:()=>w});var r,i,n=a(85608),p=a(70916),o=a(60837),s=a(55888),d=a(44592),l=a(57236),u=a(28907),c=a(30671),m=a(21777),f=a(51360),h=a(35207),v=Object.create(null),y=function(){return v},g=Object.create(null),_=function(){function e(e,t){var a=this;this.policies=e,this.group=t,this.data=Object.create(null),this.rootIds=Object.create(null),this.refs=Object.create(null),this.getFieldValue=function(e,t){return(0,l.G)((0,u.A_)(e)?a.get(e.__ref,t):e&&e[t])},this.canRead=function(e){return(0,u.A_)(e)?a.has(e.__ref):"object"==typeof e},this.toReference=function(e,t){if("string"==typeof e)return(0,u.WU)(e);if((0,u.A_)(e))return e;var r=a.policies.identify(e)[0];if(r){var i=(0,u.WU)(r);return t&&a.merge(r,e),i}}}return e.prototype.toObject=function(){return(0,n.__assign)({},this.data)},e.prototype.has=function(e){return void 0!==this.lookup(e,!0)},e.prototype.get=function(e,t){if(this.group.depend(e,t),h.$3.call(this.data,e)){var a=this.data[e];if(a&&h.$3.call(a,t))return a[t]}return"__typename"===t&&h.$3.call(this.policies.rootTypenamesById,e)?this.policies.rootTypenamesById[e]:this instanceof E?this.parent.get(e,t):void 0},e.prototype.lookup=function(e,t){return(t&&this.group.depend(e,"__exists"),h.$3.call(this.data,e))?this.data[e]:this instanceof E?this.parent.lookup(e,t):this.policies.rootTypenamesById[e]?Object.create(null):void 0},e.prototype.merge=function(e,t){var a,r=this;(0,u.A_)(e)&&(e=e.__ref),(0,u.A_)(t)&&(t=t.__ref);var i="string"==typeof e?this.lookup(a=e):e,n="string"==typeof t?this.lookup(a=t):t;if(n){(0,p.invariant)("string"==typeof a,2);var o=new c.ZI(N).merge(i,n);if(this.data[a]=o,o!==i&&(delete this.refs[a],this.group.caching)){var s=Object.create(null);i||(s.__exists=1),Object.keys(n).forEach(function(e){if(!i||i[e]!==o[e]){s[e]=1;var t=(0,h.iJ)(e);t===e||r.policies.hasKeyArgs(o.__typename,t)||(s[t]=1),void 0!==o[e]||r instanceof E||delete o[e]}}),s.__typename&&!(i&&i.__typename)&&this.policies.rootTypenamesById[a]===o.__typename&&delete s.__typename,Object.keys(s).forEach(function(e){return r.group.dirty(a,e)})}}},e.prototype.modify=function(e,t){var a=this,r=this.lookup(e);if(r){var i=Object.create(null),o=!1,s=!0,d={DELETE:v,INVALIDATE:g,isReference:u.A_,toReference:this.toReference,canRead:this.canRead,readField:function(t,r){return a.policies.readField("string"==typeof t?{fieldName:t,from:r||(0,u.WU)(e)}:t,{store:a})}};if(Object.keys(r).forEach(function(c){var m=(0,h.iJ)(c),f=r[c];if(void 0!==f){var _="function"==typeof t?t:t[c]||t[m];if(_){var b=_===y?v:_((0,l.G)(f),(0,n.__assign)((0,n.__assign)({},d),{fieldName:m,storeFieldName:c,storage:a.getStorage(e,c)}));if(b===g)a.group.dirty(e,c);else if(b===v&&(b=void 0),b!==f&&(i[c]=b,o=!0,f=b,!1!==globalThis.__DEV__)){var w=function(e){if(void 0===a.lookup(e.__ref))return!1!==globalThis.__DEV__&&p.invariant.warn(3,e),!0};if((0,u.A_)(b))w(b);else if(Array.isArray(b))for(var E=!1,T=void 0,N=0,S=b;N<S.length;N++){var O=S[N];if((0,u.A_)(O)){if(E=!0,w(O))break}else"object"==typeof O&&O&&a.policies.identify(O)[0]&&(T=O);if(E&&void 0!==T){!1!==globalThis.__DEV__&&p.invariant.warn(4,T);break}}}}void 0!==f&&(s=!1)}}),o)return this.merge(e,i),s&&(this instanceof E?this.data[e]=void 0:delete this.data[e],this.group.dirty(e,"__exists")),!0}return!1},e.prototype.delete=function(e,t,a){var r,i=this.lookup(e);if(i){var n=this.getFieldValue(i,"__typename"),p=t&&a?this.policies.getStoreFieldName({typename:n,fieldName:t,args:a}):t;return this.modify(e,p?((r={})[p]=y,r):y)}return!1},e.prototype.evict=function(e,t){var a=!1;return e.id&&(h.$3.call(this.data,e.id)&&(a=this.delete(e.id,e.fieldName,e.args)),this instanceof E&&this!==t&&(a=this.parent.evict(e,t)||a),(e.fieldName||a)&&this.group.dirty(e.id,e.fieldName||"__exists")),a},e.prototype.clear=function(){this.replace(null)},e.prototype.extract=function(){var e=this,t=this.toObject(),a=[];return this.getRootIdSet().forEach(function(t){h.$3.call(e.policies.rootTypenamesById,t)||a.push(t)}),a.length&&(t.__META={extraRootIds:a.sort()}),t},e.prototype.replace=function(e){var t=this;if(Object.keys(this.data).forEach(function(a){e&&h.$3.call(e,a)||t.delete(a)}),e){var a=e.__META,r=(0,n.__rest)(e,["__META"]);Object.keys(r).forEach(function(e){t.merge(e,r[e])}),a&&a.extraRootIds.forEach(this.retain,this)}},e.prototype.retain=function(e){return this.rootIds[e]=(this.rootIds[e]||0)+1},e.prototype.release=function(e){if(this.rootIds[e]>0){var t=--this.rootIds[e];return t||delete this.rootIds[e],t}return 0},e.prototype.getRootIdSet=function(e){return void 0===e&&(e=new Set),Object.keys(this.rootIds).forEach(e.add,e),this instanceof E?this.parent.getRootIdSet(e):Object.keys(this.policies.rootTypenamesById).forEach(e.add,e),e},e.prototype.gc=function(){var e=this,t=this.getRootIdSet(),a=this.toObject();t.forEach(function(r){h.$3.call(a,r)&&(Object.keys(e.findChildRefIds(r)).forEach(t.add,t),delete a[r])});var r=Object.keys(a);if(r.length){for(var i=this;i instanceof E;)i=i.parent;r.forEach(function(e){return i.delete(e)})}return r},e.prototype.findChildRefIds=function(e){if(!h.$3.call(this.refs,e)){var t=this.refs[e]=Object.create(null),a=this.data[e];if(!a)return t;var r=new Set([a]);r.forEach(function(e){(0,u.A_)(e)&&(t[e.__ref]=!0),(0,m.U)(e)&&Object.keys(e).forEach(function(t){var a=e[t];(0,m.U)(a)&&r.add(a)})})}return this.refs[e]},e.prototype.makeCacheKey=function(){return this.group.keyMaker.lookupArray(arguments)},e}(),b=function(){function e(e,t){void 0===t&&(t=null),this.caching=e,this.parent=t,this.d=null,this.resetCaching()}return e.prototype.resetCaching=function(){this.d=this.caching?(0,o.dep)():null,this.keyMaker=new d.Trie(f.et)},e.prototype.depend=function(e,t){if(this.d){this.d(t+"#"+e);var a=(0,h.iJ)(t);a!==t&&this.d(a+"#"+e),this.parent&&this.parent.depend(e,t)}},e.prototype.dirty=function(e,t){this.d&&this.d.dirty(t+"#"+e,"__exists"===t?"forget":"setDirty")},e}();function w(e,t){S(e)&&e.group.depend(t,"__exists")}i=function(e){function t(t){var a=t.policies,r=t.resultCaching,i=t.seed,n=e.call(this,a,new b(void 0===r||r))||this;return n.stump=new T(n),n.storageTrie=new d.Trie(f.et),i&&n.replace(i),n}return(0,n.__extends)(t,e),t.prototype.addLayer=function(e,t){return this.stump.addLayer(e,t)},t.prototype.removeLayer=function(){return this},t.prototype.getStorage=function(){return this.storageTrie.lookupArray(arguments)},t}(r=_||(_={})),r.Root=i;var E=function(e){function t(t,a,r,i){var n=e.call(this,a.policies,i)||this;return n.id=t,n.parent=a,n.replay=r,n.group=i,r(n),n}return(0,n.__extends)(t,e),t.prototype.addLayer=function(e,a){return new t(e,this,a,this.group)},t.prototype.removeLayer=function(e){var t=this,a=this.parent.removeLayer(e);return e===this.id?(this.group.caching&&Object.keys(this.data).forEach(function(e){var r=t.data[e],i=a.lookup(e);i?r?r!==i&&Object.keys(r).forEach(function(a){(0,s.equal)(r[a],i[a])||t.group.dirty(e,a)}):(t.group.dirty(e,"__exists"),Object.keys(i).forEach(function(a){t.group.dirty(e,a)})):t.delete(e)}),a):a===this.parent?this:a.addLayer(this.id,this.replay)},t.prototype.toObject=function(){return(0,n.__assign)((0,n.__assign)({},this.parent.toObject()),this.data)},t.prototype.findChildRefIds=function(t){var a=this.parent.findChildRefIds(t);return h.$3.call(this.data,t)?(0,n.__assign)((0,n.__assign)({},a),e.prototype.findChildRefIds.call(this,t)):a},t.prototype.getStorage=function(){for(var e=this.parent;e.parent;)e=e.parent;return e.getStorage.apply(e,arguments)},t}(_),T=function(e){function t(t){return e.call(this,"EntityStore.Stump",t,function(){},new b(t.group.caching,t.group))||this}return(0,n.__extends)(t,e),t.prototype.removeLayer=function(){return this},t.prototype.merge=function(e,t){return this.parent.merge(e,t)},t}(E);function N(e,t,a){var r=e[a],i=t[a];return(0,s.equal)(r,i)?r:i}function S(e){return!!(e instanceof _&&e.group.caching)}},35207(e,t,a){a.d(t,{$3:()=>u,I6:()=>h,T9:()=>function e(t,a,r){return!!(0,n.U)(a)&&((0,p.c)(a)?a.every(function(a){return e(t,a,r)}):t.selections.every(function(t){if((0,i.dt)(t)&&(0,o.MS)(t,r)){var n=(0,i.ue)(t);return u.call(a,n)&&(!t.selectionSet||e(t.selectionSet,a[n],r))}return!0}))},Ui:()=>y,Xx:()=>v,d1:()=>b,gk:()=>g,iJ:()=>_,lq:()=>E,mv:()=>w,or:()=>m});var r=a(50492),i=a(28907),n=a(21777),p=a(73767),o=a(82307),s=a(30671),d=a(2904),l=a(3777),u=Object.prototype.hasOwnProperty;function c(e){return null==e}function m(e,t){var a=e.__typename,r=e.id,i=e._id;if("string"==typeof a&&(t&&(t.keyObject=c(r)?c(i)?void 0:{_id:i}:{id:r}),c(r)&&!c(i)&&(r=i),!c(r)))return"".concat(a,":").concat("number"==typeof r||"string"==typeof r?r:JSON.stringify(r))}var f={dataIdFromObject:m,addTypename:!0,resultCaching:!0,canonizeResults:!1};function h(e){return(0,r.o)(f,e)}function v(e){var t=e.canonizeResults;return void 0===t?f.canonizeResults:t}function y(e,t){return(0,i.A_)(t)?e.get(t.__ref,"__typename"):t&&t.__typename}var g=/^[_a-z][_0-9a-z]*/i;function _(e){var t=e.match(g);return t?t[0]:e}function b(e){return(0,n.U)(e)&&!(0,i.A_)(e)&&!(0,p.c)(e)}function w(){return new s.ZI}function E(e,t){var a=(0,d.JG)((0,l.zK)(e));return{fragmentMap:a,lookupFragment:function(e){var r=a[e];return!r&&t&&(r=t.lookup(e)),r||null}}}},7068(e,t,a){a.d(t,{D:()=>B});var r=a(85608),i=a(70916),n=a(60837),p=a(55888),o=a(42495),s=a(65702),d=a(9354),l=a(53925),u=a(555),c=a(44214),m=a(38678),f=a(28907),h=a(42455),v=a(51360),y=a(50492),g=a(3777),_=a(30671),b=a(82307),w=a(2904),E=a(57236),T=a(21777),N=a(83906),S=a(35207),O=a(73767),I=a(44592),D=function(){function e(){this.known=new(v.En?WeakSet:Set),this.pool=new I.Trie(v.et),this.passes=new WeakMap,this.keysByJSON=new Map,this.empty=this.admit({})}return e.prototype.isKnown=function(e){return(0,T.U)(e)&&this.known.has(e)},e.prototype.pass=function(e){if((0,T.U)(e)){var t=(0,T.U)(e)?(0,O.c)(e)?e.slice(0):(0,r.__assign)({__proto__:Object.getPrototypeOf(e)},e):e;return this.passes.set(t,e),t}return e},e.prototype.admit=function(e){var t=this;if((0,T.U)(e)){var a=this.passes.get(e);if(a)return a;switch(Object.getPrototypeOf(e)){case Array.prototype:if(this.known.has(e))break;var r=e.map(this.admit,this),i=this.pool.lookupArray(r);return i.array||(this.known.add(i.array=r),!1!==globalThis.__DEV__&&Object.freeze(r)),i.array;case null:case Object.prototype:if(this.known.has(e))break;var n=Object.getPrototypeOf(e),p=[n],o=this.sortedKeys(e);p.push(o.json);var s=p.length;o.sorted.forEach(function(a){p.push(t.admit(e[a]))});var i=this.pool.lookupArray(p);if(!i.object){var d=i.object=Object.create(n);this.known.add(d),o.sorted.forEach(function(e,t){d[e]=p[s+t]}),!1!==globalThis.__DEV__&&Object.freeze(d)}return i.object}}return e},e.prototype.sortedKeys=function(e){var t=Object.keys(e),a=this.pool.lookupArray(t);if(!a.keys){t.sort();var r=JSON.stringify(t);(a.keys=this.keysByJSON.get(r))||this.keysByJSON.set(r,a.keys={sorted:t,json:r})}return a.keys},e}();function A(e){return[e.selectionSet,e.objectOrReference,e.context,e.context.canonizeResults]}var k=function(){function e(e){var t=this;this.knownResults=new(v.et?WeakMap:Map),this.config=(0,y.o)(e,{addTypename:!1!==e.addTypename,canonizeResults:(0,S.Xx)(e)}),this.canon=e.canon||new D,this.executeSelectionSet=(0,n.wrap)(function(e){var a,i=e.context.canonizeResults,n=A(e);n[3]=!i;var p=(a=t.executeSelectionSet).peek.apply(a,n);return p?i?(0,r.__assign)((0,r.__assign)({},p),{result:t.canon.admit(p.result)}):p:((0,N.M2)(e.context.store,e.enclosingRef.__ref),t.execSelectionSetImpl(e))},{max:this.config.resultCacheMaxSize||u.v["inMemoryCache.executeSelectionSet"]||5e4,keyArgs:A,makeCacheKey:function(e,t,a,r){if((0,N.$7)(a.store))return a.store.makeCacheKey(e,(0,f.A_)(t)?t.__ref:t,a.varString,r)}}),this.executeSubSelectedArray=(0,n.wrap)(function(e){return(0,N.M2)(e.context.store,e.enclosingRef.__ref),t.execSubSelectedArrayImpl(e)},{max:this.config.resultCacheMaxSize||u.v["inMemoryCache.executeSubSelectedArray"]||1e4,makeCacheKey:function(e){var t=e.field,a=e.array,r=e.context;if((0,N.$7)(r.store))return r.store.makeCacheKey(t,a,r.varString)}})}return e.prototype.resetCanon=function(){this.canon=new D},e.prototype.diffQueryAgainstStore=function(e){var t,a=e.store,i=e.query,n=e.rootId,p=e.variables,o=e.returnPartialData,d=e.canonizeResults,l=void 0===d?this.config.canonizeResults:d,u=this.config.cache.policies;p=(0,r.__assign)((0,r.__assign)({},(0,g.wY)((0,g.AT)(i))),p);var m=(0,f.WU)(void 0===n?"ROOT_QUERY":n),h=this.executeSelectionSet({selectionSet:(0,g.Vn)(i).selectionSet,objectOrReference:m,enclosingRef:m,context:(0,r.__assign)({store:a,query:i,policies:u,variables:p,varString:(0,c.M)(p),canonizeResults:l},(0,S.lq)(i,this.config.fragments))});if(h.missing&&(t=[new s.Z(function(e){try{JSON.stringify(e,function(e,t){if("string"==typeof t)throw t;return t})}catch(e){return e}}(h.missing),h.missing,i,p)],!(void 0===o||o)))throw t[0];return{result:h.result,complete:!t,missing:t}},e.prototype.isFresh=function(e,t,a,r){if((0,N.$7)(r.store)&&this.knownResults.get(e)===a){var i=this.executeSelectionSet.peek(a,t,r,this.canon.isKnown(e));if(i&&e===i.result)return!0}return!1},e.prototype.execSelectionSetImpl=function(e){var t,a=this,r=e.selectionSet,n=e.objectOrReference,p=e.enclosingRef,o=e.context;if((0,f.A_)(n)&&!o.policies.rootTypenamesById[n.__ref]&&!o.store.has(n.__ref))return{result:this.canon.empty,missing:"Dangling reference to missing ".concat(n.__ref," object")};var s=o.variables,d=o.policies,u=o.store.getFieldValue(n,"__typename"),c=[],m=new _.ZI;function v(e,a){var r;return e.missing&&(t=m.merge(t,((r={})[a]=e.missing,r))),e.result}this.config.addTypename&&"string"==typeof u&&!d.rootIdsByTypename[u]&&c.push({__typename:u});var y=new Set(r.selections);y.forEach(function(e){var r,g;if((0,b.MS)(e,s))if((0,f.dt)(e)){var _=d.readField({fieldName:e.name.value,field:e,variables:o.variables,from:n},o),E=(0,f.ue)(e);void 0===_?l.XY.added(e)||(t=m.merge(t,((r={})[E]="Can't find field '".concat(e.name.value,"' on ").concat((0,f.A_)(n)?n.__ref+" object":"object "+JSON.stringify(n,null,2)),r))):(0,O.c)(_)?_.length>0&&(_=v(a.executeSubSelectedArray({field:e,array:_,enclosingRef:p,context:o}),E)):e.selectionSet?null!=_&&(_=v(a.executeSelectionSet({selectionSet:e.selectionSet,objectOrReference:_,enclosingRef:(0,f.A_)(_)?_:p,context:o}),E)):o.canonizeResults&&(_=a.canon.pass(_)),void 0!==_&&c.push(((g={})[E]=_,g))}else{var T=(0,w.HQ)(e,o.lookupFragment);if(!T&&e.kind===h.b.FRAGMENT_SPREAD)throw(0,i.newInvariantError)(10,e.name.value);T&&d.fragmentMatches(T,u)&&T.selectionSet.selections.forEach(y.add,y)}});var g={result:(0,_.IM)(c),missing:t},T=o.canonizeResults?this.canon.admit(g):(0,E.G)(g);return T.result&&this.knownResults.set(T.result,r),T},e.prototype.execSubSelectedArrayImpl=function(e){var t,a=this,r=e.field,n=e.array,p=e.enclosingRef,o=e.context,s=new _.ZI;function d(e,a){var r;return e.missing&&(t=s.merge(t,((r={})[a]=e.missing,r))),e.result}return r.selectionSet&&(n=n.filter(o.store.canRead)),n=n.map(function(e,t){return null===e?null:(0,O.c)(e)?d(a.executeSubSelectedArray({field:r,array:e,enclosingRef:p,context:o}),t):r.selectionSet?d(a.executeSelectionSet({selectionSet:r.selectionSet,objectOrReference:e,enclosingRef:(0,f.A_)(e)?e:p,context:o}),t):(!1!==globalThis.__DEV__&&function(e,t,a){if(!t.selectionSet){var r=new Set([a]);r.forEach(function(a){(0,T.U)(a)&&((0,i.invariant)(!(0,f.A_)(a),11,(0,S.Ui)(e,a),t.name.value),Object.values(a).forEach(r.add,r))})}}(o.store,r,e),e)}),{result:o.canonizeResults?this.canon.admit(n):n,missing:t}},e}(),x=a(20906),C=a(92610);function R(e,t,a){var i="".concat(t).concat(a),n=e.flavors.get(i);return n||e.flavors.set(i,n=e.clientOnly===t&&e.deferred===a?e:(0,r.__assign)((0,r.__assign)({},e),{clientOnly:t,deferred:a})),n}var V=function(){function e(e,t,a){this.cache=e,this.reader=t,this.fragments=a}return e.prototype.writeToStore=function(e,t){var a=this,n=t.query,o=t.result,s=t.dataId,d=t.variables,l=t.overwrite,u=(0,g.Vu)(n),m=(0,S.mv)();d=(0,r.__assign)((0,r.__assign)({},(0,g.wY)(u)),d);var h=(0,r.__assign)((0,r.__assign)({store:e,written:Object.create(null),merge:function(e,t){return m.merge(e,t)},variables:d,varString:(0,c.M)(d)},(0,S.lq)(n,this.fragments)),{overwrite:!!l,incomingById:new Map,clientOnly:!1,deferred:!1,flavors:new Map}),v=this.processSelectionSet({result:o||Object.create(null),dataId:s,selectionSet:u.selectionSet,mergeTree:{map:new Map},context:h});if(!(0,f.A_)(v))throw(0,i.newInvariantError)(12,o);return h.incomingById.forEach(function(t,n){var o=t.storeObject,s=t.mergeTree,d=t.fieldNodeSet,l=(0,f.WU)(n);if(s&&s.map.size){var u=a.applyMerges(s,l,o,h);if((0,f.A_)(u))return;o=u}if(!1!==globalThis.__DEV__&&!h.overwrite){var c=Object.create(null);d.forEach(function(e){e.selectionSet&&(c[e.name.value]=!0)});var m=function(e){var t=s&&s.map.get(e);return!!(t&&t.info&&t.info.merge)};Object.keys(o).forEach(function(e){!0!==c[(0,S.iJ)(e)]||m(e)||function(e,t,a,n){var o=function(e){var t=n.getFieldValue(e,a);return"object"==typeof t&&t},s=o(e);if(s){var d=o(t);if(!(!d||(0,f.A_)(s)||(0,p.equal)(s,d)||Object.keys(s).every(function(e){return void 0!==n.getFieldValue(d,e)}))){var l=n.getFieldValue(e,"__typename")||n.getFieldValue(t,"__typename"),u=(0,S.iJ)(a),c="".concat(l,".").concat(u);if(!j.has(c)){j.add(c);var m=[];(0,O.c)(s)||(0,O.c)(d)||[s,d].forEach(function(e){var t=n.getFieldValue(e,"__typename");"string"!=typeof t||m.includes(t)||m.push(t)}),!1!==globalThis.__DEV__&&i.invariant.warn(15,u,l,m.length?"either ensure all objects of type "+m.join(" and ")+" have an ID or a custom merge function, or ":"",c,(0,r.__assign)({},s),(0,r.__assign)({},d))}}}}(l,o,e,h.store)})}e.merge(n,o)}),e.retain(v.__ref),v},e.prototype.processSelectionSet=function(e){var t=this,a=e.dataId,n=e.result,p=e.selectionSet,o=e.context,s=e.mergeTree,d=this.cache.policies,u=Object.create(null),c=a&&d.rootTypenamesById[a]||(0,f.D$)(n,p,o.fragmentMap)||a&&o.store.get(a,"__typename");"string"==typeof c&&(u.__typename=c);var m=function(){var e=(0,C.m)(arguments,u,o.variables);if((0,f.A_)(e.from)){var t=o.incomingById.get(e.from.__ref);if(t){var a=d.readField((0,r.__assign)((0,r.__assign)({},e),{from:t.storeObject}),o);if(void 0!==a)return a}}return d.readField(e,o)},h=new Set;this.flattenFields(p,n,o,c).forEach(function(e,a){var r,p=n[(0,f.ue)(a)];if(h.add(a),void 0!==p){var o=d.getStoreFieldName({typename:c,fieldName:a.name.value,field:a,variables:e.variables}),v=$(s,o),y=t.processFieldValue(p,a,a.selectionSet?R(e,!1,!1):e,v),g=void 0;a.selectionSet&&((0,f.A_)(y)||(0,S.d1)(y))&&(g=m("__typename",y));var _=d.getMergeFunction(c,a.name.value,g);_?v.info={field:a,typename:c,merge:_}:L(s,o),u=e.merge(u,((r={})[o]=y,r))}else!1===globalThis.__DEV__||e.clientOnly||e.deferred||l.XY.added(a)||d.getReadFunction(c,a.name.value)||!1===globalThis.__DEV__||i.invariant.error(13,(0,f.ue)(a),n)});try{var v=d.identify(n,{typename:c,selectionSet:p,fragmentMap:o.fragmentMap,storeObject:u,readField:m}),y=v[0],g=v[1];a=a||y,g&&(u=o.merge(u,g))}catch(e){if(!a)throw e}if("string"==typeof a){var _=(0,f.WU)(a),b=o.written[a]||(o.written[a]=[]);if(b.indexOf(p)>=0||(b.push(p),this.reader&&this.reader.isFresh(n,_,p,o)))return _;var w=o.incomingById.get(a);return w?(w.storeObject=o.merge(w.storeObject,u),w.mergeTree=function e(t,a){if(t===a||!a||P(a))return t;if(!t||P(t))return a;var i=t.info&&a.info?(0,r.__assign)((0,r.__assign)({},t.info),a.info):t.info||a.info,n=t.map.size&&a.map.size,p={info:i,map:n?new Map:t.map.size?t.map:a.map};if(n){var o=new Set(a.map.keys());t.map.forEach(function(t,r){p.map.set(r,e(t,a.map.get(r))),o.delete(r)}),o.forEach(function(r){p.map.set(r,e(a.map.get(r),t.map.get(r)))})}return p}(w.mergeTree,s),h.forEach(function(e){return w.fieldNodeSet.add(e)})):o.incomingById.set(a,{storeObject:u,mergeTree:P(s)?void 0:s,fieldNodeSet:h}),_}return u},e.prototype.processFieldValue=function(e,t,a,r){var i=this;return t.selectionSet&&null!==e?(0,O.c)(e)?e.map(function(e,n){var p=i.processFieldValue(e,t,a,$(r,n));return L(r,n),p}):this.processSelectionSet({result:e,selectionSet:t.selectionSet,context:a,mergeTree:r}):!1!==globalThis.__DEV__?(0,x.m)(e):e},e.prototype.flattenFields=function(e,t,a,r){void 0===r&&(r=(0,f.D$)(t,e,a.fragmentMap));var n=new Map,p=this.cache.policies,o=new I.Trie(!1);return!function e(s,d){var l=o.lookup(s,d.clientOnly,d.deferred);l.visited||(l.visited=!0,s.selections.forEach(function(o){if((0,b.MS)(o,a.variables)){var s=d.clientOnly,l=d.deferred;if(!(s&&l)&&(0,O.E)(o.directives)&&o.directives.forEach(function(e){var t=e.name.value;if("client"===t&&(s=!0),"defer"===t){var r=(0,f.MB)(e,a.variables);r&&!1===r.if||(l=!0)}}),(0,f.dt)(o)){var u=n.get(o);u&&(s=s&&u.clientOnly,l=l&&u.deferred),n.set(o,R(a,s,l))}else{var c=(0,w.HQ)(o,a.lookupFragment);if(!c&&o.kind===h.b.FRAGMENT_SPREAD)throw(0,i.newInvariantError)(14,o.name.value);c&&p.fragmentMatches(c,r,t,a.variables)&&e(c.selectionSet,R(a,s,l))}}}))}(e,a),n},e.prototype.applyMerges=function(e,t,a,n,p){var o=this;if(e.map.size&&!(0,f.A_)(a)){var s,d,l=!(0,O.c)(a)&&((0,f.A_)(t)||(0,S.d1)(t))?t:void 0,u=a;l&&!p&&(p=[(0,f.A_)(l)?l.__ref:l]);var c=function(e,t){return(0,O.c)(e)?"number"==typeof t?e[t]:void 0:n.store.getFieldValue(e,String(t))};e.map.forEach(function(e,t){var a=c(l,t),r=c(u,t);if(void 0!==r){p&&p.push(t);var s=o.applyMerges(e,a,r,n,p);s!==r&&(d=d||new Map).set(t,s),p&&(0,i.invariant)(p.pop()===t)}}),d&&(a=(0,O.c)(u)?u.slice(0):(0,r.__assign)({},u),d.forEach(function(e,t){a[t]=e}))}return e.info?this.cache.policies.runMergeFunction(t,a,e.info,n,p&&(s=n.store).getStorage.apply(s,p)):a},e}(),F=[];function $(e,t){var a=e.map;return a.has(t)||a.set(t,F.pop()||{map:new Map}),a.get(t)}function P(e){return!e||!(e.info||e.map.size)}function L(e,t){var a=e.map,r=a.get(t);r&&P(r)&&(F.push(r),a.delete(t))}var j=new Set,M=a(777),U=a(44114),B=function(e){function t(t){void 0===t&&(t={});var a=e.call(this)||this;return a.watches=new Set,a.addTypenameTransform=new d.c(l.XY),a.assumeImmutableResults=!0,a.makeVar=M.UT,a.txCount=0,a.config=(0,S.I6)(t),a.addTypename=!!a.config.addTypename,a.policies=new C.l({cache:a,dataIdFromObject:a.config.dataIdFromObject,possibleTypes:a.config.possibleTypes,typePolicies:a.config.typePolicies}),a.init(),a}return(0,r.__extends)(t,e),t.prototype.init=function(){var e=this.data=new N.D_.Root({policies:this.policies,resultCaching:this.config.resultCaching});this.optimisticData=e.stump,this.resetResultCache()},t.prototype.resetResultCache=function(e){var t=this,a=this.storeReader,r=this.config.fragments;this.storeWriter=new V(this,this.storeReader=new k({cache:this,addTypename:this.addTypename,resultCacheMaxSize:this.config.resultCacheMaxSize,canonizeResults:(0,S.Xx)(this.config),canon:e?void 0:a&&a.canon,fragments:r}),r),this.maybeBroadcastWatch=(0,n.wrap)(function(e,a){return t.broadcastWatch(e,a)},{max:this.config.resultCacheMaxSize||u.v["inMemoryCache.maybeBroadcastWatch"]||5e3,makeCacheKey:function(e){var a=e.optimistic?t.optimisticData:t.data;if((0,N.$7)(a)){var r=e.optimistic,i=e.id,n=e.variables;return a.makeCacheKey(e.query,e.callback,(0,c.M)({optimistic:r,id:i,variables:n}))}}}),new Set([this.data.group,this.optimisticData.group]).forEach(function(e){return e.resetCaching()})},t.prototype.restore=function(e){return this.init(),e&&this.data.replace(e),this},t.prototype.extract=function(e){return void 0===e&&(e=!1),(e?this.optimisticData:this.data).extract()},t.prototype.read=function(e){var t=e.returnPartialData;try{return this.storeReader.diffQueryAgainstStore((0,r.__assign)((0,r.__assign)({},e),{store:e.optimistic?this.optimisticData:this.data,config:this.config,returnPartialData:void 0!==t&&t})).result||null}catch(e){if(e instanceof s.Z)return null;throw e}},t.prototype.write=function(e){try{return++this.txCount,this.storeWriter.writeToStore(this.data,e)}finally{--this.txCount||!1===e.broadcast||this.broadcastWatches()}},t.prototype.modify=function(e){if(S.$3.call(e,"id")&&!e.id)return!1;var t=e.optimistic?this.optimisticData:this.data;try{return++this.txCount,t.modify(e.id||"ROOT_QUERY",e.fields)}finally{--this.txCount||!1===e.broadcast||this.broadcastWatches()}},t.prototype.diff=function(e){return this.storeReader.diffQueryAgainstStore((0,r.__assign)((0,r.__assign)({},e),{store:e.optimistic?this.optimisticData:this.data,rootId:e.id||"ROOT_QUERY",config:this.config}))},t.prototype.watch=function(e){var t=this;return this.watches.size||(0,M.MS)(this),this.watches.add(e),e.immediate&&this.maybeBroadcastWatch(e),function(){t.watches.delete(e)&&!t.watches.size&&(0,M.WR)(t),t.maybeBroadcastWatch.forget(e)}},t.prototype.gc=function(e){c.M.reset(),m.y.reset(),this.addTypenameTransform.resetCache(),null==(t=this.config.fragments)||t.resetCaches();var t,a=this.optimisticData.gc();return e&&!this.txCount&&(e.resetResultCache?this.resetResultCache(e.resetResultIdentities):e.resetResultIdentities&&this.storeReader.resetCanon()),a},t.prototype.retain=function(e,t){return(t?this.optimisticData:this.data).retain(e)},t.prototype.release=function(e,t){return(t?this.optimisticData:this.data).release(e)},t.prototype.identify=function(e){if((0,f.A_)(e))return e.__ref;try{return this.policies.identify(e)[0]}catch(e){!1!==globalThis.__DEV__&&i.invariant.warn(e)}},t.prototype.evict=function(e){if(!e.id){if(S.$3.call(e,"id"))return!1;e=(0,r.__assign)((0,r.__assign)({},e),{id:"ROOT_QUERY"})}try{return++this.txCount,this.optimisticData.evict(e,this.data)}finally{--this.txCount||!1===e.broadcast||this.broadcastWatches()}},t.prototype.reset=function(e){var t=this;return this.init(),c.M.reset(),e&&e.discardWatches?(this.watches.forEach(function(e){return t.maybeBroadcastWatch.forget(e)}),this.watches.clear(),(0,M.WR)(this)):this.broadcastWatches(),Promise.resolve()},t.prototype.removeOptimistic=function(e){var t=this.optimisticData.removeLayer(e);t!==this.optimisticData&&(this.optimisticData=t,this.broadcastWatches())},t.prototype.batch=function(e){var t,a=this,i=e.update,n=e.optimistic,p=void 0===n||n,o=e.removeOptimistic,s=e.onWatchUpdated,d=function(e){var r=a.data,n=a.optimisticData;++a.txCount,e&&(a.data=a.optimisticData=e);try{return t=i(a)}finally{--a.txCount,a.data=r,a.optimisticData=n}},l=new Set;return s&&!this.txCount&&this.broadcastWatches((0,r.__assign)((0,r.__assign)({},e),{onWatchUpdated:function(e){return l.add(e),!1}})),"string"==typeof p?this.optimisticData=this.optimisticData.addLayer(p,d):!1===p?d(this.data):d(),"string"==typeof o&&(this.optimisticData=this.optimisticData.removeLayer(o)),s&&l.size?(this.broadcastWatches((0,r.__assign)((0,r.__assign)({},e),{onWatchUpdated:function(e,t){var a=s.call(this,e,t);return!1!==a&&l.delete(e),a}})),l.size&&l.forEach(function(e){return a.maybeBroadcastWatch.dirty(e)})):this.broadcastWatches(e),t},t.prototype.performTransaction=function(e,t){return this.batch({update:e,optimistic:t||null!==t})},t.prototype.transformDocument=function(e){return this.addTypenameToDocument(this.addFragmentsToDocument(e))},t.prototype.fragmentMatches=function(e,t){return this.policies.fragmentMatches(e,t)},t.prototype.lookupFragment=function(e){var t;return(null==(t=this.config.fragments)?void 0:t.lookup(e))||null},t.prototype.broadcastWatches=function(e){var t=this;this.txCount||this.watches.forEach(function(a){return t.maybeBroadcastWatch(a,e)})},t.prototype.addFragmentsToDocument=function(e){var t=this.config.fragments;return t?t.transform(e):e},t.prototype.addTypenameToDocument=function(e){return this.addTypename?this.addTypenameTransform.transformDocument(e):e},t.prototype.broadcastWatch=function(e,t){var a=e.lastDiff,r=this.diff(e);(!t||(e.optimistic&&"string"==typeof t.optimistic&&(r.fromOptimisticTransaction=!0),!t.onWatchUpdated||!1!==t.onWatchUpdated.call(this,e,r,a)))&&(a&&(0,p.equal)(a.result,r.result)||e.callback(e.lastDiff=r,a))},t}(o.k);!1!==globalThis.__DEV__&&(B.prototype.getMemoryInternals=U.cM)},92610(e,t,a){a.d(t,{l:()=>S,m:()=>I});var r=a(85608),i=a(70916),n=a(28907),p=a(86563),o=a(21777),s=a(35207),d=a(73767),l=a(777),u=a(30671),c=Object.create(null);function m(e){var t=JSON.stringify(e);return c[t]||(c[t]=Object.create(null))}function f(e){var t=m(e);return t.keyFieldsFn||(t.keyFieldsFn=function(t,a){var r=function(e,t){return a.readField(t,e)},n=a.keyObject=v(e,function(e){var n=g(a.storeObject,e,r);return void 0===n&&t!==a.storeObject&&s.$3.call(t,e[0])&&(n=g(t,e,y)),(0,i.invariant)(void 0!==n,5,e.join("."),t),n});return"".concat(a.typename,":").concat(JSON.stringify(n))})}function h(e){var t=m(e);return t.keyArgsFn||(t.keyArgsFn=function(t,a){var r=a.field,i=a.variables,p=a.fieldName,o=JSON.stringify(v(e,function(e){var a=e[0],p=a.charAt(0);if("@"===p){if(r&&(0,d.E)(r.directives)){var o=a.slice(1),l=r.directives.find(function(e){return e.name.value===o}),u=l&&(0,n.MB)(l,i);return u&&g(u,e.slice(1))}return}if("$"===p){var c=a.slice(1);if(i&&s.$3.call(i,c)){var m=e.slice(0);return m[0]=c,g(i,m)}return}if(t)return g(t,e)}));return(t||"{}"!==o)&&(p+=":"+o),p})}function v(e,t){var a=new u.ZI;return(function e(t){var a=m(t);if(!a.paths){var r=a.paths=[],i=[];t.forEach(function(a,n){(0,d.c)(a)?(e(a).forEach(function(e){return r.push(i.concat(e))}),i.length=0):(i.push(a),(0,d.c)(t[n+1])||(r.push(i.slice(0)),i.length=0))})}return a.paths})(e).reduce(function(e,r){var i,n=t(r);if(void 0!==n){for(var p=r.length-1;p>=0;--p)(i={})[r[p]]=n,n=i;e=a.merge(e,n)}return e},Object.create(null))}function y(e,t){return e[t]}function g(e,t,a){return a=a||y,function e(t){return(0,o.U)(t)?(0,d.c)(t)?t.map(e):v(Object.keys(t).sort(),function(e){return g(t,e)}):t}(t.reduce(function e(t,r){return(0,d.c)(t)?t.map(function(t){return e(t,r)}):t&&a(t,r)},e))}var _=a(47150);function b(e){return void 0!==e.args?e.args:e.field?(0,n.MB)(e.field,e.variables):null}var w=function(){},E=function(e,t){return t.fieldName},T=function(e,t,a){return(0,a.mergeObjects)(e,t)},N=function(e,t){return t},S=function(){function e(e){this.config=e,this.typePolicies=Object.create(null),this.toBeAdded=Object.create(null),this.supertypeMap=new Map,this.fuzzySubtypes=new Map,this.rootIdsByTypename=Object.create(null),this.rootTypenamesById=Object.create(null),this.usingPossibleTypes=!1,this.config=(0,r.__assign)({dataIdFromObject:s.or},e),this.cache=this.config.cache,this.setRootTypename("Query"),this.setRootTypename("Mutation"),this.setRootTypename("Subscription"),e.possibleTypes&&this.addPossibleTypes(e.possibleTypes),e.typePolicies&&this.addTypePolicies(e.typePolicies)}return e.prototype.identify=function(e,t){var a,i,n=this,p=t&&(t.typename||(null==(a=t.storeObject)?void 0:a.__typename))||e.__typename;if(p===this.rootTypenamesById.ROOT_QUERY)return["ROOT_QUERY"];var o=t&&t.storeObject||e,s=(0,r.__assign)((0,r.__assign)({},t),{typename:p,storeObject:o,readField:t&&t.readField||function(){var e=I(arguments,o);return n.readField(e,{store:n.cache.data,variables:e.variables})}}),l=p&&this.getTypePolicy(p),u=l&&l.keyFn||this.config.dataIdFromObject;return _.yV.withValue(!0,function(){for(;u;){var t=u((0,r.__assign)((0,r.__assign)({},e),o),s);if((0,d.c)(t))u=f(t);else{i=t;break}}}),i=i?String(i):void 0,s.keyObject?[i,s.keyObject]:[i]},e.prototype.addTypePolicies=function(e){var t=this;Object.keys(e).forEach(function(a){var i=e[a],n=i.queryType,p=i.mutationType,o=i.subscriptionType,d=(0,r.__rest)(i,["queryType","mutationType","subscriptionType"]);n&&t.setRootTypename("Query",a),p&&t.setRootTypename("Mutation",a),o&&t.setRootTypename("Subscription",a),s.$3.call(t.toBeAdded,a)?t.toBeAdded[a].push(d):t.toBeAdded[a]=[d]})},e.prototype.updateTypePolicy=function(e,t){var a=this,r=this.getTypePolicy(e),i=t.keyFields,n=t.fields;function p(e,t){e.merge="function"==typeof t?t:!0===t?T:!1===t?N:e.merge}p(r,t.merge),r.keyFn=!1===i?w:(0,d.c)(i)?f(i):"function"==typeof i?i:r.keyFn,n&&Object.keys(n).forEach(function(t){var r=a.getFieldPolicy(e,t,!0),i=n[t];if("function"==typeof i)r.read=i;else{var o=i.keyArgs,s=i.read,l=i.merge;r.keyFn=!1===o?E:(0,d.c)(o)?h(o):"function"==typeof o?o:r.keyFn,"function"==typeof s&&(r.read=s),p(r,l)}r.read&&r.merge&&(r.keyFn=r.keyFn||E)})},e.prototype.setRootTypename=function(e,t){void 0===t&&(t=e);var a="ROOT_"+e.toUpperCase(),r=this.rootTypenamesById[a];t!==r&&((0,i.invariant)(!r||r===e,6,e),r&&delete this.rootIdsByTypename[r],this.rootIdsByTypename[t]=a,this.rootTypenamesById[a]=t)},e.prototype.addPossibleTypes=function(e){var t=this;this.usingPossibleTypes=!0,Object.keys(e).forEach(function(a){t.getSupertypeSet(a,!0),e[a].forEach(function(e){t.getSupertypeSet(e,!0).add(a);var r=e.match(s.gk);r&&r[0]===e||t.fuzzySubtypes.set(e,new RegExp(e))})})},e.prototype.getTypePolicy=function(e){var t=this;if(!s.$3.call(this.typePolicies,e)){var a=this.typePolicies[e]=Object.create(null);a.fields=Object.create(null);var i=this.supertypeMap.get(e);!i&&this.fuzzySubtypes.size&&(i=this.getSupertypeSet(e,!0),this.fuzzySubtypes.forEach(function(a,r){if(a.test(e)){var n=t.supertypeMap.get(r);n&&n.forEach(function(e){return i.add(e)})}})),i&&i.size&&i.forEach(function(e){var i=t.getTypePolicy(e),n=i.fields;Object.assign(a,(0,r.__rest)(i,["fields"])),Object.assign(a.fields,n)})}var n=this.toBeAdded[e];return n&&n.length&&n.splice(0).forEach(function(a){t.updateTypePolicy(e,a)}),this.typePolicies[e]},e.prototype.getFieldPolicy=function(e,t,a){if(e){var r=this.getTypePolicy(e).fields;return r[t]||a&&(r[t]=Object.create(null))}},e.prototype.getSupertypeSet=function(e,t){var a=this.supertypeMap.get(e);return!a&&t&&this.supertypeMap.set(e,a=new Set),a},e.prototype.fragmentMatches=function(e,t,a,r){var n=this;if(!e.typeCondition)return!0;if(!t)return!1;var p=e.typeCondition.name.value;if(t===p)return!0;if(this.usingPossibleTypes&&this.supertypeMap.has(p))for(var o=this.getSupertypeSet(t,!0),d=[o],l=function(e){var t=n.getSupertypeSet(e,!1);t&&t.size&&0>d.indexOf(t)&&d.push(t)},u=!!(a&&this.fuzzySubtypes.size),c=!1,m=0;m<d.length;++m){var f=d[m];if(f.has(p))return o.has(p)||(c&&!1!==globalThis.__DEV__&&i.invariant.warn(7,t,p),o.add(p)),!0;f.forEach(l),u&&m===d.length-1&&(0,s.T9)(e.selectionSet,a,r)&&(u=!1,c=!0,this.fuzzySubtypes.forEach(function(e,a){var r=t.match(e);r&&r[0]===t&&l(a)}))}return!1},e.prototype.hasKeyArgs=function(e,t){var a=this.getFieldPolicy(e,t,!1);return!!(a&&a.keyFn)},e.prototype.getStoreFieldName=function(e){var t,a=e.typename,r=e.fieldName,i=this.getFieldPolicy(a,r,!1),p=i&&i.keyFn;if(p&&a)for(var o={typename:a,fieldName:r,field:e.field||null,variables:e.variables},l=b(e);p;){var u=p(l,o);if((0,d.c)(u))p=h(u);else{t=u||r;break}}return(void 0===t&&(t=e.field?(0,n.Ii)(e.field,e.variables):(0,n.o5)(r,b(e))),!1===t)?r:r===(0,s.iJ)(t)?t:r+":"+t},e.prototype.readField=function(e,t){var a=e.from;if(a&&(e.field||e.fieldName)){if(void 0===e.typename){var r=t.store.getFieldValue(a,"__typename");r&&(e.typename=r)}var i=this.getStoreFieldName(e),p=(0,s.iJ)(i),o=t.store.getFieldValue(a,i),d=this.getFieldPolicy(e.typename,p,!1),u=d&&d.read;if(u){var c=O(this,a,e,t,t.store.getStorage((0,n.A_)(a)?a.__ref:a,i));return l.bl.withValue(this.cache,u,[o,c])}return o}},e.prototype.getReadFunction=function(e,t){var a=this.getFieldPolicy(e,t,!1);return a&&a.read},e.prototype.getMergeFunction=function(e,t,a){var r=this.getFieldPolicy(e,t,!1),i=r&&r.merge;return!i&&a&&(i=(r=this.getTypePolicy(a))&&r.merge),i},e.prototype.runMergeFunction=function(e,t,a,r,i){var n=a.field,p=a.typename,o=a.merge;return o===T?D(r.store)(e,t):o===N?t:(r.overwrite&&(e=void 0),o(e,t,O(this,void 0,{typename:p,fieldName:n.name.value,field:n,variables:r.variables},r,i||Object.create(null))))},e}();function O(e,t,a,r,i){var p=e.getStoreFieldName(a),o=(0,s.iJ)(p),d=a.variables||r.variables,l=r.store,u=l.toReference,c=l.canRead;return{args:b(a),field:a.field||null,fieldName:o,storeFieldName:p,variables:d,isReference:n.A_,toReference:u,storage:i,cache:e.cache,canRead:c,readField:function(){return e.readField(I(arguments,t,d),r)},mergeObjects:D(r.store)}}function I(e,t,a){var n,o=e[0],d=e[1],l=e.length;return"string"==typeof o?n={fieldName:o,from:l>1?d:t}:(n=(0,r.__assign)({},o),s.$3.call(n,"from")||(n.from=t)),!1!==globalThis.__DEV__&&void 0===n.from&&!1!==globalThis.__DEV__&&i.invariant.warn(8,(0,p.p)(Array.from(e))),void 0===n.variables&&(n.variables=a),n}function D(e){return function(t,a){if((0,d.c)(t)||(0,d.c)(a))throw(0,i.newInvariantError)(9);if((0,o.U)(t)&&(0,o.U)(a)){var p=e.getFieldValue(t,"__typename"),l=e.getFieldValue(a,"__typename");if(p&&l&&p!==l)return a;if((0,n.A_)(t)&&(0,s.d1)(a))return e.merge(t.__ref,a),t;if((0,s.d1)(t)&&(0,n.A_)(a))return e.merge(t,a.__ref),a;if((0,s.d1)(t)&&(0,s.d1)(a))return(0,r.__assign)((0,r.__assign)({},t),a)}return a}}},777(e,t,a){a.d(t,{MS:()=>s,UT:()=>d,WR:()=>o,bl:()=>i});var r=a(60837),i=new r.Slot,n=new WeakMap;function p(e){var t=n.get(e);return t||n.set(e,t={vars:new Set,dep:(0,r.dep)()}),t}function o(e){p(e).vars.forEach(function(t){return t.forgetCache(e)})}function s(e){p(e).vars.forEach(function(t){return t.attachCache(e)})}function d(e){var t=new Set,a=new Set,r=function(o){if(arguments.length>0){if(e!==o){e=o,t.forEach(function(e){var t;p(e).dep.dirty(r),(t=e).broadcastWatches&&t.broadcastWatches()});var s=Array.from(a);a.clear(),s.forEach(function(t){return t(e)})}}else{var d=i.getValue();d&&(n(d),p(d).dep(r))}return e};r.onNextChange=function(e){return a.add(e),function(){a.delete(e)}};var n=r.attachCache=function(e){return t.add(e),p(e).vars.add(r),r};return r.forgetCache=function(e){return t.delete(e)},r}},55427(e,t,a){a.d(t,{a:()=>d});var r=a(85608),i=a(55888),n=a(3777),p=a(2904),o=a(82307),s=a(28907);function d(e,t,a,d){var u=t.data,c=(0,r.__rest)(t,["data"]),m=a.data,f=(0,r.__rest)(a,["data"]);return(0,i.default)(c,f)&&function e(t,a,r,n){if(a===r)return!0;var d=new Set;return t.selections.every(function(t){if(d.has(t)||(d.add(t),!(0,o.MS)(t,n.variables)||l(t)))return!0;if((0,s.dt)(t)){var u=(0,s.ue)(t),c=a&&a[u],m=r&&r[u],f=t.selectionSet;if(!f)return(0,i.default)(c,m);var h=Array.isArray(c),v=Array.isArray(m);if(h!==v)return!1;if(h&&v){var y=c.length;if(m.length!==y)return!1;for(var g=0;g<y;++g)if(!e(f,c[g],m[g],n))return!1;return!0}return e(f,c,m,n)}var _=(0,p.HQ)(t,n.fragmentMap);if(_)return!!l(_)||e(_.selectionSet,a,r,n)})}((0,n.Vn)(e).selectionSet,u,m,{fragmentMap:(0,p.JG)((0,n.zK)(e)),variables:d})}function l(e){return!!e.directives&&e.directives.some(u)}function u(e){return"nonreactive"===e.name.value}},53570(e,t,a){a.r(t),a.d(t,{ApolloError:()=>d,PROTOCOL_ERRORS_SYMBOL:()=>n,graphQLResultHasProtocolErrors:()=>p,isApolloError:()=>o});var r=a(85608);a(70916);var i=a(21777),n=Symbol();function p(e){return!!e.extensions&&Array.isArray(e.extensions[n])}function o(e){return e.hasOwnProperty("graphQLErrors")}var s=function(e){var t=(0,r.__spreadArray)((0,r.__spreadArray)((0,r.__spreadArray)([],e.graphQLErrors,!0),e.clientErrors,!0),e.protocolErrors,!0);return e.networkError&&t.push(e.networkError),t.map(function(e){return(0,i.U)(e)&&e.message||"Error message not found."}).join("\n")},d=function(e){function t(a){var i=a.graphQLErrors,n=a.protocolErrors,p=a.clientErrors,o=a.networkError,d=a.errorMessage,l=a.extraInfo,u=e.call(this,d)||this;return u.name="ApolloError",u.graphQLErrors=i||[],u.protocolErrors=n||[],u.clientErrors=p||[],u.networkError=o||null,u.message=d||s(u),u.extraInfo=l,u.cause=(0,r.__spreadArray)((0,r.__spreadArray)((0,r.__spreadArray)([o],i||[],!0),n||[],!0),p||[],!0).find(function(e){return!!e})||null,u.__proto__=t.prototype,u}return(0,r.__extends)(t,e),t}(Error)},19074(e,t,a){a.d(t,{C:()=>u});var r=a(70916),i=a(36054),n=a(16878),p=a(38414),o=a(46192);function s(e,t){return t?t(e):i.c.of()}function d(e){return"function"==typeof e?new u(e):e}function l(e){return e.request.length<=1}var u=function(){function e(e){e&&(this.request=e)}return e.empty=function(){return new e(function(){return i.c.of()})},e.from=function(t){return 0===t.length?e.empty():t.map(d).reduce(function(e,t){return e.concat(t)})},e.split=function(t,a,r){var n=d(a),p=d(r||new e(s));return Object.assign(new e(l(n)&&l(p)?function(e){return t(e)?n.request(e)||i.c.of():p.request(e)||i.c.of()}:function(e,a){return t(e)?n.request(e,a)||i.c.of():p.request(e,a)||i.c.of()}),{left:n,right:p})},e.execute=function(e,t){return e.request((0,n.k)(t.context,(0,p.A)((0,o.K)(t))))||i.c.of()},e.concat=function(t,a){var n=d(t);if(l(n))return!1!==globalThis.__DEV__&&r.invariant.warn(38,n),n;var p=d(a);return Object.assign(new e(l(p)?function(e){return n.request(e,function(e){return p.request(e)||i.c.of()})||i.c.of()}:function(e,t){return n.request(e,function(e){return p.request(e,t)||i.c.of()})||i.c.of()}),{left:n,right:p})},e.prototype.split=function(t,a,r){return this.concat(e.split(t,a,r||new e(s)))},e.prototype.concat=function(t){return e.concat(this,t)},e.prototype.request=function(e,t){throw(0,r.newInvariantError)(39)},e.prototype.onError=function(e,t){if(t&&t.error)return t.error(e),!1;throw e},e.prototype.setOnError=function(e){return this.onError=e,this},e}()},25174(e,t,a){a.d(t,{g:()=>r});var r=a(19074).C.execute},4232(e,t,a){a.r(t),a.d(t,{ApolloLink:()=>r.C,concat:()=>o,empty:()=>i,execute:()=>s.g,from:()=>n,split:()=>p}),a(70916);var r=a(19074),i=r.C.empty,n=r.C.from,p=r.C.split,o=r.C.concat,s=a(25174)},49952(e,t,a){a.d(t,{P:()=>p});var r=a(85608),i=a(19074),n=a(79760),p=function(e){function t(t){void 0===t&&(t={});var a=e.call(this,(0,n.$)(t).request)||this;return a.options=t,a}return(0,r.__extends)(t,e),t}(i.C)},67195(e,t,a){a.d(t,{S:()=>i});var r=a(70916),i=function(e){if(!e&&"u"<typeof fetch)throw(0,r.newInvariantError)(40)}},79760(e,t,a){a.d(t,{$:()=>_});var r=a(85608),i=a(70916),n=a(19074),p=a(82307),o=a(36054),s=a(63647),d=a(33068),l=a(90117),u=a(67195),c=a(74559),m=a(11151),f=a(93161),h=a(70783),v=a(53925),y=a(3777),g=(0,i.maybe)(function(){return fetch}),_=function(e){void 0===e&&(e={});var t=e.uri,a=void 0===t?"/graphql":t,_=e.fetch,b=e.print,w=void 0===b?c.i1:b,E=e.includeExtensions,T=e.preserveHeaderCase,N=e.useGETForQueries,S=e.includeUnusedVariables,O=void 0!==S&&S,I=(0,r.__rest)(e,["uri","fetch","print","includeExtensions","preserveHeaderCase","useGETForQueries","includeUnusedVariables"]);!1!==globalThis.__DEV__&&(0,u.S)(_||g);var D={http:{includeExtensions:E,preserveHeaderCase:T},options:I.fetchOptions,credentials:I.credentials,headers:I.headers};return new n.C(function(e){var t,n,u=(0,d.z)(e,a),b=e.getContext(),E={};if(b.clientAwareness){var T=b.clientAwareness,S=T.name,I=T.version;S&&(E["apollographql-client-name"]=S),I&&(E["apollographql-client-version"]=I)}var A=(0,r.__assign)((0,r.__assign)({},E),b.headers),k={http:b.http,options:b.fetchOptions,credentials:b.credentials,headers:A};if((0,p.d8)(["client"],e.query)){var x=(0,v.er)(e.query);if(!x)return(0,f.N)(Error("HttpLink: Trying to send a client-only query to the server. To send to the server, ensure a non-client field is added to the query or set the `transformOptions.removeClientFields` option to `true`."));e.query=x}var C=(0,c.HY)(e,w,c.R4,D,k),R=C.options,V=C.body;V.variables&&!O&&(V.variables=(0,h.X)(V.variables,e.query)),!R.signal&&"u">typeof AbortController&&(R.signal=(n=new AbortController).signal);var F="OperationDefinition"===(t=(0,y.Vn)(e.query)).kind&&"subscription"===t.operation,$=(0,p.d8)(["defer"],e.query);if(N&&!e.query.definitions.some(function(e){return"OperationDefinition"===e.kind&&"mutation"===e.operation})&&(R.method="GET"),$||F){R.headers=R.headers||{};var P="multipart/mixed;";F&&$&&!1!==globalThis.__DEV__&&i.invariant.warn(41),F?P+="boundary=graphql;subscriptionSpec=1.0,application/json":$&&(P+="deferSpec=20220824,application/json"),R.headers.accept=P}if("GET"===R.method){var L=(0,m.E)(u,V),j=L.newURI,M=L.parseError;if(M)return(0,f.N)(M);u=j}else try{R.body=(0,s.Y)(V,"Payload")}catch(e){return(0,f.N)(e)}return new o.c(function(t){var a=_||(0,i.maybe)(function(){return fetch})||g,r=t.next.bind(t);return a(u,R).then(function(t){e.setContext({response:t});var a,i=null==(a=t.headers)?void 0:a.get("content-type");return null!==i&&/^multipart\/mixed/i.test(i)?(0,l.tD)(t,r):(0,l.OQ)(e)(t).then(r)}).then(function(){n=void 0,t.complete()}).catch(function(e){n=void 0,(0,l.H4)(e,t)}),function(){n&&n.abort()}})})}},28876(e,t,a){a.r(t),a.d(t,{HttpLink:()=>l.P,parseAndCheckHttpResponse:()=>r.OQ,checkFetcher:()=>p.S,rewriteURIForGET:()=>u.E,serializeFetchParameter:()=>i.Y,createSignalIfSupported:()=>o,selectHttpOptionsAndBodyInternal:()=>n.HY,selectHttpOptionsAndBody:()=>n.Wz,selectURI:()=>s.z,fallbackHttpConfig:()=>n.R4,createHttpLink:()=>d.$,defaultPrinter:()=>n.i1}),a(70916);var r=a(90117),i=a(63647),n=a(74559),p=a(67195),o=function(){if("u"<typeof AbortController)return{controller:!1,signal:!1};var e=new AbortController,t=e.signal;return{controller:e,signal:t}},s=a(33068),d=a(79760),l=a(49952),u=a(11151)},90117(e,t,a){a.d(t,{H4:()=>c,OQ:()=>m,tD:()=>l});var r=a(85608),i=a(51360);function n(e){var t={next:function(){return e.read()}};return i.uJ&&(t[Symbol.asyncIterator]=function(){return this}),t}var p=a(3848),o=a(53570),s=a(37396),d=Object.prototype.hasOwnProperty;function l(e,t){return(0,r.__awaiter)(this,void 0,void 0,function(){var a,p,d,l,c,m,f,h,v,y,g,_,b,w,E,T,N,S,O,I,D,A,k;return(0,r.__generator)(this,function(x){switch(x.label){case 0:if(void 0===TextDecoder)throw Error("TextDecoder must be defined in the environment: please import a polyfill.");a=new TextDecoder("utf-8"),p=null==(k=e.headers)?void 0:k.get("content-type"),d="boundary=",l=(null==p?void 0:p.includes(d))?null==p?void 0:p.substring((null==p?void 0:p.indexOf(d))+d.length).replace(/['"]/g,"").replace(/\;(.*)/gm,"").trim():"-",c="\r\n--".concat(l),m="",f=function(e){var t,a,r,p,o,s,d=e;if(e.body&&(d=e.body),t=d,i.uJ&&t[Symbol.asyncIterator])return r=d[Symbol.asyncIterator](),(a={next:function(){return r.next()}})[Symbol.asyncIterator]=function(){return this},a;if(d.getReader)return n(d.getReader());if(d.stream)return n(d.stream().getReader());if(d.arrayBuffer)return p=d.arrayBuffer(),o=!1,s={next:function(){return o?Promise.resolve({value:void 0,done:!0}):(o=!0,new Promise(function(e,t){p.then(function(t){e({value:t,done:!1})}).catch(t)}))}},i.uJ&&(s[Symbol.asyncIterator]=function(){return this}),s;if(d.pipe)return function(e){var t=null,a=null,r=!1,n=[],p=[];function o(e){if(!a){if(p.length){var t=p.shift();if(Array.isArray(t)&&t[0])return t[0]({value:e,done:!1})}n.push(e)}}function s(e){a=e,p.slice().forEach(function(t){t[1](e)}),t&&t()}function d(){r=!0,p.slice().forEach(function(e){e[0]({value:void 0,done:!0})}),t&&t()}t=function(){t=null,e.removeListener("data",o),e.removeListener("error",s),e.removeListener("end",d),e.removeListener("finish",d),e.removeListener("close",d)},e.on("data",o),e.on("error",s),e.on("end",d),e.on("finish",d),e.on("close",d);var l={next:function(){return new Promise(function(e,t){return a?t(a):n.length?e({value:n.shift(),done:!1}):r?e({value:void 0,done:!0}):void p.push([e,t])})}};return i.uJ&&(l[Symbol.asyncIterator]=function(){return this}),l}(d);throw Error("Unknown body type for responseIterator. Please pass a streamable response.")}(e),h=!0,x.label=1;case 1:if(!h)return[3,3];return[4,f.next()];case 2:for(y=(v=x.sent()).value,g=v.done,_="string"==typeof y?y:a.decode(y),b=m.length-c.length+1,h=!g,m+=_,w=m.indexOf(c,b);w>-1;){if(E=void 0,E=(D=[m.slice(0,w),m.slice(w+c.length)])[0],m=D[1],T=E.indexOf("\r\n\r\n"),(N=function(e){var t={};return e.split("\n").forEach(function(e){var a=e.indexOf(":");if(a>-1){var r=e.slice(0,a).trim().toLowerCase(),i=e.slice(a+1).trim();t[r]=i}}),t}(E.slice(0,T))["content-type"])&&-1===N.toLowerCase().indexOf("application/json"))throw Error("Unsupported patch content type: application/json is required.");if(S=E.slice(T)){if(Object.keys(O=u(e,S)).length>1||"data"in O||"incremental"in O||"errors"in O||"payload"in O)if((0,s.Nw)(O)){if(I={},"payload"in O){if(1===Object.keys(O).length&&null===O.payload)return[2];I=(0,r.__assign)({},O.payload)}"errors"in O&&(I=(0,r.__assign)((0,r.__assign)({},I),{extensions:(0,r.__assign)((0,r.__assign)({},"extensions"in I?I.extensions:null),((A={})[o.PROTOCOL_ERRORS_SYMBOL]=O.errors,A))})),t(I)}else t(O);else if(1===Object.keys(O).length&&"hasNext"in O&&!O.hasNext)return[2]}w=m.indexOf(c)}return[3,1];case 3:return[2]}})})}function u(e,t){e.status>=300&&(0,p.A)(e,function(){try{return JSON.parse(t)}catch(e){return t}}(),"Response not successful: Received status code ".concat(e.status));try{return JSON.parse(t)}catch(a){throw a.name="ServerParseError",a.response=e,a.statusCode=e.status,a.bodyText=t,a}}function c(e,t){e.result&&e.result.errors&&e.result.data&&t.next(e.result),t.error(e)}function m(e){return function(t){return t.text().then(function(e){return u(t,e)}).then(function(a){return Array.isArray(a)||d.call(a,"data")||d.call(a,"errors")||(0,p.A)(t,a,"Server response was missing for query '".concat(Array.isArray(e)?e.map(function(e){return e.operationName}):e.operationName,"'.")),a})}}},11151(e,t,a){a.d(t,{E:()=>i});var r=a(63647);function i(e,t){var a=[],i=function(e,t){a.push("".concat(e,"=").concat(encodeURIComponent(t)))};if("query"in t&&i("query",t.query),t.operationName&&i("operationName",t.operationName),t.variables){var n=void 0;try{n=(0,r.Y)(t.variables,"Variables map")}catch(e){return{parseError:e}}i("variables",n)}if(t.extensions){var p=void 0;try{p=(0,r.Y)(t.extensions,"Extensions map")}catch(e){return{parseError:e}}i("extensions",p)}var o="",s=e,d=e.indexOf("#");-1!==d&&(o=e.substr(d),s=e.substr(0,d));var l=-1===s.indexOf("?")?"?":"&";return{newURI:s+l+a.join("&")+o}}},74559(e,t,a){a.d(t,{HY:()=>s,R4:()=>n,Wz:()=>o,i1:()=>p});var r=a(85608),i=a(38678),n={http:{includeQuery:!0,includeExtensions:!1,preserveHeaderCase:!1},headers:{accept:"*/*","content-type":"application/json"},options:{method:"POST"}},p=function(e,t){return t(e)};function o(e,t){for(var a=[],i=2;i<arguments.length;i++)a[i-2]=arguments[i];return a.unshift(t),s.apply(void 0,(0,r.__spreadArray)([e,p],a,!1))}function s(e,t){for(var a=[],n=2;n<arguments.length;n++)a[n-2]=arguments[n];var p={},o={};a.forEach(function(e){p=(0,r.__assign)((0,r.__assign)((0,r.__assign)({},p),e.options),{headers:(0,r.__assign)((0,r.__assign)({},p.headers),e.headers)}),e.credentials&&(p.credentials=e.credentials),o=(0,r.__assign)((0,r.__assign)({},o),e.http)}),p.headers&&(p.headers=function(e,t){if(!t){var a={};return Object.keys(Object(e)).forEach(function(t){a[t.toLowerCase()]=e[t]}),a}var r={};Object.keys(Object(e)).forEach(function(t){r[t.toLowerCase()]={originalName:t,value:e[t]}});var i={};return Object.keys(r).forEach(function(e){i[r[e].originalName]=r[e].value}),i}(p.headers,o.preserveHeaderCase));var s=e.operationName,d=e.extensions,l=e.variables,u=e.query,c={operationName:s,variables:l};return o.includeExtensions&&(c.extensions=d),o.includeQuery&&(c.query=t(u,i.y)),{options:p,body:c}}},33068(e,t,a){a.d(t,{z:()=>r});var r=function(e,t){var a=e.getContext().uri;return a||("function"==typeof t?t(e):t||"/graphql")}},63647(e,t,a){a.d(t,{Y:()=>i});var r=a(70916),i=function(e,t){var a;try{a=JSON.stringify(e)}catch(e){var i=(0,r.newInvariantError)(42,t,e.message);throw i.parseError=e,i}return a}},16878(e,t,a){a.d(t,{k:()=>i});var r=a(85608);function i(e,t){var a=(0,r.__assign)({},e);return Object.defineProperty(t,"setContext",{enumerable:!1,value:function(e){a="function"==typeof e?(0,r.__assign)((0,r.__assign)({},a),e(a)):(0,r.__assign)((0,r.__assign)({},a),e)}}),Object.defineProperty(t,"getContext",{enumerable:!1,value:function(){return(0,r.__assign)({},a)}}),t}},70783(e,t,a){a.d(t,{X:()=>n});var r=a(85608),i=a(90424);function n(e,t){var a=(0,r.__assign)({},e),n=new Set(Object.keys(e));return(0,i.YR)(t,{Variable:function(e,t,a){a&&"VariableDefinition"!==a.kind&&n.delete(e.name.value)}}),n.forEach(function(e){delete a[e]}),a}},93161(e,t,a){a.d(t,{N:()=>i});var r=a(36054);function i(e){return new r.c(function(t){t.error(e)})}},22594(e,t,a){a.d(t,{S:()=>i});var r=a(36054);function i(e){return new r.c(function(t){e.then(function(e){t.next(e),t.complete()}).catch(t.error.bind(t))})}},25979(e,t,a){a.r(t),a.d(t,{createOperation:()=>s.k,filterOperationVariables:()=>l.X,fromError:()=>r.N,fromPromise:()=>n.S,throwServerError:()=>p.A,toPromise:()=>i.h,transformOperation:()=>d.A,validateOperation:()=>o.K}),a(70916);var r=a(93161),i=a(60441),n=a(22594),p=a(3848),o=a(46192),s=a(16878),d=a(38414),l=a(70783)},3848(e,t,a){a.d(t,{A:()=>r});var r=function(e,t,a){var r=Error(a);throw r.name="ServerError",r.response=e,r.statusCode=e.status,r.result=t,r}},60441(e,t,a){a.d(t,{h:()=>i});var r=a(70916);function i(e){var t=!1;return new Promise(function(a,i){e.subscribe({next:function(e){t?!1!==globalThis.__DEV__&&r.invariant.warn(45):(t=!0,a(e))},error:i})})}},38414(e,t,a){a.d(t,{A:()=>i});var r=a(3777);function i(e){var t={variables:e.variables||{},extensions:e.extensions||{},operationName:e.operationName,query:e.query};return t.operationName||(t.operationName="string"!=typeof t.query?(0,r.n4)(t.query)||void 0:""),t}},46192(e,t,a){a.d(t,{K:()=>i});var r=a(70916);function i(e){for(var t=["query","operationName","variables","extensions","context"],a=0,i=Object.keys(e);a<i.length;a++){var n=i[a];if(0>t.indexOf(n))throw(0,r.newInvariantError)(46,n)}return e}},39283(e,t,a){a.r(t),a.d(t,{disableWarningsSlot:()=>r.yV,maskFragment:()=>i.z,maskOperation:()=>n.m});var r=a(47150),i=a(62959),n=a(28354)},25186(e,t,a){a.d(t,{S:()=>d});var r=a(42455),i=a(57236),n=a(28907),p=a(82307),o=a(47150),s=a(70916);function d(e,t,a){return o.yV.withValue(!0,function(){var d=function e(t,a,i,d,l){var u,c=i.knownChanged,m=function(e,t){if(t.has(e))return t.get(e);var a=Array.isArray(e)?[]:Object.create(null);return t.set(e,a),a}(t,i.mutableTargets);if(Array.isArray(t)){for(var f=0,h=Array.from(t.entries());f<h.length;f++){var v=h[f],y=v[0],g=v[1];if(null===g){m[y]=null;continue}var _=e(g,a,i,d,!1!==globalThis.__DEV__?"".concat(l||"","[").concat(y,"]"):void 0);c.has(_)&&c.add(m),m[y]=_}return c.has(m)?m:t}for(var b=0,w=a.selections;b<w.length;b++){var E=w[b],T=void 0;if(d&&c.add(m),E.kind===r.b.FIELD){var N=(0,n.ue)(E),S=E.selectionSet;if(void 0===(T=m[N]||t[N]))continue;if(S&&null!==T){var _=e(t[N],S,i,d,!1!==globalThis.__DEV__?"".concat(l||"",".").concat(N):void 0);c.has(_)&&(T=_)}!1===globalThis.__DEV__&&(m[N]=T),!1!==globalThis.__DEV__&&(!d||"__typename"===N||(null==(u=Object.getOwnPropertyDescriptor(m,N))?void 0:u.value)?(delete m[N],m[N]=T):Object.defineProperty(m,N,function(e,t,a,r,i){var n=function(){return o.yV.getValue()||(!1!==globalThis.__DEV__&&s.invariant.warn(48,r?"".concat(i," '").concat(r,"'"):"anonymous ".concat(i),"".concat(a,".").concat(e).replace(/^\./,"")),n=function(){return t}),t};return{get:function(){return n()},set:function(e){n=function(){return e}},enumerable:!0,configurable:!0}}(N,T,l||"",i.operationName,i.operationType)))}if(E.kind===r.b.INLINE_FRAGMENT&&(!E.typeCondition||i.cache.fragmentMatches(E,t.__typename))&&(T=e(t,E.selectionSet,i,d,l)),E.kind===r.b.FRAGMENT_SPREAD){var O=E.name.value,I=i.fragmentMap[O]||(i.fragmentMap[O]=i.cache.lookupFragment(O));(0,s.invariant)(I,47,O);var D=(0,p.s7)(E);"mask"!==D&&(T=e(t,I.selectionSet,i,"migrate"===D,l))}c.has(T)&&c.add(m)}return"__typename"in t&&!("__typename"in m)&&(m.__typename=t.__typename),Object.keys(m).length!==Object.keys(t).length&&c.add(m),c.has(m)?m:t}(e,t,a,!1);return Object.isFrozen(e)&&(0,i.G)(d),d})}},62959(e,t,a){a.d(t,{z:()=>l});var r=a(42455),i=a(47150),n=a(70916),p=a(55888),o=a(25186),s=a(2904),d=a(3777);function l(e,t,a,l){if(!a.fragmentMatches)return!1!==globalThis.__DEV__&&(0,i.Ki)(),e;var u=t.definitions.filter(function(e){return e.kind===r.b.FRAGMENT_DEFINITION});void 0===l&&((0,n.invariant)(1===u.length,49,u.length),l=u[0].name.value);var c=u.find(function(e){return e.name.value===l});return((0,n.invariant)(!!c,50,l),null==e||(0,p.default)(e,{}))?e:(0,o.S)(e,c.selectionSet,{operationType:"fragment",operationName:c.name.value,fragmentMap:(0,s.JG)((0,d.zK)(t)),cache:a,mutableTargets:new i.jq,knownChanged:new i.xm})}},28354(e,t,a){a.d(t,{m:()=>s});var r=a(70916),i=a(3777),n=a(2904),p=a(25186),o=a(47150);function s(e,t,a){if(!a.fragmentMatches)return!1!==globalThis.__DEV__&&(0,o.Ki)(),e;var s,d=(0,i.Vu)(t);return((0,r.invariant)(d,51),null==e)?e:(0,p.S)(e,d.selectionSet,{operationType:d.operation,operationName:null==(s=d.name)?void 0:s.value,fragmentMap:(0,n.JG)((0,i.zK)(t)),cache:a,mutableTargets:new o.jq,knownChanged:new o.xm})}},47150(e,t,a){a.d(t,{Ki:()=>l,jq:()=>p,xm:()=>o,yV:()=>s});var r=a(60837),i=a(70916),n=a(51360),p=n.et?WeakMap:Map,o=n.En?WeakSet:Set,s=new r.Slot,d=!1;function l(){d||(d=!0,!1!==globalThis.__DEV__&&i.invariant.warn(52))}},45078(e,t,a){a.d(t,{A:()=>o,V:()=>s});var r=a(54019),i=a(31088),n=new WeakSet;function p(e){!(e.size<=(e.max||-1))&&(n.has(e)||(n.add(e),setTimeout(function(){e.clean(),n.delete(e)},100)))}var o=function(e,t){var a=new r.l(e,t);return a.set=function(e,t){var a=r.l.prototype.set.call(this,e,t);return p(this),a},a},s=function(e,t){var a=new i.C(e,t);return a.set=function(e,t){var a=i.C.prototype.set.call(this,e,t);return p(this),a},a}},44114(e,t,a){a.d(t,{D_:()=>p,cM:()=>s,ep:()=>o,tQ:()=>d});var r=a(85608),i=a(555),n={};function p(e,t){n[e]=t}var o=!1!==globalThis.__DEV__?function(){var e,t,a,p,o;if(!1===globalThis.__DEV__)throw Error("only supported in development mode");return{limits:Object.fromEntries(Object.entries({parser:1e3,canonicalStringify:1e3,print:2e3,"documentTransform.cache":2e3,"queryManager.getDocumentInfo":2e3,"PersistedQueryLink.persistedQueryHashes":2e3,"fragmentRegistry.transform":2e3,"fragmentRegistry.lookup":1e3,"fragmentRegistry.findFragmentSpreads":4e3,"cache.fragmentQueryDocuments":1e3,"removeTypenameFromVariables.getVariableDefinitions":2e3,"inMemoryCache.maybeBroadcastWatch":5e3,"inMemoryCache.executeSelectionSet":5e4,"inMemoryCache.executeSubSelectedArray":1e4}).map(function(e){var t=e[0],a=e[1];return[t,i.v[t]||a]})),sizes:(0,r.__assign)({print:null==(e=n.print)?void 0:e.call(n),parser:null==(t=n.parser)?void 0:t.call(n),canonicalStringify:null==(a=n.canonicalStringify)?void 0:a.call(n),links:function e(t){var a;return t?(0,r.__spreadArray)((0,r.__spreadArray)([null==(a=null==t?void 0:t.getMemoryInternals)?void 0:a.call(t)],e(null==t?void 0:t.left),!0),e(null==t?void 0:t.right),!0).filter(c):[]}(this.link),queryManager:{getDocumentInfo:this.queryManager.transformCache.size,documentTransforms:m(this.queryManager.documentTransform)}},null==(o=(p=this.cache).getMemoryInternals)?void 0:o.call(p))}}:void 0,s=!1!==globalThis.__DEV__?function(){var e=this.config.fragments;return(0,r.__assign)((0,r.__assign)({},l.apply(this)),{addTypenameDocumentTransform:m(this.addTypenameTransform),inMemoryCache:{executeSelectionSet:u(this.storeReader.executeSelectionSet),executeSubSelectedArray:u(this.storeReader.executeSubSelectedArray),maybeBroadcastWatch:u(this.maybeBroadcastWatch)},fragmentRegistry:{findFragmentSpreads:u(null==e?void 0:e.findFragmentSpreads),lookup:u(null==e?void 0:e.lookup),transform:u(null==e?void 0:e.transform)}})}:void 0,d=!1!==globalThis.__DEV__?l:void 0;function l(){return{cache:{fragmentQueryDocuments:u(this.getFragmentDoc)}}}function u(e){return e&&"dirtyKey"in e?e.size:void 0}function c(e){return null!=e}function m(e){return(function e(t){return t?(0,r.__spreadArray)((0,r.__spreadArray)([u(null==t?void 0:t.performWork)],e(null==t?void 0:t.left),!0),e(null==t?void 0:t.right),!0).filter(c):[]})(e).map(function(e){return{cache:e}})}},555(e,t,a){a.d(t,{v:()=>p});var r=a(85608),i=a(70916),n=Symbol.for("apollo.cacheSize"),p=(0,r.__assign)({},i.global[n])},73767(e,t,a){a.d(t,{E:()=>i,c:()=>r});var r=Array.isArray;function i(e){return Array.isArray(e)&&e.length>0}},51360(e,t,a){a.d(t,{En:()=>p,JR:()=>u,Sw:()=>d,et:()=>n,ol:()=>o,uJ:()=>s});var r=a(70916),i="ReactNative"==(0,r.maybe)(function(){return navigator.product}),n="function"==typeof WeakMap&&!(i&&!global.HermesInternal),p="function"==typeof WeakSet,o="function"==typeof Symbol&&"function"==typeof Symbol.for,s=o&&Symbol.asyncIterator,d="function"==typeof(0,r.maybe)(function(){return window.document.createElement}),l=(0,r.maybe)(function(){return navigator.userAgent.indexOf("jsdom")>=0})||!1,u=(d||i)&&!l},44214(e,t,a){a.d(t,{M:()=>o});var r,i=a(45078),n=a(555),p=a(44114),o=Object.assign(function(e){return JSON.stringify(e,s)},{reset:function(){r=new i.V(n.v.canonicalStringify||1e3)}});function s(e,t){if(t&&"object"==typeof t){var a=Object.getPrototypeOf(t);if(a===Object.prototype||null===a){var i=Object.keys(t);if(i.every(d))return t;var n=JSON.stringify(i),p=r.get(n);if(!p){i.sort();var o=JSON.stringify(i);p=r.get(o)||i,r.set(n,p),r.set(o,p)}var s=Object.create(a);return p.forEach(function(e){s[e]=t[e]}),s}}return t}function d(e,t,a){return 0===t||a[t-1]<=e}!1!==globalThis.__DEV__&&(0,p.D_)("canonicalStringify",function(){return r.size}),o.reset()},20906(e,t,a){a.d(t,{m:()=>i});var r=Object.prototype.toString;function i(e){return function e(t,a){switch(r.call(t)){case"[object Array]":if((a=a||new Map).has(t))return a.get(t);var i=t.slice(0);return a.set(t,i),i.forEach(function(t,r){i[r]=e(t,a)}),i;case"[object Object]":if((a=a||new Map).has(t))return a.get(t);var n=Object.create(Object.getPrototypeOf(t));return a.set(t,n),Object.keys(t).forEach(function(r){n[r]=e(t[r],a)}),n;default:return t}}(e)}},50492(e,t,a){a.d(t,{o:()=>r});function r(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var a=Object.create(null);return e.forEach(function(e){e&&Object.keys(e).forEach(function(t){var r=e[t];void 0!==r&&(a[t]=r)})}),a}},32710(e,t,a){a.d(t,{M:()=>p,t:()=>n});var r=a(73767),i=a(37396);function n(e){var t=p(e);return(0,r.E)(t)}function p(e){var t=(0,r.E)(e.errors)?e.errors.slice(0):[];return(0,i.ST)(e)&&(0,r.E)(e.incremental)&&e.incremental.forEach(function(e){e.errors&&t.push.apply(t,e.errors)}),t}},37396(e,t,a){a.d(t,{EQ:()=>o,Nw:()=>d,ST:()=>p,YX:()=>s,bd:()=>l});var r=a(21777),i=a(73767),n=a(30671);function p(e){return"incremental"in e}function o(e){return"hasNext"in e&&"data"in e}function s(e){return p(e)||o(e)}function d(e){return(0,r.U)(e)&&"payload"in e}function l(e,t){var a=e,r=new n.ZI;return p(t)&&(0,i.E)(t.incremental)&&t.incremental.forEach(function(e){for(var t=e.data,i=e.path,n=i.length-1;n>=0;--n){var p=i[n],o=isNaN(+p)?{}:[];o[p]=t,t=o}a=r.merge(a,t)}),a}},21461(e,t,a){a.d(t,{v:()=>i});var r=new Map;function i(e){var t=r.get(e)||1;return r.set(e,t+1),"".concat(e,":").concat(t,":").concat(Math.random().toString(36).slice(2))}},57236(e,t,a){a.d(t,{G:()=>i});var r=a(21777);function i(e){var t;return!1!==globalThis.__DEV__&&(t=new Set([e])).forEach(function(e){(0,r.U)(e)&&function(e){if(!1!==globalThis.__DEV__&&!Object.isFrozen(e))try{Object.freeze(e)}catch(e){if(e instanceof TypeError)return null;throw e}return e}(e)===e&&Object.getOwnPropertyNames(e).forEach(function(a){(0,r.U)(e[a])&&t.add(e[a])})}),e}},30671(e,t,a){a.d(t,{D9:()=>p,IM:()=>o,ZI:()=>d});var r=a(85608),i=a(21777),n=Object.prototype.hasOwnProperty;function p(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return o(e)}function o(e){var t=e[0]||{},a=e.length;if(a>1)for(var r=new d,i=1;i<a;++i)t=r.merge(t,e[i]);return t}var s=function(e,t,a){return this.merge(e[a],t[a])},d=function(){function e(e){void 0===e&&(e=s),this.reconciler=e,this.isObject=i.U,this.pastCopies=new Set}return e.prototype.merge=function(e,t){for(var a=this,p=[],o=2;o<arguments.length;o++)p[o-2]=arguments[o];return(0,i.U)(t)&&(0,i.U)(e)?(Object.keys(t).forEach(function(i){if(n.call(e,i)){var o=e[i];if(t[i]!==o){var s=a.reconciler.apply(a,(0,r.__spreadArray)([e,t,i],p,!1));s!==o&&((e=a.shallowCopyForMerge(e))[i]=s)}}else(e=a.shallowCopyForMerge(e))[i]=t[i]}),e):t},e.prototype.shallowCopyForMerge=function(e){return(0,i.U)(e)&&!this.pastCopies.has(e)&&(e=Array.isArray(e)?e.slice(0):(0,r.__assign)({__proto__:Object.getPrototypeOf(e)},e),this.pastCopies.add(e)),e},e}()},31507(e,t,a){a.d(t,{l:()=>n});var r=a(85608),i=a(50492);function n(e,t){return(0,i.o)(e,t,t.variables&&{variables:(0,i.o)((0,r.__assign)((0,r.__assign)({},e&&e.variables),t.variables))})}},21777(e,t,a){function r(e){return null!==e&&"object"==typeof e}function i(e){return null!==e&&"object"==typeof e&&(Object.getPrototypeOf(e)===Object.prototype||null===Object.getPrototypeOf(e))}a.d(t,{Q:()=>i,U:()=>r})},86563(e,t,a){a.d(t,{p:()=>i});var r=a(21461);function i(e,t){void 0===t&&(t=0);var a=(0,r.v)("stringifyForDisplay");return JSON.stringify(e,function(e,t){return void 0===t?a:t},t).split(JSON.stringify(a)).join("<undefined>")}},70916(e,t,a){a.r(t),a.d(t,{invariant:()=>d,__DEV__:()=>h,DEV:()=>h,global:()=>p,InvariantError:()=>r.InvariantError,newInvariantError:()=>l,maybe:()=>n});var r=a(19371),i=a(73972);function n(e){try{return e()}catch(e){}}let p=n(function(){return globalThis})||n(function(){return window})||n(function(){return self})||n(function(){return global})||n(function(){return n.constructor("return this")()});var o=a(86563);function s(e){return function(t){for(var a=[],r=1;r<arguments.length;r++)a[r-1]=arguments[r];if("number"==typeof t){var i=t;(t=m(i))||(t=f(i,a),a=[])}e.apply(void 0,[t].concat(a))}}var d=Object.assign(function(e,t){for(var a=[],i=2;i<arguments.length;i++)a[i-2]=arguments[i];e||(0,r.invariant)(e,m(t,a)||f(t,a))},{debug:s(r.invariant.debug),log:s(r.invariant.log),warn:s(r.invariant.warn),error:s(r.invariant.error)});function l(e){for(var t=[],a=1;a<arguments.length;a++)t[a-1]=arguments[a];return new r.InvariantError(m(e,t)||f(e,t))}var u=Symbol.for("ApolloErrorMessageHandler_"+i.r);function c(e){if("string"==typeof e)return e;try{return(0,o.p)(e,2).slice(0,1e3)}catch(e){return"<non-serializable>"}}function m(e,t){if(void 0===t&&(t=[]),e)return p[u]&&p[u](e,t.map(c))}function f(e,t){if(void 0===t&&(t=[]),e)return"An error occurred! For more details, see the full error text at https://go.apollo.dev/c/err#".concat(encodeURIComponent(JSON.stringify({version:i.r,message:e,args:t.map(c)})))}var h=!1!==globalThis.__DEV__},9354(e,t,a){a.d(t,{c:()=>u});var r=a(44592),i=a(51360),n=a(3777),p=a(70916),o=a(54019),s=a(60837),d=a(555);function l(e){return e}var u=function(){function e(e,t){void 0===t&&(t=Object.create(null)),this.resultCache=i.En?new WeakSet:new Set,this.transform=e,t.getCacheKey&&(this.getCacheKey=t.getCacheKey),this.cached=!1!==t.cache,this.resetCache()}return e.prototype.getCacheKey=function(e){return[e]},e.identity=function(){return new e(l,{cache:!1})},e.split=function(t,a,r){return void 0===r&&(r=e.identity()),Object.assign(new e(function(e){return(t(e)?a:r).transformDocument(e)},{cache:!1}),{left:a,right:r})},e.prototype.resetCache=function(){var t=this;if(this.cached){var a=new r.Trie(i.et);this.performWork=(0,s.wrap)(e.prototype.performWork.bind(this),{makeCacheKey:function(e){var r=t.getCacheKey(e);if(r)return(0,p.invariant)(Array.isArray(r),77),a.lookupArray(r)},max:d.v["documentTransform.cache"],cache:o.l})}},e.prototype.performWork=function(e){return(0,n.sw)(e),this.transform(e)},e.prototype.transformDocument=function(e){if(this.resultCache.has(e))return e;var t=this.performWork(e);return this.resultCache.add(t),t},e.prototype.concat=function(t){var a=this;return Object.assign(new e(function(e){return t.transformDocument(a.transformDocument(e))},{cache:!1}),{left:this,right:t})},e}()},82307(e,t,a){a.d(t,{I5:()=>d,MS:()=>p,d8:()=>l,f2:()=>u,hE:()=>s,s7:()=>m,sx:()=>o,tY:()=>c});var r=a(70916),i=a(90424),n=a(42455);function p(e,t){var a=e.directives;return!a||!a.length||c(a).every(function(e){var a=e.directive,i=e.ifArgument,n=!1;return"Variable"===i.value.kind?(n=t&&t[i.value.name.value],(0,r.invariant)(void 0!==n,78,a.name.value)):n=i.value.value,"skip"===a.name.value?!n:n})}function o(e){var t=[];return(0,i.YR)(e,{Directive:function(e){t.push(e.name.value)}}),t}var s=function(e,t){return l(e,t,!1)},d=function(e,t){return l(e,t,!0)};function l(e,t,a){var r=new Set(e),n=r.size;return(0,i.YR)(t,{Directive:function(e){if(r.delete(e.name.value)&&(!a||!r.size))return i.sP}}),a?!r.size:r.size<n}function u(e){return e&&l(["client","export"],e,!0)}function c(e){var t=[];return e&&e.length&&e.forEach(function(e){if("skip"===(a=e.name.value)||"include"===a){var a,i=e.arguments,n=e.name.value;(0,r.invariant)(i&&1===i.length,79,n);var p=i[0];(0,r.invariant)(p.name&&"if"===p.name.value,80,n);var o=p.value;(0,r.invariant)(o&&("Variable"===o.kind||"BooleanValue"===o.kind),81,n),t.push({directive:e,ifArgument:p})}}),t}function m(e){var t,a,i=null==(t=e.directives)?void 0:t.find(function(e){return"unmask"===e.name.value});if(!i)return"mask";var p=null==(a=i.arguments)?void 0:a.find(function(e){return"mode"===e.name.value});return(!1!==globalThis.__DEV__&&p&&(p.value.kind===n.b.VARIABLE?!1!==globalThis.__DEV__&&r.invariant.warn(82):p.value.kind!==n.b.STRING?!1!==globalThis.__DEV__&&r.invariant.warn(83):"migrate"!==p.value.value&&!1!==globalThis.__DEV__&&r.invariant.warn(84,p.value.value)),p&&"value"in p.value&&"migrate"===p.value.value)?"migrate":"unmask"}},2904(e,t,a){a.d(t,{HQ:()=>s,JG:()=>o,ct:()=>p,s6:()=>d});var r=a(85608),i=a(70916),n=a(90424);function p(e,t){var a=t,n=[];return e.definitions.forEach(function(e){if("OperationDefinition"===e.kind)throw(0,i.newInvariantError)(85,e.operation,e.name?" named '".concat(e.name.value,"'"):"");"FragmentDefinition"===e.kind&&n.push(e)}),void 0===a&&((0,i.invariant)(1===n.length,86,n.length),a=n[0].name.value),(0,r.__assign)((0,r.__assign)({},e),{definitions:(0,r.__spreadArray)([{kind:"OperationDefinition",operation:"query",selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:a}}]}}],e.definitions,!0)})}function o(e){void 0===e&&(e=[]);var t={};return e.forEach(function(e){t[e.name.value]=e}),t}function s(e,t){switch(e.kind){case"InlineFragment":return e;case"FragmentSpread":var a=e.name.value;if("function"==typeof t)return t(a);var r=t&&t[a];return(0,i.invariant)(r,87,a),r||null;default:return null}}function d(e){var t=!0;return(0,n.YR)(e,{FragmentSpread:function(e){if(!(t=!!e.directives&&e.directives.some(function(e){return"unmask"===e.name.value})))return n.sP}}),t}},3777(e,t,a){a.d(t,{AT:()=>d,E4:()=>l,Vn:()=>u,Vu:()=>p,n4:()=>o,sw:()=>n,wY:()=>c,zK:()=>s});var r=a(70916),i=a(28907);function n(e){(0,r.invariant)(e&&"Document"===e.kind,88);var t=e.definitions.filter(function(e){return"FragmentDefinition"!==e.kind}).map(function(e){if("OperationDefinition"!==e.kind)throw(0,r.newInvariantError)(89,e.kind);return e});return(0,r.invariant)(t.length<=1,90,t.length),e}function p(e){return n(e),e.definitions.filter(function(e){return"OperationDefinition"===e.kind})[0]}function o(e){return e.definitions.filter(function(e){return"OperationDefinition"===e.kind&&!!e.name}).map(function(e){return e.name.value})[0]||null}function s(e){return e.definitions.filter(function(e){return"FragmentDefinition"===e.kind})}function d(e){var t=p(e);return(0,r.invariant)(t&&"query"===t.operation,91),t}function l(e){(0,r.invariant)("Document"===e.kind,92),(0,r.invariant)(e.definitions.length<=1,93);var t=e.definitions[0];return(0,r.invariant)("FragmentDefinition"===t.kind,94),t}function u(e){n(e);for(var t,a=0,i=e.definitions;a<i.length;a++){var p=i[a];if("OperationDefinition"===p.kind){var o=p.operation;if("query"===o||"mutation"===o||"subscription"===o)return p}"FragmentDefinition"!==p.kind||t||(t=p)}if(t)return t;throw(0,r.newInvariantError)(95)}function c(e){var t=Object.create(null),a=e&&e.variableDefinitions;return a&&a.length&&a.forEach(function(e){e.defaultValue&&(0,i.J)(t,e.variable.name,e.defaultValue)}),t}},38678(e,t,a){a.d(t,{y:()=>s});var r,i=a(95818),n=a(45078),p=a(555),o=a(44114),s=Object.assign(function(e){var t=r.get(e);return t||(t=(0,i.y)(e),r.set(e,t)),t},{reset:function(){r=new n.A(p.v.print||2e3)}});s.reset(),!1!==globalThis.__DEV__&&(0,o.D_)("print",function(){return r?r.size:0})},28907(e,t,a){a.d(t,{A_:()=>s,D$:()=>function e(t,a,r){for(var i,p=0,o=a.selections;p<o.length;p++){var s=o[p];if(y(s)){if("__typename"===s.name.value)return t[v(s)]}else i?i.push(s):i=[s]}if("string"==typeof t.__typename)return t.__typename;if(i)for(var d=0,l=i;d<l.length;d++){var s=l[d],u=e(t,(0,n.HQ)(s,r).selectionSet,r);if("string"==typeof u)return u}},Ii:()=>u,J:()=>l,Kc:()=>d,MB:()=>h,WU:()=>o,dt:()=>y,kd:()=>g,o5:()=>f,ue:()=>v});var r=a(70916),i=a(21777),n=a(2904),p=a(44214);function o(e){return{__ref:String(e)}}function s(e){return!!(e&&"object"==typeof e&&"string"==typeof e.__ref)}function d(e){return(0,i.U)(e)&&"Document"===e.kind&&Array.isArray(e.definitions)}function l(e,t,a,i){if("IntValue"===a.kind||"FloatValue"===a.kind)e[t.value]=Number(a.value);else if("BooleanValue"===a.kind||"StringValue"===a.kind)e[t.value]=a.value;else if("ObjectValue"===a.kind){var n={};a.fields.map(function(e){return l(n,e.name,e.value,i)}),e[t.value]=n}else if("Variable"===a.kind){var p=(i||{})[a.name.value];e[t.value]=p}else if("ListValue"===a.kind)e[t.value]=a.values.map(function(e){var a={};return l(a,t,e,i),a[t.value]});else if("EnumValue"===a.kind)e[t.value]=a.value;else if("NullValue"===a.kind)e[t.value]=null;else throw(0,r.newInvariantError)(96,t.value,a.kind)}function u(e,t){var a=null;e.directives&&(a={},e.directives.forEach(function(e){a[e.name.value]={},e.arguments&&e.arguments.forEach(function(r){var i=r.name,n=r.value;return l(a[e.name.value],i,n,t)})}));var r=null;return e.arguments&&e.arguments.length&&(r={},e.arguments.forEach(function(e){var a=e.name,i=e.value;return l(r,a,i,t)})),f(e.name.value,r,a)}var c=["connection","include","skip","client","rest","export","nonreactive"],m=p.M,f=Object.assign(function(e,t,a){if(t&&a&&a.connection&&a.connection.key)if(!a.connection.filter||!(a.connection.filter.length>0))return a.connection.key;else{var r=a.connection.filter?a.connection.filter:[];r.sort();var i={};return r.forEach(function(e){i[e]=t[e]}),"".concat(a.connection.key,"(").concat(m(i),")")}var n=e;if(t){var p=m(t);n+="(".concat(p,")")}return a&&Object.keys(a).forEach(function(e){-1===c.indexOf(e)&&(a[e]&&Object.keys(a[e]).length?n+="@".concat(e,"(").concat(m(a[e]),")"):n+="@".concat(e))}),n},{setStringify:function(e){var t=m;return m=e,t}});function h(e,t){if(e.arguments&&e.arguments.length){var a={};return e.arguments.forEach(function(e){return l(a,e.name,e.value,t)}),a}return null}function v(e){return e.alias?e.alias.value:e.name.value}function y(e){return"Field"===e.kind}function g(e){return"InlineFragment"===e.kind}},53925(e,t,a){a.d(t,{TC:()=>_,XY:()=>h,er:()=>w,hX:()=>y,it:()=>g,iz:()=>f,x3:()=>E,zc:()=>b});var r=a(85608),i=a(70916),n=a(42455),p=a(90424),o=a(3777),s=a(28907),d=a(2904),l=a(73767),u={kind:n.b.FIELD,name:{kind:n.b.NAME,value:"__typename"}};function c(e){return!function e(t,a){return!t||t.selectionSet.selections.every(function(t){return t.kind===n.b.FRAGMENT_SPREAD&&e(a[t.name.value],a)})}((0,o.Vu)(e)||(0,o.E4)(e),(0,d.JG)((0,o.zK)(e)))?e:null}function m(e){var t=new Map;return function(a){void 0===a&&(a=e);var r=t.get(a);return r||t.set(a,r={variables:new Set,fragmentSpreads:new Set}),r}}function f(e,t){(0,o.sw)(t);for(var a,s,d=m(""),u=m(""),f=function(e){for(var t=0,a=void 0;t<e.length&&(a=e[t]);++t)if(!(0,l.c)(a)){if(a.kind===n.b.OPERATION_DEFINITION)return d(a.name&&a.name.value);if(a.kind===n.b.FRAGMENT_DEFINITION)return u(a.name.value)}return!1!==globalThis.__DEV__&&i.invariant.error(97),null},h=0,v=t.definitions.length-1;v>=0;--v)t.definitions[v].kind===n.b.OPERATION_DEFINITION&&++h;var y=(a=new Map,s=new Map,e.forEach(function(e){e&&(e.name?a.set(e.name,e):e.test&&s.set(e.test,e))}),function(e){var t=a.get(e.name.value);return!t&&s.size&&s.forEach(function(a,r){r(e)&&(t=a)}),t}),g=function(e){return(0,l.E)(e)&&e.map(y).some(function(e){return e&&e.remove})},_=new Map,b=!1,w={enter:function(e){if(g(e.directives))return b=!0,null}},E=(0,p.YR)(t,{Field:w,InlineFragment:w,VariableDefinition:{enter:function(){return!1}},Variable:{enter:function(e,t,a,r,i){var n=f(i);n&&n.variables.add(e.name.value)}},FragmentSpread:{enter:function(e,t,a,r,i){if(g(e.directives))return b=!0,null;var n=f(i);n&&n.fragmentSpreads.add(e.name.value)}},FragmentDefinition:{enter:function(e,t,a,r){_.set(JSON.stringify(r),e)},leave:function(e,t,a,r){return e===_.get(JSON.stringify(r))?e:h>0&&e.selectionSet.selections.every(function(e){return e.kind===n.b.FIELD&&"__typename"===e.name.value})?(u(e.name.value).removed=!0,b=!0,null):void 0}},Directive:{leave:function(e){if(y(e))return b=!0,null}}});if(!b)return t;var T=function(e){return!e.transitiveVars&&(e.transitiveVars=new Set(e.variables),e.removed||e.fragmentSpreads.forEach(function(t){T(u(t)).transitiveVars.forEach(function(t){e.transitiveVars.add(t)})})),e},N=new Set;E.definitions.forEach(function(e){e.kind===n.b.OPERATION_DEFINITION?T(d(e.name&&e.name.value)).fragmentSpreads.forEach(function(e){N.add(e)}):e.kind!==n.b.FRAGMENT_DEFINITION||0!==h||u(e.name.value).removed||N.add(e.name.value)}),N.forEach(function(e){T(u(e)).fragmentSpreads.forEach(function(e){N.add(e)})});var S={enter:function(e){var t;if(t=e.name.value,!N.has(t)||u(t).removed)return null}};return c((0,p.YR)(E,{FragmentSpread:S,FragmentDefinition:S,OperationDefinition:{leave:function(e){if(e.variableDefinitions){var t=T(d(e.name&&e.name.value)).transitiveVars;if(t.size<e.variableDefinitions.length)return(0,r.__assign)((0,r.__assign)({},e),{variableDefinitions:e.variableDefinitions.filter(function(e){return t.has(e.variable.name.value)})})}}}}))}var h=Object.assign(function(e){return(0,p.YR)(e,{SelectionSet:{enter:function(e,t,a){if(!a||a.kind!==n.b.OPERATION_DEFINITION){var i=e.selections;if(!(!i||i.some(function(e){return(0,s.dt)(e)&&("__typename"===e.name.value||0===e.name.value.lastIndexOf("__",0))}))&&!((0,s.dt)(a)&&a.directives&&a.directives.some(function(e){return"export"===e.name.value})))return(0,r.__assign)((0,r.__assign)({},e),{selections:(0,r.__spreadArray)((0,r.__spreadArray)([],i,!0),[u],!1)})}}}})},{added:function(e){return e===u}}),v={test:function(e){var t="connection"===e.name.value;return!t||e.arguments&&e.arguments.some(function(e){return"key"===e.name.value})||!1===globalThis.__DEV__||i.invariant.warn(98),t}};function y(e){return f([v],(0,o.sw)(e))}function g(e,t){var a=function(t){return e.some(function(e){return t.value&&t.value.kind===n.b.VARIABLE&&t.value.name&&(e.name===t.value.name.value||e.test&&e.test(t))})};return c((0,p.YR)(t,{OperationDefinition:{enter:function(t){return(0,r.__assign)((0,r.__assign)({},t),{variableDefinitions:t.variableDefinitions?t.variableDefinitions.filter(function(t){return!e.some(function(e){return e.name===t.variable.name.value})}):[]})}},Field:{enter:function(t){if(e.some(function(e){return e.remove})){var r=0;if(t.arguments&&t.arguments.forEach(function(e){a(e)&&(r+=1)}),1===r)return null}}},Argument:{enter:function(e){if(a(e))return null}}}))}function _(e,t){function a(t){if(e.some(function(e){return e.name===t.name.value}))return null}return c((0,p.YR)(t,{FragmentSpread:{enter:a},FragmentDefinition:{enter:a}}))}function b(e){return"query"===(0,o.Vn)(e).operation?e:(0,p.YR)(e,{OperationDefinition:{enter:function(e){return(0,r.__assign)((0,r.__assign)({},e),{operation:"query"})}}})}function w(e){return(0,o.sw)(e),f([{test:function(e){return"client"===e.name.value},remove:!0}],e)}function E(e){return(0,o.sw)(e),(0,p.YR)(e,{FragmentSpread:function(e){var t;if(null==(t=e.directives)||!t.some(function(e){return"unmask"===e.name.value}))return(0,r.__assign)((0,r.__assign)({},e),{directives:(0,r.__spreadArray)((0,r.__spreadArray)([],e.directives||[],!0),[{kind:n.b.DIRECTIVE,name:{kind:n.b.NAME,value:"nonreactive"}}],!1)})}})}},5437(e,t,a){a.r(t),a.d(t,{DEV:()=>r.DEV,concatPagination:()=>y,getInclusionDirectives:()=>i.tY,makeReference:()=>d.WU,shouldInclude:()=>i.MS,createFragmentMap:()=>p.JG,AutoCleanedStrongCache:()=>z.V,hasAllDirectives:()=>i.I5,AutoCleanedWeakCache:()=>z.A,canUseWeakMap:()=>P.et,getFragmentFromSelection:()=>p.HQ,storeKeyNameFromField:()=>d.Ii,getOperationDefinition:()=>o.Vu,isArray:()=>V.c,checkDocument:()=>o.sw,getFragmentMaskMode:()=>i.s7,maybe:()=>r.maybe,valueToObjectRepresentation:()=>d.J,mergeDeepArray:()=>v.IM,getDirectiveNames:()=>i.sx,isExecutionPatchInitialResult:()=>B.EQ,graphQLResultHasError:()=>$.t,resultKeyNameFromField:()=>d.ue,hasDirectives:()=>i.d8,isPlainObject:()=>F.Q,isNonNullObject:()=>F.U,mergeOptions:()=>U.l,canUseAsyncIteratorSymbol:()=>P.uJ,isReference:()=>d.A_,DeepMerger:()=>v.ZI,maybeDeepFreeze:()=>A.G,getFragmentDefinition:()=>o.E4,getTypenameFromResult:()=>d.D$,iterateObserversSafely:()=>k.w,getOperationName:()=>o.n4,removeDirectivesFromDocument:()=>l.iz,isStatefulPromise:()=>S,isInlineFragment:()=>d.kd,canUseWeakSet:()=>P.En,mergeDeep:()=>v.D9,omitDeep:()=>Q,isQueryOperation:()=>m,print:()=>s.y,createRejectedPromise:()=>N,getStoreKeyName:()=>d.o5,removeFragmentSpreadFromDocument:()=>l.TC,removeArgumentsFromDocument:()=>l.it,fixObservableSubclass:()=>R.r,createFulfilledPromise:()=>T,canUseSymbol:()=>P.ol,getFragmentQueryDocument:()=>p.ct,removeConnectionDirectiveFromDocument:()=>l.hX,stringifyForDisplay:()=>M.p,wrapPromiseWithState:()=>O,relayStylePagination:()=>_,isNonEmptyArray:()=>V.E,getFragmentDefinitions:()=>o.zK,isExecutionPatchIncrementalResult:()=>B.ST,buildQueryFromSelectionSet:()=>l.zc,preventUnhandledRejection:()=>I.X,stripTypename:()=>G,canUseDOM:()=>P.Sw,canUseLayoutEffect:()=>P.JR,isApolloPayloadResult:()=>B.Nw,DocumentTransform:()=>n.c,addTypenameToDocument:()=>l.XY,canonicalStringify:()=>q.M,Concast:()=>C.E,Observable:()=>E.c,argumentsObjectFromField:()=>d.MB,getDefaultValues:()=>o.wY,isField:()=>d.dt,hasClientExports:()=>i.f2,offsetLimitPagination:()=>g,removeClientSetsFromDocument:()=>l.er,isDocumentNode:()=>d.Kc,compact:()=>L.o,getGraphQLErrorsFromResult:()=>$.M,addNonReactiveToNamedFragments:()=>l.x3,getQueryDefinition:()=>o.AT,isExecutionPatchResult:()=>B.YX,asyncMap:()=>x.x,isFullyUnmaskedOperation:()=>p.s6,hasAnyDirectives:()=>i.hE,getMainDefinition:()=>o.Vn,isMutationOperation:()=>c,cloneDeep:()=>D.m,isSubscriptionOperation:()=>f,cacheSizes:()=>H.v,makeUniqueId:()=>j.v,mergeIncrementalData:()=>B.bd});var r=a(70916),i=a(82307),n=a(9354),p=a(2904),o=a(3777),s=a(38678),d=a(28907),l=a(53925);function u(e,t){var a;return(null==(a=(0,o.Vu)(e))?void 0:a.operation)===t}function c(e){return u(e,"mutation")}function m(e){return u(e,"query")}function f(e){return u(e,"subscription")}var h=a(85608),v=a(30671);function y(e){return void 0===e&&(e=!1),{keyArgs:e,merge:function(e,t){return e?(0,h.__spreadArray)((0,h.__spreadArray)([],e,!0),t,!0):t}}}function g(e){return void 0===e&&(e=!1),{keyArgs:e,merge:function(e,t,a){var r=a.args,i=e?e.slice(0):[];if(t)if(r)for(var n=r.offset,p=void 0===n?0:n,o=0;o<t.length;++o)i[p+o]=t[o];else i.push.apply(i,t);return i}}}function _(e){return void 0===e&&(e=!1),{keyArgs:e,read:function(e,t){var a=t.canRead,r=t.readField;if(!e)return e;var i=[],n="",p="";e.edges.forEach(function(e){a(r("node",e))&&(i.push(e),e.cursor&&(n=n||e.cursor||"",p=e.cursor||p))}),i.length>1&&n===p&&(n="");var o=e.pageInfo||{},s=o.startCursor,d=o.endCursor;return(0,h.__assign)((0,h.__assign)({},b(e)),{edges:i,pageInfo:(0,h.__assign)((0,h.__assign)({},e.pageInfo),{startCursor:s||n,endCursor:d||p})})},merge:function(e,t,a){var r=a.args,i=a.isReference,n=a.readField;if(e||(e={edges:[],pageInfo:{hasPreviousPage:!1,hasNextPage:!0,startCursor:"",endCursor:""}}),!t)return e;var p=t.edges?t.edges.map(function(e){return i(e=(0,h.__assign)({},e))&&(e.cursor=n("cursor",e)),e}):[];if(t.pageInfo){var o=t.pageInfo,s=o.startCursor,d=o.endCursor,l=p[0],u=p[p.length-1];l&&s&&(l.cursor=s),u&&d&&(u.cursor=d);var c=l&&l.cursor;c&&!s&&(t=(0,v.D9)(t,{pageInfo:{startCursor:c}}));var m=u&&u.cursor;m&&!d&&(t=(0,v.D9)(t,{pageInfo:{endCursor:m}}))}var f=e.edges,y=[];if(r&&r.after){var g=f.findIndex(function(e){return e.cursor===r.after});g>=0&&(f=f.slice(0,g+1))}else if(r&&r.before){var g=f.findIndex(function(e){return e.cursor===r.before});y=g<0?f:f.slice(g),f=[]}else t.edges&&(f=[]);var _=(0,h.__spreadArray)((0,h.__spreadArray)((0,h.__spreadArray)([],f,!0),p,!0),y,!0),w=(0,h.__assign)((0,h.__assign)({},t.pageInfo),e.pageInfo);if(t.pageInfo){var E=t.pageInfo,T=E.hasPreviousPage,N=E.hasNextPage,s=E.startCursor,d=E.endCursor;Object.assign(w,(0,h.__rest)(E,["hasPreviousPage","hasNextPage","startCursor","endCursor"])),f.length||(void 0!==T&&(w.hasPreviousPage=T),void 0!==s&&(w.startCursor=s)),y.length||(void 0!==N&&(w.hasNextPage=N),void 0!==d&&(w.endCursor=d))}return(0,h.__assign)((0,h.__assign)((0,h.__assign)({},b(e)),b(t)),{edges:_,pageInfo:w})}}}var b=function(e){return(0,h.__rest)(e,w)},w=["edges","pageInfo"],E=a(36054);function T(e){var t=Promise.resolve(e);return t.status="fulfilled",t.value=e,t}function N(e){var t=Promise.reject(e);return t.catch(function(){}),t.status="rejected",t.reason=e,t}function S(e){return"status"in e}function O(e){return S(e)||(e.status="pending",e.then(function(t){"pending"===e.status&&(e.status="fulfilled",e.value=t)},function(t){"pending"===e.status&&(e.status="rejected",e.reason=t)})),e}var I=a(30234),D=a(20906),A=a(57236),k=a(87613),x=a(5762),C=a(45637),R=a(35892),V=a(73767),F=a(21777),$=a(32710),P=a(51360),L=a(50492),j=a(21461),M=a(86563),U=a(31507),B=a(37396),q=a(44214);function Q(e,t){return Y(e,t)}function Y(e,t,a){if(void 0===a&&(a=new Map),a.has(e))return a.get(e);var r=!1;if(Array.isArray(e)){var i=[];if(a.set(e,i),e.forEach(function(e,n){var p=Y(e,t,a);r||(r=p!==e),i[n]=p}),r)return i}else if((0,F.Q)(e)){var n=Object.create(Object.getPrototypeOf(e));if(a.set(e,n),Object.keys(e).forEach(function(i){if(i===t){r=!0;return}var p=Y(e[i],t,a);r||(r=p!==e[i]),n[i]=p}),r)return n}return e}function G(e){return Y(e,"__typename")}var z=a(45078),H=a(555)},45637(e,t,a){a.d(t,{E:()=>s});var r=a(85608),i=a(36054),n=a(87613),p=a(35892);function o(e){return e&&"function"==typeof e.then}var s=function(e){function t(t){var a=e.call(this,function(e){return a.addObserver(e),function(){return a.removeObserver(e)}})||this;return a.observers=new Set,a.promise=new Promise(function(e,t){a.resolve=e,a.reject=t}),a.handlers={next:function(e){null!==a.sub&&(a.latest=["next",e],a.notify("next",e),(0,n.w)(a.observers,"next",e))},error:function(e){var t=a.sub;null!==t&&(t&&setTimeout(function(){return t.unsubscribe()}),a.sub=null,a.latest=["error",e],a.reject(e),a.notify("error",e),(0,n.w)(a.observers,"error",e))},complete:function(){var e=a.sub,t=a.sources;if(null!==e){var r=(void 0===t?[]:t).shift();r?o(r)?r.then(function(e){return a.sub=e.subscribe(a.handlers)},a.handlers.error):a.sub=r.subscribe(a.handlers):(e&&setTimeout(function(){return e.unsubscribe()}),a.sub=null,a.latest&&"next"===a.latest[0]?a.resolve(a.latest[1]):a.resolve(),a.notify("complete"),(0,n.w)(a.observers,"complete"))}}},a.nextResultListeners=new Set,a.cancel=function(e){a.reject(e),a.sources=[],a.handlers.error(e)},a.promise.catch(function(e){}),"function"==typeof t&&(t=[new i.c(t)]),o(t)?t.then(function(e){return a.start(e)},a.handlers.error):a.start(t),a}return(0,r.__extends)(t,e),t.prototype.start=function(e){void 0===this.sub&&(this.sources=Array.from(e),this.handlers.complete())},t.prototype.deliverLastMessage=function(e){if(this.latest){var t=this.latest[0],a=e[t];a&&a.call(e,this.latest[1]),null===this.sub&&"next"===t&&e.complete&&e.complete()}},t.prototype.addObserver=function(e){this.observers.has(e)||(this.deliverLastMessage(e),this.observers.add(e))},t.prototype.removeObserver=function(e){this.observers.delete(e)&&this.observers.size<1&&this.handlers.complete()},t.prototype.notify=function(e,t){var a=this.nextResultListeners;a.size&&(this.nextResultListeners=new Set,a.forEach(function(a){return a(e,t)}))},t.prototype.beforeNext=function(e){var t=!1;this.nextResultListeners.add(function(a,r){t||(t=!0,e(a,r))})},t}(i.c);(0,p.r)(s)},5762(e,t,a){a.d(t,{x:()=>i});var r=a(36054);function i(e,t,a){return new r.c(function(r){var i={then:function(e){return new Promise(function(t){return t(e())})}};function n(e,t){return function(a){if(e){var n=function(){return r.closed?0:e(a)};i=i.then(n,n).then(function(e){return r.next(e)},function(e){return r.error(e)})}else r[t](a)}}var p={next:n(t,"next"),error:n(a,"error"),complete:function(){i.then(function(){return r.complete()})}},o=e.subscribe(p);return function(){return o.unsubscribe()}})}},87613(e,t,a){a.d(t,{w:()=>r});function r(e,t,a){var r=[];e.forEach(function(e){return e[t]&&r.push(e)}),r.forEach(function(e){return e[t](a)})}},35892(e,t,a){a.d(t,{r:()=>n});var r=a(36054),i=a(51360);function n(e){function t(t){Object.defineProperty(e,t,{value:r.c})}return i.ol&&Symbol.species&&t(Symbol.species),t("@@species"),e}},30234(e,t,a){a.d(t,{X:()=>r});function r(e){return e.catch(function(){}),e}},73972(e,t,a){a.d(t,{r:()=>r});var r="3.13.8"},31088(e,t,a){function r(){}a.d(t,{C:()=>i});class i{constructor(e=1/0,t=r){this.max=e,this.dispose=t,this.map=new Map,this.newest=null,this.oldest=null}has(e){return this.map.has(e)}get(e){let t=this.getNode(e);return t&&t.value}get size(){return this.map.size}getNode(e){let t=this.map.get(e);if(t&&t!==this.newest){let{older:e,newer:a}=t;a&&(a.older=e),e&&(e.newer=a),t.older=this.newest,t.older.newer=t,t.newer=null,this.newest=t,t===this.oldest&&(this.oldest=a)}return t}set(e,t){let a=this.getNode(e);return a?a.value=t:(a={key:e,value:t,newer:null,older:this.newest},this.newest&&(this.newest.newer=a),this.newest=a,this.oldest=this.oldest||a,this.map.set(e,a),a.value)}clean(){for(;this.oldest&&this.map.size>this.max;)this.delete(this.oldest.key)}delete(e){let t=this.map.get(e);return!!t&&(t===this.newest&&(this.newest=t.older),t===this.oldest&&(this.oldest=t.newer),t.newer&&(t.newer.older=t.older),t.older&&(t.older.newer=t.newer),this.map.delete(e),this.dispose(t.value,e),!0)}}},54019(e,t,a){function r(){}a.d(t,{l:()=>o});let i="u">typeof WeakRef?WeakRef:function(e){return{deref:()=>e}},n="u">typeof WeakMap?WeakMap:Map,p="u">typeof FinalizationRegistry?FinalizationRegistry:function(){return{register:r,unregister:r}};class o{constructor(e=1/0,t=r){this.max=e,this.dispose=t,this.map=new n,this.newest=null,this.oldest=null,this.unfinalizedNodes=new Set,this.finalizationScheduled=!1,this.size=0,this.finalize=()=>{let e=this.unfinalizedNodes.values();for(let t=0;t<10024;t++){let t=e.next().value;if(!t)break;this.unfinalizedNodes.delete(t);let a=t.key;delete t.key,t.keyRef=new i(a),this.registry.register(a,t,t)}this.unfinalizedNodes.size>0?queueMicrotask(this.finalize):this.finalizationScheduled=!1},this.registry=new p(this.deleteNode.bind(this))}has(e){return this.map.has(e)}get(e){let t=this.getNode(e);return t&&t.value}getNode(e){let t=this.map.get(e);if(t&&t!==this.newest){let{older:e,newer:a}=t;a&&(a.older=e),e&&(e.newer=a),t.older=this.newest,t.older.newer=t,t.newer=null,this.newest=t,t===this.oldest&&(this.oldest=a)}return t}set(e,t){let a=this.getNode(e);return a?a.value=t:(a={key:e,value:t,newer:null,older:this.newest},this.newest&&(this.newest.newer=a),this.newest=a,this.oldest=this.oldest||a,this.scheduleFinalization(a),this.map.set(e,a),this.size++,a.value)}clean(){for(;this.oldest&&this.size>this.max;)this.deleteNode(this.oldest)}deleteNode(e){e===this.newest&&(this.newest=e.older),e===this.oldest&&(this.oldest=e.newer),e.newer&&(e.newer.older=e.older),e.older&&(e.older.newer=e.newer),this.size--;let t=e.key||e.keyRef&&e.keyRef.deref();this.dispose(e.value,t),e.keyRef?this.registry.unregister(e):this.unfinalizedNodes.delete(e),t&&this.map.delete(t)}delete(e){let t=this.map.get(e);return!!t&&(this.deleteNode(t),!0)}scheduleFinalization(e){this.unfinalizedNodes.add(e),this.finalizationScheduled||(this.finalizationScheduled=!0,queueMicrotask(this.finalize))}}},55888(e,t,a){a.r(t),a.d(t,{default:()=>s,equal:()=>o});let{toString:r,hasOwnProperty:i}=Object.prototype,n=Function.prototype.toString,p=new Map;function o(e,t){try{return function e(t,a){if(t===a)return!0;let p=r.call(t);if(p!==r.call(a))return!1;switch(p){case"[object Array]":if(t.length!==a.length)break;case"[object Object]":{if(c(t,a))return!0;let r=d(t),n=d(a),p=r.length;if(p!==n.length)return!1;for(let e=0;e<p;++e)if(!i.call(a,r[e]))return!1;for(let i=0;i<p;++i){let n=r[i];if(!e(t[n],a[n]))return!1}return!0}case"[object Error]":return t.name===a.name&&t.message===a.message;case"[object Number]":if(t!=t)return a!=a;case"[object Boolean]":case"[object Date]":return+t==+a;case"[object RegExp]":case"[object String]":return t==`${a}`;case"[object Map]":case"[object Set]":{if(t.size!==a.size)return!1;if(c(t,a))return!0;let r=t.entries(),i="[object Map]"===p;for(;;){let t=r.next();if(t.done)break;let[n,p]=t.value;if(!a.has(n)||i&&!e(p,a.get(n)))return!1}return!0}case"[object Uint16Array]":case"[object Uint8Array]":case"[object Uint32Array]":case"[object Int32Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object ArrayBuffer]":t=new Uint8Array(t),a=new Uint8Array(a);case"[object DataView]":{let e=t.byteLength;if(e===a.byteLength)for(;e--&&t[e]===a[e];);return -1===e}case"[object AsyncFunction]":case"[object GeneratorFunction]":case"[object AsyncGeneratorFunction]":case"[object Function]":{var o,s;let e,r=n.call(t);if(r!==n.call(a))return!1;return o=r,s=u,!((e=o.length-s.length)>=0)||o.indexOf(s,e)!==e}}return!1}(e,t)}finally{p.clear()}}let s=o;function d(e){return Object.keys(e).filter(l,e)}function l(e){return void 0!==this[e]}let u="{ [native code] }";function c(e,t){let a=p.get(e);if(a){if(a.has(t))return!0}else p.set(e,a=new Set);return a.add(t),!1}},44592(e,t,a){a.r(t),a.d(t,{Trie:()=>o});let r=()=>Object.create(null),{forEach:i,slice:n}=Array.prototype,{hasOwnProperty:p}=Object.prototype;class o{constructor(e=!0,t=r){this.weakness=e,this.makeData=t}lookup(){return this.lookupArray(arguments)}lookupArray(e){let t=this;return i.call(e,e=>t=t.getChildTrie(e)),p.call(t,"data")?t.data:t.data=this.makeData(n.call(e))}peek(){return this.peekArray(arguments)}peekArray(e){let t=this;for(let a=0,r=e.length;t&&a<r;++a){let r=t.mapFor(e[a],!1);t=r&&r.get(e[a])}return t&&t.data}remove(){return this.removeArray(arguments)}removeArray(e){let t;if(e.length){let a=e[0],r=this.mapFor(a,!1),i=r&&r.get(a);i&&(t=i.removeArray(n.call(e,1)),i.data||i.weak||i.strong&&i.strong.size||r.delete(a))}else t=this.data,delete this.data;return t}getChildTrie(e){let t=this.mapFor(e,!0),a=t.get(e);return a||t.set(e,a=new o(this.weakness,this.makeData)),a}mapFor(e,t){return this.weakness&&function(e){switch(typeof e){case"object":if(null===e)break;case"function":return!0}return!1}(e)?this.weak||(t?this.weak=new WeakMap:void 0):this.strong||(t?this.strong=new Map:void 0)}}},74261(e,r,i){let n;i.d(r,{F2:()=>rq,UU:()=>aV,W0:()=>i3,Sz:()=>i4,Pq:()=>ea,le:()=>a6,Nm:()=>aD,TM:()=>iv,xB:()=>iS,A8:()=>rM,US:()=>rS,IC:()=>i1,iF:()=>i0,ph:()=>i2,En:()=>rW,R5:()=>rP,B3:()=>iC,n3:()=>ix,V0:()=>rA,Em:()=>iV,BZ:()=>iN,tX:()=>r_,Rp:()=>rk,he:()=>ih,Sk:()=>aj,HM:()=>iA,SC:()=>aR,mp:()=>rx,UY:()=>iH,bo:()=>iJ,EC:()=>iX,P9:()=>rL,Zd:()=>iK,QI:()=>rU,lh:()=>aA,Yg:()=>iG,_o:()=>rj,mn:()=>rV,mF:()=>aM,WF:()=>rH,UM:()=>rB,Ix:()=>ik,b2:()=>iz,V5:()=>rJ,el:()=>rF,n_:()=>iP,z4:()=>er,TZ:()=>r9,dG:()=>iU});var p,o,s,d,l,u,c,m,f,h,v,y,g,_,b,w,E,T,N,S,O,I,D,A,k,x,C,R,V,F,$,P,L,j,M,U,B,q,Q,Y,G,z,H,W,K,J,Z,X,ee,et,ea={};i.r(ea),i.d(ea,{application:()=>eR,applicationDeviceSettings:()=>eV,applicationProject:()=>eH,applicationReleaseVersions:()=>eF,applications:()=>e$,blueprint:()=>eZ,blueprintEvents:()=>e6,blueprintProjection:()=>e0,blueprintRevisions:()=>e2,blueprints:()=>eX,blueprintsByInstance:()=>e1,buttressServers:()=>eK,checkBindDevicePasscode:()=>eU,device:()=>eI,deviceGroup:()=>ek,deviceGroups:()=>ex,deviceUsage:()=>ez,devices:()=>eD,devicesApplicationStatus:()=>e4,devicesByGroup:()=>eC,devicesPanel:()=>eA,mediaBox:()=>eY,mediaBoxes:()=>eQ,mediaFile:()=>eG,mediaFiles:()=>eB,mediaWorkspace:()=>eq,module:()=>eL,moduleProject:()=>eW,modules:()=>ej,publicApplicationShareInfo:()=>eP,publicModules:()=>eM,registryTrust:()=>eJ,workspace:()=>eO});var er={};i.r(er),i.d(er,{acquireBlueprintRun:()=>tV,bindApplication:()=>ts,bindButtressServer:()=>tT,bindButtressServerWithRegistry:()=>tN,controlDevice:()=>e9,copyMediaFiles:()=>tg,createApplication:()=>ta,createApplicationWithShareVersion:()=>tr,createBlueprint:()=>tk,createDevice:()=>e3,createMediaFileUploadRequest:()=>tv,createModule:()=>tl,createVirtualDevice:()=>e5,deleteMediaBoxFiles:()=>tb,deleteMediaFiles:()=>t_,dispatchDeviceGroupAction:()=>tt,heartbeatBlueprintRun:()=>tF,issueButtressAccessToken:()=>tI,issueButtressNodeCredential:()=>tS,issueDevtoolsAccessToken:()=>tD,releaseApplication:()=>th,releaseBlueprintRun:()=>t$,releaseModule:()=>tE,removeApplication:()=>tp,removeBlueprint:()=>tR,removeDevice:()=>te,removeModule:()=>tc,revertBlueprint:()=>tC,revokeAccessTokens:()=>tA,setMediaFileAsBoxPreview:()=>tw,shortEditApplication:()=>to,shortEditModule:()=>tm,triggerApplicationCanvasControl:()=>td,unbindButtressServer:()=>tO,updateApplication:()=>ti,updateBlueprint:()=>tx,updateDevice:()=>e7,updateMediaFiles:()=>ty,updateModule:()=>tu,updateVirtualDevice:()=>e8,updateWorkspace:()=>tf,useApplicationReleaseVersion:()=>tn});var ei=i(99436),en=i(5018),ep=i(44668),eo=i(54506),es=i(78549),ed=i(94370),el=i(90424),eu=(0,ed.default)`
|
|
4
|
+
`);let{statusCode:b,buffered:w}=yield _;if(200===b){if(e.once("socket",f),t.secureEndpoint){c("Upgrading socket connection to TLS");let e=t.servername||t.host;return p.default.connect(Object.assign(Object.assign({},function(e,...t){let a,r={};for(a in e)t.includes(a)||(r[a]=e[a]);return r}(t,"host","hostname","path","port")),{socket:i,servername:e}))}return i}i.destroy();let E=new n.default.Socket({writable:!1});return E.readable=!0,e.once("socket",e=>{c("replaying proxy buffer for failed request"),s.default(e.listenerCount("data")>0),e.push(w),e.push(null)}),E})}}function f(e){e.resume()}t.default=m},64007(e,t,a){var r;let i=(this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}})(a(35646));function n(e){return new i.default(e)}(r=n||(n={})).HttpsProxyAgent=i.default,r.prototype=i.default.prototype,e.exports=n},36981(e,t,a){var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});let i=r(a(3680)).default("https-proxy-agent:parse-proxy-response");t.default=function(e){return new Promise((t,a)=>{let r=0,n=[];function p(){let a=e.read();a?function(e){n.push(e),r+=e.length;let a=Buffer.concat(n,r);if(-1===a.indexOf("\r\n\r\n")){i("have not received end of HTTP headers yet..."),p();return}let o=a.toString("ascii",0,a.indexOf("\r\n")),s=+o.split(" ")[1];i("got proxy server response: %o",o),t({statusCode:s,buffered:a})}(a):e.once("readable",p)}function o(e){i("onclose had error %o",e)}function s(){i("onend")}e.on("error",function t(r){e.removeListener("end",s),e.removeListener("error",t),e.removeListener("close",o),e.removeListener("readable",p),i("onerror %o",r),a(r)}),e.on("close",o),e.on("end",s),p()})}},65650(e,t,a){e.exports=a(78942).Symbol},65111(e){e.exports=function(e,t){for(var a=-1,r=null==e?0:e.length,i=Array(r);++a<r;)i[a]=t(e[a],a,e);return i}},44187(e){e.exports=function(e,t,a,r){var i=-1,n=null==e?0:e.length;for(r&&n&&(a=e[++i]);++i<n;)a=t(a,e[i],i,e);return a}},39546(e){var t=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;e.exports=function(e){return e.match(t)||[]}},87379(e,t,a){var r=a(65650),i=a(8870),n=a(29005),p=r?r.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":p&&p in Object(e)?i(e):n(e)}},51035(e){e.exports=function(e){return function(t){return null==e?void 0:e[t]}}},52291(e,t,a){var r=a(65650),i=a(65111),n=a(53142),p=a(51187),o=1/0,s=r?r.prototype:void 0,d=s?s.toString:void 0;e.exports=function e(t){if("string"==typeof t)return t;if(n(t))return i(t,e)+"";if(p(t))return d?d.call(t):"";var a=t+"";return"0"==a&&1/t==-o?"-0":a}},93640(e,t,a){var r=a(44187),i=a(45881),n=a(39850),p=RegExp("['’]","g");e.exports=function(e){return function(t){return r(n(i(t).replace(p,"")),e,"")}}},69968(e,t,a){e.exports=a(51035)({À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"})},74967(e){e.exports="object"==typeof global&&global&&global.Object===Object&&global},8870(e,t,a){var r=a(65650),i=Object.prototype,n=i.hasOwnProperty,p=i.toString,o=r?r.toStringTag:void 0;e.exports=function(e){var t=n.call(e,o),a=e[o];try{e[o]=void 0;var r=!0}catch(e){}var i=p.call(e);return r&&(t?e[o]=a:delete e[o]),i}},15813(e){var t=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;e.exports=function(e){return t.test(e)}},29005(e){var t=Object.prototype.toString;e.exports=function(e){return t.call(e)}},78942(e,t,a){var r=a(74967),i="object"==typeof self&&self&&self.Object===Object&&self;e.exports=r||i||Function("return this")()},10482(e){var t="\\ud800-\\udfff",a="\\u2700-\\u27bf",r="a-z\\xdf-\\xf6\\xf8-\\xff",i="A-Z\\xc0-\\xd6\\xd8-\\xde",n="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\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",p="['’]",o="["+n+"]",s="["+r+"]",d="[^"+t+n+"\\d+"+a+r+i+"]",l="(?:\\ud83c[\\udde6-\\uddff]){2}",u="[\\ud800-\\udbff][\\udc00-\\udfff]",c="["+i+"]",m="(?:"+s+"|"+d+")",f="(?:"+c+"|"+d+")",h="(?:"+p+"(?:d|ll|m|re|s|t|ve))?",v="(?:"+p+"(?:D|LL|M|RE|S|T|VE))?",y="(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?",g="[\\ufe0e\\ufe0f]?",_="(?:\\u200d(?:"+["[^"+t+"]",l,u].join("|")+")"+g+y+")*",b="(?:"+["["+a+"]",l,u].join("|")+")"+(g+y+_),w=RegExp([c+"?"+s+"+"+h+"(?="+[o,c,"$"].join("|")+")",f+"+"+v+"(?="+[o,c+m,"$"].join("|")+")",c+"?"+m+"+"+h,c+"+"+v,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])|\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])|\\d+",b].join("|"),"g");e.exports=function(e){return e.match(w)||[]}},45881(e,t,a){var r=a(69968),i=a(95243),n=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,p=RegExp("[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]","g");e.exports=function(e){return(e=i(e))&&e.replace(n,r).replace(p,"")}},53142(e){e.exports=Array.isArray},80547(e){e.exports=function(e){return null!=e&&"object"==typeof e}},51187(e,t,a){var r=a(87379),i=a(80547);e.exports=function(e){return"symbol"==typeof e||i(e)&&"[object Symbol]"==r(e)}},10750(e,t,a){e.exports=a(93640)(function(e,t,a){return e+(a?"-":"")+t.toLowerCase()})},95243(e,t,a){var r=a(52291);e.exports=function(e){return null==e?"":r(e)}},39850(e,t,a){var r=a(39546),i=a(15813),n=a(95243),p=a(10482);e.exports=function(e,t,a){return(e=n(e),void 0===(t=a?void 0:t))?i(e)?p(e):r(e):e.match(t)||[]}},27250(e){function t(e,t,a,r){return Math.round(e/a)+" "+r+(t>=1.5*a?"s":"")}e.exports=function(e,a){a=a||{};var r,i,n,p,o=typeof e;if("string"===o&&e.length>0){var s=e;if(!((s=String(s)).length>100)){var d=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(s);if(d){var l=parseFloat(d[1]);switch((d[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*l;case"weeks":case"week":case"w":return 6048e5*l;case"days":case"day":case"d":return 864e5*l;case"hours":case"hour":case"hrs":case"hr":case"h":return 36e5*l;case"minutes":case"minute":case"mins":case"min":case"m":return 6e4*l;case"seconds":case"second":case"secs":case"sec":case"s":return 1e3*l;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return l;default:break}}}return}if("number"===o&&isFinite(e)){return a.long?(i=Math.abs(r=e))>=864e5?t(r,i,864e5,"day"):i>=36e5?t(r,i,36e5,"hour"):i>=6e4?t(r,i,6e4,"minute"):i>=1e3?t(r,i,1e3,"second"):r+" ms":(p=Math.abs(n=e))>=864e5?Math.round(n/864e5)+"d":p>=36e5?Math.round(n/36e5)+"h":p>=6e4?Math.round(n/6e4)+"m":p>=1e3?Math.round(n/1e3)+"s":n+"ms"}throw Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},27549(e,t,a){e.exports=function(e,t){var r=[function(e,t,a){e.exports=a(34)},function(e,t,a){var r=a(29)("wks"),i=a(33),n=a(2).Symbol,p="function"==typeof n;(e.exports=function(e){return r[e]||(r[e]=p&&n[e]||(p?n:i)("Symbol."+e))}).store=r},function(e,t){var a=e.exports="u">typeof window&&window.Math==Math?window:"u">typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=a)},function(e,t,a){var r=a(9);e.exports=function(e){if(!r(e))throw TypeError(e+" is not an object!");return e}},function(e,t,a){e.exports=!a(24)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(e,t,a){var r=a(12),i=a(17);e.exports=a(4)?function(e,t,a){return r.f(e,t,i(1,a))}:function(e,t,a){return e[t]=a,e}},function(e,t){var a=e.exports={version:"2.4.0"};"number"==typeof __e&&(__e=a)},function(e,t,a){var r=a(14);e.exports=function(e,t,a){if(r(e),void 0===t)return e;switch(a){case 1:return function(a){return e.call(t,a)};case 2:return function(a,r){return e.call(t,a,r)};case 3:return function(a,r,i){return e.call(t,a,r,i)}}return function(){return e.apply(t,arguments)}}},function(e,t){var a={}.hasOwnProperty;e.exports=function(e,t){return a.call(e,t)}},function(e,t){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},function(e,t){e.exports={}},function(e,t){var a={}.toString;e.exports=function(e){return a.call(e).slice(8,-1)}},function(e,t,a){var r=a(3),i=a(26),n=a(32),p=Object.defineProperty;t.f=a(4)?Object.defineProperty:function(e,t,a){if(r(e),t=n(t,!0),r(a),i)try{return p(e,t,a)}catch(e){}if("get"in a||"set"in a)throw TypeError("Accessors not supported!");return"value"in a&&(e[t]=a.value),e}},function(e,t,a){var r=a(42),i=a(15);e.exports=function(e){return r(i(e))}},function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},function(e,t){e.exports=function(e){if(void 0==e)throw TypeError("Can't call method on "+e);return e}},function(e,t,a){var r=a(9),i=a(2).document,n=r(i)&&r(i.createElement);e.exports=function(e){return n?i.createElement(e):{}}},function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},function(e,t,a){var r=a(12).f,i=a(8),n=a(1)("toStringTag");e.exports=function(e,t,a){e&&!i(e=a?e:e.prototype,n)&&r(e,n,{configurable:!0,value:t})}},function(e,t,a){var r=a(29)("keys"),i=a(33);e.exports=function(e){return r[e]||(r[e]=i(e))}},function(e,t){var a=Math.ceil,r=Math.floor;e.exports=function(e){return isNaN(e*=1)?0:(e>0?r:a)(e)}},function(e,t,a){var r=a(11),i=a(1)("toStringTag"),n="Arguments"==r(function(){return arguments}()),p=function(e,t){try{return e[t]}catch(e){}};e.exports=function(e){var t,a,o;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(a=p(t=Object(e),i))?a:n?r(t):"Object"==(o=r(t))&&"function"==typeof t.callee?"Arguments":o}},function(e,t){e.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(e,t,a){var r=a(2),i=a(6),n=a(7),p=a(5),o="prototype",s=function(e,t,a){var d,l,u,c=e&s.F,m=e&s.G,f=e&s.S,h=e&s.P,v=e&s.B,y=e&s.W,g=m?i:i[t]||(i[t]={}),_=g[o],b=m?r:f?r[t]:(r[t]||{})[o];for(d in m&&(a=t),a)(l=!c&&b&&void 0!==b[d])&&d in g||(u=l?b[d]:a[d],g[d]=m&&"function"!=typeof b[d]?a[d]:v&&l?n(u,r):y&&b[d]==u?function(e){var t=function(t,a,r){if(this instanceof e){switch(arguments.length){case 0:return new e;case 1:return new e(t);case 2:return new e(t,a)}return new e(t,a,r)}return e.apply(this,arguments)};return t[o]=e[o],t}(u):h&&"function"==typeof u?n(Function.call,u):u,h&&((g.virtual||(g.virtual={}))[d]=u,e&s.R&&_&&!_[d]&&p(_,d,u)))};s.F=1,s.G=2,s.S=4,s.P=8,s.B=16,s.W=32,s.U=64,s.R=128,e.exports=s},function(e,t){e.exports=function(e){try{return!!e()}catch(e){return!0}}},function(e,t,a){e.exports=a(2).document&&document.documentElement},function(e,t,a){e.exports=!a(4)&&!a(24)(function(){return 7!=Object.defineProperty(a(16)("div"),"a",{get:function(){return 7}}).a})},function(e,t,a){"use strict";var r=a(28),i=a(23),n=a(57),p=a(5),o=a(8),s=a(10),d=a(45),l=a(18),u=a(52),c=a(1)("iterator"),m=!([].keys&&"next"in[].keys()),f="keys",h="values",v=function(){return this};e.exports=function(e,t,a,y,g,_,b){d(a,t,y);var w,E,T,N=function(e){if(!m&&e in D)return D[e];switch(e){case f:case h:return function(){return new a(this,e)}}return function(){return new a(this,e)}},S=t+" Iterator",O=g==h,I=!1,D=e.prototype,A=D[c]||D["@@iterator"]||g&&D[g],k=A||N(g),x=g?O?N("entries"):k:void 0,C="Array"==t&&D.entries||A;if(C&&(T=u(C.call(new e)))!==Object.prototype&&(l(T,S,!0),r||o(T,c)||p(T,c,v)),O&&A&&A.name!==h&&(I=!0,k=function(){return A.call(this)}),(!r||b)&&(m||I||!D[c])&&p(D,c,k),s[t]=k,s[S]=v,g)if(w={values:O?k:N(h),keys:_?k:N(f),entries:x},b)for(E in w)E in D||n(D,E,w[E]);else i(i.P+i.F*(m||I),t,w);return w}},function(e,t){e.exports=!0},function(e,t,a){var r=a(2),i="__core-js_shared__",n=r[i]||(r[i]={});e.exports=function(e){return n[e]||(n[e]={})}},function(e,t,a){var r,i,n,p=a(7),o=a(41),s=a(25),d=a(16),l=a(2),u=l.process,c=l.setImmediate,m=l.clearImmediate,f=l.MessageChannel,h=0,v={},y="onreadystatechange",g=function(){var e=+this;if(v.hasOwnProperty(e)){var t=v[e];delete v[e],t()}},_=function(e){g.call(e.data)};c&&m||(c=function(e){for(var t=[],a=1;arguments.length>a;)t.push(arguments[a++]);return v[++h]=function(){o("function"==typeof e?e:Function(e),t)},r(h),h},m=function(e){delete v[e]},"process"==a(11)(u)?r=function(e){u.nextTick(p(g,e,1))}:f?(n=(i=new f).port2,i.port1.onmessage=_,r=p(n.postMessage,n,1)):l.addEventListener&&"function"==typeof postMessage&&!l.importScripts?(r=function(e){l.postMessage(e+"","*")},l.addEventListener("message",_,!1)):r=y in d("script")?function(e){s.appendChild(d("script"))[y]=function(){s.removeChild(this),g.call(e)}}:function(e){setTimeout(p(g,e,1),0)}),e.exports={set:c,clear:m}},function(e,t,a){var r=a(20),i=Math.min;e.exports=function(e){return e>0?i(r(e),0x1fffffffffffff):0}},function(e,t,a){var r=a(9);e.exports=function(e,t){var a,i;if(!r(e))return e;if(t&&"function"==typeof(a=e.toString)&&!r(i=a.call(e))||"function"==typeof(a=e.valueOf)&&!r(i=a.call(e))||!t&&"function"==typeof(a=e.toString)&&!r(i=a.call(e)))return i;throw TypeError("Can't convert object to primitive value")}},function(e,t){var a=0,r=Math.random();e.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++a+r).toString(36))}},function(e,t,a){"use strict";function r(e){return(0,s.createHash)("sha256").update(e).digest("hex")}function i(e){switch(d){case"darwin":return e.split("IOPlatformUUID")[1].split("\n")[0].replace(/\=|\s+|\"/gi,"").toLowerCase();case"win32":return e.toString().split("REG_SZ")[1].replace(/\r+|\n+|\s+/gi,"").toLowerCase();case"linux":case"freebsd":return e.toString().replace(/\r+|\n+|\s+/gi,"").toLowerCase();default:throw Error("Unsupported platform: "+process.platform)}}Object.defineProperty(t,"__esModule",{value:!0});var n,p=(n=a(35))&&n.__esModule?n:{default:n};t.machineIdSync=function(e){var t=i((0,o.execSync)(l[d]).toString());return e?t:r(t)},t.machineId=function(e){return new p.default(function(t,a){return(0,o.exec)(l[d],{},function(n,p,o){if(n)return a(Error("Error while obtaining machine id: "+n.stack));var s=i(p.toString());return t(e?s:r(s))})})};var o=a(70),s=a(71),d=process.platform,l={darwin:"ioreg -rd1 -c IOPlatformExpertDevice",win32:{native:"%windir%\\System32",mixed:"%windir%\\sysnative\\cmd.exe /c %windir%\\System32"}["win32"!==process.platform?"":"ia32"===process.arch&&process.env.hasOwnProperty("PROCESSOR_ARCHITEW6432")?"mixed":"native"]+"\\REG.exe QUERY HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Cryptography /v MachineGuid",linux:"( cat /var/lib/dbus/machine-id /etc/machine-id 2> /dev/null || hostname ) | head -n 1 || :",freebsd:"kenv -q smbios.system.uuid || sysctl -n kern.hostuuid"}},function(e,t,a){e.exports={default:a(36),__esModule:!0}},function(e,t,a){a(66),a(68),a(69),a(67),e.exports=a(6).Promise},function(e,t){e.exports=function(){}},function(e,t){e.exports=function(e,t,a,r){if(!(e instanceof t)||void 0!==r&&r in e)throw TypeError(a+": incorrect invocation!");return e}},function(e,t,a){var r=a(13),i=a(31),n=a(62);e.exports=function(e){return function(t,a,p){var o,s=r(t),d=i(s.length),l=n(p,d);if(e&&a!=a){for(;d>l;)if((o=s[l++])!=o)return!0}else for(;d>l;l++)if((e||l in s)&&s[l]===a)return e||l||0;return!e&&-1}}},function(e,t,a){var r=a(7),i=a(44),n=a(43),p=a(3),o=a(31),s=a(64),d={},l={},t=e.exports=function(e,t,a,u,c){var m,f,h,v,y=c?function(){return e}:s(e),g=r(a,u,t?2:1),_=0;if("function"!=typeof y)throw TypeError(e+" is not iterable!");if(n(y)){for(m=o(e.length);m>_;_++)if((v=t?g(p(f=e[_])[0],f[1]):g(e[_]))===d||v===l)return v}else for(h=y.call(e);!(f=h.next()).done;)if((v=i(h,g,f.value,t))===d||v===l)return v};t.BREAK=d,t.RETURN=l},function(e,t){e.exports=function(e,t,a){var r=void 0===a;switch(t.length){case 0:return r?e():e.call(a);case 1:return r?e(t[0]):e.call(a,t[0]);case 2:return r?e(t[0],t[1]):e.call(a,t[0],t[1]);case 3:return r?e(t[0],t[1],t[2]):e.call(a,t[0],t[1],t[2]);case 4:return r?e(t[0],t[1],t[2],t[3]):e.call(a,t[0],t[1],t[2],t[3])}return e.apply(a,t)}},function(e,t,a){var r=a(11);e.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==r(e)?e.split(""):Object(e)}},function(e,t,a){var r=a(10),i=a(1)("iterator"),n=Array.prototype;e.exports=function(e){return void 0!==e&&(r.Array===e||n[i]===e)}},function(e,t,a){var r=a(3);e.exports=function(e,t,a,i){try{return i?t(r(a)[0],a[1]):t(a)}catch(t){var n=e.return;throw void 0!==n&&r(n.call(e)),t}}},function(e,t,a){"use strict";var r=a(49),i=a(17),n=a(18),p={};a(5)(p,a(1)("iterator"),function(){return this}),e.exports=function(e,t,a){e.prototype=r(p,{next:i(1,a)}),n(e,t+" Iterator")}},function(e,t,a){var r=a(1)("iterator"),i=!1;try{var n=[7][r]();n.return=function(){i=!0},Array.from(n,function(){throw 2})}catch(e){}e.exports=function(e,t){if(!t&&!i)return!1;var a=!1;try{var n=[7],p=n[r]();p.next=function(){return{done:a=!0}},n[r]=function(){return p},e(n)}catch(e){}return a}},function(e,t){e.exports=function(e,t){return{value:t,done:!!e}}},function(e,t,a){var r=a(2),i=a(30).set,n=r.MutationObserver||r.WebKitMutationObserver,p=r.process,o=r.Promise,s="process"==a(11)(p);e.exports=function(){var e,t,a,d=function(){var r,i;for(s&&(r=p.domain)&&r.exit();e;){i=e.fn,e=e.next;try{i()}catch(r){throw e?a():t=void 0,r}}t=void 0,r&&r.enter()};if(s)a=function(){p.nextTick(d)};else if(n){var l=!0,u=document.createTextNode("");new n(d).observe(u,{characterData:!0}),a=function(){u.data=l=!l}}else if(o&&o.resolve){var c=o.resolve();a=function(){c.then(d)}}else a=function(){i.call(r,d)};return function(r){var i={fn:r,next:void 0};t&&(t.next=i),e||(e=i,a()),t=i}}},function(e,t,a){var r=a(3),i=a(50),n=a(22),p=a(19)("IE_PROTO"),o=function(){},s="prototype",d=function(){var e,t=a(16)("iframe"),r=n.length;for(t.style.display="none",a(25).appendChild(t),t.src="javascript:",(e=t.contentWindow.document).open(),e.write("<script>document.F=Object<\/script>"),e.close(),d=e.F;r--;)delete d[s][n[r]];return d()};e.exports=Object.create||function(e,t){var a;return null!==e?(o[s]=r(e),a=new o,o[s]=null,a[p]=e):a=d(),void 0===t?a:i(a,t)}},function(e,t,a){var r=a(12),i=a(3),n=a(54);e.exports=a(4)?Object.defineProperties:function(e,t){i(e);for(var a,p=n(t),o=p.length,s=0;o>s;)r.f(e,a=p[s++],t[a]);return e}},function(e,t,a){var r=a(55),i=a(17),n=a(13),p=a(32),o=a(8),s=a(26),d=Object.getOwnPropertyDescriptor;t.f=a(4)?d:function(e,t){if(e=n(e),t=p(t,!0),s)try{return d(e,t)}catch(e){}if(o(e,t))return i(!r.f.call(e,t),e[t])}},function(e,t,a){var r=a(8),i=a(63),n=a(19)("IE_PROTO"),p=Object.prototype;e.exports=Object.getPrototypeOf||function(e){return r(e=i(e),n)?e[n]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?p:null}},function(e,t,a){var r=a(8),i=a(13),n=a(39)(!1),p=a(19)("IE_PROTO");e.exports=function(e,t){var a,o=i(e),s=0,d=[];for(a in o)a!=p&&r(o,a)&&d.push(a);for(;t.length>s;)r(o,a=t[s++])&&(~n(d,a)||d.push(a));return d}},function(e,t,a){var r=a(53),i=a(22);e.exports=Object.keys||function(e){return r(e,i)}},function(e,t){t.f=({}).propertyIsEnumerable},function(e,t,a){var r=a(5);e.exports=function(e,t,a){for(var i in t)a&&e[i]?e[i]=t[i]:r(e,i,t[i]);return e}},function(e,t,a){e.exports=a(5)},function(e,t,a){var r=a(9),i=a(3),n=function(e,t){if(i(e),!r(t)&&null!==t)throw TypeError(t+": can't set as prototype!")};e.exports={set:Object.setPrototypeOf||("__proto__"in{}?function(e,t,r){try{(r=a(7)(Function.call,a(51).f(Object.prototype,"__proto__").set,2))(e,[]),t=!(e instanceof Array)}catch(e){t=!0}return function(e,a){return n(e,a),t?e.__proto__=a:r(e,a),e}}({},!1):void 0),check:n}},function(e,t,a){"use strict";var r=a(2),i=a(6),n=a(12),p=a(4),o=a(1)("species");e.exports=function(e){var t="function"==typeof i[e]?i[e]:r[e];p&&t&&!t[o]&&n.f(t,o,{configurable:!0,get:function(){return this}})}},function(e,t,a){var r=a(3),i=a(14),n=a(1)("species");e.exports=function(e,t){var a,p=r(e).constructor;return void 0===p||void 0==(a=r(p)[n])?t:i(a)}},function(e,t,a){var r=a(20),i=a(15);e.exports=function(e){return function(t,a){var n,p,o=String(i(t)),s=r(a),d=o.length;return s<0||s>=d?e?"":void 0:(n=o.charCodeAt(s))<55296||n>56319||s+1===d||(p=o.charCodeAt(s+1))<56320||p>57343?e?o.charAt(s):n:e?o.slice(s,s+2):(n-55296<<10)+(p-56320)+65536}}},function(e,t,a){var r=a(20),i=Math.max,n=Math.min;e.exports=function(e,t){return(e=r(e))<0?i(e+t,0):n(e,t)}},function(e,t,a){var r=a(15);e.exports=function(e){return Object(r(e))}},function(e,t,a){var r=a(21),i=a(1)("iterator"),n=a(10);e.exports=a(6).getIteratorMethod=function(e){if(void 0!=e)return e[i]||e["@@iterator"]||n[r(e)]}},function(e,t,a){"use strict";var r=a(37),i=a(47),n=a(10),p=a(13);e.exports=a(27)(Array,"Array",function(e,t){this._t=p(e),this._i=0,this._k=t},function(){var e=this._t,t=this._k,a=this._i++;return!e||a>=e.length?(this._t=void 0,i(1)):"keys"==t?i(0,a):"values"==t?i(0,e[a]):i(0,[a,e[a]])},"values"),n.Arguments=n.Array,r("keys"),r("values"),r("entries")},function(e,t){},function(e,t,a){"use strict";var r,i,n,p=a(28),o=a(2),s=a(7),d=a(21),l=a(23),u=a(9),c=(a(3),a(14)),m=a(38),f=a(40),h=(a(58).set,a(60)),v=a(30).set,y=a(48)(),g="Promise",_=o.TypeError,b=o.process,w=o[g],b=o.process,E="process"==d(b),T=function(){},N=!!function(){try{var e=w.resolve(1),t=(e.constructor={})[a(1)("species")]=function(e){e(T,T)};return(E||"function"==typeof PromiseRejectionEvent)&&e.then(T)instanceof t}catch(e){}}(),S=function(e,t){return e===t||e===w&&t===n},O=function(e){var t;return!(!u(e)||"function"!=typeof(t=e.then))&&t},I=function(e){return S(w,e)?new D(e):new i(e)},D=i=function(e){var t,a;this.promise=new e(function(e,r){if(void 0!==t||void 0!==a)throw _("Bad Promise constructor");t=e,a=r}),this.resolve=c(t),this.reject=c(a)},A=function(e){try{e()}catch(e){return{error:e}}},k=function(e,t){if(!e._n){e._n=!0;var a=e._c;y(function(){for(var r=e._v,i=1==e._s,n=0;a.length>n;)!function(t){var a,n,p=i?t.ok:t.fail,o=t.resolve,s=t.reject,d=t.domain;try{p?(i||(2==e._h&&R(e),e._h=1),!0===p?a=r:(d&&d.enter(),a=p(r),d&&d.exit()),a===t.promise?s(_("Promise-chain cycle")):(n=O(a))?n.call(a,o,s):o(a)):s(r)}catch(e){s(e)}}(a[n++]);e._c=[],e._n=!1,t&&!e._h&&x(e)})}},x=function(e){v.call(o,function(){var t,a,r,i=e._v;if(C(e)&&(t=A(function(){E?b.emit("unhandledRejection",i,e):(a=o.onunhandledrejection)?a({promise:e,reason:i}):(r=o.console)&&r.error&&r.error("Unhandled promise rejection",i)}),e._h=E||C(e)?2:1),e._a=void 0,t)throw t.error})},C=function(e){if(1==e._h)return!1;for(var t,a=e._a||e._c,r=0;a.length>r;)if((t=a[r++]).fail||!C(t.promise))return!1;return!0},R=function(e){v.call(o,function(){var t;E?b.emit("rejectionHandled",e):(t=o.onrejectionhandled)&&t({promise:e,reason:e._v})})},V=function(e){var t=this;t._d||(t._d=!0,(t=t._w||t)._v=e,t._s=2,t._a||(t._a=t._c.slice()),k(t,!0))},F=function(e){var t,a=this;if(!a._d){a._d=!0,a=a._w||a;try{if(a===e)throw _("Promise can't be resolved itself");(t=O(e))?y(function(){var r={_w:a,_d:!1};try{t.call(e,s(F,r,1),s(V,r,1))}catch(e){V.call(r,e)}}):(a._v=e,a._s=1,k(a,!1))}catch(e){V.call({_w:a,_d:!1},e)}}};N||(w=function(e){m(this,w,g,"_h"),c(e),r.call(this);try{e(s(F,this,1),s(V,this,1))}catch(e){V.call(this,e)}},(r=function(e){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1}).prototype=a(56)(w.prototype,{then:function(e,t){var a=I(h(this,w));return a.ok="function"!=typeof e||e,a.fail="function"==typeof t&&t,a.domain=E?b.domain:void 0,this._c.push(a),this._a&&this._a.push(a),this._s&&k(this,!1),a.promise},catch:function(e){return this.then(void 0,e)}}),D=function(){var e=new r;this.promise=e,this.resolve=s(F,e,1),this.reject=s(V,e,1)}),l(l.G+l.W+!N*l.F,{Promise:w}),a(18)(w,g),a(59)(g),n=a(6)[g],l(l.S+!N*l.F,g,{reject:function(e){var t=I(this);return(0,t.reject)(e),t.promise}}),l(l.S+l.F*(p||!N),g,{resolve:function(e){if(e instanceof w&&S(e.constructor,this))return e;var t=I(this);return(0,t.resolve)(e),t.promise}}),l(l.S+!(N&&a(46)(function(e){w.all(e).catch(T)}))*l.F,g,{all:function(e){var t=this,a=I(t),r=a.resolve,i=a.reject,n=A(function(){var a=[],n=0,p=1;f(e,!1,function(e){var o=n++,s=!1;a.push(void 0),p++,t.resolve(e).then(function(e){s||(s=!0,a[o]=e,--p||r(a))},i)}),--p||r(a)});return n&&i(n.error),a.promise},race:function(e){var t=this,a=I(t),r=a.reject,i=A(function(){f(e,!1,function(e){t.resolve(e).then(a.resolve,r)})});return i&&r(i.error),a.promise}})},function(e,t,a){"use strict";var r=a(61)(!0);a(27)(String,"String",function(e){this._t=String(e),this._i=0},function(){var e,t=this._t,a=this._i;return a>=t.length?{value:void 0,done:!0}:(e=r(t,a),this._i+=e.length,{value:e,done:!1})})},function(e,t,a){a(65);for(var r=a(2),i=a(5),n=a(10),p=a(1)("toStringTag"),o=["NodeList","DOMTokenList","MediaList","StyleSheetList","CSSRuleList"],s=0;s<5;s++){var d=o[s],l=r[d],u=l&&l.prototype;u&&!u[p]&&i(u,p,d),n[d]=n.Array}},function(e,t){e.exports=a(35317)},function(e,t){e.exports=a(76982)}];function i(e){if(n[e])return n[e].exports;var t=n[e]={exports:{},id:e,loaded:!1};return r[e].call(t.exports,t,t.exports,i),t.loaded=!0,t.exports}var n={};return i.m=r,i.c=n,i.p="",i(0)}(a(35317),a(76982))},35600(e,t,a){let r,i=a(70857),n=a(52018),p=a(56071),{env:o}=process;function s(e,t={}){var a;return 0!==(a=function(e,{streamIsTTY:t,sniffFlags:a=!0}={}){let n=function(){if("FORCE_COLOR"in o)return"true"===o.FORCE_COLOR?1:"false"===o.FORCE_COLOR?0:0===o.FORCE_COLOR.length?1:Math.min(Number.parseInt(o.FORCE_COLOR,10),3)}();void 0!==n&&(r=n);let s=a?r:n;if(0===s)return 0;if(a){if(p("color=16m")||p("color=full")||p("color=truecolor"))return 3;if(p("color=256"))return 2}if(e&&!t&&void 0===s)return 0;let d=s||0;if("dumb"===o.TERM)return d;if("win32"===process.platform){let e=i.release().split(".");return Number(e[0])>=10&&Number(e[2])>=10586?Number(e[2])>=14931?3:2:1}if("CI"in o)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE","DRONE"].some(e=>e in o)||"codeship"===o.CI_NAME?1:d;if("TEAMCITY_VERSION"in o)return+!!/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(o.TEAMCITY_VERSION);if("truecolor"===o.COLORTERM)return 3;if("TERM_PROGRAM"in o){let e=Number.parseInt((o.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(o.TERM_PROGRAM){case"iTerm.app":return e>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(o.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(o.TERM)||"COLORTERM"in o?1:d}(e,{streamIsTTY:e&&e.isTTY,...t}))&&{level:a,hasBasic:!0,has256:a>=2,has16m:a>=3}}p("no-color")||p("no-colors")||p("color=false")||p("color=never")?r=0:(p("color")||p("colors")||p("color=true")||p("color=always"))&&(r=1),e.exports={supportsColor:s,stdout:s({isTTY:n.isatty(1)}),stderr:s({isTTY:n.isatty(2)})}},23246(e,t,a){var r=a(24876),i=a(91749),n={TRANSITIONAL:0,NONTRANSITIONAL:1};function p(e){return e.split("\0").map(function(e){return e.normalize("NFC")}).join("\0")}function o(e){for(var t=0,a=i.length-1;t<=a;){var r=Math.floor((t+a)/2),n=i[r];if(n[0][0]<=e&&n[0][1]>=e)return n;n[0][0]>e?a=r-1:t=r+1}return null}var s=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g;function d(e){return e.replace(s,"_").length}var l=/[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08E4-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B62\u0B63\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0C00-\u0C03\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D01-\u0D03\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D82\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EB9\u0EBB\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F\u109A-\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u180B-\u180D\u18A9\u1920-\u192B\u1930-\u193B\u19B0-\u19C0\u19C8\u19C9\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F\u1AB0-\u1ABE\u1B00-\u1B04\u1B34-\u1B44\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BE6-\u1BF3\u1C24-\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF2-\u1CF4\u1CF8\u1CF9\u1DC0-\u1DF5\u1DFC-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA880\uA881\uA8B4-\uA8C4\uA8E0-\uA8F1\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9E5\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2D]|\uD800[\uDDFD\uDEE0\uDF76-\uDF7A]|\uD802[\uDE01-\uDE03\uDE05\uDE06\uDE0C-\uDE0F\uDE38-\uDE3A\uDE3F\uDEE5\uDEE6]|\uD804[\uDC00-\uDC02\uDC38-\uDC46\uDC7F-\uDC82\uDCB0-\uDCBA\uDD00-\uDD02\uDD27-\uDD34\uDD73\uDD80-\uDD82\uDDB3-\uDDC0\uDE2C-\uDE37\uDEDF-\uDEEA\uDF01-\uDF03\uDF3C\uDF3E-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF57\uDF62\uDF63\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDCB0-\uDCC3\uDDAF-\uDDB5\uDDB8-\uDDC0\uDE30-\uDE40\uDEAB-\uDEB7]|\uD81A[\uDEF0-\uDEF4\uDF30-\uDF36]|\uD81B[\uDF51-\uDF7E\uDF8F-\uDF92]|\uD82F[\uDC9D\uDC9E]|\uD834[\uDD65-\uDD69\uDD6D-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD83A[\uDCD0-\uDCD6]|\uDB40[\uDD00-\uDDEF]/;e.exports.toASCII=function(e,t,a,i){var s=function e(t,a,i){var s=function(e,t,a){for(var r=!1,i="",p=d(e),s=0;s<p;++s){var l=e.codePointAt(s),u=o(l);switch(u[1]){case"disallowed":r=!0,i+=String.fromCodePoint(l);break;case"ignored":break;case"mapped":i+=String.fromCodePoint.apply(String,u[2]);break;case"deviation":a===n.TRANSITIONAL?i+=String.fromCodePoint.apply(String,u[2]):i+=String.fromCodePoint(l);break;case"valid":i+=String.fromCodePoint(l);break;case"disallowed_STD3_mapped":t?(r=!0,i+=String.fromCodePoint(l)):i+=String.fromCodePoint.apply(String,u[2]);break;case"disallowed_STD3_valid":t&&(r=!0),i+=String.fromCodePoint(l)}}return{string:i,error:r}}(t,a,i);s.string=p(s.string);for(var u=s.string.split("."),c=0;c<u.length;++c)try{var m=function(t){"xn--"===t.substr(0,4)&&(t=r.toUnicode(t),n.NONTRANSITIONAL);var a=!1;(p(t)!==t||"-"===t[3]&&"-"===t[4]||"-"===t[0]||"-"===t[t.length-1]||-1!==t.indexOf(".")||0===t.search(l))&&(a=!0);for(var i=d(t),s=0;s<i;++s){var u=o(t.codePointAt(s));if(e===n.TRANSITIONAL&&"valid"!==u[1]||e===n.NONTRANSITIONAL&&"valid"!==u[1]&&"deviation"!==u[1]){a=!0;break}}return{label:t,error:a}}(u[c]);u[c]=m.label,s.error=s.error||m.error}catch(e){s.error=!0}return{string:u.join("."),error:s.error}}(e,t,a),u=s.string.split(".");if(u=u.map(function(e){try{return r.toASCII(e)}catch(t){return s.error=!0,e}}),i){var c=u.slice(0,u.length-1).join(".").length;(c.length>253||0===c.length)&&(s.error=!0);for(var m=0;m<u.length;++m)if(u.length>63||0===u.length){s.error=!0;break}}return s.error?null:u.join(".")},e.exports.PROCESSING_OPTIONS=n},98706(e,t,a){let r=a(78323);t.implementation=class{constructor(e){let t=e[0],a=e[1],i=null;if(void 0!==a&&"failure"===(i=r.basicURLParse(a)))throw TypeError("Invalid base URL");let n=r.basicURLParse(t,{baseURL:i});if("failure"===n)throw TypeError("Invalid URL");this._url=n}get href(){return r.serializeURL(this._url)}set href(e){let t=r.basicURLParse(e);if("failure"===t)throw TypeError("Invalid URL");this._url=t}get origin(){return r.serializeURLOrigin(this._url)}get protocol(){return this._url.scheme+":"}set protocol(e){r.basicURLParse(e+":",{url:this._url,stateOverride:"scheme start"})}get username(){return this._url.username}set username(e){r.cannotHaveAUsernamePasswordPort(this._url)||r.setTheUsername(this._url,e)}get password(){return this._url.password}set password(e){r.cannotHaveAUsernamePasswordPort(this._url)||r.setThePassword(this._url,e)}get host(){let e=this._url;return null===e.host?"":null===e.port?r.serializeHost(e.host):r.serializeHost(e.host)+":"+r.serializeInteger(e.port)}set host(e){this._url.cannotBeABaseURL||r.basicURLParse(e,{url:this._url,stateOverride:"host"})}get hostname(){return null===this._url.host?"":r.serializeHost(this._url.host)}set hostname(e){this._url.cannotBeABaseURL||r.basicURLParse(e,{url:this._url,stateOverride:"hostname"})}get port(){return null===this._url.port?"":r.serializeInteger(this._url.port)}set port(e){r.cannotHaveAUsernamePasswordPort(this._url)||(""===e?this._url.port=null:r.basicURLParse(e,{url:this._url,stateOverride:"port"}))}get pathname(){return this._url.cannotBeABaseURL?this._url.path[0]:0===this._url.path.length?"":"/"+this._url.path.join("/")}set pathname(e){this._url.cannotBeABaseURL||(this._url.path=[],r.basicURLParse(e,{url:this._url,stateOverride:"path start"}))}get search(){return null===this._url.query||""===this._url.query?"":"?"+this._url.query}set search(e){let t=this._url;if(""===e){t.query=null;return}let a="?"===e[0]?e.substring(1):e;t.query="",r.basicURLParse(a,{url:t,stateOverride:"query"})}get hash(){return null===this._url.fragment||""===this._url.fragment?"":"#"+this._url.fragment}set hash(e){if(""===e){this._url.fragment=null;return}let t="#"===e[0]?e.substring(1):e;this._url.fragment="",r.basicURLParse(t,{url:this._url,stateOverride:"fragment"})}toJSON(){return this.href}}},76447(e,t,a){let r=a(36151),i=a(4887),n=a(98706),p=i.implSymbol;function o(t){if(!this||this[p]||!(this instanceof o))throw TypeError("Failed to construct 'URL': Please use the 'new' operator, this DOM object constructor cannot be called as a function.");if(arguments.length<1)throw TypeError("Failed to construct 'URL': 1 argument required, but only "+arguments.length+" present.");let a=[];for(let e=0;e<arguments.length&&e<2;++e)a[e]=arguments[e];a[0]=r.USVString(a[0]),void 0!==a[1]&&(a[1]=r.USVString(a[1])),e.exports.setup(this,a)}o.prototype.toJSON=function(){if(!this||!e.exports.is(this))throw TypeError("Illegal invocation");let t=[];for(let e=0;e<arguments.length&&e<0;++e)t[e]=arguments[e];return this[p].toJSON.apply(this[p],t)},Object.defineProperty(o.prototype,"href",{get(){return this[p].href},set(e){e=r.USVString(e),this[p].href=e},enumerable:!0,configurable:!0}),o.prototype.toString=function(){if(!this||!e.exports.is(this))throw TypeError("Illegal invocation");return this.href},Object.defineProperty(o.prototype,"origin",{get(){return this[p].origin},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"protocol",{get(){return this[p].protocol},set(e){e=r.USVString(e),this[p].protocol=e},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"username",{get(){return this[p].username},set(e){e=r.USVString(e),this[p].username=e},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"password",{get(){return this[p].password},set(e){e=r.USVString(e),this[p].password=e},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"host",{get(){return this[p].host},set(e){e=r.USVString(e),this[p].host=e},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"hostname",{get(){return this[p].hostname},set(e){e=r.USVString(e),this[p].hostname=e},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"port",{get(){return this[p].port},set(e){e=r.USVString(e),this[p].port=e},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"pathname",{get(){return this[p].pathname},set(e){e=r.USVString(e),this[p].pathname=e},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"search",{get(){return this[p].search},set(e){e=r.USVString(e),this[p].search=e},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"hash",{get(){return this[p].hash},set(e){e=r.USVString(e),this[p].hash=e},enumerable:!0,configurable:!0}),e.exports={is:e=>!!e&&e[p]instanceof n.implementation,create(e,t){let a=Object.create(o.prototype);return this.setup(a,e,t),a},setup(e,t,a){a||(a={}),a.wrapper=e,e[p]=new n.implementation(t,a),e[p][i.wrapperSymbol]=e},interface:o,expose:{Window:{URL:o},Worker:{URL:o}}}},44044(e,t,a){t.k=a(76447).interface,a(78323).serializeURL,a(78323).serializeURLOrigin,a(78323).basicURLParse,a(78323).setTheUsername,a(78323).setThePassword,a(78323).serializeHost,a(78323).serializeInteger,a(78323).parseURL},78323(e,t,a){let r=a(24876),i=a(23246),n={ftp:21,file:null,gopher:70,http:80,https:443,ws:80,wss:443},p=Symbol("failure");function o(e){return r.ucs2.decode(e).length}function s(e,t){let a=e[t];return isNaN(a)?void 0:String.fromCodePoint(a)}function d(e){return e>=48&&e<=57}function l(e){return e>=65&&e<=90||e>=97&&e<=122}function u(e){return d(e)||e>=65&&e<=70||e>=97&&e<=102}function c(e){return"."===e||"%2e"===e.toLowerCase()}function m(e){return 2===e.length&&l(e.codePointAt(0))&&(":"===e[1]||"|"===e[1])}function f(e){return void 0!==n[e]}function h(e){return f(e.scheme)}function v(e){let t=e.toString(16).toUpperCase();return 1===t.length&&(t="0"+t),"%"+t}function y(e){return e<=31||e>126}let g=new Set([32,34,35,60,62,63,96,123,125]);function _(e){return y(e)||g.has(e)}let b=new Set([47,58,59,61,64,91,92,93,94,124]);function w(e){return _(e)||b.has(e)}function E(e,t){let a=String.fromCodePoint(e);if(t(e)){let e=new Buffer(a),t="";for(let a=0;a<e.length;++a)t+=v(e[a]);return t}return a}function T(e,t){if("["===e[0])return"]"!==e[e.length-1]?p:function(e){let t=[0,0,0,0,0,0,0,0],a=0,i=null,n=0;if(58===(e=r.ucs2.decode(e))[n]){if(58!==e[n+1])return p;n+=2,i=++a}for(;n<e.length;){if(8===a)return p;if(58===e[n]){if(null!==i)return p;++n,i=++a;continue}let r=0,o=0;for(;o<4&&u(e[n]);)r=16*r+parseInt(s(e,n),16),++n,++o;if(46===e[n]){if(0===o||(n-=o,a>6))return p;let r=0;for(;void 0!==e[n];){let i=null;if(r>0)if(46!==e[n]||!(r<4))return p;else++n;if(!d(e[n]))return p;for(;d(e[n]);){let t=parseInt(s(e,n));if(null===i)i=t;else{if(0===i)return p;i=10*i+t}if(i>255)return p;++n}t[a]=256*t[a]+i,(2==++r||4===r)&&++a}if(4!==r)return p;break}if(58===e[n]){if(void 0===e[++n])return p}else if(void 0!==e[n])return p;t[a]=r,++a}if(null!==i){let e=a-i;for(a=7;0!==a&&e>0;){let r=t[i+e-1];t[i+e-1]=t[a],t[a]=r,--a,--e}}else if(null===i&&8!==a)return p;return t}(e.substring(1,e.length-1));if(!t){var a=e;if(-1!==a.search(/\u0000|\u0009|\u000A|\u000D|\u0020|#|\/|:|\?|@|\[|\\|\]/))return p;let t="",i=r.ucs2.decode(a);for(let e=0;e<i.length;++e)t+=E(i[e],y);return t}let n=function(e){let t=new Buffer(e),a=[];for(let e=0;e<t.length;++e)37!==t[e]?a.push(t[e]):37===t[e]&&u(t[e+1])&&u(t[e+2])?(a.push(parseInt(t.slice(e+1,e+3).toString(),16)),e+=2):a.push(t[e]);return new Buffer(a).toString()}(e),o=i.toASCII(n,!1,i.PROCESSING_OPTIONS.NONTRANSITIONAL,!1);if(null===o||-1!==o.search(/\u0000|\u0009|\u000A|\u000D|\u0020|#|%|\/|:|\?|@|\[|\\|\]/))return p;let l=function(e){let t=e.split(".");if(""===t[t.length-1]&&t.length>1&&t.pop(),t.length>4)return e;let a=[];for(let r of t){if(""===r)return e;let t=function(e){let t=10;return(e.length>=2&&"0"===e.charAt(0)&&"x"===e.charAt(1).toLowerCase()?(e=e.substring(2),t=16):e.length>=2&&"0"===e.charAt(0)&&(e=e.substring(1),t=8),""===e)?0:(10===t?/[^0-9]/:16===t?/[^0-9A-Fa-f]/:/[^0-7]/).test(e)?p:parseInt(e,t)}(r);if(t===p)return e;a.push(t)}for(let e=0;e<a.length-1;++e)if(a[e]>255)return p;if(a[a.length-1]>=Math.pow(256,5-a.length))return p;let r=a.pop(),i=0;for(let e of a)r+=e*Math.pow(256,3-i),++i;return r}(o);return"number"==typeof l||l===p?l:o}function N(e){if("number"==typeof e){let t="",a=e;for(let e=1;e<=4;++e)t=String(a%256)+t,4!==e&&(t="."+t),a=Math.floor(a/256);return t}return e instanceof Array?"["+function(e){let t="",a=function(e){let t=null,a=1,r=null,i=0;for(let n=0;n<e.length;++n)0!==e[n]?(i>a&&(t=r,a=i),r=null,i=0):(null===r&&(r=n),++i);return i>a&&(t=r,a=i),{idx:t,len:a}}(e).idx,r=!1;for(let i=0;i<=7;++i)if(!r||0!==e[i]){if(r&&(r=!1),a===i){t+=0===i?"::":":",r=!0;continue}t+=e[i].toString(16),7!==i&&(t+=":")}return t}(e)+"]":e}function S(e){var t;let a=e.path;0===a.length||"file"===e.scheme&&1===a.length&&(t=a[0],/^[A-Za-z]:$/.test(t))||a.pop()}function O(e){return""!==e.username||""!==e.password}function I(e,t,a,i,n){if(this.pointer=0,this.input=e,this.base=t||null,this.encodingOverride=a||"utf-8",this.stateOverride=n,this.url=i,this.failure=!1,this.parseError=!1,!this.url){this.url={scheme:"",username:"",password:"",host:null,port:null,path:[],query:null,fragment:null,cannotBeABaseURL:!1};let e=this.input.replace(/^[\u0000-\u001F\u0020]+|[\u0000-\u001F\u0020]+$/g,"");e!==this.input&&(this.parseError=!0),this.input=e}let o=this.input.replace(/\u0009|\u000A|\u000D/g,"");for(o!==this.input&&(this.parseError=!0),this.input=o,this.state=n||"scheme start",this.buffer="",this.atFlag=!1,this.arrFlag=!1,this.passwordTokenSeenFlag=!1,this.input=r.ucs2.decode(this.input);this.pointer<=this.input.length;++this.pointer){let e=this.input[this.pointer],t=isNaN(e)?void 0:String.fromCodePoint(e),a=this["parse "+this.state](e,t);if(a){if(a===p){this.failure=!0;break}}else break}}I.prototype["parse scheme start"]=function(e,t){if(l(e))this.buffer+=t.toLowerCase(),this.state="scheme";else{if(this.stateOverride)return this.parseError=!0,p;this.state="no scheme",--this.pointer}return!0},I.prototype["parse scheme"]=function(e,t){if(l(e)||d(e)||43===e||45===e||46===e)this.buffer+=t.toLowerCase();else if(58===e){if(this.stateOverride&&(h(this.url)&&!f(this.buffer)||!h(this.url)&&f(this.buffer)||(O(this.url)||null!==this.url.port)&&"file"===this.buffer||"file"===this.url.scheme&&(""===this.url.host||null===this.url.host))||(this.url.scheme=this.buffer,this.buffer="",this.stateOverride))return!1;"file"===this.url.scheme?((47!==this.input[this.pointer+1]||47!==this.input[this.pointer+2])&&(this.parseError=!0),this.state="file"):h(this.url)&&null!==this.base&&this.base.scheme===this.url.scheme?this.state="special relative or authority":h(this.url)?this.state="special authority slashes":47===this.input[this.pointer+1]?(this.state="path or authority",++this.pointer):(this.url.cannotBeABaseURL=!0,this.url.path.push(""),this.state="cannot-be-a-base-URL path")}else{if(this.stateOverride)return this.parseError=!0,p;this.buffer="",this.state="no scheme",this.pointer=-1}return!0},I.prototype["parse no scheme"]=function(e){return null===this.base||this.base.cannotBeABaseURL&&35!==e?p:(this.base.cannotBeABaseURL&&35===e?(this.url.scheme=this.base.scheme,this.url.path=this.base.path.slice(),this.url.query=this.base.query,this.url.fragment="",this.url.cannotBeABaseURL=!0,this.state="fragment"):("file"===this.base.scheme?this.state="file":this.state="relative",--this.pointer),!0)},I.prototype["parse special relative or authority"]=function(e){return 47===e&&47===this.input[this.pointer+1]?(this.state="special authority ignore slashes",++this.pointer):(this.parseError=!0,this.state="relative",--this.pointer),!0},I.prototype["parse path or authority"]=function(e){return 47===e?this.state="authority":(this.state="path",--this.pointer),!0},I.prototype["parse relative"]=function(e){return this.url.scheme=this.base.scheme,isNaN(e)?(this.url.username=this.base.username,this.url.password=this.base.password,this.url.host=this.base.host,this.url.port=this.base.port,this.url.path=this.base.path.slice(),this.url.query=this.base.query):47===e?this.state="relative slash":63===e?(this.url.username=this.base.username,this.url.password=this.base.password,this.url.host=this.base.host,this.url.port=this.base.port,this.url.path=this.base.path.slice(),this.url.query="",this.state="query"):35===e?(this.url.username=this.base.username,this.url.password=this.base.password,this.url.host=this.base.host,this.url.port=this.base.port,this.url.path=this.base.path.slice(),this.url.query=this.base.query,this.url.fragment="",this.state="fragment"):h(this.url)&&92===e?(this.parseError=!0,this.state="relative slash"):(this.url.username=this.base.username,this.url.password=this.base.password,this.url.host=this.base.host,this.url.port=this.base.port,this.url.path=this.base.path.slice(0,this.base.path.length-1),this.state="path",--this.pointer),!0},I.prototype["parse relative slash"]=function(e){return h(this.url)&&(47===e||92===e)?(92===e&&(this.parseError=!0),this.state="special authority ignore slashes"):47===e?this.state="authority":(this.url.username=this.base.username,this.url.password=this.base.password,this.url.host=this.base.host,this.url.port=this.base.port,this.state="path",--this.pointer),!0},I.prototype["parse special authority slashes"]=function(e){return 47===e&&47===this.input[this.pointer+1]?(this.state="special authority ignore slashes",++this.pointer):(this.parseError=!0,this.state="special authority ignore slashes",--this.pointer),!0},I.prototype["parse special authority ignore slashes"]=function(e){return 47!==e&&92!==e?(this.state="authority",--this.pointer):this.parseError=!0,!0},I.prototype["parse authority"]=function(e,t){if(64===e){this.parseError=!0,this.atFlag&&(this.buffer="%40"+this.buffer),this.atFlag=!0;let e=o(this.buffer);for(let t=0;t<e;++t){let e=this.buffer.codePointAt(t);if(58===e&&!this.passwordTokenSeenFlag){this.passwordTokenSeenFlag=!0;continue}let a=E(e,w);this.passwordTokenSeenFlag?this.url.password+=a:this.url.username+=a}this.buffer=""}else if(isNaN(e)||47===e||63===e||35===e||h(this.url)&&92===e){if(this.atFlag&&""===this.buffer)return this.parseError=!0,p;this.pointer-=o(this.buffer)+1,this.buffer="",this.state="host"}else this.buffer+=t;return!0},I.prototype["parse hostname"]=I.prototype["parse host"]=function(e,t){if(this.stateOverride&&"file"===this.url.scheme)--this.pointer,this.state="file host";else if(58!==e||this.arrFlag)if(isNaN(e)||47===e||63===e||35===e||h(this.url)&&92===e){if(--this.pointer,h(this.url)&&""===this.buffer)return this.parseError=!0,p;if(this.stateOverride&&""===this.buffer&&(O(this.url)||null!==this.url.port))return this.parseError=!0,!1;let e=T(this.buffer,h(this.url));if(e===p)return p;if(this.url.host=e,this.buffer="",this.state="path start",this.stateOverride)return!1}else 91===e?this.arrFlag=!0:93===e&&(this.arrFlag=!1),this.buffer+=t;else{if(""===this.buffer)return this.parseError=!0,p;let e=T(this.buffer,h(this.url));if(e===p)return p;if(this.url.host=e,this.buffer="",this.state="port","hostname"===this.stateOverride)return!1}return!0},I.prototype["parse port"]=function(e,t){if(d(e))this.buffer+=t;else{if(!(isNaN(e)||47===e||63===e||35===e||h(this.url)&&92===e)&&!this.stateOverride)return this.parseError=!0,p;if(""!==this.buffer){let e=parseInt(this.buffer);if(e>65535)return this.parseError=!0,p;this.url.port=e===n[this.url.scheme]?null:e,this.buffer=""}if(this.stateOverride)return!1;this.state="path start",--this.pointer}return!0};let D=new Set([47,92,63,35]);I.prototype["parse file"]=function(e){if(this.url.scheme="file",47===e||92===e)92===e&&(this.parseError=!0),this.state="file slash";else if(null!==this.base&&"file"===this.base.scheme)if(isNaN(e))this.url.host=this.base.host,this.url.path=this.base.path.slice(),this.url.query=this.base.query;else if(63===e)this.url.host=this.base.host,this.url.path=this.base.path.slice(),this.url.query="",this.state="query";else if(35===e)this.url.host=this.base.host,this.url.path=this.base.path.slice(),this.url.query=this.base.query,this.url.fragment="",this.state="fragment";else{var t;this.input.length-this.pointer-1!=0&&(t=this.input[this.pointer+1],l(e)&&(58===t||124===t))&&(!(this.input.length-this.pointer-1>=2)||D.has(this.input[this.pointer+2]))?this.parseError=!0:(this.url.host=this.base.host,this.url.path=this.base.path.slice(),S(this.url)),this.state="path",--this.pointer}else this.state="path",--this.pointer;return!0},I.prototype["parse file slash"]=function(e){if(47===e||92===e)92===e&&(this.parseError=!0),this.state="file host";else{if(null!==this.base&&"file"===this.base.scheme){var t;2===(t=this.base.path[0]).length&&l(t.codePointAt(0))&&":"===t[1]?this.url.path.push(this.base.path[0]):this.url.host=this.base.host}this.state="path",--this.pointer}return!0},I.prototype["parse file host"]=function(e,t){if(isNaN(e)||47===e||92===e||63===e||35===e)if(--this.pointer,!this.stateOverride&&m(this.buffer))this.parseError=!0,this.state="path";else if(""===this.buffer){if(this.url.host="",this.stateOverride)return!1;this.state="path start"}else{let e=T(this.buffer,h(this.url));if(e===p)return p;if("localhost"===e&&(e=""),this.url.host=e,this.stateOverride)return!1;this.buffer="",this.state="path start"}else this.buffer+=t;return!0},I.prototype["parse path start"]=function(e){return h(this.url)?(92===e&&(this.parseError=!0),this.state="path",47!==e&&92!==e&&--this.pointer):this.stateOverride||63!==e?this.stateOverride||35!==e?void 0!==e&&(this.state="path",47!==e&&--this.pointer):(this.url.fragment="",this.state="fragment"):(this.url.query="",this.state="query"),!0},I.prototype["parse path"]=function(e){if(isNaN(e)||47===e||h(this.url)&&92===e||!this.stateOverride&&(63===e||35===e)){var t;if((h(this.url)&&92===e&&(this.parseError=!0),".."===(t=(t=this.buffer).toLowerCase())||"%2e."===t||".%2e"===t||"%2e%2e"===t)?(S(this.url),47===e||h(this.url)&&92===e||this.url.path.push("")):c(this.buffer)&&47!==e&&!(h(this.url)&&92===e)?this.url.path.push(""):c(this.buffer)||("file"===this.url.scheme&&0===this.url.path.length&&m(this.buffer)&&(""!==this.url.host&&null!==this.url.host&&(this.parseError=!0,this.url.host=""),this.buffer=this.buffer[0]+":"),this.url.path.push(this.buffer)),this.buffer="","file"===this.url.scheme&&(void 0===e||63===e||35===e))for(;this.url.path.length>1&&""===this.url.path[0];)this.parseError=!0,this.url.path.shift();63===e&&(this.url.query="",this.state="query"),35===e&&(this.url.fragment="",this.state="fragment")}else 37!==e||u(this.input[this.pointer+1])&&u(this.input[this.pointer+2])||(this.parseError=!0),this.buffer+=E(e,_);return!0},I.prototype["parse cannot-be-a-base-URL path"]=function(e){return 63===e?(this.url.query="",this.state="query"):35===e?(this.url.fragment="",this.state="fragment"):(isNaN(e)||37===e||(this.parseError=!0),37!==e||u(this.input[this.pointer+1])&&u(this.input[this.pointer+2])||(this.parseError=!0),isNaN(e)||(this.url.path[0]=this.url.path[0]+E(e,y))),!0},I.prototype["parse query"]=function(e,t){if(isNaN(e)||!this.stateOverride&&35===e){h(this.url)&&"ws"!==this.url.scheme&&"wss"!==this.url.scheme||(this.encodingOverride="utf-8");let t=new Buffer(this.buffer);for(let e=0;e<t.length;++e)t[e]<33||t[e]>126||34===t[e]||35===t[e]||60===t[e]||62===t[e]?this.url.query+=v(t[e]):this.url.query+=String.fromCodePoint(t[e]);this.buffer="",35===e&&(this.url.fragment="",this.state="fragment")}else 37!==e||u(this.input[this.pointer+1])&&u(this.input[this.pointer+2])||(this.parseError=!0),this.buffer+=t;return!0},I.prototype["parse fragment"]=function(e){return isNaN(e)||(0===e?this.parseError=!0:(37!==e||u(this.input[this.pointer+1])&&u(this.input[this.pointer+2])||(this.parseError=!0),this.url.fragment+=E(e,y))),!0},e.exports.serializeURL=function(e,t){let a=e.scheme+":";if(null!==e.host?(a+="//",(""!==e.username||""!==e.password)&&(a+=e.username,""!==e.password&&(a+=":"+e.password),a+="@"),a+=N(e.host),null!==e.port&&(a+=":"+e.port)):null===e.host&&"file"===e.scheme&&(a+="//"),e.cannotBeABaseURL)a+=e.path[0];else for(let t of e.path)a+="/"+t;return null!==e.query&&(a+="?"+e.query),t||null===e.fragment||(a+="#"+e.fragment),a},e.exports.serializeURLOrigin=function(t){switch(t.scheme){case"blob":try{return e.exports.serializeURLOrigin(e.exports.parseURL(t.path[0]))}catch(e){return"null"}case"ftp":case"gopher":case"http":case"https":case"ws":case"wss":var a;let r;return r=(a={scheme:t.scheme,host:t.host,port:t.port}).scheme+"://"+N(a.host),null!==a.port&&(r+=":"+a.port),r;case"file":return"file://";default:return"null"}},e.exports.basicURLParse=function(e,t){void 0===t&&(t={});let a=new I(e,t.baseURL,t.encodingOverride,t.url,t.stateOverride);return a.failure?"failure":a.url},e.exports.setTheUsername=function(e,t){e.username="";let a=r.ucs2.decode(t);for(let t=0;t<a.length;++t)e.username+=E(a[t],w)},e.exports.setThePassword=function(e,t){e.password="";let a=r.ucs2.decode(t);for(let t=0;t<a.length;++t)e.password+=E(a[t],w)},e.exports.serializeHost=N,e.exports.cannotHaveAUsernamePasswordPort=function(e){return null===e.host||""===e.host||e.cannotBeABaseURL||"file"===e.scheme},e.exports.serializeInteger=function(e){return String(e)},e.exports.parseURL=function(t,a){return void 0===a&&(a={}),e.exports.basicURLParse(t,{baseURL:a.baseURL,encodingOverride:a.encodingOverride})}},4887(e){e.exports.wrapperSymbol=Symbol("wrapper"),e.exports.implSymbol=Symbol("impl")},36151(e){var t={};function a(e,t){!t.unsigned&&--e;let a=t.unsigned?0:-Math.pow(2,e),r=Math.pow(2,e)-1,i=t.moduloBitLength?Math.pow(2,t.moduloBitLength):Math.pow(2,e),n=t.moduloBitLength?Math.pow(2,t.moduloBitLength-1):Math.pow(2,e-1);return function(e,p){p||(p={});let o=+e;if(p.enforceRange){if(!Number.isFinite(o))throw TypeError("Argument is not a finite number");if((o=(o<0?-1:1)*Math.floor(Math.abs(o)))<a||o>r)throw TypeError("Argument is not in byte range");return o}if(!isNaN(o)&&p.clamp){var s;return(o=(s=o)%1==.5&&(1&s)==0?Math.floor(s):Math.round(s))<a&&(o=a),o>r&&(o=r),o}if(!Number.isFinite(o)||0===o)return 0;if(o=(o<0?-1:1)*Math.floor(Math.abs(o))%i,!t.unsigned&&o>=n)return o-i;if(t.unsigned){if(o<0)o+=i;else if(-0===o)return 0}return o}}e.exports=t,t.void=function(){},t.boolean=function(e){return!!e},t.byte=a(8,{unsigned:!1}),t.octet=a(8,{unsigned:!0}),t.short=a(16,{unsigned:!1}),t["unsigned short"]=a(16,{unsigned:!0}),t.long=a(32,{unsigned:!1}),t["unsigned long"]=a(32,{unsigned:!0}),t["long long"]=a(32,{unsigned:!1,moduloBitLength:64}),t["unsigned long long"]=a(32,{unsigned:!0,moduloBitLength:64}),t.double=function(e){let t=+e;if(!Number.isFinite(t))throw TypeError("Argument is not a finite floating-point value");return t},t["unrestricted double"]=function(e){let t=+e;if(isNaN(t))throw TypeError("Argument is NaN");return t},t.float=t.double,t["unrestricted float"]=t["unrestricted double"],t.DOMString=function(e,t){return(t||(t={}),t.treatNullAsEmptyString&&null===e)?"":String(e)},t.ByteString=function(e,t){let a,r=String(e);for(let e=0;void 0!==(a=r.codePointAt(e));++e)if(a>255)throw TypeError("Argument is not a valid bytestring");return r},t.USVString=function(e){let t=String(e),a=t.length,r=[];for(let e=0;e<a;++e){let i=t.charCodeAt(e);if(i<55296||i>57343)r.push(String.fromCodePoint(i));else if(56320<=i&&i<=57343)r.push(String.fromCodePoint(65533));else if(e===a-1)r.push(String.fromCodePoint(65533));else{let a=t.charCodeAt(e+1);if(56320<=a&&a<=57343){let t=1023&i,n=1023&a;r.push(String.fromCodePoint(65536+1024*t+n)),++e}else r.push(String.fromCodePoint(65533))}}return r.join("")},t.Date=function(e,t){if(!(e instanceof Date))throw TypeError("Argument is not a Date object");if(!isNaN(e))return e},t.RegExp=function(e,t){return e instanceof RegExp||(e=new RegExp(e)),e}},42613(e){e.exports=t("assert")},35317(e){e.exports=t("child_process")},76982(e){e.exports=t("crypto")},24434(e){e.exports=t("events")},69278(e){e.exports=t("net")},70857(e){e.exports=t("os")},24876(e){e.exports=t("punycode")},64756(e){e.exports=t("tls")},52018(e){e.exports=t("tty")},87016(e){e.exports=t("url")},39023(e){e.exports=t("util")},54506(e,t,a){Object.defineProperty(t,"__esModule",{value:!0});var r,i=a(85608),n=a(70916),p=a(4232),o=a(28876),s=a(55888),d=a(5437),l=a(94037),u=a(53570),c=a(60837),m=a(44592),f=a(39283),h=a(36869),v=a(25979),y=a(19371),g=a(94370),_=s&&"object"==typeof s&&"default"in s?s.default:s;function b(e){return null!==e&&"object"==typeof e}var w=Object.prototype.hasOwnProperty,E=function(e,t,a){return this.merge(e[a],t[a])},T=function(){function e(e){void 0===e&&(e=E),this.reconciler=e,this.isObject=b,this.pastCopies=new Set}return e.prototype.merge=function(e,t){for(var a=this,r=[],n=2;n<arguments.length;n++)r[n-2]=arguments[n];return b(t)&&b(e)?(Object.keys(t).forEach(function(n){if(w.call(e,n)){var p=e[n];if(t[n]!==p){var o=a.reconciler.apply(a,i.__spreadArray([e,t,n],r,!1));o!==p&&((e=a.shallowCopyForMerge(e))[n]=o)}}else(e=a.shallowCopyForMerge(e))[n]=t[n]}),e):t},e.prototype.shallowCopyForMerge=function(e){return b(e)&&!this.pastCopies.has(e)&&(e=Array.isArray(e)?e.slice(0):i.__assign({__proto__:Object.getPrototypeOf(e)},e),this.pastCopies.add(e)),e},e}();function N(e){return!!e&&e<7}function S(e){return!!e.directives&&e.directives.some(O)}function O(e){return"nonreactive"===e.name.value}t.NetworkStatus=void 0,(r=t.NetworkStatus||(t.NetworkStatus={}))[r.loading=1]="loading",r[r.setVariables=2]="setVariables",r[r.fetchMore=3]="fetchMore",r[r.refetch=4]="refetch",r[r.poll=6]="poll",r[r.ready=7]="ready",r[r.error=8]="error";var I=Object.assign,D=Object.hasOwnProperty,A=function(e){function a(t){var r=t.queryManager,n=t.queryInfo,p=t.options,o=this,s=a.inactiveOnCreation.getValue();(o=e.call(this,function(e){s&&(r.queries.set(o.queryId,n),s=!1);try{var t=e._subscription._observer;t&&!t.error&&(t.error=k)}catch(e){}var a=!o.observers.size;o.observers.add(e);var i=o.last;return i&&i.error?e.error&&e.error(i.error):i&&i.result&&e.next&&e.next(o.maskResult(i.result)),a&&o.reobserve().catch(function(){}),function(){o.observers.delete(e)&&!o.observers.size&&o.tearDownQuery()}})||this).observers=new Set,o.subscriptions=new Set,o.dirty=!1,o.queryInfo=n,o.queryManager=r,o.waitForOwnResult=C(p.fetchPolicy),o.isTornDown=!1,o.subscribeToMore=o.subscribeToMore.bind(o),o.maskResult=o.maskResult.bind(o);var l=r.defaultOptions.watchQuery,u=(void 0===l?{}:l).fetchPolicy,c=void 0===u?"cache-first":u,m=p.fetchPolicy,f=void 0===m?c:m,h=p.initialFetchPolicy,v=void 0===h?"standby"===f?c:f:h;o.options=i.__assign(i.__assign({},p),{initialFetchPolicy:v,fetchPolicy:f}),o.queryId=n.queryId||r.generateQueryId();var y=d.getOperationDefinition(o.query);return o.queryName=y&&y.name&&y.name.value,o}return i.__extends(a,e),Object.defineProperty(a.prototype,"query",{get:function(){return this.lastQuery||this.options.query},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"variables",{get:function(){return this.options.variables},enumerable:!1,configurable:!0}),a.prototype.result=function(){var e=this;return new Promise(function(t,a){var r={next:function(a){t(a),e.observers.delete(r),e.observers.size||e.queryManager.removeQuery(e.queryId),setTimeout(function(){i.unsubscribe()},0)},error:a},i=e.subscribe(r)})},a.prototype.resetDiff=function(){this.queryInfo.resetDiff()},a.prototype.getCurrentFullResult=function(e){void 0===e&&(e=!0);var a=this.getLastResult(!0),r=this.queryInfo.networkStatus||a&&a.networkStatus||t.NetworkStatus.ready,n=i.__assign(i.__assign({},a),{loading:N(r),networkStatus:r}),p=this.options.fetchPolicy,o=void 0===p?"cache-first":p;if(C(o)||this.queryManager.getDocumentInfo(this.query).hasForcedResolvers);else if(this.waitForOwnResult)this.queryInfo.updateWatch();else{var d=this.queryInfo.getDiff();(d.complete||this.options.returnPartialData)&&(n.data=d.result),s.equal(n.data,{})&&(n.data=void 0),d.complete?(delete n.partial,d.complete&&n.networkStatus===t.NetworkStatus.loading&&("cache-first"===o||"cache-only"===o)&&(n.networkStatus=t.NetworkStatus.ready,n.loading=!1)):n.partial=!0,n.networkStatus===t.NetworkStatus.ready&&(n.error||n.errors)&&(n.networkStatus=t.NetworkStatus.error),!1===globalThis.__DEV__||d.complete||this.options.partialRefetch||n.loading||n.data||n.error||x(d.missing)}return e&&this.updateLastResult(n),n},a.prototype.getCurrentResult=function(e){return void 0===e&&(e=!0),this.maskResult(this.getCurrentFullResult(e))},a.prototype.isDifferentFromLastResult=function(e,t){if(!this.last)return!0;var a,r,n,p,o,l=this.queryManager.getDocumentInfo(this.query),u=this.queryManager.dataMasking,c=u?l.nonReactiveQuery:this.query;return(u||l.hasNonreactiveDirective?(a=this.last.result,r=this.variables,n=a.data,p=i.__rest(a,["data"]),o=e.data,!(_(p,i.__rest(e,["data"]))&&function e(t,a,r,i){if(a===r)return!0;var n=new Set;return t.selections.every(function(t){if(n.has(t)||(n.add(t),!d.shouldInclude(t,i.variables)||S(t)))return!0;if(d.isField(t)){var p=d.resultKeyNameFromField(t),o=a&&a[p],s=r&&r[p],l=t.selectionSet;if(!l)return _(o,s);var u=Array.isArray(o),c=Array.isArray(s);if(u!==c)return!1;if(u&&c){var m=o.length;if(s.length!==m)return!1;for(var f=0;f<m;++f)if(!e(l,o[f],s[f],i))return!1;return!0}return e(l,o,s,i)}var h=d.getFragmentFromSelection(t,i.fragmentMap);if(h)return!!S(h)||e(h.selectionSet,a,r,i)})}(d.getMainDefinition(c).selectionSet,n,o,{fragmentMap:d.createFragmentMap(d.getFragmentDefinitions(c)),variables:r}))):!s.equal(this.last.result,e))||t&&!s.equal(this.last.variables,t)},a.prototype.getLast=function(e,t){var a=this.last;if(a&&a[e]&&(!t||s.equal(a.variables,this.variables)))return a[e]},a.prototype.getLastResult=function(e){return this.getLast("result",e)},a.prototype.getLastError=function(e){return this.getLast("error",e)},a.prototype.resetLastResults=function(){delete this.last,this.isTornDown=!1},a.prototype.resetQueryStoreErrors=function(){this.queryManager.resetErrors(this.queryId)},a.prototype.refetch=function(e){var a,r={pollInterval:0};if("no-cache"===this.options.fetchPolicy?r.fetchPolicy="no-cache":r.fetchPolicy="network-only",!1!==globalThis.__DEV__&&e&&D.call(e,"variables")){var p=d.getQueryDefinition(this.query),o=p.variableDefinitions;o&&o.some(function(e){return"variables"===e.variable.name.value})||!1===globalThis.__DEV__||n.invariant.warn(21,e,(null==(a=p.name)?void 0:a.value)||p)}return e&&!s.equal(this.options.variables,e)&&(r.variables=this.options.variables=i.__assign(i.__assign({},this.options.variables),e)),this.queryInfo.resetLastWrite(),this.reobserve(r,t.NetworkStatus.refetch)},a.prototype.fetchMore=function(e){var a=this,r=i.__assign(i.__assign({},e.query?e:i.__assign(i.__assign(i.__assign(i.__assign({},this.options),{query:this.options.query}),e),{variables:i.__assign(i.__assign({},this.options.variables),e.variables)})),{fetchPolicy:"no-cache"});r.query=this.transformDocument(r.query);var p=this.queryManager.generateQueryId();this.lastQuery=e.query?this.transformDocument(this.options.query):r.query;var o=this.queryInfo,s=o.networkStatus;o.networkStatus=t.NetworkStatus.fetchMore,r.notifyOnNetworkStatusChange&&this.observe();var d=new Set,l=null==e?void 0:e.updateQuery,u="no-cache"!==this.options.fetchPolicy;return u||n.invariant(l,22),this.queryManager.fetchQuery(p,r,t.NetworkStatus.fetchMore).then(function(n){if(a.queryManager.removeQuery(p),o.networkStatus===t.NetworkStatus.fetchMore&&(o.networkStatus=s),u)a.queryManager.cache.batch({update:function(t){var i=e.updateQuery;i?t.updateQuery({query:a.query,variables:a.variables,returnPartialData:!0,optimistic:!1},function(e){return i(e,{fetchMoreResult:n.data,variables:r.variables})}):t.writeQuery({query:r.query,variables:r.variables,data:n.data})},onWatchUpdated:function(e){d.add(e.query)}});else{var c=a.getLast("result"),m=l(c.data,{fetchMoreResult:n.data,variables:r.variables});a.reportResult(i.__assign(i.__assign({},c),{networkStatus:s,loading:N(s),data:m}),a.variables)}return a.maskResult(n)}).finally(function(){u&&!d.has(a.query)&&a.reobserveCacheFirst()})},a.prototype.subscribeToMore=function(e){var t=this,a=this.queryManager.startGraphQLSubscription({query:e.document,variables:e.variables,context:e.context}).subscribe({next:function(a){var r=e.updateQuery;r&&t.updateQuery(function(e,t){return r(e,i.__assign({subscriptionData:a},t))})},error:function(t){e.onError?e.onError(t):!1!==globalThis.__DEV__&&n.invariant.error(23,t)}});return this.subscriptions.add(a),function(){t.subscriptions.delete(a)&&a.unsubscribe()}},a.prototype.setOptions=function(e){return this.reobserve(e)},a.prototype.silentSetOptions=function(e){var t=d.compact(this.options,e||{});I(this.options,t)},a.prototype.setVariables=function(e){return s.equal(this.variables,e)?this.observers.size?this.result():Promise.resolve():(this.options.variables=e,this.observers.size)?this.reobserve({fetchPolicy:this.options.initialFetchPolicy,variables:e},t.NetworkStatus.setVariables):Promise.resolve()},a.prototype.updateQuery=function(e){var t=this.queryManager,a=t.cache.diff({query:this.options.query,variables:this.variables,returnPartialData:!0,optimistic:!1}),r=a.result,i=a.complete,n=e(r,{variables:this.variables,complete:!!i,previousData:r});n&&(t.cache.writeQuery({query:this.options.query,data:n,variables:this.variables}),t.broadcastQueries())},a.prototype.startPolling=function(e){this.options.pollInterval=e,this.updatePolling()},a.prototype.stopPolling=function(){this.options.pollInterval=0,this.updatePolling()},a.prototype.applyNextFetchPolicy=function(e,t){if(t.nextFetchPolicy){var a=t.fetchPolicy,r=void 0===a?"cache-first":a,i=t.initialFetchPolicy,n=void 0===i?r:i;"standby"===r||("function"==typeof t.nextFetchPolicy?t.fetchPolicy=t.nextFetchPolicy(r,{reason:e,options:t,observable:this,initialFetchPolicy:n}):"variables-changed"===e?t.fetchPolicy=n:t.fetchPolicy=t.nextFetchPolicy)}return t.fetchPolicy},a.prototype.fetch=function(e,t,a){var r=this.queryManager.getOrCreateQuery(this.queryId);return r.setObservableQuery(this),this.queryManager.fetchConcastWithInfo(r,e,t,a)},a.prototype.updatePolling=function(){var e=this;if(!this.queryManager.ssrMode){var a=this.pollingInfo,r=this.options.pollInterval;if(!r||!this.hasObservers()){a&&(clearTimeout(a.timeout),delete this.pollingInfo);return}if(!a||a.interval!==r){n.invariant(r,24),(a||(this.pollingInfo={})).interval=r;var i=function(){var a,r;e.pollingInfo&&(N(e.queryInfo.networkStatus)||(null==(r=(a=e.options).skipPollAttempt)?void 0:r.call(a))?p():e.reobserve({fetchPolicy:"no-cache"===e.options.initialFetchPolicy?"no-cache":"network-only"},t.NetworkStatus.poll).then(p,p))},p=function(){var t=e.pollingInfo;t&&(clearTimeout(t.timeout),t.timeout=setTimeout(i,t.interval))};p()}}},a.prototype.updateLastResult=function(e,t){void 0===t&&(t=this.variables);var a=this.getLastError();return a&&this.last&&!s.equal(t,this.last.variables)&&(a=void 0),this.last=i.__assign({result:this.queryManager.assumeImmutableResults?e:d.cloneDeep(e),variables:t},a?{error:a}:null)},a.prototype.reobserveAsConcast=function(e,a){var r=this;this.isTornDown=!1;var n=a===t.NetworkStatus.refetch||a===t.NetworkStatus.fetchMore||a===t.NetworkStatus.poll,p=this.options.variables,o=this.options.fetchPolicy,l=d.compact(this.options,e||{}),c=n?l:I(this.options,l),m=this.transformDocument(c.query);this.lastQuery=m,!n&&(this.updatePolling(),e&&e.variables&&!s.equal(e.variables,p)&&"standby"!==c.fetchPolicy&&(c.fetchPolicy===o||"function"==typeof c.nextFetchPolicy)&&(this.applyNextFetchPolicy("variables-changed",c),void 0===a&&(a=t.NetworkStatus.setVariables))),this.waitForOwnResult&&(this.waitForOwnResult=C(c.fetchPolicy));var f=function(){r.concast===y&&(r.waitForOwnResult=!1)},h=c.variables&&i.__assign({},c.variables),v=this.fetch(c,a,m),y=v.concast,g=v.fromLink,_={next:function(e){s.equal(r.variables,h)&&(f(),r.reportResult(e,h))},error:function(e){s.equal(r.variables,h)&&(u.isApolloError(e)||(e=new u.ApolloError({networkError:e})),f(),r.reportError(e,h))}};return n||!g&&this.concast||(this.concast&&this.observer&&this.concast.removeObserver(this.observer),this.concast=y,this.observer=_),y.addObserver(_),y},a.prototype.reobserve=function(e,t){return d.preventUnhandledRejection(this.reobserveAsConcast(e,t).promise.then(this.maskResult))},a.prototype.resubscribeAfterError=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var a=this.last;this.resetLastResults();var r=this.subscribe.apply(this,e);return this.last=a,r},a.prototype.observe=function(){this.reportResult(this.getCurrentFullResult(!1),this.variables)},a.prototype.reportResult=function(e,t){var a=this.getLastError(),r=this.isDifferentFromLastResult(e,t);(a||!e.partial||this.options.returnPartialData)&&this.updateLastResult(e,t),(a||r)&&d.iterateObserversSafely(this.observers,"next",this.maskResult(e))},a.prototype.reportError=function(e,a){var r=i.__assign(i.__assign({},this.getLastResult()),{error:e,errors:e.graphQLErrors,networkStatus:t.NetworkStatus.error,loading:!1});this.updateLastResult(r,a),d.iterateObserversSafely(this.observers,"error",this.last.error=e)},a.prototype.hasObservers=function(){return this.observers.size>0},a.prototype.tearDownQuery=function(){this.isTornDown||(this.concast&&this.observer&&(this.concast.removeObserver(this.observer),delete this.concast,delete this.observer),this.stopPolling(),this.subscriptions.forEach(function(e){return e.unsubscribe()}),this.subscriptions.clear(),this.queryManager.stopQuery(this.queryId),this.observers.clear(),this.isTornDown=!0)},a.prototype.transformDocument=function(e){return this.queryManager.transform(e)},a.prototype.maskResult=function(e){return e&&"data"in e?i.__assign(i.__assign({},e),{data:this.queryManager.maskOperation({document:this.query,data:e.data,fetchPolicy:this.options.fetchPolicy,id:this.queryId})}):e},a.prototype.resetNotifications=function(){this.cancelNotifyTimeout(),this.dirty=!1},a.prototype.cancelNotifyTimeout=function(){this.notifyTimeout&&(clearTimeout(this.notifyTimeout),this.notifyTimeout=void 0)},a.prototype.scheduleNotify=function(){var e=this;!this.dirty&&(this.dirty=!0,this.notifyTimeout||(this.notifyTimeout=setTimeout(function(){return e.notify()},0)))},a.prototype.notify=function(){this.cancelNotifyTimeout(),this.dirty&&("cache-only"==this.options.fetchPolicy||"cache-and-network"==this.options.fetchPolicy||!N(this.queryInfo.networkStatus))&&(this.queryInfo.getDiff().fromOptimisticTransaction?this.observe():this.reobserveCacheFirst()),this.dirty=!1},a.prototype.reobserveCacheFirst=function(){var e=this.options,t=e.fetchPolicy,a=e.nextFetchPolicy;return"cache-and-network"===t||"network-only"===t?this.reobserve({fetchPolicy:"cache-first",nextFetchPolicy:function(e,r){return(this.nextFetchPolicy=a,"function"==typeof this.nextFetchPolicy)?this.nextFetchPolicy(e,r):t}}):this.reobserve()},a.inactiveOnCreation=new c.Slot,a}(d.Observable);function k(e){!1!==globalThis.__DEV__&&n.invariant.error(25,e.message,e.stack)}function x(e){!1!==globalThis.__DEV__&&e&&!1!==globalThis.__DEV__&&n.invariant.debug(26,e)}function C(e){return"network-only"===e||"no-cache"===e||"standby"===e}d.fixObservableSubclass(A);var R=new(d.canUseWeakMap?WeakMap:Map);function V(e,t){var a=e[t];"function"==typeof a&&(e[t]=function(){return R.set(e,(R.get(e)+1)%1e15),a.apply(this,arguments)})}var F=function(){function e(e,t){void 0===t&&(t=e.generateQueryId()),this.queryId=t,this.document=null,this.lastRequestId=1,this.stopped=!1,this.observableQuery=null;var a=this.cache=e.cache;R.has(a)||(R.set(a,0),V(a,"evict"),V(a,"modify"),V(a,"reset"))}return e.prototype.init=function(e){var a=e.networkStatus||t.NetworkStatus.loading;return this.variables&&this.networkStatus!==t.NetworkStatus.loading&&!s.equal(this.variables,e.variables)&&(a=t.NetworkStatus.setVariables),s.equal(e.variables,this.variables)||(this.lastDiff=void 0,this.cancel()),Object.assign(this,{document:e.document,variables:e.variables,networkError:null,graphQLErrors:this.graphQLErrors||[],networkStatus:a}),e.observableQuery&&this.setObservableQuery(e.observableQuery),e.lastRequestId&&(this.lastRequestId=e.lastRequestId),this},e.prototype.resetDiff=function(){this.lastDiff=void 0},e.prototype.getDiff=function(){var e=this.getDiffOptions();if(this.lastDiff&&s.equal(e,this.lastDiff.options))return this.lastDiff.diff;this.updateWatch(this.variables);var t=this.observableQuery;if(t&&"no-cache"===t.options.fetchPolicy)return{complete:!1};var a=this.cache.diff(e);return this.updateLastDiff(a,e),a},e.prototype.updateLastDiff=function(e,t){this.lastDiff=e?{diff:e,options:t||this.getDiffOptions()}:void 0},e.prototype.getDiffOptions=function(e){var t;return void 0===e&&(e=this.variables),{query:this.document,variables:e,returnPartialData:!0,optimistic:!0,canonizeResults:null==(t=this.observableQuery)?void 0:t.options.canonizeResults}},e.prototype.setDiff=function(e){var t,a,r=this.lastDiff&&this.lastDiff.diff;!(e&&!e.complete&&(null==(t=this.observableQuery)?void 0:t.getLastError()))&&(this.updateLastDiff(e),s.equal(r&&r.result,e&&e.result)||null==(a=this.observableQuery)||a.scheduleNotify())},e.prototype.setObservableQuery=function(e){e!==this.observableQuery&&(this.observableQuery=e,e&&(e.queryInfo=this))},e.prototype.stop=function(){var e;if(!this.stopped){this.stopped=!0,null==(e=this.observableQuery)||e.resetNotifications(),this.cancel();var t=this.observableQuery;t&&t.stopPolling()}},e.prototype.cancel=function(){var e;null==(e=this.cancelWatch)||e.call(this),this.cancelWatch=void 0},e.prototype.updateWatch=function(e){var t=this;void 0===e&&(e=this.variables);var a=this.observableQuery;if(!a||"no-cache"!==a.options.fetchPolicy){var r=i.__assign(i.__assign({},this.getDiffOptions(e)),{watcher:this,callback:function(e){return t.setDiff(e)}});this.lastWatch&&s.equal(r,this.lastWatch)||(this.cancel(),this.cancelWatch=this.cache.watch(this.lastWatch=r))}},e.prototype.resetLastWrite=function(){this.lastWrite=void 0},e.prototype.shouldWrite=function(e,t){var a=this.lastWrite;return!(a&&a.dmCount===R.get(this.cache)&&s.equal(t,a.variables)&&s.equal(e.data,a.result.data))},e.prototype.markResult=function(e,t,a,r){var i,n=this,p=new d.DeepMerger,o=d.isNonEmptyArray(e.errors)?e.errors.slice(0):[];if(null==(i=this.observableQuery)||i.resetNotifications(),"incremental"in e&&d.isNonEmptyArray(e.incremental)){var l=d.mergeIncrementalData(this.getDiff().result,e);e.data=l}else if("hasNext"in e&&e.hasNext){var u=this.getDiff();e.data=p.merge(u.result,e.data)}this.graphQLErrors=o,"no-cache"===a.fetchPolicy?this.updateLastDiff({result:e.data,complete:!0},this.getDiffOptions(a.variables)):0!==r&&($(e,a.errorPolicy)?this.cache.performTransaction(function(i){if(n.shouldWrite(e,a.variables))i.writeQuery({query:t,data:e.data,variables:a.variables,overwrite:1===r}),n.lastWrite={result:e,variables:a.variables,dmCount:R.get(n.cache)};else if(n.lastDiff&&n.lastDiff.diff.complete){e.data=n.lastDiff.diff.result;return}var p=n.getDiffOptions(a.variables),o=i.diff(p);!n.stopped&&s.equal(n.variables,a.variables)&&n.updateWatch(a.variables),n.updateLastDiff(o,p),o.complete&&(e.data=o.result)}):this.lastWrite=void 0)},e.prototype.markReady=function(){return this.networkError=null,this.networkStatus=t.NetworkStatus.ready},e.prototype.markError=function(e){var a;return this.networkStatus=t.NetworkStatus.error,this.lastWrite=void 0,null==(a=this.observableQuery)||a.resetNotifications(),e.graphQLErrors&&(this.graphQLErrors=e.graphQLErrors),e.networkError&&(this.networkError=e.networkError),e},e}();function $(e,t){void 0===t&&(t="none");var a="ignore"===t||"all"===t,r=!d.graphQLResultHasError(e);return!r&&a&&e.data&&(r=!0),r}var P=Object.prototype.hasOwnProperty,L=Object.create(null),j=function(){function e(e){var t=this;this.clientAwareness={},this.queries=new Map,this.fetchCancelFns=new Map,this.transformCache=new d.AutoCleanedWeakCache(d.cacheSizes["queryManager.getDocumentInfo"]||2e3),this.queryIdCounter=1,this.requestIdCounter=1,this.mutationIdCounter=1,this.inFlightLinkObservables=new m.Trie(!1),this.noCacheWarningsByQueryId=new Set;var a=new d.DocumentTransform(function(e){return t.cache.transformDocument(e)},{cache:!1});this.cache=e.cache,this.link=e.link,this.defaultOptions=e.defaultOptions,this.queryDeduplication=e.queryDeduplication,this.clientAwareness=e.clientAwareness,this.localState=e.localState,this.ssrMode=e.ssrMode,this.assumeImmutableResults=e.assumeImmutableResults,this.dataMasking=e.dataMasking;var r=e.documentTransform;this.documentTransform=r?a.concat(r).concat(a):a,this.defaultContext=e.defaultContext||Object.create(null),(this.onBroadcast=e.onBroadcast)&&(this.mutationStore=Object.create(null))}return e.prototype.stop=function(){var e=this;this.queries.forEach(function(t,a){e.stopQueryNoBroadcast(a)}),this.cancelPendingFetches(n.newInvariantError(27))},e.prototype.cancelPendingFetches=function(e){this.fetchCancelFns.forEach(function(t){return t(e)}),this.fetchCancelFns.clear()},e.prototype.mutate=function(e){return i.__awaiter(this,arguments,void 0,function(e){var t,a,r,p,o,s,l,c=e.mutation,m=e.variables,f=e.optimisticResponse,h=e.updateQueries,v=e.refetchQueries,y=void 0===v?[]:v,g=e.awaitRefetchQueries,_=void 0!==g&&g,b=e.update,w=e.onQueryUpdated,E=e.fetchPolicy,T=void 0===E?(null==(s=this.defaultOptions.mutate)?void 0:s.fetchPolicy)||"network-only":E,N=e.errorPolicy,S=void 0===N?(null==(l=this.defaultOptions.mutate)?void 0:l.errorPolicy)||"none":N,O=e.keepRootFields,I=e.context;return i.__generator(this,function(e){switch(e.label){case 0:if(n.invariant(c,28),n.invariant("network-only"===T||"no-cache"===T,29),t=this.generateMutationId(),c=this.cache.transformForLink(this.transform(c)),a=this.getDocumentInfo(c).hasClientExports,m=this.getVariables(c,m),!a)return[3,2];return[4,this.localState.addExportedVariables(c,m,I)];case 1:m=e.sent(),e.label=2;case 2:return r=this.mutationStore&&(this.mutationStore[t]={mutation:c,variables:m,loading:!0,error:null}),p=f&&this.markMutationOptimistic(f,{mutationId:t,document:c,variables:m,fetchPolicy:T,errorPolicy:S,context:I,updateQueries:h,update:b,keepRootFields:O}),this.broadcastQueries(),o=this,[2,new Promise(function(e,a){return d.asyncMap(o.getObservableFromLink(c,i.__assign(i.__assign({},I),{optimisticResponse:p?f:void 0}),m,{},!1),function(e){if(d.graphQLResultHasError(e)&&"none"===S)throw new u.ApolloError({graphQLErrors:d.getGraphQLErrorsFromResult(e)});r&&(r.loading=!1,r.error=null);var a=i.__assign({},e);return"function"==typeof y&&(y=y(a)),"ignore"===S&&d.graphQLResultHasError(a)&&delete a.errors,o.markMutationResult({mutationId:t,result:a,document:c,variables:m,fetchPolicy:T,errorPolicy:S,context:I,update:b,updateQueries:h,awaitRefetchQueries:_,refetchQueries:y,removeOptimistic:p?t:void 0,onQueryUpdated:w,keepRootFields:O})}).subscribe({next:function(a){o.broadcastQueries(),"hasNext"in a&&!1!==a.hasNext||e(i.__assign(i.__assign({},a),{data:o.maskOperation({document:c,data:a.data,fetchPolicy:T,id:t})}))},error:function(e){r&&(r.loading=!1,r.error=e),p&&o.cache.removeOptimistic(t),o.broadcastQueries(),a(e instanceof u.ApolloError?e:new u.ApolloError({networkError:e}))}})})]}})})},e.prototype.markMutationResult=function(e,t){var a=this;void 0===t&&(t=this.cache);var r=e.result,n=[],p="no-cache"===e.fetchPolicy;if(!p&&$(r,e.errorPolicy)){if(d.isExecutionPatchIncrementalResult(r)||n.push({result:r.data,dataId:"ROOT_MUTATION",query:e.document,variables:e.variables}),d.isExecutionPatchIncrementalResult(r)&&d.isNonEmptyArray(r.incremental)){var o,s,l,u,c,m=t.diff({id:"ROOT_MUTATION",query:this.getDocumentInfo(e.document).asQuery,variables:e.variables,optimistic:!1,returnPartialData:!0}),f=void 0;m.result&&(o=m.result,s=r,u=o,c=new T,"incremental"in s&&Array.isArray(l=s.incremental)&&l.length>0&&s.incremental.forEach(function(e){for(var t=e.data,a=e.path,r=a.length-1;r>=0;--r){var i=a[r],n=isNaN(+i)?{}:[];n[i]=t,t=n}u=c.merge(u,t)}),f=u),void 0!==f&&(r.data=f,n.push({result:f,dataId:"ROOT_MUTATION",query:e.document,variables:e.variables}))}var h=e.updateQueries;h&&this.queries.forEach(function(e,i){var p=e.observableQuery,o=p&&p.queryName;if(o&&P.call(h,o)){var s=h[o],l=a.queries.get(i),u=l.document,c=l.variables,m=t.diff({query:u,variables:c,returnPartialData:!0,optimistic:!1}),f=m.result;if(m.complete&&f){var v=s(f,{mutationResult:r,queryName:u&&d.getOperationName(u)||void 0,queryVariables:c});v&&n.push({result:v,dataId:"ROOT_QUERY",query:u,variables:c})}}})}if(n.length>0||(e.refetchQueries||"").length>0||e.update||e.onQueryUpdated||e.removeOptimistic){var v=[];if(this.refetchQueries({updateCache:function(t){p||n.forEach(function(e){return t.write(e)});var o=e.update,s=!d.isExecutionPatchResult(r)||d.isExecutionPatchIncrementalResult(r)&&!r.hasNext;if(o){if(!p){var l=t.diff({id:"ROOT_MUTATION",query:a.getDocumentInfo(e.document).asQuery,variables:e.variables,optimistic:!1,returnPartialData:!0});l.complete&&("incremental"in(r=i.__assign(i.__assign({},r),{data:l.result}))&&delete r.incremental,"hasNext"in r&&delete r.hasNext)}s&&o(t,r,{context:e.context,variables:e.variables})}p||e.keepRootFields||!s||t.modify({id:"ROOT_MUTATION",fields:function(e,t){var a=t.fieldName,r=t.DELETE;return"__typename"===a?e:r}})},include:e.refetchQueries,optimistic:!1,removeOptimistic:e.removeOptimistic,onQueryUpdated:e.onQueryUpdated||null}).forEach(function(e){return v.push(e)}),e.awaitRefetchQueries||e.onQueryUpdated)return Promise.all(v).then(function(){return r})}return Promise.resolve(r)},e.prototype.markMutationOptimistic=function(e,t){var a=this,r="function"==typeof e?e(t.variables,{IGNORE:L}):e;return r!==L&&(this.cache.recordOptimisticTransaction(function(e){try{a.markMutationResult(i.__assign(i.__assign({},t),{result:{data:r}}),e)}catch(e){!1!==globalThis.__DEV__&&n.invariant.error(e)}},t.mutationId),!0)},e.prototype.fetchQuery=function(e,t,a){return this.fetchConcastWithInfo(this.getOrCreateQuery(e),t,a).concast.promise},e.prototype.getQueryStore=function(){var e=Object.create(null);return this.queries.forEach(function(t,a){e[a]={variables:t.variables,networkStatus:t.networkStatus,networkError:t.networkError,graphQLErrors:t.graphQLErrors}}),e},e.prototype.resetErrors=function(e){var t=this.queries.get(e);t&&(t.networkError=void 0,t.graphQLErrors=[])},e.prototype.transform=function(e){return this.documentTransform.transformDocument(e)},e.prototype.getDocumentInfo=function(e){var t=this.transformCache;if(!t.has(e)){var a={hasClientExports:d.hasClientExports(e),hasForcedResolvers:this.localState.shouldForceResolvers(e),hasNonreactiveDirective:d.hasDirectives(["nonreactive"],e),nonReactiveQuery:d.addNonReactiveToNamedFragments(e),clientQuery:this.localState.clientQuery(e),serverQuery:d.removeDirectivesFromDocument([{name:"client",remove:!0},{name:"connection"},{name:"nonreactive"},{name:"unmask"}],e),defaultVars:d.getDefaultValues(d.getOperationDefinition(e)),asQuery:i.__assign(i.__assign({},e),{definitions:e.definitions.map(function(e){return"OperationDefinition"===e.kind&&"query"!==e.operation?i.__assign(i.__assign({},e),{operation:"query"}):e})})};t.set(e,a)}return t.get(e)},e.prototype.getVariables=function(e,t){return i.__assign(i.__assign({},this.getDocumentInfo(e).defaultVars),t)},e.prototype.watchQuery=function(e){var t=this.transform(e.query);void 0===(e=i.__assign(i.__assign({},e),{variables:this.getVariables(t,e.variables)})).notifyOnNetworkStatusChange&&(e.notifyOnNetworkStatusChange=!1);var a=new F(this),r=new A({queryManager:this,queryInfo:a,options:e});return r.lastQuery=t,A.inactiveOnCreation.getValue()||this.queries.set(r.queryId,a),a.init({document:t,observableQuery:r,variables:r.variables}),r},e.prototype.query=function(e,t){var a=this;void 0===t&&(t=this.generateQueryId()),n.invariant(e.query,30),n.invariant("Document"===e.query.kind,31),n.invariant(!e.returnPartialData,32),n.invariant(!e.pollInterval,33);var r=this.transform(e.query);return this.fetchQuery(t,i.__assign(i.__assign({},e),{query:r})).then(function(n){return n&&i.__assign(i.__assign({},n),{data:a.maskOperation({document:r,data:n.data,fetchPolicy:e.fetchPolicy,id:t})})}).finally(function(){return a.stopQuery(t)})},e.prototype.generateQueryId=function(){return String(this.queryIdCounter++)},e.prototype.generateRequestId=function(){return this.requestIdCounter++},e.prototype.generateMutationId=function(){return String(this.mutationIdCounter++)},e.prototype.stopQueryInStore=function(e){this.stopQueryInStoreNoBroadcast(e),this.broadcastQueries()},e.prototype.stopQueryInStoreNoBroadcast=function(e){var t=this.queries.get(e);t&&t.stop()},e.prototype.clearStore=function(e){return void 0===e&&(e={discardWatches:!0}),this.cancelPendingFetches(n.newInvariantError(34)),this.queries.forEach(function(e){e.observableQuery?e.networkStatus=t.NetworkStatus.loading:e.stop()}),this.mutationStore&&(this.mutationStore=Object.create(null)),this.cache.reset(e)},e.prototype.getObservableQueries=function(e){var t=this;void 0===e&&(e="active");var a=new Map,r=new Map,p=new Map,o=new Set;return Array.isArray(e)&&e.forEach(function(e){if("string"==typeof e)r.set(e,e),p.set(e,!1);else if(d.isDocumentNode(e)){var a=d.print(t.transform(e));r.set(a,d.getOperationName(e)),p.set(a,!1)}else d.isNonNullObject(e)&&e.query&&o.add(e)}),this.queries.forEach(function(t,r){var i=t.observableQuery,n=t.document;if(i){if("all"===e)return void a.set(r,i);var o=i.queryName;if("standby"===i.options.fetchPolicy||"active"===e&&!i.hasObservers())return;("active"===e||o&&p.has(o)||n&&p.has(d.print(n)))&&(a.set(r,i),o&&p.set(o,!0),n&&p.set(d.print(n),!0))}}),o.size&&o.forEach(function(e){var r=d.makeUniqueId("legacyOneTimeQuery"),p=t.getOrCreateQuery(r).init({document:e.query,variables:e.variables}),o=new A({queryManager:t,queryInfo:p,options:i.__assign(i.__assign({},e),{fetchPolicy:"network-only"})});n.invariant(o.queryId===r),p.setObservableQuery(o),a.set(r,o)}),!1!==globalThis.__DEV__&&p.size&&p.forEach(function(e,t){if(!e){var a=r.get(t);a?!1!==globalThis.__DEV__&&n.invariant.warn(35,a):!1!==globalThis.__DEV__&&n.invariant.warn(36)}}),a},e.prototype.reFetchObservableQueries=function(e){var t=this;void 0===e&&(e=!1);var a=[];return this.getObservableQueries(e?"all":"active").forEach(function(r,i){var n=r.options.fetchPolicy;r.resetLastResults(),(e||"standby"!==n&&"cache-only"!==n)&&a.push(r.refetch()),(t.queries.get(i)||r.queryInfo).setDiff(null)}),this.broadcastQueries(),Promise.all(a)},e.prototype.startGraphQLSubscription=function(e){var t=this,a=e.query,r=e.variables,i=e.fetchPolicy,n=e.errorPolicy,p=void 0===n?"none":n,o=e.context,s=void 0===o?{}:o,l=e.extensions,c=void 0===l?{}:l;a=this.transform(a),r=this.getVariables(a,r);var m=function(e){return t.getObservableFromLink(a,s,e,c).map(function(r){"no-cache"!==i&&($(r,p)&&t.cache.write({query:a,result:r.data,dataId:"ROOT_SUBSCRIPTION",variables:e}),t.broadcastQueries());var n=d.graphQLResultHasError(r),o=u.graphQLResultHasProtocolErrors(r);if(n||o){var s={};if(n&&(s.graphQLErrors=r.errors),o&&(s.protocolErrors=r.extensions[u.PROTOCOL_ERRORS_SYMBOL]),"none"===p||o)throw new u.ApolloError(s)}return"ignore"===p&&delete r.errors,r})};if(this.getDocumentInfo(a).hasClientExports){var f=this.localState.addExportedVariables(a,r,s).then(m);return new d.Observable(function(e){var t=null;return f.then(function(a){return t=a.subscribe(e)},e.error),function(){return t&&t.unsubscribe()}})}return m(r)},e.prototype.stopQuery=function(e){this.stopQueryNoBroadcast(e),this.broadcastQueries()},e.prototype.stopQueryNoBroadcast=function(e){this.stopQueryInStoreNoBroadcast(e),this.removeQuery(e)},e.prototype.removeQuery=function(e){var t;this.fetchCancelFns.delete(e),this.queries.has(e)&&(null==(t=this.queries.get(e))||t.stop(),this.queries.delete(e))},e.prototype.broadcastQueries=function(){this.onBroadcast&&this.onBroadcast(),this.queries.forEach(function(e){var t;return null==(t=e.observableQuery)?void 0:t.notify()})},e.prototype.getLocalState=function(){return this.localState},e.prototype.getObservableFromLink=function(e,t,a,r,n){var o,s,u=this;void 0===n&&(n=null!=(o=null==t?void 0:t.queryDeduplication)?o:this.queryDeduplication);var c=this.getDocumentInfo(e),m=c.serverQuery,f=c.clientQuery;if(m){var h=this.inFlightLinkObservables,v=this.link,y={query:m,variables:a,operationName:d.getOperationName(m)||void 0,context:this.prepareContext(i.__assign(i.__assign({},t),{forceFetch:!n})),extensions:r};if(t=y.context,n){var g=d.print(m),_=l.canonicalStringify(a),b=h.lookup(g,_);if(!(s=b.observable)){var w=new d.Concast([p.execute(v,y)]);s=b.observable=w,w.beforeNext(function e(t,a){"next"===t&&"hasNext"in a&&a.hasNext?w.beforeNext(e):h.remove(g,_)})}}else s=new d.Concast([p.execute(v,y)])}else s=new d.Concast([d.Observable.of({data:{}})]),t=this.prepareContext(t);return f&&(s=d.asyncMap(s,function(e){return u.localState.runResolvers({document:f,remoteResult:e,context:t,variables:a})})),s},e.prototype.getResultsFromLink=function(e,a,r){var i=e.lastRequestId=this.generateRequestId(),n=this.cache.transformForLink(r.query);return d.asyncMap(this.getObservableFromLink(n,r.context,r.variables),function(p){var o=d.getGraphQLErrorsFromResult(p),s=o.length>0,l=r.errorPolicy;if(i>=e.lastRequestId){if(s&&"none"===l)throw e.markError(new u.ApolloError({graphQLErrors:o}));e.markResult(p,n,r,a),e.markReady()}var c={data:p.data,loading:!1,networkStatus:t.NetworkStatus.ready};return s&&"none"===l&&(c.data=void 0),s&&"ignore"!==l&&(c.errors=o,c.networkStatus=t.NetworkStatus.error),c},function(t){var a=u.isApolloError(t)?t:new u.ApolloError({networkError:t});throw i>=e.lastRequestId&&e.markError(a),a})},e.prototype.fetchConcastWithInfo=function(e,a,r,i){var n,p,o=this;void 0===r&&(r=t.NetworkStatus.loading),void 0===i&&(i=a.query);var s=this.getVariables(i,a.variables),l=this.defaultOptions.watchQuery,u=a.fetchPolicy,c=void 0===u?l&&l.fetchPolicy||"cache-first":u,m=a.errorPolicy,f=void 0===m?l&&l.errorPolicy||"none":m,h=a.returnPartialData,v=a.notifyOnNetworkStatusChange,y=a.context,g=Object.assign({},a,{query:i,variables:s,fetchPolicy:c,errorPolicy:f,returnPartialData:void 0!==h&&h,notifyOnNetworkStatusChange:void 0!==v&&v,context:void 0===y?{}:y}),_=function(t){g.variables=t;var i=o.fetchQueryByPolicy(e,g,r);return"standby"!==g.fetchPolicy&&i.sources.length>0&&e.observableQuery&&e.observableQuery.applyNextFetchPolicy("after-fetch",a),i},b=function(){return o.fetchCancelFns.delete(e.queryId)};if(this.fetchCancelFns.set(e.queryId,function(e){b(),setTimeout(function(){return n.cancel(e)})}),this.getDocumentInfo(g.query).hasClientExports)n=new d.Concast(this.localState.addExportedVariables(g.query,g.variables,g.context).then(_).then(function(e){return e.sources})),p=!0;else{var w=_(g.variables);p=w.fromLink,n=new d.Concast(w.sources)}return n.promise.then(b,b),{concast:n,fromLink:p}},e.prototype.refetchQueries=function(e){var t=this,a=e.updateCache,r=e.include,i=e.optimistic,n=void 0!==i&&i,p=e.removeOptimistic,o=void 0===p?n?d.makeUniqueId("refetchQueries"):void 0:p,s=e.onQueryUpdated,l=new Map;r&&this.getObservableQueries(r).forEach(function(e,a){l.set(a,{oq:e,lastDiff:(t.queries.get(a)||e.queryInfo).getDiff()})});var u=new Map;return a&&this.cache.batch({update:a,optimistic:n&&o||!1,removeOptimistic:o,onWatchUpdated:function(e,t,a){var r=e.watcher instanceof F&&e.watcher.observableQuery;if(r){if(s){l.delete(r.queryId);var i=s(r,t,a);return!0===i&&(i=r.refetch()),!1!==i&&u.set(r,i),i}null!==s&&l.set(r.queryId,{oq:r,lastDiff:a,diff:t})}}}),l.size&&l.forEach(function(e,a){var r,i=e.oq,n=e.lastDiff,p=e.diff;s&&(p||(p=t.cache.diff(i.queryInfo.getDiffOptions())),r=s(i,p,n)),s&&!0!==r||(r=i.refetch()),!1!==r&&u.set(i,r),a.indexOf("legacyOneTimeQuery")>=0&&t.stopQueryNoBroadcast(a)}),o&&this.cache.removeOptimistic(o),u},e.prototype.maskOperation=function(e){var t,a,r,i=e.document,p=e.data;if(!1!==globalThis.__DEV__){var o=e.fetchPolicy,s=e.id,l=null==(t=d.getOperationDefinition(i))?void 0:t.operation,u=(null!=(a=null==l?void 0:l[0])?a:"o")+s;!this.dataMasking||"no-cache"!==o||d.isFullyUnmaskedOperation(i)||this.noCacheWarningsByQueryId.has(u)||(this.noCacheWarningsByQueryId.add(u),!1!==globalThis.__DEV__&&n.invariant.warn(37,null!=(r=d.getOperationName(i))?r:"Unnamed ".concat(null!=l?l:"operation")))}return this.dataMasking?f.maskOperation(p,i,this.cache):p},e.prototype.maskFragment=function(e){var t=e.data,a=e.fragment,r=e.fragmentName;return this.dataMasking?f.maskFragment(t,a,this.cache,r):t},e.prototype.fetchQueryByPolicy=function(e,a,r){var n=this,p=a.query,o=a.variables,l=a.fetchPolicy,u=a.refetchWritePolicy,c=a.errorPolicy,m=a.returnPartialData,f=a.context,h=a.notifyOnNetworkStatusChange,v=e.networkStatus;e.init({document:p,variables:o,networkStatus:r});var y=function(){return e.getDiff()},g=function(a,r){void 0===r&&(r=e.networkStatus||t.NetworkStatus.loading);var l=a.result;!1===globalThis.__DEV__||m||s.equal(l,{})||x(a.missing);var u=function(e){return d.Observable.of(i.__assign({data:e,loading:N(r),networkStatus:r},a.complete?null:{partial:!0}))};return l&&n.getDocumentInfo(p).hasForcedResolvers?n.localState.runResolvers({document:p,remoteResult:{data:l},context:f,variables:o,onlyRunForcedResolvers:!0}).then(function(e){return u(e.data||void 0)}):"none"===c&&r===t.NetworkStatus.refetch&&Array.isArray(a.missing)?u(void 0):u(l)},_="no-cache"===l?0:r===t.NetworkStatus.refetch&&"merge"!==u?1:2,b=function(){return n.getResultsFromLink(e,_,{query:p,variables:o,context:f,fetchPolicy:l,errorPolicy:c})},w=h&&"number"==typeof v&&v!==r&&N(r);switch(l){default:case"cache-first":var E=y();if(E.complete)return{fromLink:!1,sources:[g(E,e.markReady())]};if(m||w)return{fromLink:!0,sources:[g(E),b()]};return{fromLink:!0,sources:[b()]};case"cache-and-network":var E=y();if(E.complete||m||w)return{fromLink:!0,sources:[g(E),b()]};return{fromLink:!0,sources:[b()]};case"cache-only":return{fromLink:!1,sources:[g(y(),e.markReady())]};case"network-only":if(w)return{fromLink:!0,sources:[g(y()),b()]};return{fromLink:!0,sources:[b()]};case"no-cache":if(w)return{fromLink:!0,sources:[g(e.getDiff()),b()]};return{fromLink:!0,sources:[b()]};case"standby":return{fromLink:!1,sources:[]}}},e.prototype.getOrCreateQuery=function(e){return e&&!this.queries.has(e)&&this.queries.set(e,new F(this,e)),this.queries.get(e)},e.prototype.prepareContext=function(e){void 0===e&&(e={});var t=this.localState.prepareContext(e);return i.__assign(i.__assign(i.__assign({},this.defaultContext),t),{clientAwareness:this.clientAwareness})},e}(),M=function(){function e(e){var t=e.cache,a=e.client,r=e.resolvers,i=e.fragmentMatcher;this.selectionsToResolveCache=new WeakMap,this.cache=t,a&&(this.client=a),r&&this.addResolvers(r),i&&this.setFragmentMatcher(i)}return e.prototype.addResolvers=function(e){var t=this;this.resolvers=this.resolvers||{},Array.isArray(e)?e.forEach(function(e){t.resolvers=d.mergeDeep(t.resolvers,e)}):this.resolvers=d.mergeDeep(this.resolvers,e)},e.prototype.setResolvers=function(e){this.resolvers={},this.addResolvers(e)},e.prototype.getResolvers=function(){return this.resolvers||{}},e.prototype.runResolvers=function(e){return i.__awaiter(this,arguments,void 0,function(e){var t=e.document,a=e.remoteResult,r=e.context,n=e.variables,p=e.onlyRunForcedResolvers,o=void 0!==p&&p;return i.__generator(this,function(e){return t?[2,this.resolveDocument(t,a.data,r,n,this.fragmentMatcher,o).then(function(e){return i.__assign(i.__assign({},a),{data:e.result})})]:[2,a]})})},e.prototype.setFragmentMatcher=function(e){this.fragmentMatcher=e},e.prototype.getFragmentMatcher=function(){return this.fragmentMatcher},e.prototype.clientQuery=function(e){return d.hasDirectives(["client"],e)&&this.resolvers?e:null},e.prototype.serverQuery=function(e){return d.removeClientSetsFromDocument(e)},e.prototype.prepareContext=function(e){var t=this.cache;return i.__assign(i.__assign({},e),{cache:t,getCacheKey:function(e){return t.identify(e)}})},e.prototype.addExportedVariables=function(e){return i.__awaiter(this,arguments,void 0,function(e,t,a){return void 0===t&&(t={}),void 0===a&&(a={}),i.__generator(this,function(r){return e?[2,this.resolveDocument(e,this.buildRootValueFromCache(e,t)||{},this.prepareContext(a),t).then(function(e){return i.__assign(i.__assign({},t),e.exportedVariables)})]:[2,i.__assign({},t)]})})},e.prototype.shouldForceResolvers=function(e){var t=!1;return h.visit(e,{Directive:{enter:function(e){if("client"===e.name.value&&e.arguments&&(t=e.arguments.some(function(e){return"always"===e.name.value&&"BooleanValue"===e.value.kind&&!0===e.value.value})))return h.BREAK}}}),t},e.prototype.buildRootValueFromCache=function(e,t){return this.cache.diff({query:d.buildQueryFromSelectionSet(e),variables:t,returnPartialData:!0,optimistic:!1}).result},e.prototype.resolveDocument=function(e,t){return i.__awaiter(this,arguments,void 0,function(e,t,a,r,n,p){var o,s,l,u,c,m,f,h,v,y;return void 0===a&&(a={}),void 0===r&&(r={}),void 0===n&&(n=function(){return!0}),void 0===p&&(p=!1),i.__generator(this,function(g){return o=d.getMainDefinition(e),s=d.getFragmentDefinitions(e),l=d.createFragmentMap(s),u=this.collectSelectionsToResolve(o,l),m=(c=o.operation)?c.charAt(0).toUpperCase()+c.slice(1):"Query",f=this,h=f.cache,v=f.client,y={fragmentMap:l,context:i.__assign(i.__assign({},a),{cache:h,client:v}),variables:r,fragmentMatcher:n,defaultOperationType:m,exportedVariables:{},selectionsToResolve:u,onlyRunForcedResolvers:p},[2,this.resolveSelectionSet(o.selectionSet,!1,t,y).then(function(e){return{result:e,exportedVariables:y.exportedVariables}})]})})},e.prototype.resolveSelectionSet=function(e,t,a,r){return i.__awaiter(this,void 0,void 0,function(){var p,o,s,l,u,c=this;return i.__generator(this,function(m){return p=r.fragmentMap,o=r.context,s=r.variables,l=[a],u=function(e){return i.__awaiter(c,void 0,void 0,function(){var u,c;return i.__generator(this,function(i){return(t||r.selectionsToResolve.has(e))&&d.shouldInclude(e,s)?d.isField(e)?[2,this.resolveField(e,t,a,r).then(function(t){var a;void 0!==t&&l.push(((a={})[d.resultKeyNameFromField(e)]=t,a))})]:(d.isInlineFragment(e)?u=e:(u=p[e.name.value],n.invariant(u,19,e.name.value)),u&&u.typeCondition&&(c=u.typeCondition.name.value,r.fragmentMatcher(a,c,o)))?[2,this.resolveSelectionSet(u.selectionSet,t,a,r).then(function(e){l.push(e)})]:[2]:[2]})})},[2,Promise.all(e.selections.map(u)).then(function(){return d.mergeDeepArray(l)})]})})},e.prototype.resolveField=function(e,t,a,r){return i.__awaiter(this,void 0,void 0,function(){var n,p,o,s,u,c,m,f,h,v=this;return i.__generator(this,function(i){return a?(n=r.variables,s=(p=e.name.value)!==(o=d.resultKeyNameFromField(e)),c=Promise.resolve(u=a[o]||a[p]),(!r.onlyRunForcedResolvers||this.shouldForceResolvers(e))&&(m=a.__typename||r.defaultOperationType,(f=this.resolvers&&this.resolvers[m])&&(h=f[s?p:o])&&(c=Promise.resolve(l.cacheSlot.withValue(this.cache,h,[a,d.argumentsObjectFromField(e,n),r.context,{field:e,fragmentMap:r.fragmentMap}])))),[2,c.then(function(a){if(void 0===a&&(a=u),e.directives&&e.directives.forEach(function(e){"export"===e.name.value&&e.arguments&&e.arguments.forEach(function(e){"as"===e.name.value&&"StringValue"===e.value.kind&&(r.exportedVariables[e.value.value]=a)})}),!e.selectionSet||null==a)return a;var i,n,p=null!=(n=null==(i=e.directives)?void 0:i.some(function(e){return"client"===e.name.value}))&&n;return Array.isArray(a)?v.resolveSubSelectedArray(e,t||p,a,r):e.selectionSet?v.resolveSelectionSet(e.selectionSet,t||p,a,r):void 0})]):[2,null]})})},e.prototype.resolveSubSelectedArray=function(e,t,a,r){var i=this;return Promise.all(a.map(function(a){return null===a?null:Array.isArray(a)?i.resolveSubSelectedArray(e,t,a,r):e.selectionSet?i.resolveSelectionSet(e.selectionSet,t,a,r):void 0}))},e.prototype.collectSelectionsToResolve=function(e,t){var a=function(e){return!Array.isArray(e)},r=this.selectionsToResolveCache;return function e(i){if(!r.has(i)){var p=new Set;r.set(i,p),h.visit(i,{Directive:function(e,t,r,i,n){"client"===e.name.value&&n.forEach(function(e){a(e)&&h.isSelectionNode(e)&&p.add(e)})},FragmentSpread:function(r,i,o,s,d){var l=t[r.name.value];n.invariant(l,20,r.name.value);var u=e(l);u.size>0&&(d.forEach(function(e){a(e)&&h.isSelectionNode(e)&&p.add(e)}),p.add(r),u.forEach(function(e){p.add(e)}))}})}return r.get(i)}(e)},e}(),U=Symbol.for("apollo.cacheSize"),B=i.__assign({},n.global[U]),q={},Q=!1!==globalThis.__DEV__?function(){var e,t,a,r,n;if(!1===globalThis.__DEV__)throw Error("only supported in development mode");return{limits:Object.fromEntries(Object.entries({parser:1e3,canonicalStringify:1e3,print:2e3,"documentTransform.cache":2e3,"queryManager.getDocumentInfo":2e3,"PersistedQueryLink.persistedQueryHashes":2e3,"fragmentRegistry.transform":2e3,"fragmentRegistry.lookup":1e3,"fragmentRegistry.findFragmentSpreads":4e3,"cache.fragmentQueryDocuments":1e3,"removeTypenameFromVariables.getVariableDefinitions":2e3,"inMemoryCache.maybeBroadcastWatch":5e3,"inMemoryCache.executeSelectionSet":5e4,"inMemoryCache.executeSubSelectedArray":1e4}).map(function(e){var t=e[0],a=e[1];return[t,B[t]||a]})),sizes:i.__assign({print:null==(e=q.print)?void 0:e.call(q),parser:null==(t=q.parser)?void 0:t.call(q),canonicalStringify:null==(a=q.canonicalStringify)?void 0:a.call(q),links:function e(t){var a;return t?i.__spreadArray(i.__spreadArray([null==(a=null==t?void 0:t.getMemoryInternals)?void 0:a.call(t)],e(null==t?void 0:t.left),!0),e(null==t?void 0:t.right),!0).filter(Y):[]}(this.link),queryManager:{getDocumentInfo:this.queryManager.transformCache.size,documentTransforms:(function e(t){var a,r;return t?i.__spreadArray(i.__spreadArray([(r=a=null==t?void 0:t.performWork)&&"dirtyKey"in r?a.size:void 0],e(null==t?void 0:t.left),!0),e(null==t?void 0:t.right),!0).filter(Y):[]})(this.queryManager.documentTransform).map(function(e){return{cache:e}})}},null==(n=(r=this.cache).getMemoryInternals)?void 0:n.call(r))}}:void 0;function Y(e){return null!=e}var G=!1,z=function(){function e(e){var t,a=this;if(this.resetStoreCallbacks=[],this.clearStoreCallbacks=[],!e.cache)throw n.newInvariantError(16);var r=e.uri,s=e.credentials,d=e.headers,l=e.cache,u=e.documentTransform,c=e.ssrMode,m=void 0!==c&&c,f=e.ssrForceFetchDelay,h=void 0===f?0:f,v=e.connectToDevTools,y=e.queryDeduplication,g=void 0===y||y,_=e.defaultOptions,b=e.defaultContext,w=e.assumeImmutableResults,E=void 0===w?l.assumeImmutableResults:w,T=e.resolvers,N=e.typeDefs,S=e.fragmentMatcher,O=e.name,I=e.version,D=e.devtools,A=e.dataMasking,k=e.link;k||(k=r?new o.HttpLink({uri:r,credentials:s,headers:d}):p.ApolloLink.empty()),this.link=k,this.cache=l,this.disableNetworkFetches=m||h>0,this.queryDeduplication=g,this.defaultOptions=_||Object.create(null),this.typeDefs=N,this.devtoolsConfig=i.__assign(i.__assign({},D),{enabled:null!=(t=null==D?void 0:D.enabled)?t:v}),void 0===this.devtoolsConfig.enabled&&(this.devtoolsConfig.enabled=!1!==globalThis.__DEV__),h&&setTimeout(function(){return a.disableNetworkFetches=!1},h),this.watchQuery=this.watchQuery.bind(this),this.query=this.query.bind(this),this.mutate=this.mutate.bind(this),this.watchFragment=this.watchFragment.bind(this),this.resetStore=this.resetStore.bind(this),this.reFetchObservableQueries=this.reFetchObservableQueries.bind(this),this.version="3.13.8",this.localState=new M({cache:l,client:this,resolvers:T,fragmentMatcher:S}),this.queryManager=new j({cache:this.cache,link:this.link,defaultOptions:this.defaultOptions,defaultContext:b,documentTransform:u,queryDeduplication:g,ssrMode:m,dataMasking:!!A,clientAwareness:{name:O,version:I},localState:this.localState,assumeImmutableResults:E,onBroadcast:this.devtoolsConfig.enabled?function(){a.devToolsHookCb&&a.devToolsHookCb({action:{},state:{queries:a.queryManager.getQueryStore(),mutations:a.queryManager.mutationStore||{}},dataWithOptimisticResults:a.cache.extract(!0)})}:void 0}),this.devtoolsConfig.enabled&&this.connectToDevTools()}return e.prototype.connectToDevTools=function(){if("u">typeof window){var e=window,t=Symbol.for("apollo.devtools");(e[t]=e[t]||[]).push(this),e.__APOLLO_CLIENT__=this,!G&&!1!==globalThis.__DEV__&&(G=!0,window.document&&window.top===window.self&&/^(https?|file):$/.test(window.location.protocol)&&setTimeout(function(){if(!window.__APOLLO_DEVTOOLS_GLOBAL_HOOK__){var e=window.navigator,t=e&&e.userAgent,a=void 0;"string"==typeof t&&(t.indexOf("Chrome/")>-1?a="https://chrome.google.com/webstore/detail/apollo-client-developer-t/jdkknkkbebbapilgoeccciglkfbmbnfm":t.indexOf("Firefox/")>-1&&(a="https://addons.mozilla.org/en-US/firefox/addon/apollo-developer-tools/")),a&&!1!==globalThis.__DEV__&&n.invariant.log("Download the Apollo DevTools for a better development experience: %s",a)}},1e4))}},Object.defineProperty(e.prototype,"documentTransform",{get:function(){return this.queryManager.documentTransform},enumerable:!1,configurable:!0}),e.prototype.stop=function(){this.queryManager.stop()},e.prototype.watchQuery=function(e){return this.defaultOptions.watchQuery&&(e=d.mergeOptions(this.defaultOptions.watchQuery,e)),this.disableNetworkFetches&&("network-only"===e.fetchPolicy||"cache-and-network"===e.fetchPolicy)&&(e=i.__assign(i.__assign({},e),{fetchPolicy:"cache-first"})),this.queryManager.watchQuery(e)},e.prototype.query=function(e){return this.defaultOptions.query&&(e=d.mergeOptions(this.defaultOptions.query,e)),n.invariant("cache-and-network"!==e.fetchPolicy,17),this.disableNetworkFetches&&"network-only"===e.fetchPolicy&&(e=i.__assign(i.__assign({},e),{fetchPolicy:"cache-first"})),this.queryManager.query(e)},e.prototype.mutate=function(e){return this.defaultOptions.mutate&&(e=d.mergeOptions(this.defaultOptions.mutate,e)),this.queryManager.mutate(e)},e.prototype.subscribe=function(e){var t=this,a=this.queryManager.generateQueryId();return this.queryManager.startGraphQLSubscription(e).map(function(r){return i.__assign(i.__assign({},r),{data:t.queryManager.maskOperation({document:e.query,data:r.data,fetchPolicy:e.fetchPolicy,id:a})})})},e.prototype.readQuery=function(e,t){return void 0===t&&(t=!1),this.cache.readQuery(e,t)},e.prototype.watchFragment=function(e){var t;return this.cache.watchFragment(i.__assign(i.__assign({},e),((t={})[Symbol.for("apollo.dataMasking")]=this.queryManager.dataMasking,t)))},e.prototype.readFragment=function(e,t){return void 0===t&&(t=!1),this.cache.readFragment(e,t)},e.prototype.writeQuery=function(e){var t=this.cache.writeQuery(e);return!1!==e.broadcast&&this.queryManager.broadcastQueries(),t},e.prototype.writeFragment=function(e){var t=this.cache.writeFragment(e);return!1!==e.broadcast&&this.queryManager.broadcastQueries(),t},e.prototype.__actionHookForDevTools=function(e){this.devToolsHookCb=e},e.prototype.__requestRaw=function(e){return p.execute(this.link,e)},e.prototype.resetStore=function(){var e=this;return Promise.resolve().then(function(){return e.queryManager.clearStore({discardWatches:!1})}).then(function(){return Promise.all(e.resetStoreCallbacks.map(function(e){return e()}))}).then(function(){return e.reFetchObservableQueries()})},e.prototype.clearStore=function(){var e=this;return Promise.resolve().then(function(){return e.queryManager.clearStore({discardWatches:!0})}).then(function(){return Promise.all(e.clearStoreCallbacks.map(function(e){return e()}))})},e.prototype.onResetStore=function(e){var t=this;return this.resetStoreCallbacks.push(e),function(){t.resetStoreCallbacks=t.resetStoreCallbacks.filter(function(t){return t!==e})}},e.prototype.onClearStore=function(e){var t=this;return this.clearStoreCallbacks.push(e),function(){t.clearStoreCallbacks=t.clearStoreCallbacks.filter(function(t){return t!==e})}},e.prototype.reFetchObservableQueries=function(e){return this.queryManager.reFetchObservableQueries(e)},e.prototype.refetchQueries=function(e){var t=this.queryManager.refetchQueries(e),a=[],r=[];t.forEach(function(e,t){a.push(t),r.push(e)});var i=Promise.all(r);return i.queries=a,i.results=r,i.catch(function(e){!1!==globalThis.__DEV__&&n.invariant.debug(18,e)}),i},e.prototype.getObservableQueries=function(e){return void 0===e&&(e="active"),this.queryManager.getObservableQueries(e)},e.prototype.extract=function(e){return this.cache.extract(e)},e.prototype.restore=function(e){return this.cache.restore(e)},e.prototype.addResolvers=function(e){this.localState.addResolvers(e)},e.prototype.setResolvers=function(e){this.localState.setResolvers(e)},e.prototype.getResolvers=function(){return this.localState.getResolvers()},e.prototype.setLocalStateFragmentMatcher=function(e){this.localState.setFragmentMatcher(e)},e.prototype.setLink=function(e){this.link=this.queryManager.link=e},Object.defineProperty(e.prototype,"defaultContext",{get:function(){return this.queryManager.defaultContext},enumerable:!1,configurable:!0}),e}();for(var H in!1!==globalThis.__DEV__&&(z.prototype.getMemoryInternals=Q),y.setVerbosity(!1!==globalThis.__DEV__?"log":"silent"),t.DocumentTransform=d.DocumentTransform,t.Observable=d.Observable,t.isReference=d.isReference,t.makeReference=d.makeReference,t.mergeOptions=d.mergeOptions,t.ApolloCache=l.ApolloCache,t.Cache=l.Cache,t.InMemoryCache=l.InMemoryCache,t.MissingFieldError=l.MissingFieldError,t.defaultDataIdFromObject=l.defaultDataIdFromObject,t.makeVar=l.makeVar,t.ApolloError=u.ApolloError,t.isApolloError=u.isApolloError,t.fromError=v.fromError,t.fromPromise=v.fromPromise,t.throwServerError=v.throwServerError,t.toPromise=v.toPromise,t.setLogVerbosity=y.setVerbosity,t.disableExperimentalFragmentVariables=g.disableExperimentalFragmentVariables,t.disableFragmentWarnings=g.disableFragmentWarnings,t.enableExperimentalFragmentVariables=g.enableExperimentalFragmentVariables,t.gql=g.gql,t.resetCaches=g.resetCaches,t.ApolloClient=z,t.ObservableQuery=A,t.isNetworkRequestSettled=function(e){return 7===e||8===e},p)"default"===H||t.hasOwnProperty(H)||(t[H]=p[H]);for(var H in o)"default"===H||t.hasOwnProperty(H)||(t[H]=o[H])},78549(e,t,a){var r=a(85608),i=a(4232),n=a(5437);t.o=function(e){return new i.ApolloLink(function(t,a){var i=r.__rest(t,[]);return new n.Observable(function(r){var n,p=!1;return Promise.resolve(i).then(function(a){return e(a,t.getContext())}).then(t.setContext).then(function(){p||(n=a(t).subscribe({next:r.next.bind(r),error:r.error.bind(r),complete:r.complete.bind(r)}))}).catch(r.error.bind(r)),function(){p=!0,n&&n.unsubscribe()}})})}},66442(e){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var a=0,r=Array(t);a<t;a++)r[a]=e[a];return r},e.exports.__esModule=!0,e.exports.default=e.exports},3634(e){e.exports=function(e){if(Array.isArray(e))return e},e.exports.__esModule=!0,e.exports.default=e.exports},65372(e){e.exports=function(e){if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e},e.exports.__esModule=!0,e.exports.default=e.exports},99436(e){function t(e,t,a,r,i,n,p){try{var o=e[n](p),s=o.value}catch(e){return void a(e)}o.done?t(s):Promise.resolve(s).then(r,i)}e.exports=function(e){return function(){var a=this,r=arguments;return new Promise(function(i,n){var p=e.apply(a,r);function o(e){t(p,i,n,o,s,"next",e)}function s(e){t(p,i,n,o,s,"throw",e)}o(void 0)})}},e.exports.__esModule=!0,e.exports.default=e.exports},5018(e){e.exports=function(e,t){if(!(e instanceof t))throw TypeError("Cannot call a class as a function")},e.exports.__esModule=!0,e.exports.default=e.exports},57301(e,t,a){var r=a(37399),i=a(69893);e.exports=function(e,t,a){if(r())return Reflect.construct.apply(null,arguments);var n=[null];n.push.apply(n,t);var p=new(e.bind.apply(e,n));return a&&i(p,a.prototype),p},e.exports.__esModule=!0,e.exports.default=e.exports},44668(e,t,a){var r=a(56347);function i(e,t){for(var a=0;a<t.length;a++){var i=t[a];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,r(i.key),i)}}e.exports=function(e,t,a){return t&&i(e.prototype,t),a&&i(e,a),Object.defineProperty(e,"prototype",{writable:!1}),e},e.exports.__esModule=!0,e.exports.default=e.exports},30409(e){function t(a){return e.exports=t=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},e.exports.__esModule=!0,e.exports.default=e.exports,t(a)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},40906(e,t,a){var r=a(69893);e.exports=function(e,t){if("function"!=typeof t&&null!==t)throw TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&r(e,t)},e.exports.__esModule=!0,e.exports.default=e.exports},39833(e){e.exports=function(e){try{return -1!==Function.toString.call(e).indexOf("[native code]")}catch(t){return"function"==typeof e}},e.exports.__esModule=!0,e.exports.default=e.exports},37399(e){function t(){try{var a=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(e.exports=t=function(){return!!a},e.exports.__esModule=!0,e.exports.default=e.exports)()}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},96525(e){e.exports=function(e,t){var a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var r,i,n,p,o=[],s=!0,d=!1;try{if(n=(a=a.call(e)).next,0===t){if(Object(a)!==a)return;s=!1}else for(;!(s=(r=n.call(a)).done)&&(o.push(r.value),o.length!==t);s=!0);}catch(e){d=!0,i=e}finally{try{if(!s&&null!=a.return&&(p=a.return(),Object(p)!==p))return}finally{if(d)throw i}}return o}},e.exports.__esModule=!0,e.exports.default=e.exports},5523(e){e.exports=function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.__esModule=!0,e.exports.default=e.exports},67996(e,t,a){var r=a(51112);e.exports=function(e,t){if(null==e)return{};var a,i,n=r(e,t);if(Object.getOwnPropertySymbols){var p=Object.getOwnPropertySymbols(e);for(i=0;i<p.length;i++)a=p[i],-1===t.indexOf(a)&&({}).propertyIsEnumerable.call(e,a)&&(n[a]=e[a])}return n},e.exports.__esModule=!0,e.exports.default=e.exports},51112(e){e.exports=function(e,t){if(null==e)return{};var a={};for(var r in e)if(({}).hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;a[r]=e[r]}return a},e.exports.__esModule=!0,e.exports.default=e.exports},63315(e,t,a){var r=a(14319).default,i=a(65372);e.exports=function(e,t){if(t&&("object"==r(t)||"function"==typeof t))return t;if(void 0!==t)throw TypeError("Derived constructors may only return object or undefined");return i(e)},e.exports.__esModule=!0,e.exports.default=e.exports},69893(e){function t(a,r){return e.exports=t=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},e.exports.__esModule=!0,e.exports.default=e.exports,t(a,r)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},68832(e,t,a){var r=a(3634),i=a(96525),n=a(78243),p=a(5523);e.exports=function(e,t){return r(e)||i(e,t)||n(e,t)||p()},e.exports.__esModule=!0,e.exports.default=e.exports},23878(e,t,a){var r=a(14319).default;e.exports=function(e,t){if("object"!=r(e)||!e)return e;var a=e[Symbol.toPrimitive];if(void 0!==a){var i=a.call(e,t||"default");if("object"!=r(i))return i;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)},e.exports.__esModule=!0,e.exports.default=e.exports},56347(e,t,a){var r=a(14319).default,i=a(23878);e.exports=function(e){var t=i(e,"string");return"symbol"==r(t)?t:t+""},e.exports.__esModule=!0,e.exports.default=e.exports},14319(e){function t(a){return e.exports=t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.__esModule=!0,e.exports.default=e.exports,t(a)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},78243(e,t,a){var r=a(66442);e.exports=function(e,t){if(e){if("string"==typeof e)return r(e,t);var a=({}).toString.call(e).slice(8,-1);return"Object"===a&&e.constructor&&(a=e.constructor.name),"Map"===a||"Set"===a?Array.from(e):"Arguments"===a||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a)?r(e,t):void 0}},e.exports.__esModule=!0,e.exports.default=e.exports},59410(e,t,a){var r=a(30409),i=a(69893),n=a(39833),p=a(57301);function o(t){var a="function"==typeof Map?new Map:void 0;return e.exports=o=function(e){if(null===e||!n(e))return e;if("function"!=typeof e)throw TypeError("Super expression must either be null or a function");if(void 0!==a){if(a.has(e))return a.get(e);a.set(e,t)}function t(){return p(e,arguments,r(this).constructor)}return t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),i(t,e)},e.exports.__esModule=!0,e.exports.default=e.exports,o(t)}e.exports=o,e.exports.__esModule=!0,e.exports.default=e.exports},42495(e,t,a){a.d(t,{k:()=>h});var r=a(85608),i=a(60837),n=a(2904),p=a(555),o=a(3777),s=a(36054),d=a(30671),l=a(54019),u=a(44114),c=a(55427),m=a(70916),f=a(62959),h=function(){function e(){this.assumeImmutableResults=!1,this.getFragmentDoc=(0,i.wrap)(n.ct,{max:p.v["cache.fragmentQueryDocuments"]||1e3,cache:l.l})}return e.prototype.lookupFragment=function(e){return null},e.prototype.batch=function(e){var t,a=this,r="string"==typeof e.optimistic?e.optimistic:!1===e.optimistic?null:void 0;return this.performTransaction(function(){return t=e.update(a)},r),t},e.prototype.recordOptimisticTransaction=function(e,t){this.performTransaction(e,t)},e.prototype.transformDocument=function(e){return e},e.prototype.transformForLink=function(e){return e},e.prototype.identify=function(e){},e.prototype.gc=function(){return[]},e.prototype.modify=function(e){return!1},e.prototype.readQuery=function(e,t){return void 0===t&&(t=!!e.optimistic),this.read((0,r.__assign)((0,r.__assign)({},e),{rootId:e.id||"ROOT_QUERY",optimistic:t}))},e.prototype.watchFragment=function(e){var t,a=this,i=e.fragment,n=e.fragmentName,p=e.from,l=e.optimistic,u=(0,r.__rest)(e,["fragment","fragmentName","from","optimistic"]),h=this.getFragmentDoc(i,n),v=void 0===p||"string"==typeof p?p:this.identify(p),y=!!e[Symbol.for("apollo.dataMasking")];if(!1!==globalThis.__DEV__){var g=n||(0,o.E4)(i).name.value;v||!1===globalThis.__DEV__||m.invariant.warn(1,g)}var _=(0,r.__assign)((0,r.__assign)({},u),{returnPartialData:!0,id:v,query:h,optimistic:void 0===l||l});return new s.c(function(p){return a.watch((0,r.__assign)((0,r.__assign)({},_),{immediate:!0,callback:function(o){var s=y?(0,f.z)(o.result,i,a,n):o.result;if(!(t&&(0,c.a)(h,{data:t.result},{data:s},e.variables))){var l={data:s,complete:!!o.complete};o.missing&&(l.missing=(0,d.IM)(o.missing.map(function(e){return e.missing}))),t=(0,r.__assign)((0,r.__assign)({},o),{result:s}),p.next(l)}}}))})},e.prototype.readFragment=function(e,t){return void 0===t&&(t=!!e.optimistic),this.read((0,r.__assign)((0,r.__assign)({},e),{query:this.getFragmentDoc(e.fragment,e.fragmentName),rootId:e.id,optimistic:t}))},e.prototype.writeQuery=function(e){var t=e.id,a=e.data,i=(0,r.__rest)(e,["id","data"]);return this.write(Object.assign(i,{dataId:t||"ROOT_QUERY",result:a}))},e.prototype.writeFragment=function(e){var t=e.id,a=e.data,i=e.fragment,n=e.fragmentName,p=(0,r.__rest)(e,["id","data","fragment","fragmentName"]);return this.write(Object.assign(p,{query:this.getFragmentDoc(i,n),dataId:t,result:a}))},e.prototype.updateQuery=function(e,t){return this.batch({update:function(a){var i=a.readQuery(e),n=t(i);return null==n?i:(a.writeQuery((0,r.__assign)((0,r.__assign)({},e),{data:n})),n)}})},e.prototype.updateFragment=function(e,t){return this.batch({update:function(a){var i=a.readFragment(e),n=t(i);return null==n?i:(a.writeFragment((0,r.__assign)((0,r.__assign)({},e),{data:n})),n)}})},e}();!1!==globalThis.__DEV__&&(h.prototype.getMemoryInternals=u.tQ)},84673(e,t,a){var r;a.d(t,{l:()=>r}),r||(r={})},65702(e,t,a){a.d(t,{Z:()=>i});var r=a(85608),i=function(e){function t(a,r,i,n){var p,o=e.call(this,a)||this;if(o.message=a,o.path=r,o.query=i,o.variables=n,Array.isArray(o.path)){o.missing=o.message;for(var s=o.path.length-1;s>=0;--s)(p={})[o.path[s]]=o.missing,o.missing=p}else o.missing=o.path;return o.__proto__=t.prototype,o}return(0,r.__extends)(t,e),t}(Error)},94037(e,t,a){a.r(t),a.d(t,{fieldNameFromStoreName:()=>d.iJ,makeVar:()=>u.UT,canonicalStringify:()=>o.M,cacheSlot:()=>u.bl,isReference:()=>p.A_,MissingFieldError:()=>n.Z,EntityStore:()=>s.D_,Cache:()=>i.l,Policies:()=>c.l,InMemoryCache:()=>l.D,ApolloCache:()=>r.k,defaultDataIdFromObject:()=>d.or,makeReference:()=>p.WU,createFragmentRegistry:()=>_}),a(70916);var r=a(42495),i=a(84673),n=a(65702),p=a(28907),o=a(44214),s=a(83906),d=a(35207),l=a(7068),u=a(777),c=a(92610),m=a(85608),f=a(90424),h=a(60837),v=a(3777),y=a(555),g=a(54019);function _(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return new(b.bind.apply(b,(0,m.__spreadArray)([void 0],e,!1)))}var b=function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.registry=Object.create(null),this.resetCaches(),e.length&&this.register.apply(this,e)}return e.prototype.register=function(){for(var e=this,t=[],a=0;a<arguments.length;a++)t[a]=arguments[a];var r=new Map;return t.forEach(function(e){(0,v.zK)(e).forEach(function(e){r.set(e.name.value,e)})}),r.forEach(function(t,a){t!==e.registry[a]&&(e.registry[a]=t,e.invalidate(a))}),this},e.prototype.invalidate=function(e){},e.prototype.resetCaches=function(){var t=e.prototype;this.invalidate=(this.lookup=(0,h.wrap)(t.lookup.bind(this),{makeCacheKey:function(e){return e},max:y.v["fragmentRegistry.lookup"]||1e3})).dirty,this.transform=(0,h.wrap)(t.transform.bind(this),{cache:g.l,max:y.v["fragmentRegistry.transform"]||2e3}),this.findFragmentSpreads=(0,h.wrap)(t.findFragmentSpreads.bind(this),{cache:g.l,max:y.v["fragmentRegistry.findFragmentSpreads"]||4e3})},e.prototype.lookup=function(e){return this.registry[e]||null},e.prototype.transform=function(e){var t=this,a=new Map;(0,v.zK)(e).forEach(function(e){a.set(e.name.value,e)});var r=new Set,i=function(e){a.has(e)||r.add(e)},n=function(e){return Object.keys(t.findFragmentSpreads(e)).forEach(i)};n(e);var p=[],o=Object.create(null);if(r.forEach(function(e){var r=a.get(e);if(r)n(o[e]=r);else{p.push(e);var i=t.lookup(e);i&&n(o[e]=i)}}),p.length){var s=[];p.forEach(function(e){var t=o[e];t&&s.push(t)}),s.length&&(e=(0,m.__assign)((0,m.__assign)({},e),{definitions:e.definitions.concat(s)}))}return e},e.prototype.findFragmentSpreads=function(e){var t=Object.create(null);return(0,f.YR)(e,{FragmentSpread:function(e){t[e.name.value]=e}}),t},e}()},83906(e,t,a){a.d(t,{$7:()=>S,D_:()=>_,M2:()=>w});var r,i,n=a(85608),p=a(70916),o=a(60837),s=a(55888),d=a(44592),l=a(57236),u=a(28907),c=a(30671),m=a(21777),f=a(51360),h=a(35207),v=Object.create(null),y=function(){return v},g=Object.create(null),_=function(){function e(e,t){var a=this;this.policies=e,this.group=t,this.data=Object.create(null),this.rootIds=Object.create(null),this.refs=Object.create(null),this.getFieldValue=function(e,t){return(0,l.G)((0,u.A_)(e)?a.get(e.__ref,t):e&&e[t])},this.canRead=function(e){return(0,u.A_)(e)?a.has(e.__ref):"object"==typeof e},this.toReference=function(e,t){if("string"==typeof e)return(0,u.WU)(e);if((0,u.A_)(e))return e;var r=a.policies.identify(e)[0];if(r){var i=(0,u.WU)(r);return t&&a.merge(r,e),i}}}return e.prototype.toObject=function(){return(0,n.__assign)({},this.data)},e.prototype.has=function(e){return void 0!==this.lookup(e,!0)},e.prototype.get=function(e,t){if(this.group.depend(e,t),h.$3.call(this.data,e)){var a=this.data[e];if(a&&h.$3.call(a,t))return a[t]}return"__typename"===t&&h.$3.call(this.policies.rootTypenamesById,e)?this.policies.rootTypenamesById[e]:this instanceof E?this.parent.get(e,t):void 0},e.prototype.lookup=function(e,t){return(t&&this.group.depend(e,"__exists"),h.$3.call(this.data,e))?this.data[e]:this instanceof E?this.parent.lookup(e,t):this.policies.rootTypenamesById[e]?Object.create(null):void 0},e.prototype.merge=function(e,t){var a,r=this;(0,u.A_)(e)&&(e=e.__ref),(0,u.A_)(t)&&(t=t.__ref);var i="string"==typeof e?this.lookup(a=e):e,n="string"==typeof t?this.lookup(a=t):t;if(n){(0,p.invariant)("string"==typeof a,2);var o=new c.ZI(N).merge(i,n);if(this.data[a]=o,o!==i&&(delete this.refs[a],this.group.caching)){var s=Object.create(null);i||(s.__exists=1),Object.keys(n).forEach(function(e){if(!i||i[e]!==o[e]){s[e]=1;var t=(0,h.iJ)(e);t===e||r.policies.hasKeyArgs(o.__typename,t)||(s[t]=1),void 0!==o[e]||r instanceof E||delete o[e]}}),s.__typename&&!(i&&i.__typename)&&this.policies.rootTypenamesById[a]===o.__typename&&delete s.__typename,Object.keys(s).forEach(function(e){return r.group.dirty(a,e)})}}},e.prototype.modify=function(e,t){var a=this,r=this.lookup(e);if(r){var i=Object.create(null),o=!1,s=!0,d={DELETE:v,INVALIDATE:g,isReference:u.A_,toReference:this.toReference,canRead:this.canRead,readField:function(t,r){return a.policies.readField("string"==typeof t?{fieldName:t,from:r||(0,u.WU)(e)}:t,{store:a})}};if(Object.keys(r).forEach(function(c){var m=(0,h.iJ)(c),f=r[c];if(void 0!==f){var _="function"==typeof t?t:t[c]||t[m];if(_){var b=_===y?v:_((0,l.G)(f),(0,n.__assign)((0,n.__assign)({},d),{fieldName:m,storeFieldName:c,storage:a.getStorage(e,c)}));if(b===g)a.group.dirty(e,c);else if(b===v&&(b=void 0),b!==f&&(i[c]=b,o=!0,f=b,!1!==globalThis.__DEV__)){var w=function(e){if(void 0===a.lookup(e.__ref))return!1!==globalThis.__DEV__&&p.invariant.warn(3,e),!0};if((0,u.A_)(b))w(b);else if(Array.isArray(b))for(var E=!1,T=void 0,N=0,S=b;N<S.length;N++){var O=S[N];if((0,u.A_)(O)){if(E=!0,w(O))break}else"object"==typeof O&&O&&a.policies.identify(O)[0]&&(T=O);if(E&&void 0!==T){!1!==globalThis.__DEV__&&p.invariant.warn(4,T);break}}}}void 0!==f&&(s=!1)}}),o)return this.merge(e,i),s&&(this instanceof E?this.data[e]=void 0:delete this.data[e],this.group.dirty(e,"__exists")),!0}return!1},e.prototype.delete=function(e,t,a){var r,i=this.lookup(e);if(i){var n=this.getFieldValue(i,"__typename"),p=t&&a?this.policies.getStoreFieldName({typename:n,fieldName:t,args:a}):t;return this.modify(e,p?((r={})[p]=y,r):y)}return!1},e.prototype.evict=function(e,t){var a=!1;return e.id&&(h.$3.call(this.data,e.id)&&(a=this.delete(e.id,e.fieldName,e.args)),this instanceof E&&this!==t&&(a=this.parent.evict(e,t)||a),(e.fieldName||a)&&this.group.dirty(e.id,e.fieldName||"__exists")),a},e.prototype.clear=function(){this.replace(null)},e.prototype.extract=function(){var e=this,t=this.toObject(),a=[];return this.getRootIdSet().forEach(function(t){h.$3.call(e.policies.rootTypenamesById,t)||a.push(t)}),a.length&&(t.__META={extraRootIds:a.sort()}),t},e.prototype.replace=function(e){var t=this;if(Object.keys(this.data).forEach(function(a){e&&h.$3.call(e,a)||t.delete(a)}),e){var a=e.__META,r=(0,n.__rest)(e,["__META"]);Object.keys(r).forEach(function(e){t.merge(e,r[e])}),a&&a.extraRootIds.forEach(this.retain,this)}},e.prototype.retain=function(e){return this.rootIds[e]=(this.rootIds[e]||0)+1},e.prototype.release=function(e){if(this.rootIds[e]>0){var t=--this.rootIds[e];return t||delete this.rootIds[e],t}return 0},e.prototype.getRootIdSet=function(e){return void 0===e&&(e=new Set),Object.keys(this.rootIds).forEach(e.add,e),this instanceof E?this.parent.getRootIdSet(e):Object.keys(this.policies.rootTypenamesById).forEach(e.add,e),e},e.prototype.gc=function(){var e=this,t=this.getRootIdSet(),a=this.toObject();t.forEach(function(r){h.$3.call(a,r)&&(Object.keys(e.findChildRefIds(r)).forEach(t.add,t),delete a[r])});var r=Object.keys(a);if(r.length){for(var i=this;i instanceof E;)i=i.parent;r.forEach(function(e){return i.delete(e)})}return r},e.prototype.findChildRefIds=function(e){if(!h.$3.call(this.refs,e)){var t=this.refs[e]=Object.create(null),a=this.data[e];if(!a)return t;var r=new Set([a]);r.forEach(function(e){(0,u.A_)(e)&&(t[e.__ref]=!0),(0,m.U)(e)&&Object.keys(e).forEach(function(t){var a=e[t];(0,m.U)(a)&&r.add(a)})})}return this.refs[e]},e.prototype.makeCacheKey=function(){return this.group.keyMaker.lookupArray(arguments)},e}(),b=function(){function e(e,t){void 0===t&&(t=null),this.caching=e,this.parent=t,this.d=null,this.resetCaching()}return e.prototype.resetCaching=function(){this.d=this.caching?(0,o.dep)():null,this.keyMaker=new d.Trie(f.et)},e.prototype.depend=function(e,t){if(this.d){this.d(t+"#"+e);var a=(0,h.iJ)(t);a!==t&&this.d(a+"#"+e),this.parent&&this.parent.depend(e,t)}},e.prototype.dirty=function(e,t){this.d&&this.d.dirty(t+"#"+e,"__exists"===t?"forget":"setDirty")},e}();function w(e,t){S(e)&&e.group.depend(t,"__exists")}i=function(e){function t(t){var a=t.policies,r=t.resultCaching,i=t.seed,n=e.call(this,a,new b(void 0===r||r))||this;return n.stump=new T(n),n.storageTrie=new d.Trie(f.et),i&&n.replace(i),n}return(0,n.__extends)(t,e),t.prototype.addLayer=function(e,t){return this.stump.addLayer(e,t)},t.prototype.removeLayer=function(){return this},t.prototype.getStorage=function(){return this.storageTrie.lookupArray(arguments)},t}(r=_||(_={})),r.Root=i;var E=function(e){function t(t,a,r,i){var n=e.call(this,a.policies,i)||this;return n.id=t,n.parent=a,n.replay=r,n.group=i,r(n),n}return(0,n.__extends)(t,e),t.prototype.addLayer=function(e,a){return new t(e,this,a,this.group)},t.prototype.removeLayer=function(e){var t=this,a=this.parent.removeLayer(e);return e===this.id?(this.group.caching&&Object.keys(this.data).forEach(function(e){var r=t.data[e],i=a.lookup(e);i?r?r!==i&&Object.keys(r).forEach(function(a){(0,s.equal)(r[a],i[a])||t.group.dirty(e,a)}):(t.group.dirty(e,"__exists"),Object.keys(i).forEach(function(a){t.group.dirty(e,a)})):t.delete(e)}),a):a===this.parent?this:a.addLayer(this.id,this.replay)},t.prototype.toObject=function(){return(0,n.__assign)((0,n.__assign)({},this.parent.toObject()),this.data)},t.prototype.findChildRefIds=function(t){var a=this.parent.findChildRefIds(t);return h.$3.call(this.data,t)?(0,n.__assign)((0,n.__assign)({},a),e.prototype.findChildRefIds.call(this,t)):a},t.prototype.getStorage=function(){for(var e=this.parent;e.parent;)e=e.parent;return e.getStorage.apply(e,arguments)},t}(_),T=function(e){function t(t){return e.call(this,"EntityStore.Stump",t,function(){},new b(t.group.caching,t.group))||this}return(0,n.__extends)(t,e),t.prototype.removeLayer=function(){return this},t.prototype.merge=function(e,t){return this.parent.merge(e,t)},t}(E);function N(e,t,a){var r=e[a],i=t[a];return(0,s.equal)(r,i)?r:i}function S(e){return!!(e instanceof _&&e.group.caching)}},35207(e,t,a){a.d(t,{$3:()=>u,I6:()=>h,T9:()=>function e(t,a,r){return!!(0,n.U)(a)&&((0,p.c)(a)?a.every(function(a){return e(t,a,r)}):t.selections.every(function(t){if((0,i.dt)(t)&&(0,o.MS)(t,r)){var n=(0,i.ue)(t);return u.call(a,n)&&(!t.selectionSet||e(t.selectionSet,a[n],r))}return!0}))},Ui:()=>y,Xx:()=>v,d1:()=>b,gk:()=>g,iJ:()=>_,lq:()=>E,mv:()=>w,or:()=>m});var r=a(50492),i=a(28907),n=a(21777),p=a(73767),o=a(82307),s=a(30671),d=a(2904),l=a(3777),u=Object.prototype.hasOwnProperty;function c(e){return null==e}function m(e,t){var a=e.__typename,r=e.id,i=e._id;if("string"==typeof a&&(t&&(t.keyObject=c(r)?c(i)?void 0:{_id:i}:{id:r}),c(r)&&!c(i)&&(r=i),!c(r)))return"".concat(a,":").concat("number"==typeof r||"string"==typeof r?r:JSON.stringify(r))}var f={dataIdFromObject:m,addTypename:!0,resultCaching:!0,canonizeResults:!1};function h(e){return(0,r.o)(f,e)}function v(e){var t=e.canonizeResults;return void 0===t?f.canonizeResults:t}function y(e,t){return(0,i.A_)(t)?e.get(t.__ref,"__typename"):t&&t.__typename}var g=/^[_a-z][_0-9a-z]*/i;function _(e){var t=e.match(g);return t?t[0]:e}function b(e){return(0,n.U)(e)&&!(0,i.A_)(e)&&!(0,p.c)(e)}function w(){return new s.ZI}function E(e,t){var a=(0,d.JG)((0,l.zK)(e));return{fragmentMap:a,lookupFragment:function(e){var r=a[e];return!r&&t&&(r=t.lookup(e)),r||null}}}},7068(e,t,a){a.d(t,{D:()=>B});var r=a(85608),i=a(70916),n=a(60837),p=a(55888),o=a(42495),s=a(65702),d=a(9354),l=a(53925),u=a(555),c=a(44214),m=a(38678),f=a(28907),h=a(42455),v=a(51360),y=a(50492),g=a(3777),_=a(30671),b=a(82307),w=a(2904),E=a(57236),T=a(21777),N=a(83906),S=a(35207),O=a(73767),I=a(44592),D=function(){function e(){this.known=new(v.En?WeakSet:Set),this.pool=new I.Trie(v.et),this.passes=new WeakMap,this.keysByJSON=new Map,this.empty=this.admit({})}return e.prototype.isKnown=function(e){return(0,T.U)(e)&&this.known.has(e)},e.prototype.pass=function(e){if((0,T.U)(e)){var t=(0,T.U)(e)?(0,O.c)(e)?e.slice(0):(0,r.__assign)({__proto__:Object.getPrototypeOf(e)},e):e;return this.passes.set(t,e),t}return e},e.prototype.admit=function(e){var t=this;if((0,T.U)(e)){var a=this.passes.get(e);if(a)return a;switch(Object.getPrototypeOf(e)){case Array.prototype:if(this.known.has(e))break;var r=e.map(this.admit,this),i=this.pool.lookupArray(r);return i.array||(this.known.add(i.array=r),!1!==globalThis.__DEV__&&Object.freeze(r)),i.array;case null:case Object.prototype:if(this.known.has(e))break;var n=Object.getPrototypeOf(e),p=[n],o=this.sortedKeys(e);p.push(o.json);var s=p.length;o.sorted.forEach(function(a){p.push(t.admit(e[a]))});var i=this.pool.lookupArray(p);if(!i.object){var d=i.object=Object.create(n);this.known.add(d),o.sorted.forEach(function(e,t){d[e]=p[s+t]}),!1!==globalThis.__DEV__&&Object.freeze(d)}return i.object}}return e},e.prototype.sortedKeys=function(e){var t=Object.keys(e),a=this.pool.lookupArray(t);if(!a.keys){t.sort();var r=JSON.stringify(t);(a.keys=this.keysByJSON.get(r))||this.keysByJSON.set(r,a.keys={sorted:t,json:r})}return a.keys},e}();function A(e){return[e.selectionSet,e.objectOrReference,e.context,e.context.canonizeResults]}var k=function(){function e(e){var t=this;this.knownResults=new(v.et?WeakMap:Map),this.config=(0,y.o)(e,{addTypename:!1!==e.addTypename,canonizeResults:(0,S.Xx)(e)}),this.canon=e.canon||new D,this.executeSelectionSet=(0,n.wrap)(function(e){var a,i=e.context.canonizeResults,n=A(e);n[3]=!i;var p=(a=t.executeSelectionSet).peek.apply(a,n);return p?i?(0,r.__assign)((0,r.__assign)({},p),{result:t.canon.admit(p.result)}):p:((0,N.M2)(e.context.store,e.enclosingRef.__ref),t.execSelectionSetImpl(e))},{max:this.config.resultCacheMaxSize||u.v["inMemoryCache.executeSelectionSet"]||5e4,keyArgs:A,makeCacheKey:function(e,t,a,r){if((0,N.$7)(a.store))return a.store.makeCacheKey(e,(0,f.A_)(t)?t.__ref:t,a.varString,r)}}),this.executeSubSelectedArray=(0,n.wrap)(function(e){return(0,N.M2)(e.context.store,e.enclosingRef.__ref),t.execSubSelectedArrayImpl(e)},{max:this.config.resultCacheMaxSize||u.v["inMemoryCache.executeSubSelectedArray"]||1e4,makeCacheKey:function(e){var t=e.field,a=e.array,r=e.context;if((0,N.$7)(r.store))return r.store.makeCacheKey(t,a,r.varString)}})}return e.prototype.resetCanon=function(){this.canon=new D},e.prototype.diffQueryAgainstStore=function(e){var t,a=e.store,i=e.query,n=e.rootId,p=e.variables,o=e.returnPartialData,d=e.canonizeResults,l=void 0===d?this.config.canonizeResults:d,u=this.config.cache.policies;p=(0,r.__assign)((0,r.__assign)({},(0,g.wY)((0,g.AT)(i))),p);var m=(0,f.WU)(void 0===n?"ROOT_QUERY":n),h=this.executeSelectionSet({selectionSet:(0,g.Vn)(i).selectionSet,objectOrReference:m,enclosingRef:m,context:(0,r.__assign)({store:a,query:i,policies:u,variables:p,varString:(0,c.M)(p),canonizeResults:l},(0,S.lq)(i,this.config.fragments))});if(h.missing&&(t=[new s.Z(function(e){try{JSON.stringify(e,function(e,t){if("string"==typeof t)throw t;return t})}catch(e){return e}}(h.missing),h.missing,i,p)],!(void 0===o||o)))throw t[0];return{result:h.result,complete:!t,missing:t}},e.prototype.isFresh=function(e,t,a,r){if((0,N.$7)(r.store)&&this.knownResults.get(e)===a){var i=this.executeSelectionSet.peek(a,t,r,this.canon.isKnown(e));if(i&&e===i.result)return!0}return!1},e.prototype.execSelectionSetImpl=function(e){var t,a=this,r=e.selectionSet,n=e.objectOrReference,p=e.enclosingRef,o=e.context;if((0,f.A_)(n)&&!o.policies.rootTypenamesById[n.__ref]&&!o.store.has(n.__ref))return{result:this.canon.empty,missing:"Dangling reference to missing ".concat(n.__ref," object")};var s=o.variables,d=o.policies,u=o.store.getFieldValue(n,"__typename"),c=[],m=new _.ZI;function v(e,a){var r;return e.missing&&(t=m.merge(t,((r={})[a]=e.missing,r))),e.result}this.config.addTypename&&"string"==typeof u&&!d.rootIdsByTypename[u]&&c.push({__typename:u});var y=new Set(r.selections);y.forEach(function(e){var r,g;if((0,b.MS)(e,s))if((0,f.dt)(e)){var _=d.readField({fieldName:e.name.value,field:e,variables:o.variables,from:n},o),E=(0,f.ue)(e);void 0===_?l.XY.added(e)||(t=m.merge(t,((r={})[E]="Can't find field '".concat(e.name.value,"' on ").concat((0,f.A_)(n)?n.__ref+" object":"object "+JSON.stringify(n,null,2)),r))):(0,O.c)(_)?_.length>0&&(_=v(a.executeSubSelectedArray({field:e,array:_,enclosingRef:p,context:o}),E)):e.selectionSet?null!=_&&(_=v(a.executeSelectionSet({selectionSet:e.selectionSet,objectOrReference:_,enclosingRef:(0,f.A_)(_)?_:p,context:o}),E)):o.canonizeResults&&(_=a.canon.pass(_)),void 0!==_&&c.push(((g={})[E]=_,g))}else{var T=(0,w.HQ)(e,o.lookupFragment);if(!T&&e.kind===h.b.FRAGMENT_SPREAD)throw(0,i.newInvariantError)(10,e.name.value);T&&d.fragmentMatches(T,u)&&T.selectionSet.selections.forEach(y.add,y)}});var g={result:(0,_.IM)(c),missing:t},T=o.canonizeResults?this.canon.admit(g):(0,E.G)(g);return T.result&&this.knownResults.set(T.result,r),T},e.prototype.execSubSelectedArrayImpl=function(e){var t,a=this,r=e.field,n=e.array,p=e.enclosingRef,o=e.context,s=new _.ZI;function d(e,a){var r;return e.missing&&(t=s.merge(t,((r={})[a]=e.missing,r))),e.result}return r.selectionSet&&(n=n.filter(o.store.canRead)),n=n.map(function(e,t){return null===e?null:(0,O.c)(e)?d(a.executeSubSelectedArray({field:r,array:e,enclosingRef:p,context:o}),t):r.selectionSet?d(a.executeSelectionSet({selectionSet:r.selectionSet,objectOrReference:e,enclosingRef:(0,f.A_)(e)?e:p,context:o}),t):(!1!==globalThis.__DEV__&&function(e,t,a){if(!t.selectionSet){var r=new Set([a]);r.forEach(function(a){(0,T.U)(a)&&((0,i.invariant)(!(0,f.A_)(a),11,(0,S.Ui)(e,a),t.name.value),Object.values(a).forEach(r.add,r))})}}(o.store,r,e),e)}),{result:o.canonizeResults?this.canon.admit(n):n,missing:t}},e}(),x=a(20906),C=a(92610);function R(e,t,a){var i="".concat(t).concat(a),n=e.flavors.get(i);return n||e.flavors.set(i,n=e.clientOnly===t&&e.deferred===a?e:(0,r.__assign)((0,r.__assign)({},e),{clientOnly:t,deferred:a})),n}var V=function(){function e(e,t,a){this.cache=e,this.reader=t,this.fragments=a}return e.prototype.writeToStore=function(e,t){var a=this,n=t.query,o=t.result,s=t.dataId,d=t.variables,l=t.overwrite,u=(0,g.Vu)(n),m=(0,S.mv)();d=(0,r.__assign)((0,r.__assign)({},(0,g.wY)(u)),d);var h=(0,r.__assign)((0,r.__assign)({store:e,written:Object.create(null),merge:function(e,t){return m.merge(e,t)},variables:d,varString:(0,c.M)(d)},(0,S.lq)(n,this.fragments)),{overwrite:!!l,incomingById:new Map,clientOnly:!1,deferred:!1,flavors:new Map}),v=this.processSelectionSet({result:o||Object.create(null),dataId:s,selectionSet:u.selectionSet,mergeTree:{map:new Map},context:h});if(!(0,f.A_)(v))throw(0,i.newInvariantError)(12,o);return h.incomingById.forEach(function(t,n){var o=t.storeObject,s=t.mergeTree,d=t.fieldNodeSet,l=(0,f.WU)(n);if(s&&s.map.size){var u=a.applyMerges(s,l,o,h);if((0,f.A_)(u))return;o=u}if(!1!==globalThis.__DEV__&&!h.overwrite){var c=Object.create(null);d.forEach(function(e){e.selectionSet&&(c[e.name.value]=!0)});var m=function(e){var t=s&&s.map.get(e);return!!(t&&t.info&&t.info.merge)};Object.keys(o).forEach(function(e){!0!==c[(0,S.iJ)(e)]||m(e)||function(e,t,a,n){var o=function(e){var t=n.getFieldValue(e,a);return"object"==typeof t&&t},s=o(e);if(s){var d=o(t);if(!(!d||(0,f.A_)(s)||(0,p.equal)(s,d)||Object.keys(s).every(function(e){return void 0!==n.getFieldValue(d,e)}))){var l=n.getFieldValue(e,"__typename")||n.getFieldValue(t,"__typename"),u=(0,S.iJ)(a),c="".concat(l,".").concat(u);if(!j.has(c)){j.add(c);var m=[];(0,O.c)(s)||(0,O.c)(d)||[s,d].forEach(function(e){var t=n.getFieldValue(e,"__typename");"string"!=typeof t||m.includes(t)||m.push(t)}),!1!==globalThis.__DEV__&&i.invariant.warn(15,u,l,m.length?"either ensure all objects of type "+m.join(" and ")+" have an ID or a custom merge function, or ":"",c,(0,r.__assign)({},s),(0,r.__assign)({},d))}}}}(l,o,e,h.store)})}e.merge(n,o)}),e.retain(v.__ref),v},e.prototype.processSelectionSet=function(e){var t=this,a=e.dataId,n=e.result,p=e.selectionSet,o=e.context,s=e.mergeTree,d=this.cache.policies,u=Object.create(null),c=a&&d.rootTypenamesById[a]||(0,f.D$)(n,p,o.fragmentMap)||a&&o.store.get(a,"__typename");"string"==typeof c&&(u.__typename=c);var m=function(){var e=(0,C.m)(arguments,u,o.variables);if((0,f.A_)(e.from)){var t=o.incomingById.get(e.from.__ref);if(t){var a=d.readField((0,r.__assign)((0,r.__assign)({},e),{from:t.storeObject}),o);if(void 0!==a)return a}}return d.readField(e,o)},h=new Set;this.flattenFields(p,n,o,c).forEach(function(e,a){var r,p=n[(0,f.ue)(a)];if(h.add(a),void 0!==p){var o=d.getStoreFieldName({typename:c,fieldName:a.name.value,field:a,variables:e.variables}),v=$(s,o),y=t.processFieldValue(p,a,a.selectionSet?R(e,!1,!1):e,v),g=void 0;a.selectionSet&&((0,f.A_)(y)||(0,S.d1)(y))&&(g=m("__typename",y));var _=d.getMergeFunction(c,a.name.value,g);_?v.info={field:a,typename:c,merge:_}:L(s,o),u=e.merge(u,((r={})[o]=y,r))}else!1===globalThis.__DEV__||e.clientOnly||e.deferred||l.XY.added(a)||d.getReadFunction(c,a.name.value)||!1===globalThis.__DEV__||i.invariant.error(13,(0,f.ue)(a),n)});try{var v=d.identify(n,{typename:c,selectionSet:p,fragmentMap:o.fragmentMap,storeObject:u,readField:m}),y=v[0],g=v[1];a=a||y,g&&(u=o.merge(u,g))}catch(e){if(!a)throw e}if("string"==typeof a){var _=(0,f.WU)(a),b=o.written[a]||(o.written[a]=[]);if(b.indexOf(p)>=0||(b.push(p),this.reader&&this.reader.isFresh(n,_,p,o)))return _;var w=o.incomingById.get(a);return w?(w.storeObject=o.merge(w.storeObject,u),w.mergeTree=function e(t,a){if(t===a||!a||P(a))return t;if(!t||P(t))return a;var i=t.info&&a.info?(0,r.__assign)((0,r.__assign)({},t.info),a.info):t.info||a.info,n=t.map.size&&a.map.size,p={info:i,map:n?new Map:t.map.size?t.map:a.map};if(n){var o=new Set(a.map.keys());t.map.forEach(function(t,r){p.map.set(r,e(t,a.map.get(r))),o.delete(r)}),o.forEach(function(r){p.map.set(r,e(a.map.get(r),t.map.get(r)))})}return p}(w.mergeTree,s),h.forEach(function(e){return w.fieldNodeSet.add(e)})):o.incomingById.set(a,{storeObject:u,mergeTree:P(s)?void 0:s,fieldNodeSet:h}),_}return u},e.prototype.processFieldValue=function(e,t,a,r){var i=this;return t.selectionSet&&null!==e?(0,O.c)(e)?e.map(function(e,n){var p=i.processFieldValue(e,t,a,$(r,n));return L(r,n),p}):this.processSelectionSet({result:e,selectionSet:t.selectionSet,context:a,mergeTree:r}):!1!==globalThis.__DEV__?(0,x.m)(e):e},e.prototype.flattenFields=function(e,t,a,r){void 0===r&&(r=(0,f.D$)(t,e,a.fragmentMap));var n=new Map,p=this.cache.policies,o=new I.Trie(!1);return!function e(s,d){var l=o.lookup(s,d.clientOnly,d.deferred);l.visited||(l.visited=!0,s.selections.forEach(function(o){if((0,b.MS)(o,a.variables)){var s=d.clientOnly,l=d.deferred;if(!(s&&l)&&(0,O.E)(o.directives)&&o.directives.forEach(function(e){var t=e.name.value;if("client"===t&&(s=!0),"defer"===t){var r=(0,f.MB)(e,a.variables);r&&!1===r.if||(l=!0)}}),(0,f.dt)(o)){var u=n.get(o);u&&(s=s&&u.clientOnly,l=l&&u.deferred),n.set(o,R(a,s,l))}else{var c=(0,w.HQ)(o,a.lookupFragment);if(!c&&o.kind===h.b.FRAGMENT_SPREAD)throw(0,i.newInvariantError)(14,o.name.value);c&&p.fragmentMatches(c,r,t,a.variables)&&e(c.selectionSet,R(a,s,l))}}}))}(e,a),n},e.prototype.applyMerges=function(e,t,a,n,p){var o=this;if(e.map.size&&!(0,f.A_)(a)){var s,d,l=!(0,O.c)(a)&&((0,f.A_)(t)||(0,S.d1)(t))?t:void 0,u=a;l&&!p&&(p=[(0,f.A_)(l)?l.__ref:l]);var c=function(e,t){return(0,O.c)(e)?"number"==typeof t?e[t]:void 0:n.store.getFieldValue(e,String(t))};e.map.forEach(function(e,t){var a=c(l,t),r=c(u,t);if(void 0!==r){p&&p.push(t);var s=o.applyMerges(e,a,r,n,p);s!==r&&(d=d||new Map).set(t,s),p&&(0,i.invariant)(p.pop()===t)}}),d&&(a=(0,O.c)(u)?u.slice(0):(0,r.__assign)({},u),d.forEach(function(e,t){a[t]=e}))}return e.info?this.cache.policies.runMergeFunction(t,a,e.info,n,p&&(s=n.store).getStorage.apply(s,p)):a},e}(),F=[];function $(e,t){var a=e.map;return a.has(t)||a.set(t,F.pop()||{map:new Map}),a.get(t)}function P(e){return!e||!(e.info||e.map.size)}function L(e,t){var a=e.map,r=a.get(t);r&&P(r)&&(F.push(r),a.delete(t))}var j=new Set,M=a(777),U=a(44114),B=function(e){function t(t){void 0===t&&(t={});var a=e.call(this)||this;return a.watches=new Set,a.addTypenameTransform=new d.c(l.XY),a.assumeImmutableResults=!0,a.makeVar=M.UT,a.txCount=0,a.config=(0,S.I6)(t),a.addTypename=!!a.config.addTypename,a.policies=new C.l({cache:a,dataIdFromObject:a.config.dataIdFromObject,possibleTypes:a.config.possibleTypes,typePolicies:a.config.typePolicies}),a.init(),a}return(0,r.__extends)(t,e),t.prototype.init=function(){var e=this.data=new N.D_.Root({policies:this.policies,resultCaching:this.config.resultCaching});this.optimisticData=e.stump,this.resetResultCache()},t.prototype.resetResultCache=function(e){var t=this,a=this.storeReader,r=this.config.fragments;this.storeWriter=new V(this,this.storeReader=new k({cache:this,addTypename:this.addTypename,resultCacheMaxSize:this.config.resultCacheMaxSize,canonizeResults:(0,S.Xx)(this.config),canon:e?void 0:a&&a.canon,fragments:r}),r),this.maybeBroadcastWatch=(0,n.wrap)(function(e,a){return t.broadcastWatch(e,a)},{max:this.config.resultCacheMaxSize||u.v["inMemoryCache.maybeBroadcastWatch"]||5e3,makeCacheKey:function(e){var a=e.optimistic?t.optimisticData:t.data;if((0,N.$7)(a)){var r=e.optimistic,i=e.id,n=e.variables;return a.makeCacheKey(e.query,e.callback,(0,c.M)({optimistic:r,id:i,variables:n}))}}}),new Set([this.data.group,this.optimisticData.group]).forEach(function(e){return e.resetCaching()})},t.prototype.restore=function(e){return this.init(),e&&this.data.replace(e),this},t.prototype.extract=function(e){return void 0===e&&(e=!1),(e?this.optimisticData:this.data).extract()},t.prototype.read=function(e){var t=e.returnPartialData;try{return this.storeReader.diffQueryAgainstStore((0,r.__assign)((0,r.__assign)({},e),{store:e.optimistic?this.optimisticData:this.data,config:this.config,returnPartialData:void 0!==t&&t})).result||null}catch(e){if(e instanceof s.Z)return null;throw e}},t.prototype.write=function(e){try{return++this.txCount,this.storeWriter.writeToStore(this.data,e)}finally{--this.txCount||!1===e.broadcast||this.broadcastWatches()}},t.prototype.modify=function(e){if(S.$3.call(e,"id")&&!e.id)return!1;var t=e.optimistic?this.optimisticData:this.data;try{return++this.txCount,t.modify(e.id||"ROOT_QUERY",e.fields)}finally{--this.txCount||!1===e.broadcast||this.broadcastWatches()}},t.prototype.diff=function(e){return this.storeReader.diffQueryAgainstStore((0,r.__assign)((0,r.__assign)({},e),{store:e.optimistic?this.optimisticData:this.data,rootId:e.id||"ROOT_QUERY",config:this.config}))},t.prototype.watch=function(e){var t=this;return this.watches.size||(0,M.MS)(this),this.watches.add(e),e.immediate&&this.maybeBroadcastWatch(e),function(){t.watches.delete(e)&&!t.watches.size&&(0,M.WR)(t),t.maybeBroadcastWatch.forget(e)}},t.prototype.gc=function(e){c.M.reset(),m.y.reset(),this.addTypenameTransform.resetCache(),null==(t=this.config.fragments)||t.resetCaches();var t,a=this.optimisticData.gc();return e&&!this.txCount&&(e.resetResultCache?this.resetResultCache(e.resetResultIdentities):e.resetResultIdentities&&this.storeReader.resetCanon()),a},t.prototype.retain=function(e,t){return(t?this.optimisticData:this.data).retain(e)},t.prototype.release=function(e,t){return(t?this.optimisticData:this.data).release(e)},t.prototype.identify=function(e){if((0,f.A_)(e))return e.__ref;try{return this.policies.identify(e)[0]}catch(e){!1!==globalThis.__DEV__&&i.invariant.warn(e)}},t.prototype.evict=function(e){if(!e.id){if(S.$3.call(e,"id"))return!1;e=(0,r.__assign)((0,r.__assign)({},e),{id:"ROOT_QUERY"})}try{return++this.txCount,this.optimisticData.evict(e,this.data)}finally{--this.txCount||!1===e.broadcast||this.broadcastWatches()}},t.prototype.reset=function(e){var t=this;return this.init(),c.M.reset(),e&&e.discardWatches?(this.watches.forEach(function(e){return t.maybeBroadcastWatch.forget(e)}),this.watches.clear(),(0,M.WR)(this)):this.broadcastWatches(),Promise.resolve()},t.prototype.removeOptimistic=function(e){var t=this.optimisticData.removeLayer(e);t!==this.optimisticData&&(this.optimisticData=t,this.broadcastWatches())},t.prototype.batch=function(e){var t,a=this,i=e.update,n=e.optimistic,p=void 0===n||n,o=e.removeOptimistic,s=e.onWatchUpdated,d=function(e){var r=a.data,n=a.optimisticData;++a.txCount,e&&(a.data=a.optimisticData=e);try{return t=i(a)}finally{--a.txCount,a.data=r,a.optimisticData=n}},l=new Set;return s&&!this.txCount&&this.broadcastWatches((0,r.__assign)((0,r.__assign)({},e),{onWatchUpdated:function(e){return l.add(e),!1}})),"string"==typeof p?this.optimisticData=this.optimisticData.addLayer(p,d):!1===p?d(this.data):d(),"string"==typeof o&&(this.optimisticData=this.optimisticData.removeLayer(o)),s&&l.size?(this.broadcastWatches((0,r.__assign)((0,r.__assign)({},e),{onWatchUpdated:function(e,t){var a=s.call(this,e,t);return!1!==a&&l.delete(e),a}})),l.size&&l.forEach(function(e){return a.maybeBroadcastWatch.dirty(e)})):this.broadcastWatches(e),t},t.prototype.performTransaction=function(e,t){return this.batch({update:e,optimistic:t||null!==t})},t.prototype.transformDocument=function(e){return this.addTypenameToDocument(this.addFragmentsToDocument(e))},t.prototype.fragmentMatches=function(e,t){return this.policies.fragmentMatches(e,t)},t.prototype.lookupFragment=function(e){var t;return(null==(t=this.config.fragments)?void 0:t.lookup(e))||null},t.prototype.broadcastWatches=function(e){var t=this;this.txCount||this.watches.forEach(function(a){return t.maybeBroadcastWatch(a,e)})},t.prototype.addFragmentsToDocument=function(e){var t=this.config.fragments;return t?t.transform(e):e},t.prototype.addTypenameToDocument=function(e){return this.addTypename?this.addTypenameTransform.transformDocument(e):e},t.prototype.broadcastWatch=function(e,t){var a=e.lastDiff,r=this.diff(e);(!t||(e.optimistic&&"string"==typeof t.optimistic&&(r.fromOptimisticTransaction=!0),!t.onWatchUpdated||!1!==t.onWatchUpdated.call(this,e,r,a)))&&(a&&(0,p.equal)(a.result,r.result)||e.callback(e.lastDiff=r,a))},t}(o.k);!1!==globalThis.__DEV__&&(B.prototype.getMemoryInternals=U.cM)},92610(e,t,a){a.d(t,{l:()=>S,m:()=>I});var r=a(85608),i=a(70916),n=a(28907),p=a(86563),o=a(21777),s=a(35207),d=a(73767),l=a(777),u=a(30671),c=Object.create(null);function m(e){var t=JSON.stringify(e);return c[t]||(c[t]=Object.create(null))}function f(e){var t=m(e);return t.keyFieldsFn||(t.keyFieldsFn=function(t,a){var r=function(e,t){return a.readField(t,e)},n=a.keyObject=v(e,function(e){var n=g(a.storeObject,e,r);return void 0===n&&t!==a.storeObject&&s.$3.call(t,e[0])&&(n=g(t,e,y)),(0,i.invariant)(void 0!==n,5,e.join("."),t),n});return"".concat(a.typename,":").concat(JSON.stringify(n))})}function h(e){var t=m(e);return t.keyArgsFn||(t.keyArgsFn=function(t,a){var r=a.field,i=a.variables,p=a.fieldName,o=JSON.stringify(v(e,function(e){var a=e[0],p=a.charAt(0);if("@"===p){if(r&&(0,d.E)(r.directives)){var o=a.slice(1),l=r.directives.find(function(e){return e.name.value===o}),u=l&&(0,n.MB)(l,i);return u&&g(u,e.slice(1))}return}if("$"===p){var c=a.slice(1);if(i&&s.$3.call(i,c)){var m=e.slice(0);return m[0]=c,g(i,m)}return}if(t)return g(t,e)}));return(t||"{}"!==o)&&(p+=":"+o),p})}function v(e,t){var a=new u.ZI;return(function e(t){var a=m(t);if(!a.paths){var r=a.paths=[],i=[];t.forEach(function(a,n){(0,d.c)(a)?(e(a).forEach(function(e){return r.push(i.concat(e))}),i.length=0):(i.push(a),(0,d.c)(t[n+1])||(r.push(i.slice(0)),i.length=0))})}return a.paths})(e).reduce(function(e,r){var i,n=t(r);if(void 0!==n){for(var p=r.length-1;p>=0;--p)(i={})[r[p]]=n,n=i;e=a.merge(e,n)}return e},Object.create(null))}function y(e,t){return e[t]}function g(e,t,a){return a=a||y,function e(t){return(0,o.U)(t)?(0,d.c)(t)?t.map(e):v(Object.keys(t).sort(),function(e){return g(t,e)}):t}(t.reduce(function e(t,r){return(0,d.c)(t)?t.map(function(t){return e(t,r)}):t&&a(t,r)},e))}var _=a(47150);function b(e){return void 0!==e.args?e.args:e.field?(0,n.MB)(e.field,e.variables):null}var w=function(){},E=function(e,t){return t.fieldName},T=function(e,t,a){return(0,a.mergeObjects)(e,t)},N=function(e,t){return t},S=function(){function e(e){this.config=e,this.typePolicies=Object.create(null),this.toBeAdded=Object.create(null),this.supertypeMap=new Map,this.fuzzySubtypes=new Map,this.rootIdsByTypename=Object.create(null),this.rootTypenamesById=Object.create(null),this.usingPossibleTypes=!1,this.config=(0,r.__assign)({dataIdFromObject:s.or},e),this.cache=this.config.cache,this.setRootTypename("Query"),this.setRootTypename("Mutation"),this.setRootTypename("Subscription"),e.possibleTypes&&this.addPossibleTypes(e.possibleTypes),e.typePolicies&&this.addTypePolicies(e.typePolicies)}return e.prototype.identify=function(e,t){var a,i,n=this,p=t&&(t.typename||(null==(a=t.storeObject)?void 0:a.__typename))||e.__typename;if(p===this.rootTypenamesById.ROOT_QUERY)return["ROOT_QUERY"];var o=t&&t.storeObject||e,s=(0,r.__assign)((0,r.__assign)({},t),{typename:p,storeObject:o,readField:t&&t.readField||function(){var e=I(arguments,o);return n.readField(e,{store:n.cache.data,variables:e.variables})}}),l=p&&this.getTypePolicy(p),u=l&&l.keyFn||this.config.dataIdFromObject;return _.yV.withValue(!0,function(){for(;u;){var t=u((0,r.__assign)((0,r.__assign)({},e),o),s);if((0,d.c)(t))u=f(t);else{i=t;break}}}),i=i?String(i):void 0,s.keyObject?[i,s.keyObject]:[i]},e.prototype.addTypePolicies=function(e){var t=this;Object.keys(e).forEach(function(a){var i=e[a],n=i.queryType,p=i.mutationType,o=i.subscriptionType,d=(0,r.__rest)(i,["queryType","mutationType","subscriptionType"]);n&&t.setRootTypename("Query",a),p&&t.setRootTypename("Mutation",a),o&&t.setRootTypename("Subscription",a),s.$3.call(t.toBeAdded,a)?t.toBeAdded[a].push(d):t.toBeAdded[a]=[d]})},e.prototype.updateTypePolicy=function(e,t){var a=this,r=this.getTypePolicy(e),i=t.keyFields,n=t.fields;function p(e,t){e.merge="function"==typeof t?t:!0===t?T:!1===t?N:e.merge}p(r,t.merge),r.keyFn=!1===i?w:(0,d.c)(i)?f(i):"function"==typeof i?i:r.keyFn,n&&Object.keys(n).forEach(function(t){var r=a.getFieldPolicy(e,t,!0),i=n[t];if("function"==typeof i)r.read=i;else{var o=i.keyArgs,s=i.read,l=i.merge;r.keyFn=!1===o?E:(0,d.c)(o)?h(o):"function"==typeof o?o:r.keyFn,"function"==typeof s&&(r.read=s),p(r,l)}r.read&&r.merge&&(r.keyFn=r.keyFn||E)})},e.prototype.setRootTypename=function(e,t){void 0===t&&(t=e);var a="ROOT_"+e.toUpperCase(),r=this.rootTypenamesById[a];t!==r&&((0,i.invariant)(!r||r===e,6,e),r&&delete this.rootIdsByTypename[r],this.rootIdsByTypename[t]=a,this.rootTypenamesById[a]=t)},e.prototype.addPossibleTypes=function(e){var t=this;this.usingPossibleTypes=!0,Object.keys(e).forEach(function(a){t.getSupertypeSet(a,!0),e[a].forEach(function(e){t.getSupertypeSet(e,!0).add(a);var r=e.match(s.gk);r&&r[0]===e||t.fuzzySubtypes.set(e,new RegExp(e))})})},e.prototype.getTypePolicy=function(e){var t=this;if(!s.$3.call(this.typePolicies,e)){var a=this.typePolicies[e]=Object.create(null);a.fields=Object.create(null);var i=this.supertypeMap.get(e);!i&&this.fuzzySubtypes.size&&(i=this.getSupertypeSet(e,!0),this.fuzzySubtypes.forEach(function(a,r){if(a.test(e)){var n=t.supertypeMap.get(r);n&&n.forEach(function(e){return i.add(e)})}})),i&&i.size&&i.forEach(function(e){var i=t.getTypePolicy(e),n=i.fields;Object.assign(a,(0,r.__rest)(i,["fields"])),Object.assign(a.fields,n)})}var n=this.toBeAdded[e];return n&&n.length&&n.splice(0).forEach(function(a){t.updateTypePolicy(e,a)}),this.typePolicies[e]},e.prototype.getFieldPolicy=function(e,t,a){if(e){var r=this.getTypePolicy(e).fields;return r[t]||a&&(r[t]=Object.create(null))}},e.prototype.getSupertypeSet=function(e,t){var a=this.supertypeMap.get(e);return!a&&t&&this.supertypeMap.set(e,a=new Set),a},e.prototype.fragmentMatches=function(e,t,a,r){var n=this;if(!e.typeCondition)return!0;if(!t)return!1;var p=e.typeCondition.name.value;if(t===p)return!0;if(this.usingPossibleTypes&&this.supertypeMap.has(p))for(var o=this.getSupertypeSet(t,!0),d=[o],l=function(e){var t=n.getSupertypeSet(e,!1);t&&t.size&&0>d.indexOf(t)&&d.push(t)},u=!!(a&&this.fuzzySubtypes.size),c=!1,m=0;m<d.length;++m){var f=d[m];if(f.has(p))return o.has(p)||(c&&!1!==globalThis.__DEV__&&i.invariant.warn(7,t,p),o.add(p)),!0;f.forEach(l),u&&m===d.length-1&&(0,s.T9)(e.selectionSet,a,r)&&(u=!1,c=!0,this.fuzzySubtypes.forEach(function(e,a){var r=t.match(e);r&&r[0]===t&&l(a)}))}return!1},e.prototype.hasKeyArgs=function(e,t){var a=this.getFieldPolicy(e,t,!1);return!!(a&&a.keyFn)},e.prototype.getStoreFieldName=function(e){var t,a=e.typename,r=e.fieldName,i=this.getFieldPolicy(a,r,!1),p=i&&i.keyFn;if(p&&a)for(var o={typename:a,fieldName:r,field:e.field||null,variables:e.variables},l=b(e);p;){var u=p(l,o);if((0,d.c)(u))p=h(u);else{t=u||r;break}}return(void 0===t&&(t=e.field?(0,n.Ii)(e.field,e.variables):(0,n.o5)(r,b(e))),!1===t)?r:r===(0,s.iJ)(t)?t:r+":"+t},e.prototype.readField=function(e,t){var a=e.from;if(a&&(e.field||e.fieldName)){if(void 0===e.typename){var r=t.store.getFieldValue(a,"__typename");r&&(e.typename=r)}var i=this.getStoreFieldName(e),p=(0,s.iJ)(i),o=t.store.getFieldValue(a,i),d=this.getFieldPolicy(e.typename,p,!1),u=d&&d.read;if(u){var c=O(this,a,e,t,t.store.getStorage((0,n.A_)(a)?a.__ref:a,i));return l.bl.withValue(this.cache,u,[o,c])}return o}},e.prototype.getReadFunction=function(e,t){var a=this.getFieldPolicy(e,t,!1);return a&&a.read},e.prototype.getMergeFunction=function(e,t,a){var r=this.getFieldPolicy(e,t,!1),i=r&&r.merge;return!i&&a&&(i=(r=this.getTypePolicy(a))&&r.merge),i},e.prototype.runMergeFunction=function(e,t,a,r,i){var n=a.field,p=a.typename,o=a.merge;return o===T?D(r.store)(e,t):o===N?t:(r.overwrite&&(e=void 0),o(e,t,O(this,void 0,{typename:p,fieldName:n.name.value,field:n,variables:r.variables},r,i||Object.create(null))))},e}();function O(e,t,a,r,i){var p=e.getStoreFieldName(a),o=(0,s.iJ)(p),d=a.variables||r.variables,l=r.store,u=l.toReference,c=l.canRead;return{args:b(a),field:a.field||null,fieldName:o,storeFieldName:p,variables:d,isReference:n.A_,toReference:u,storage:i,cache:e.cache,canRead:c,readField:function(){return e.readField(I(arguments,t,d),r)},mergeObjects:D(r.store)}}function I(e,t,a){var n,o=e[0],d=e[1],l=e.length;return"string"==typeof o?n={fieldName:o,from:l>1?d:t}:(n=(0,r.__assign)({},o),s.$3.call(n,"from")||(n.from=t)),!1!==globalThis.__DEV__&&void 0===n.from&&!1!==globalThis.__DEV__&&i.invariant.warn(8,(0,p.p)(Array.from(e))),void 0===n.variables&&(n.variables=a),n}function D(e){return function(t,a){if((0,d.c)(t)||(0,d.c)(a))throw(0,i.newInvariantError)(9);if((0,o.U)(t)&&(0,o.U)(a)){var p=e.getFieldValue(t,"__typename"),l=e.getFieldValue(a,"__typename");if(p&&l&&p!==l)return a;if((0,n.A_)(t)&&(0,s.d1)(a))return e.merge(t.__ref,a),t;if((0,s.d1)(t)&&(0,n.A_)(a))return e.merge(t,a.__ref),a;if((0,s.d1)(t)&&(0,s.d1)(a))return(0,r.__assign)((0,r.__assign)({},t),a)}return a}}},777(e,t,a){a.d(t,{MS:()=>s,UT:()=>d,WR:()=>o,bl:()=>i});var r=a(60837),i=new r.Slot,n=new WeakMap;function p(e){var t=n.get(e);return t||n.set(e,t={vars:new Set,dep:(0,r.dep)()}),t}function o(e){p(e).vars.forEach(function(t){return t.forgetCache(e)})}function s(e){p(e).vars.forEach(function(t){return t.attachCache(e)})}function d(e){var t=new Set,a=new Set,r=function(o){if(arguments.length>0){if(e!==o){e=o,t.forEach(function(e){var t;p(e).dep.dirty(r),(t=e).broadcastWatches&&t.broadcastWatches()});var s=Array.from(a);a.clear(),s.forEach(function(t){return t(e)})}}else{var d=i.getValue();d&&(n(d),p(d).dep(r))}return e};r.onNextChange=function(e){return a.add(e),function(){a.delete(e)}};var n=r.attachCache=function(e){return t.add(e),p(e).vars.add(r),r};return r.forgetCache=function(e){return t.delete(e)},r}},55427(e,t,a){a.d(t,{a:()=>d});var r=a(85608),i=a(55888),n=a(3777),p=a(2904),o=a(82307),s=a(28907);function d(e,t,a,d){var u=t.data,c=(0,r.__rest)(t,["data"]),m=a.data,f=(0,r.__rest)(a,["data"]);return(0,i.default)(c,f)&&function e(t,a,r,n){if(a===r)return!0;var d=new Set;return t.selections.every(function(t){if(d.has(t)||(d.add(t),!(0,o.MS)(t,n.variables)||l(t)))return!0;if((0,s.dt)(t)){var u=(0,s.ue)(t),c=a&&a[u],m=r&&r[u],f=t.selectionSet;if(!f)return(0,i.default)(c,m);var h=Array.isArray(c),v=Array.isArray(m);if(h!==v)return!1;if(h&&v){var y=c.length;if(m.length!==y)return!1;for(var g=0;g<y;++g)if(!e(f,c[g],m[g],n))return!1;return!0}return e(f,c,m,n)}var _=(0,p.HQ)(t,n.fragmentMap);if(_)return!!l(_)||e(_.selectionSet,a,r,n)})}((0,n.Vn)(e).selectionSet,u,m,{fragmentMap:(0,p.JG)((0,n.zK)(e)),variables:d})}function l(e){return!!e.directives&&e.directives.some(u)}function u(e){return"nonreactive"===e.name.value}},53570(e,t,a){a.r(t),a.d(t,{ApolloError:()=>d,PROTOCOL_ERRORS_SYMBOL:()=>n,graphQLResultHasProtocolErrors:()=>p,isApolloError:()=>o});var r=a(85608);a(70916);var i=a(21777),n=Symbol();function p(e){return!!e.extensions&&Array.isArray(e.extensions[n])}function o(e){return e.hasOwnProperty("graphQLErrors")}var s=function(e){var t=(0,r.__spreadArray)((0,r.__spreadArray)((0,r.__spreadArray)([],e.graphQLErrors,!0),e.clientErrors,!0),e.protocolErrors,!0);return e.networkError&&t.push(e.networkError),t.map(function(e){return(0,i.U)(e)&&e.message||"Error message not found."}).join("\n")},d=function(e){function t(a){var i=a.graphQLErrors,n=a.protocolErrors,p=a.clientErrors,o=a.networkError,d=a.errorMessage,l=a.extraInfo,u=e.call(this,d)||this;return u.name="ApolloError",u.graphQLErrors=i||[],u.protocolErrors=n||[],u.clientErrors=p||[],u.networkError=o||null,u.message=d||s(u),u.extraInfo=l,u.cause=(0,r.__spreadArray)((0,r.__spreadArray)((0,r.__spreadArray)([o],i||[],!0),n||[],!0),p||[],!0).find(function(e){return!!e})||null,u.__proto__=t.prototype,u}return(0,r.__extends)(t,e),t}(Error)},19074(e,t,a){a.d(t,{C:()=>u});var r=a(70916),i=a(36054),n=a(16878),p=a(38414),o=a(46192);function s(e,t){return t?t(e):i.c.of()}function d(e){return"function"==typeof e?new u(e):e}function l(e){return e.request.length<=1}var u=function(){function e(e){e&&(this.request=e)}return e.empty=function(){return new e(function(){return i.c.of()})},e.from=function(t){return 0===t.length?e.empty():t.map(d).reduce(function(e,t){return e.concat(t)})},e.split=function(t,a,r){var n=d(a),p=d(r||new e(s));return Object.assign(new e(l(n)&&l(p)?function(e){return t(e)?n.request(e)||i.c.of():p.request(e)||i.c.of()}:function(e,a){return t(e)?n.request(e,a)||i.c.of():p.request(e,a)||i.c.of()}),{left:n,right:p})},e.execute=function(e,t){return e.request((0,n.k)(t.context,(0,p.A)((0,o.K)(t))))||i.c.of()},e.concat=function(t,a){var n=d(t);if(l(n))return!1!==globalThis.__DEV__&&r.invariant.warn(38,n),n;var p=d(a);return Object.assign(new e(l(p)?function(e){return n.request(e,function(e){return p.request(e)||i.c.of()})||i.c.of()}:function(e,t){return n.request(e,function(e){return p.request(e,t)||i.c.of()})||i.c.of()}),{left:n,right:p})},e.prototype.split=function(t,a,r){return this.concat(e.split(t,a,r||new e(s)))},e.prototype.concat=function(t){return e.concat(this,t)},e.prototype.request=function(e,t){throw(0,r.newInvariantError)(39)},e.prototype.onError=function(e,t){if(t&&t.error)return t.error(e),!1;throw e},e.prototype.setOnError=function(e){return this.onError=e,this},e}()},25174(e,t,a){a.d(t,{g:()=>r});var r=a(19074).C.execute},4232(e,t,a){a.r(t),a.d(t,{ApolloLink:()=>r.C,concat:()=>o,empty:()=>i,execute:()=>s.g,from:()=>n,split:()=>p}),a(70916);var r=a(19074),i=r.C.empty,n=r.C.from,p=r.C.split,o=r.C.concat,s=a(25174)},49952(e,t,a){a.d(t,{P:()=>p});var r=a(85608),i=a(19074),n=a(79760),p=function(e){function t(t){void 0===t&&(t={});var a=e.call(this,(0,n.$)(t).request)||this;return a.options=t,a}return(0,r.__extends)(t,e),t}(i.C)},67195(e,t,a){a.d(t,{S:()=>i});var r=a(70916),i=function(e){if(!e&&"u"<typeof fetch)throw(0,r.newInvariantError)(40)}},79760(e,t,a){a.d(t,{$:()=>_});var r=a(85608),i=a(70916),n=a(19074),p=a(82307),o=a(36054),s=a(63647),d=a(33068),l=a(90117),u=a(67195),c=a(74559),m=a(11151),f=a(93161),h=a(70783),v=a(53925),y=a(3777),g=(0,i.maybe)(function(){return fetch}),_=function(e){void 0===e&&(e={});var t=e.uri,a=void 0===t?"/graphql":t,_=e.fetch,b=e.print,w=void 0===b?c.i1:b,E=e.includeExtensions,T=e.preserveHeaderCase,N=e.useGETForQueries,S=e.includeUnusedVariables,O=void 0!==S&&S,I=(0,r.__rest)(e,["uri","fetch","print","includeExtensions","preserveHeaderCase","useGETForQueries","includeUnusedVariables"]);!1!==globalThis.__DEV__&&(0,u.S)(_||g);var D={http:{includeExtensions:E,preserveHeaderCase:T},options:I.fetchOptions,credentials:I.credentials,headers:I.headers};return new n.C(function(e){var t,n,u=(0,d.z)(e,a),b=e.getContext(),E={};if(b.clientAwareness){var T=b.clientAwareness,S=T.name,I=T.version;S&&(E["apollographql-client-name"]=S),I&&(E["apollographql-client-version"]=I)}var A=(0,r.__assign)((0,r.__assign)({},E),b.headers),k={http:b.http,options:b.fetchOptions,credentials:b.credentials,headers:A};if((0,p.d8)(["client"],e.query)){var x=(0,v.er)(e.query);if(!x)return(0,f.N)(Error("HttpLink: Trying to send a client-only query to the server. To send to the server, ensure a non-client field is added to the query or set the `transformOptions.removeClientFields` option to `true`."));e.query=x}var C=(0,c.HY)(e,w,c.R4,D,k),R=C.options,V=C.body;V.variables&&!O&&(V.variables=(0,h.X)(V.variables,e.query)),!R.signal&&"u">typeof AbortController&&(R.signal=(n=new AbortController).signal);var F="OperationDefinition"===(t=(0,y.Vn)(e.query)).kind&&"subscription"===t.operation,$=(0,p.d8)(["defer"],e.query);if(N&&!e.query.definitions.some(function(e){return"OperationDefinition"===e.kind&&"mutation"===e.operation})&&(R.method="GET"),$||F){R.headers=R.headers||{};var P="multipart/mixed;";F&&$&&!1!==globalThis.__DEV__&&i.invariant.warn(41),F?P+="boundary=graphql;subscriptionSpec=1.0,application/json":$&&(P+="deferSpec=20220824,application/json"),R.headers.accept=P}if("GET"===R.method){var L=(0,m.E)(u,V),j=L.newURI,M=L.parseError;if(M)return(0,f.N)(M);u=j}else try{R.body=(0,s.Y)(V,"Payload")}catch(e){return(0,f.N)(e)}return new o.c(function(t){var a=_||(0,i.maybe)(function(){return fetch})||g,r=t.next.bind(t);return a(u,R).then(function(t){e.setContext({response:t});var a,i=null==(a=t.headers)?void 0:a.get("content-type");return null!==i&&/^multipart\/mixed/i.test(i)?(0,l.tD)(t,r):(0,l.OQ)(e)(t).then(r)}).then(function(){n=void 0,t.complete()}).catch(function(e){n=void 0,(0,l.H4)(e,t)}),function(){n&&n.abort()}})})}},28876(e,t,a){a.r(t),a.d(t,{HttpLink:()=>l.P,parseAndCheckHttpResponse:()=>r.OQ,checkFetcher:()=>p.S,rewriteURIForGET:()=>u.E,serializeFetchParameter:()=>i.Y,createSignalIfSupported:()=>o,selectHttpOptionsAndBodyInternal:()=>n.HY,selectHttpOptionsAndBody:()=>n.Wz,selectURI:()=>s.z,fallbackHttpConfig:()=>n.R4,createHttpLink:()=>d.$,defaultPrinter:()=>n.i1}),a(70916);var r=a(90117),i=a(63647),n=a(74559),p=a(67195),o=function(){if("u"<typeof AbortController)return{controller:!1,signal:!1};var e=new AbortController,t=e.signal;return{controller:e,signal:t}},s=a(33068),d=a(79760),l=a(49952),u=a(11151)},90117(e,t,a){a.d(t,{H4:()=>c,OQ:()=>m,tD:()=>l});var r=a(85608),i=a(51360);function n(e){var t={next:function(){return e.read()}};return i.uJ&&(t[Symbol.asyncIterator]=function(){return this}),t}var p=a(3848),o=a(53570),s=a(37396),d=Object.prototype.hasOwnProperty;function l(e,t){return(0,r.__awaiter)(this,void 0,void 0,function(){var a,p,d,l,c,m,f,h,v,y,g,_,b,w,E,T,N,S,O,I,D,A,k;return(0,r.__generator)(this,function(x){switch(x.label){case 0:if(void 0===TextDecoder)throw Error("TextDecoder must be defined in the environment: please import a polyfill.");a=new TextDecoder("utf-8"),p=null==(k=e.headers)?void 0:k.get("content-type"),d="boundary=",l=(null==p?void 0:p.includes(d))?null==p?void 0:p.substring((null==p?void 0:p.indexOf(d))+d.length).replace(/['"]/g,"").replace(/\;(.*)/gm,"").trim():"-",c="\r\n--".concat(l),m="",f=function(e){var t,a,r,p,o,s,d=e;if(e.body&&(d=e.body),t=d,i.uJ&&t[Symbol.asyncIterator])return r=d[Symbol.asyncIterator](),(a={next:function(){return r.next()}})[Symbol.asyncIterator]=function(){return this},a;if(d.getReader)return n(d.getReader());if(d.stream)return n(d.stream().getReader());if(d.arrayBuffer)return p=d.arrayBuffer(),o=!1,s={next:function(){return o?Promise.resolve({value:void 0,done:!0}):(o=!0,new Promise(function(e,t){p.then(function(t){e({value:t,done:!1})}).catch(t)}))}},i.uJ&&(s[Symbol.asyncIterator]=function(){return this}),s;if(d.pipe)return function(e){var t=null,a=null,r=!1,n=[],p=[];function o(e){if(!a){if(p.length){var t=p.shift();if(Array.isArray(t)&&t[0])return t[0]({value:e,done:!1})}n.push(e)}}function s(e){a=e,p.slice().forEach(function(t){t[1](e)}),t&&t()}function d(){r=!0,p.slice().forEach(function(e){e[0]({value:void 0,done:!0})}),t&&t()}t=function(){t=null,e.removeListener("data",o),e.removeListener("error",s),e.removeListener("end",d),e.removeListener("finish",d),e.removeListener("close",d)},e.on("data",o),e.on("error",s),e.on("end",d),e.on("finish",d),e.on("close",d);var l={next:function(){return new Promise(function(e,t){return a?t(a):n.length?e({value:n.shift(),done:!1}):r?e({value:void 0,done:!0}):void p.push([e,t])})}};return i.uJ&&(l[Symbol.asyncIterator]=function(){return this}),l}(d);throw Error("Unknown body type for responseIterator. Please pass a streamable response.")}(e),h=!0,x.label=1;case 1:if(!h)return[3,3];return[4,f.next()];case 2:for(y=(v=x.sent()).value,g=v.done,_="string"==typeof y?y:a.decode(y),b=m.length-c.length+1,h=!g,m+=_,w=m.indexOf(c,b);w>-1;){if(E=void 0,E=(D=[m.slice(0,w),m.slice(w+c.length)])[0],m=D[1],T=E.indexOf("\r\n\r\n"),(N=function(e){var t={};return e.split("\n").forEach(function(e){var a=e.indexOf(":");if(a>-1){var r=e.slice(0,a).trim().toLowerCase(),i=e.slice(a+1).trim();t[r]=i}}),t}(E.slice(0,T))["content-type"])&&-1===N.toLowerCase().indexOf("application/json"))throw Error("Unsupported patch content type: application/json is required.");if(S=E.slice(T)){if(Object.keys(O=u(e,S)).length>1||"data"in O||"incremental"in O||"errors"in O||"payload"in O)if((0,s.Nw)(O)){if(I={},"payload"in O){if(1===Object.keys(O).length&&null===O.payload)return[2];I=(0,r.__assign)({},O.payload)}"errors"in O&&(I=(0,r.__assign)((0,r.__assign)({},I),{extensions:(0,r.__assign)((0,r.__assign)({},"extensions"in I?I.extensions:null),((A={})[o.PROTOCOL_ERRORS_SYMBOL]=O.errors,A))})),t(I)}else t(O);else if(1===Object.keys(O).length&&"hasNext"in O&&!O.hasNext)return[2]}w=m.indexOf(c)}return[3,1];case 3:return[2]}})})}function u(e,t){e.status>=300&&(0,p.A)(e,function(){try{return JSON.parse(t)}catch(e){return t}}(),"Response not successful: Received status code ".concat(e.status));try{return JSON.parse(t)}catch(a){throw a.name="ServerParseError",a.response=e,a.statusCode=e.status,a.bodyText=t,a}}function c(e,t){e.result&&e.result.errors&&e.result.data&&t.next(e.result),t.error(e)}function m(e){return function(t){return t.text().then(function(e){return u(t,e)}).then(function(a){return Array.isArray(a)||d.call(a,"data")||d.call(a,"errors")||(0,p.A)(t,a,"Server response was missing for query '".concat(Array.isArray(e)?e.map(function(e){return e.operationName}):e.operationName,"'.")),a})}}},11151(e,t,a){a.d(t,{E:()=>i});var r=a(63647);function i(e,t){var a=[],i=function(e,t){a.push("".concat(e,"=").concat(encodeURIComponent(t)))};if("query"in t&&i("query",t.query),t.operationName&&i("operationName",t.operationName),t.variables){var n=void 0;try{n=(0,r.Y)(t.variables,"Variables map")}catch(e){return{parseError:e}}i("variables",n)}if(t.extensions){var p=void 0;try{p=(0,r.Y)(t.extensions,"Extensions map")}catch(e){return{parseError:e}}i("extensions",p)}var o="",s=e,d=e.indexOf("#");-1!==d&&(o=e.substr(d),s=e.substr(0,d));var l=-1===s.indexOf("?")?"?":"&";return{newURI:s+l+a.join("&")+o}}},74559(e,t,a){a.d(t,{HY:()=>s,R4:()=>n,Wz:()=>o,i1:()=>p});var r=a(85608),i=a(38678),n={http:{includeQuery:!0,includeExtensions:!1,preserveHeaderCase:!1},headers:{accept:"*/*","content-type":"application/json"},options:{method:"POST"}},p=function(e,t){return t(e)};function o(e,t){for(var a=[],i=2;i<arguments.length;i++)a[i-2]=arguments[i];return a.unshift(t),s.apply(void 0,(0,r.__spreadArray)([e,p],a,!1))}function s(e,t){for(var a=[],n=2;n<arguments.length;n++)a[n-2]=arguments[n];var p={},o={};a.forEach(function(e){p=(0,r.__assign)((0,r.__assign)((0,r.__assign)({},p),e.options),{headers:(0,r.__assign)((0,r.__assign)({},p.headers),e.headers)}),e.credentials&&(p.credentials=e.credentials),o=(0,r.__assign)((0,r.__assign)({},o),e.http)}),p.headers&&(p.headers=function(e,t){if(!t){var a={};return Object.keys(Object(e)).forEach(function(t){a[t.toLowerCase()]=e[t]}),a}var r={};Object.keys(Object(e)).forEach(function(t){r[t.toLowerCase()]={originalName:t,value:e[t]}});var i={};return Object.keys(r).forEach(function(e){i[r[e].originalName]=r[e].value}),i}(p.headers,o.preserveHeaderCase));var s=e.operationName,d=e.extensions,l=e.variables,u=e.query,c={operationName:s,variables:l};return o.includeExtensions&&(c.extensions=d),o.includeQuery&&(c.query=t(u,i.y)),{options:p,body:c}}},33068(e,t,a){a.d(t,{z:()=>r});var r=function(e,t){var a=e.getContext().uri;return a||("function"==typeof t?t(e):t||"/graphql")}},63647(e,t,a){a.d(t,{Y:()=>i});var r=a(70916),i=function(e,t){var a;try{a=JSON.stringify(e)}catch(e){var i=(0,r.newInvariantError)(42,t,e.message);throw i.parseError=e,i}return a}},16878(e,t,a){a.d(t,{k:()=>i});var r=a(85608);function i(e,t){var a=(0,r.__assign)({},e);return Object.defineProperty(t,"setContext",{enumerable:!1,value:function(e){a="function"==typeof e?(0,r.__assign)((0,r.__assign)({},a),e(a)):(0,r.__assign)((0,r.__assign)({},a),e)}}),Object.defineProperty(t,"getContext",{enumerable:!1,value:function(){return(0,r.__assign)({},a)}}),t}},70783(e,t,a){a.d(t,{X:()=>n});var r=a(85608),i=a(90424);function n(e,t){var a=(0,r.__assign)({},e),n=new Set(Object.keys(e));return(0,i.YR)(t,{Variable:function(e,t,a){a&&"VariableDefinition"!==a.kind&&n.delete(e.name.value)}}),n.forEach(function(e){delete a[e]}),a}},93161(e,t,a){a.d(t,{N:()=>i});var r=a(36054);function i(e){return new r.c(function(t){t.error(e)})}},22594(e,t,a){a.d(t,{S:()=>i});var r=a(36054);function i(e){return new r.c(function(t){e.then(function(e){t.next(e),t.complete()}).catch(t.error.bind(t))})}},25979(e,t,a){a.r(t),a.d(t,{createOperation:()=>s.k,filterOperationVariables:()=>l.X,fromError:()=>r.N,fromPromise:()=>n.S,throwServerError:()=>p.A,toPromise:()=>i.h,transformOperation:()=>d.A,validateOperation:()=>o.K}),a(70916);var r=a(93161),i=a(60441),n=a(22594),p=a(3848),o=a(46192),s=a(16878),d=a(38414),l=a(70783)},3848(e,t,a){a.d(t,{A:()=>r});var r=function(e,t,a){var r=Error(a);throw r.name="ServerError",r.response=e,r.statusCode=e.status,r.result=t,r}},60441(e,t,a){a.d(t,{h:()=>i});var r=a(70916);function i(e){var t=!1;return new Promise(function(a,i){e.subscribe({next:function(e){t?!1!==globalThis.__DEV__&&r.invariant.warn(45):(t=!0,a(e))},error:i})})}},38414(e,t,a){a.d(t,{A:()=>i});var r=a(3777);function i(e){var t={variables:e.variables||{},extensions:e.extensions||{},operationName:e.operationName,query:e.query};return t.operationName||(t.operationName="string"!=typeof t.query?(0,r.n4)(t.query)||void 0:""),t}},46192(e,t,a){a.d(t,{K:()=>i});var r=a(70916);function i(e){for(var t=["query","operationName","variables","extensions","context"],a=0,i=Object.keys(e);a<i.length;a++){var n=i[a];if(0>t.indexOf(n))throw(0,r.newInvariantError)(46,n)}return e}},39283(e,t,a){a.r(t),a.d(t,{disableWarningsSlot:()=>r.yV,maskFragment:()=>i.z,maskOperation:()=>n.m});var r=a(47150),i=a(62959),n=a(28354)},25186(e,t,a){a.d(t,{S:()=>d});var r=a(42455),i=a(57236),n=a(28907),p=a(82307),o=a(47150),s=a(70916);function d(e,t,a){return o.yV.withValue(!0,function(){var d=function e(t,a,i,d,l){var u,c=i.knownChanged,m=function(e,t){if(t.has(e))return t.get(e);var a=Array.isArray(e)?[]:Object.create(null);return t.set(e,a),a}(t,i.mutableTargets);if(Array.isArray(t)){for(var f=0,h=Array.from(t.entries());f<h.length;f++){var v=h[f],y=v[0],g=v[1];if(null===g){m[y]=null;continue}var _=e(g,a,i,d,!1!==globalThis.__DEV__?"".concat(l||"","[").concat(y,"]"):void 0);c.has(_)&&c.add(m),m[y]=_}return c.has(m)?m:t}for(var b=0,w=a.selections;b<w.length;b++){var E=w[b],T=void 0;if(d&&c.add(m),E.kind===r.b.FIELD){var N=(0,n.ue)(E),S=E.selectionSet;if(void 0===(T=m[N]||t[N]))continue;if(S&&null!==T){var _=e(t[N],S,i,d,!1!==globalThis.__DEV__?"".concat(l||"",".").concat(N):void 0);c.has(_)&&(T=_)}!1===globalThis.__DEV__&&(m[N]=T),!1!==globalThis.__DEV__&&(!d||"__typename"===N||(null==(u=Object.getOwnPropertyDescriptor(m,N))?void 0:u.value)?(delete m[N],m[N]=T):Object.defineProperty(m,N,function(e,t,a,r,i){var n=function(){return o.yV.getValue()||(!1!==globalThis.__DEV__&&s.invariant.warn(48,r?"".concat(i," '").concat(r,"'"):"anonymous ".concat(i),"".concat(a,".").concat(e).replace(/^\./,"")),n=function(){return t}),t};return{get:function(){return n()},set:function(e){n=function(){return e}},enumerable:!0,configurable:!0}}(N,T,l||"",i.operationName,i.operationType)))}if(E.kind===r.b.INLINE_FRAGMENT&&(!E.typeCondition||i.cache.fragmentMatches(E,t.__typename))&&(T=e(t,E.selectionSet,i,d,l)),E.kind===r.b.FRAGMENT_SPREAD){var O=E.name.value,I=i.fragmentMap[O]||(i.fragmentMap[O]=i.cache.lookupFragment(O));(0,s.invariant)(I,47,O);var D=(0,p.s7)(E);"mask"!==D&&(T=e(t,I.selectionSet,i,"migrate"===D,l))}c.has(T)&&c.add(m)}return"__typename"in t&&!("__typename"in m)&&(m.__typename=t.__typename),Object.keys(m).length!==Object.keys(t).length&&c.add(m),c.has(m)?m:t}(e,t,a,!1);return Object.isFrozen(e)&&(0,i.G)(d),d})}},62959(e,t,a){a.d(t,{z:()=>l});var r=a(42455),i=a(47150),n=a(70916),p=a(55888),o=a(25186),s=a(2904),d=a(3777);function l(e,t,a,l){if(!a.fragmentMatches)return!1!==globalThis.__DEV__&&(0,i.Ki)(),e;var u=t.definitions.filter(function(e){return e.kind===r.b.FRAGMENT_DEFINITION});void 0===l&&((0,n.invariant)(1===u.length,49,u.length),l=u[0].name.value);var c=u.find(function(e){return e.name.value===l});return((0,n.invariant)(!!c,50,l),null==e||(0,p.default)(e,{}))?e:(0,o.S)(e,c.selectionSet,{operationType:"fragment",operationName:c.name.value,fragmentMap:(0,s.JG)((0,d.zK)(t)),cache:a,mutableTargets:new i.jq,knownChanged:new i.xm})}},28354(e,t,a){a.d(t,{m:()=>s});var r=a(70916),i=a(3777),n=a(2904),p=a(25186),o=a(47150);function s(e,t,a){if(!a.fragmentMatches)return!1!==globalThis.__DEV__&&(0,o.Ki)(),e;var s,d=(0,i.Vu)(t);return((0,r.invariant)(d,51),null==e)?e:(0,p.S)(e,d.selectionSet,{operationType:d.operation,operationName:null==(s=d.name)?void 0:s.value,fragmentMap:(0,n.JG)((0,i.zK)(t)),cache:a,mutableTargets:new o.jq,knownChanged:new o.xm})}},47150(e,t,a){a.d(t,{Ki:()=>l,jq:()=>p,xm:()=>o,yV:()=>s});var r=a(60837),i=a(70916),n=a(51360),p=n.et?WeakMap:Map,o=n.En?WeakSet:Set,s=new r.Slot,d=!1;function l(){d||(d=!0,!1!==globalThis.__DEV__&&i.invariant.warn(52))}},45078(e,t,a){a.d(t,{A:()=>o,V:()=>s});var r=a(54019),i=a(31088),n=new WeakSet;function p(e){!(e.size<=(e.max||-1))&&(n.has(e)||(n.add(e),setTimeout(function(){e.clean(),n.delete(e)},100)))}var o=function(e,t){var a=new r.l(e,t);return a.set=function(e,t){var a=r.l.prototype.set.call(this,e,t);return p(this),a},a},s=function(e,t){var a=new i.C(e,t);return a.set=function(e,t){var a=i.C.prototype.set.call(this,e,t);return p(this),a},a}},44114(e,t,a){a.d(t,{D_:()=>p,cM:()=>s,ep:()=>o,tQ:()=>d});var r=a(85608),i=a(555),n={};function p(e,t){n[e]=t}var o=!1!==globalThis.__DEV__?function(){var e,t,a,p,o;if(!1===globalThis.__DEV__)throw Error("only supported in development mode");return{limits:Object.fromEntries(Object.entries({parser:1e3,canonicalStringify:1e3,print:2e3,"documentTransform.cache":2e3,"queryManager.getDocumentInfo":2e3,"PersistedQueryLink.persistedQueryHashes":2e3,"fragmentRegistry.transform":2e3,"fragmentRegistry.lookup":1e3,"fragmentRegistry.findFragmentSpreads":4e3,"cache.fragmentQueryDocuments":1e3,"removeTypenameFromVariables.getVariableDefinitions":2e3,"inMemoryCache.maybeBroadcastWatch":5e3,"inMemoryCache.executeSelectionSet":5e4,"inMemoryCache.executeSubSelectedArray":1e4}).map(function(e){var t=e[0],a=e[1];return[t,i.v[t]||a]})),sizes:(0,r.__assign)({print:null==(e=n.print)?void 0:e.call(n),parser:null==(t=n.parser)?void 0:t.call(n),canonicalStringify:null==(a=n.canonicalStringify)?void 0:a.call(n),links:function e(t){var a;return t?(0,r.__spreadArray)((0,r.__spreadArray)([null==(a=null==t?void 0:t.getMemoryInternals)?void 0:a.call(t)],e(null==t?void 0:t.left),!0),e(null==t?void 0:t.right),!0).filter(c):[]}(this.link),queryManager:{getDocumentInfo:this.queryManager.transformCache.size,documentTransforms:m(this.queryManager.documentTransform)}},null==(o=(p=this.cache).getMemoryInternals)?void 0:o.call(p))}}:void 0,s=!1!==globalThis.__DEV__?function(){var e=this.config.fragments;return(0,r.__assign)((0,r.__assign)({},l.apply(this)),{addTypenameDocumentTransform:m(this.addTypenameTransform),inMemoryCache:{executeSelectionSet:u(this.storeReader.executeSelectionSet),executeSubSelectedArray:u(this.storeReader.executeSubSelectedArray),maybeBroadcastWatch:u(this.maybeBroadcastWatch)},fragmentRegistry:{findFragmentSpreads:u(null==e?void 0:e.findFragmentSpreads),lookup:u(null==e?void 0:e.lookup),transform:u(null==e?void 0:e.transform)}})}:void 0,d=!1!==globalThis.__DEV__?l:void 0;function l(){return{cache:{fragmentQueryDocuments:u(this.getFragmentDoc)}}}function u(e){return e&&"dirtyKey"in e?e.size:void 0}function c(e){return null!=e}function m(e){return(function e(t){return t?(0,r.__spreadArray)((0,r.__spreadArray)([u(null==t?void 0:t.performWork)],e(null==t?void 0:t.left),!0),e(null==t?void 0:t.right),!0).filter(c):[]})(e).map(function(e){return{cache:e}})}},555(e,t,a){a.d(t,{v:()=>p});var r=a(85608),i=a(70916),n=Symbol.for("apollo.cacheSize"),p=(0,r.__assign)({},i.global[n])},73767(e,t,a){a.d(t,{E:()=>i,c:()=>r});var r=Array.isArray;function i(e){return Array.isArray(e)&&e.length>0}},51360(e,t,a){a.d(t,{En:()=>p,JR:()=>u,Sw:()=>d,et:()=>n,ol:()=>o,uJ:()=>s});var r=a(70916),i="ReactNative"==(0,r.maybe)(function(){return navigator.product}),n="function"==typeof WeakMap&&!(i&&!global.HermesInternal),p="function"==typeof WeakSet,o="function"==typeof Symbol&&"function"==typeof Symbol.for,s=o&&Symbol.asyncIterator,d="function"==typeof(0,r.maybe)(function(){return window.document.createElement}),l=(0,r.maybe)(function(){return navigator.userAgent.indexOf("jsdom")>=0})||!1,u=(d||i)&&!l},44214(e,t,a){a.d(t,{M:()=>o});var r,i=a(45078),n=a(555),p=a(44114),o=Object.assign(function(e){return JSON.stringify(e,s)},{reset:function(){r=new i.V(n.v.canonicalStringify||1e3)}});function s(e,t){if(t&&"object"==typeof t){var a=Object.getPrototypeOf(t);if(a===Object.prototype||null===a){var i=Object.keys(t);if(i.every(d))return t;var n=JSON.stringify(i),p=r.get(n);if(!p){i.sort();var o=JSON.stringify(i);p=r.get(o)||i,r.set(n,p),r.set(o,p)}var s=Object.create(a);return p.forEach(function(e){s[e]=t[e]}),s}}return t}function d(e,t,a){return 0===t||a[t-1]<=e}!1!==globalThis.__DEV__&&(0,p.D_)("canonicalStringify",function(){return r.size}),o.reset()},20906(e,t,a){a.d(t,{m:()=>i});var r=Object.prototype.toString;function i(e){return function e(t,a){switch(r.call(t)){case"[object Array]":if((a=a||new Map).has(t))return a.get(t);var i=t.slice(0);return a.set(t,i),i.forEach(function(t,r){i[r]=e(t,a)}),i;case"[object Object]":if((a=a||new Map).has(t))return a.get(t);var n=Object.create(Object.getPrototypeOf(t));return a.set(t,n),Object.keys(t).forEach(function(r){n[r]=e(t[r],a)}),n;default:return t}}(e)}},50492(e,t,a){a.d(t,{o:()=>r});function r(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var a=Object.create(null);return e.forEach(function(e){e&&Object.keys(e).forEach(function(t){var r=e[t];void 0!==r&&(a[t]=r)})}),a}},32710(e,t,a){a.d(t,{M:()=>p,t:()=>n});var r=a(73767),i=a(37396);function n(e){var t=p(e);return(0,r.E)(t)}function p(e){var t=(0,r.E)(e.errors)?e.errors.slice(0):[];return(0,i.ST)(e)&&(0,r.E)(e.incremental)&&e.incremental.forEach(function(e){e.errors&&t.push.apply(t,e.errors)}),t}},37396(e,t,a){a.d(t,{EQ:()=>o,Nw:()=>d,ST:()=>p,YX:()=>s,bd:()=>l});var r=a(21777),i=a(73767),n=a(30671);function p(e){return"incremental"in e}function o(e){return"hasNext"in e&&"data"in e}function s(e){return p(e)||o(e)}function d(e){return(0,r.U)(e)&&"payload"in e}function l(e,t){var a=e,r=new n.ZI;return p(t)&&(0,i.E)(t.incremental)&&t.incremental.forEach(function(e){for(var t=e.data,i=e.path,n=i.length-1;n>=0;--n){var p=i[n],o=isNaN(+p)?{}:[];o[p]=t,t=o}a=r.merge(a,t)}),a}},21461(e,t,a){a.d(t,{v:()=>i});var r=new Map;function i(e){var t=r.get(e)||1;return r.set(e,t+1),"".concat(e,":").concat(t,":").concat(Math.random().toString(36).slice(2))}},57236(e,t,a){a.d(t,{G:()=>i});var r=a(21777);function i(e){var t;return!1!==globalThis.__DEV__&&(t=new Set([e])).forEach(function(e){(0,r.U)(e)&&function(e){if(!1!==globalThis.__DEV__&&!Object.isFrozen(e))try{Object.freeze(e)}catch(e){if(e instanceof TypeError)return null;throw e}return e}(e)===e&&Object.getOwnPropertyNames(e).forEach(function(a){(0,r.U)(e[a])&&t.add(e[a])})}),e}},30671(e,t,a){a.d(t,{D9:()=>p,IM:()=>o,ZI:()=>d});var r=a(85608),i=a(21777),n=Object.prototype.hasOwnProperty;function p(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return o(e)}function o(e){var t=e[0]||{},a=e.length;if(a>1)for(var r=new d,i=1;i<a;++i)t=r.merge(t,e[i]);return t}var s=function(e,t,a){return this.merge(e[a],t[a])},d=function(){function e(e){void 0===e&&(e=s),this.reconciler=e,this.isObject=i.U,this.pastCopies=new Set}return e.prototype.merge=function(e,t){for(var a=this,p=[],o=2;o<arguments.length;o++)p[o-2]=arguments[o];return(0,i.U)(t)&&(0,i.U)(e)?(Object.keys(t).forEach(function(i){if(n.call(e,i)){var o=e[i];if(t[i]!==o){var s=a.reconciler.apply(a,(0,r.__spreadArray)([e,t,i],p,!1));s!==o&&((e=a.shallowCopyForMerge(e))[i]=s)}}else(e=a.shallowCopyForMerge(e))[i]=t[i]}),e):t},e.prototype.shallowCopyForMerge=function(e){return(0,i.U)(e)&&!this.pastCopies.has(e)&&(e=Array.isArray(e)?e.slice(0):(0,r.__assign)({__proto__:Object.getPrototypeOf(e)},e),this.pastCopies.add(e)),e},e}()},31507(e,t,a){a.d(t,{l:()=>n});var r=a(85608),i=a(50492);function n(e,t){return(0,i.o)(e,t,t.variables&&{variables:(0,i.o)((0,r.__assign)((0,r.__assign)({},e&&e.variables),t.variables))})}},21777(e,t,a){function r(e){return null!==e&&"object"==typeof e}function i(e){return null!==e&&"object"==typeof e&&(Object.getPrototypeOf(e)===Object.prototype||null===Object.getPrototypeOf(e))}a.d(t,{Q:()=>i,U:()=>r})},86563(e,t,a){a.d(t,{p:()=>i});var r=a(21461);function i(e,t){void 0===t&&(t=0);var a=(0,r.v)("stringifyForDisplay");return JSON.stringify(e,function(e,t){return void 0===t?a:t},t).split(JSON.stringify(a)).join("<undefined>")}},70916(e,t,a){a.r(t),a.d(t,{invariant:()=>d,__DEV__:()=>h,DEV:()=>h,global:()=>p,InvariantError:()=>r.InvariantError,newInvariantError:()=>l,maybe:()=>n});var r=a(19371),i=a(73972);function n(e){try{return e()}catch(e){}}let p=n(function(){return globalThis})||n(function(){return window})||n(function(){return self})||n(function(){return global})||n(function(){return n.constructor("return this")()});var o=a(86563);function s(e){return function(t){for(var a=[],r=1;r<arguments.length;r++)a[r-1]=arguments[r];if("number"==typeof t){var i=t;(t=m(i))||(t=f(i,a),a=[])}e.apply(void 0,[t].concat(a))}}var d=Object.assign(function(e,t){for(var a=[],i=2;i<arguments.length;i++)a[i-2]=arguments[i];e||(0,r.invariant)(e,m(t,a)||f(t,a))},{debug:s(r.invariant.debug),log:s(r.invariant.log),warn:s(r.invariant.warn),error:s(r.invariant.error)});function l(e){for(var t=[],a=1;a<arguments.length;a++)t[a-1]=arguments[a];return new r.InvariantError(m(e,t)||f(e,t))}var u=Symbol.for("ApolloErrorMessageHandler_"+i.r);function c(e){if("string"==typeof e)return e;try{return(0,o.p)(e,2).slice(0,1e3)}catch(e){return"<non-serializable>"}}function m(e,t){if(void 0===t&&(t=[]),e)return p[u]&&p[u](e,t.map(c))}function f(e,t){if(void 0===t&&(t=[]),e)return"An error occurred! For more details, see the full error text at https://go.apollo.dev/c/err#".concat(encodeURIComponent(JSON.stringify({version:i.r,message:e,args:t.map(c)})))}var h=!1!==globalThis.__DEV__},9354(e,t,a){a.d(t,{c:()=>u});var r=a(44592),i=a(51360),n=a(3777),p=a(70916),o=a(54019),s=a(60837),d=a(555);function l(e){return e}var u=function(){function e(e,t){void 0===t&&(t=Object.create(null)),this.resultCache=i.En?new WeakSet:new Set,this.transform=e,t.getCacheKey&&(this.getCacheKey=t.getCacheKey),this.cached=!1!==t.cache,this.resetCache()}return e.prototype.getCacheKey=function(e){return[e]},e.identity=function(){return new e(l,{cache:!1})},e.split=function(t,a,r){return void 0===r&&(r=e.identity()),Object.assign(new e(function(e){return(t(e)?a:r).transformDocument(e)},{cache:!1}),{left:a,right:r})},e.prototype.resetCache=function(){var t=this;if(this.cached){var a=new r.Trie(i.et);this.performWork=(0,s.wrap)(e.prototype.performWork.bind(this),{makeCacheKey:function(e){var r=t.getCacheKey(e);if(r)return(0,p.invariant)(Array.isArray(r),77),a.lookupArray(r)},max:d.v["documentTransform.cache"],cache:o.l})}},e.prototype.performWork=function(e){return(0,n.sw)(e),this.transform(e)},e.prototype.transformDocument=function(e){if(this.resultCache.has(e))return e;var t=this.performWork(e);return this.resultCache.add(t),t},e.prototype.concat=function(t){var a=this;return Object.assign(new e(function(e){return t.transformDocument(a.transformDocument(e))},{cache:!1}),{left:this,right:t})},e}()},82307(e,t,a){a.d(t,{I5:()=>d,MS:()=>p,d8:()=>l,f2:()=>u,hE:()=>s,s7:()=>m,sx:()=>o,tY:()=>c});var r=a(70916),i=a(90424),n=a(42455);function p(e,t){var a=e.directives;return!a||!a.length||c(a).every(function(e){var a=e.directive,i=e.ifArgument,n=!1;return"Variable"===i.value.kind?(n=t&&t[i.value.name.value],(0,r.invariant)(void 0!==n,78,a.name.value)):n=i.value.value,"skip"===a.name.value?!n:n})}function o(e){var t=[];return(0,i.YR)(e,{Directive:function(e){t.push(e.name.value)}}),t}var s=function(e,t){return l(e,t,!1)},d=function(e,t){return l(e,t,!0)};function l(e,t,a){var r=new Set(e),n=r.size;return(0,i.YR)(t,{Directive:function(e){if(r.delete(e.name.value)&&(!a||!r.size))return i.sP}}),a?!r.size:r.size<n}function u(e){return e&&l(["client","export"],e,!0)}function c(e){var t=[];return e&&e.length&&e.forEach(function(e){if("skip"===(a=e.name.value)||"include"===a){var a,i=e.arguments,n=e.name.value;(0,r.invariant)(i&&1===i.length,79,n);var p=i[0];(0,r.invariant)(p.name&&"if"===p.name.value,80,n);var o=p.value;(0,r.invariant)(o&&("Variable"===o.kind||"BooleanValue"===o.kind),81,n),t.push({directive:e,ifArgument:p})}}),t}function m(e){var t,a,i=null==(t=e.directives)?void 0:t.find(function(e){return"unmask"===e.name.value});if(!i)return"mask";var p=null==(a=i.arguments)?void 0:a.find(function(e){return"mode"===e.name.value});return(!1!==globalThis.__DEV__&&p&&(p.value.kind===n.b.VARIABLE?!1!==globalThis.__DEV__&&r.invariant.warn(82):p.value.kind!==n.b.STRING?!1!==globalThis.__DEV__&&r.invariant.warn(83):"migrate"!==p.value.value&&!1!==globalThis.__DEV__&&r.invariant.warn(84,p.value.value)),p&&"value"in p.value&&"migrate"===p.value.value)?"migrate":"unmask"}},2904(e,t,a){a.d(t,{HQ:()=>s,JG:()=>o,ct:()=>p,s6:()=>d});var r=a(85608),i=a(70916),n=a(90424);function p(e,t){var a=t,n=[];return e.definitions.forEach(function(e){if("OperationDefinition"===e.kind)throw(0,i.newInvariantError)(85,e.operation,e.name?" named '".concat(e.name.value,"'"):"");"FragmentDefinition"===e.kind&&n.push(e)}),void 0===a&&((0,i.invariant)(1===n.length,86,n.length),a=n[0].name.value),(0,r.__assign)((0,r.__assign)({},e),{definitions:(0,r.__spreadArray)([{kind:"OperationDefinition",operation:"query",selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:a}}]}}],e.definitions,!0)})}function o(e){void 0===e&&(e=[]);var t={};return e.forEach(function(e){t[e.name.value]=e}),t}function s(e,t){switch(e.kind){case"InlineFragment":return e;case"FragmentSpread":var a=e.name.value;if("function"==typeof t)return t(a);var r=t&&t[a];return(0,i.invariant)(r,87,a),r||null;default:return null}}function d(e){var t=!0;return(0,n.YR)(e,{FragmentSpread:function(e){if(!(t=!!e.directives&&e.directives.some(function(e){return"unmask"===e.name.value})))return n.sP}}),t}},3777(e,t,a){a.d(t,{AT:()=>d,E4:()=>l,Vn:()=>u,Vu:()=>p,n4:()=>o,sw:()=>n,wY:()=>c,zK:()=>s});var r=a(70916),i=a(28907);function n(e){(0,r.invariant)(e&&"Document"===e.kind,88);var t=e.definitions.filter(function(e){return"FragmentDefinition"!==e.kind}).map(function(e){if("OperationDefinition"!==e.kind)throw(0,r.newInvariantError)(89,e.kind);return e});return(0,r.invariant)(t.length<=1,90,t.length),e}function p(e){return n(e),e.definitions.filter(function(e){return"OperationDefinition"===e.kind})[0]}function o(e){return e.definitions.filter(function(e){return"OperationDefinition"===e.kind&&!!e.name}).map(function(e){return e.name.value})[0]||null}function s(e){return e.definitions.filter(function(e){return"FragmentDefinition"===e.kind})}function d(e){var t=p(e);return(0,r.invariant)(t&&"query"===t.operation,91),t}function l(e){(0,r.invariant)("Document"===e.kind,92),(0,r.invariant)(e.definitions.length<=1,93);var t=e.definitions[0];return(0,r.invariant)("FragmentDefinition"===t.kind,94),t}function u(e){n(e);for(var t,a=0,i=e.definitions;a<i.length;a++){var p=i[a];if("OperationDefinition"===p.kind){var o=p.operation;if("query"===o||"mutation"===o||"subscription"===o)return p}"FragmentDefinition"!==p.kind||t||(t=p)}if(t)return t;throw(0,r.newInvariantError)(95)}function c(e){var t=Object.create(null),a=e&&e.variableDefinitions;return a&&a.length&&a.forEach(function(e){e.defaultValue&&(0,i.J)(t,e.variable.name,e.defaultValue)}),t}},38678(e,t,a){a.d(t,{y:()=>s});var r,i=a(95818),n=a(45078),p=a(555),o=a(44114),s=Object.assign(function(e){var t=r.get(e);return t||(t=(0,i.y)(e),r.set(e,t)),t},{reset:function(){r=new n.A(p.v.print||2e3)}});s.reset(),!1!==globalThis.__DEV__&&(0,o.D_)("print",function(){return r?r.size:0})},28907(e,t,a){a.d(t,{A_:()=>s,D$:()=>function e(t,a,r){for(var i,p=0,o=a.selections;p<o.length;p++){var s=o[p];if(y(s)){if("__typename"===s.name.value)return t[v(s)]}else i?i.push(s):i=[s]}if("string"==typeof t.__typename)return t.__typename;if(i)for(var d=0,l=i;d<l.length;d++){var s=l[d],u=e(t,(0,n.HQ)(s,r).selectionSet,r);if("string"==typeof u)return u}},Ii:()=>u,J:()=>l,Kc:()=>d,MB:()=>h,WU:()=>o,dt:()=>y,kd:()=>g,o5:()=>f,ue:()=>v});var r=a(70916),i=a(21777),n=a(2904),p=a(44214);function o(e){return{__ref:String(e)}}function s(e){return!!(e&&"object"==typeof e&&"string"==typeof e.__ref)}function d(e){return(0,i.U)(e)&&"Document"===e.kind&&Array.isArray(e.definitions)}function l(e,t,a,i){if("IntValue"===a.kind||"FloatValue"===a.kind)e[t.value]=Number(a.value);else if("BooleanValue"===a.kind||"StringValue"===a.kind)e[t.value]=a.value;else if("ObjectValue"===a.kind){var n={};a.fields.map(function(e){return l(n,e.name,e.value,i)}),e[t.value]=n}else if("Variable"===a.kind){var p=(i||{})[a.name.value];e[t.value]=p}else if("ListValue"===a.kind)e[t.value]=a.values.map(function(e){var a={};return l(a,t,e,i),a[t.value]});else if("EnumValue"===a.kind)e[t.value]=a.value;else if("NullValue"===a.kind)e[t.value]=null;else throw(0,r.newInvariantError)(96,t.value,a.kind)}function u(e,t){var a=null;e.directives&&(a={},e.directives.forEach(function(e){a[e.name.value]={},e.arguments&&e.arguments.forEach(function(r){var i=r.name,n=r.value;return l(a[e.name.value],i,n,t)})}));var r=null;return e.arguments&&e.arguments.length&&(r={},e.arguments.forEach(function(e){var a=e.name,i=e.value;return l(r,a,i,t)})),f(e.name.value,r,a)}var c=["connection","include","skip","client","rest","export","nonreactive"],m=p.M,f=Object.assign(function(e,t,a){if(t&&a&&a.connection&&a.connection.key)if(!a.connection.filter||!(a.connection.filter.length>0))return a.connection.key;else{var r=a.connection.filter?a.connection.filter:[];r.sort();var i={};return r.forEach(function(e){i[e]=t[e]}),"".concat(a.connection.key,"(").concat(m(i),")")}var n=e;if(t){var p=m(t);n+="(".concat(p,")")}return a&&Object.keys(a).forEach(function(e){-1===c.indexOf(e)&&(a[e]&&Object.keys(a[e]).length?n+="@".concat(e,"(").concat(m(a[e]),")"):n+="@".concat(e))}),n},{setStringify:function(e){var t=m;return m=e,t}});function h(e,t){if(e.arguments&&e.arguments.length){var a={};return e.arguments.forEach(function(e){return l(a,e.name,e.value,t)}),a}return null}function v(e){return e.alias?e.alias.value:e.name.value}function y(e){return"Field"===e.kind}function g(e){return"InlineFragment"===e.kind}},53925(e,t,a){a.d(t,{TC:()=>_,XY:()=>h,er:()=>w,hX:()=>y,it:()=>g,iz:()=>f,x3:()=>E,zc:()=>b});var r=a(85608),i=a(70916),n=a(42455),p=a(90424),o=a(3777),s=a(28907),d=a(2904),l=a(73767),u={kind:n.b.FIELD,name:{kind:n.b.NAME,value:"__typename"}};function c(e){return!function e(t,a){return!t||t.selectionSet.selections.every(function(t){return t.kind===n.b.FRAGMENT_SPREAD&&e(a[t.name.value],a)})}((0,o.Vu)(e)||(0,o.E4)(e),(0,d.JG)((0,o.zK)(e)))?e:null}function m(e){var t=new Map;return function(a){void 0===a&&(a=e);var r=t.get(a);return r||t.set(a,r={variables:new Set,fragmentSpreads:new Set}),r}}function f(e,t){(0,o.sw)(t);for(var a,s,d=m(""),u=m(""),f=function(e){for(var t=0,a=void 0;t<e.length&&(a=e[t]);++t)if(!(0,l.c)(a)){if(a.kind===n.b.OPERATION_DEFINITION)return d(a.name&&a.name.value);if(a.kind===n.b.FRAGMENT_DEFINITION)return u(a.name.value)}return!1!==globalThis.__DEV__&&i.invariant.error(97),null},h=0,v=t.definitions.length-1;v>=0;--v)t.definitions[v].kind===n.b.OPERATION_DEFINITION&&++h;var y=(a=new Map,s=new Map,e.forEach(function(e){e&&(e.name?a.set(e.name,e):e.test&&s.set(e.test,e))}),function(e){var t=a.get(e.name.value);return!t&&s.size&&s.forEach(function(a,r){r(e)&&(t=a)}),t}),g=function(e){return(0,l.E)(e)&&e.map(y).some(function(e){return e&&e.remove})},_=new Map,b=!1,w={enter:function(e){if(g(e.directives))return b=!0,null}},E=(0,p.YR)(t,{Field:w,InlineFragment:w,VariableDefinition:{enter:function(){return!1}},Variable:{enter:function(e,t,a,r,i){var n=f(i);n&&n.variables.add(e.name.value)}},FragmentSpread:{enter:function(e,t,a,r,i){if(g(e.directives))return b=!0,null;var n=f(i);n&&n.fragmentSpreads.add(e.name.value)}},FragmentDefinition:{enter:function(e,t,a,r){_.set(JSON.stringify(r),e)},leave:function(e,t,a,r){return e===_.get(JSON.stringify(r))?e:h>0&&e.selectionSet.selections.every(function(e){return e.kind===n.b.FIELD&&"__typename"===e.name.value})?(u(e.name.value).removed=!0,b=!0,null):void 0}},Directive:{leave:function(e){if(y(e))return b=!0,null}}});if(!b)return t;var T=function(e){return!e.transitiveVars&&(e.transitiveVars=new Set(e.variables),e.removed||e.fragmentSpreads.forEach(function(t){T(u(t)).transitiveVars.forEach(function(t){e.transitiveVars.add(t)})})),e},N=new Set;E.definitions.forEach(function(e){e.kind===n.b.OPERATION_DEFINITION?T(d(e.name&&e.name.value)).fragmentSpreads.forEach(function(e){N.add(e)}):e.kind!==n.b.FRAGMENT_DEFINITION||0!==h||u(e.name.value).removed||N.add(e.name.value)}),N.forEach(function(e){T(u(e)).fragmentSpreads.forEach(function(e){N.add(e)})});var S={enter:function(e){var t;if(t=e.name.value,!N.has(t)||u(t).removed)return null}};return c((0,p.YR)(E,{FragmentSpread:S,FragmentDefinition:S,OperationDefinition:{leave:function(e){if(e.variableDefinitions){var t=T(d(e.name&&e.name.value)).transitiveVars;if(t.size<e.variableDefinitions.length)return(0,r.__assign)((0,r.__assign)({},e),{variableDefinitions:e.variableDefinitions.filter(function(e){return t.has(e.variable.name.value)})})}}}}))}var h=Object.assign(function(e){return(0,p.YR)(e,{SelectionSet:{enter:function(e,t,a){if(!a||a.kind!==n.b.OPERATION_DEFINITION){var i=e.selections;if(!(!i||i.some(function(e){return(0,s.dt)(e)&&("__typename"===e.name.value||0===e.name.value.lastIndexOf("__",0))}))&&!((0,s.dt)(a)&&a.directives&&a.directives.some(function(e){return"export"===e.name.value})))return(0,r.__assign)((0,r.__assign)({},e),{selections:(0,r.__spreadArray)((0,r.__spreadArray)([],i,!0),[u],!1)})}}}})},{added:function(e){return e===u}}),v={test:function(e){var t="connection"===e.name.value;return!t||e.arguments&&e.arguments.some(function(e){return"key"===e.name.value})||!1===globalThis.__DEV__||i.invariant.warn(98),t}};function y(e){return f([v],(0,o.sw)(e))}function g(e,t){var a=function(t){return e.some(function(e){return t.value&&t.value.kind===n.b.VARIABLE&&t.value.name&&(e.name===t.value.name.value||e.test&&e.test(t))})};return c((0,p.YR)(t,{OperationDefinition:{enter:function(t){return(0,r.__assign)((0,r.__assign)({},t),{variableDefinitions:t.variableDefinitions?t.variableDefinitions.filter(function(t){return!e.some(function(e){return e.name===t.variable.name.value})}):[]})}},Field:{enter:function(t){if(e.some(function(e){return e.remove})){var r=0;if(t.arguments&&t.arguments.forEach(function(e){a(e)&&(r+=1)}),1===r)return null}}},Argument:{enter:function(e){if(a(e))return null}}}))}function _(e,t){function a(t){if(e.some(function(e){return e.name===t.name.value}))return null}return c((0,p.YR)(t,{FragmentSpread:{enter:a},FragmentDefinition:{enter:a}}))}function b(e){return"query"===(0,o.Vn)(e).operation?e:(0,p.YR)(e,{OperationDefinition:{enter:function(e){return(0,r.__assign)((0,r.__assign)({},e),{operation:"query"})}}})}function w(e){return(0,o.sw)(e),f([{test:function(e){return"client"===e.name.value},remove:!0}],e)}function E(e){return(0,o.sw)(e),(0,p.YR)(e,{FragmentSpread:function(e){var t;if(null==(t=e.directives)||!t.some(function(e){return"unmask"===e.name.value}))return(0,r.__assign)((0,r.__assign)({},e),{directives:(0,r.__spreadArray)((0,r.__spreadArray)([],e.directives||[],!0),[{kind:n.b.DIRECTIVE,name:{kind:n.b.NAME,value:"nonreactive"}}],!1)})}})}},5437(e,t,a){a.r(t),a.d(t,{DEV:()=>r.DEV,concatPagination:()=>y,getInclusionDirectives:()=>i.tY,makeReference:()=>d.WU,shouldInclude:()=>i.MS,createFragmentMap:()=>p.JG,AutoCleanedStrongCache:()=>z.V,hasAllDirectives:()=>i.I5,AutoCleanedWeakCache:()=>z.A,canUseWeakMap:()=>P.et,getFragmentFromSelection:()=>p.HQ,storeKeyNameFromField:()=>d.Ii,getOperationDefinition:()=>o.Vu,isArray:()=>V.c,checkDocument:()=>o.sw,getFragmentMaskMode:()=>i.s7,maybe:()=>r.maybe,valueToObjectRepresentation:()=>d.J,mergeDeepArray:()=>v.IM,getDirectiveNames:()=>i.sx,isExecutionPatchInitialResult:()=>B.EQ,graphQLResultHasError:()=>$.t,resultKeyNameFromField:()=>d.ue,hasDirectives:()=>i.d8,isPlainObject:()=>F.Q,isNonNullObject:()=>F.U,mergeOptions:()=>U.l,canUseAsyncIteratorSymbol:()=>P.uJ,isReference:()=>d.A_,DeepMerger:()=>v.ZI,maybeDeepFreeze:()=>A.G,getFragmentDefinition:()=>o.E4,getTypenameFromResult:()=>d.D$,iterateObserversSafely:()=>k.w,getOperationName:()=>o.n4,removeDirectivesFromDocument:()=>l.iz,isStatefulPromise:()=>S,isInlineFragment:()=>d.kd,canUseWeakSet:()=>P.En,mergeDeep:()=>v.D9,omitDeep:()=>Q,isQueryOperation:()=>m,print:()=>s.y,createRejectedPromise:()=>N,getStoreKeyName:()=>d.o5,removeFragmentSpreadFromDocument:()=>l.TC,removeArgumentsFromDocument:()=>l.it,fixObservableSubclass:()=>R.r,createFulfilledPromise:()=>T,canUseSymbol:()=>P.ol,getFragmentQueryDocument:()=>p.ct,removeConnectionDirectiveFromDocument:()=>l.hX,stringifyForDisplay:()=>M.p,wrapPromiseWithState:()=>O,relayStylePagination:()=>_,isNonEmptyArray:()=>V.E,getFragmentDefinitions:()=>o.zK,isExecutionPatchIncrementalResult:()=>B.ST,buildQueryFromSelectionSet:()=>l.zc,preventUnhandledRejection:()=>I.X,stripTypename:()=>G,canUseDOM:()=>P.Sw,canUseLayoutEffect:()=>P.JR,isApolloPayloadResult:()=>B.Nw,DocumentTransform:()=>n.c,addTypenameToDocument:()=>l.XY,canonicalStringify:()=>q.M,Concast:()=>C.E,Observable:()=>E.c,argumentsObjectFromField:()=>d.MB,getDefaultValues:()=>o.wY,isField:()=>d.dt,hasClientExports:()=>i.f2,offsetLimitPagination:()=>g,removeClientSetsFromDocument:()=>l.er,isDocumentNode:()=>d.Kc,compact:()=>L.o,getGraphQLErrorsFromResult:()=>$.M,addNonReactiveToNamedFragments:()=>l.x3,getQueryDefinition:()=>o.AT,isExecutionPatchResult:()=>B.YX,asyncMap:()=>x.x,isFullyUnmaskedOperation:()=>p.s6,hasAnyDirectives:()=>i.hE,getMainDefinition:()=>o.Vn,isMutationOperation:()=>c,cloneDeep:()=>D.m,isSubscriptionOperation:()=>f,cacheSizes:()=>H.v,makeUniqueId:()=>j.v,mergeIncrementalData:()=>B.bd});var r=a(70916),i=a(82307),n=a(9354),p=a(2904),o=a(3777),s=a(38678),d=a(28907),l=a(53925);function u(e,t){var a;return(null==(a=(0,o.Vu)(e))?void 0:a.operation)===t}function c(e){return u(e,"mutation")}function m(e){return u(e,"query")}function f(e){return u(e,"subscription")}var h=a(85608),v=a(30671);function y(e){return void 0===e&&(e=!1),{keyArgs:e,merge:function(e,t){return e?(0,h.__spreadArray)((0,h.__spreadArray)([],e,!0),t,!0):t}}}function g(e){return void 0===e&&(e=!1),{keyArgs:e,merge:function(e,t,a){var r=a.args,i=e?e.slice(0):[];if(t)if(r)for(var n=r.offset,p=void 0===n?0:n,o=0;o<t.length;++o)i[p+o]=t[o];else i.push.apply(i,t);return i}}}function _(e){return void 0===e&&(e=!1),{keyArgs:e,read:function(e,t){var a=t.canRead,r=t.readField;if(!e)return e;var i=[],n="",p="";e.edges.forEach(function(e){a(r("node",e))&&(i.push(e),e.cursor&&(n=n||e.cursor||"",p=e.cursor||p))}),i.length>1&&n===p&&(n="");var o=e.pageInfo||{},s=o.startCursor,d=o.endCursor;return(0,h.__assign)((0,h.__assign)({},b(e)),{edges:i,pageInfo:(0,h.__assign)((0,h.__assign)({},e.pageInfo),{startCursor:s||n,endCursor:d||p})})},merge:function(e,t,a){var r=a.args,i=a.isReference,n=a.readField;if(e||(e={edges:[],pageInfo:{hasPreviousPage:!1,hasNextPage:!0,startCursor:"",endCursor:""}}),!t)return e;var p=t.edges?t.edges.map(function(e){return i(e=(0,h.__assign)({},e))&&(e.cursor=n("cursor",e)),e}):[];if(t.pageInfo){var o=t.pageInfo,s=o.startCursor,d=o.endCursor,l=p[0],u=p[p.length-1];l&&s&&(l.cursor=s),u&&d&&(u.cursor=d);var c=l&&l.cursor;c&&!s&&(t=(0,v.D9)(t,{pageInfo:{startCursor:c}}));var m=u&&u.cursor;m&&!d&&(t=(0,v.D9)(t,{pageInfo:{endCursor:m}}))}var f=e.edges,y=[];if(r&&r.after){var g=f.findIndex(function(e){return e.cursor===r.after});g>=0&&(f=f.slice(0,g+1))}else if(r&&r.before){var g=f.findIndex(function(e){return e.cursor===r.before});y=g<0?f:f.slice(g),f=[]}else t.edges&&(f=[]);var _=(0,h.__spreadArray)((0,h.__spreadArray)((0,h.__spreadArray)([],f,!0),p,!0),y,!0),w=(0,h.__assign)((0,h.__assign)({},t.pageInfo),e.pageInfo);if(t.pageInfo){var E=t.pageInfo,T=E.hasPreviousPage,N=E.hasNextPage,s=E.startCursor,d=E.endCursor;Object.assign(w,(0,h.__rest)(E,["hasPreviousPage","hasNextPage","startCursor","endCursor"])),f.length||(void 0!==T&&(w.hasPreviousPage=T),void 0!==s&&(w.startCursor=s)),y.length||(void 0!==N&&(w.hasNextPage=N),void 0!==d&&(w.endCursor=d))}return(0,h.__assign)((0,h.__assign)((0,h.__assign)({},b(e)),b(t)),{edges:_,pageInfo:w})}}}var b=function(e){return(0,h.__rest)(e,w)},w=["edges","pageInfo"],E=a(36054);function T(e){var t=Promise.resolve(e);return t.status="fulfilled",t.value=e,t}function N(e){var t=Promise.reject(e);return t.catch(function(){}),t.status="rejected",t.reason=e,t}function S(e){return"status"in e}function O(e){return S(e)||(e.status="pending",e.then(function(t){"pending"===e.status&&(e.status="fulfilled",e.value=t)},function(t){"pending"===e.status&&(e.status="rejected",e.reason=t)})),e}var I=a(30234),D=a(20906),A=a(57236),k=a(87613),x=a(5762),C=a(45637),R=a(35892),V=a(73767),F=a(21777),$=a(32710),P=a(51360),L=a(50492),j=a(21461),M=a(86563),U=a(31507),B=a(37396),q=a(44214);function Q(e,t){return Y(e,t)}function Y(e,t,a){if(void 0===a&&(a=new Map),a.has(e))return a.get(e);var r=!1;if(Array.isArray(e)){var i=[];if(a.set(e,i),e.forEach(function(e,n){var p=Y(e,t,a);r||(r=p!==e),i[n]=p}),r)return i}else if((0,F.Q)(e)){var n=Object.create(Object.getPrototypeOf(e));if(a.set(e,n),Object.keys(e).forEach(function(i){if(i===t){r=!0;return}var p=Y(e[i],t,a);r||(r=p!==e[i]),n[i]=p}),r)return n}return e}function G(e){return Y(e,"__typename")}var z=a(45078),H=a(555)},45637(e,t,a){a.d(t,{E:()=>s});var r=a(85608),i=a(36054),n=a(87613),p=a(35892);function o(e){return e&&"function"==typeof e.then}var s=function(e){function t(t){var a=e.call(this,function(e){return a.addObserver(e),function(){return a.removeObserver(e)}})||this;return a.observers=new Set,a.promise=new Promise(function(e,t){a.resolve=e,a.reject=t}),a.handlers={next:function(e){null!==a.sub&&(a.latest=["next",e],a.notify("next",e),(0,n.w)(a.observers,"next",e))},error:function(e){var t=a.sub;null!==t&&(t&&setTimeout(function(){return t.unsubscribe()}),a.sub=null,a.latest=["error",e],a.reject(e),a.notify("error",e),(0,n.w)(a.observers,"error",e))},complete:function(){var e=a.sub,t=a.sources;if(null!==e){var r=(void 0===t?[]:t).shift();r?o(r)?r.then(function(e){return a.sub=e.subscribe(a.handlers)},a.handlers.error):a.sub=r.subscribe(a.handlers):(e&&setTimeout(function(){return e.unsubscribe()}),a.sub=null,a.latest&&"next"===a.latest[0]?a.resolve(a.latest[1]):a.resolve(),a.notify("complete"),(0,n.w)(a.observers,"complete"))}}},a.nextResultListeners=new Set,a.cancel=function(e){a.reject(e),a.sources=[],a.handlers.error(e)},a.promise.catch(function(e){}),"function"==typeof t&&(t=[new i.c(t)]),o(t)?t.then(function(e){return a.start(e)},a.handlers.error):a.start(t),a}return(0,r.__extends)(t,e),t.prototype.start=function(e){void 0===this.sub&&(this.sources=Array.from(e),this.handlers.complete())},t.prototype.deliverLastMessage=function(e){if(this.latest){var t=this.latest[0],a=e[t];a&&a.call(e,this.latest[1]),null===this.sub&&"next"===t&&e.complete&&e.complete()}},t.prototype.addObserver=function(e){this.observers.has(e)||(this.deliverLastMessage(e),this.observers.add(e))},t.prototype.removeObserver=function(e){this.observers.delete(e)&&this.observers.size<1&&this.handlers.complete()},t.prototype.notify=function(e,t){var a=this.nextResultListeners;a.size&&(this.nextResultListeners=new Set,a.forEach(function(a){return a(e,t)}))},t.prototype.beforeNext=function(e){var t=!1;this.nextResultListeners.add(function(a,r){t||(t=!0,e(a,r))})},t}(i.c);(0,p.r)(s)},5762(e,t,a){a.d(t,{x:()=>i});var r=a(36054);function i(e,t,a){return new r.c(function(r){var i={then:function(e){return new Promise(function(t){return t(e())})}};function n(e,t){return function(a){if(e){var n=function(){return r.closed?0:e(a)};i=i.then(n,n).then(function(e){return r.next(e)},function(e){return r.error(e)})}else r[t](a)}}var p={next:n(t,"next"),error:n(a,"error"),complete:function(){i.then(function(){return r.complete()})}},o=e.subscribe(p);return function(){return o.unsubscribe()}})}},87613(e,t,a){a.d(t,{w:()=>r});function r(e,t,a){var r=[];e.forEach(function(e){return e[t]&&r.push(e)}),r.forEach(function(e){return e[t](a)})}},35892(e,t,a){a.d(t,{r:()=>n});var r=a(36054),i=a(51360);function n(e){function t(t){Object.defineProperty(e,t,{value:r.c})}return i.ol&&Symbol.species&&t(Symbol.species),t("@@species"),e}},30234(e,t,a){a.d(t,{X:()=>r});function r(e){return e.catch(function(){}),e}},73972(e,t,a){a.d(t,{r:()=>r});var r="3.13.8"},31088(e,t,a){function r(){}a.d(t,{C:()=>i});class i{constructor(e=1/0,t=r){this.max=e,this.dispose=t,this.map=new Map,this.newest=null,this.oldest=null}has(e){return this.map.has(e)}get(e){let t=this.getNode(e);return t&&t.value}get size(){return this.map.size}getNode(e){let t=this.map.get(e);if(t&&t!==this.newest){let{older:e,newer:a}=t;a&&(a.older=e),e&&(e.newer=a),t.older=this.newest,t.older.newer=t,t.newer=null,this.newest=t,t===this.oldest&&(this.oldest=a)}return t}set(e,t){let a=this.getNode(e);return a?a.value=t:(a={key:e,value:t,newer:null,older:this.newest},this.newest&&(this.newest.newer=a),this.newest=a,this.oldest=this.oldest||a,this.map.set(e,a),a.value)}clean(){for(;this.oldest&&this.map.size>this.max;)this.delete(this.oldest.key)}delete(e){let t=this.map.get(e);return!!t&&(t===this.newest&&(this.newest=t.older),t===this.oldest&&(this.oldest=t.newer),t.newer&&(t.newer.older=t.older),t.older&&(t.older.newer=t.newer),this.map.delete(e),this.dispose(t.value,e),!0)}}},54019(e,t,a){function r(){}a.d(t,{l:()=>o});let i="u">typeof WeakRef?WeakRef:function(e){return{deref:()=>e}},n="u">typeof WeakMap?WeakMap:Map,p="u">typeof FinalizationRegistry?FinalizationRegistry:function(){return{register:r,unregister:r}};class o{constructor(e=1/0,t=r){this.max=e,this.dispose=t,this.map=new n,this.newest=null,this.oldest=null,this.unfinalizedNodes=new Set,this.finalizationScheduled=!1,this.size=0,this.finalize=()=>{let e=this.unfinalizedNodes.values();for(let t=0;t<10024;t++){let t=e.next().value;if(!t)break;this.unfinalizedNodes.delete(t);let a=t.key;delete t.key,t.keyRef=new i(a),this.registry.register(a,t,t)}this.unfinalizedNodes.size>0?queueMicrotask(this.finalize):this.finalizationScheduled=!1},this.registry=new p(this.deleteNode.bind(this))}has(e){return this.map.has(e)}get(e){let t=this.getNode(e);return t&&t.value}getNode(e){let t=this.map.get(e);if(t&&t!==this.newest){let{older:e,newer:a}=t;a&&(a.older=e),e&&(e.newer=a),t.older=this.newest,t.older.newer=t,t.newer=null,this.newest=t,t===this.oldest&&(this.oldest=a)}return t}set(e,t){let a=this.getNode(e);return a?a.value=t:(a={key:e,value:t,newer:null,older:this.newest},this.newest&&(this.newest.newer=a),this.newest=a,this.oldest=this.oldest||a,this.scheduleFinalization(a),this.map.set(e,a),this.size++,a.value)}clean(){for(;this.oldest&&this.size>this.max;)this.deleteNode(this.oldest)}deleteNode(e){e===this.newest&&(this.newest=e.older),e===this.oldest&&(this.oldest=e.newer),e.newer&&(e.newer.older=e.older),e.older&&(e.older.newer=e.newer),this.size--;let t=e.key||e.keyRef&&e.keyRef.deref();this.dispose(e.value,t),e.keyRef?this.registry.unregister(e):this.unfinalizedNodes.delete(e),t&&this.map.delete(t)}delete(e){let t=this.map.get(e);return!!t&&(this.deleteNode(t),!0)}scheduleFinalization(e){this.unfinalizedNodes.add(e),this.finalizationScheduled||(this.finalizationScheduled=!0,queueMicrotask(this.finalize))}}},55888(e,t,a){a.r(t),a.d(t,{default:()=>s,equal:()=>o});let{toString:r,hasOwnProperty:i}=Object.prototype,n=Function.prototype.toString,p=new Map;function o(e,t){try{return function e(t,a){if(t===a)return!0;let p=r.call(t);if(p!==r.call(a))return!1;switch(p){case"[object Array]":if(t.length!==a.length)break;case"[object Object]":{if(c(t,a))return!0;let r=d(t),n=d(a),p=r.length;if(p!==n.length)return!1;for(let e=0;e<p;++e)if(!i.call(a,r[e]))return!1;for(let i=0;i<p;++i){let n=r[i];if(!e(t[n],a[n]))return!1}return!0}case"[object Error]":return t.name===a.name&&t.message===a.message;case"[object Number]":if(t!=t)return a!=a;case"[object Boolean]":case"[object Date]":return+t==+a;case"[object RegExp]":case"[object String]":return t==`${a}`;case"[object Map]":case"[object Set]":{if(t.size!==a.size)return!1;if(c(t,a))return!0;let r=t.entries(),i="[object Map]"===p;for(;;){let t=r.next();if(t.done)break;let[n,p]=t.value;if(!a.has(n)||i&&!e(p,a.get(n)))return!1}return!0}case"[object Uint16Array]":case"[object Uint8Array]":case"[object Uint32Array]":case"[object Int32Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object ArrayBuffer]":t=new Uint8Array(t),a=new Uint8Array(a);case"[object DataView]":{let e=t.byteLength;if(e===a.byteLength)for(;e--&&t[e]===a[e];);return -1===e}case"[object AsyncFunction]":case"[object GeneratorFunction]":case"[object AsyncGeneratorFunction]":case"[object Function]":{var o,s;let e,r=n.call(t);if(r!==n.call(a))return!1;return o=r,s=u,!((e=o.length-s.length)>=0)||o.indexOf(s,e)!==e}}return!1}(e,t)}finally{p.clear()}}let s=o;function d(e){return Object.keys(e).filter(l,e)}function l(e){return void 0!==this[e]}let u="{ [native code] }";function c(e,t){let a=p.get(e);if(a){if(a.has(t))return!0}else p.set(e,a=new Set);return a.add(t),!1}},44592(e,t,a){a.r(t),a.d(t,{Trie:()=>o});let r=()=>Object.create(null),{forEach:i,slice:n}=Array.prototype,{hasOwnProperty:p}=Object.prototype;class o{constructor(e=!0,t=r){this.weakness=e,this.makeData=t}lookup(){return this.lookupArray(arguments)}lookupArray(e){let t=this;return i.call(e,e=>t=t.getChildTrie(e)),p.call(t,"data")?t.data:t.data=this.makeData(n.call(e))}peek(){return this.peekArray(arguments)}peekArray(e){let t=this;for(let a=0,r=e.length;t&&a<r;++a){let r=t.mapFor(e[a],!1);t=r&&r.get(e[a])}return t&&t.data}remove(){return this.removeArray(arguments)}removeArray(e){let t;if(e.length){let a=e[0],r=this.mapFor(a,!1),i=r&&r.get(a);i&&(t=i.removeArray(n.call(e,1)),i.data||i.weak||i.strong&&i.strong.size||r.delete(a))}else t=this.data,delete this.data;return t}getChildTrie(e){let t=this.mapFor(e,!0),a=t.get(e);return a||t.set(e,a=new o(this.weakness,this.makeData)),a}mapFor(e,t){return this.weakness&&function(e){switch(typeof e){case"object":if(null===e)break;case"function":return!0}return!1}(e)?this.weak||(t?this.weak=new WeakMap:void 0):this.strong||(t?this.strong=new Map:void 0)}}},74261(e,r,i){let n;i.d(r,{F2:()=>rQ,UU:()=>aF,W0:()=>na,Sz:()=>nt,Pq:()=>er,le:()=>a4,Nm:()=>aA,TM:()=>iT,xB:()=>iC,A8:()=>rU,US:()=>rO,IC:()=>i5,iF:()=>i8,ph:()=>i7,En:()=>rK,R5:()=>rL,B3:()=>ij,n3:()=>iL,V0:()=>rk,Em:()=>iU,BZ:()=>ix,tX:()=>rb,Rp:()=>rx,he:()=>iw,Sk:()=>aM,HM:()=>i$,SC:()=>aV,mp:()=>rC,UY:()=>i0,bo:()=>i4,EC:()=>i9,P9:()=>rj,Zd:()=>i6,QI:()=>rB,lh:()=>ak,Yg:()=>iX,_o:()=>rM,mn:()=>rF,mF:()=>aU,WF:()=>rW,UM:()=>rq,Ix:()=>iP,b2:()=>i1,V5:()=>rZ,el:()=>r$,n_:()=>iQ,z4:()=>ei,TZ:()=>r5,dG:()=>iH});var p,o,s,d,l,u,c,m,f,h,v,y,g,_,b,w,E,T,N,S,O,I,D,A,k,x,C,R,V,F,$,P,L,j,M,U,B,q,Q,Y,G,z,H,W,K,J,Z,X,ee,et,ea,er={};i.r(er),i.d(er,{application:()=>eV,applicationDeviceSettings:()=>eF,applicationProject:()=>eW,applicationReleaseVersions:()=>e$,applications:()=>eP,blueprint:()=>eX,blueprintEvents:()=>e4,blueprintProjection:()=>e2,blueprintRevisions:()=>e6,blueprints:()=>e1,blueprintsByInstance:()=>e0,buttressServers:()=>eJ,checkBindDevicePasscode:()=>eB,device:()=>eD,deviceGroup:()=>ex,deviceGroups:()=>eC,deviceUsage:()=>eH,devices:()=>eA,devicesApplicationStatus:()=>e3,devicesByGroup:()=>eR,devicesPanel:()=>ek,mediaBox:()=>eG,mediaBoxes:()=>eY,mediaFile:()=>ez,mediaFiles:()=>eq,mediaWorkspace:()=>eQ,module:()=>ej,moduleProject:()=>eK,modules:()=>eM,publicApplicationShareInfo:()=>eL,publicModules:()=>eU,registryTrust:()=>eZ,workspace:()=>eI});var ei={};i.r(ei),i.d(ei,{acquireBlueprintRun:()=>tF,bindApplication:()=>td,bindButtressServer:()=>tN,bindButtressServerWithRegistry:()=>tS,controlDevice:()=>e5,copyMediaFiles:()=>t_,createApplication:()=>tr,createApplicationWithShareVersion:()=>ti,createBlueprint:()=>tx,createDevice:()=>e9,createMediaFileUploadRequest:()=>ty,createModule:()=>tu,createVirtualDevice:()=>e8,deleteMediaBoxFiles:()=>tw,deleteMediaFiles:()=>tb,dispatchDeviceGroupAction:()=>ta,heartbeatBlueprintRun:()=>t$,issueButtressAccessToken:()=>tD,issueButtressNodeCredential:()=>tO,issueDevtoolsAccessToken:()=>tA,releaseApplication:()=>tv,releaseBlueprintRun:()=>tP,releaseModule:()=>tT,removeApplication:()=>to,removeBlueprint:()=>tV,removeDevice:()=>tt,removeModule:()=>tm,revertBlueprint:()=>tR,revokeAccessTokens:()=>tk,setMediaFileAsBoxPreview:()=>tE,shortEditApplication:()=>ts,shortEditModule:()=>tf,triggerApplicationCanvasControl:()=>tl,unbindButtressServer:()=>tI,updateApplication:()=>tn,updateBlueprint:()=>tC,updateDevice:()=>te,updateMediaFiles:()=>tg,updateModule:()=>tc,updateVirtualDevice:()=>e7,updateWorkspace:()=>th,useApplicationReleaseVersion:()=>tp});var en=i(99436),ep=i(5018),eo=i(44668),es=i(54506),ed=i(78549),el=i(94370),eu=i(90424),ec=(0,el.default)`
|
|
5
5
|
fragment cliWorkspaceArguments on Workspace {
|
|
6
6
|
_id
|
|
7
7
|
name
|
|
@@ -26,7 +26,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
26
26
|
}
|
|
27
27
|
}
|
|
28
28
|
}
|
|
29
|
-
`,
|
|
29
|
+
`,em=(0,el.default)`
|
|
30
30
|
fragment cliDeviceArguments on Device {
|
|
31
31
|
_id
|
|
32
32
|
name
|
|
@@ -122,7 +122,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
122
122
|
create_datetime
|
|
123
123
|
last_modify_datetime
|
|
124
124
|
}
|
|
125
|
-
`,
|
|
125
|
+
`,ef=(0,el.default)`
|
|
126
126
|
fragment cliDevicePanelArguments on Device {
|
|
127
127
|
_id
|
|
128
128
|
name
|
|
@@ -160,7 +160,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
160
160
|
}
|
|
161
161
|
}
|
|
162
162
|
}
|
|
163
|
-
`,
|
|
163
|
+
`,eh=(0,el.default)`
|
|
164
164
|
fragment cliDeviceShortArguments on Device {
|
|
165
165
|
_id
|
|
166
166
|
name
|
|
@@ -177,7 +177,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
177
177
|
}
|
|
178
178
|
}
|
|
179
179
|
}
|
|
180
|
-
`,
|
|
180
|
+
`,ev=(0,el.default)`
|
|
181
181
|
fragment cliDeviceGroupArguments on DeviceGroup {
|
|
182
182
|
_id
|
|
183
183
|
name
|
|
@@ -190,7 +190,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
190
190
|
create_datetime
|
|
191
191
|
last_modify_datetime
|
|
192
192
|
}
|
|
193
|
-
`,
|
|
193
|
+
`,ey=(0,el.default)`
|
|
194
194
|
fragment cliApplicationArguments on Application {
|
|
195
195
|
_id
|
|
196
196
|
name
|
|
@@ -238,7 +238,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
238
238
|
create_datetime
|
|
239
239
|
last_modify_datetime
|
|
240
240
|
}
|
|
241
|
-
`,
|
|
241
|
+
`,eg=(0,el.default)`
|
|
242
242
|
fragment cliApplicationShortArguments on Application {
|
|
243
243
|
_id
|
|
244
244
|
name
|
|
@@ -246,7 +246,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
246
246
|
has_unreleased_changes
|
|
247
247
|
current_version
|
|
248
248
|
}
|
|
249
|
-
`,
|
|
249
|
+
`,e_=(0,el.default)`
|
|
250
250
|
fragment cliModuleArguments on Module {
|
|
251
251
|
_id
|
|
252
252
|
name
|
|
@@ -269,14 +269,14 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
269
269
|
create_datetime
|
|
270
270
|
last_modify_datetime
|
|
271
271
|
}
|
|
272
|
-
`,
|
|
272
|
+
`,eb=(0,el.default)`
|
|
273
273
|
fragment cliModuleShortArguments on Module {
|
|
274
274
|
_id
|
|
275
275
|
name
|
|
276
276
|
description
|
|
277
277
|
current_version
|
|
278
278
|
}
|
|
279
|
-
`,
|
|
279
|
+
`,ew=(0,el.default)`
|
|
280
280
|
fragment cliBlueprintEdgeArguments on BlueprintEdge {
|
|
281
281
|
id
|
|
282
282
|
from
|
|
@@ -285,7 +285,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
285
285
|
label
|
|
286
286
|
derived
|
|
287
287
|
}
|
|
288
|
-
`,
|
|
288
|
+
`,eE=(0,el.default)`
|
|
289
289
|
fragment cliBlueprintRunArguments on BlueprintRun {
|
|
290
290
|
instance_id
|
|
291
291
|
sessions {
|
|
@@ -299,7 +299,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
299
299
|
started_at
|
|
300
300
|
heartbeat_at
|
|
301
301
|
}
|
|
302
|
-
`,
|
|
302
|
+
`,eT=(0,el.default)`
|
|
303
303
|
fragment cliBlueprintArguments on Blueprint {
|
|
304
304
|
_id
|
|
305
305
|
name
|
|
@@ -336,9 +336,9 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
336
336
|
create_datetime
|
|
337
337
|
last_modify_datetime
|
|
338
338
|
}
|
|
339
|
-
${eb}
|
|
340
339
|
${ew}
|
|
341
|
-
|
|
340
|
+
${eE}
|
|
341
|
+
`,eN=(0,el.default)`
|
|
342
342
|
fragment cliBlueprintShortArguments on Blueprint {
|
|
343
343
|
_id
|
|
344
344
|
name
|
|
@@ -354,8 +354,8 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
354
354
|
}
|
|
355
355
|
last_modify_datetime
|
|
356
356
|
}
|
|
357
|
-
${
|
|
358
|
-
`,
|
|
357
|
+
${eE}
|
|
358
|
+
`,eS=(0,el.default)`
|
|
359
359
|
fragment cliRegistryCredentialArguments on RegistryCredential {
|
|
360
360
|
token
|
|
361
361
|
jti
|
|
@@ -364,56 +364,56 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
364
364
|
expiresAt
|
|
365
365
|
renewAfter
|
|
366
366
|
}
|
|
367
|
-
`,
|
|
367
|
+
`,eO=(0,el.default)`
|
|
368
368
|
fragment cliRegistryTrustArguments on RegistryTrust {
|
|
369
369
|
issuer
|
|
370
370
|
audience
|
|
371
371
|
baseUrl
|
|
372
372
|
jwks
|
|
373
373
|
}
|
|
374
|
-
`,
|
|
374
|
+
`,eI=(0,el.default)`
|
|
375
375
|
query CLI_workspace {
|
|
376
376
|
workspace {
|
|
377
377
|
...cliWorkspaceArguments
|
|
378
378
|
}
|
|
379
379
|
}
|
|
380
|
-
${
|
|
381
|
-
`,
|
|
380
|
+
${ec}
|
|
381
|
+
`,eD=(0,el.default)`
|
|
382
382
|
query CLI_device($id: ID) {
|
|
383
383
|
device(id: $id) {
|
|
384
384
|
...cliDeviceArguments
|
|
385
385
|
}
|
|
386
386
|
}
|
|
387
|
-
${
|
|
388
|
-
`,
|
|
387
|
+
${em}
|
|
388
|
+
`,eA=(0,el.default)`
|
|
389
389
|
query CLI_devices($keyword: String, $paginate: Paginate) {
|
|
390
390
|
devices(keyword: $keyword, paginate: $paginate) {
|
|
391
391
|
...cliDeviceShortArguments
|
|
392
392
|
}
|
|
393
393
|
}
|
|
394
|
-
${
|
|
395
|
-
`,
|
|
394
|
+
${eh}
|
|
395
|
+
`,ek=(0,el.default)`
|
|
396
396
|
query CLI_devicesPanel($keyword: String, $paginate: Paginate) {
|
|
397
397
|
devicesPanel: devices(keyword: $keyword, paginate: $paginate) {
|
|
398
398
|
...cliDevicePanelArguments
|
|
399
399
|
}
|
|
400
400
|
}
|
|
401
|
-
${
|
|
402
|
-
`,
|
|
401
|
+
${ef}
|
|
402
|
+
`,ex=(0,el.default)`
|
|
403
403
|
query CLI_deviceGroup($id: ID) {
|
|
404
404
|
deviceGroup(id: $id) {
|
|
405
405
|
...cliDeviceGroupArguments
|
|
406
406
|
}
|
|
407
407
|
}
|
|
408
|
-
${
|
|
409
|
-
`,
|
|
408
|
+
${ev}
|
|
409
|
+
`,eC=(0,el.default)`
|
|
410
410
|
query CLI_deviceGroups($paginate: Paginate) {
|
|
411
411
|
deviceGroups(paginate: $paginate) {
|
|
412
412
|
...cliDeviceGroupArguments
|
|
413
413
|
}
|
|
414
414
|
}
|
|
415
|
-
${
|
|
416
|
-
`,
|
|
415
|
+
${ev}
|
|
416
|
+
`,eR=(0,el.default)`
|
|
417
417
|
query CLI_devicesByGroup($id: ID) {
|
|
418
418
|
devicesByGroup(id: $id) {
|
|
419
419
|
target_name
|
|
@@ -434,14 +434,14 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
434
434
|
}
|
|
435
435
|
}
|
|
436
436
|
}
|
|
437
|
-
`,
|
|
437
|
+
`,eV=(0,el.default)`
|
|
438
438
|
query CLI_application($id: ID!, $composed: Boolean, $debug: Boolean) {
|
|
439
439
|
application(id: $id, composed: $composed, debug: $debug) {
|
|
440
440
|
...cliApplicationArguments
|
|
441
441
|
}
|
|
442
442
|
}
|
|
443
|
-
${
|
|
444
|
-
`,
|
|
443
|
+
${ey}
|
|
444
|
+
`,eF=(0,el.default)`
|
|
445
445
|
query CLI_applicationDeviceSettings($id: ID!) {
|
|
446
446
|
applicationDeviceSettings: application(id: $id) {
|
|
447
447
|
_id
|
|
@@ -466,7 +466,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
466
466
|
}
|
|
467
467
|
}
|
|
468
468
|
}
|
|
469
|
-
`,
|
|
469
|
+
`,e$=(0,el.default)`
|
|
470
470
|
query CLI_applicationReleaseVersions($id: ID!) {
|
|
471
471
|
applicationReleaseVersions(id: $id) {
|
|
472
472
|
_id
|
|
@@ -475,14 +475,14 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
475
475
|
create_datetime
|
|
476
476
|
}
|
|
477
477
|
}
|
|
478
|
-
`,
|
|
478
|
+
`,eP=(0,el.default)`
|
|
479
479
|
query CLI_applications($keyword: String, $paginate: Paginate) {
|
|
480
480
|
applications(keyword: $keyword, paginate: $paginate) {
|
|
481
481
|
...cliApplicationShortArguments
|
|
482
482
|
}
|
|
483
483
|
}
|
|
484
|
-
${
|
|
485
|
-
`,
|
|
484
|
+
${eg}
|
|
485
|
+
`,eL=(0,el.default)`
|
|
486
486
|
query CLI_publicApplicationShareInfo($id: ID!) {
|
|
487
487
|
publicApplicationShareInfo(id: $id) {
|
|
488
488
|
_id
|
|
@@ -507,32 +507,32 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
507
507
|
}
|
|
508
508
|
}
|
|
509
509
|
}
|
|
510
|
-
`,
|
|
510
|
+
`,ej=(0,el.default)`
|
|
511
511
|
query CLI_module($id: ID!) {
|
|
512
512
|
module(id: $id) {
|
|
513
513
|
...cliModuleArguments
|
|
514
514
|
}
|
|
515
515
|
}
|
|
516
|
-
${
|
|
517
|
-
`,
|
|
516
|
+
${e_}
|
|
517
|
+
`,eM=(0,el.default)`
|
|
518
518
|
query CLI_modules($keyword: String, $paginate: Paginate) {
|
|
519
519
|
modules(keyword: $keyword, paginate: $paginate) {
|
|
520
520
|
...cliModuleShortArguments
|
|
521
521
|
}
|
|
522
522
|
}
|
|
523
|
-
${
|
|
524
|
-
`,
|
|
523
|
+
${eb}
|
|
524
|
+
`,eU=(0,el.default)`
|
|
525
525
|
query CLI_publicModules($keyword: String!, $limit: Int) {
|
|
526
526
|
publicModules(keyword: $keyword, paginate: { limit: $limit }) {
|
|
527
527
|
...cliModuleShortArguments
|
|
528
528
|
}
|
|
529
529
|
}
|
|
530
|
-
${
|
|
531
|
-
`,
|
|
530
|
+
${eb}
|
|
531
|
+
`,eB=(0,el.default)`
|
|
532
532
|
query CLI_checkBindDevicePasscode($passcode: String!) {
|
|
533
533
|
checkBindDevicePasscode(passcode: $passcode)
|
|
534
534
|
}
|
|
535
|
-
`,
|
|
535
|
+
`,eq=(0,el.default)`
|
|
536
536
|
query CLI_mediaFiles(
|
|
537
537
|
$boxId: ID!
|
|
538
538
|
$includeTypes: [String]
|
|
@@ -575,7 +575,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
575
575
|
}
|
|
576
576
|
}
|
|
577
577
|
}
|
|
578
|
-
`,
|
|
578
|
+
`,eQ=(0,el.default)`
|
|
579
579
|
query CLI_mediaWorkspace {
|
|
580
580
|
mediaWorkspace {
|
|
581
581
|
id
|
|
@@ -588,7 +588,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
588
588
|
updatedAt
|
|
589
589
|
}
|
|
590
590
|
}
|
|
591
|
-
`,
|
|
591
|
+
`,eY=(0,el.default)`
|
|
592
592
|
query CLI_mediaBoxes($includeCodes: Boolean = false) {
|
|
593
593
|
mediaBoxes {
|
|
594
594
|
id
|
|
@@ -610,7 +610,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
610
610
|
}
|
|
611
611
|
}
|
|
612
612
|
}
|
|
613
|
-
`,
|
|
613
|
+
`,eG=(0,el.default)`
|
|
614
614
|
query CLI_mediaBox($id: ID!, $includeCodes: Boolean = false) {
|
|
615
615
|
mediaBox(id: $id) {
|
|
616
616
|
id
|
|
@@ -632,7 +632,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
632
632
|
}
|
|
633
633
|
}
|
|
634
634
|
}
|
|
635
|
-
`,
|
|
635
|
+
`,ez=(0,el.default)`
|
|
636
636
|
query CLI_mediaFile($id: ID!) {
|
|
637
637
|
mediaFile(id: $id) {
|
|
638
638
|
id
|
|
@@ -663,7 +663,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
663
663
|
}
|
|
664
664
|
}
|
|
665
665
|
}
|
|
666
|
-
`,
|
|
666
|
+
`,eH=(0,el.default)`
|
|
667
667
|
query CLI_deviceUsage($deviceId: ID, $startDate: Date, $endDate: Date) {
|
|
668
668
|
deviceUsage(deviceId: $deviceId, startDate: $startDate, endDate: $endDate) {
|
|
669
669
|
_id
|
|
@@ -682,7 +682,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
682
682
|
}
|
|
683
683
|
}
|
|
684
684
|
}
|
|
685
|
-
`,
|
|
685
|
+
`,eW=(0,el.default)`
|
|
686
686
|
query CLI_applicationProject(
|
|
687
687
|
$id: ID!
|
|
688
688
|
$buildApplicationOnly: Boolean
|
|
@@ -700,7 +700,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
700
700
|
setupGeminiCLI: $setupGeminiCLI
|
|
701
701
|
)
|
|
702
702
|
}
|
|
703
|
-
`,
|
|
703
|
+
`,eK=(0,el.default)`
|
|
704
704
|
query CLI_moduleProject(
|
|
705
705
|
$id: ID!
|
|
706
706
|
$buildApplicationOnly: Boolean
|
|
@@ -718,7 +718,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
718
718
|
setupGeminiCLI: $setupGeminiCLI
|
|
719
719
|
)
|
|
720
720
|
}
|
|
721
|
-
`,
|
|
721
|
+
`,eJ=(0,el.default)`
|
|
722
722
|
query CLI_buttressServers {
|
|
723
723
|
buttressServers {
|
|
724
724
|
serverId
|
|
@@ -727,39 +727,39 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
727
727
|
lastSeenAt
|
|
728
728
|
}
|
|
729
729
|
}
|
|
730
|
-
`,
|
|
730
|
+
`,eZ=(0,el.default)`
|
|
731
731
|
query CLI_registryTrust {
|
|
732
732
|
registryTrust {
|
|
733
733
|
...cliRegistryTrustArguments
|
|
734
734
|
}
|
|
735
735
|
}
|
|
736
|
-
${
|
|
737
|
-
`,
|
|
736
|
+
${eO}
|
|
737
|
+
`,eX=(0,el.default)`
|
|
738
738
|
query CLI_blueprint($id: ID!) {
|
|
739
739
|
blueprint(id: $id) {
|
|
740
740
|
...cliBlueprintArguments
|
|
741
741
|
}
|
|
742
742
|
}
|
|
743
|
-
${
|
|
744
|
-
`,
|
|
743
|
+
${eT}
|
|
744
|
+
`,e1=(0,el.default)`
|
|
745
745
|
query CLI_blueprints($keyword: String, $paginate: Paginate) {
|
|
746
746
|
blueprints(keyword: $keyword, paginate: $paginate) {
|
|
747
747
|
...cliBlueprintShortArguments
|
|
748
748
|
}
|
|
749
749
|
}
|
|
750
|
-
${
|
|
751
|
-
`,
|
|
750
|
+
${eN}
|
|
751
|
+
`,e0=(0,el.default)`
|
|
752
752
|
query CLI_blueprintsByInstance($kind: BlueprintNodeKind!, $ref: String!) {
|
|
753
753
|
blueprintsByInstance(kind: $kind, ref: $ref) {
|
|
754
754
|
...cliBlueprintShortArguments
|
|
755
755
|
}
|
|
756
756
|
}
|
|
757
|
-
${
|
|
758
|
-
`,
|
|
757
|
+
${eN}
|
|
758
|
+
`,e2=(0,el.default)`
|
|
759
759
|
query CLI_blueprintProjection($id: ID!, $format: Int) {
|
|
760
760
|
blueprintProjection(id: $id, format: $format)
|
|
761
761
|
}
|
|
762
|
-
`,
|
|
762
|
+
`,e6=(0,el.default)`
|
|
763
763
|
query CLI_blueprintRevisions($id: ID!, $limit: Int) {
|
|
764
764
|
blueprintRevisions(id: $id, limit: $limit) {
|
|
765
765
|
_id
|
|
@@ -769,7 +769,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
769
769
|
created_at
|
|
770
770
|
}
|
|
771
771
|
}
|
|
772
|
-
`,
|
|
772
|
+
`,e4=(0,el.default)`
|
|
773
773
|
query CLI_blueprintEvents($id: ID!, $limit: Int) {
|
|
774
774
|
blueprintEvents(id: $id, limit: $limit) {
|
|
775
775
|
_id
|
|
@@ -785,7 +785,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
785
785
|
created_at
|
|
786
786
|
}
|
|
787
787
|
}
|
|
788
|
-
`,
|
|
788
|
+
`,e3=(0,el.default)`
|
|
789
789
|
query CLI_devicesApplicationStatus($filter: DeviceApplicationStatusFilter, $paginate: Paginate) {
|
|
790
790
|
devicesApplicationStatus(filter: $filter, paginate: $paginate) {
|
|
791
791
|
device_id
|
|
@@ -815,28 +815,28 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
815
815
|
}
|
|
816
816
|
}
|
|
817
817
|
}
|
|
818
|
-
`,
|
|
818
|
+
`,e9=(0,el.default)`
|
|
819
819
|
mutation CLI_createDevice($bindPasscode: String, $name: String, $deviceName: String) {
|
|
820
820
|
createDevice(bindPasscode: $bindPasscode, name: $name, deviceName: $deviceName) {
|
|
821
821
|
...cliDeviceArguments
|
|
822
822
|
}
|
|
823
823
|
}
|
|
824
|
-
${
|
|
825
|
-
`,
|
|
824
|
+
${em}
|
|
825
|
+
`,e5=(0,el.default)`
|
|
826
826
|
mutation CLI_controlDevice($id: ID!, $type: String!, $eventPayload: JSON) {
|
|
827
827
|
controlDevice(id: $id, type: $type, eventPayload: $eventPayload) {
|
|
828
828
|
_id
|
|
829
829
|
name
|
|
830
830
|
}
|
|
831
831
|
}
|
|
832
|
-
`,
|
|
832
|
+
`,e8=(0,el.default)`
|
|
833
833
|
mutation CLI_createVirtualDevice($name: String, $deviceName: String) {
|
|
834
834
|
createVirtualDevice(name: $name, deviceName: $deviceName) {
|
|
835
835
|
...cliDeviceArguments
|
|
836
836
|
}
|
|
837
837
|
}
|
|
838
|
-
${
|
|
839
|
-
`,
|
|
838
|
+
${em}
|
|
839
|
+
`,e7=(0,el.default)`
|
|
840
840
|
mutation CLI_updateVirtualDevice($id: ID!, $tokens: [DeviceTokenInput], $revokeTokens: [ID!]) {
|
|
841
841
|
updateVirtualDevice(id: $id, tokens: $tokens, revokeTokens: $revokeTokens) {
|
|
842
842
|
device {
|
|
@@ -848,8 +848,8 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
848
848
|
}
|
|
849
849
|
}
|
|
850
850
|
}
|
|
851
|
-
${
|
|
852
|
-
`,
|
|
851
|
+
${em}
|
|
852
|
+
`,te=(0,el.default)`
|
|
853
853
|
mutation CLI_updateDevice(
|
|
854
854
|
$id: ID!
|
|
855
855
|
$name: String
|
|
@@ -875,19 +875,19 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
875
875
|
...cliDeviceArguments
|
|
876
876
|
}
|
|
877
877
|
}
|
|
878
|
-
${
|
|
879
|
-
`,
|
|
878
|
+
${em}
|
|
879
|
+
`,tt=(0,el.default)`
|
|
880
880
|
mutation CLI_removeDevice($id: ID!) {
|
|
881
881
|
removeDevice(id: $id)
|
|
882
882
|
}
|
|
883
|
-
`,
|
|
883
|
+
`,ta=(0,el.default)`
|
|
884
884
|
mutation CLI_dispatchDeviceGroupAction($id: ID!, $action: String!) {
|
|
885
885
|
dispatchDeviceGroupAction(id: $id, action: $action) {
|
|
886
886
|
dispatched
|
|
887
887
|
devices
|
|
888
888
|
}
|
|
889
889
|
}
|
|
890
|
-
`,
|
|
890
|
+
`,tr=(0,el.default)`
|
|
891
891
|
mutation CLI_createApplication(
|
|
892
892
|
$name: String
|
|
893
893
|
$description: String
|
|
@@ -903,8 +903,8 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
903
903
|
...cliApplicationShortArguments
|
|
904
904
|
}
|
|
905
905
|
}
|
|
906
|
-
${
|
|
907
|
-
`,
|
|
906
|
+
${eg}
|
|
907
|
+
`,ti=(0,el.default)`
|
|
908
908
|
mutation CLI_createApplicationWithShareVersion(
|
|
909
909
|
$name: String
|
|
910
910
|
$description: String
|
|
@@ -920,8 +920,8 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
920
920
|
...cliApplicationShortArguments
|
|
921
921
|
}
|
|
922
922
|
}
|
|
923
|
-
${
|
|
924
|
-
`,
|
|
923
|
+
${eg}
|
|
924
|
+
`,tn=(0,el.default)`
|
|
925
925
|
mutation CLI_updateApplication(
|
|
926
926
|
$id: ID!
|
|
927
927
|
$config: String
|
|
@@ -951,19 +951,19 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
951
951
|
}
|
|
952
952
|
}
|
|
953
953
|
}
|
|
954
|
-
${
|
|
955
|
-
`,
|
|
954
|
+
${eg}
|
|
955
|
+
`,tp=(0,el.default)`
|
|
956
956
|
mutation CLI_useApplicationReleaseVersion($id: ID!, $versionId: ID!) {
|
|
957
957
|
useApplicationReleaseVersion: updateApplication(id: $id, useReleaseVersion: $versionId) {
|
|
958
958
|
...cliApplicationShortArguments
|
|
959
959
|
}
|
|
960
960
|
}
|
|
961
|
-
${
|
|
962
|
-
`,
|
|
961
|
+
${eg}
|
|
962
|
+
`,to=(0,el.default)`
|
|
963
963
|
mutation CLI_removeApplication($id: ID!) {
|
|
964
964
|
removeApplication(id: $id)
|
|
965
965
|
}
|
|
966
|
-
`,
|
|
966
|
+
`,ts=(0,el.default)`
|
|
967
967
|
mutation CLI_shortEditApplication(
|
|
968
968
|
$id: ID!
|
|
969
969
|
$list: [ShortEditInput]!
|
|
@@ -974,8 +974,8 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
974
974
|
...cliApplicationShortArguments
|
|
975
975
|
}
|
|
976
976
|
}
|
|
977
|
-
${
|
|
978
|
-
`,
|
|
977
|
+
${eg}
|
|
978
|
+
`,td=(0,el.default)`
|
|
979
979
|
mutation CLI_bindApplication(
|
|
980
980
|
$id: ID!
|
|
981
981
|
$bindDevices: [ID]
|
|
@@ -1000,7 +1000,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
1000
1000
|
}
|
|
1001
1001
|
}
|
|
1002
1002
|
}
|
|
1003
|
-
`,
|
|
1003
|
+
`,tl=(0,el.default)`
|
|
1004
1004
|
mutation CLI_triggerApplicationCanvasControl(
|
|
1005
1005
|
$id: ID!
|
|
1006
1006
|
$testId: String!
|
|
@@ -1018,7 +1018,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
1018
1018
|
_id
|
|
1019
1019
|
}
|
|
1020
1020
|
}
|
|
1021
|
-
`,
|
|
1021
|
+
`,tu=(0,el.default)`
|
|
1022
1022
|
mutation CLI_createModule(
|
|
1023
1023
|
$name: String
|
|
1024
1024
|
$description: String
|
|
@@ -1042,8 +1042,8 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
1042
1042
|
...cliModuleArguments
|
|
1043
1043
|
}
|
|
1044
1044
|
}
|
|
1045
|
-
${
|
|
1046
|
-
`,
|
|
1045
|
+
${e_}
|
|
1046
|
+
`,tc=(0,el.default)`
|
|
1047
1047
|
mutation CLI_updateModule(
|
|
1048
1048
|
$id: ID!
|
|
1049
1049
|
$config: String
|
|
@@ -1063,12 +1063,12 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
1063
1063
|
...cliModuleArguments
|
|
1064
1064
|
}
|
|
1065
1065
|
}
|
|
1066
|
-
${
|
|
1067
|
-
`,
|
|
1066
|
+
${e_}
|
|
1067
|
+
`,tm=(0,el.default)`
|
|
1068
1068
|
mutation CLI_removeModule($id: ID!) {
|
|
1069
1069
|
removeModule(id: $id)
|
|
1070
1070
|
}
|
|
1071
|
-
`,
|
|
1071
|
+
`,tf=(0,el.default)`
|
|
1072
1072
|
mutation CLI_shortEditModule(
|
|
1073
1073
|
$id: ID!
|
|
1074
1074
|
$list: [ShortEditInput]!
|
|
@@ -1080,7 +1080,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
1080
1080
|
name
|
|
1081
1081
|
}
|
|
1082
1082
|
}
|
|
1083
|
-
`,
|
|
1083
|
+
`,th=(0,el.default)`
|
|
1084
1084
|
mutation CLI_updateWorkspace(
|
|
1085
1085
|
$name: String
|
|
1086
1086
|
$description: String
|
|
@@ -1104,7 +1104,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
1104
1104
|
}
|
|
1105
1105
|
}
|
|
1106
1106
|
}
|
|
1107
|
-
`,
|
|
1107
|
+
`,tv=(0,el.default)`
|
|
1108
1108
|
mutation CLI_releaseApplication(
|
|
1109
1109
|
$id: ID!
|
|
1110
1110
|
$config: String
|
|
@@ -1127,7 +1127,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
1127
1127
|
has_unreleased_changes
|
|
1128
1128
|
}
|
|
1129
1129
|
}
|
|
1130
|
-
`,
|
|
1130
|
+
`,ty=(0,el.default)`
|
|
1131
1131
|
mutation CLI_createMediaFileUploadRequest(
|
|
1132
1132
|
$name: String!
|
|
1133
1133
|
$description: String!
|
|
@@ -1154,7 +1154,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
1154
1154
|
}
|
|
1155
1155
|
}
|
|
1156
1156
|
}
|
|
1157
|
-
`,
|
|
1157
|
+
`,tg=(0,el.default)`
|
|
1158
1158
|
mutation CLI_updateMediaFiles(
|
|
1159
1159
|
$fileIds: [ID!]!
|
|
1160
1160
|
$name: String
|
|
@@ -1163,23 +1163,23 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
1163
1163
|
) {
|
|
1164
1164
|
updateMediaFiles(fileIds: $fileIds, name: $name, description: $description, userTags: $userTags)
|
|
1165
1165
|
}
|
|
1166
|
-
`,
|
|
1166
|
+
`,t_=(0,el.default)`
|
|
1167
1167
|
mutation CLI_copyMediaFiles($fromBoxId: ID!, $toBoxId: ID!, $fileIds: [ID!]!) {
|
|
1168
1168
|
copyMediaFiles(fromBoxId: $fromBoxId, toBoxId: $toBoxId, fileIds: $fileIds)
|
|
1169
1169
|
}
|
|
1170
|
-
`,
|
|
1170
|
+
`,tb=(0,el.default)`
|
|
1171
1171
|
mutation CLI_deleteMediaFiles($boxId: ID!, $fileIds: [ID!]!) {
|
|
1172
1172
|
deleteMediaFiles(boxId: $boxId, fileIds: $fileIds)
|
|
1173
1173
|
}
|
|
1174
|
-
`,
|
|
1174
|
+
`,tw=(0,el.default)`
|
|
1175
1175
|
mutation CLI_deleteMediaBoxFiles($boxId: ID!, $includeTypes: [String]) {
|
|
1176
1176
|
deleteMediaBoxFiles(boxId: $boxId, includeTypes: $includeTypes)
|
|
1177
1177
|
}
|
|
1178
|
-
`,
|
|
1178
|
+
`,tE=(0,el.default)`
|
|
1179
1179
|
mutation CLI_setMediaFileAsBoxPreview($id: ID!) {
|
|
1180
1180
|
setMediaFileAsBoxPreview(id: $id)
|
|
1181
1181
|
}
|
|
1182
|
-
`,
|
|
1182
|
+
`,tT=(0,el.default)`
|
|
1183
1183
|
mutation CLI_releaseModule(
|
|
1184
1184
|
$id: ID!
|
|
1185
1185
|
$config: String
|
|
@@ -1199,7 +1199,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
1199
1199
|
name
|
|
1200
1200
|
}
|
|
1201
1201
|
}
|
|
1202
|
-
`,
|
|
1202
|
+
`,tN=(0,el.default)`
|
|
1203
1203
|
mutation CLI_bindButtressServer(
|
|
1204
1204
|
$serverId: String!
|
|
1205
1205
|
$name: String
|
|
@@ -1215,7 +1215,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
1215
1215
|
}
|
|
1216
1216
|
}
|
|
1217
1217
|
}
|
|
1218
|
-
`,
|
|
1218
|
+
`,tS=(0,el.default)`
|
|
1219
1219
|
mutation CLI_bindButtressServerWithRegistry(
|
|
1220
1220
|
$serverId: String!
|
|
1221
1221
|
$name: String
|
|
@@ -1241,20 +1241,20 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
1241
1241
|
}
|
|
1242
1242
|
}
|
|
1243
1243
|
}
|
|
1244
|
-
${eN}
|
|
1245
1244
|
${eS}
|
|
1246
|
-
|
|
1245
|
+
${eO}
|
|
1246
|
+
`,tO=(0,el.default)`
|
|
1247
1247
|
mutation CLI_issueButtressNodeCredential($serverId: String!) {
|
|
1248
1248
|
issueButtressNodeCredential(serverId: $serverId) {
|
|
1249
1249
|
...cliRegistryCredentialArguments
|
|
1250
1250
|
}
|
|
1251
1251
|
}
|
|
1252
|
-
${
|
|
1253
|
-
`,
|
|
1252
|
+
${eS}
|
|
1253
|
+
`,tI=(0,el.default)`
|
|
1254
1254
|
mutation CLI_unbindButtressServer($serverId: String!) {
|
|
1255
1255
|
unbindButtressServer(serverId: $serverId)
|
|
1256
1256
|
}
|
|
1257
|
-
`,
|
|
1257
|
+
`,tD=(0,el.default)`
|
|
1258
1258
|
mutation CLI_issueButtressAccessToken($ttlSeconds: Int) {
|
|
1259
1259
|
issueButtressAccessToken(ttlSeconds: $ttlSeconds) {
|
|
1260
1260
|
token
|
|
@@ -1263,7 +1263,7 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
1263
1263
|
jti
|
|
1264
1264
|
}
|
|
1265
1265
|
}
|
|
1266
|
-
`,
|
|
1266
|
+
`,tA=(0,el.default)`
|
|
1267
1267
|
mutation CLI_issueDevtoolsAccessToken($ttlSeconds: Int) {
|
|
1268
1268
|
issueDevtoolsAccessToken(ttlSeconds: $ttlSeconds) {
|
|
1269
1269
|
token
|
|
@@ -1272,39 +1272,39 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
1272
1272
|
jti
|
|
1273
1273
|
}
|
|
1274
1274
|
}
|
|
1275
|
-
`,
|
|
1275
|
+
`,tk=(0,el.default)`
|
|
1276
1276
|
mutation CLI_revokeAccessTokens {
|
|
1277
1277
|
revokeAccessTokens {
|
|
1278
1278
|
workspaceId
|
|
1279
1279
|
notBefore
|
|
1280
1280
|
}
|
|
1281
1281
|
}
|
|
1282
|
-
`,
|
|
1282
|
+
`,tx=(0,el.default)`
|
|
1283
1283
|
mutation CLI_createBlueprint($name: String!, $description: String) {
|
|
1284
1284
|
createBlueprint(name: $name, description: $description) {
|
|
1285
1285
|
...cliBlueprintArguments
|
|
1286
1286
|
}
|
|
1287
1287
|
}
|
|
1288
|
-
${
|
|
1289
|
-
`,
|
|
1288
|
+
${eT}
|
|
1289
|
+
`,tC=(0,el.default)`
|
|
1290
1290
|
mutation CLI_updateBlueprint($id: ID!, $revision: Int!, $patch: BlueprintPatchInput!) {
|
|
1291
1291
|
updateBlueprint(id: $id, revision: $revision, patch: $patch) {
|
|
1292
1292
|
...cliBlueprintArguments
|
|
1293
1293
|
}
|
|
1294
1294
|
}
|
|
1295
|
-
${
|
|
1296
|
-
`,
|
|
1295
|
+
${eT}
|
|
1296
|
+
`,tR=(0,el.default)`
|
|
1297
1297
|
mutation CLI_revertBlueprint($id: ID!, $toRevision: Int!) {
|
|
1298
1298
|
revertBlueprint(id: $id, toRevision: $toRevision) {
|
|
1299
1299
|
...cliBlueprintArguments
|
|
1300
1300
|
}
|
|
1301
1301
|
}
|
|
1302
|
-
${
|
|
1303
|
-
`,
|
|
1302
|
+
${eT}
|
|
1303
|
+
`,tV=(0,el.default)`
|
|
1304
1304
|
mutation CLI_removeBlueprint($id: ID!) {
|
|
1305
1305
|
removeBlueprint(id: $id)
|
|
1306
1306
|
}
|
|
1307
|
-
`,
|
|
1307
|
+
`,tF=(0,el.default)`
|
|
1308
1308
|
mutation CLI_acquireBlueprintRun(
|
|
1309
1309
|
$id: ID!
|
|
1310
1310
|
$host: String!
|
|
@@ -1318,8 +1318,8 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
1318
1318
|
}
|
|
1319
1319
|
}
|
|
1320
1320
|
}
|
|
1321
|
-
${
|
|
1322
|
-
`,
|
|
1321
|
+
${eE}
|
|
1322
|
+
`,t$=(0,el.default)`
|
|
1323
1323
|
mutation CLI_heartbeatBlueprintRun($id: ID!, $sessionId: String!) {
|
|
1324
1324
|
heartbeatBlueprintRun(id: $id, sessionId: $sessionId) {
|
|
1325
1325
|
ok
|
|
@@ -1328,16 +1328,16 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
1328
1328
|
}
|
|
1329
1329
|
}
|
|
1330
1330
|
}
|
|
1331
|
-
${
|
|
1332
|
-
`,
|
|
1331
|
+
${eE}
|
|
1332
|
+
`,tP=(0,el.default)`
|
|
1333
1333
|
mutation CLI_releaseBlueprintRun($id: ID!, $sessionId: String!) {
|
|
1334
1334
|
releaseBlueprintRun(id: $id, sessionId: $sessionId)
|
|
1335
1335
|
}
|
|
1336
|
-
`;let tP=t("stream"),tL=t("http");var tj=i(87016),tM=i(44044);let tU=t("https"),tB=t("zlib"),tq=tP.Readable,tQ=Symbol("buffer"),tY=Symbol("type");class tG{constructor(){this[tY]="";let e=arguments[0],t=arguments[1],a=[];if(e){let t=Number(e.length);for(let r=0;r<t;r++){let t,i=e[r];(t=i instanceof Buffer?i:ArrayBuffer.isView(i)?Buffer.from(i.buffer,i.byteOffset,i.byteLength):i instanceof ArrayBuffer?Buffer.from(i):i instanceof tG?i[tQ]:Buffer.from("string"==typeof i?i:String(i))).length,a.push(t)}}this[tQ]=Buffer.concat(a);let r=t&&void 0!==t.type&&String(t.type).toLowerCase();r&&!/[^\u0020-\u007E]/.test(r)&&(this[tY]=r)}get size(){return this[tQ].length}get type(){return this[tY]}text(){return Promise.resolve(this[tQ].toString())}arrayBuffer(){let e=this[tQ];return Promise.resolve(e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength))}stream(){let e=new tq;return e._read=function(){},e.push(this[tQ]),e.push(null),e}toString(){return"[object Blob]"}slice(){let e,t=this.size,a=arguments[0],r=arguments[1];e=void 0===a?0:a<0?Math.max(t+a,0):Math.min(a,t);let i=Math.max((void 0===r?t:r<0?Math.max(t+r,0):Math.min(r,t))-e,0),n=this[tQ].slice(e,e+i),p=new tG([],{type:arguments[2]});return p[tQ]=n,p}}function tz(e,t,a){Error.call(this,e),this.message=e,this.type=t,a&&(this.code=this.errno=a.code),Error.captureStackTrace(this,this.constructor)}Object.defineProperties(tG.prototype,{size:{enumerable:!0},type:{enumerable:!0},slice:{enumerable:!0}}),Object.defineProperty(tG.prototype,Symbol.toStringTag,{value:"Blob",writable:!1,enumerable:!1,configurable:!0}),tz.prototype=Object.create(Error.prototype),tz.prototype.constructor=tz,tz.prototype.name="FetchError";try{n=require("encoding").convert}catch(e){}let tH=Symbol("Body internals"),tW=tP.PassThrough;function tK(e){var t=this,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=a.size,i=a.timeout;null==e?e=null:tZ(e)?e=Buffer.from(e.toString()):tX(e)||Buffer.isBuffer(e)||("[object ArrayBuffer]"===Object.prototype.toString.call(e)?e=Buffer.from(e):ArrayBuffer.isView(e)?e=Buffer.from(e.buffer,e.byteOffset,e.byteLength):e instanceof tP||(e=Buffer.from(String(e)))),this[tH]={body:e,disturbed:!1,error:null},this.size=void 0===r?0:r,this.timeout=void 0===i?0:i,e instanceof tP&&e.on("error",function(e){let a="AbortError"===e.name?e:new tz(`Invalid response body while trying to fetch ${t.url}: ${e.message}`,"system",e);t[tH].error=a})}function tJ(){var e=this;if(this[tH].disturbed)return tK.Promise.reject(TypeError(`body used already for: ${this.url}`));if(this[tH].disturbed=!0,this[tH].error)return tK.Promise.reject(this[tH].error);let t=this.body;if(null===t)return tK.Promise.resolve(Buffer.alloc(0));if(tX(t)&&(t=t.stream()),Buffer.isBuffer(t))return tK.Promise.resolve(t);if(!(t instanceof tP))return tK.Promise.resolve(Buffer.alloc(0));let a=[],r=0,i=!1;return new tK.Promise(function(n,p){let o;e.timeout&&(o=setTimeout(function(){i=!0,p(new tz(`Response timeout while trying to fetch ${e.url} (over ${e.timeout}ms)`,"body-timeout"))},e.timeout)),t.on("error",function(t){"AbortError"===t.name?(i=!0,p(t)):p(new tz(`Invalid response body while trying to fetch ${e.url}: ${t.message}`,"system",t))}),t.on("data",function(t){if(!i&&null!==t){if(e.size&&r+t.length>e.size){i=!0,p(new tz(`content size at ${e.url} over limit: ${e.size}`,"max-size"));return}r+=t.length,a.push(t)}}),t.on("end",function(){if(!i){clearTimeout(o);try{n(Buffer.concat(a,r))}catch(t){p(new tz(`Could not create Buffer from response body for ${e.url}: ${t.message}`,"system",t))}}})})}function tZ(e){return"object"==typeof e&&"function"==typeof e.append&&"function"==typeof e.delete&&"function"==typeof e.get&&"function"==typeof e.getAll&&"function"==typeof e.has&&"function"==typeof e.set&&("URLSearchParams"===e.constructor.name||"[object URLSearchParams]"===Object.prototype.toString.call(e)||"function"==typeof e.sort)}function tX(e){return"object"==typeof e&&"function"==typeof e.arrayBuffer&&"string"==typeof e.type&&"function"==typeof e.stream&&"function"==typeof e.constructor&&"string"==typeof e.constructor.name&&/^(Blob|File)$/.test(e.constructor.name)&&/^(Blob|File)$/.test(e[Symbol.toStringTag])}function t1(e){let t,a,r=e.body;if(e.bodyUsed)throw Error("cannot clone body after it is used");return r instanceof tP&&"function"!=typeof r.getBoundary&&(t=new tW,a=new tW,r.pipe(t),r.pipe(a),e[tH].body=t,r=a),r}function t0(e){if(null===e)return null;if("string"==typeof e)return"text/plain;charset=UTF-8";if(tZ(e))return"application/x-www-form-urlencoded;charset=UTF-8";if(tX(e))return e.type||null;if(Buffer.isBuffer(e))return null;else if("[object ArrayBuffer]"===Object.prototype.toString.call(e))return null;else if(ArrayBuffer.isView(e))return null;else if("function"==typeof e.getBoundary)return`multipart/form-data;boundary=${e.getBoundary()}`;else if(e instanceof tP)return null;else return"text/plain;charset=UTF-8"}function t2(e){let t=e.body;return null===t?0:tX(t)?t.size:Buffer.isBuffer(t)?t.length:t&&"function"==typeof t.getLengthSync?t._lengthRetrievers&&0==t._lengthRetrievers.length||t.hasKnownLength&&t.hasKnownLength()?t.getLengthSync():null:null}tK.prototype={get body(){return this[tH].body},get bodyUsed(){return this[tH].disturbed},arrayBuffer(){return tJ.call(this).then(function(e){return e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength)})},blob(){let e=this.headers&&this.headers.get("content-type")||"";return tJ.call(this).then(function(t){return Object.assign(new tG([],{type:e.toLowerCase()}),{[tQ]:t})})},json(){var e=this;return tJ.call(this).then(function(t){try{return JSON.parse(t.toString())}catch(t){return tK.Promise.reject(new tz(`invalid json response body at ${e.url} reason: ${t.message}`,"invalid-json"))}})},text(){return tJ.call(this).then(function(e){return e.toString()})},buffer(){return tJ.call(this)},textConverted(){var e=this;return tJ.call(this).then(function(t){return function(e,t){let a,r;if("function"!=typeof n)throw Error("The package `encoding` must be installed to use the textConverted() function");let i=t.get("content-type"),p="utf-8";return i&&(a=/charset=([^;]*)/i.exec(i)),r=e.slice(0,1024).toString(),!a&&r&&(a=/<meta.+?charset=(['"])(.+?)\1/i.exec(r)),!a&&r&&(!(a=/<meta[\s]+?http-equiv=(['"])content-type\1[\s]+?content=(['"])(.+?)\2/i.exec(r))&&(a=/<meta[\s]+?content=(['"])(.+?)\1[\s]+?http-equiv=(['"])content-type\3/i.exec(r))&&a.pop(),a&&(a=/charset=(.*)/i.exec(a.pop()))),!a&&r&&(a=/<\?xml.+?encoding=(['"])(.+?)\1/i.exec(r)),a&&("gb2312"===(p=a.pop())||"gbk"===p)&&(p="gb18030"),n(e,"UTF-8",p).toString()}(t,e.headers)})}},Object.defineProperties(tK.prototype,{body:{enumerable:!0},bodyUsed:{enumerable:!0},arrayBuffer:{enumerable:!0},blob:{enumerable:!0},json:{enumerable:!0},text:{enumerable:!0}}),tK.mixIn=function(e){for(let t of Object.getOwnPropertyNames(tK.prototype))if(!(t in e)){let a=Object.getOwnPropertyDescriptor(tK.prototype,t);Object.defineProperty(e,t,a)}},tK.Promise=global.Promise;let t6=/[^\^_`a-zA-Z\-0-9!#$%&'*+.|~]/,t4=/[^\t\x20-\x7e\x80-\xff]/;function t3(e){if(e=`${e}`,t6.test(e)||""===e)throw TypeError(`${e} is not a legal HTTP header name`)}function t9(e){if(e=`${e}`,t4.test(e))throw TypeError(`${e} is not a legal HTTP header value`)}function t5(e,t){for(let a in t=t.toLowerCase(),e)if(a.toLowerCase()===t)return a}let t8=Symbol("map");class t7{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:void 0;if(this[t8]=Object.create(null),e instanceof t7){let t=e.raw();for(let e of Object.keys(t))for(let a of t[e])this.append(e,a);return}if(null==e);else if("object"==typeof e){let t=e[Symbol.iterator];if(null!=t){if("function"!=typeof t)throw TypeError("Header pairs must be iterable");let a=[];for(let t of e){if("object"!=typeof t||"function"!=typeof t[Symbol.iterator])throw TypeError("Each header pair must be iterable");a.push(Array.from(t))}for(let e of a){if(2!==e.length)throw TypeError("Each header pair must be a name/value tuple");this.append(e[0],e[1])}}else for(let t of Object.keys(e)){let a=e[t];this.append(t,a)}}else throw TypeError("Provided initializer must be an object")}get(e){t3(e=`${e}`);let t=t5(this[t8],e);return void 0===t?null:this[t8][t].join(", ")}forEach(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0,a=ae(this),r=0;for(;r<a.length;){var i=a[r];let n=i[0],p=i[1];e.call(t,p,n,this),a=ae(this),r++}}set(e,t){e=`${e}`,t=`${t}`,t3(e),t9(t);let a=t5(this[t8],e);this[t8][void 0!==a?a:e]=[t]}append(e,t){e=`${e}`,t=`${t}`,t3(e),t9(t);let a=t5(this[t8],e);void 0!==a?this[t8][a].push(t):this[t8][e]=[t]}has(e){return t3(e=`${e}`),void 0!==t5(this[t8],e)}delete(e){t3(e=`${e}`);let t=t5(this[t8],e);void 0!==t&&delete this[t8][t]}raw(){return this[t8]}keys(){return aa(this,"key")}values(){return aa(this,"value")}[Symbol.iterator](){return aa(this,"key+value")}}function ae(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"key+value";return Object.keys(e[t8]).sort().map("key"===t?function(e){return e.toLowerCase()}:"value"===t?function(t){return e[t8][t].join(", ")}:function(t){return[t.toLowerCase(),e[t8][t].join(", ")]})}t7.prototype.entries=t7.prototype[Symbol.iterator],Object.defineProperty(t7.prototype,Symbol.toStringTag,{value:"Headers",writable:!1,enumerable:!1,configurable:!0}),Object.defineProperties(t7.prototype,{get:{enumerable:!0},forEach:{enumerable:!0},set:{enumerable:!0},append:{enumerable:!0},has:{enumerable:!0},delete:{enumerable:!0},keys:{enumerable:!0},values:{enumerable:!0},entries:{enumerable:!0}});let at=Symbol("internal");function aa(e,t){let a=Object.create(ar);return a[at]={target:e,kind:t,index:0},a}let ar=Object.setPrototypeOf({next(){if(!this||Object.getPrototypeOf(this)!==ar)throw TypeError("Value of `this` is not a HeadersIterator");var e=this[at];let t=e.target,a=e.kind,r=e.index,i=ae(t,a);return r>=i.length?{value:void 0,done:!0}:(this[at].index=r+1,{value:i[r],done:!1})}},Object.getPrototypeOf(Object.getPrototypeOf([][Symbol.iterator]())));Object.defineProperty(ar,Symbol.toStringTag,{value:"HeadersIterator",writable:!1,enumerable:!1,configurable:!0});let ai=Symbol("Response internals"),an=tL.STATUS_CODES;class ap{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};tK.call(this,e,t);let a=t.status||200,r=new t7(t.headers);if(null!=e&&!r.has("Content-Type")){let t=t0(e);t&&r.append("Content-Type",t)}this[ai]={url:t.url,status:a,statusText:t.statusText||an[a],headers:r,counter:t.counter}}get url(){return this[ai].url||""}get status(){return this[ai].status}get ok(){return this[ai].status>=200&&this[ai].status<300}get redirected(){return this[ai].counter>0}get statusText(){return this[ai].statusText}get headers(){return this[ai].headers}clone(){return new ap(t1(this),{url:this.url,status:this.status,statusText:this.statusText,headers:this.headers,ok:this.ok,redirected:this.redirected})}}tK.mixIn(ap.prototype),Object.defineProperties(ap.prototype,{url:{enumerable:!0},status:{enumerable:!0},ok:{enumerable:!0},redirected:{enumerable:!0},statusText:{enumerable:!0},headers:{enumerable:!0},clone:{enumerable:!0}}),Object.defineProperty(ap.prototype,Symbol.toStringTag,{value:"Response",writable:!1,enumerable:!1,configurable:!0});let ao=Symbol("Request internals"),as=tj.URL||tM.k,ad=tj.parse,al=tj.format;function au(e){return/^[a-zA-Z][a-zA-Z\d+\-.]*:/.exec(e)&&(e=new as(e).toString()),ad(e)}let ac="destroy"in tP.Readable.prototype;function am(e){return"object"==typeof e&&"object"==typeof e[ao]}class af{constructor(e){var t;let a,r,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};am(e)?r=au(e.url):(r=e&&e.href?au(e.href):au(`${e}`),e={});let n=i.method||e.method||"GET";if(n=n.toUpperCase(),(null!=i.body||am(e)&&null!==e.body)&&("GET"===n||"HEAD"===n))throw TypeError("Request with GET/HEAD method cannot have body");let p=null!=i.body?i.body:am(e)&&null!==e.body?t1(e):null;tK.call(this,p,{timeout:i.timeout||e.timeout||0,size:i.size||e.size||0});let o=new t7(i.headers||e.headers||{});if(null!=p&&!o.has("Content-Type")){let e=t0(p);e&&o.append("Content-Type",e)}let s=am(e)?e.signal:null;if("signal"in i&&(s=i.signal),null!=s&&(!(a=(t=s)&&"object"==typeof t&&Object.getPrototypeOf(t))||"AbortSignal"!==a.constructor.name))throw TypeError("Expected signal to be an instanceof AbortSignal");this[ao]={method:n,redirect:i.redirect||e.redirect||"follow",headers:o,parsedURL:r,signal:s},this.follow=void 0!==i.follow?i.follow:void 0!==e.follow?e.follow:20,this.compress=void 0!==i.compress?i.compress:void 0===e.compress||e.compress,this.counter=i.counter||e.counter||0,this.agent=i.agent||e.agent}get method(){return this[ao].method}get url(){return al(this[ao].parsedURL)}get headers(){return this[ao].headers}get redirect(){return this[ao].redirect}get signal(){return this[ao].signal}clone(){return new af(this)}}function ah(e){Error.call(this,e),this.type="aborted",this.message=e,Error.captureStackTrace(this,this.constructor)}tK.mixIn(af.prototype),Object.defineProperty(af.prototype,Symbol.toStringTag,{value:"Request",writable:!1,enumerable:!1,configurable:!0}),Object.defineProperties(af.prototype,{method:{enumerable:!0},url:{enumerable:!0},headers:{enumerable:!0},redirect:{enumerable:!0},clone:{enumerable:!0},signal:{enumerable:!0}}),ah.prototype=Object.create(Error.prototype),ah.prototype.constructor=ah,ah.prototype.name="AbortError";let av=tj.URL||tM.k,ay=tP.PassThrough,ag=function(e,t){let a=new av(t).hostname,r=new av(e).hostname;return a===r||"."===a[a.length-r.length-1]&&a.endsWith(r)};function a_(e,t){if(!a_.Promise)throw Error("native promise missing, set fetch.Promise to your favorite alternative");return tK.Promise=a_.Promise,new a_.Promise(function(a,r){var i,n;let p,o,s,d=new af(e,t),l=function(e){let t,a,r=e[ao].parsedURL,i=new t7(e[ao].headers);if(i.has("Accept")||i.set("Accept","*/*"),!r.protocol||!r.hostname)throw TypeError("Only absolute URLs are supported");if(!/^https?:$/.test(r.protocol))throw TypeError("Only HTTP(S) protocols are supported");if(e.signal&&e.body instanceof tP.Readable&&!ac)throw Error("Cancellation of streamed requests with AbortSignal is not supported in node < 8");let n=null;if(null==e.body&&/^(POST|PUT)$/i.test(e.method)&&(n="0"),null!=e.body){let t=t2(e);"number"==typeof t&&(n=String(t))}n&&i.set("Content-Length",n),i.has("User-Agent")||i.set("User-Agent","node-fetch/1.0 (+https://github.com/bitinn/node-fetch)"),e.compress&&!i.has("Accept-Encoding")&&i.set("Accept-Encoding","gzip,deflate");let p=e.agent;return"function"==typeof p&&(p=p(r)),Object.assign({},r,{method:e.method,headers:(t=Object.assign({__proto__:null},i[t8]),void 0!==(a=t5(i[t8],"Host"))&&(t[a]=t[a][0]),t),agent:p})}(d),u=("https:"===l.protocol?tU:tL).request,c=d.signal,m=null,f=function(){let e=new ah("The user aborted a request.");r(e),d.body&&d.body instanceof tP.Readable&&ab(d.body,e),m&&m.body&&m.body.emit("error",e)};if(c&&c.aborted)return void f();let h=function(){f(),y()},v=u(l);function y(){v.abort(),c&&c.removeEventListener("abort",h),clearTimeout(o)}c&&c.addEventListener("abort",h),d.timeout&&v.once("socket",function(e){o=setTimeout(function(){r(new tz(`network timeout at: ${d.url}`,"request-timeout")),y()},d.timeout)}),v.on("error",function(e){r(new tz(`request to ${d.url} failed, reason: ${e.message}`,"system",e)),m&&m.body&&ab(m.body,e),y()}),i=v,n=function(e){(!c||!c.aborted)&&m&&m.body&&ab(m.body,e)},i.on("socket",function(e){p=e}),i.on("response",function(e){let t=e.headers;"chunked"!==t["transfer-encoding"]||t["content-length"]||e.once("close",function(e){if(p&&p.listenerCount("data")>0&&!e){let e=Error("Premature close");e.code="ERR_STREAM_PREMATURE_CLOSE",n(e)}})}),14>parseInt(process.version.substring(1))&&v.on("socket",function(e){e.addListener("close",function(t){let a=e.listenerCount("data")>0;if(m&&a&&!t&&!(c&&c.aborted)){let e=Error("Premature close");e.code="ERR_STREAM_PREMATURE_CLOSE",m.body.emit("error",e)}})}),v.on("response",function(e){clearTimeout(o);let t=function(e){let t=new t7;for(let a of Object.keys(e))if(!t6.test(a))if(Array.isArray(e[a]))for(let r of e[a])t4.test(r)||(void 0===t[t8][a]?t[t8][a]=[r]:t[t8][a].push(r));else t4.test(e[a])||(t[t8][a]=[e[a]]);return t}(e.headers);if(a_.isRedirect(e.statusCode)){let n=t.get("Location"),p=null;try{p=null===n?null:new av(n,d.url).toString()}catch(e){if("manual"!==d.redirect){r(new tz(`uri requested responds with an invalid redirect URL: ${n}`,"invalid-redirect")),y();return}}switch(d.redirect){case"error":r(new tz(`uri requested responds with a redirect, redirect mode is set to error: ${d.url}`,"no-redirect")),y();return;case"manual":if(null!==p)try{t.set("Location",p)}catch(e){r(e)}break;case"follow":var i;if(null===p)break;if(d.counter>=d.follow){r(new tz(`maximum redirect reached at: ${d.url}`,"max-redirect")),y();return}let o={headers:new t7(d.headers),follow:d.follow,counter:d.counter+1,agent:d.agent,compress:d.compress,method:d.method,body:d.body,signal:d.signal,timeout:d.timeout,size:d.size};if(!ag(d.url,p)||(i=d.url,new av(p).protocol!==new av(i).protocol))for(let e of["authorization","www-authenticate","cookie","cookie2"])o.headers.delete(e);if(303!==e.statusCode&&d.body&&null===t2(d)){r(new tz("Cannot follow redirect with body being a readable stream","unsupported-redirect")),y();return}(303===e.statusCode||(301===e.statusCode||302===e.statusCode)&&"POST"===d.method)&&(o.method="GET",o.body=void 0,o.headers.delete("content-length")),a(a_(new af(p,o))),y();return}}e.once("end",function(){c&&c.removeEventListener("abort",h)});let n=e.pipe(new ay),p={url:d.url,status:e.statusCode,statusText:e.statusMessage,headers:t,size:d.size,timeout:d.timeout,counter:d.counter},s=t.get("Content-Encoding");if(!d.compress||"HEAD"===d.method||null===s||204===e.statusCode||304===e.statusCode)return void a(m=new ap(n,p));let l={flush:tB.Z_SYNC_FLUSH,finishFlush:tB.Z_SYNC_FLUSH};if("gzip"==s||"x-gzip"==s)return void a(m=new ap(n=n.pipe(tB.createGunzip(l)),p));if("deflate"==s||"x-deflate"==s){let t=e.pipe(new ay);t.once("data",function(e){a(m=new ap(n=(15&e[0])==8?n.pipe(tB.createInflate()):n.pipe(tB.createInflateRaw()),p))}),t.on("end",function(){m||a(m=new ap(n,p))});return}"br"==s&&"function"==typeof tB.createBrotliDecompress?a(m=new ap(n=n.pipe(tB.createBrotliDecompress()),p)):a(m=new ap(n,p))}),null===(s=d.body)?v.end():tX(s)?s.stream().pipe(v):Buffer.isBuffer(s)?(v.write(s),v.end()):s.pipe(v)})}function ab(e,t){e.destroy?e.destroy(t):(e.emit("error",t),e.end())}a_.isRedirect=function(e){return 301===e||302===e||303===e||307===e||308===e},a_.Promise=global.Promise;var aw=i(64007);function aE(e){var t=process.env.HTTPS_PROXY||process.env.https_proxy;if(!t||!e.startsWith("https://"))return a_;var a=new aw(t);return(e,t={})=>a_(e,{...t,agent:a})}var aT=eo.ApolloClient,aN=eo.InMemoryCache,aS=eo.HttpLink,aO=es.o,aI={query:"query",mutation:"mutate"},aD=ep(function e(t){en(this,e),this.baseUrl=t,this.endpoint="/api/graphql-nonauth";var a=new aS({uri:`${t}${this.endpoint}`,fetch:aE(t)});this.apolloClient=new aT({link:a,cache:new aN,defaultOptions:{query:{errorPolicy:"all",fetchPolicy:"no-cache"}}})},[{key:"checkWorkspaceOTP",value:(p=ei(function*(e){var t=(0,ed.default)`
|
|
1336
|
+
`;let tL=t("stream"),tj=t("http");var tM=i(87016),tU=i(44044);let tB=t("https"),tq=t("zlib"),tQ=tL.Readable,tY=Symbol("buffer"),tG=Symbol("type");class tz{constructor(){this[tG]="";let e=arguments[0],t=arguments[1],a=[];if(e){let t=Number(e.length);for(let r=0;r<t;r++){let t,i=e[r];(t=i instanceof Buffer?i:ArrayBuffer.isView(i)?Buffer.from(i.buffer,i.byteOffset,i.byteLength):i instanceof ArrayBuffer?Buffer.from(i):i instanceof tz?i[tY]:Buffer.from("string"==typeof i?i:String(i))).length,a.push(t)}}this[tY]=Buffer.concat(a);let r=t&&void 0!==t.type&&String(t.type).toLowerCase();r&&!/[^\u0020-\u007E]/.test(r)&&(this[tG]=r)}get size(){return this[tY].length}get type(){return this[tG]}text(){return Promise.resolve(this[tY].toString())}arrayBuffer(){let e=this[tY];return Promise.resolve(e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength))}stream(){let e=new tQ;return e._read=function(){},e.push(this[tY]),e.push(null),e}toString(){return"[object Blob]"}slice(){let e,t=this.size,a=arguments[0],r=arguments[1];e=void 0===a?0:a<0?Math.max(t+a,0):Math.min(a,t);let i=Math.max((void 0===r?t:r<0?Math.max(t+r,0):Math.min(r,t))-e,0),n=this[tY].slice(e,e+i),p=new tz([],{type:arguments[2]});return p[tY]=n,p}}function tH(e,t,a){Error.call(this,e),this.message=e,this.type=t,a&&(this.code=this.errno=a.code),Error.captureStackTrace(this,this.constructor)}Object.defineProperties(tz.prototype,{size:{enumerable:!0},type:{enumerable:!0},slice:{enumerable:!0}}),Object.defineProperty(tz.prototype,Symbol.toStringTag,{value:"Blob",writable:!1,enumerable:!1,configurable:!0}),tH.prototype=Object.create(Error.prototype),tH.prototype.constructor=tH,tH.prototype.name="FetchError";try{n=require("encoding").convert}catch(e){}let tW=Symbol("Body internals"),tK=tL.PassThrough;function tJ(e){var t=this,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=a.size,i=a.timeout;null==e?e=null:tX(e)?e=Buffer.from(e.toString()):t1(e)||Buffer.isBuffer(e)||("[object ArrayBuffer]"===Object.prototype.toString.call(e)?e=Buffer.from(e):ArrayBuffer.isView(e)?e=Buffer.from(e.buffer,e.byteOffset,e.byteLength):e instanceof tL||(e=Buffer.from(String(e)))),this[tW]={body:e,disturbed:!1,error:null},this.size=void 0===r?0:r,this.timeout=void 0===i?0:i,e instanceof tL&&e.on("error",function(e){let a="AbortError"===e.name?e:new tH(`Invalid response body while trying to fetch ${t.url}: ${e.message}`,"system",e);t[tW].error=a})}function tZ(){var e=this;if(this[tW].disturbed)return tJ.Promise.reject(TypeError(`body used already for: ${this.url}`));if(this[tW].disturbed=!0,this[tW].error)return tJ.Promise.reject(this[tW].error);let t=this.body;if(null===t)return tJ.Promise.resolve(Buffer.alloc(0));if(t1(t)&&(t=t.stream()),Buffer.isBuffer(t))return tJ.Promise.resolve(t);if(!(t instanceof tL))return tJ.Promise.resolve(Buffer.alloc(0));let a=[],r=0,i=!1;return new tJ.Promise(function(n,p){let o;e.timeout&&(o=setTimeout(function(){i=!0,p(new tH(`Response timeout while trying to fetch ${e.url} (over ${e.timeout}ms)`,"body-timeout"))},e.timeout)),t.on("error",function(t){"AbortError"===t.name?(i=!0,p(t)):p(new tH(`Invalid response body while trying to fetch ${e.url}: ${t.message}`,"system",t))}),t.on("data",function(t){if(!i&&null!==t){if(e.size&&r+t.length>e.size){i=!0,p(new tH(`content size at ${e.url} over limit: ${e.size}`,"max-size"));return}r+=t.length,a.push(t)}}),t.on("end",function(){if(!i){clearTimeout(o);try{n(Buffer.concat(a,r))}catch(t){p(new tH(`Could not create Buffer from response body for ${e.url}: ${t.message}`,"system",t))}}})})}function tX(e){return"object"==typeof e&&"function"==typeof e.append&&"function"==typeof e.delete&&"function"==typeof e.get&&"function"==typeof e.getAll&&"function"==typeof e.has&&"function"==typeof e.set&&("URLSearchParams"===e.constructor.name||"[object URLSearchParams]"===Object.prototype.toString.call(e)||"function"==typeof e.sort)}function t1(e){return"object"==typeof e&&"function"==typeof e.arrayBuffer&&"string"==typeof e.type&&"function"==typeof e.stream&&"function"==typeof e.constructor&&"string"==typeof e.constructor.name&&/^(Blob|File)$/.test(e.constructor.name)&&/^(Blob|File)$/.test(e[Symbol.toStringTag])}function t0(e){let t,a,r=e.body;if(e.bodyUsed)throw Error("cannot clone body after it is used");return r instanceof tL&&"function"!=typeof r.getBoundary&&(t=new tK,a=new tK,r.pipe(t),r.pipe(a),e[tW].body=t,r=a),r}function t2(e){if(null===e)return null;if("string"==typeof e)return"text/plain;charset=UTF-8";if(tX(e))return"application/x-www-form-urlencoded;charset=UTF-8";if(t1(e))return e.type||null;if(Buffer.isBuffer(e))return null;else if("[object ArrayBuffer]"===Object.prototype.toString.call(e))return null;else if(ArrayBuffer.isView(e))return null;else if("function"==typeof e.getBoundary)return`multipart/form-data;boundary=${e.getBoundary()}`;else if(e instanceof tL)return null;else return"text/plain;charset=UTF-8"}function t6(e){let t=e.body;return null===t?0:t1(t)?t.size:Buffer.isBuffer(t)?t.length:t&&"function"==typeof t.getLengthSync?t._lengthRetrievers&&0==t._lengthRetrievers.length||t.hasKnownLength&&t.hasKnownLength()?t.getLengthSync():null:null}tJ.prototype={get body(){return this[tW].body},get bodyUsed(){return this[tW].disturbed},arrayBuffer(){return tZ.call(this).then(function(e){return e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength)})},blob(){let e=this.headers&&this.headers.get("content-type")||"";return tZ.call(this).then(function(t){return Object.assign(new tz([],{type:e.toLowerCase()}),{[tY]:t})})},json(){var e=this;return tZ.call(this).then(function(t){try{return JSON.parse(t.toString())}catch(t){return tJ.Promise.reject(new tH(`invalid json response body at ${e.url} reason: ${t.message}`,"invalid-json"))}})},text(){return tZ.call(this).then(function(e){return e.toString()})},buffer(){return tZ.call(this)},textConverted(){var e=this;return tZ.call(this).then(function(t){return function(e,t){let a,r;if("function"!=typeof n)throw Error("The package `encoding` must be installed to use the textConverted() function");let i=t.get("content-type"),p="utf-8";return i&&(a=/charset=([^;]*)/i.exec(i)),r=e.slice(0,1024).toString(),!a&&r&&(a=/<meta.+?charset=(['"])(.+?)\1/i.exec(r)),!a&&r&&(!(a=/<meta[\s]+?http-equiv=(['"])content-type\1[\s]+?content=(['"])(.+?)\2/i.exec(r))&&(a=/<meta[\s]+?content=(['"])(.+?)\1[\s]+?http-equiv=(['"])content-type\3/i.exec(r))&&a.pop(),a&&(a=/charset=(.*)/i.exec(a.pop()))),!a&&r&&(a=/<\?xml.+?encoding=(['"])(.+?)\1/i.exec(r)),a&&("gb2312"===(p=a.pop())||"gbk"===p)&&(p="gb18030"),n(e,"UTF-8",p).toString()}(t,e.headers)})}},Object.defineProperties(tJ.prototype,{body:{enumerable:!0},bodyUsed:{enumerable:!0},arrayBuffer:{enumerable:!0},blob:{enumerable:!0},json:{enumerable:!0},text:{enumerable:!0}}),tJ.mixIn=function(e){for(let t of Object.getOwnPropertyNames(tJ.prototype))if(!(t in e)){let a=Object.getOwnPropertyDescriptor(tJ.prototype,t);Object.defineProperty(e,t,a)}},tJ.Promise=global.Promise;let t4=/[^\^_`a-zA-Z\-0-9!#$%&'*+.|~]/,t3=/[^\t\x20-\x7e\x80-\xff]/;function t9(e){if(e=`${e}`,t4.test(e)||""===e)throw TypeError(`${e} is not a legal HTTP header name`)}function t5(e){if(e=`${e}`,t3.test(e))throw TypeError(`${e} is not a legal HTTP header value`)}function t8(e,t){for(let a in t=t.toLowerCase(),e)if(a.toLowerCase()===t)return a}let t7=Symbol("map");class ae{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:void 0;if(this[t7]=Object.create(null),e instanceof ae){let t=e.raw();for(let e of Object.keys(t))for(let a of t[e])this.append(e,a);return}if(null==e);else if("object"==typeof e){let t=e[Symbol.iterator];if(null!=t){if("function"!=typeof t)throw TypeError("Header pairs must be iterable");let a=[];for(let t of e){if("object"!=typeof t||"function"!=typeof t[Symbol.iterator])throw TypeError("Each header pair must be iterable");a.push(Array.from(t))}for(let e of a){if(2!==e.length)throw TypeError("Each header pair must be a name/value tuple");this.append(e[0],e[1])}}else for(let t of Object.keys(e)){let a=e[t];this.append(t,a)}}else throw TypeError("Provided initializer must be an object")}get(e){t9(e=`${e}`);let t=t8(this[t7],e);return void 0===t?null:this[t7][t].join(", ")}forEach(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0,a=at(this),r=0;for(;r<a.length;){var i=a[r];let n=i[0],p=i[1];e.call(t,p,n,this),a=at(this),r++}}set(e,t){e=`${e}`,t=`${t}`,t9(e),t5(t);let a=t8(this[t7],e);this[t7][void 0!==a?a:e]=[t]}append(e,t){e=`${e}`,t=`${t}`,t9(e),t5(t);let a=t8(this[t7],e);void 0!==a?this[t7][a].push(t):this[t7][e]=[t]}has(e){return t9(e=`${e}`),void 0!==t8(this[t7],e)}delete(e){t9(e=`${e}`);let t=t8(this[t7],e);void 0!==t&&delete this[t7][t]}raw(){return this[t7]}keys(){return ar(this,"key")}values(){return ar(this,"value")}[Symbol.iterator](){return ar(this,"key+value")}}function at(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"key+value";return Object.keys(e[t7]).sort().map("key"===t?function(e){return e.toLowerCase()}:"value"===t?function(t){return e[t7][t].join(", ")}:function(t){return[t.toLowerCase(),e[t7][t].join(", ")]})}ae.prototype.entries=ae.prototype[Symbol.iterator],Object.defineProperty(ae.prototype,Symbol.toStringTag,{value:"Headers",writable:!1,enumerable:!1,configurable:!0}),Object.defineProperties(ae.prototype,{get:{enumerable:!0},forEach:{enumerable:!0},set:{enumerable:!0},append:{enumerable:!0},has:{enumerable:!0},delete:{enumerable:!0},keys:{enumerable:!0},values:{enumerable:!0},entries:{enumerable:!0}});let aa=Symbol("internal");function ar(e,t){let a=Object.create(ai);return a[aa]={target:e,kind:t,index:0},a}let ai=Object.setPrototypeOf({next(){if(!this||Object.getPrototypeOf(this)!==ai)throw TypeError("Value of `this` is not a HeadersIterator");var e=this[aa];let t=e.target,a=e.kind,r=e.index,i=at(t,a);return r>=i.length?{value:void 0,done:!0}:(this[aa].index=r+1,{value:i[r],done:!1})}},Object.getPrototypeOf(Object.getPrototypeOf([][Symbol.iterator]())));Object.defineProperty(ai,Symbol.toStringTag,{value:"HeadersIterator",writable:!1,enumerable:!1,configurable:!0});let an=Symbol("Response internals"),ap=tj.STATUS_CODES;class ao{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};tJ.call(this,e,t);let a=t.status||200,r=new ae(t.headers);if(null!=e&&!r.has("Content-Type")){let t=t2(e);t&&r.append("Content-Type",t)}this[an]={url:t.url,status:a,statusText:t.statusText||ap[a],headers:r,counter:t.counter}}get url(){return this[an].url||""}get status(){return this[an].status}get ok(){return this[an].status>=200&&this[an].status<300}get redirected(){return this[an].counter>0}get statusText(){return this[an].statusText}get headers(){return this[an].headers}clone(){return new ao(t0(this),{url:this.url,status:this.status,statusText:this.statusText,headers:this.headers,ok:this.ok,redirected:this.redirected})}}tJ.mixIn(ao.prototype),Object.defineProperties(ao.prototype,{url:{enumerable:!0},status:{enumerable:!0},ok:{enumerable:!0},redirected:{enumerable:!0},statusText:{enumerable:!0},headers:{enumerable:!0},clone:{enumerable:!0}}),Object.defineProperty(ao.prototype,Symbol.toStringTag,{value:"Response",writable:!1,enumerable:!1,configurable:!0});let as=Symbol("Request internals"),ad=tM.URL||tU.k,al=tM.parse,au=tM.format;function ac(e){return/^[a-zA-Z][a-zA-Z\d+\-.]*:/.exec(e)&&(e=new ad(e).toString()),al(e)}let am="destroy"in tL.Readable.prototype;function af(e){return"object"==typeof e&&"object"==typeof e[as]}class ah{constructor(e){var t;let a,r,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};af(e)?r=ac(e.url):(r=e&&e.href?ac(e.href):ac(`${e}`),e={});let n=i.method||e.method||"GET";if(n=n.toUpperCase(),(null!=i.body||af(e)&&null!==e.body)&&("GET"===n||"HEAD"===n))throw TypeError("Request with GET/HEAD method cannot have body");let p=null!=i.body?i.body:af(e)&&null!==e.body?t0(e):null;tJ.call(this,p,{timeout:i.timeout||e.timeout||0,size:i.size||e.size||0});let o=new ae(i.headers||e.headers||{});if(null!=p&&!o.has("Content-Type")){let e=t2(p);e&&o.append("Content-Type",e)}let s=af(e)?e.signal:null;if("signal"in i&&(s=i.signal),null!=s&&(!(a=(t=s)&&"object"==typeof t&&Object.getPrototypeOf(t))||"AbortSignal"!==a.constructor.name))throw TypeError("Expected signal to be an instanceof AbortSignal");this[as]={method:n,redirect:i.redirect||e.redirect||"follow",headers:o,parsedURL:r,signal:s},this.follow=void 0!==i.follow?i.follow:void 0!==e.follow?e.follow:20,this.compress=void 0!==i.compress?i.compress:void 0===e.compress||e.compress,this.counter=i.counter||e.counter||0,this.agent=i.agent||e.agent}get method(){return this[as].method}get url(){return au(this[as].parsedURL)}get headers(){return this[as].headers}get redirect(){return this[as].redirect}get signal(){return this[as].signal}clone(){return new ah(this)}}function av(e){Error.call(this,e),this.type="aborted",this.message=e,Error.captureStackTrace(this,this.constructor)}tJ.mixIn(ah.prototype),Object.defineProperty(ah.prototype,Symbol.toStringTag,{value:"Request",writable:!1,enumerable:!1,configurable:!0}),Object.defineProperties(ah.prototype,{method:{enumerable:!0},url:{enumerable:!0},headers:{enumerable:!0},redirect:{enumerable:!0},clone:{enumerable:!0},signal:{enumerable:!0}}),av.prototype=Object.create(Error.prototype),av.prototype.constructor=av,av.prototype.name="AbortError";let ay=tM.URL||tU.k,ag=tL.PassThrough,a_=function(e,t){let a=new ay(t).hostname,r=new ay(e).hostname;return a===r||"."===a[a.length-r.length-1]&&a.endsWith(r)};function ab(e,t){if(!ab.Promise)throw Error("native promise missing, set fetch.Promise to your favorite alternative");return tJ.Promise=ab.Promise,new ab.Promise(function(a,r){var i,n;let p,o,s,d=new ah(e,t),l=function(e){let t,a,r=e[as].parsedURL,i=new ae(e[as].headers);if(i.has("Accept")||i.set("Accept","*/*"),!r.protocol||!r.hostname)throw TypeError("Only absolute URLs are supported");if(!/^https?:$/.test(r.protocol))throw TypeError("Only HTTP(S) protocols are supported");if(e.signal&&e.body instanceof tL.Readable&&!am)throw Error("Cancellation of streamed requests with AbortSignal is not supported in node < 8");let n=null;if(null==e.body&&/^(POST|PUT)$/i.test(e.method)&&(n="0"),null!=e.body){let t=t6(e);"number"==typeof t&&(n=String(t))}n&&i.set("Content-Length",n),i.has("User-Agent")||i.set("User-Agent","node-fetch/1.0 (+https://github.com/bitinn/node-fetch)"),e.compress&&!i.has("Accept-Encoding")&&i.set("Accept-Encoding","gzip,deflate");let p=e.agent;return"function"==typeof p&&(p=p(r)),Object.assign({},r,{method:e.method,headers:(t=Object.assign({__proto__:null},i[t7]),void 0!==(a=t8(i[t7],"Host"))&&(t[a]=t[a][0]),t),agent:p})}(d),u=("https:"===l.protocol?tB:tj).request,c=d.signal,m=null,f=function(){let e=new av("The user aborted a request.");r(e),d.body&&d.body instanceof tL.Readable&&aw(d.body,e),m&&m.body&&m.body.emit("error",e)};if(c&&c.aborted)return void f();let h=function(){f(),y()},v=u(l);function y(){v.abort(),c&&c.removeEventListener("abort",h),clearTimeout(o)}c&&c.addEventListener("abort",h),d.timeout&&v.once("socket",function(e){o=setTimeout(function(){r(new tH(`network timeout at: ${d.url}`,"request-timeout")),y()},d.timeout)}),v.on("error",function(e){r(new tH(`request to ${d.url} failed, reason: ${e.message}`,"system",e)),m&&m.body&&aw(m.body,e),y()}),i=v,n=function(e){(!c||!c.aborted)&&m&&m.body&&aw(m.body,e)},i.on("socket",function(e){p=e}),i.on("response",function(e){let t=e.headers;"chunked"!==t["transfer-encoding"]||t["content-length"]||e.once("close",function(e){if(p&&p.listenerCount("data")>0&&!e){let e=Error("Premature close");e.code="ERR_STREAM_PREMATURE_CLOSE",n(e)}})}),14>parseInt(process.version.substring(1))&&v.on("socket",function(e){e.addListener("close",function(t){let a=e.listenerCount("data")>0;if(m&&a&&!t&&!(c&&c.aborted)){let e=Error("Premature close");e.code="ERR_STREAM_PREMATURE_CLOSE",m.body.emit("error",e)}})}),v.on("response",function(e){clearTimeout(o);let t=function(e){let t=new ae;for(let a of Object.keys(e))if(!t4.test(a))if(Array.isArray(e[a]))for(let r of e[a])t3.test(r)||(void 0===t[t7][a]?t[t7][a]=[r]:t[t7][a].push(r));else t3.test(e[a])||(t[t7][a]=[e[a]]);return t}(e.headers);if(ab.isRedirect(e.statusCode)){let n=t.get("Location"),p=null;try{p=null===n?null:new ay(n,d.url).toString()}catch(e){if("manual"!==d.redirect){r(new tH(`uri requested responds with an invalid redirect URL: ${n}`,"invalid-redirect")),y();return}}switch(d.redirect){case"error":r(new tH(`uri requested responds with a redirect, redirect mode is set to error: ${d.url}`,"no-redirect")),y();return;case"manual":if(null!==p)try{t.set("Location",p)}catch(e){r(e)}break;case"follow":var i;if(null===p)break;if(d.counter>=d.follow){r(new tH(`maximum redirect reached at: ${d.url}`,"max-redirect")),y();return}let o={headers:new ae(d.headers),follow:d.follow,counter:d.counter+1,agent:d.agent,compress:d.compress,method:d.method,body:d.body,signal:d.signal,timeout:d.timeout,size:d.size};if(!a_(d.url,p)||(i=d.url,new ay(p).protocol!==new ay(i).protocol))for(let e of["authorization","www-authenticate","cookie","cookie2"])o.headers.delete(e);if(303!==e.statusCode&&d.body&&null===t6(d)){r(new tH("Cannot follow redirect with body being a readable stream","unsupported-redirect")),y();return}(303===e.statusCode||(301===e.statusCode||302===e.statusCode)&&"POST"===d.method)&&(o.method="GET",o.body=void 0,o.headers.delete("content-length")),a(ab(new ah(p,o))),y();return}}e.once("end",function(){c&&c.removeEventListener("abort",h)});let n=e.pipe(new ag),p={url:d.url,status:e.statusCode,statusText:e.statusMessage,headers:t,size:d.size,timeout:d.timeout,counter:d.counter},s=t.get("Content-Encoding");if(!d.compress||"HEAD"===d.method||null===s||204===e.statusCode||304===e.statusCode)return void a(m=new ao(n,p));let l={flush:tq.Z_SYNC_FLUSH,finishFlush:tq.Z_SYNC_FLUSH};if("gzip"==s||"x-gzip"==s)return void a(m=new ao(n=n.pipe(tq.createGunzip(l)),p));if("deflate"==s||"x-deflate"==s){let t=e.pipe(new ag);t.once("data",function(e){a(m=new ao(n=(15&e[0])==8?n.pipe(tq.createInflate()):n.pipe(tq.createInflateRaw()),p))}),t.on("end",function(){m||a(m=new ao(n,p))});return}"br"==s&&"function"==typeof tq.createBrotliDecompress?a(m=new ao(n=n.pipe(tq.createBrotliDecompress()),p)):a(m=new ao(n,p))}),null===(s=d.body)?v.end():t1(s)?s.stream().pipe(v):Buffer.isBuffer(s)?(v.write(s),v.end()):s.pipe(v)})}function aw(e,t){e.destroy?e.destroy(t):(e.emit("error",t),e.end())}ab.isRedirect=function(e){return 301===e||302===e||303===e||307===e||308===e},ab.Promise=global.Promise;var aE=i(64007);function aT(e){var t=process.env.HTTPS_PROXY||process.env.https_proxy;if(!t||!e.startsWith("https://"))return ab;var a=new aE(t);return(e,t={})=>ab(e,{...t,agent:a})}var aN=es.ApolloClient,aS=es.InMemoryCache,aO=es.HttpLink,aI=ed.o,aD={query:"query",mutation:"mutate"},aA=eo(function e(t){ep(this,e),this.baseUrl=t,this.endpoint="/api/graphql-nonauth";var a=new aO({uri:`${t}${this.endpoint}`,fetch:aT(t)});this.apolloClient=new aN({link:a,cache:new aS,defaultOptions:{query:{errorPolicy:"all",fetchPolicy:"no-cache"}}})},[{key:"checkWorkspaceOTP",value:(p=en(function*(e){var t=(0,el.default)`
|
|
1337
1337
|
query checkWorkspaceOTP($passcode: String!) {
|
|
1338
1338
|
checkWorkspaceOTP(passcode: $passcode)
|
|
1339
1339
|
}
|
|
1340
|
-
`,a=yield this.apolloClient.query({query:t,variables:{passcode:e}}),r=a.data,i=a.errors;if(i?.length>0)throw Error(i.map(({message:e})=>e).join("\n"));return r.checkWorkspaceOTP}),function(e){return p.apply(this,arguments)})},{key:"exchangeWorkspaceOTP",value:(o=
|
|
1340
|
+
`,a=yield this.apolloClient.query({query:t,variables:{passcode:e}}),r=a.data,i=a.errors;if(i?.length>0)throw Error(i.map(({message:e})=>e).join("\n"));return r.checkWorkspaceOTP}),function(e){return p.apply(this,arguments)})},{key:"exchangeWorkspaceOTP",value:(o=en(function*(e){var t=(0,el.default)`
|
|
1341
1341
|
mutation exchangeWorkspaceOTP($passcode: String!) {
|
|
1342
1342
|
exchangeWorkspaceOTP(passcode: $passcode) {
|
|
1343
1343
|
token
|
|
@@ -1345,9 +1345,9 @@ import{createRequire as e}from"node:module";let t=e(import.meta.url);import a fr
|
|
|
1345
1345
|
workspaceName
|
|
1346
1346
|
}
|
|
1347
1347
|
}
|
|
1348
|
-
`,a=yield this.apolloClient.mutate({mutation:t,variables:{passcode:e}}),r=a.data,i=a.errors;if(i?.length>0)throw Error(i.map(({message:e})=>e).join("\n"));return r.exchangeWorkspaceOTP}),function(e){return o.apply(this,arguments)})}]),
|
|
1348
|
+
`,a=yield this.apolloClient.mutate({mutation:t,variables:{passcode:e}}),r=a.data,i=a.errors;if(i?.length>0)throw Error(i.map(({message:e})=>e).join("\n"));return r.exchangeWorkspaceOTP}),function(e){return o.apply(this,arguments)})}]),ak=e=>new aA(e),ax=e=>Object.assign(Error(e.map(({message:e})=>e).join("\n")),{graphQLErrors:e}),aC="Note: OAuth workspace access is awaiting the next production server release. Until then, use workspace auth (passcode or token; CLI: `bricks auth login-workspace`).",aR=(e,t)=>{if(t?.kind!=="oauth")return e;var a=e?.message||String(e);if(!(403===(e?.statusCode||e?.networkError?.statusCode||e?.cause?.statusCode)||/\b403\b|invalid algorithm/i.test(a))||a.includes(aC))return e;var r=Error(`${a}
|
|
1349
1349
|
|
|
1350
|
-
${
|
|
1350
|
+
${aC}`);return r.cause=e,r},aV=eo(function e(t,a){var r,i=this;ep(this,e),this.baseUrl=t,this.auth=(e=>{if(!e)return null;if("string"==typeof e){var t;return{kind:"token",token:e,getHeaders:(t=en(function*(){return{authorization:`Bearer ${e}`}}),function(){return t.apply(this,arguments)})}}return e})(a),this.token=this.auth?.token,this.endpoint="/api/graphql-workspace";var n=new aO({uri:`${t}${this.endpoint}`,fetch:aT(t)}),p=aI((r=en(function*(e,{headers:t}){return{headers:{...t,...i.auth?yield i.auth.getHeaders():{}}}}),function(e,t){return r.apply(this,arguments)}));this.apolloClient=new aN({link:p.concat(n),cache:new aS,defaultOptions:{watchQuery:{errorPolicy:"all",fetchPolicy:"no-cache"},query:{errorPolicy:"all",fetchPolicy:"no-cache"}}}),this.queries=er,this.mutations=ei,this.generateMethods()},[{key:"generateMethods",value:function(){var e=this,t=t=>([a,r])=>{if(!this[a]){var i,n=(i=en(function*(i,n,p=!1){try{var o=e.apolloClient[aD[t]].bind(e.apolloClient),s=yield o({[t]:p?(0,eu.YR)(r,{FragmentDefinition(e){if("BlueprintRun"===e.typeCondition.name.value)return{...e,selectionSet:{...e.selectionSet,selections:e.selectionSet.selections.filter(e=>!["instance_id","sessions"].includes(e.name?.value))}}},VariableDefinition:e=>"instanceId"===e.variable.name.value?null:void 0,Argument:e=>"instanceId"===e.name.value?null:void 0}):r,variables:p?Object.fromEntries(Object.entries(i).filter(([e])=>"instanceId"!==e)):i,...n}),d=s.data,l=s.errors;if(l)throw ax(l);return d[a]}catch(e){var u=e.cause?.result?.errors||e.networkError?.result?.errors;if(u)throw ax(u);throw e}}),function(e,t){return i.apply(this,arguments)});this[a]=en(function*(t={},r={}){try{return yield n(t,r)}catch(p){let i;if(/blueprint/i.test(a)&&(i=p.message,/Unknown argument "instanceId".*acquireBlueprintRun|Cannot query field "(?:instance_id|sessions)" on type "BlueprintRun"/.test(i)))return n(t,r,!0);if(e.auth?.kind==="oauth"&&e.auth.refresh&&/401|unauthoriz|jwt expired|token.*expired|invalid.*token/i.test(p?.message||"")){yield e.auth.refresh();try{return yield n(t,r)}catch(t){throw aR(t,e.auth)}}throw aR(p,e.auth)}})}};Object.entries(this.queries).forEach(t("query")),Object.entries(this.mutations).forEach(t("mutation"))}},{key:"query",value:(s=en(function*(e,t={}){var a=yield this.apolloClient.query({query:e,variables:t,fetchPolicy:"no-cache"}),r=a.data,i=a.errors;if(i?.length>0)throw ax(i);return r}),function(e){return s.apply(this,arguments)})},{key:"mutate",value:(d=en(function*(e,t={}){var a=yield this.apolloClient.mutate({mutation:e,variables:t}),r=a.data,i=a.errors;if(i?.length>0)throw ax(i);return r}),function(e){return d.apply(this,arguments)})}]),aF=(e,t)=>new aV(e,t),a$=es.ApolloClient,aP=es.InMemoryCache,aL=es.HttpLink,aj=ed.o,aM=eo(function e(t,a){ep(this,e),this.baseUrl=t,this.endpoint="/api/graphql";var r,i=new aL({uri:`${t}${this.endpoint}`,fetch:aT(t)}),n=aj((r=en(function*(e,{headers:t}){return{headers:{...t,authorization:`Bearer ${yield a()}`}}}),function(e,t){return r.apply(this,arguments)}));this.apolloClient=new a$({link:n.concat(i),cache:new aP,defaultOptions:{query:{errorPolicy:"all",fetchPolicy:"no-cache"}}})},[{key:"workspaces",value:(l=en(function*(){for(var e=(0,el.default)`
|
|
1351
1351
|
query cliWorkspaces($paginate: Paginate) {
|
|
1352
1352
|
workspaces(paginate: $paginate) {
|
|
1353
1353
|
_id
|
|
@@ -1364,7 +1364,7 @@ ${ax}`);return r.cause=e,r},aR=ep(function e(t,a){var r,i=this;en(this,e),this.b
|
|
|
1364
1364
|
}
|
|
1365
1365
|
}
|
|
1366
1366
|
}
|
|
1367
|
-
`,t=[],a=0;;a+=100){var r=yield this.apolloClient.query({query:e,variables:{paginate:{limit:100,offset:a}}}),i=r.data,n=r.errors;if(n?.length>0)throw Error(n.map(({message:e})=>e).join("\n"));var p=i.workspaces||[];if(t.push(...p),p.length<100)return t}}),function(){return l.apply(this,arguments)})},{key:"createWorkspace",value:(u=
|
|
1367
|
+
`,t=[],a=0;;a+=100){var r=yield this.apolloClient.query({query:e,variables:{paginate:{limit:100,offset:a}}}),i=r.data,n=r.errors;if(n?.length>0)throw Error(n.map(({message:e})=>e).join("\n"));var p=i.workspaces||[];if(t.push(...p),p.length<100)return t}}),function(){return l.apply(this,arguments)})},{key:"createWorkspace",value:(u=en(function*({name:e,description:t}){var a=(0,el.default)`
|
|
1368
1368
|
mutation cliCreateWorkspace($name: String, $description: String) {
|
|
1369
1369
|
createWorkspace(name: $name, description: $description) {
|
|
1370
1370
|
_id
|
|
@@ -1381,7 +1381,7 @@ ${ax}`);return r.cause=e,r},aR=ep(function e(t,a){var r,i=this;en(this,e),this.b
|
|
|
1381
1381
|
}
|
|
1382
1382
|
}
|
|
1383
1383
|
}
|
|
1384
|
-
`,r=yield this.apolloClient.mutate({mutation:a,variables:{name:e,description:t},errorPolicy:"all",fetchPolicy:"no-cache"}),i=r.data,n=r.errors;if(n?.length>0)throw Error(n.map(({message:e})=>e).join("\n"));return i.createWorkspace}),function(e){return u.apply(this,arguments)})},{key:"updateWorkspaceTokens",value:(c=
|
|
1384
|
+
`,r=yield this.apolloClient.mutate({mutation:a,variables:{name:e,description:t},errorPolicy:"all",fetchPolicy:"no-cache"}),i=r.data,n=r.errors;if(n?.length>0)throw Error(n.map(({message:e})=>e).join("\n"));return i.createWorkspace}),function(e){return u.apply(this,arguments)})},{key:"updateWorkspaceTokens",value:(c=en(function*({id:e,tokens:t}){var a=(0,el.default)`
|
|
1385
1385
|
mutation cliUpdateWorkspaceTokens($id: ID!, $tokens: [WorkspaceTokenInput]) {
|
|
1386
1386
|
updateWorkspaceTokens(id: $id, tokens: $tokens) {
|
|
1387
1387
|
newTokens {
|
|
@@ -1390,7 +1390,7 @@ ${ax}`);return r.cause=e,r},aR=ep(function e(t,a){var r,i=this;en(this,e),this.b
|
|
|
1390
1390
|
}
|
|
1391
1391
|
}
|
|
1392
1392
|
}
|
|
1393
|
-
`,r=yield this.apolloClient.mutate({mutation:a,variables:{id:e,tokens:t},errorPolicy:"all",fetchPolicy:"no-cache"}),i=r.data,n=r.errors;if(n?.length>0)throw Error(n.map(({message:e})=>e).join("\n"));return i.updateWorkspaceTokens.newTokens}),function(e){return c.apply(this,arguments)})}]),aM=(e,t)=>new aj(e,t),aU=i(68832);let aB=t("node:fs/promises"),aq=t("node:path"),aQ=t("node:dgram"),aY=t("node:os");var aG=()=>Math.random().toString(36).slice(2,9),az=new Set(["ANNOUNCE","RESPONSE"]),aH=(e,t)=>{var a=JSON.parse(e.toString());return t(a)&&az.has(a.t)&&a.d?.info||null},aW=()=>{var e=[];for(var t of Object.values(aY.networkInterfaces()))for(var a of t)if(function(){if("IPv4"!==a.family||a.internal)return 1;var t=a.address.split(".").map(Number),r=a.netmask.split(".").map(Number),i=t.map((e,t)=>(e|255&~r[t]).toString()).join(".");e.push({address:a.address,broadcast:i})}())continue;return e},aK=({port:e,timeout:t=3e3,idleTimeout:a=0,buildQuery:r,parseMessage:i})=>new Promise((n,p)=>{var o=new Map,s=aQ.createSocket("udp4"),d=null,l=null,u=!1,c=e=>{if(!u){u=!0,clearTimeout(d),clearTimeout(l);try{s.close()}catch{}e?p(e):n([...o.values()])}};s.on("error",c),s.on("message",(e,t)=>{if(!u)try{var r=i(e,t);if(!r||o.has(r.key))return;o.set(r.key,r.value),a&&!u&&(clearTimeout(l),l=setTimeout(c,a))}catch{}});try{s.bind(()=>{if(!u)try{s.setBroadcast(!0);var a=r();for(var i of(()=>{var e=new Set(["255.255.255.255","127.0.0.1"]);for(var t of aW())e.add(t.broadcast);return[...e]})())s.send(a,0,a.length,e,i);d=setTimeout(c,t)}catch(e){c(e)}})}catch(e){c(e)}}),aJ=(m=ei(function*(e,t=3e3){var a,r=new AbortController;try{a=setTimeout(()=>r.abort(),t);var i=yield fetch(e,{signal:r.signal});if(!i.ok)return null;return yield i.json()}catch{return null}finally{void 0!==a&&clearTimeout(a),r.abort()}}),function(e){return m.apply(this,arguments)}),aZ="bricks-devtools",aX=(f=ei(function*({port:e=19851,connectTimeout:t=500,concurrency:a=50,timeout:r=0}={}){var i=aW();if(0===i.length)return[];var n=[],p=r>0?Date.now()+r:0,o=[],s=new Set;for(var d of i){var l=d.address.split(".").slice(0,3).join(".");if(!s.has(l)){s.add(l);for(var u=1;u<255;u++)o.push(`${l}.${u}`)}}for(var c=0;c<o.length&&!(p&&Date.now()>=p);c+=a){var m=o.slice(c,c+a);yield Promise.allSettled(m.map(function(){var a=ei(function*(a){var r=yield a1(a,e,t);r&&n.push({...r,address:a,port:e})});return function(e){return a.apply(this,arguments)}}()))}return n}),function(){return f.apply(this,arguments)}),a1=(h=ei(function*(e,t,a=3e3){return aJ(`http://${e}:${t}/devtools/info`,a)}),function(e,t){return h.apply(this,arguments)}),a0=(v=ei(function*(e,t,a=3e3){return aJ(`http://${e}:${t}/json/list`,a)}),function(e,t){return v.apply(this,arguments)}),a2=(y=ei(function*(e,t=1e3){for(var a=[],r=e,i=0;i<10;i++){var n=aq.join(r,".bricks","devtools.json");try{var p=yield aB.readFile(n,"utf8"),o=JSON.parse(p),s=yield a1(o.address||"localhost",o.port,t);s&&a.push({name:o.name||"BRICKS Simulator",address:o.address||"localhost",port:o.port,protocols:["cdp"],hasPasscode:!1,source:"project",projectPath:r,...s})}catch{}var d=aq.dirname(r);if(d===r)break;r=d}return a}),function(e){return y.apply(this,arguments)}),a6=(g=ei(function*({timeout:e=3e3,verify:t=!1,udpOnly:a=!1,project:r=!0,port:i=19851,cwd:n=process.cwd(),onStatus:p}={}){var o,s=(({timeout:e=3e3,idleTimeout:t=0}={})=>aK({port:19900,timeout:e,idleTimeout:t,buildQuery:()=>Buffer.from(JSON.stringify({t:"QUERY",v:"1.0",s:aZ,d:{id:`cli-${aG()}`}})),parseMessage:(e,t)=>{var a=aH(e,e=>e?.s===aZ);if(!a)return null;var r=t.address;return{key:`${r}:${a.port}`,value:{...a,address:r}}}}))({timeout:e,idleTimeout:800}),d=a?Promise.resolve([]):(p?.("Scanning via UDP + HTTP probe..."),aX({port:i,timeout:e})),l=r?a2(n,1e3):Promise.resolve([]),u=aU((yield Promise.all([s,d,l])),3),c=(e=>{var t=new Map;for(var a of e){var r=a.deviceId||`${a.address}:${a.port}`,i=t.get(r);if(!i){t.set(r,{...a,addresses:[a.address],protocols:[...a.protocols||[]]});continue}for(var n of(i.addresses.includes(a.address)||i.addresses.push(a.address),"127.0.0.1"===i.address&&"127.0.0.1"!==a.address&&(i.address=a.address),a.protocols||[]))i.protocols.includes(n)||i.protocols.push(n);for(var p of Object.entries(a)){var o=aU(p,2),s=o[0],d=o[1];null!=d&&"address"!==s&&"addresses"!==s&&"protocols"!==s&&(void 0===i[s]||null===i[s])&&(i[s]=d)}}return[...t.values()]})([...u[0],...u[1],...u[2]]);if(0===c.length)return[];if(t){p?.(`Verifying ${c.length} server(s)...`);var m,f=yield Promise.all(c.map((m=ei(function*(e){var t=yield a1(e.address,e.port);return{...e,...t||{},address:e.address,port:e.port,verified:!!t,version:t?.version||e.version}}),function(e){return m.apply(this,arguments)})));c.splice(0,c.length,...f)}return p?.("Checking chrome://inspect support..."),yield Promise.all(c.map((o=ei(function*(e){var t=yield a0(e.address,e.port);if(t){e.chromeInspect=!0;var a=(e=>{if(!e)return null;var t=e.match(/\/ws\/(.+)$/);return t?decodeURIComponent(t[1]):null})(t[0]?.webSocketDebuggerUrl);a&&(e.passcode=a)}}),function(e){return o.apply(this,arguments)}))),c}),function(){return g.apply(this,arguments)}),a4=i(67996),a3=i(76982);let a9=t("fs"),a5=t("path");var a8=i(70857);function a7(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var a=e[Symbol.toPrimitive];if(void 0!==a){var r=a.call(e,t||"default");if("object"!=typeof r)return r;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}var re=a5.join(a8.homedir(),".bricks-cli"),rt=a5.join(re,"config.json"),ra=`${rt}.lock`,rr=`${rt}.oauth-refresh.lock`,ri=new Int32Array(new SharedArrayBuffer(4)),rn=e=>new Promise(t=>setTimeout(t,e)),rp=e=>{if(!Number.isInteger(e)||e<=0)return!1;try{return process.kill(e,0),!0}catch(e){return"ESRCH"!==e.code}},ro=e=>{try{var t=a9.readFileSync(e,"utf8"),a=a9.statSync(e),r=null;try{var i=JSON.parse(t);Number.isInteger(i?.pid)&&"string"==typeof i?.nonce&&(r=i)}catch{}return{raw:t,stat:a,owner:r}}catch(e){if("ENOENT"===e.code)return null;throw e}},rs=e=>{var t,a=ro(e);if(!a)return!0;var r=a.owner?!rp(a.owner.pid):Date.now()-a.stat.mtimeMs>1e3;if(!r)return!1;var i=`${e}.recovery`;try{t=rd(i)}catch(e){if("EEXIST"===e.code)return!1;throw e}try{if(!(a=ro(e)))return!0;if(!(r=a.owner?!rp(a.owner.pid):Date.now()-a.stat.mtimeMs>1e3))return!1;return a9.unlinkSync(e),!0}catch(e){if("ENOENT"===e.code)return!0;throw e}finally{rl(i,t)}},rd=e=>{var t,a={pid:process.pid,nonce:a3.randomUUID()},r=`${e}.${a.pid}.${a.nonce}.candidate`;try{t=a9.openSync(r,"wx",384),a9.writeFileSync(t,JSON.stringify(a)),a9.fsyncSync(t),a9.closeSync(t),t=void 0}catch(e){if(void 0!==t)try{a9.closeSync(t)}catch{}try{a9.unlinkSync(r)}catch{}throw e}try{a9.linkSync(r,e)}catch(e){try{a9.unlinkSync(r)}catch{}throw e}try{a9.unlinkSync(r)}catch(e){"ENOENT"!==e.code&&console.error(`Failed to clean up shared BRICKS lock candidate: ${e.message}`)}return{owner:a}},rl=(e,{owner:t})=>{try{var a;(a=ro(e))&&a.owner?.nonce===t.nonce&&a9.unlinkSync(e)}catch(e){"ENOENT"!==e.code&&console.error(`Failed to release shared BRICKS lock: ${e.message}`)}},ru=e=>{a9.mkdirSync(re,{recursive:!0});for(var t,a=Date.now()+5e3;!t;)try{t=rd(ra)}catch(e){if("EEXIST"!==e.code)throw e;if(rs(ra))continue;if(Date.now()>=a)throw Error(`Timed out waiting for shared BRICKS config lock: ${ra}`);Atomics.wait(ri,0,0,20)}try{return e()}finally{rl(ra,t)}},rc=(_=ei(function*(e){a9.mkdirSync(re,{recursive:!0});for(var t,a=Date.now()+5e3;!t;)try{t=rd(ra)}catch(e){if("EEXIST"!==e.code)throw e;if(rs(ra))continue;if(Date.now()>=a)throw Error(`Timed out waiting for shared BRICKS config lock: ${ra}`);yield rn(20)}try{var r=e();if(r&&"function"==typeof r.then)throw Error("Shared BRICKS config lock callbacks must be synchronous");return r}finally{rl(ra,t)}}),function(e){return _.apply(this,arguments)}),rm=(b=ei(function*(e,{timeoutMs:t=3e4}={}){a9.mkdirSync(re,{recursive:!0});for(var a,r=Date.now()+t;!a;)try{a=rd(rr)}catch(e){if("EEXIST"!==e.code)throw e;if(rs(rr))continue;if(Date.now()>=r)throw Error(`Timed out waiting for OAuth refresh lock: ${rr}`);yield rn(20)}try{return yield e()}finally{rl(rr,a)}}),function(e){return b.apply(this,arguments)}),rf=()=>new a({projectName:"bricks-cli",cwd:re,configFileMode:384,schema:{oauth:{type:"object",default:{},properties:{accessToken:{type:"string"},refreshToken:{type:["string","null"]},expiresAt:{type:"string"},user:{type:"object"},audience:{type:"string"}}},tokens:{type:"object",default:{},additionalProperties:{type:"object",properties:{type:{type:"string",enum:["oauth"]},oauthSubject:{type:"string"},token:{type:"string"},name:{type:"string"},workspaceId:{type:"string"},workspaceName:{type:"string"},workspaceBilling:{type:"object"},createdAt:{type:"string"},baseUrl:{type:"string"},activityLogBaseUrl:{type:"string"},bank:{type:"object"}}}},currentProfile:{type:"string",default:"default"},baseUrl:{type:"string",default:"https://display.bricks.tools"},activityLogBaseUrl:{type:"string",default:"https://activity-log.bricks.tools"},devtoolsTokens:{type:"object",default:{},additionalProperties:{type:"object",additionalProperties:{type:"object",properties:{token:{type:"string"},expiresAt:{type:"string"},jti:{type:"string"},workspaceId:{type:"string"}}}}}}}),rh=null,rv=null,ry=()=>rh||=rf(),rg=(w=ei(function*(){if(rh)return rh;rv||=rc(()=>rh||=rf());try{return yield rv}finally{rv=null}}),function(){return w.apply(this,arguments)}),r_=(E=ei(function*(){yield rg()}),function(){return E.apply(this,arguments)}),rb={get:e=>ry().get(e),set:(e,t)=>{var a=ry();return ru(()=>a.set(e,t))},clear:()=>{var e=ry();return ru(()=>e.clear())},setAsync:(T=ei(function*(e,t){var a=yield rg();return rc(()=>a.set(e,t))}),function(e,t){return T.apply(this,arguments)}),update:(e,t)=>{var a=ry();return ru(()=>{var r=t(a.get(e));return a.set(e,r),r})},updateAsync:(N=ei(function*(e,t){var a=yield rg();return rc(()=>{var r=t(a.get(e));return a.set(e,r),r})}),function(e,t){return N.apply(this,arguments)}),snapshot:e=>{var t=ry().store;return Object.fromEntries(e.map(e=>[e,t[e]]))},snapshotAsync:(S=ei(function*(e){var t=(yield rg()).store;return Object.fromEntries(e.map(e=>[e,t[e]]))}),function(e){return S.apply(this,arguments)}),transaction:(e,t)=>{var a=ry();return ru(()=>{var r=t(Object.fromEntries(e.map(e=>[e,a.get(e)])))||{};return Object.keys(r).length>0&&a.set(r),r})},transactionAsync:(O=ei(function*(e,t){var a=yield rg();return rc(()=>{var r=t(Object.fromEntries(e.map(e=>[e,a.get(e)])))||{};return Object.keys(r).length>0&&a.set(r),r})}),function(e,t){return O.apply(this,arguments)})},rw=(e,t,a,r)=>{if(!e)return null;var i=null==e.workspaceId?null:String(e.workspaceId);return"oauth"===e.type?e.oauthSubject&&e.oauthSubject===t?.user?.sub?{kind:"oauth",workspaceId:i,oauthSubject:e.oauthSubject,baseUrl:a,activityLogBaseUrl:r}:null:e.token?{kind:"token",workspaceId:i,token:e.token,baseUrl:a,activityLogBaseUrl:r}:null},rE=(e,t,a)=>({exists:void 0!==e,kind:e?.type==="oauth"?"oauth":e?.token?"token":"incomplete",workspaceId:e?.workspaceId==null?null:String(e.workspaceId),credential:e?.type==="oauth"?e.oauthSubject||null:e?.token||null,baseUrl:t,activityLogBaseUrl:a}),rT=(e,{tokens:t={},oauth:a,devtoolsTokens:r={},baseUrl:i,activityLogBaseUrl:n})=>{var p=t[e],o=p?.baseUrl||i,s=p?.activityLogBaseUrl||n,d=rw(p,a,o,s);return{profile:e,tokenInfo:p,oauth:a,fingerprint:d,baseline:rE(p,o,s),bank:d&&p?.bank||null,devtoolsTokens:r[e]||{},baseUrl:o,activityLogBaseUrl:s}},rN=(I=ei(function*(e="default"){return rT(e,(yield rb.snapshotAsync(["tokens","oauth","devtoolsTokens","baseUrl","activityLogBaseUrl"])))}),function(){return I.apply(this,arguments)}),rS=(e,t,a)=>{for(var r=rb.snapshot(["tokens","baseUrl","activityLogBaseUrl"]),i=r.tokens||{},n=e,p=2;;){var o=i[n];if(!o||"oauth"===o.type&&o.oauthSubject===a&&String(o.workspaceId)===String(t))break;n=`${e}-${p}`,p+=1}var s=i[n];return{profile:n,baseline:rE(s,s?.baseUrl||r.baseUrl,s?.activityLogBaseUrl||r.activityLogBaseUrl)}},rO=(e,t,a,r)=>{var i=a[e],n=i?.workspaceId&&t?.workspaceId&&String(i.workspaceId)===String(t.workspaceId),p=i?.type==="oauth"&&t?.type==="oauth"&&!!i.oauthSubject&&i.oauthSubject===t.oauthSubject||i?.type!=="oauth"&&t?.type!=="oauth"&&!!i?.token&&i.token===t?.token,o=n&&p,s={tokens:{...a,[e]:{...i?.baseUrl?{baseUrl:i.baseUrl}:{},...i?.activityLogBaseUrl?{activityLogBaseUrl:i.activityLogBaseUrl}:{},...o&&i?.bank?{bank:i.bank}:{},...t,createdAt:new Date().toISOString()}}};if(!o&&r[e]){var d={...r};delete d[e],s.devtoolsTokens=d}return s},rI=(e,t)=>{if(e&&t?.user?.sub!==e)throw Error("OAuth account changed. Re-select the workspace for the current account.")},rD=(e,t,a,r)=>!!e&&JSON.stringify(e)===JSON.stringify(rE(t,t?.baseUrl||a,t?.activityLogBaseUrl||r)),rA=(e,t,a,{expectedOAuthSubject:r,makeCurrent:i=!1}={})=>{var n=!1;return rb.transaction(["tokens","devtoolsTokens","oauth","currentProfile","baseUrl","activityLogBaseUrl"],({tokens:p={},devtoolsTokens:o={},oauth:s,baseUrl:d,activityLogBaseUrl:l})=>{if(!rD(a,p[e],d,l))return{};rI(r,s),n=!0;var u=rO(e,t,p,o);return i?{...u,currentProfile:e}:u}),n},rk=(D=ei(function*(e,t,a,{expectedOAuthSubject:r,makeCurrent:i=!1}={}){var n=!1;return yield rb.transactionAsync(["tokens","devtoolsTokens","oauth","currentProfile","baseUrl","activityLogBaseUrl"],({tokens:p={},devtoolsTokens:o={},oauth:s,baseUrl:d,activityLogBaseUrl:l})=>{if(!rD(a,p[e],d,l))return{};rI(r,s),n=!0;var u=rO(e,t,p,o);return i?{...u,currentProfile:e}:u}),n}),function(e,t,a){return D.apply(this,arguments)}),rx=(e,t)=>{var a=!1;return rb.transaction(["tokens","devtoolsTokens"],({tokens:r={},devtoolsTokens:i={}})=>{if(n=r[e],!n||!t||String(n.workspaceId??"")!==String(t.workspaceId??"")||("oauth"===t.type?"oauth"!==n.type||n.oauthSubject!==t.oauthSubject:t.token?"oauth"===n.type||n.token!==t.token:JSON.stringify(n)!==JSON.stringify(t)))return{};a=!0;var n,p={...r};delete p[e];var o={...i};return delete o[e],{tokens:p,devtoolsTokens:o}}),a},rC=(A=ei(function*(e,t,a,r){var i=!1;return yield rb.transactionAsync(["tokens","oauth","devtoolsTokens","baseUrl","activityLogBaseUrl"],({tokens:n={},oauth:p,devtoolsTokens:o={},baseUrl:s,activityLogBaseUrl:d})=>((e,t,a,r,i)=>{if(!e)return!1;var n=rw(t,a,t?.baseUrl||r,t?.activityLogBaseUrl||i);return!!n&&n.kind===e.kind&&n.workspaceId===e.workspaceId&&n.baseUrl===e.baseUrl&&n.activityLogBaseUrl===e.activityLogBaseUrl&&("oauth"===n.kind?n.oauthSubject===e.oauthSubject:n.token===e.token)})(t,n[e],p,s,d)?(i=!0,{devtoolsTokens:{...o,[e]:{...o[e],[a]:r}}}):{}),i}),function(e,t,a,r){return A.apply(this,arguments)});ei(function*(e,t){var a=!1;return yield rb.transactionAsync(["devtoolsTokens"],({devtoolsTokens:r={}})=>{var i=r[e];if(!i?.[t])return{};a=!0,i[t];var n=a4(i,[t].map(a7));return{devtoolsTokens:{...r,[e]:n}}}),a});var rR=(e,t)=>{if(e)return t(["tokens","devtoolsTokens"],({tokens:t={},devtoolsTokens:a={}})=>{var r={...t},i=[];for(var n of Object.entries(t)){var p=aU(n,2),o=p[0],s=p[1];if(s?.type==="oauth"&&(!s.oauthSubject||s.oauthSubject===e)){i.push(o);var d={...s,oauthSubject:s.oauthSubject||e};delete d.bank,r[o]=d}}var l={...a},u=!1;return i.forEach(e=>{l[e]&&(delete l[e],u=!0)}),{tokens:r,...u?{devtoolsTokens:l}:{}}})},rV=e=>rR(e,rb.transaction),rF=e=>rR(e,rb.transactionAsync),r$=(e,t,a)=>{if(r=a.oauth,e?.accessToken?!rY(e,r):!!r?.accessToken)return{result:{installed:!1,identityChanged:!1,previous:null},updates:{}};var r,i=a.oauth?.accessToken?a.oauth:null,n=i?.user?.sub,p=!!(n&&t?.user?.sub&&n!==t.user.sub),o={installed:!0,identityChanged:p,previous:i};if(!p)return{result:o,updates:{oauth:t}};var s={...a.tokens||{}},d={...a.devtoolsTokens||{}},l=!1;for(var u of Object.entries(a.tokens||{})){var c=aU(u,2),m=c[0],f=c[1];if(f?.type==="oauth"&&(!f.oauthSubject||f.oauthSubject===n)){var h={...f,oauthSubject:f.oauthSubject||n};delete h.bank,s[m]=h,d[m]&&(delete d[m],l=!0)}}return{result:o,updates:{oauth:t,tokens:s,...l?{devtoolsTokens:d}:{}}}},rP=(e,t)=>{var a;return rb.transaction(["oauth","tokens","devtoolsTokens"],r=>{var i=r$(e,t,r);return a=i.result,i.updates}),a},rL=(k=ei(function*(e,t){var a;return yield rb.transactionAsync(["oauth","tokens","devtoolsTokens"],r=>{var i=r$(e,t,r);return a=i.result,i.updates}),a}),function(e,t){return k.apply(this,arguments)}),rj=(e="default")=>{var t=((e="default")=>rb.get("tokens")[e])(e);return t?"oauth"===t.type?"oauth":t.token?"token":null:null},rM=()=>{var e=rb.get("oauth");return e&&Object.keys(e).length>0?e:null},rU=e=>rb.set("oauth",e),rB=e=>rb.setAsync("oauth",e),rq=()=>rb.set("oauth",{}),rQ=(x=ei(function*(){var e=null;return yield rb.updateAsync("oauth",t=>(t?.accessToken&&(e=t),{})),e}),function(){return x.apply(this,arguments)}),rY=(e,t)=>!!e&&!!t&&e.accessToken===t.accessToken&&e.refreshToken===t.refreshToken,rG=(C=ei(function*(e,t){var a=!1;return yield rb.updateAsync("oauth",r=>rY(e,r)?(a=!0,t||{}):r||{}),a}),function(e,t){return C.apply(this,arguments)}),rz=e=>rG(e,{}),rH=(R=ei(function*({client:e,ttlSeconds:t}={}){if(!e?.issueDevtoolsAccessToken)throw Error("A BRICKS workspace client is required to issue a DevTools access token.");return e.issueDevtoolsAccessToken({ttlSeconds:t})}),function(){return R.apply(this,arguments)}),rW=(V=ei(function*({profile:e,client:t,workspaceId:a,ttlSeconds:r,force:i=!1,now:n=Date.now()}={}){var p=e||process.env.BRICKS_PROFILE||rb.get("currentProfile"),o=yield rN(p),s=o.tokenInfo,d=o.fingerprint,l=o.devtoolsTokens;if(s?.type==="oauth"&&!d)throw Error(`OAuth profile ${p} belongs to a different account.`);if(!d)throw Error(`Profile ${p} is not logged in or has no workspace id.`);var u=s?.workspaceId,c=a||u;if(!c)throw Error(`Profile ${p} is not logged in or has no workspace id.`);var m=l[c];if(!i&&((e,t=Date.now())=>{if(!e?.token||!e?.expiresAt)return!1;var a=new Date(e.expiresAt).getTime();return Number.isFinite(a)&&a-t>6048e5})(m,n))return m;if(String(c)!==String(u))throw Error(`Profile ${p} has no usable DevTools token for workspace ${c}.`);var f=yield rH({client:t,ttlSeconds:r});if(!f?.token||!f?.expiresAt)throw Error("DevTools access token response was incomplete.");if(f.workspaceId&&String(f.workspaceId)!==String(c))throw Error("DevTools access token was issued for a different workspace.");var h={token:f.token,expiresAt:f.expiresAt,jti:f.jti,workspaceId:f.workspaceId||c};if(!(yield rC(p,d,c,h)))throw Error(`Profile ${p} changed while issuing the DevTools token. Retry.`);return h}),function(){return V.apply(this,arguments)});let rK=t("node:crypto");i(27549);var rJ=8089,rZ=(F=ei(function*(e,t,a=3e3){return aJ(`http://${e}:${t}/buttress/info`,a)}),function(e,t){return F.apply(this,arguments)}),rX=(0,ed.default)`
|
|
1393
|
+
`,r=yield this.apolloClient.mutate({mutation:a,variables:{id:e,tokens:t},errorPolicy:"all",fetchPolicy:"no-cache"}),i=r.data,n=r.errors;if(n?.length>0)throw Error(n.map(({message:e})=>e).join("\n"));return i.updateWorkspaceTokens.newTokens}),function(e){return c.apply(this,arguments)})}]),aU=(e,t)=>new aM(e,t),aB=i(68832);let aq=t("node:fs/promises"),aQ=t("node:path"),aY=t("node:dgram"),aG=t("node:os");var az=()=>Math.random().toString(36).slice(2,9),aH=new Set(["ANNOUNCE","RESPONSE"]),aW=(e,t)=>{var a=JSON.parse(e.toString());return t(a)&&aH.has(a.t)&&a.d?.info||null},aK=()=>{var e=[];for(var t of Object.values(aG.networkInterfaces()))for(var a of t)if(function(){if("IPv4"!==a.family||a.internal)return 1;var t=a.address.split(".").map(Number),r=a.netmask.split(".").map(Number),i=t.map((e,t)=>(e|255&~r[t]).toString()).join(".");e.push({address:a.address,broadcast:i})}())continue;return e},aJ=({port:e,timeout:t=3e3,idleTimeout:a=0,buildQuery:r,parseMessage:i})=>new Promise((n,p)=>{var o=new Map,s=aY.createSocket("udp4"),d=null,l=null,u=!1,c=e=>{if(!u){u=!0,clearTimeout(d),clearTimeout(l);try{s.close()}catch{}e?p(e):n([...o.values()])}};s.on("error",c),s.on("message",(e,t)=>{if(!u)try{var r=i(e,t);if(!r||o.has(r.key))return;o.set(r.key,r.value),a&&!u&&(clearTimeout(l),l=setTimeout(c,a))}catch{}});try{s.bind(()=>{if(!u)try{s.setBroadcast(!0);var a=r();for(var i of(()=>{var e=new Set(["255.255.255.255","127.0.0.1"]);for(var t of aK())e.add(t.broadcast);return[...e]})())s.send(a,0,a.length,e,i);d=setTimeout(c,t)}catch(e){c(e)}})}catch(e){c(e)}}),aZ=(m=en(function*(e,t=3e3){var a,r=new AbortController;try{a=setTimeout(()=>r.abort(),t);var i=yield fetch(e,{signal:r.signal});if(!i.ok)return null;return yield i.json()}catch{return null}finally{void 0!==a&&clearTimeout(a),r.abort()}}),function(e){return m.apply(this,arguments)}),aX="bricks-devtools",a1=(f=en(function*({port:e=19851,connectTimeout:t=500,concurrency:a=50,timeout:r=0}={}){var i=aK();if(0===i.length)return[];var n=[],p=r>0?Date.now()+r:0,o=[],s=new Set;for(var d of i){var l=d.address.split(".").slice(0,3).join(".");if(!s.has(l)){s.add(l);for(var u=1;u<255;u++)o.push(`${l}.${u}`)}}for(var c=0;c<o.length&&!(p&&Date.now()>=p);c+=a){var m=o.slice(c,c+a);yield Promise.allSettled(m.map(function(){var a=en(function*(a){var r=yield a0(a,e,t);r&&n.push({...r,address:a,port:e})});return function(e){return a.apply(this,arguments)}}()))}return n}),function(){return f.apply(this,arguments)}),a0=(h=en(function*(e,t,a=3e3){return aZ(`http://${e}:${t}/devtools/info`,a)}),function(e,t){return h.apply(this,arguments)}),a2=(v=en(function*(e,t,a=3e3){return aZ(`http://${e}:${t}/json/list`,a)}),function(e,t){return v.apply(this,arguments)}),a6=(y=en(function*(e,t=1e3){for(var a=[],r=e,i=0;i<10;i++){var n=aQ.join(r,".bricks","devtools.json");try{var p=yield aq.readFile(n,"utf8"),o=JSON.parse(p),s=yield a0(o.address||"localhost",o.port,t);s&&a.push({name:o.name||"BRICKS Simulator",address:o.address||"localhost",port:o.port,protocols:["cdp"],hasPasscode:!1,source:"project",projectPath:r,...s})}catch{}var d=aQ.dirname(r);if(d===r)break;r=d}return a}),function(e){return y.apply(this,arguments)}),a4=(g=en(function*({timeout:e=3e3,verify:t=!1,udpOnly:a=!1,project:r=!0,port:i=19851,cwd:n=process.cwd(),onStatus:p}={}){var o,s=(({timeout:e=3e3,idleTimeout:t=0}={})=>aJ({port:19900,timeout:e,idleTimeout:t,buildQuery:()=>Buffer.from(JSON.stringify({t:"QUERY",v:"1.0",s:aX,d:{id:`cli-${az()}`}})),parseMessage:(e,t)=>{var a=aW(e,e=>e?.s===aX);if(!a)return null;var r=t.address;return{key:`${r}:${a.port}`,value:{...a,address:r}}}}))({timeout:e,idleTimeout:800}),d=a?Promise.resolve([]):(p?.("Scanning via UDP + HTTP probe..."),a1({port:i,timeout:e})),l=r?a6(n,1e3):Promise.resolve([]),u=aB((yield Promise.all([s,d,l])),3),c=(e=>{var t=new Map;for(var a of e){var r=a.deviceId||`${a.address}:${a.port}`,i=t.get(r);if(!i){t.set(r,{...a,addresses:[a.address],protocols:[...a.protocols||[]]});continue}for(var n of(i.addresses.includes(a.address)||i.addresses.push(a.address),"127.0.0.1"===i.address&&"127.0.0.1"!==a.address&&(i.address=a.address),a.protocols||[]))i.protocols.includes(n)||i.protocols.push(n);for(var p of Object.entries(a)){var o=aB(p,2),s=o[0],d=o[1];null!=d&&"address"!==s&&"addresses"!==s&&"protocols"!==s&&(void 0===i[s]||null===i[s])&&(i[s]=d)}}return[...t.values()]})([...u[0],...u[1],...u[2]]);if(0===c.length)return[];if(t){p?.(`Verifying ${c.length} server(s)...`);var m,f=yield Promise.all(c.map((m=en(function*(e){var t=yield a0(e.address,e.port);return{...e,...t||{},address:e.address,port:e.port,verified:!!t,version:t?.version||e.version}}),function(e){return m.apply(this,arguments)})));c.splice(0,c.length,...f)}return p?.("Checking chrome://inspect support..."),yield Promise.all(c.map((o=en(function*(e){var t=yield a2(e.address,e.port);if(t){e.chromeInspect=!0;var a=(e=>{if(!e)return null;var t=e.match(/\/ws\/(.+)$/);return t?decodeURIComponent(t[1]):null})(t[0]?.webSocketDebuggerUrl);a&&(e.passcode=a)}}),function(e){return o.apply(this,arguments)}))),c}),function(){return g.apply(this,arguments)}),a3=i(67996),a9=i(76982);let a5=t("fs"),a8=t("path");var a7=i(70857);function re(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var a=e[Symbol.toPrimitive];if(void 0!==a){var r=a.call(e,t||"default");if("object"!=typeof r)return r;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}var rt=a8.join(a7.homedir(),".bricks-cli"),ra=a8.join(rt,"config.json"),rr=`${ra}.lock`,ri=`${ra}.oauth-refresh.lock`,rn=new Int32Array(new SharedArrayBuffer(4)),rp=e=>new Promise(t=>setTimeout(t,e)),ro=e=>{if(!Number.isInteger(e)||e<=0)return!1;try{return process.kill(e,0),!0}catch(e){return"ESRCH"!==e.code}},rs=e=>{try{var t=a5.readFileSync(e,"utf8"),a=a5.statSync(e),r=null;try{var i=JSON.parse(t);Number.isInteger(i?.pid)&&"string"==typeof i?.nonce&&(r=i)}catch{}return{raw:t,stat:a,owner:r}}catch(e){if("ENOENT"===e.code)return null;throw e}},rd=e=>{var t,a=rs(e);if(!a)return!0;var r=a.owner?!ro(a.owner.pid):Date.now()-a.stat.mtimeMs>1e3;if(!r)return!1;var i=`${e}.recovery`;try{t=rl(i)}catch(e){if("EEXIST"===e.code)return!1;throw e}try{if(!(a=rs(e)))return!0;if(!(r=a.owner?!ro(a.owner.pid):Date.now()-a.stat.mtimeMs>1e3))return!1;return a5.unlinkSync(e),!0}catch(e){if("ENOENT"===e.code)return!0;throw e}finally{ru(i,t)}},rl=e=>{var t,a={pid:process.pid,nonce:a9.randomUUID()},r=`${e}.${a.pid}.${a.nonce}.candidate`;try{t=a5.openSync(r,"wx",384),a5.writeFileSync(t,JSON.stringify(a)),a5.fsyncSync(t),a5.closeSync(t),t=void 0}catch(e){if(void 0!==t)try{a5.closeSync(t)}catch{}try{a5.unlinkSync(r)}catch{}throw e}try{a5.linkSync(r,e)}catch(e){try{a5.unlinkSync(r)}catch{}throw e}try{a5.unlinkSync(r)}catch(e){"ENOENT"!==e.code&&console.error(`Failed to clean up shared BRICKS lock candidate: ${e.message}`)}return{owner:a}},ru=(e,{owner:t})=>{try{var a;(a=rs(e))&&a.owner?.nonce===t.nonce&&a5.unlinkSync(e)}catch(e){"ENOENT"!==e.code&&console.error(`Failed to release shared BRICKS lock: ${e.message}`)}},rc=e=>{a5.mkdirSync(rt,{recursive:!0});for(var t,a=Date.now()+5e3;!t;)try{t=rl(rr)}catch(e){if("EEXIST"!==e.code)throw e;if(rd(rr))continue;if(Date.now()>=a)throw Error(`Timed out waiting for shared BRICKS config lock: ${rr}`);Atomics.wait(rn,0,0,20)}try{return e()}finally{ru(rr,t)}},rm=(_=en(function*(e){a5.mkdirSync(rt,{recursive:!0});for(var t,a=Date.now()+5e3;!t;)try{t=rl(rr)}catch(e){if("EEXIST"!==e.code)throw e;if(rd(rr))continue;if(Date.now()>=a)throw Error(`Timed out waiting for shared BRICKS config lock: ${rr}`);yield rp(20)}try{var r=e();if(r&&"function"==typeof r.then)throw Error("Shared BRICKS config lock callbacks must be synchronous");return r}finally{ru(rr,t)}}),function(e){return _.apply(this,arguments)}),rf=(b=en(function*(e,{timeoutMs:t=3e4}={}){a5.mkdirSync(rt,{recursive:!0});for(var a,r=Date.now()+t;!a;)try{a=rl(ri)}catch(e){if("EEXIST"!==e.code)throw e;if(rd(ri))continue;if(Date.now()>=r)throw Error(`Timed out waiting for OAuth refresh lock: ${ri}`);yield rp(20)}try{return yield e()}finally{ru(ri,a)}}),function(e){return b.apply(this,arguments)}),rh=()=>new a({projectName:"bricks-cli",cwd:rt,configFileMode:384,schema:{oauth:{type:"object",default:{},properties:{accessToken:{type:"string"},refreshToken:{type:["string","null"]},expiresAt:{type:"string"},user:{type:"object"},audience:{type:"string"}}},tokens:{type:"object",default:{},additionalProperties:{type:"object",properties:{type:{type:"string",enum:["oauth"]},oauthSubject:{type:"string"},token:{type:"string"},name:{type:"string"},workspaceId:{type:"string"},workspaceName:{type:"string"},workspaceBilling:{type:"object"},createdAt:{type:"string"},baseUrl:{type:"string"},activityLogBaseUrl:{type:"string"},bank:{type:"object"}}}},currentProfile:{type:"string",default:"default"},baseUrl:{type:"string",default:"https://display.bricks.tools"},activityLogBaseUrl:{type:"string",default:"https://activity-log.bricks.tools"},devtoolsTokens:{type:"object",default:{},additionalProperties:{type:"object",additionalProperties:{type:"object",properties:{token:{type:"string"},expiresAt:{type:"string"},jti:{type:"string"},workspaceId:{type:"string"}}}}}}}),rv=null,ry=null,rg=()=>rv||=rh(),r_=(w=en(function*(){if(rv)return rv;ry||=rm(()=>rv||=rh());try{return yield ry}finally{ry=null}}),function(){return w.apply(this,arguments)}),rb=(E=en(function*(){yield r_()}),function(){return E.apply(this,arguments)}),rw={get:e=>rg().get(e),set:(e,t)=>{var a=rg();return rc(()=>a.set(e,t))},clear:()=>{var e=rg();return rc(()=>e.clear())},setAsync:(T=en(function*(e,t){var a=yield r_();return rm(()=>a.set(e,t))}),function(e,t){return T.apply(this,arguments)}),update:(e,t)=>{var a=rg();return rc(()=>{var r=t(a.get(e));return a.set(e,r),r})},updateAsync:(N=en(function*(e,t){var a=yield r_();return rm(()=>{var r=t(a.get(e));return a.set(e,r),r})}),function(e,t){return N.apply(this,arguments)}),snapshot:e=>{var t=rg().store;return Object.fromEntries(e.map(e=>[e,t[e]]))},snapshotAsync:(S=en(function*(e){var t=(yield r_()).store;return Object.fromEntries(e.map(e=>[e,t[e]]))}),function(e){return S.apply(this,arguments)}),transaction:(e,t)=>{var a=rg();return rc(()=>{var r=t(Object.fromEntries(e.map(e=>[e,a.get(e)])))||{};return Object.keys(r).length>0&&a.set(r),r})},transactionAsync:(O=en(function*(e,t){var a=yield r_();return rm(()=>{var r=t(Object.fromEntries(e.map(e=>[e,a.get(e)])))||{};return Object.keys(r).length>0&&a.set(r),r})}),function(e,t){return O.apply(this,arguments)})},rE=(e,t,a,r)=>{if(!e)return null;var i=null==e.workspaceId?null:String(e.workspaceId);return"oauth"===e.type?e.oauthSubject&&e.oauthSubject===t?.user?.sub?{kind:"oauth",workspaceId:i,oauthSubject:e.oauthSubject,baseUrl:a,activityLogBaseUrl:r}:null:e.token?{kind:"token",workspaceId:i,token:e.token,baseUrl:a,activityLogBaseUrl:r}:null},rT=(e,t,a)=>({exists:void 0!==e,kind:e?.type==="oauth"?"oauth":e?.token?"token":"incomplete",workspaceId:e?.workspaceId==null?null:String(e.workspaceId),credential:e?.type==="oauth"?e.oauthSubject||null:e?.token||null,baseUrl:t,activityLogBaseUrl:a}),rN=(e,{tokens:t={},oauth:a,devtoolsTokens:r={},baseUrl:i,activityLogBaseUrl:n})=>{var p=t[e],o=p?.baseUrl||i,s=p?.activityLogBaseUrl||n,d=rE(p,a,o,s);return{profile:e,tokenInfo:p,oauth:a,fingerprint:d,baseline:rT(p,o,s),bank:d&&p?.bank||null,devtoolsTokens:r[e]||{},baseUrl:o,activityLogBaseUrl:s}},rS=(I=en(function*(e="default"){return rN(e,(yield rw.snapshotAsync(["tokens","oauth","devtoolsTokens","baseUrl","activityLogBaseUrl"])))}),function(){return I.apply(this,arguments)}),rO=(e,t,a)=>{for(var r=rw.snapshot(["tokens","baseUrl","activityLogBaseUrl"]),i=r.tokens||{},n=e,p=2;;){var o=i[n];if(!o||"oauth"===o.type&&o.oauthSubject===a&&String(o.workspaceId)===String(t))break;n=`${e}-${p}`,p+=1}var s=i[n];return{profile:n,baseline:rT(s,s?.baseUrl||r.baseUrl,s?.activityLogBaseUrl||r.activityLogBaseUrl)}},rI=(e,t,a,r)=>{var i=a[e],n=i?.workspaceId&&t?.workspaceId&&String(i.workspaceId)===String(t.workspaceId),p=i?.type==="oauth"&&t?.type==="oauth"&&!!i.oauthSubject&&i.oauthSubject===t.oauthSubject||i?.type!=="oauth"&&t?.type!=="oauth"&&!!i?.token&&i.token===t?.token,o=n&&p,s={tokens:{...a,[e]:{...i?.baseUrl?{baseUrl:i.baseUrl}:{},...i?.activityLogBaseUrl?{activityLogBaseUrl:i.activityLogBaseUrl}:{},...o&&i?.bank?{bank:i.bank}:{},...t,createdAt:new Date().toISOString()}}};if(!o&&r[e]){var d={...r};delete d[e],s.devtoolsTokens=d}return s},rD=(e,t)=>{if(e&&t?.user?.sub!==e)throw Error("OAuth account changed. Re-select the workspace for the current account.")},rA=(e,t,a,r)=>!!e&&JSON.stringify(e)===JSON.stringify(rT(t,t?.baseUrl||a,t?.activityLogBaseUrl||r)),rk=(e,t,a,{expectedOAuthSubject:r,makeCurrent:i=!1}={})=>{var n=!1;return rw.transaction(["tokens","devtoolsTokens","oauth","currentProfile","baseUrl","activityLogBaseUrl"],({tokens:p={},devtoolsTokens:o={},oauth:s,baseUrl:d,activityLogBaseUrl:l})=>{if(!rA(a,p[e],d,l))return{};rD(r,s),n=!0;var u=rI(e,t,p,o);return i?{...u,currentProfile:e}:u}),n},rx=(D=en(function*(e,t,a,{expectedOAuthSubject:r,makeCurrent:i=!1}={}){var n=!1;return yield rw.transactionAsync(["tokens","devtoolsTokens","oauth","currentProfile","baseUrl","activityLogBaseUrl"],({tokens:p={},devtoolsTokens:o={},oauth:s,baseUrl:d,activityLogBaseUrl:l})=>{if(!rA(a,p[e],d,l))return{};rD(r,s),n=!0;var u=rI(e,t,p,o);return i?{...u,currentProfile:e}:u}),n}),function(e,t,a){return D.apply(this,arguments)}),rC=(e,t)=>{var a=!1;return rw.transaction(["tokens","devtoolsTokens"],({tokens:r={},devtoolsTokens:i={}})=>{if(n=r[e],!n||!t||String(n.workspaceId??"")!==String(t.workspaceId??"")||("oauth"===t.type?"oauth"!==n.type||n.oauthSubject!==t.oauthSubject:t.token?"oauth"===n.type||n.token!==t.token:JSON.stringify(n)!==JSON.stringify(t)))return{};a=!0;var n,p={...r};delete p[e];var o={...i};return delete o[e],{tokens:p,devtoolsTokens:o}}),a},rR=(A=en(function*(e,t,a,r){var i=!1;return yield rw.transactionAsync(["tokens","oauth","devtoolsTokens","baseUrl","activityLogBaseUrl"],({tokens:n={},oauth:p,devtoolsTokens:o={},baseUrl:s,activityLogBaseUrl:d})=>((e,t,a,r,i)=>{if(!e)return!1;var n=rE(t,a,t?.baseUrl||r,t?.activityLogBaseUrl||i);return!!n&&n.kind===e.kind&&n.workspaceId===e.workspaceId&&n.baseUrl===e.baseUrl&&n.activityLogBaseUrl===e.activityLogBaseUrl&&("oauth"===n.kind?n.oauthSubject===e.oauthSubject:n.token===e.token)})(t,n[e],p,s,d)?(i=!0,{devtoolsTokens:{...o,[e]:{...o[e],[a]:r}}}):{}),i}),function(e,t,a,r){return A.apply(this,arguments)});en(function*(e,t){var a=!1;return yield rw.transactionAsync(["devtoolsTokens"],({devtoolsTokens:r={}})=>{var i=r[e];if(!i?.[t])return{};a=!0,i[t];var n=a3(i,[t].map(re));return{devtoolsTokens:{...r,[e]:n}}}),a});var rV=(e,t)=>{if(e)return t(["tokens","devtoolsTokens"],({tokens:t={},devtoolsTokens:a={}})=>{var r={...t},i=[];for(var n of Object.entries(t)){var p=aB(n,2),o=p[0],s=p[1];if(s?.type==="oauth"&&(!s.oauthSubject||s.oauthSubject===e)){i.push(o);var d={...s,oauthSubject:s.oauthSubject||e};delete d.bank,r[o]=d}}var l={...a},u=!1;return i.forEach(e=>{l[e]&&(delete l[e],u=!0)}),{tokens:r,...u?{devtoolsTokens:l}:{}}})},rF=e=>rV(e,rw.transaction),r$=e=>rV(e,rw.transactionAsync),rP=(e,t,a)=>{if(r=a.oauth,e?.accessToken?!rG(e,r):!!r?.accessToken)return{result:{installed:!1,identityChanged:!1,previous:null},updates:{}};var r,i=a.oauth?.accessToken?a.oauth:null,n=i?.user?.sub,p=!!(n&&t?.user?.sub&&n!==t.user.sub),o={installed:!0,identityChanged:p,previous:i};if(!p)return{result:o,updates:{oauth:t}};var s={...a.tokens||{}},d={...a.devtoolsTokens||{}},l=!1;for(var u of Object.entries(a.tokens||{})){var c=aB(u,2),m=c[0],f=c[1];if(f?.type==="oauth"&&(!f.oauthSubject||f.oauthSubject===n)){var h={...f,oauthSubject:f.oauthSubject||n};delete h.bank,s[m]=h,d[m]&&(delete d[m],l=!0)}}return{result:o,updates:{oauth:t,tokens:s,...l?{devtoolsTokens:d}:{}}}},rL=(e,t)=>{var a;return rw.transaction(["oauth","tokens","devtoolsTokens"],r=>{var i=rP(e,t,r);return a=i.result,i.updates}),a},rj=(k=en(function*(e,t){var a;return yield rw.transactionAsync(["oauth","tokens","devtoolsTokens"],r=>{var i=rP(e,t,r);return a=i.result,i.updates}),a}),function(e,t){return k.apply(this,arguments)}),rM=(e="default")=>{var t=((e="default")=>rw.get("tokens")[e])(e);return t?"oauth"===t.type?"oauth":t.token?"token":null:null},rU=()=>{var e=rw.get("oauth");return e&&Object.keys(e).length>0?e:null},rB=e=>rw.set("oauth",e),rq=e=>rw.setAsync("oauth",e),rQ=()=>rw.set("oauth",{}),rY=(x=en(function*(){var e=null;return yield rw.updateAsync("oauth",t=>(t?.accessToken&&(e=t),{})),e}),function(){return x.apply(this,arguments)}),rG=(e,t)=>!!e&&!!t&&e.accessToken===t.accessToken&&e.refreshToken===t.refreshToken,rz=(C=en(function*(e,t){var a=!1;return yield rw.updateAsync("oauth",r=>rG(e,r)?(a=!0,t||{}):r||{}),a}),function(e,t){return C.apply(this,arguments)}),rH=e=>rz(e,{}),rW=(R=en(function*({client:e,ttlSeconds:t}={}){if(!e?.issueDevtoolsAccessToken)throw Error("A BRICKS workspace client is required to issue a DevTools access token.");return e.issueDevtoolsAccessToken({ttlSeconds:t})}),function(){return R.apply(this,arguments)}),rK=(V=en(function*({profile:e,client:t,workspaceId:a,ttlSeconds:r,force:i=!1,now:n=Date.now()}={}){var p=e||process.env.BRICKS_PROFILE||rw.get("currentProfile"),o=yield rS(p),s=o.tokenInfo,d=o.fingerprint,l=o.devtoolsTokens;if(s?.type==="oauth"&&!d)throw Error(`OAuth profile ${p} belongs to a different account.`);if(!d)throw Error(`Profile ${p} is not logged in or has no workspace id.`);var u=s?.workspaceId,c=a||u;if(!c)throw Error(`Profile ${p} is not logged in or has no workspace id.`);var m=l[c];if(!i&&((e,t=Date.now())=>{if(!e?.token||!e?.expiresAt)return!1;var a=new Date(e.expiresAt).getTime();return Number.isFinite(a)&&a-t>6048e5})(m,n))return m;if(String(c)!==String(u))throw Error(`Profile ${p} has no usable DevTools token for workspace ${c}.`);var f=yield rW({client:t,ttlSeconds:r});if(!f?.token||!f?.expiresAt)throw Error("DevTools access token response was incomplete.");if(f.workspaceId&&String(f.workspaceId)!==String(c))throw Error("DevTools access token was issued for a different workspace.");var h={token:f.token,expiresAt:f.expiresAt,jti:f.jti,workspaceId:f.workspaceId||c};if(!(yield rR(p,d,c,h)))throw Error(`Profile ${p} changed while issuing the DevTools token. Retry.`);return h}),function(){return V.apply(this,arguments)});let rJ=t("node:crypto");i(27549);var rZ=8089,rX=(F=en(function*(e,t,a=3e3){return aZ(`http://${e}:${t}/buttress/info`,a)}),function(e,t){return F.apply(this,arguments)}),r1=(0,el.default)`
|
|
1394
1394
|
query CLI_buttressRegistryCapabilities {
|
|
1395
1395
|
bindResult: __type(name: "ButtressBindResult") {
|
|
1396
1396
|
fields {
|
|
@@ -1410,13 +1410,13 @@ ${ax}`);return r.cause=e,r},aR=ep(function e(t,a){var r,i=this;en(this,e),this.b
|
|
|
1410
1410
|
}
|
|
1411
1411
|
}
|
|
1412
1412
|
}
|
|
1413
|
-
`,
|
|
1414
|
-
`,o?{mode:384}:{}),{file:e,created:o}}),ei(function*({client:e,workspaceId:t,serverId:a,name:r,withRegistry:i=!1,onNodeCredentialDropped:n}){if(!t)throw Error("A workspace-authenticated client is required to bind Buttress.");var p,o,s,d,l,u,c=yield e.issueDevtoolsAccessToken({});if("string"!=typeof c?.token||!c.token||String(c.workspaceId)!==String(t)||!(Date.parse(c.expiresAt)>Date.now()))throw Error("DevTools token response is incomplete, expired, or belongs to another workspace.");var m=(o=(p=rK.generateKeyPairSync("ed25519")).publicKey,s=p.privateKey,d=o.export({type:"spki",format:"der"}),l=s.export({type:"pkcs8",format:"der"}),u=rK.createHash("sha256").update(d).digest("hex").slice(0,16),{publicKeySpki:d.toString("base64"),privateKeyPkcs8:l.toString("base64"),kid:u}),f={serverId:a,name:r,serverPublicKey:{spkiBase64:m.publicKeySpki,kid:m.kid}},h=i?yield e.bindButtressServerWithRegistry(f):yield e.bindButtressServer(f);if(String(h.workspaceId)!==String(t))throw Error("Buttress binding response belongs to another workspace.");var v={workspace:{id:h.workspaceId,name:h.workspaceName,serverId:h.serverId,issuerPublicKey:h.issuerPublicKey.pem,kid:h.issuerPublicKey.kid,boundAt:new Date().toISOString()},serverKeyPair:m,devtools:{token:c.token,workspaceId:c.workspaceId,expiresAt:c.expiresAt,...c.jti?{jti:c.jti}:{}}};if(i){var y=((e,t=new Date().toISOString())=>{if(!e||"object"!=typeof e)return null;var a=e.issuer,r=e.audience,i=e.baseUrl,n=e.jwks;return"string"==typeof a&&"string"==typeof r&&"string"==typeof i&&Array.isArray(n?.keys)?{issuer:a,audience:r,baseUrl:i,jwks:n,fetchedAt:t}:null})(h.registry);y&&(v.registry=y);var g=(e=>{if(!e||"object"!=typeof e)return null;var t=e.token,a=e.jti,r=e.kid,i=e.issuedAt,n=e.expiresAt,p=e.renewAfter;return"string"==typeof t&&t&&"string"==typeof a&&"string"==typeof r&&[i,n,p].every(r0)?{token:t,jti:a,kid:r,issuedAt:i,expiresAt:n,renewAfter:p}:null})(h.nodeCredential),_=g&&((e,t)=>{var a,r,i,n,p,o=(e=>{try{var t=JSON.parse(Buffer.from(e.split(".")[1],"base64url").toString("utf8"));return t&&"object"==typeof t?t:null}catch{return null}})(e?.token);if(!o||"kc"!==o.k||"node"!==o.st)return"it is not a node credential";if(String(o.w_id)!==String(t?.workspace?.id)||o.sid!==t?.workspace?.serverId)return"it belongs to another workspace or server";var s=null;try{a=t.serverKeyPair.publicKeySpki,i=(r=rK.createPublicKey({key:Buffer.from(a,"base64"),format:"der",type:"spki"}).export({format:"jwk"})).crv,n=r.kty,p=r.x,s=rK.createHash("sha256").update(JSON.stringify({crv:i,kty:n,x:p})).digest("base64url")}catch{return"the local state has no usable announce key"}return o.cnf?.jkt!==s?"it is bound to another announce key":null})(g,v);_?n?.(_):g&&(v.nodeCredential=g)}return v});var r4=($=ei(function*(e){var t=r6(e);try{var a=yield aB.readFile(t,"utf8");return JSON.parse(a)}catch(e){if(e instanceof SyntaxError)throw Error("Buttress state.json contains invalid JSON.");if("ENOENT"===e.code)return null;throw e}}),function(e){return $.apply(this,arguments)});ei(function*(e,t){var a=t||r2,r=r6(t);yield aB.mkdir(a,{recursive:!0,mode:448}),yield aB.chmod(a,448);var i=`${r}.tmp-${process.pid}-${rK.randomUUID()}`;try{yield aB.writeFile(i,JSON.stringify(e,null,2),{encoding:"utf8",mode:384}),yield aB.chmod(i,384),yield aB.rename(i,r),yield aB.chmod(r,384)}catch(e){throw yield aB.unlink(i).catch(()=>{}),e}return r});var r3=(P=ei(function*(e){var t=r6(e);try{return yield aB.unlink(t),!0}catch(e){if("ENOENT"===e.code)return!1;throw e}}),function(e){return P.apply(this,arguments)});ei(function*({client:e,serverId:t,workspaceId:a,stateDir:r,keepLocal:i=!1}){var n=i?null:yield r4(r),p=!i&&((e,t,a)=>{if(e?.workspace?.serverId!==t)return!1;var r=e.workspace.id;if(!r||!a||String(r)!==String(a))throw Error(`Local Buttress state belongs to workspace ${r||"unknown"}, but the current profile targets ${a||"unknown"}. Switch profiles first.`);return!0})(n,t,a);return{removed:yield e.unbindButtressServer({serverId:t}),localRemoved:!!p&&(yield r3(r))}});var r9=(L=ei(function*({timeout:e=3e3,verify:t=!0,port:a=rJ,onStatus:r}={}){r?.(`Scanning UDP ${a} for ${e}ms...`);var i,n=yield(({timeout:e=3e3,idleTimeout:t=0,port:a=rJ}={})=>aK({port:a,timeout:e,idleTimeout:t,buildQuery:()=>Buffer.from(JSON.stringify({t:"QUERY",v:"2.0",d:{id:`cli-${aG()}`}})),parseMessage:(e,t)=>{var a=aH(e,e=>e?.v==="2.0");if(!a)return null;var r={...a,address:t.address};return{key:r.id||`${t.address}:${r.port}`,value:r}}}))({timeout:e,port:a});return 0===n.length?[]:t?(r?.(`Verifying ${n.length} server(s)...`),yield Promise.all(n.map((i=ei(function*(e){var t=yield rZ(e.address,e.port,2e3);return t?{...e,...t,address:e.address,verified:!0}:{...e,verified:!1}}),function(e){return i.apply(this,arguments)})))):n}),function(){return L.apply(this,arguments)}),r5=i(63315),r8=i(30409),r7=i(40906),ie=i(59410);let it=t("node:fs");var ia=e=>e?.meta?.originalFileKey||null,ir=(e,t)=>{var a=ia(e);return!!a&&!0===e.meta.originalFileUploaded&&a!==ia(t)},ii=(e,t)=>{var a=t&&ia(e)===ia(t)?t:e;return a?.updatedAt||a?.createdAt||null};function ip(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(ip=function(){return!!e})()}var io=e=>e?.media_resource?.enable_media_workspace!==!0?null:e.media_resource?.system_media_box_id||null,is=(j=ei(function*(e,t,a,r){var i=yield e.mediaFiles({boxId:t,userTags:[`bricks_screenshot_${a}`],limit:1},r);return i?.[0]||null}),function(e,t,a,r){return j.apply(this,arguments)}),id=function(e){function t(e,a){var r,i,n;return en(this,t),i=t,n=[`Timed out after ${e} s while ${a}`],i=r8(i),(r=r5(this,ip()?Reflect.construct(i,n||[],r8(this).constructor):i.apply(this,n))).name="ScreenshotTimeoutError",r}return r7(t,e),ep(t)}(ie(Error)),il=Symbol("screenshot-timed-out"),iu=[{format:"PNG",contentType:"image/png",extensions:[".png"],test:e=>e.length>=8&&0x89504e47===e.readUInt32BE(0)&&0xd0a1a0a===e.readUInt32BE(4)},{format:"JPEG",contentType:"image/jpeg",extensions:[".jpg",".jpeg"],test:e=>e.length>=3&&255===e[0]&&216===e[1]&&255===e[2]},{format:"WebP",contentType:"image/webp",extensions:[".webp"],test:e=>e.length>=12&&"RIFF"===e.toString("latin1",0,4)&&"WEBP"===e.toString("latin1",8,12)},{format:"GIF",contentType:"image/gif",extensions:[".gif"],test:e=>e.length>=6&&/^GIF8[79]a$/.test(e.toString("latin1",0,6))}],ic=(M=ei(function*(e,t=null,{signal:a}={}){var r,i=new AbortController,n=()=>i.abort();a?.addEventListener("abort",n,{once:!0});try{var p=yield a_(e,{signal:i.signal});if(!p.ok)throw Error(`Failed to download screenshot: ${p.statusText}`);r=yield p.buffer()}finally{a?.removeEventListener("abort",n),i.abort()}var o=(e=>{var t=iu.find(({test:t})=>t(e));if(!t)return null;var a=t.format;return{format:a,contentType:t.contentType,extensions:t.extensions}})(r),s=o?o.extensions[0]:".bin",d=t||aq.join(aY.tmpdir(),`bricks-screenshot-${Date.now()}${s}`),l=aq.dirname(d);return it.existsSync(l)||it.mkdirSync(l,{recursive:!0}),it.writeFileSync(d,r),{path:d,buffer:r,detected:o}}),function(e){return M.apply(this,arguments)}),im=(U=ei(function*(e,t,{deadline:a,preferThumbnail:r}){var i=((e,{preferThumbnail:t=!1}={})=>{if(!e?.meta?.storageEndpoint)return null;var a=e.meta,r=a.storageEndpoint,i=a.originalFileKey,n=(t?(e=>{var t=e?.meta;if(!t)return null;if("Video"===e.fileType&&t.videoThumbOriginalFileKey)return t.videoThumbOriginalFileKey;var a=t.imageVersions||[];if(!Array.isArray(a)||0===a.length)return null;var r=a.filter(e=>e?.strategy==="BOUNDED"&&"number"==typeof e.width).sort((e,t)=>e.width-t.width);return(r[0]||a[0])?.key||null})(e):null)||i;return n?`${r}/${n}`:null})(e,{preferThumbnail:r});if(!i)return{error:"Could not build screenshot URL"};var n=ic(i,t,{signal:a?.signal}),p=yield a?a.run(n,"downloading the screenshot"):n;return{path:p.path,file:e,url:i,bytes:p.buffer.length,format:p.detected?.format||null,contentType:p.detected?.contentType||null,...((e,t)=>{if(!t)return{extensionMatches:null,warning:null};var a=aq.extname(e).toLowerCase();return t.extensions.includes(a)?{extensionMatches:!0,warning:null}:{extensionMatches:!1,warning:`Saved ${t.format} data to ${e}; use a ${t.extensions[0]} name to match`}})(p.path,p.detected)}}),function(e,t,a){return U.apply(this,arguments)}),ih=(B=ei(function*(e,t,a,r=null,i={}){var n=i.deadline,p=io(t);if(!p)return{error:"Media workspace not enabled for this workspace"};var o=is(e,p,a,n?.requestOptions),s=yield n?n.run(o,"fetching the screenshot"):o;if(!s)return{error:"No screenshot available for this device"};var d=yield im(s,r,i);return d.error?d:{...d,captureRequested:!1,fresh:!1,updatedAt:ii(s,null)}}),function(e,t,a){return B.apply(this,arguments)}),iv=(q=ei(function*(e,t,a,r=null,i={}){var n=i.preferThumbnail,p=i.timeoutSeconds,o=i.maxWaitSeconds,s=void 0===o?1/0:o,d=i.signal,l=i.onStep,u=void 0===l?()=>{}:l,c=io(t);if(!c)return{error:"Media workspace not enabled for this workspace"};var m=i.deadline||((e,{signal:t}={})=>{var a=new AbortController,r=performance.now()+1e3*e,i=setTimeout(()=>a.abort(il),1e3*e),n=()=>a.abort(t.reason);t?.aborted?n():t?.addEventListener("abort",n,{once:!0});var p=a.signal,o=(t,a)=>new Promise((r,i)=>{var n=()=>i(p.reason===il?new id(e,a):p.reason);p.addEventListener("abort",n,{once:!0}),p.aborted&&n(),Promise.resolve(t).then(r,i).finally(()=>p.removeEventListener("abort",n))});return{seconds:e,signal:p,run:o,remainingMs:()=>Math.max(0,r-performance.now()),requestOptions:{context:{fetchOptions:{signal:p}}},sleep:(e,t)=>{var a;return o(new Promise(t=>{a=setTimeout(t,e)}),t).finally(()=>clearTimeout(a))},clear:()=>{clearTimeout(i),t?.removeEventListener("abort",n)}}})(void 0===p?60:p,{signal:d}),f=()=>m.run(is(e,c,a,m.requestOptions),"fetching the screenshot");try{var h=yield f();u("Sending screenshot request to device..."),yield m.run(e.controlDevice({id:a,type:"take-screenshot"},m.requestOptions),"sending the screenshot request"),u("Waiting for device to capture screenshot..."),yield m.sleep(3e3,"waiting for the device to capture");for(var v=3e3,y=yield f();!ir(y,h)&&v+2e3<=1e3*s&&m.remainingMs()>12e3;)yield m.sleep(2e3,"waiting for the device to capture"),v+=2e3,y=yield f();if(!y)return{error:"No screenshot available for this device"};var g=ir(y,h);u("Fetching screenshot...");var _=yield im(y,r,{deadline:m,preferThumbnail:n&&!g});if(_.error)return _;return{..._,captureRequested:!0,fresh:g,updatedAt:ii(y,h)}}finally{i.deadline||m.clear()}}),function(e,t,a){return q.apply(this,arguments)}),iy=i(35317),ig=i(10750),i_=e=>{try{return(0,iy.execSync)(`which ${e}`,{stdio:"ignore"}),!0}catch{return!1}},ib=(e,t,a)=>new Promise((r,i)=>{var n=[e,...t].join(" "),p=(0,iy.spawn)(n,[],{cwd:a,stdio:["pipe","ignore","pipe"],shell:!0}),o=[];p.stderr.on("data",e=>o.push(e)),p.on("close",e=>{0===e?r():i(Error(Buffer.concat(o).toString().trim()||`Command failed with code ${e}`))}),p.on("error",i)}),iw=(Q=ei(function*(e,t){try{var a=(yield i.e(7456).then(i.bind(i,79491))).format;return(yield a(t,e,{trailingComma:"all",tabWidth:2,semi:!1,singleQuote:!0,printWidth:100})).code}catch{}return e}),function(e,t){return Q.apply(this,arguments)}),iE=(Y=ei(function*(e,t){var a;return Promise.all(e.map((a=ei(function*(e){var a=a5.join(t,e.name),r=e.input;return e.formatable&&(r=yield iw(r,a)),{...e,filePath:a,content:r}}),function(e){return a.apply(this,arguments)})))}),function(e,t){return Y.apply(this,arguments)}),iT=(G=ei(function*(e,t={}){var a="function"==typeof t.onStatus?t.onStatus:()=>{},r=!1,i=!1;if(!1!==t.install&&i_("bun")){a("Installing dependencies (bun install)...");try{yield ib("bun",["install"],e),r=!0}catch{}}if(!1!==t.git&&i_("git")){a("Initializing git repository...");try{yield ib("git",["init"],e),yield ib("git",["add","."],e),yield ib("git",["-c 'user.name=BRICKS CLI'","-c 'user.email=cli@bricks.tools'","commit","-m 'chore: initialize commit'"],e),i=!0}catch{}}return{bunInstalled:r,gitInitialized:i}}),function(e){return G.apply(this,arguments)}),iN=(z=ei(function*(e,t,a){var r=a.client,i=a.output,n=a.outputAsTarget;if(!r)throw Error("client is required");if(!i)throw Error("output directory is required");var p=(e=>{for(var t=a5.resolve(e);;){if(a9.existsSync(a5.join(t,"application.json"))||a9.existsSync(a5.join(t,"module.json")))return t;var a=a5.dirname(t);if(a===t)return null;t=a}})(n?a5.dirname(a5.resolve(i)):i);if(p)throw Error(`Cannot initialize a new BRICKS project inside an existing project (${p}). Choose a directory outside the project.`);var o="application"===e?r.applicationProject:r.moduleProject,s=yield o({id:t,buildApplicationOnly:!1,setupGitHubActions:!1!==a.githubActions,setupAgents:!1!==a.agents,setupClaudeCode:!1!==a.claude,setupGeminiCLI:!0===a.gemini});if(!s?.files)throw Error(`${e} project not found`);var d=((e=[])=>{var t=e.find(e=>"application.json"===e.name);if(!t)return"bricks-ctor";try{var a=JSON.parse(t.input);return ig(a.name||"bricks-ctor")}catch{return"bricks-ctor"}})(s.files),l=n?a5.resolve(i):a5.resolve(i,d);if(a9.existsSync(l))throw Error(`Directory already exists: ${l}`);a9.mkdirSync(l,{recursive:!0}),(yield iE(s.files,l)).forEach(e=>{a9.mkdirSync(a5.dirname(e.filePath),{recursive:!0}),a9.writeFileSync(e.filePath,e.content)});var u=yield iT(l,a),c=u.bunInstalled,m=u.gitInitialized;return{success:!0,path:l,files:s.files.length,bunInstalled:c,gitInitialized:m}}),function(e,t,a){return z.apply(this,arguments)}),iS=e=>{var t=/^(v?)(\d+)\.(\d+)(?:\.(\d+))?(-[0-9A-Za-z.-]+)?(\+[0-9A-Za-z.-]+)?$/.exec(e);if(!t)return null;var a=aU(t,6),r=a[1],i=a[2],n=a[3],p=a[4],o=void 0===p?"0":p;return a[5]?`${r}${i}.${n}.${o}`:`${r}${i}.${n}.${Number(o)+1}`};function iO(e){if("string"!=typeof e)return null;var t=/^v?(\d+)\.(\d+)\.(\d+)(?:-([0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*))?(?:\+[0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*)?$/.exec(e);if(!t||t[0]!==e)return null;var a=t.slice(1,4),r=t[4]?.split(".")||[];return[...a,...r].some(e=>/^0\d+$/.test(e))?null:{core:a,prerelease:r}}var iI=(e,t)=>{var a=/^\d+$/.test(e),r=/^\d+$/.test(t);if(a!==r)return a?-1:1;var i=a?BigInt(e):e,n=r?BigInt(t):t;return i<n?-1:+(i>n)},iD=(e,t)=>{for(var a=0;a<3;a+=1){var r=iI(e.core[a],t.core[a]);if(r)return r}if(!e.prerelease.length||!t.prerelease.length)return Number(!e.prerelease.length)-Number(!t.prerelease.length);for(var i=0;i<Math.min(e.prerelease.length,t.prerelease.length);i+=1){var n=iI(e.prerelease[i],t.prerelease[i]);if(n)return n}return e.prerelease.length-t.prerelease.length};function iA(e,t=null){var a,r=(a=e.map(e=>({value:e,parsed:iO(e)})).filter(({parsed:e})=>e).sort((e,t)=>iD(t.parsed,e.parsed))[0])?{...a,next:(({core:e,prerelease:t})=>{var a=aU(e.map(BigInt),3),r=a[0],i=a[1],n=a[2];return{patch:`${r}.${i}.${t.length?n:n+1n}`,minor:`${r}.${t.length&&0n===n?i:i+1n}.0`}})(a.parsed)}:null,i=t||(r?r.next.patch:"1.0.0"),n=iO(i),p=null;return n?r&&0>=iD(n,r.parsed)&&(p=`"${i}" is not newer than the highest release version "${r.value}" (the next patch is ${r.next.patch}).`):p=`"${i}" is not a semantic version (for example 1.4.2).`,{version:i,latest:r?.value||null,problem:p}}var ik=(e,t,a)=>`Another release of "${e}" was made while the card was open (the highest version is now "${a}"), so version ${t} is not newer. Nothing was released. Call deploy_application again to approve the next version.`,ix=process.env.BRICKS_OAUTH_DOMAIN||"auth0.bricks.tools",iC=process.env.BRICKS_OAUTH_AUDIENCE||"https://display.bricks.tools",iR="openid profile email offline_access",iV=process.env.BRICKS_OAUTH_CLIENT_ID||"Atyy2gp0suIWE33rj8LtJ0pJpIGHiGaT",iF="/callback",i$="127.0.0.1",iP=()=>!!iV,iL=(e,t,{signal:a}={})=>(()=>{var e=process.env.HTTPS_PROXY||process.env.https_proxy;if(!e)return a_;var t=new aw(e);return(e,a={})=>a_(e,{...a,agent:t})})()(`https://${ix}${e}`,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:new URLSearchParams(t).toString(),signal:a}),ij=(H=ei(function*(e){var t;try{t=yield e.json()}catch(e){if(e?.name==="AbortError")throw e;t={}}if(!e.ok){var a=Error(t.error_description||t.error||`HTTP ${e.status}`);throw a.code=t.error,a}return t}),function(e){return H.apply(this,arguments)}),iM=(W=ei(function*(e,t,{signal:a}={}){var r=new AbortController,i=()=>r.abort();a?.addEventListener("abort",i,{once:!0}),a?.aborted&&i();var n=setTimeout(()=>r.abort(),15e3);try{return yield ij((yield iL(e,t,{signal:r.signal})))}finally{clearTimeout(n),a?.removeEventListener("abort",i)}}),function(e,t){return W.apply(this,arguments)}),iU=e=>{try{return JSON.parse(Buffer.from(e.split(".")[1],"base64url").toString("utf8"))}catch{return{}}},iB=e=>String(e).replaceAll("&","&").replaceAll("<","<").replaceAll(">",">").replaceAll('"',""").replaceAll("'","'"),iq=({title:e,heading:t,message:a})=>`<!doctype html>
|
|
1413
|
+
`,r0=e=>new Set((e?.fields||[]).map(({name:e})=>e));en(function*(e){var t=yield e.query(r1),a=r0(t?.bindResult);return{bindNodeCredential:a.has("nodeCredential")&&a.has("registry"),issueNodeCredential:r0(t?.__schema?.mutationType).has("issueButtressNodeCredential"),registryTrust:r0(t?.__schema?.queryType).has("registryTrust")}});var r2=e=>"string"==typeof e&&Number.isFinite(Date.parse(e)),r6=aQ.join(aG.homedir(),".bricks-cli","buttress"),r4=e=>aQ.join(e||r6,"state.json");en(function*(e,t,a){var r,i,n,p=null,o=!0;try{p=JSON.parse((yield aq.readFile(e,"utf8"))),o=!1}catch(t){if(t instanceof SyntaxError)throw Error(`${e} is not valid JSON; refusing to overwrite it.`);if("ENOENT"!==t.code)throw t}var s=(n=(i=(r=p)&&"object"==typeof r&&!Array.isArray(r)?r:{}).mcpServers&&"object"==typeof i.mcpServers&&!Array.isArray(i.mcpServers)?i.mcpServers:{},{...i,mcpServers:{...n,[t]:a}});return yield aq.writeFile(e,`${JSON.stringify(s,null,2)}
|
|
1414
|
+
`,o?{mode:384}:{}),{file:e,created:o}}),en(function*({client:e,workspaceId:t,serverId:a,name:r,withRegistry:i=!1,onNodeCredentialDropped:n}){if(!t)throw Error("A workspace-authenticated client is required to bind Buttress.");var p,o,s,d,l,u,c=yield e.issueDevtoolsAccessToken({});if("string"!=typeof c?.token||!c.token||String(c.workspaceId)!==String(t)||!(Date.parse(c.expiresAt)>Date.now()))throw Error("DevTools token response is incomplete, expired, or belongs to another workspace.");var m=(o=(p=rJ.generateKeyPairSync("ed25519")).publicKey,s=p.privateKey,d=o.export({type:"spki",format:"der"}),l=s.export({type:"pkcs8",format:"der"}),u=rJ.createHash("sha256").update(d).digest("hex").slice(0,16),{publicKeySpki:d.toString("base64"),privateKeyPkcs8:l.toString("base64"),kid:u}),f={serverId:a,name:r,serverPublicKey:{spkiBase64:m.publicKeySpki,kid:m.kid}},h=i?yield e.bindButtressServerWithRegistry(f):yield e.bindButtressServer(f);if(String(h.workspaceId)!==String(t))throw Error("Buttress binding response belongs to another workspace.");var v={workspace:{id:h.workspaceId,name:h.workspaceName,serverId:h.serverId,issuerPublicKey:h.issuerPublicKey.pem,kid:h.issuerPublicKey.kid,boundAt:new Date().toISOString()},serverKeyPair:m,devtools:{token:c.token,workspaceId:c.workspaceId,expiresAt:c.expiresAt,...c.jti?{jti:c.jti}:{}}};if(i){var y=((e,t=new Date().toISOString())=>{if(!e||"object"!=typeof e)return null;var a=e.issuer,r=e.audience,i=e.baseUrl,n=e.jwks;return"string"==typeof a&&"string"==typeof r&&"string"==typeof i&&Array.isArray(n?.keys)?{issuer:a,audience:r,baseUrl:i,jwks:n,fetchedAt:t}:null})(h.registry);y&&(v.registry=y);var g=(e=>{if(!e||"object"!=typeof e)return null;var t=e.token,a=e.jti,r=e.kid,i=e.issuedAt,n=e.expiresAt,p=e.renewAfter;return"string"==typeof t&&t&&"string"==typeof a&&"string"==typeof r&&[i,n,p].every(r2)?{token:t,jti:a,kid:r,issuedAt:i,expiresAt:n,renewAfter:p}:null})(h.nodeCredential),_=g&&((e,t)=>{var a,r,i,n,p,o=(e=>{try{var t=JSON.parse(Buffer.from(e.split(".")[1],"base64url").toString("utf8"));return t&&"object"==typeof t?t:null}catch{return null}})(e?.token);if(!o||"kc"!==o.k||"node"!==o.st)return"it is not a node credential";if(String(o.w_id)!==String(t?.workspace?.id)||o.sid!==t?.workspace?.serverId)return"it belongs to another workspace or server";var s=null;try{a=t.serverKeyPair.publicKeySpki,i=(r=rJ.createPublicKey({key:Buffer.from(a,"base64"),format:"der",type:"spki"}).export({format:"jwk"})).crv,n=r.kty,p=r.x,s=rJ.createHash("sha256").update(JSON.stringify({crv:i,kty:n,x:p})).digest("base64url")}catch{return"the local state has no usable announce key"}return o.cnf?.jkt!==s?"it is bound to another announce key":null})(g,v);_?n?.(_):g&&(v.nodeCredential=g)}return v});var r3=($=en(function*(e){var t=r4(e);try{var a=yield aq.readFile(t,"utf8");return JSON.parse(a)}catch(e){if(e instanceof SyntaxError)throw Error("Buttress state.json contains invalid JSON.");if("ENOENT"===e.code)return null;throw e}}),function(e){return $.apply(this,arguments)});en(function*(e,t){var a=t||r6,r=r4(t);yield aq.mkdir(a,{recursive:!0,mode:448}),yield aq.chmod(a,448);var i=`${r}.tmp-${process.pid}-${rJ.randomUUID()}`;try{yield aq.writeFile(i,JSON.stringify(e,null,2),{encoding:"utf8",mode:384}),yield aq.chmod(i,384),yield aq.rename(i,r),yield aq.chmod(r,384)}catch(e){throw yield aq.unlink(i).catch(()=>{}),e}return r});var r9=(P=en(function*(e){var t=r4(e);try{return yield aq.unlink(t),!0}catch(e){if("ENOENT"===e.code)return!1;throw e}}),function(e){return P.apply(this,arguments)});en(function*({client:e,serverId:t,workspaceId:a,stateDir:r,keepLocal:i=!1}){var n=i?null:yield r3(r),p=!i&&((e,t,a)=>{if(e?.workspace?.serverId!==t)return!1;var r=e.workspace.id;if(!r||!a||String(r)!==String(a))throw Error(`Local Buttress state belongs to workspace ${r||"unknown"}, but the current profile targets ${a||"unknown"}. Switch profiles first.`);return!0})(n,t,a);return{removed:yield e.unbindButtressServer({serverId:t}),localRemoved:!!p&&(yield r9(r))}});var r5=(L=en(function*({timeout:e=3e3,verify:t=!0,port:a=rZ,onStatus:r}={}){r?.(`Scanning UDP ${a} for ${e}ms...`);var i,n=yield(({timeout:e=3e3,idleTimeout:t=0,port:a=rZ}={})=>aJ({port:a,timeout:e,idleTimeout:t,buildQuery:()=>Buffer.from(JSON.stringify({t:"QUERY",v:"2.0",d:{id:`cli-${az()}`}})),parseMessage:(e,t)=>{var a=aW(e,e=>e?.v==="2.0");if(!a)return null;var r={...a,address:t.address};return{key:r.id||`${t.address}:${r.port}`,value:r}}}))({timeout:e,port:a});return 0===n.length?[]:t?(r?.(`Verifying ${n.length} server(s)...`),yield Promise.all(n.map((i=en(function*(e){var t=yield rX(e.address,e.port,2e3);return t?{...e,...t,address:e.address,verified:!0}:{...e,verified:!1}}),function(e){return i.apply(this,arguments)})))):n}),function(){return L.apply(this,arguments)}),r8=i(63315),r7=i(30409),ie=i(40906),it=i(59410);let ia=t("node:fs");var ir=e=>e<1e4?2e3:5e3,ii=e=>e?.meta?.originalFileKey||null,ip=(e,t)=>{var a=ii(e);return!!a&&!0===e.meta.originalFileUploaded&&a!==ii(t)},io=(e,t)=>{var a=t&&ii(e)===ii(t)?t:e;return a?.updatedAt||a?.createdAt||null};function is(e,t,a){return t=r7(t),r8(e,id()?Reflect.construct(t,a||[],r7(e).constructor):t.apply(e,a))}function id(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(id=function(){return!!e})()}var il=e=>e?.media_resource?.enable_media_workspace!==!0?null:e.media_resource?.system_media_box_id||null,iu=(j=en(function*(e,t,a,r){var i=yield e.mediaFiles({boxId:t,userTags:[`bricks_screenshot_${a}`],limit:1},r);return i?.[0]||null}),function(e,t,a,r){return j.apply(this,arguments)}),ic=function(e){function t(e,a){var r;return ep(this,t),(r=is(this,t,[`Timed out after ${e} s while ${a}`])).name="ScreenshotTimeoutError",r}return ie(t,e),eo(t)}(it(Error)),im=e=>`The workspace request limit was reached (one budget for every CLI, CTOR and MCP client of the workspace); try again in ${Math.max(1,Math.ceil(e/1e3))} s`,ih=function(e){function t(e,a){var r;return ep(this,t),(r=is(this,t,[im(e),{cause:a}])).name="WorkspaceRateLimitError",r.retryAfterMs=e,r}return ie(t,e),eo(t)}(it(Error)),iv=e=>{if(e instanceof ih)return e.retryAfterMs;var t=e?.graphQLErrors?.find(e=>e?.extensions?.code==="rate_limited"),a=t?.extensions.retryAfterMs;if(Number.isFinite(a)&&a>0)return a;var r=/too many requests, please try again in (\d+) seconds?/i.exec(e?.message||"");return r?1e3*Number(r[1]):t?6e4:null},iy=Symbol("screenshot-timed-out"),ig=[{format:"PNG",contentType:"image/png",extensions:[".png"],test:e=>e.length>=8&&0x89504e47===e.readUInt32BE(0)&&0xd0a1a0a===e.readUInt32BE(4)},{format:"JPEG",contentType:"image/jpeg",extensions:[".jpg",".jpeg"],test:e=>e.length>=3&&255===e[0]&&216===e[1]&&255===e[2]},{format:"WebP",contentType:"image/webp",extensions:[".webp"],test:e=>e.length>=12&&"RIFF"===e.toString("latin1",0,4)&&"WEBP"===e.toString("latin1",8,12)},{format:"GIF",contentType:"image/gif",extensions:[".gif"],test:e=>e.length>=6&&/^GIF8[79]a$/.test(e.toString("latin1",0,6))}],i_=(M=en(function*(e,t=null,{signal:a}={}){var r,i=new AbortController,n=()=>i.abort();a?.addEventListener("abort",n,{once:!0});try{var p=yield ab(e,{signal:i.signal});if(!p.ok)throw Error(`Failed to download screenshot: ${p.statusText}`);r=yield p.buffer()}finally{a?.removeEventListener("abort",n),i.abort()}var o=(e=>{var t=ig.find(({test:t})=>t(e));if(!t)return null;var a=t.format;return{format:a,contentType:t.contentType,extensions:t.extensions}})(r),s=o?o.extensions[0]:".bin",d=t||aQ.join(aG.tmpdir(),`bricks-screenshot-${Date.now()}${s}`),l=aQ.dirname(d);return ia.existsSync(l)||ia.mkdirSync(l,{recursive:!0}),ia.writeFileSync(d,r),{path:d,buffer:r,detected:o}}),function(e){return M.apply(this,arguments)}),ib=(U=en(function*(e,t,{deadline:a,preferThumbnail:r}){var i=((e,{preferThumbnail:t=!1}={})=>{if(!e?.meta?.storageEndpoint)return null;var a=e.meta,r=a.storageEndpoint,i=a.originalFileKey,n=(t?(e=>{var t=e?.meta;if(!t)return null;if("Video"===e.fileType&&t.videoThumbOriginalFileKey)return t.videoThumbOriginalFileKey;var a=t.imageVersions||[];if(!Array.isArray(a)||0===a.length)return null;var r=a.filter(e=>e?.strategy==="BOUNDED"&&"number"==typeof e.width).sort((e,t)=>e.width-t.width);return(r[0]||a[0])?.key||null})(e):null)||i;return n?`${r}/${n}`:null})(e,{preferThumbnail:r});if(!i)return{error:"Could not build screenshot URL"};var n=i_(i,t,{signal:a?.signal}),p=yield a?a.run(n,"downloading the screenshot"):n;return{path:p.path,file:e,url:i,bytes:p.buffer.length,format:p.detected?.format||null,contentType:p.detected?.contentType||null,...((e,t)=>{if(!t)return{extensionMatches:null,warning:null};var a=aQ.extname(e).toLowerCase();return t.extensions.includes(a)?{extensionMatches:!0,warning:null}:{extensionMatches:!1,warning:`Saved ${t.format} data to ${e}; use a ${t.extensions[0]} name to match`}})(p.path,p.detected)}}),function(e,t,a){return U.apply(this,arguments)}),iw=(B=en(function*(e,t,a,r=null,i={}){var n=i.deadline,p=il(t);if(!p)return{error:"Media workspace not enabled for this workspace"};var o=iu(e,p,a,n?.requestOptions),s=yield n?n.run(o,"fetching the screenshot"):o;if(!s)return{error:"No screenshot available for this device"};var d=yield ib(s,r,i);return d.error?d:{...d,captureRequested:!1,fresh:!1,updatedAt:io(s,null)}}),function(e,t,a){return B.apply(this,arguments)}),iE=(q=en(function*({latest:e,baseline:t,deadline:a,maxWaitMs:r=1/0}){var i="waiting for the device to capture";yield a.sleep(3e3,i);for(var n=3e3,p=t;;){var o=void 0,s=null;try{if(p=yield e(),ip(p,t))return{file:p,rateLimitRetryAfterMs:null};o=ir(n)}catch(e){if(null===(s=iv(e)))throw e;o=s}if(!(n+o<=r&&a.remainingMs()>1e4+o))return{file:p,rateLimitRetryAfterMs:s};yield a.sleep(o,i),n+=o}}),function(e){return q.apply(this,arguments)}),iT=(Q=en(function*(e,t,a,r=null,i={}){var n=i.preferThumbnail,p=i.timeoutSeconds,o=i.maxWaitSeconds,s=i.signal,d=i.onStep,l=void 0===d?()=>{}:d,u=il(t);if(!u)return{error:"Media workspace not enabled for this workspace"};var c=i.deadline||((e,{signal:t}={})=>{var a=new AbortController,r=performance.now()+1e3*e,i=setTimeout(()=>a.abort(iy),1e3*e),n=()=>a.abort(t.reason);t?.aborted?n():t?.addEventListener("abort",n,{once:!0});var p=a.signal,o=(t,a)=>new Promise((r,i)=>{var n=()=>i(p.reason===iy?new ic(e,a):p.reason);p.addEventListener("abort",n,{once:!0}),p.aborted&&n(),Promise.resolve(t).then(r,i).finally(()=>p.removeEventListener("abort",n))});return{seconds:e,signal:p,run:o,remainingMs:()=>Math.max(0,r-performance.now()),requestOptions:{context:{fetchOptions:{signal:p}}},sleep:(e,t)=>{var a;return o(new Promise(t=>{a=setTimeout(t,e)}),t).finally(()=>clearTimeout(a))},clear:()=>{clearTimeout(i),t?.removeEventListener("abort",n)}}})(void 0===p?60:p,{signal:s}),m=()=>c.run(iu(e,u,a,c.requestOptions),"fetching the screenshot");try{try{h=yield m(),l("Sending screenshot request to device..."),yield c.run(e.controlDevice({id:a,type:"take-screenshot"},c.requestOptions),"sending the screenshot request")}catch(e){throw f=iv(e),null===f||e instanceof ih?e:new ih(f,e)}l("Waiting for device to capture screenshot...");var f,h,v=yield iE({latest:m,baseline:h,deadline:c,maxWaitMs:1e3*(void 0===o?1/0:o)}),y=v.file,g=v.rateLimitRetryAfterMs;if(!y)return{error:null===g?"No screenshot available for this device":im(g)};var _=ip(y,h);l("Fetching screenshot...");var b=yield ib(y,r,{deadline:c,preferThumbnail:n&&!_});if(b.error)return b;return{...b,captureRequested:!0,fresh:_,updatedAt:io(y,h),rateLimitRetryAfterMs:g}}finally{i.deadline||c.clear()}}),function(e,t,a){return Q.apply(this,arguments)}),iN=i(35317),iS=i(10750),iO=e=>{try{return(0,iN.execSync)(`which ${e}`,{stdio:"ignore"}),!0}catch{return!1}},iI=(e,t,a)=>new Promise((r,i)=>{var n=[e,...t].join(" "),p=(0,iN.spawn)(n,[],{cwd:a,stdio:["pipe","ignore","pipe"],shell:!0}),o=[];p.stderr.on("data",e=>o.push(e)),p.on("close",e=>{0===e?r():i(Error(Buffer.concat(o).toString().trim()||`Command failed with code ${e}`))}),p.on("error",i)}),iD=(Y=en(function*(e,t){try{var a=(yield i.e(7456).then(i.bind(i,79491))).format;return(yield a(t,e,{trailingComma:"all",tabWidth:2,semi:!1,singleQuote:!0,printWidth:100})).code}catch{}return e}),function(e,t){return Y.apply(this,arguments)}),iA=(G=en(function*(e,t){var a;return Promise.all(e.map((a=en(function*(e){var a=a8.join(t,e.name),r=e.input;return e.formatable&&(r=yield iD(r,a)),{...e,filePath:a,content:r}}),function(e){return a.apply(this,arguments)})))}),function(e,t){return G.apply(this,arguments)}),ik=(z=en(function*(e,t={}){var a="function"==typeof t.onStatus?t.onStatus:()=>{},r=!1,i=!1;if(!1!==t.install&&iO("bun")){a("Installing dependencies (bun install)...");try{yield iI("bun",["install"],e),r=!0}catch{}}if(!1!==t.git&&iO("git")){a("Initializing git repository...");try{yield iI("git",["init"],e),yield iI("git",["add","."],e),yield iI("git",["-c 'user.name=BRICKS CLI'","-c 'user.email=cli@bricks.tools'","commit","-m 'chore: initialize commit'"],e),i=!0}catch{}}return{bunInstalled:r,gitInitialized:i}}),function(e){return z.apply(this,arguments)}),ix=(H=en(function*(e,t,a){var r=a.client,i=a.output,n=a.outputAsTarget;if(!r)throw Error("client is required");if(!i)throw Error("output directory is required");var p=(e=>{for(var t=a8.resolve(e);;){if(a5.existsSync(a8.join(t,"application.json"))||a5.existsSync(a8.join(t,"module.json")))return t;var a=a8.dirname(t);if(a===t)return null;t=a}})(n?a8.dirname(a8.resolve(i)):i);if(p)throw Error(`Cannot initialize a new BRICKS project inside an existing project (${p}). Choose a directory outside the project.`);var o="application"===e?r.applicationProject:r.moduleProject,s=yield o({id:t,buildApplicationOnly:!1,setupGitHubActions:!1!==a.githubActions,setupAgents:!1!==a.agents,setupClaudeCode:!1!==a.claude,setupGeminiCLI:!0===a.gemini});if(!s?.files)throw Error(`${e} project not found`);var d=((e=[])=>{var t=e.find(e=>"application.json"===e.name);if(!t)return"bricks-ctor";try{var a=JSON.parse(t.input);return iS(a.name||"bricks-ctor")}catch{return"bricks-ctor"}})(s.files),l=n?a8.resolve(i):a8.resolve(i,d);if(a5.existsSync(l))throw Error(`Directory already exists: ${l}`);a5.mkdirSync(l,{recursive:!0}),(yield iA(s.files,l)).forEach(e=>{a5.mkdirSync(a8.dirname(e.filePath),{recursive:!0}),a5.writeFileSync(e.filePath,e.content)});var u=yield ik(l,a),c=u.bunInstalled,m=u.gitInitialized;return{success:!0,path:l,files:s.files.length,bunInstalled:c,gitInitialized:m}}),function(e,t,a){return H.apply(this,arguments)}),iC=e=>{var t=/^(v?)(\d+)\.(\d+)(?:\.(\d+))?(-[0-9A-Za-z.-]+)?(\+[0-9A-Za-z.-]+)?$/.exec(e);if(!t)return null;var a=aB(t,6),r=a[1],i=a[2],n=a[3],p=a[4],o=void 0===p?"0":p;return a[5]?`${r}${i}.${n}.${o}`:`${r}${i}.${n}.${Number(o)+1}`};function iR(e){if("string"!=typeof e)return null;var t=/^v?(\d+)\.(\d+)\.(\d+)(?:-([0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*))?(?:\+[0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*)?$/.exec(e);if(!t||t[0]!==e)return null;var a=t.slice(1,4),r=t[4]?.split(".")||[];return[...a,...r].some(e=>/^0\d+$/.test(e))?null:{core:a,prerelease:r}}var iV=(e,t)=>{var a=/^\d+$/.test(e),r=/^\d+$/.test(t);if(a!==r)return a?-1:1;var i=a?BigInt(e):e,n=r?BigInt(t):t;return i<n?-1:+(i>n)},iF=(e,t)=>{for(var a=0;a<3;a+=1){var r=iV(e.core[a],t.core[a]);if(r)return r}if(!e.prerelease.length||!t.prerelease.length)return Number(!e.prerelease.length)-Number(!t.prerelease.length);for(var i=0;i<Math.min(e.prerelease.length,t.prerelease.length);i+=1){var n=iV(e.prerelease[i],t.prerelease[i]);if(n)return n}return e.prerelease.length-t.prerelease.length};function i$(e,t=null){var a,r=(a=e.map(e=>({value:e,parsed:iR(e)})).filter(({parsed:e})=>e).sort((e,t)=>iF(t.parsed,e.parsed))[0])?{...a,next:(({core:e,prerelease:t})=>{var a=aB(e.map(BigInt),3),r=a[0],i=a[1],n=a[2];return{patch:`${r}.${i}.${t.length?n:n+1n}`,minor:`${r}.${t.length&&0n===n?i:i+1n}.0`}})(a.parsed)}:null,i=t||(r?r.next.patch:"1.0.0"),n=iR(i),p=null;return n?r&&0>=iF(n,r.parsed)&&(p=`"${i}" is not newer than the highest release version "${r.value}" (the next patch is ${r.next.patch}).`):p=`"${i}" is not a semantic version (for example 1.4.2).`,{version:i,latest:r?.value||null,problem:p}}var iP=(e,t,a)=>`Another release of "${e}" was made while the card was open (the highest version is now "${a}"), so version ${t} is not newer. Nothing was released. Call deploy_application again to approve the next version.`,iL=process.env.BRICKS_OAUTH_DOMAIN||"auth0.bricks.tools",ij=process.env.BRICKS_OAUTH_AUDIENCE||"https://display.bricks.tools",iM="openid profile email offline_access",iU=process.env.BRICKS_OAUTH_CLIENT_ID||"Atyy2gp0suIWE33rj8LtJ0pJpIGHiGaT",iB="/callback",iq="127.0.0.1",iQ=()=>!!iU,iY=(e,t,{signal:a}={})=>(()=>{var e=process.env.HTTPS_PROXY||process.env.https_proxy;if(!e)return ab;var t=new aE(e);return(e,a={})=>ab(e,{...a,agent:t})})()(`https://${iL}${e}`,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:new URLSearchParams(t).toString(),signal:a}),iG=(W=en(function*(e){var t;try{t=yield e.json()}catch(e){if(e?.name==="AbortError")throw e;t={}}if(!e.ok){var a=Error(t.error_description||t.error||`HTTP ${e.status}`);throw a.code=t.error,a}return t}),function(e){return W.apply(this,arguments)}),iz=(K=en(function*(e,t,{signal:a}={}){var r=new AbortController,i=()=>r.abort();a?.addEventListener("abort",i,{once:!0}),a?.aborted&&i();var n=setTimeout(()=>r.abort(),15e3);try{return yield iG((yield iY(e,t,{signal:r.signal})))}finally{clearTimeout(n),a?.removeEventListener("abort",i)}}),function(e,t){return K.apply(this,arguments)}),iH=e=>{try{return JSON.parse(Buffer.from(e.split(".")[1],"base64url").toString("utf8"))}catch{return{}}},iW=e=>String(e).replaceAll("&","&").replaceAll("<","<").replaceAll(">",">").replaceAll('"',""").replaceAll("'","'"),iK=({title:e,heading:t,message:a})=>`<!doctype html>
|
|
1415
1415
|
<html lang="en">
|
|
1416
1416
|
<head>
|
|
1417
1417
|
<meta charset="utf-8" />
|
|
1418
1418
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
1419
|
-
<title>${
|
|
1419
|
+
<title>${iW(e)}</title>
|
|
1420
1420
|
<style>
|
|
1421
1421
|
:root {
|
|
1422
1422
|
--text: #fafafa;
|
|
@@ -1470,11 +1470,11 @@ ${ax}`);return r.cause=e,r},aR=ep(function e(t,a){var r,i=this;en(this,e),this.b
|
|
|
1470
1470
|
<body>
|
|
1471
1471
|
<main>
|
|
1472
1472
|
<img class="logo" src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMAAAADACAQAAAD41aSMAAAAAmJLR0QA/4ePzL8AAAAJcEhZcwAAFxIAABcSAWef0lIAAAAHdElNRQfqAxUDIA9cEchTAAAJD0lEQVR42u2dfVMbNxDGH/mMDZiCm2YCtClpknaS6ff/LJ2QljadSQqEBAyBALHvtn/4rNOd70WyLe+d2R8zCT7r5JUe7erlZKEIAictbgMeOiIAMyIAMyIAMyIAMyIAMyIAMyIAMyIAMyIAMyIAMyIAMyIAMyIAMyIAMyIAM22rVPLUxh1lmay6bkf0DiF3cRpGgOcIrCSoDkH0p1S/MyH+tIwblQJc2vqSkOHKKlWlACPucjQWu5qTURAzdqMgjYSjctyHiw4CEPaxw13CmnOJY8dG6uQBPXGBCjYoQuB0h1MfEHGXbwWRTpgZEYAZBwFkQcgHDgJI/+sDCUHMiADMOM6ELcnvLtQcKanq/REucQdgDVvYzEuTlwMV5klfcY1hkp+3+OtFgFNcTFkc4DvanSrIv7jNXFIIsDWVMsRhPMEh9LGXzoQG+GjMUc4BbOKAsp/1h85hEwcAQEcYQoEAfIefjPw+4Itx3zmATTrwJMLSRkEhLvAGo0wmKqehjnCBw8zHlXw2fcAJCCr1czuVQ16hh1AY1+u+kd8RvmRyU/iKt56GgUsYBZG+X+GovC51SsLfqZTFn32Fq4J3q6rsxsg9qYZBLMvYnsSiCB9mLH853jvhNfSNOEe4LkzZxZZRJd/ssqcTowiv8Ao7utJGFUsnn7RN5hpXEjwVXuM1uvrVrRcf8CwAYQ976qXRRi8LU/6Cp+pXo4x2EkT6/nVAQe3pKy1clJp2F1sVmX0KhTq/HqCg+toiPw9mvXtABwBUV78eFqQbV1tgSHVnlX/SyrtT75XnMKnQIDUSSap5DQDQ9rwEuaR5QBC3I4XI2pFdCz7dE4TFKek0LjoVLrIP47R+q8jPPGAK+8okIwbPl68qffda5/8kc9ekqdwABNXDa/PNhePZAyZVMNIzn451MboWaWbrFUNc6UfmahwkJyhzwPAOmfGtBzwL0MIVQKBhXKQw097MlPcAnevXEdYt8s8TIEKof/JQuMeZvj87y31k5HmPQ1yS32VgzyFI4UwXFljHj+ioopTv4v8BIDSGpK48RxB7XpEPRUZw2s2818dp6vUxPuMF+Wn9wNL6AAAIcICWVUHW8QyYNeKqnkPiKB2AAEC9osNUTzTEG+zTDv9SxGwQwtiHQ/yDQYlDkw4ZSv/jmxbOpy+qV+hk1umOccq/FDEbm3imw8kI/+FjYco+nsYOeYs3+LSUB3AKg7yKVS+wn5HgIk+qBeB9FLSLnnqqI12Ai4KWFGIP2+qlHgSeeXwGqozIWzDfVjvqNdYME3xZ5L0PCABArdEQ00vw5ZV0A5dorqGPetm5g+2cQEbYwLbR1RZ+jnpB5sK6n6UIp51x7kyMt3e0pMZsNrfmdRRnemtUB9u5dwXo46Muz+eUADc0WSzZREftgmgQf0oLA/RnqINyvHgAGb/N7rVU8LtJ3i40pX2tbI9aN14pilc5tZInuI9/28IBgD2c63zsVqfc8PI8oC77J4rsIMBYtg4z9wQIEKClqyapIh/Lct5HQeNKGM0pis3d0zG6xL1V31i2Nqdey96l4Pnz1NihyfLxylwFmO4z1q3uVPhixLiOHoeN4qtJu+9g8XhfijjBGt15XE5pxy1f4Q4g4L2u2AiPSk3r6mZhSrejv1p0jxHa9J+R3+zLI2X2e2ZkPGMFFu5y6gm918POw/Gl+FXVauo2zrRlyfjGHBEdGfkBLavlQVeWEPKS6ieEyG44mdc3ttHLif6ENl5WdB0/6OCSmg+rn/XiiUmIfS+jCy/zAEKUUXZseQd72FT5KUlfGROlxhykB7RTIxH1jAY4RYhxa4oAtMZ7hzLVleSQdL+TT/tqpOup3+lv3GHSOiMAXfxmuZDoSuUXtT/TxFEjvCxcTJ5SoODTKlKqzBVVkm4qnyt8Q4Q2ttG23VtXnCsBd7hBiAAb+TvtcvlGf+mA+ASPLO7x0wfMM2VQlumm3t+uTOGQqwLWvcT8LLI9nRnZHc2MCMCMCMCMCMCMkwCi1uJxqlN/S2qrwtC5kTrMAxROsCXfVS3l2nmw7jQRG3raGbA6uM+V5LgaZqRfZUYEYMYxBM2zN6aVWW6sy+E3abuiuZ5QuJ0VBDgKsIHd+Bsj2e3CUbwW35q6lnCPY0PA7/E9Wjn5jKskeZXnosn1KJW6lZOyhax1hHFfNnn9CQNtRYCfsG7kG6VyT/LJtyzEKW79CUDYRXeOXriNtvEVuN3a9Oh7dG7spduaq4S7dOTzxCzpMKpwV8+pTmUWtnikUTMjAjAjAjAjAjAjAjAjAjAjAjAjAjAjAjAjJ+cyIx7AjOwNZUY8gBkRgBkRgBkZBTEjnTAzEoKYEQGYEQGYEQGYEQGYkWEoM+IBzMg8gBnxAGZEAGZEAGZkFMSMeAAzMgpiRjyAGekDmJEQxIyEIGZEAGZEAGZEAGZEAGZEAGaczooY4Mlck4HkpAiFG/RqMrG4Nv6SwHDO6c7AuUU7nB0NzDsZS88kalL/C7XKrCkvZ0cvcjJWz4ndsq2SPoAZEYAZ5+Pr6xG5s4GiHlZ5PzVRIahJ5I5Sh6cFtXHkkXNTcDwxq89dQs1bo6i/chujucSxYxN1EqBXn6ELtdIHCNbErg2K/B1ZpmoTaVeJxj4Rq5c1s9PYJ2L1smZ26jJ8cOYBekC9EA8QFoIIwIwIwExjBZBOmBnphIWF0NiZ8KrQ2JlwXf7+xrw0NgQ11vAVLUdjEQGYaWwnXC9rZqexnXC9rJkdCUHMNFaABxiC6oWEIGbEA4SF0FgBJAQJC6GxAkgfICwEEYCZxgognbCwEEQAZkQAZkQAZkQAZhorgEzEhIXQWAFkHsCMbMwSwx92OR5gJ7wqRa4XTvuCRtzWGtSzOYycQ4rDUQUKx9iieow+7lMCvEenFnoQrp1HZ06npYxwwV1GjVnQa25jcq2yg/HIMs5i14fKkNXkwvFi1xtUpnq0MlOe5RJZnq1UHYLUYzrnLk0DeWwZPCrPDQUA0CK9gFKna6qSd+fP3y59cV3l5TW+RiX3BIB17LYTQPBGY5ciVgURgBkRgBkRgBkRgBkRgBkRgBkRgBkRgBkRgBkRgBkRgBkRgBkRgBkRgJn/AQveHJLic/uaAAAAJXRFWHRkYXRlOmNyZWF0ZQAyMDI1LTA1LTMwVDAxOjA2OjI1KzAwOjAw6pDGFAAAACV0RVh0ZGF0ZTptb2RpZnkAMjAyNS0wNS0zMFQwMTowNjoyNSswMDowMJvNfqgAAAAodEVYdGRhdGU6dGltZXN0YW1wADIwMjYtMDMtMjFUMDM6MzI6MTUrMDA6MDA/aNclAAAARnRFWHRzb2Z0d2FyZQBJbWFnZU1hZ2ljayA2LjcuOC05IDIwMTQtMDUtMTIgUTE2IGh0dHA6Ly93d3cuaW1hZ2VtYWdpY2sub3Jn3IbtAAAAABh0RVh0VGh1bWI6OkRvY3VtZW50OjpQYWdlcwAxp/+7LwAAABh0RVh0VGh1bWI6OkltYWdlOjpoZWlnaHQANTEywNBQUQAAABd0RVh0VGh1bWI6OkltYWdlOjpXaWR0aAA1MTIcfAPcAAAAGXRFWHRUaHVtYjo6TWltZXR5cGUAaW1hZ2UvcG5nP7JWTgAAABd0RVh0VGh1bWI6Ok1UaW1lADE1NDY5OTk4MDiLx93fAAAAD3RFWHRUaHVtYjo6U2l6ZQAwQkKUoj7sAAAAQHRFWHRUaHVtYjo6VVJJAGZpbGU6Ly8vdG1wL2Zhdmljb25zLzY1OTQ5ODdlNmE3NjU4MmMzZjU3MWZiZWE2OTFiOTg3I9M9xAAAAABJRU5ErkJggg==" alt="" />
|
|
1473
|
-
<h1>${
|
|
1474
|
-
<p>${
|
|
1473
|
+
<h1>${iW(t)}</h1>
|
|
1474
|
+
<p>${iW(a)}</p>
|
|
1475
1475
|
</main>
|
|
1476
1476
|
</body>
|
|
1477
|
-
</html>`,iQ=iq({title:"Signed in to BRICKS",heading:"Signed in to BRICKS",message:"You can close this tab now."}),iY=e=>iq({title:"Sign-in failed",heading:"Sign-in failed",message:e}),iG="Sign-in cancelled",iz=(K=ei(function*({onAuthorizeUrl:e,signal:t}={}){if(t?.aborted)throw Error(iG);var a,r,i,n,p,o,s,d=(a=a3.randomBytes(32).toString("base64url"),r=a3.createHash("sha256").update(a).digest("base64url"),{verifier:a,challenge:r}),l=d.verifier,u=d.challenge,c=a3.randomBytes(16).toString("base64url"),m=process.env.BRICKS_OAUTH_CALLBACK_PORT,f=null!=m&&""!==m?Number(m):8535,h=new Promise((e,t)=>{i=e,n=t}),v=tL.createServer((e,t)=>{var a=new URL(e.url,`http://${i$}`);if(a.pathname!==iF)return void t.writeHead(404).end();var r=a.searchParams.get("error"),p=a.searchParams.get("code");if(a.searchParams.get("state")!==c)return void t.writeHead(400,{"Content-Type":"text/html"}).end(iY("Invalid state"));if(r){var o=a.searchParams.get("error_description")||r;t.writeHead(200,{"Content-Type":"text/html"}).end(iY(o)),n(Error(o));return}if(!p){t.writeHead(400,{"Content-Type":"text/html"}).end(iY("Invalid state")),n(Error("OAuth callback did not include an authorization code"));return}t.writeHead(200,{"Content-Type":"text/html"}).end(iQ),i(p)}),y=yield new Promise((e,t)=>{v.once("error",e=>{e?.code==="EADDRINUSE"?t(Error(`Callback port ${f} is already in use — is another sign-in in progress? Close it and retry.`)):t(e)}),v.listen(f,i$,()=>e(v.address().port))}),g=`http://${i$}:${y}${iF}`,_=(({redirectUri:e,state:t,challenge:a})=>{var r=new URL(`https://${ix}/authorize`);return r.searchParams.set("response_type","code"),r.searchParams.set("client_id",iV),r.searchParams.set("redirect_uri",e),r.searchParams.set("scope",iR),r.searchParams.set("audience",iC),r.searchParams.set("state",t),r.searchParams.set("code_challenge",a),r.searchParams.set("code_challenge_method","S256"),r.toString()})({redirectUri:g,state:c,challenge:u}),b=new Promise((e,t)=>{s=t}),w=()=>s(Error(iG));t?.addEventListener("abort",w,{once:!0});try{if(t?.aborted)throw Error(iG);var E=new Promise((e,t)=>{p=setTimeout(()=>t(Error("Timed out waiting for the browser sign-in (5 minutes)")),3e5)}),T=e?Promise.resolve().then(()=>e(_)):Promise.resolve(),N=yield Promise.race([Promise.all([T,h]),E,b]),S=aU(N,2)[1];o=yield iM("/oauth/token",{grant_type:"authorization_code",client_id:iV,code:S,code_verifier:l,redirect_uri:g},{signal:t})}catch(e){if(t?.aborted)throw Error(iG);throw e}finally{p&&clearTimeout(p),t?.removeEventListener("abort",w),yield new Promise(e=>{v.close(e),v.closeIdleConnections?.()})}if(t?.aborted)throw Error(iG);return o}),function(){return K.apply(this,arguments)}),iH=(J=ei(function*(){return yield iM("/oauth/device/code",{client_id:iV,scope:iR,audience:iC})}),function(){return J.apply(this,arguments)}),iW=e=>new Promise(t=>setTimeout(t,e)),iK=(Z=ei(function*({device_code:e,interval:t=5,expires_in:a=900}){for(var r=Date.now()+1e3*a,i=1e3*t;Date.now()<r;){yield iW(i);try{return yield iM("/oauth/token",{grant_type:"urn:ietf:params:oauth:grant-type:device_code",client_id:iV,device_code:e})}catch(e){if("authorization_pending"===e.code)continue;if("slow_down"===e.code){i+=5e3;continue}throw e}}throw Error("Device authorization expired before the sign-in was confirmed")}),function(e){return Z.apply(this,arguments)}),iJ=(e,t=null,{preservePrevious:a=!1}={})=>{if(!e?.access_token)throw Error("OAuth token response did not include an access token");if(!a&&!e.id_token)throw Error("OAuth login response did not include an ID token");var r=e.id_token?iU(e.id_token):{};if(!a&&!r.sub)throw Error("OAuth ID token did not include a user subject");if(a&&r.sub&&t?.user?.sub&&r.sub!==t.user.sub)throw Error("OAuth refresh returned a different user identity");var i=a?t?.user:null;return{accessToken:e.access_token,refreshToken:e.refresh_token||(a?t?.refreshToken:null)||null,expiresAt:new Date(Date.now()+1e3*(e.expires_in||0)).toISOString(),user:{sub:r.sub||i?.sub||null,email:r.email||i?.email||null,name:r.name||i?.name||null,nickname:r.nickname||i?.nickname||null,picture:r.picture||i?.picture||null},audience:iC}},iZ=null,iX=(X=ei(function*({forceRefresh:e=!1}={}){var t=rM();if(!t?.accessToken)return null;var a=new Date(t.expiresAt||0).getTime()-Date.now();if(!e&&a>3e5)return t;if(!t.refreshToken){if(a>0)return t;if(!(yield rz(t)))return rM();throw Error("OAuth session expired. Run `bricks auth login` again.")}var r=`${t.accessToken}\0${t.refreshToken}`;if(iZ){var i=iZ;return i.sessionKey===r?i.promise:(yield i.promise.catch(()=>{}),iX({forceRefresh:e}))}var n=rm(ei(function*(){var a=rM();if(!a?.accessToken)return null;if(!t||!a||t.accessToken!==a.accessToken||t.refreshToken!==a.refreshToken)return a;var r=new Date(a.expiresAt||0).getTime()-Date.now();if(!e&&r>3e5)return a;if(!a.refreshToken){if(r>0)return a;if(!(yield rz(a)))return rM();throw Error("OAuth session expired. Run `bricks auth login` again.")}try{var i=yield iM("/oauth/token",{grant_type:"refresh_token",client_id:iV,refresh_token:a.refreshToken}),n=iJ(i,a,{preservePrevious:!0});if(!(yield rG(a,n)))return rM();return n}catch(e){if("invalid_grant"===e.code){if(!(yield rz(a)))return rM();throw Error("OAuth session expired. Run `bricks auth login` again.")}throw e}}));iZ={sessionKey:r,promise:n};try{return yield n}finally{iZ?.promise===n&&(iZ=null)}}),function(){return X.apply(this,arguments)}),i1=(ee=ei(function*(e){if(e){var t=new AbortController,a=setTimeout(()=>t.abort(),5e3);try{yield iL("/oauth/revoke",{client_id:iV,token:e},{signal:t.signal})}catch{}finally{clearTimeout(a),t.abort()}}}),function(e){return ee.apply(this,arguments)}),i0=(et=ei(function*(){var e=yield rQ();return!!e?.accessToken&&(yield i1(e.refreshToken),!0)}),function(){return et.apply(this,arguments)}),i2=e=>new Promise(t=>{var a=aU("darwin"===process.platform?["open",[e]]:"win32"===process.platform?["cmd",["/c","start","",e.replace(/&/g,"^&")]]:["xdg-open",[e]],2),r=a[0],i=a[1];try{var n=(0,iy.spawn)(r,i,{stdio:"ignore",detached:!0});n.once("error",()=>t(!1)),n.once("spawn",()=>{n.unref(),t(!0)})}catch{t(!1)}}),i6=(e,t)=>{if(!e)throw Error("Not logged in. Run `bricks auth login` first.");if(e.user?.sub!==t)throw Error("OAuth account changed. Re-select the workspace for the current account.");return e},i4=e=>{var t=((e="default")=>rT(e,rb.snapshot(["tokens","oauth","devtoolsTokens","baseUrl","activityLogBaseUrl"])))(e);return{...t,auth:(({tokenInfo:e,oauth:t})=>{if(!e)return null;if("oauth"===e.type){if(!t?.accessToken||!e.oauthSubject||e.oauthSubject!==t.user?.sub||!e.workspaceId)return null;var a,r,i,n,p=e.oauthSubject,o=(r=ei(function*(){return i6((yield iX()),p).accessToken}),function(){return r.apply(this,arguments)});return{kind:"oauth",workspaceId:e.workspaceId,workspaceName:e.workspaceName,getAccessToken:o,getHeaders:(i=ei(function*(){return{authorization:`Bearer ${yield o()}`,"x-bricks-workspace-id":String(e.workspaceId)}}),function(){return i.apply(this,arguments)}),refresh:(n=ei(function*(){i6((yield iX({forceRefresh:!0})),p)}),function(){return n.apply(this,arguments)})}}return e.token?{kind:"token",token:e.token,workspaceId:e.workspaceId,workspaceName:e.workspaceName,getHeaders:(a=ei(function*(){return{authorization:`Bearer ${e.token}`}}),function(){return a.apply(this,arguments)})}:null})(t)}},i3=e=>i4(e).auth},48255(e,t,a){a.d(t,{Wk:()=>d,eO:()=>p,yJ:()=>s});var r=a(91070),i=a(73971),n=a(8238);class p extends Error{constructor(e,...t){var a,n,s;let d,{nodes:l,source:u,positions:c,path:m,originalError:f,extensions:h}=null==(d=t[0])||"kind"in d||"length"in d?{nodes:d,source:t[1],positions:t[2],path:t[3],originalError:t[4],extensions:t[5]}:d;super(e),this.name="GraphQLError",this.path=null!=m?m:void 0,this.originalError=null!=f?f:void 0,this.nodes=o(Array.isArray(l)?l:l?[l]:void 0);let v=o(null==(a=this.nodes)?void 0:a.map(e=>e.loc).filter(e=>null!=e));this.source=null!=u?u:null==v||null==(n=v[0])?void 0:n.source,this.positions=null!=c?c:null==v?void 0:v.map(e=>e.start),this.locations=c&&u?c.map(e=>(0,i.g)(u,e)):null==v?void 0:v.map(e=>(0,i.g)(e.source,e.start));let y=(0,r.Z)(null==f?void 0:f.extensions)?null==f?void 0:f.extensions:void 0;this.extensions=null!=(s=null!=h?h:y)?s: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}}),null!=f&&f.stack?Object.defineProperty(this,"stack",{value:f.stack,writable:!0,configurable:!0}):Error.captureStackTrace?Error.captureStackTrace(this,p):Object.defineProperty(this,"stack",{value:Error().stack,writable:!0,configurable:!0})}get[Symbol.toStringTag](){return"GraphQLError"}toString(){let e=this.message;if(this.nodes)for(let t of this.nodes)t.loc&&(e+="\n\n"+(0,n.V)(t.loc));else if(this.source&&this.locations)for(let t of this.locations)e+="\n\n"+(0,n.C)(this.source,t);return e}toJSON(){let e={message:this.message};return null!=this.locations&&(e.locations=this.locations),null!=this.path&&(e.path=this.path),null!=this.extensions&&Object.keys(this.extensions).length>0&&(e.extensions=this.extensions),e}}function o(e){return void 0===e||0===e.length?void 0:e}function s(e){return e.toString()}function d(e){return e.toJSON()}},59841(e,t,a){a.d(t,{I:()=>i});var r=a(48255);function i(e,t,a){return new r.eO(`Syntax Error: ${a}`,{source:e,positions:[t]})}},36869(e,t,a){let r;a.r(t),a.d(t,{VariablesAreInputTypesRule:()=>aj,SingleFieldSubscriptionsRule:()=>aT,UniqueVariableNamesRule:()=>a$,GraphQLDeprecatedDirective:()=>e7,GraphQLNonNull:()=>ef,__InputValue:()=>tm,createSourceEventStream:()=>rh,execute:()=>aX,isDefinitionNode:()=>tL.MD,isInterfaceType:()=>Y,isRequiredArgument:()=>eR,isValidNameError:()=>r1,parseValue:()=>h.$x,valueFromAST:()=>am,NoUnusedVariablesRule:()=>t1,__DirectiveLocation:()=>tl,findDangerousChanges:()=>r2,__TypeKind:()=>th,isSchema:()=>tw,UniqueTypeNamesRule:()=>aF,NoSchemaIntrospectionCustomRule:()=>rg,defaultTypeResolver:()=>ra,isType:()=>j,syntaxError:()=>r_.I,version:()=>i,UniqueFragmentNamesRule:()=>ax,assertWrappingType:()=>ev,getNullableType:()=>e_,isObjectType:()=>q,visitWithTypeInfo:()=>tP,assertEnumValueName:()=>L,printSchema:()=>rP,validate:()=>az,BREAK:()=>tR.sP,assertNonNullType:()=>ea,assertNullableType:()=>eg,executeSync:()=>a1,isLeafType:()=>eo,resolveSchemaCoordinate:()=>r8,assertOutputType:()=>ep,buildASTSchema:()=>rk,astFromValue:()=>tp,Kind:()=>R.b,ProvidedRequiredArgumentsRule:()=>ai,UniqueDirectiveNamesRule:()=>aI,KnownDirectivesRule:()=>tQ,DEFAULT_DEPRECATION_REASON:()=>e8,TypeKind:()=>l,assertInterfaceType:()=>G,isValueNode:()=>tL.aR,GraphQLSpecifiedByDirective:()=>te,GraphQLFloat:()=>eK,UniqueFieldDefinitionNamesRule:()=>ak,LoneAnonymousOperationRule:()=>tH,VariablesInAllowedPositionRule:()=>aM,assertInputType:()=>ei,formatError:()=>y.Wk,assertInputObjectType:()=>Z,isOutputType:()=>en,isWrappingType:()=>eh,assertLeafType:()=>es,assertValidSchema:()=>tO,FragmentsOnCompositeTypesRule:()=>tU,graphql:()=>rn,UniqueOperationTypesRule:()=>aV,parseSchemaCoordinate:()=>h.Ng,UniqueEnumValueNamesRule:()=>aA,isNonNullType:()=>et,isSelectionNode:()=>tL.VK,printError:()=>y.yJ,specifiedDirectives:()=>ta,visit:()=>tR.YR,GraphQLScalarType:()=>eS,assertEnumType:()=>K,UniqueDirectivesPerLocationRule:()=>aD,assertName:()=>P,getDirectiveValues:()=>ay,isConstValueNode:()=>tL.TZ,isEqualType:()=>eq,isNamedType:()=>eb,isTypeDefinitionNode:()=>tL.a6,validateSchema:()=>tS,parse:()=>h.qg,__Schema:()=>ts,isTypeSystemDefinitionNode:()=>tL.xu,valueFromASTUntyped:()=>F,LoneSchemaDefinitionRule:()=>tW,isTypeSubTypeOf:()=>eQ,UniqueArgumentNamesRule:()=>aO,UniqueInputFieldNamesRule:()=>aC,locatedError:()=>aJ,typeFromAST:()=>tV,printLocation:()=>rl.V,assertUnionType:()=>H,separateOperations:()=>rK,getVariableValues:()=>ah,Location:()=>g.aZ,GraphQLObjectType:()=>eO,UniqueArgumentDefinitionNamesRule:()=>aS,stripIgnoredCharacters:()=>rZ,GRAPHQL_MAX_INT:()=>ez,visitInParallel:()=>tR.oP,parseType:()=>h.Mb,isTypeNode:()=>tL.dI,PossibleTypeExtensionsRule:()=>aa,graphqlSync:()=>rp,isSchemaCoordinateNode:()=>tL.gj,DirectiveLocation:()=>eG.H,TypeNameMetaFieldDef:()=>tg,coerceInputValue:()=>au,GraphQLInt:()=>eW,resolveObjMapThunk:()=>eN,GraphQLInterfaceType:()=>eV,UniqueOperationNamesRule:()=>aR,GraphQLSkipDirective:()=>e5,isEnumType:()=>W,assertValidName:()=>rX,buildClientSchema:()=>rN,KnownArgumentNamesRule:()=>tB,ValuesOfCorrectTypeRule:()=>aP,isInputObjectType:()=>J,GraphQLID:()=>eX,NoUnusedFragmentsRule:()=>tX,isUnionType:()=>z,isSpecifiedScalarType:()=>e0,getArgumentValues:()=>av,printSourceLocation:()=>rl.C,__EnumValue:()=>tf,getOperationAST:()=>rw,isExecutableDefinitionNode:()=>tL._m,isAbstractType:()=>eu,assertAbstractType:()=>ec,isTypeExtensionNode:()=>tL.i7,GraphQLInputObjectType:()=>eM,getNamedType:()=>eE,parseConstValue:()=>h.u8,KnownFragmentNamesRule:()=>tY,isListType:()=>X,Lexer:()=>ru.JG,isSpecifiedDirective:()=>tr,responsePathAsArray:()=>al,isDirective:()=>e6,TypeInfo:()=>tF,assertScalarType:()=>B,extendSchema:()=>rS,isIntrospectionType:()=>tb,print:()=>V.y,getIntrospectionQuery:()=>rb,GraphQLBoolean:()=>eZ,KnownTypeNamesRule:()=>tG,assertListType:()=>ee,concatAST:()=>rW,NoDeprecatedCustomRule:()=>ry,defaultFieldResolver:()=>rr,GraphQLDirective:()=>e3,getLocation:()=>rd.g,TypeMetaFieldDef:()=>ty,GRAPHQL_MIN_INT:()=>eH,GraphQLIncludeDirective:()=>e9,ScalarLeafsRule:()=>ao,assertSchema:()=>tE,lexicographicSortSchema:()=>rC,GraphQLList:()=>em,isTypeSystemExtensionNode:()=>tL.fT,specifiedScalarTypes:()=>e1,BreakingChangeType:()=>u,ExecutableDefinitionsRule:()=>tj,assertDirective:()=>e4,__Field:()=>tc,getVisitFn:()=>tR.UY,recommendedRules:()=>aU,SchemaMetaFieldDef:()=>tv,assertCompositeType:()=>el,isRequiredInputField:()=>eB,Token:()=>g.ou,specifiedRules:()=>aB,DangerousChangeType:()=>c,GraphQLUnionType:()=>eF,isCompositeType:()=>ed,versionInfo:()=>n,FieldsOnCorrectTypeRule:()=>tM,GraphQLString:()=>eJ,assertType:()=>M,introspectionFromSchema:()=>rT,doTypesOverlap:()=>eY,GraphQLEnumType:()=>eP,resolveReadonlyArrayThunk:()=>eT,GraphQLOneOfDirective:()=>tt,NoFragmentCyclesRule:()=>tJ,findBreakingChanges:()=>r0,ValidationContext:()=>aG,OverlappingFieldsCanBeMergedRule:()=>t2,isScalarType:()=>U,MaxIntrospectionDepthRule:()=>tK,NoUndefinedVariablesRule:()=>tZ,assertObjectType:()=>Q,getOperationRootType:()=>rE,printType:()=>rU,OperationTypeNode:()=>g.cE,isInputType:()=>er,__Directive:()=>td,GraphQLSchema:()=>tT,Source:()=>rs.k,resolveASTSchemaCoordinate:()=>r7,GraphQLError:()=>y.eO,assertNamedType:()=>ew,buildSchema:()=>rx,introspectionTypes:()=>t_,PossibleFragmentSpreadsRule:()=>at,__Type:()=>tu,getEnterLeaveForKind:()=>tR.XO,TokenKind:()=>rc.Y,printIntrospectionSchema:()=>rL,isNullableType:()=>ey,subscribe:()=>rf});let i="16.12.0",n=Object.freeze({major:16,minor:12,patch:0,preReleaseTag:null});var p,o,s,d,l,u,c,m=a(93217);function f(e){return"function"==typeof(null==e?void 0:e.then)}var h=a(20186),v=a(35198),y=a(48255),g=a(59762);function _(e,t){let[a,r]=t?[e,t]:[void 0,e],i=" Did you mean ";a&&(i+=a+" ");let n=r.map(e=>`"${e}"`);switch(n.length){case 0:return"";case 1:return i+n[0]+"?";case 2:return i+n[0]+" or "+n[1]+"?"}let p=n.slice(0,5),o=p.pop();return i+p.join(", ")+", or "+o+"?"}function b(e){return e}var w=a(50792),E=a(91070);function T(e,t){let a=Object.create(null);for(let r of e)a[t(r)]=r;return a}function N(e,t,a){let r=Object.create(null);for(let i of e)r[t(i)]=a(i);return r}function S(e,t){let a=Object.create(null);for(let r of Object.keys(e))a[r]=t(e[r],r);return a}function O(e,t){let a=0,r=0;for(;a<e.length&&r<t.length;){let i=e.charCodeAt(a),n=t.charCodeAt(r);if(D(i)&&D(n)){let p=0;do++a,p=10*p+i-I,i=e.charCodeAt(a);while(D(i)&&p>0);let o=0;do++r,o=10*o+n-I,n=t.charCodeAt(r);while(D(n)&&o>0);if(p<o)return -1;if(p>o)return 1}else{if(i<n)return -1;if(i>n)return 1;++a,++r}}return e.length-t.length}let I=48;function D(e){return!isNaN(e)&&I<=e&&e<=57}function A(e,t){let a=Object.create(null),r=new k(e),i=Math.floor(.4*e.length)+1;for(let e of t){let t=r.measure(e,i);void 0!==t&&(a[e]=t)}return Object.keys(a).sort((e,t)=>{let r=a[e]-a[t];return 0!==r?r:O(e,t)})}class k{constructor(e){this._input=e,this._inputLowerCase=e.toLowerCase(),this._inputArray=x(this._inputLowerCase),this._rows=[Array(e.length+1).fill(0),Array(e.length+1).fill(0),Array(e.length+1).fill(0)]}measure(e,t){if(this._input===e)return 0;let a=e.toLowerCase();if(this._inputLowerCase===a)return 1;let r=x(a),i=this._inputArray;if(r.length<i.length){let e=r;r=i,i=e}let n=r.length,p=i.length;if(n-p>t)return;let o=this._rows;for(let e=0;e<=p;e++)o[0][e]=e;for(let e=1;e<=n;e++){let a=o[(e-1)%3],n=o[e%3],s=n[0]=e;for(let t=1;t<=p;t++){let p=+(r[e-1]!==i[t-1]),d=Math.min(a[t]+1,n[t-1]+1,a[t-1]+p);e>1&&t>1&&r[e-1]===i[t-2]&&r[e-2]===i[t-1]&&(d=Math.min(d,o[(e-2)%3][t-2]+1)),d<s&&(s=d),n[t]=d}if(s>t)return}let s=o[n%3][p];return s<=t?s:void 0}}function x(e){let t=e.length,a=Array(t);for(let r=0;r<t;++r)a[r]=e.charCodeAt(r);return a}function C(e){if(null==e)return Object.create(null);if(null===Object.getPrototypeOf(e))return e;let t=Object.create(null);for(let[a,r]of Object.entries(e))t[a]=r;return t}var R=a(42455),V=a(95818);function F(e,t){switch(e.kind){case R.b.NULL:return null;case R.b.INT:return parseInt(e.value,10);case R.b.FLOAT:return parseFloat(e.value);case R.b.STRING:case R.b.ENUM:case R.b.BOOLEAN:return e.value;case R.b.LIST:return e.values.map(e=>F(e,t));case R.b.OBJECT:return N(e.fields,e=>e.name.value,e=>F(e.value,t));case R.b.VARIABLE:return null==t?void 0:t[e.name.value]}}var $=a(25881);function P(e){if(null!=e||(0,m.U)(!1,"Must provide name."),"string"==typeof e||(0,m.U)(!1,"Expected name to be a string."),0===e.length)throw new y.eO("Expected name to be a non-empty string.");for(let t=1;t<e.length;++t)if(!(0,$.xr)(e.charCodeAt(t)))throw new y.eO(`Names must only contain [_a-zA-Z0-9] but "${e}" does not.`);if(!(0,$.un)(e.charCodeAt(0)))throw new y.eO(`Names must start with [_a-zA-Z] but "${e}" does not.`);return e}function L(e){if("true"===e||"false"===e||"null"===e)throw new y.eO(`Enum values cannot be named: ${e}`);return P(e)}function j(e){return U(e)||q(e)||Y(e)||z(e)||W(e)||J(e)||X(e)||et(e)}function M(e){if(!j(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL type.`);return e}function U(e){return(0,w.h)(e,eS)}function B(e){if(!U(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL Scalar type.`);return e}function q(e){return(0,w.h)(e,eO)}function Q(e){if(!q(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL Object type.`);return e}function Y(e){return(0,w.h)(e,eV)}function G(e){if(!Y(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL Interface type.`);return e}function z(e){return(0,w.h)(e,eF)}function H(e){if(!z(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL Union type.`);return e}function W(e){return(0,w.h)(e,eP)}function K(e){if(!W(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL Enum type.`);return e}function J(e){return(0,w.h)(e,eM)}function Z(e){if(!J(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL Input Object type.`);return e}function X(e){return(0,w.h)(e,em)}function ee(e){if(!X(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL List type.`);return e}function et(e){return(0,w.h)(e,ef)}function ea(e){if(!et(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL Non-Null type.`);return e}function er(e){return U(e)||W(e)||J(e)||eh(e)&&er(e.ofType)}function ei(e){if(!er(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL input type.`);return e}function en(e){return U(e)||q(e)||Y(e)||z(e)||W(e)||eh(e)&&en(e.ofType)}function ep(e){if(!en(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL output type.`);return e}function eo(e){return U(e)||W(e)}function es(e){if(!eo(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL leaf type.`);return e}function ed(e){return q(e)||Y(e)||z(e)}function el(e){if(!ed(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL composite type.`);return e}function eu(e){return Y(e)||z(e)}function ec(e){if(!eu(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL abstract type.`);return e}class em{constructor(e){j(e)||(0,m.U)(!1,`Expected ${(0,v.N)(e)} to be a GraphQL type.`),this.ofType=e}get[Symbol.toStringTag](){return"GraphQLList"}toString(){return"["+String(this.ofType)+"]"}toJSON(){return this.toString()}}class ef{constructor(e){ey(e)||(0,m.U)(!1,`Expected ${(0,v.N)(e)} to be a GraphQL nullable type.`),this.ofType=e}get[Symbol.toStringTag](){return"GraphQLNonNull"}toString(){return String(this.ofType)+"!"}toJSON(){return this.toString()}}function eh(e){return X(e)||et(e)}function ev(e){if(!eh(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL wrapping type.`);return e}function ey(e){return j(e)&&!et(e)}function eg(e){if(!ey(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL nullable type.`);return e}function e_(e){if(e)return et(e)?e.ofType:e}function eb(e){return U(e)||q(e)||Y(e)||z(e)||W(e)||J(e)}function ew(e){if(!eb(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL named type.`);return e}function eE(e){if(e){let t=e;for(;eh(t);)t=t.ofType;return t}}function eT(e){return"function"==typeof e?e():e}function eN(e){return"function"==typeof e?e():e}class eS{constructor(e){var t,a,r,i;let n=null!=(t=e.parseValue)?t:b;this.name=P(e.name),this.description=e.description,this.specifiedByURL=e.specifiedByURL,this.serialize=null!=(a=e.serialize)?a:b,this.parseValue=n,this.parseLiteral=null!=(r=e.parseLiteral)?r:(e,t)=>n(F(e,t)),this.extensions=C(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=null!=(i=e.extensionASTNodes)?i:[],null==e.specifiedByURL||"string"==typeof e.specifiedByURL||(0,m.U)(!1,`${this.name} must provide "specifiedByURL" as a string, but got: ${(0,v.N)(e.specifiedByURL)}.`),null==e.serialize||"function"==typeof e.serialize||(0,m.U)(!1,`${this.name} must provide "serialize" function. If this custom Scalar is also used as an input type, ensure "parseValue" and "parseLiteral" functions are also provided.`),e.parseLiteral&&("function"==typeof e.parseValue&&"function"==typeof e.parseLiteral||(0,m.U)(!1,`${this.name} must provide both "parseValue" and "parseLiteral" functions.`))}get[Symbol.toStringTag](){return"GraphQLScalarType"}toConfig(){return{name:this.name,description:this.description,specifiedByURL:this.specifiedByURL,serialize:this.serialize,parseValue:this.parseValue,parseLiteral:this.parseLiteral,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}class eO{constructor(e){var t;this.name=P(e.name),this.description=e.description,this.isTypeOf=e.isTypeOf,this.extensions=C(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=null!=(t=e.extensionASTNodes)?t:[],this._fields=()=>eD(e),this._interfaces=()=>eI(e),null==e.isTypeOf||"function"==typeof e.isTypeOf||(0,m.U)(!1,`${this.name} must provide "isTypeOf" as a function, but got: ${(0,v.N)(e.isTypeOf)}.`)}get[Symbol.toStringTag](){return"GraphQLObjectType"}getFields(){return"function"==typeof this._fields&&(this._fields=this._fields()),this._fields}getInterfaces(){return"function"==typeof this._interfaces&&(this._interfaces=this._interfaces()),this._interfaces}toConfig(){return{name:this.name,description:this.description,interfaces:this.getInterfaces(),fields:ex(this.getFields()),isTypeOf:this.isTypeOf,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}function eI(e){var t;let a=eT(null!=(t=e.interfaces)?t:[]);return Array.isArray(a)||(0,m.U)(!1,`${e.name} interfaces must be an Array or a function which returns an Array.`),a}function eD(e){let t=eN(e.fields);return ek(t)||(0,m.U)(!1,`${e.name} fields must be an object with field names as keys or a function which returns such an object.`),S(t,(t,a)=>{var r;ek(t)||(0,m.U)(!1,`${e.name}.${a} field config must be an object.`),null==t.resolve||"function"==typeof t.resolve||(0,m.U)(!1,`${e.name}.${a} field resolver must be a function if provided, but got: ${(0,v.N)(t.resolve)}.`);let i=null!=(r=t.args)?r:{};return ek(i)||(0,m.U)(!1,`${e.name}.${a} args must be an object with argument names as keys.`),{name:P(a),description:t.description,type:t.type,args:eA(i),resolve:t.resolve,subscribe:t.subscribe,deprecationReason:t.deprecationReason,extensions:C(t.extensions),astNode:t.astNode}})}function eA(e){return Object.entries(e).map(([e,t])=>({name:P(e),description:t.description,type:t.type,defaultValue:t.defaultValue,deprecationReason:t.deprecationReason,extensions:C(t.extensions),astNode:t.astNode}))}function ek(e){return(0,E.Z)(e)&&!Array.isArray(e)}function ex(e){return S(e,e=>({description:e.description,type:e.type,args:eC(e.args),resolve:e.resolve,subscribe:e.subscribe,deprecationReason:e.deprecationReason,extensions:e.extensions,astNode:e.astNode}))}function eC(e){return N(e,e=>e.name,e=>({description:e.description,type:e.type,defaultValue:e.defaultValue,deprecationReason:e.deprecationReason,extensions:e.extensions,astNode:e.astNode}))}function eR(e){return et(e.type)&&void 0===e.defaultValue}class eV{constructor(e){var t;this.name=P(e.name),this.description=e.description,this.resolveType=e.resolveType,this.extensions=C(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=null!=(t=e.extensionASTNodes)?t:[],this._fields=eD.bind(void 0,e),this._interfaces=eI.bind(void 0,e),null==e.resolveType||"function"==typeof e.resolveType||(0,m.U)(!1,`${this.name} must provide "resolveType" as a function, but got: ${(0,v.N)(e.resolveType)}.`)}get[Symbol.toStringTag](){return"GraphQLInterfaceType"}getFields(){return"function"==typeof this._fields&&(this._fields=this._fields()),this._fields}getInterfaces(){return"function"==typeof this._interfaces&&(this._interfaces=this._interfaces()),this._interfaces}toConfig(){return{name:this.name,description:this.description,interfaces:this.getInterfaces(),fields:ex(this.getFields()),resolveType:this.resolveType,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}class eF{constructor(e){var t;this.name=P(e.name),this.description=e.description,this.resolveType=e.resolveType,this.extensions=C(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=null!=(t=e.extensionASTNodes)?t:[],this._types=e$.bind(void 0,e),null==e.resolveType||"function"==typeof e.resolveType||(0,m.U)(!1,`${this.name} must provide "resolveType" as a function, but got: ${(0,v.N)(e.resolveType)}.`)}get[Symbol.toStringTag](){return"GraphQLUnionType"}getTypes(){return"function"==typeof this._types&&(this._types=this._types()),this._types}toConfig(){return{name:this.name,description:this.description,types:this.getTypes(),resolveType:this.resolveType,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}function e$(e){let t=eT(e.types);return Array.isArray(t)||(0,m.U)(!1,`Must provide Array of types or a function which returns such an array for Union ${e.name}.`),t}class eP{constructor(e){var t;this.name=P(e.name),this.description=e.description,this.extensions=C(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=null!=(t=e.extensionASTNodes)?t:[],this._values="function"==typeof e.values?e.values:ej(this.name,e.values),this._valueLookup=null,this._nameLookup=null}get[Symbol.toStringTag](){return"GraphQLEnumType"}getValues(){return"function"==typeof this._values&&(this._values=ej(this.name,this._values())),this._values}getValue(e){return null===this._nameLookup&&(this._nameLookup=T(this.getValues(),e=>e.name)),this._nameLookup[e]}serialize(e){null===this._valueLookup&&(this._valueLookup=new Map(this.getValues().map(e=>[e.value,e])));let t=this._valueLookup.get(e);if(void 0===t)throw new y.eO(`Enum "${this.name}" cannot represent value: ${(0,v.N)(e)}`);return t.name}parseValue(e){if("string"!=typeof e){let t=(0,v.N)(e);throw new y.eO(`Enum "${this.name}" cannot represent non-string value: ${t}.`+eL(this,t))}let t=this.getValue(e);if(null==t)throw new y.eO(`Value "${e}" does not exist in "${this.name}" enum.`+eL(this,e));return t.value}parseLiteral(e,t){if(e.kind!==R.b.ENUM){let t=(0,V.y)(e);throw new y.eO(`Enum "${this.name}" cannot represent non-enum value: ${t}.`+eL(this,t),{nodes:e})}let a=this.getValue(e.value);if(null==a){let t=(0,V.y)(e);throw new y.eO(`Value "${t}" does not exist in "${this.name}" enum.`+eL(this,t),{nodes:e})}return a.value}toConfig(){let e=N(this.getValues(),e=>e.name,e=>({description:e.description,value:e.value,deprecationReason:e.deprecationReason,extensions:e.extensions,astNode:e.astNode}));return{name:this.name,description:this.description,values:e,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}function eL(e,t){return _("the enum value",A(t,e.getValues().map(e=>e.name)))}function ej(e,t){return ek(t)||(0,m.U)(!1,`${e} values must be an object with value names as keys.`),Object.entries(t).map(([t,a])=>(ek(a)||(0,m.U)(!1,`${e}.${t} must refer to an object with a "value" key representing an internal value but got: ${(0,v.N)(a)}.`),{name:L(t),description:a.description,value:void 0!==a.value?a.value:t,deprecationReason:a.deprecationReason,extensions:C(a.extensions),astNode:a.astNode}))}class eM{constructor(e){var t,a;this.name=P(e.name),this.description=e.description,this.extensions=C(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=null!=(t=e.extensionASTNodes)?t:[],this.isOneOf=null!=(a=e.isOneOf)&&a,this._fields=eU.bind(void 0,e)}get[Symbol.toStringTag](){return"GraphQLInputObjectType"}getFields(){return"function"==typeof this._fields&&(this._fields=this._fields()),this._fields}toConfig(){let e=S(this.getFields(),e=>({description:e.description,type:e.type,defaultValue:e.defaultValue,deprecationReason:e.deprecationReason,extensions:e.extensions,astNode:e.astNode}));return{name:this.name,description:this.description,fields:e,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes,isOneOf:this.isOneOf}}toString(){return this.name}toJSON(){return this.toString()}}function eU(e){let t=eN(e.fields);return ek(t)||(0,m.U)(!1,`${e.name} fields must be an object with field names as keys or a function which returns such an object.`),S(t,(t,a)=>("resolve"in t&&(0,m.U)(!1,`${e.name}.${a} field has a resolve property, but Input Types cannot define resolvers.`),{name:P(a),description:t.description,type:t.type,defaultValue:t.defaultValue,deprecationReason:t.deprecationReason,extensions:C(t.extensions),astNode:t.astNode}))}function eB(e){return et(e.type)&&void 0===e.defaultValue}function eq(e,t){return e===t||!!(et(e)&&et(t)||X(e)&&X(t))&&eq(e.ofType,t.ofType)}function eQ(e,t,a){return t===a||(et(a)?!!et(t)&&eQ(e,t.ofType,a.ofType):et(t)?eQ(e,t.ofType,a):X(a)?!!X(t)&&eQ(e,t.ofType,a.ofType):!X(t)&&eu(a)&&(Y(t)||q(t))&&e.isSubType(a,t))}function eY(e,t,a){return t===a||(eu(t)?eu(a)?e.getPossibleTypes(t).some(t=>e.isSubType(a,t)):e.isSubType(t,a):!!eu(a)&&e.isSubType(a,t))}var eG=a(42868);let ez=0x7fffffff,eH=-0x80000000,eW=new eS({name:"Int",description:"The `Int` scalar type represents non-fractional signed whole numeric values. Int can represent values between -(2^31) and 2^31 - 1.",serialize(e){let t=e2(e);if("boolean"==typeof t)return+!!t;let a=t;if("string"==typeof t&&""!==t&&(a=Number(t)),"number"!=typeof a||!Number.isInteger(a))throw new y.eO(`Int cannot represent non-integer value: ${(0,v.N)(t)}`);if(a>ez||a<eH)throw new y.eO("Int cannot represent non 32-bit signed integer value: "+(0,v.N)(t));return a},parseValue(e){if("number"!=typeof e||!Number.isInteger(e))throw new y.eO(`Int cannot represent non-integer value: ${(0,v.N)(e)}`);if(e>ez||e<eH)throw new y.eO(`Int cannot represent non 32-bit signed integer value: ${e}`);return e},parseLiteral(e){if(e.kind!==R.b.INT)throw new y.eO(`Int cannot represent non-integer value: ${(0,V.y)(e)}`,{nodes:e});let t=parseInt(e.value,10);if(t>ez||t<eH)throw new y.eO(`Int cannot represent non 32-bit signed integer value: ${e.value}`,{nodes:e});return t}}),eK=new eS({name:"Float",description:"The `Float` scalar type represents signed double-precision fractional values as specified by [IEEE 754](https://en.wikipedia.org/wiki/IEEE_floating_point).",serialize(e){let t=e2(e);if("boolean"==typeof t)return+!!t;let a=t;if("string"==typeof t&&""!==t&&(a=Number(t)),"number"!=typeof a||!Number.isFinite(a))throw new y.eO(`Float cannot represent non numeric value: ${(0,v.N)(t)}`);return a},parseValue(e){if("number"!=typeof e||!Number.isFinite(e))throw new y.eO(`Float cannot represent non numeric value: ${(0,v.N)(e)}`);return e},parseLiteral(e){if(e.kind!==R.b.FLOAT&&e.kind!==R.b.INT)throw new y.eO(`Float cannot represent non numeric value: ${(0,V.y)(e)}`,e);return parseFloat(e.value)}}),eJ=new eS({name:"String",description:"The `String` scalar type represents textual data, represented as UTF-8 character sequences. The String type is most often used by GraphQL to represent free-form human-readable text.",serialize(e){let t=e2(e);if("string"==typeof t)return t;if("boolean"==typeof t)return t?"true":"false";if("number"==typeof t&&Number.isFinite(t))return t.toString();throw new y.eO(`String cannot represent value: ${(0,v.N)(e)}`)},parseValue(e){if("string"!=typeof e)throw new y.eO(`String cannot represent a non string value: ${(0,v.N)(e)}`);return e},parseLiteral(e){if(e.kind!==R.b.STRING)throw new y.eO(`String cannot represent a non string value: ${(0,V.y)(e)}`,{nodes:e});return e.value}}),eZ=new eS({name:"Boolean",description:"The `Boolean` scalar type represents `true` or `false`.",serialize(e){let t=e2(e);if("boolean"==typeof t)return t;if(Number.isFinite(t))return 0!==t;throw new y.eO(`Boolean cannot represent a non boolean value: ${(0,v.N)(t)}`)},parseValue(e){if("boolean"!=typeof e)throw new y.eO(`Boolean cannot represent a non boolean value: ${(0,v.N)(e)}`);return e},parseLiteral(e){if(e.kind!==R.b.BOOLEAN)throw new y.eO(`Boolean cannot represent a non boolean value: ${(0,V.y)(e)}`,{nodes:e});return e.value}}),eX=new eS({name:"ID",description:'The `ID` scalar type represents a unique identifier, often used to refetch an object or as key for a cache. The ID type appears in a JSON response as a String; however, it is not intended to be human-readable. When expected as an input type, any string (such as `"4"`) or integer (such as `4`) input value will be accepted as an ID.',serialize(e){let t=e2(e);if("string"==typeof t)return t;if(Number.isInteger(t))return String(t);throw new y.eO(`ID cannot represent value: ${(0,v.N)(e)}`)},parseValue(e){if("string"==typeof e)return e;if("number"==typeof e&&Number.isInteger(e))return e.toString();throw new y.eO(`ID cannot represent value: ${(0,v.N)(e)}`)},parseLiteral(e){if(e.kind!==R.b.STRING&&e.kind!==R.b.INT)throw new y.eO("ID cannot represent a non-string and non-integer value: "+(0,V.y)(e),{nodes:e});return e.value}}),e1=Object.freeze([eJ,eW,eK,eZ,eX]);function e0(e){return e1.some(({name:t})=>e.name===t)}function e2(e){if((0,E.Z)(e)){if("function"==typeof e.valueOf){let t=e.valueOf();if(!(0,E.Z)(t))return t}if("function"==typeof e.toJSON)return e.toJSON()}return e}function e6(e){return(0,w.h)(e,e3)}function e4(e){if(!e6(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL directive.`);return e}class e3{constructor(e){var t,a;this.name=P(e.name),this.description=e.description,this.locations=e.locations,this.isRepeatable=null!=(t=e.isRepeatable)&&t,this.extensions=C(e.extensions),this.astNode=e.astNode,Array.isArray(e.locations)||(0,m.U)(!1,`@${e.name} locations must be an Array.`);let r=null!=(a=e.args)?a:{};(0,E.Z)(r)&&!Array.isArray(r)||(0,m.U)(!1,`@${e.name} args must be an object with argument names as keys.`),this.args=eA(r)}get[Symbol.toStringTag](){return"GraphQLDirective"}toConfig(){return{name:this.name,description:this.description,locations:this.locations,args:eC(this.args),isRepeatable:this.isRepeatable,extensions:this.extensions,astNode:this.astNode}}toString(){return"@"+this.name}toJSON(){return this.toString()}}let e9=new e3({name:"include",description:"Directs the executor to include this field or fragment only when the `if` argument is true.",locations:[eG.H.FIELD,eG.H.FRAGMENT_SPREAD,eG.H.INLINE_FRAGMENT],args:{if:{type:new ef(eZ),description:"Included when true."}}}),e5=new e3({name:"skip",description:"Directs the executor to skip this field or fragment when the `if` argument is true.",locations:[eG.H.FIELD,eG.H.FRAGMENT_SPREAD,eG.H.INLINE_FRAGMENT],args:{if:{type:new ef(eZ),description:"Skipped when true."}}}),e8="No longer supported",e7=new e3({name:"deprecated",description:"Marks an element of a GraphQL schema as no longer supported.",locations:[eG.H.FIELD_DEFINITION,eG.H.ARGUMENT_DEFINITION,eG.H.INPUT_FIELD_DEFINITION,eG.H.ENUM_VALUE],args:{reason:{type:eJ,description:"Explains why this element was deprecated, usually also including a suggestion for how to access supported similar data. Formatted using the Markdown syntax, as specified by [CommonMark](https://commonmark.org/).",defaultValue:e8}}}),te=new e3({name:"specifiedBy",description:"Exposes a URL that specifies the behavior of this scalar.",locations:[eG.H.SCALAR],args:{url:{type:new ef(eJ),description:"The URL that specifies the behavior of this scalar."}}}),tt=new e3({name:"oneOf",description:"Indicates exactly one field must be supplied and this field must not be `null`.",locations:[eG.H.INPUT_OBJECT],args:{}}),ta=Object.freeze([e9,e5,e7,te,tt]);function tr(e){return ta.some(({name:t})=>t===e.name)}var ti=a(71306);function tn(e){return"object"==typeof e&&"function"==typeof(null==e?void 0:e[Symbol.iterator])}function tp(e,t){if(et(t)){let a=tp(e,t.ofType);return(null==a?void 0:a.kind)===R.b.NULL?null:a}if(null===e)return{kind:R.b.NULL};if(void 0===e)return null;if(X(t)){let a=t.ofType;if(tn(e)){let t=[];for(let r of e){let e=tp(r,a);null!=e&&t.push(e)}return{kind:R.b.LIST,values:t}}return tp(e,a)}if(J(t)){if(!(0,E.Z)(e))return null;let a=[];for(let r of Object.values(t.getFields())){let t=tp(e[r.name],r.type);t&&a.push({kind:R.b.OBJECT_FIELD,name:{kind:R.b.NAME,value:r.name},value:t})}return{kind:R.b.OBJECT,fields:a}}if(eo(t)){let a=t.serialize(e);if(null==a)return null;if("boolean"==typeof a)return{kind:R.b.BOOLEAN,value:a};if("number"==typeof a&&Number.isFinite(a)){let e=String(a);return to.test(e)?{kind:R.b.INT,value:e}:{kind:R.b.FLOAT,value:e}}if("string"==typeof a)return W(t)?{kind:R.b.ENUM,value:a}:t===eX&&to.test(a)?{kind:R.b.INT,value:a}:{kind:R.b.STRING,value:a};throw TypeError(`Cannot convert value to AST: ${(0,v.N)(a)}.`)}(0,ti.V)(!1,"Unexpected input type: "+(0,v.N)(t))}let to=/^-?(?:0|[1-9][0-9]*)$/,ts=new eO({name:"__Schema",description:"A GraphQL Schema defines the capabilities of a GraphQL server. It exposes all available types and directives on the server, as well as the entry points for query, mutation, and subscription operations.",fields:()=>({description:{type:eJ,resolve:e=>e.description},types:{description:"A list of all types supported by this server.",type:new ef(new em(new ef(tu))),resolve:e=>Object.values(e.getTypeMap())},queryType:{description:"The type that query operations will be rooted at.",type:new ef(tu),resolve:e=>e.getQueryType()},mutationType:{description:"If this server supports mutation, the type that mutation operations will be rooted at.",type:tu,resolve:e=>e.getMutationType()},subscriptionType:{description:"If this server support subscription, the type that subscription operations will be rooted at.",type:tu,resolve:e=>e.getSubscriptionType()},directives:{description:"A list of all directives supported by this server.",type:new ef(new em(new ef(td))),resolve:e=>e.getDirectives()}})}),td=new eO({name:"__Directive",description:"A Directive provides a way to describe alternate runtime execution and type validation behavior in a GraphQL document.\n\nIn 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 ef(eJ),resolve:e=>e.name},description:{type:eJ,resolve:e=>e.description},isRepeatable:{type:new ef(eZ),resolve:e=>e.isRepeatable},locations:{type:new ef(new em(new ef(tl))),resolve:e=>e.locations},args:{type:new ef(new em(new ef(tm))),args:{includeDeprecated:{type:eZ,defaultValue:!1}},resolve:(e,{includeDeprecated:t})=>t?e.args:e.args.filter(e=>null==e.deprecationReason)}})}),tl=new eP({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:eG.H.QUERY,description:"Location adjacent to a query operation."},MUTATION:{value:eG.H.MUTATION,description:"Location adjacent to a mutation operation."},SUBSCRIPTION:{value:eG.H.SUBSCRIPTION,description:"Location adjacent to a subscription operation."},FIELD:{value:eG.H.FIELD,description:"Location adjacent to a field."},FRAGMENT_DEFINITION:{value:eG.H.FRAGMENT_DEFINITION,description:"Location adjacent to a fragment definition."},FRAGMENT_SPREAD:{value:eG.H.FRAGMENT_SPREAD,description:"Location adjacent to a fragment spread."},INLINE_FRAGMENT:{value:eG.H.INLINE_FRAGMENT,description:"Location adjacent to an inline fragment."},VARIABLE_DEFINITION:{value:eG.H.VARIABLE_DEFINITION,description:"Location adjacent to a variable definition."},SCHEMA:{value:eG.H.SCHEMA,description:"Location adjacent to a schema definition."},SCALAR:{value:eG.H.SCALAR,description:"Location adjacent to a scalar definition."},OBJECT:{value:eG.H.OBJECT,description:"Location adjacent to an object type definition."},FIELD_DEFINITION:{value:eG.H.FIELD_DEFINITION,description:"Location adjacent to a field definition."},ARGUMENT_DEFINITION:{value:eG.H.ARGUMENT_DEFINITION,description:"Location adjacent to an argument definition."},INTERFACE:{value:eG.H.INTERFACE,description:"Location adjacent to an interface definition."},UNION:{value:eG.H.UNION,description:"Location adjacent to a union definition."},ENUM:{value:eG.H.ENUM,description:"Location adjacent to an enum definition."},ENUM_VALUE:{value:eG.H.ENUM_VALUE,description:"Location adjacent to an enum value definition."},INPUT_OBJECT:{value:eG.H.INPUT_OBJECT,description:"Location adjacent to an input object type definition."},INPUT_FIELD_DEFINITION:{value:eG.H.INPUT_FIELD_DEFINITION,description:"Location adjacent to an input object field definition."}}}),tu=new eO({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 ef(th),resolve:e=>U(e)?l.SCALAR:q(e)?l.OBJECT:Y(e)?l.INTERFACE:z(e)?l.UNION:W(e)?l.ENUM:J(e)?l.INPUT_OBJECT:X(e)?l.LIST:et(e)?l.NON_NULL:void(0,ti.V)(!1,`Unexpected type: "${(0,v.N)(e)}".`)},name:{type:eJ,resolve:e=>"name"in e?e.name:void 0},description:{type:eJ,resolve:e=>"description"in e?e.description:void 0},specifiedByURL:{type:eJ,resolve:e=>"specifiedByURL"in e?e.specifiedByURL:void 0},fields:{type:new em(new ef(tc)),args:{includeDeprecated:{type:eZ,defaultValue:!1}},resolve(e,{includeDeprecated:t}){if(q(e)||Y(e)){let a=Object.values(e.getFields());return t?a:a.filter(e=>null==e.deprecationReason)}}},interfaces:{type:new em(new ef(tu)),resolve(e){if(q(e)||Y(e))return e.getInterfaces()}},possibleTypes:{type:new em(new ef(tu)),resolve(e,t,a,{schema:r}){if(eu(e))return r.getPossibleTypes(e)}},enumValues:{type:new em(new ef(tf)),args:{includeDeprecated:{type:eZ,defaultValue:!1}},resolve(e,{includeDeprecated:t}){if(W(e)){let a=e.getValues();return t?a:a.filter(e=>null==e.deprecationReason)}}},inputFields:{type:new em(new ef(tm)),args:{includeDeprecated:{type:eZ,defaultValue:!1}},resolve(e,{includeDeprecated:t}){if(J(e)){let a=Object.values(e.getFields());return t?a:a.filter(e=>null==e.deprecationReason)}}},ofType:{type:tu,resolve:e=>"ofType"in e?e.ofType:void 0},isOneOf:{type:eZ,resolve:e=>{if(J(e))return e.isOneOf}}})}),tc=new eO({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 ef(eJ),resolve:e=>e.name},description:{type:eJ,resolve:e=>e.description},args:{type:new ef(new em(new ef(tm))),args:{includeDeprecated:{type:eZ,defaultValue:!1}},resolve:(e,{includeDeprecated:t})=>t?e.args:e.args.filter(e=>null==e.deprecationReason)},type:{type:new ef(tu),resolve:e=>e.type},isDeprecated:{type:new ef(eZ),resolve:e=>null!=e.deprecationReason},deprecationReason:{type:eJ,resolve:e=>e.deprecationReason}})}),tm=new eO({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 ef(eJ),resolve:e=>e.name},description:{type:eJ,resolve:e=>e.description},type:{type:new ef(tu),resolve:e=>e.type},defaultValue:{type:eJ,description:"A GraphQL-formatted string representing the default value for this input value.",resolve(e){let{type:t,defaultValue:a}=e,r=tp(a,t);return r?(0,V.y)(r):null}},isDeprecated:{type:new ef(eZ),resolve:e=>null!=e.deprecationReason},deprecationReason:{type:eJ,resolve:e=>e.deprecationReason}})}),tf=new eO({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 ef(eJ),resolve:e=>e.name},description:{type:eJ,resolve:e=>e.description},isDeprecated:{type:new ef(eZ),resolve:e=>null!=e.deprecationReason},deprecationReason:{type:eJ,resolve:e=>e.deprecationReason}})});(p=l||(l={})).SCALAR="SCALAR",p.OBJECT="OBJECT",p.INTERFACE="INTERFACE",p.UNION="UNION",p.ENUM="ENUM",p.INPUT_OBJECT="INPUT_OBJECT",p.LIST="LIST",p.NON_NULL="NON_NULL";let th=new eP({name:"__TypeKind",description:"An enum describing what kind of type a given `__Type` is.",values:{SCALAR:{value:l.SCALAR,description:"Indicates this type is a scalar."},OBJECT:{value:l.OBJECT,description:"Indicates this type is an object. `fields` and `interfaces` are valid fields."},INTERFACE:{value:l.INTERFACE,description:"Indicates this type is an interface. `fields`, `interfaces`, and `possibleTypes` are valid fields."},UNION:{value:l.UNION,description:"Indicates this type is a union. `possibleTypes` is a valid field."},ENUM:{value:l.ENUM,description:"Indicates this type is an enum. `enumValues` is a valid field."},INPUT_OBJECT:{value:l.INPUT_OBJECT,description:"Indicates this type is an input object. `inputFields` is a valid field."},LIST:{value:l.LIST,description:"Indicates this type is a list. `ofType` is a valid field."},NON_NULL:{value:l.NON_NULL,description:"Indicates this type is a non-null. `ofType` is a valid field."}}}),tv={name:"__schema",type:new ef(ts),description:"Access the current type schema of this server.",args:[],resolve:(e,t,a,{schema:r})=>r,deprecationReason:void 0,extensions:Object.create(null),astNode:void 0},ty={name:"__type",type:tu,description:"Request the type information of a single type.",args:[{name:"name",description:void 0,type:new ef(eJ),defaultValue:void 0,deprecationReason:void 0,extensions:Object.create(null),astNode:void 0}],resolve:(e,{name:t},a,{schema:r})=>r.getType(t),deprecationReason:void 0,extensions:Object.create(null),astNode:void 0},tg={name:"__typename",type:new ef(eJ),description:"The name of the current Object type at runtime.",args:[],resolve:(e,t,a,{parentType:r})=>r.name,deprecationReason:void 0,extensions:Object.create(null),astNode:void 0},t_=Object.freeze([ts,td,tl,tu,tc,tm,tf,th]);function tb(e){return t_.some(({name:t})=>e.name===t)}function tw(e){return(0,w.h)(e,tT)}function tE(e){if(!tw(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL schema.`);return e}class tT{constructor(e){var t,a;this.__validationErrors=!0===e.assumeValid?[]:void 0,(0,E.Z)(e)||(0,m.U)(!1,"Must provide configuration object."),!e.types||Array.isArray(e.types)||(0,m.U)(!1,`"types" must be Array if provided but got: ${(0,v.N)(e.types)}.`),!e.directives||Array.isArray(e.directives)||(0,m.U)(!1,`"directives" must be Array if provided but got: ${(0,v.N)(e.directives)}.`),this.description=e.description,this.extensions=C(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=null!=(t=e.extensionASTNodes)?t:[],this._queryType=e.query,this._mutationType=e.mutation,this._subscriptionType=e.subscription,this._directives=null!=(a=e.directives)?a:ta;let r=new Set(e.types);if(null!=e.types)for(let t of e.types)r.delete(t),tN(t,r);for(let e of(null!=this._queryType&&tN(this._queryType,r),null!=this._mutationType&&tN(this._mutationType,r),null!=this._subscriptionType&&tN(this._subscriptionType,r),this._directives))if(e6(e))for(let t of e.args)tN(t.type,r);for(let e of(tN(ts,r),this._typeMap=Object.create(null),this._subTypeMap=Object.create(null),this._implementationsMap=Object.create(null),r)){if(null==e)continue;let t=e.name;if(t||(0,m.U)(!1,"One of the provided types for building the Schema is missing a name."),void 0!==this._typeMap[t])throw Error(`Schema must contain uniquely named types but contains multiple types named "${t}".`);if(this._typeMap[t]=e,Y(e)){for(let t of e.getInterfaces())if(Y(t)){let a=this._implementationsMap[t.name];void 0===a&&(a=this._implementationsMap[t.name]={objects:[],interfaces:[]}),a.interfaces.push(e)}}else if(q(e)){for(let t of e.getInterfaces())if(Y(t)){let a=this._implementationsMap[t.name];void 0===a&&(a=this._implementationsMap[t.name]={objects:[],interfaces:[]}),a.objects.push(e)}}}}get[Symbol.toStringTag](){return"GraphQLSchema"}getQueryType(){return this._queryType}getMutationType(){return this._mutationType}getSubscriptionType(){return this._subscriptionType}getRootType(e){switch(e){case g.cE.QUERY:return this.getQueryType();case g.cE.MUTATION:return this.getMutationType();case g.cE.SUBSCRIPTION:return this.getSubscriptionType()}}getTypeMap(){return this._typeMap}getType(e){return this.getTypeMap()[e]}getPossibleTypes(e){return z(e)?e.getTypes():this.getImplementations(e).objects}getImplementations(e){let t=this._implementationsMap[e.name];return null!=t?t:{objects:[],interfaces:[]}}isSubType(e,t){let a=this._subTypeMap[e.name];if(void 0===a){if(a=Object.create(null),z(e))for(let t of e.getTypes())a[t.name]=!0;else{let t=this.getImplementations(e);for(let e of t.objects)a[e.name]=!0;for(let e of t.interfaces)a[e.name]=!0}this._subTypeMap[e.name]=a}return void 0!==a[t.name]}getDirectives(){return this._directives}getDirective(e){return this.getDirectives().find(t=>t.name===e)}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:void 0!==this.__validationErrors}}}function tN(e,t){let a=eE(e);if(!t.has(a)){if(t.add(a),z(a))for(let e of a.getTypes())tN(e,t);else if(q(a)||Y(a)){for(let e of a.getInterfaces())tN(e,t);for(let e of Object.values(a.getFields()))for(let a of(tN(e.type,t),e.args))tN(a.type,t)}else if(J(a))for(let e of Object.values(a.getFields()))tN(e.type,t)}return t}function tS(e){var t,a,r,i;let n,p,o,s;if(tE(e),e.__validationErrors)return e.__validationErrors;let d=new tI(e);(p=(n=(t=d).schema).getQueryType())?q(p)||t.reportError(`Query root type must be Object type, it cannot be ${(0,v.N)(p)}.`,null!=(a=tD(n,g.cE.QUERY))?a:p.astNode):t.reportError("Query root type must be provided.",n.astNode),(o=n.getMutationType())&&!q(o)&&t.reportError(`Mutation root type must be Object type if provided, it cannot be ${(0,v.N)(o)}.`,null!=(r=tD(n,g.cE.MUTATION))?r:o.astNode),(s=n.getSubscriptionType())&&!q(s)&&t.reportError(`Subscription root type must be Object type if provided, it cannot be ${(0,v.N)(s)}.`,null!=(i=tD(n,g.cE.SUBSCRIPTION))?i:s.astNode),function(e){for(let a of e.schema.getDirectives()){if(!e6(a)){e.reportError(`Expected directive but got: ${(0,v.N)(a)}.`,null==a?void 0:a.astNode);continue}for(let r of(tA(e,a),0===a.locations.length&&e.reportError(`Directive @${a.name} must include 1 or more locations.`,a.astNode),a.args))if(tA(e,r),er(r.type)||e.reportError(`The type of @${a.name}(${r.name}:) must be Input Type but got: ${(0,v.N)(r.type)}.`,r.astNode),eR(r)&&null!=r.deprecationReason){var t;e.reportError(`Required argument @${a.name}(${r.name}:) cannot be deprecated.`,[tC(r.astNode),null==(t=r.astNode)?void 0:t.type])}}}(d),function(e){var t;let a,r,i,n=(t=e,a=Object.create(null),r=[],i=Object.create(null),function e(n){if(!a[n.name]){for(let p of(a[n.name]=!0,i[n.name]=r.length,Object.values(n.getFields())))if(et(p.type)&&J(p.type.ofType)){let a=p.type.ofType,n=i[a.name];if(r.push(p),void 0===n)e(a);else{let e=r.slice(n),i=e.map(e=>e.name).join(".");t.reportError(`Cannot reference Input Object "${a.name}" within itself through a series of non-null fields: "${i}".`,e.map(e=>e.astNode))}r.pop()}i[n.name]=void 0}});for(let t of Object.values(e.schema.getTypeMap())){if(!eb(t)){e.reportError(`Expected GraphQL named type but got: ${(0,v.N)(t)}.`,t.astNode);continue}tb(t)||tA(e,t),q(t)||Y(t)?(function(e,t){let a=Object.values(t.getFields());for(let p of(0===a.length&&e.reportError(`Type ${t.name} must define one or more fields.`,[t.astNode,...t.extensionASTNodes]),a)){var r,i,n;for(let a of(tA(e,p),en(p.type)||e.reportError(`The type of ${t.name}.${p.name} must be Output Type but got: ${(0,v.N)(p.type)}.`,null==(r=p.astNode)?void 0:r.type),p.args)){let r=a.name;tA(e,a),er(a.type)||e.reportError(`The type of ${t.name}.${p.name}(${r}:) must be Input Type but got: ${(0,v.N)(a.type)}.`,null==(i=a.astNode)?void 0:i.type),eR(a)&&null!=a.deprecationReason&&e.reportError(`Required argument ${t.name}.${p.name}(${r}:) cannot be deprecated.`,[tC(a.astNode),null==(n=a.astNode)?void 0:n.type])}}}(e,t),function(e,t){let a=Object.create(null);for(let r of t.getInterfaces()){if(!Y(r)){e.reportError(`Type ${(0,v.N)(t)} must only implement Interface types, it cannot implement ${(0,v.N)(r)}.`,tk(t,r));continue}if(t===r){e.reportError(`Type ${t.name} cannot implement itself because it would create a circular reference.`,tk(t,r));continue}if(a[r.name]){e.reportError(`Type ${t.name} can only implement ${r.name} once.`,tk(t,r));continue}a[r.name]=!0,function(e,t,a){let r=t.getInterfaces();for(let i of a.getInterfaces())r.includes(i)||e.reportError(i===t?`Type ${t.name} cannot implement ${a.name} because it would create a circular reference.`:`Type ${t.name} must implement ${i.name} because it is implemented by ${a.name}.`,[...tk(a,i),...tk(t,a)])}(e,t,r),function(e,t,a){let r=t.getFields();for(let s of Object.values(a.getFields())){var i,n,p,o;let d=s.name,l=r[d];if(!l){e.reportError(`Interface field ${a.name}.${d} expected but ${t.name} does not provide it.`,[s.astNode,t.astNode,...t.extensionASTNodes]);continue}for(let r of(eQ(e.schema,l.type,s.type)||e.reportError(`Interface field ${a.name}.${d} expects type ${(0,v.N)(s.type)} but ${t.name}.${d} is type ${(0,v.N)(l.type)}.`,[null==(i=s.astNode)?void 0:i.type,null==(n=l.astNode)?void 0:n.type]),s.args)){let i=r.name,n=l.args.find(e=>e.name===i);if(!n){e.reportError(`Interface field argument ${a.name}.${d}(${i}:) expected but ${t.name}.${d} does not provide it.`,[r.astNode,l.astNode]);continue}eq(r.type,n.type)||e.reportError(`Interface field argument ${a.name}.${d}(${i}:) expects type ${(0,v.N)(r.type)} but ${t.name}.${d}(${i}:) is type ${(0,v.N)(n.type)}.`,[null==(p=r.astNode)?void 0:p.type,null==(o=n.astNode)?void 0:o.type])}for(let r of l.args){let i=r.name;!s.args.find(e=>e.name===i)&&eR(r)&&e.reportError(`Object field ${t.name}.${d} includes required argument ${i} that is missing from the Interface field ${a.name}.${d}.`,[r.astNode,s.astNode])}}}(e,t,r)}}(e,t)):z(t)?function(e,t){let a=t.getTypes();0===a.length&&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 a){if(r[i.name]){e.reportError(`Union type ${t.name} can only include type ${i.name} once.`,tx(t,i.name));continue}r[i.name]=!0,q(i)||e.reportError(`Union type ${t.name} can only include Object types, it cannot include ${(0,v.N)(i)}.`,tx(t,String(i)))}}(e,t):W(t)?function(e,t){let a=t.getValues();for(let r of(0===a.length&&e.reportError(`Enum type ${t.name} must define one or more values.`,[t.astNode,...t.extensionASTNodes]),a))tA(e,r)}(e,t):J(t)&&(function(e,t){let a=Object.values(t.getFields());for(let n of(0===a.length&&e.reportError(`Input Object type ${t.name} must define one or more fields.`,[t.astNode,...t.extensionASTNodes]),a)){var r,i;tA(e,n),er(n.type)||e.reportError(`The type of ${t.name}.${n.name} must be Input Type but got: ${(0,v.N)(n.type)}.`,null==(r=n.astNode)?void 0:r.type),eB(n)&&null!=n.deprecationReason&&e.reportError(`Required input field ${t.name}.${n.name} cannot be deprecated.`,[tC(n.astNode),null==(i=n.astNode)?void 0:i.type]),t.isOneOf&&function(e,t,a){if(et(t.type)){var r;a.reportError(`OneOf input field ${e.name}.${t.name} must be nullable.`,null==(r=t.astNode)?void 0:r.type)}void 0!==t.defaultValue&&a.reportError(`OneOf input field ${e.name}.${t.name} cannot have a default value.`,t.astNode)}(t,n,e)}}(e,t),n(t))}}(d);let l=d.getErrors();return e.__validationErrors=l,l}function tO(e){let t=tS(e);if(0!==t.length)throw Error(t.map(e=>e.message).join("\n\n"))}class tI{constructor(e){this._errors=[],this.schema=e}reportError(e,t){let a=Array.isArray(t)?t.filter(Boolean):t;this._errors.push(new y.eO(e,{nodes:a}))}getErrors(){return this._errors}}function tD(e,t){var a;return null==(a=[e.astNode,...e.extensionASTNodes].flatMap(e=>{var t;return null!=(t=null==e?void 0:e.operationTypes)?t:[]}).find(e=>e.operation===t))?void 0:a.type}function tA(e,t){t.name.startsWith("__")&&e.reportError(`Name "${t.name}" must not begin with "__", which is reserved by GraphQL introspection.`,t.astNode)}function tk(e,t){let{astNode:a,extensionASTNodes:r}=e;return(null!=a?[a,...r]:r).flatMap(e=>{var t;return null!=(t=e.interfaces)?t:[]}).filter(e=>e.name.value===t.name)}function tx(e,t){let{astNode:a,extensionASTNodes:r}=e;return(null!=a?[a,...r]:r).flatMap(e=>{var t;return null!=(t=e.types)?t:[]}).filter(e=>e.name.value===t)}function tC(e){var t;return null==e||null==(t=e.directives)?void 0:t.find(e=>e.name.value===e7.name)}var tR=a(90424);function tV(e,t){switch(t.kind){case R.b.LIST_TYPE:{let a=tV(e,t.type);return a&&new em(a)}case R.b.NON_NULL_TYPE:{let a=tV(e,t.type);return a&&new ef(a)}case R.b.NAMED_TYPE:return e.getType(t.name.value)}}class tF{constructor(e,t,a){this._schema=e,this._typeStack=[],this._parentTypeStack=[],this._inputTypeStack=[],this._fieldDefStack=[],this._defaultValueStack=[],this._directive=null,this._argument=null,this._enumValue=null,this._getFieldDef=null!=a?a:t$,t&&(er(t)&&this._inputTypeStack.push(t),ed(t)&&this._parentTypeStack.push(t),en(t)&&this._typeStack.push(t))}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(e){let t=this._schema;switch(e.kind){case R.b.SELECTION_SET:{let e=eE(this.getType());this._parentTypeStack.push(ed(e)?e:void 0);break}case R.b.FIELD:{let a,r,i=this.getParentType();i&&(a=this._getFieldDef(t,i,e))&&(r=a.type),this._fieldDefStack.push(a),this._typeStack.push(en(r)?r:void 0);break}case R.b.DIRECTIVE:this._directive=t.getDirective(e.name.value);break;case R.b.OPERATION_DEFINITION:{let a=t.getRootType(e.operation);this._typeStack.push(q(a)?a:void 0);break}case R.b.INLINE_FRAGMENT:case R.b.FRAGMENT_DEFINITION:{let a=e.typeCondition,r=a?tV(t,a):eE(this.getType());this._typeStack.push(en(r)?r:void 0);break}case R.b.VARIABLE_DEFINITION:{let a=tV(t,e.type);this._inputTypeStack.push(er(a)?a:void 0);break}case R.b.ARGUMENT:{var a;let t,r,i=null!=(a=this.getDirective())?a:this.getFieldDef();i&&(t=i.args.find(t=>t.name===e.name.value))&&(r=t.type),this._argument=t,this._defaultValueStack.push(t?t.defaultValue:void 0),this._inputTypeStack.push(er(r)?r:void 0);break}case R.b.LIST:{let e=e_(this.getInputType()),t=X(e)?e.ofType:e;this._defaultValueStack.push(void 0),this._inputTypeStack.push(er(t)?t:void 0);break}case R.b.OBJECT_FIELD:{let t,a,r=eE(this.getInputType());J(r)&&(a=r.getFields()[e.name.value])&&(t=a.type),this._defaultValueStack.push(a?a.defaultValue:void 0),this._inputTypeStack.push(er(t)?t:void 0);break}case R.b.ENUM:{let t,a=eE(this.getInputType());W(a)&&(t=a.getValue(e.value)),this._enumValue=t}}}leave(e){switch(e.kind){case R.b.SELECTION_SET:this._parentTypeStack.pop();break;case R.b.FIELD:this._fieldDefStack.pop(),this._typeStack.pop();break;case R.b.DIRECTIVE:this._directive=null;break;case R.b.OPERATION_DEFINITION:case R.b.INLINE_FRAGMENT:case R.b.FRAGMENT_DEFINITION:this._typeStack.pop();break;case R.b.VARIABLE_DEFINITION:this._inputTypeStack.pop();break;case R.b.ARGUMENT:this._argument=null,this._defaultValueStack.pop(),this._inputTypeStack.pop();break;case R.b.LIST:case R.b.OBJECT_FIELD:this._defaultValueStack.pop(),this._inputTypeStack.pop();break;case R.b.ENUM:this._enumValue=null}}}function t$(e,t,a){let r=a.name.value;return r===tv.name&&e.getQueryType()===t?tv:r===ty.name&&e.getQueryType()===t?ty:r===tg.name&&ed(t)?tg:q(t)||Y(t)?t.getFields()[r]:void 0}function tP(e,t){return{enter(...a){let r=a[0];e.enter(r);let i=(0,tR.XO)(t,r.kind).enter;if(i){let n=i.apply(t,a);return void 0!==n&&(e.leave(r),(0,g.Ll)(n)&&e.enter(n)),n}},leave(...a){let r,i=a[0],n=(0,tR.XO)(t,i.kind).leave;return n&&(r=n.apply(t,a)),e.leave(i),r}}}var tL=a(3420);function tj(e){return{Document(t){for(let a of t.definitions)if(!(0,tL._m)(a)){let t=a.kind===R.b.SCHEMA_DEFINITION||a.kind===R.b.SCHEMA_EXTENSION?"schema":'"'+a.name.value+'"';e.reportError(new y.eO(`The ${t} definition is not executable.`,{nodes:a}))}return!1}}}function tM(e){return{Field(t){let a=e.getParentType();if(a&&!e.getFieldDef()){var r,i;let n=e.getSchema(),p=t.name.value,o=_("to use an inline fragment on",function(e,t,a){if(!eu(t))return[];let r=new Set,i=Object.create(null);for(let p of e.getPossibleTypes(t))if(p.getFields()[a])for(let e of(r.add(p),i[p.name]=1,p.getInterfaces())){var n;e.getFields()[a]&&(r.add(e),i[e.name]=(null!=(n=i[e.name])?n:0)+1)}return[...r].sort((t,a)=>{let r=i[a.name]-i[t.name];return 0!==r?r:Y(t)&&e.isSubType(t,a)?-1:Y(a)&&e.isSubType(a,t)?1:O(t.name,a.name)}).map(e=>e.name)}(n,a,p));""===o&&(o=_((r=a,i=p,q(r)||Y(r)?A(i,Object.keys(r.getFields())):[]))),e.reportError(new y.eO(`Cannot query field "${p}" on type "${a.name}".`+o,{nodes:t}))}}}}function tU(e){return{InlineFragment(t){let a=t.typeCondition;if(a){let t=tV(e.getSchema(),a);if(t&&!ed(t)){let t=(0,V.y)(a);e.reportError(new y.eO(`Fragment cannot condition on non composite type "${t}".`,{nodes:a}))}}},FragmentDefinition(t){let a=tV(e.getSchema(),t.typeCondition);if(a&&!ed(a)){let a=(0,V.y)(t.typeCondition);e.reportError(new y.eO(`Fragment "${t.name.value}" cannot condition on non composite type "${a}".`,{nodes:t.typeCondition}))}}}}function tB(e){return{...tq(e),Argument(t){let a=e.getArgument(),r=e.getFieldDef(),i=e.getParentType();if(!a&&r&&i){let a=t.name.value,n=A(a,r.args.map(e=>e.name));e.reportError(new y.eO(`Unknown argument "${a}" on field "${i.name}.${r.name}".`+_(n),{nodes:t}))}}}}function tq(e){let t=Object.create(null),a=e.getSchema();for(let e of a?a.getDirectives():ta)t[e.name]=e.args.map(e=>e.name);for(let a of e.getDocument().definitions)if(a.kind===R.b.DIRECTIVE_DEFINITION){var r;let e=null!=(r=a.arguments)?r:[];t[a.name.value]=e.map(e=>e.name.value)}return{Directive(a){let r=a.name.value,i=t[r];if(a.arguments&&i)for(let t of a.arguments){let a=t.name.value;if(!i.includes(a)){let n=A(a,i);e.reportError(new y.eO(`Unknown argument "${a}" on directive "@${r}".`+_(n),{nodes:t}))}}return!1}}}function tQ(e){let t=Object.create(null),a=e.getSchema();for(let e of a?a.getDirectives():ta)t[e.name]=e.locations;for(let a of e.getDocument().definitions)a.kind===R.b.DIRECTIVE_DEFINITION&&(t[a.name.value]=a.locations.map(e=>e.value));return{Directive(a,r,i,n,p){let o=a.name.value,s=t[o];if(!s)return void e.reportError(new y.eO(`Unknown directive "@${o}".`,{nodes:a}));let d=function(e){let t=e[e.length-1];switch("kind"in t||(0,ti.V)(!1),t.kind){case R.b.OPERATION_DEFINITION:var a=t.operation;switch(a){case g.cE.QUERY:return eG.H.QUERY;case g.cE.MUTATION:return eG.H.MUTATION;case g.cE.SUBSCRIPTION:return eG.H.SUBSCRIPTION}return;case R.b.FIELD:return eG.H.FIELD;case R.b.FRAGMENT_SPREAD:return eG.H.FRAGMENT_SPREAD;case R.b.INLINE_FRAGMENT:return eG.H.INLINE_FRAGMENT;case R.b.FRAGMENT_DEFINITION:return eG.H.FRAGMENT_DEFINITION;case R.b.VARIABLE_DEFINITION:return eG.H.VARIABLE_DEFINITION;case R.b.SCHEMA_DEFINITION:case R.b.SCHEMA_EXTENSION:return eG.H.SCHEMA;case R.b.SCALAR_TYPE_DEFINITION:case R.b.SCALAR_TYPE_EXTENSION:return eG.H.SCALAR;case R.b.OBJECT_TYPE_DEFINITION:case R.b.OBJECT_TYPE_EXTENSION:return eG.H.OBJECT;case R.b.FIELD_DEFINITION:return eG.H.FIELD_DEFINITION;case R.b.INTERFACE_TYPE_DEFINITION:case R.b.INTERFACE_TYPE_EXTENSION:return eG.H.INTERFACE;case R.b.UNION_TYPE_DEFINITION:case R.b.UNION_TYPE_EXTENSION:return eG.H.UNION;case R.b.ENUM_TYPE_DEFINITION:case R.b.ENUM_TYPE_EXTENSION:return eG.H.ENUM;case R.b.ENUM_VALUE_DEFINITION:return eG.H.ENUM_VALUE;case R.b.INPUT_OBJECT_TYPE_DEFINITION:case R.b.INPUT_OBJECT_TYPE_EXTENSION:return eG.H.INPUT_OBJECT;case R.b.INPUT_VALUE_DEFINITION:{let t=e[e.length-3];return"kind"in t||(0,ti.V)(!1),t.kind===R.b.INPUT_OBJECT_TYPE_DEFINITION?eG.H.INPUT_FIELD_DEFINITION:eG.H.ARGUMENT_DEFINITION}default:(0,ti.V)(!1,"Unexpected kind: "+(0,v.N)(t.kind))}}(p);d&&!s.includes(d)&&e.reportError(new y.eO(`Directive "@${o}" may not be used on ${d}.`,{nodes:a}))}}}function tY(e){return{FragmentSpread(t){let a=t.name.value;e.getFragment(a)||e.reportError(new y.eO(`Unknown fragment "${a}".`,{nodes:t.name}))}}}function tG(e){let t=e.getSchema(),a=t?t.getTypeMap():Object.create(null),r=Object.create(null);for(let t of e.getDocument().definitions)(0,tL.a6)(t)&&(r[t.name.value]=!0);let i=[...Object.keys(a),...Object.keys(r)];return{NamedType(t,n,p,o,s){let d=t.name.value;if(!a[d]&&!r[d]){var l,u;let a=null!=(l=s[2])?l:p,r=null!=a&&"kind"in(u=a)&&((0,tL.xu)(u)||(0,tL.fT)(u));if(r&&tz.includes(d))return;let n=A(d,r?tz.concat(i):i);e.reportError(new y.eO(`Unknown type "${d}".`+_(n),{nodes:t}))}}}}let tz=[...e1,...t_].map(e=>e.name);function tH(e){let t=0;return{Document(e){t=e.definitions.filter(e=>e.kind===R.b.OPERATION_DEFINITION).length},OperationDefinition(a){!a.name&&t>1&&e.reportError(new y.eO("This anonymous operation must be the only defined operation.",{nodes:a}))}}}function tW(e){var t,a,r;let i=e.getSchema(),n=null!=(t=null!=(a=null!=(r=null==i?void 0:i.astNode)?r:null==i?void 0:i.getQueryType())?a:null==i?void 0:i.getMutationType())?t:null==i?void 0:i.getSubscriptionType(),p=0;return{SchemaDefinition(t){n?e.reportError(new y.eO("Cannot define a new schema within a schema extension.",{nodes:t})):(p>0&&e.reportError(new y.eO("Must provide only one schema definition.",{nodes:t})),++p)}}}function tK(e){return{Field(t){if(("__schema"===t.name.value||"__type"===t.name.value)&&function t(a,r=Object.create(null),i=0){if(a.kind===R.b.FRAGMENT_SPREAD){let n=a.name.value;if(!0===r[n])return!1;let p=e.getFragment(n);if(!p)return!1;try{return r[n]=!0,t(p,r,i)}finally{r[n]=void 0}}if(a.kind===R.b.FIELD&&("fields"===a.name.value||"interfaces"===a.name.value||"possibleTypes"===a.name.value||"inputFields"===a.name.value)&&++i>=3)return!0;if("selectionSet"in a&&a.selectionSet){for(let e of a.selectionSet.selections)if(t(e,r,i))return!0}return!1}(t))return e.reportError(new y.eO("Maximum introspection depth exceeded",{nodes:[t]})),!1}}}function tJ(e){let t=Object.create(null),a=[],r=Object.create(null);return{OperationDefinition:()=>!1,FragmentDefinition:i=>((function i(n){if(t[n.name.value])return;let p=n.name.value;t[p]=!0;let o=e.getFragmentSpreads(n.selectionSet);if(0!==o.length){for(let t of(r[p]=a.length,o)){let n=t.name.value,p=r[n];if(a.push(t),void 0===p){let t=e.getFragment(n);t&&i(t)}else{let t=a.slice(p),r=t.slice(0,-1).map(e=>'"'+e.name.value+'"').join(", ");e.reportError(new y.eO(`Cannot spread fragment "${n}" within itself`+(""!==r?` via ${r}.`:"."),{nodes:t}))}a.pop()}r[p]=void 0}})(i),!1)}}function tZ(e){let t=Object.create(null);return{OperationDefinition:{enter(){t=Object.create(null)},leave(a){for(let{node:r}of e.getRecursiveVariableUsages(a)){let i=r.name.value;!0!==t[i]&&e.reportError(new y.eO(a.name?`Variable "$${i}" is not defined by operation "${a.name.value}".`:`Variable "$${i}" is not defined.`,{nodes:[r,a]}))}}},VariableDefinition(e){t[e.variable.name.value]=!0}}}function tX(e){let t=[],a=[];return{OperationDefinition:e=>(t.push(e),!1),FragmentDefinition:e=>(a.push(e),!1),Document:{leave(){let r=Object.create(null);for(let a of t)for(let t of e.getRecursivelyReferencedFragments(a))r[t.name.value]=!0;for(let t of a){let a=t.name.value;!0!==r[a]&&e.reportError(new y.eO(`Fragment "${a}" is never used.`,{nodes:t}))}}}}}function t1(e){let t=[];return{OperationDefinition:{enter(){t=[]},leave(a){let r=Object.create(null);for(let{node:t}of e.getRecursiveVariableUsages(a))r[t.name.value]=!0;for(let i of t){let t=i.variable.name.value;!0!==r[t]&&e.reportError(new y.eO(a.name?`Variable "$${t}" is never used in operation "${a.name.value}".`:`Variable "$${t}" is never used.`,{nodes:i}))}}},VariableDefinition(e){t.push(e)}}}function t0(e){switch(e.kind){case R.b.OBJECT:return{...e,fields:e.fields.map(e=>({...e,value:t0(e.value)})).sort((e,t)=>O(e.name.value,t.name.value))};case R.b.LIST:return{...e,values:e.values.map(t0)};case R.b.INT:case R.b.FLOAT:case R.b.STRING:case R.b.BOOLEAN:case R.b.NULL:case R.b.ENUM:case R.b.VARIABLE:return e}}function t2(e){let t=new t7,a=new ae,r=new Map;return{SelectionSet(i){for(let[[n,p],o,s]of function(e,t,a,r,i,n){let p=[],[o,s]=t5(e,t,i,n);if(function(e,t,a,r,i,n){for(let[p,o]of Object.entries(n))if(o.length>1)for(let n=0;n<o.length;n++)for(let s=n+1;s<o.length;s++){let d=t9(e,a,r,i,!1,p,o[n],o[s]);d&&t.push(d)}}(e,p,t,a,r,o),0!==s.length)for(let i=0;i<s.length;i++){t6(e,p,t,a,r,!1,o,s[i]);for(let n=i+1;n<s.length;n++)t4(e,p,t,a,r,!1,s[i],s[n])}return p}(e,r,t,a,e.getParentType(),i)){let t=function e(t){return Array.isArray(t)?t.map(([t,a])=>`subfields "${t}" conflict because `+e(a)).join(" and "):t}(p);e.reportError(new y.eO(`Fields "${n}" conflict because ${t}. Use different aliases on the fields to fetch both if this was intentional.`,{nodes:o.concat(s)}))}}}}function t6(e,t,a,r,i,n,p,o){if(r.has(p,o,n))return;r.add(p,o,n);let s=e.getFragment(o);if(!s)return;let[d,l]=t8(e,a,s);if(p!==d)for(let o of(t3(e,t,a,r,i,n,p,d),l))t6(e,t,a,r,i,n,p,o)}function t4(e,t,a,r,i,n,p,o){if(p===o||i.has(p,o,n))return;i.add(p,o,n);let s=e.getFragment(p),d=e.getFragment(o);if(!s||!d)return;let[l,u]=t8(e,a,s),[c,m]=t8(e,a,d);for(let o of(t3(e,t,a,r,i,n,l,c),m))t4(e,t,a,r,i,n,p,o);for(let p of u)t4(e,t,a,r,i,n,p,o)}function t3(e,t,a,r,i,n,p,o){for(let[s,d]of Object.entries(p)){let p=o[s];if(p)for(let o of d)for(let d of p){let p=t9(e,a,r,i,n,s,o,d);p&&t.push(p)}}}function t9(e,t,a,r,i,n,p,o){let[s,d,l]=p,[u,c,m]=o,f=i||s!==u&&q(s)&&q(u);if(!f){let e=d.name.value,t=c.name.value;if(e!==t)return[[n,`"${e}" and "${t}" are different fields`],[d],[c]];if(!function(e,t){let a=e.arguments,r=t.arguments;if(void 0===a||0===a.length)return void 0===r||0===r.length;if(void 0===r||0===r.length||a.length!==r.length)return!1;let i=new Map(r.map(({name:e,value:t})=>[e.value,t]));return a.every(e=>{let t=e.value,a=i.get(e.name.value);return void 0!==a&&function(e){return(0,V.y)(t0(e))}(t)===function(e){return(0,V.y)(t0(e))}(a)})}(d,c))return[[n,"they have differing arguments"],[d],[c]]}let h=null==l?void 0:l.type,y=null==m?void 0:m.type;if(h&&y&&function e(t,a){return X(t)?!X(a)||e(t.ofType,a.ofType):!!X(a)||(et(t)?!et(a)||e(t.ofType,a.ofType):!!et(a)||!!(eo(t)||eo(a))&&t!==a)}(h,y))return[[n,`they return conflicting types "${(0,v.N)(h)}" and "${(0,v.N)(y)}"`],[d],[c]];let g=d.selectionSet,_=c.selectionSet;if(g&&_){var b=function(e,t,a,r,i,n,p,o,s){let d=[],[l,u]=t5(e,t,n,p),[c,m]=t5(e,t,o,s);for(let n of(t3(e,d,t,a,r,i,l,c),m))t6(e,d,t,a,r,i,l,n);for(let n of u)t6(e,d,t,a,r,i,c,n);for(let n of u)for(let p of m)t4(e,d,t,a,r,i,n,p);return d}(e,t,a,r,f,eE(h),g,eE(y),_),w=n,E=d,T=c;return b.length>0?[[w,b.map(([e])=>e)],[E,...b.map(([,e])=>e).flat()],[T,...b.map(([,,e])=>e).flat()]]:void 0}}function t5(e,t,a,r){let i=t.get(r);if(i)return i;let n=Object.create(null),p=Object.create(null);!function e(t,a,r,i,n){for(let p of r.selections)switch(p.kind){case R.b.FIELD:{let e,t=p.name.value;(q(a)||Y(a))&&(e=a.getFields()[t]);let r=p.alias?p.alias.value:t;i[r]||(i[r]=[]),i[r].push([a,p,e]);break}case R.b.FRAGMENT_SPREAD:n[p.name.value]=!0;break;case R.b.INLINE_FRAGMENT:{let r=p.typeCondition,o=r?tV(t.getSchema(),r):a;e(t,o,p.selectionSet,i,n)}}}(e,a,r,n,p);let o=[n,Object.keys(p)];return t.set(r,o),o}function t8(e,t,a){let r=t.get(a.selectionSet);if(r)return r;let i=tV(e.getSchema(),a.typeCondition);return t5(e,t,i,a.selectionSet)}class t7{constructor(){this._data=new Map}has(e,t,a){var r;let i=null==(r=this._data.get(e))?void 0:r.get(t);return void 0!==i&&(!!a||a===i)}add(e,t,a){let r=this._data.get(e);void 0===r?this._data.set(e,new Map([[t,a]])):r.set(t,a)}}class ae{constructor(){this._orderedPairSet=new t7}has(e,t,a){return e<t?this._orderedPairSet.has(e,t,a):this._orderedPairSet.has(t,e,a)}add(e,t,a){e<t?this._orderedPairSet.add(e,t,a):this._orderedPairSet.add(t,e,a)}}function at(e){return{InlineFragment(t){let a=e.getType(),r=e.getParentType();if(ed(a)&&ed(r)&&!eY(e.getSchema(),a,r)){let i=(0,v.N)(r),n=(0,v.N)(a);e.reportError(new y.eO(`Fragment cannot be spread here as objects of type "${i}" can never be of type "${n}".`,{nodes:t}))}},FragmentSpread(t){let a=t.name.value,r=function(e,t){let a=e.getFragment(t);if(a){let t=tV(e.getSchema(),a.typeCondition);if(ed(t))return t}}(e,a),i=e.getParentType();if(r&&i&&!eY(e.getSchema(),r,i)){let n=(0,v.N)(i),p=(0,v.N)(r);e.reportError(new y.eO(`Fragment "${a}" cannot be spread here as objects of type "${n}" can never be of type "${p}".`,{nodes:t}))}}}}function aa(e){let t=e.getSchema(),a=Object.create(null);for(let t of e.getDocument().definitions)(0,tL.a6)(t)&&(a[t.name.value]=t);return{ScalarTypeExtension:r,ObjectTypeExtension:r,InterfaceTypeExtension:r,UnionTypeExtension:r,EnumTypeExtension:r,InputObjectTypeExtension:r};function r(r){var i;let n,p=r.name.value,o=a[p],s=null==t?void 0:t.getType(p);if(o?n=ar[o.kind]:s&&(n=U(i=s)?R.b.SCALAR_TYPE_EXTENSION:q(i)?R.b.OBJECT_TYPE_EXTENSION:Y(i)?R.b.INTERFACE_TYPE_EXTENSION:z(i)?R.b.UNION_TYPE_EXTENSION:W(i)?R.b.ENUM_TYPE_EXTENSION:J(i)?R.b.INPUT_OBJECT_TYPE_EXTENSION:void(0,ti.V)(!1,"Unexpected type: "+(0,v.N)(i))),n){if(n!==r.kind){let t=function(e){switch(e){case R.b.SCALAR_TYPE_EXTENSION:return"scalar";case R.b.OBJECT_TYPE_EXTENSION:return"object";case R.b.INTERFACE_TYPE_EXTENSION:return"interface";case R.b.UNION_TYPE_EXTENSION:return"union";case R.b.ENUM_TYPE_EXTENSION:return"enum";case R.b.INPUT_OBJECT_TYPE_EXTENSION:return"input object";default:(0,ti.V)(!1,"Unexpected kind: "+(0,v.N)(e))}}(r.kind);e.reportError(new y.eO(`Cannot extend non-${t} type "${p}".`,{nodes:o?[o,r]:r}))}}else{let i=A(p,Object.keys({...a,...null==t?void 0:t.getTypeMap()}));e.reportError(new y.eO(`Cannot extend type "${p}" because it is not defined.`+_(i),{nodes:r.name}))}}}let ar={[R.b.SCALAR_TYPE_DEFINITION]:R.b.SCALAR_TYPE_EXTENSION,[R.b.OBJECT_TYPE_DEFINITION]:R.b.OBJECT_TYPE_EXTENSION,[R.b.INTERFACE_TYPE_DEFINITION]:R.b.INTERFACE_TYPE_EXTENSION,[R.b.UNION_TYPE_DEFINITION]:R.b.UNION_TYPE_EXTENSION,[R.b.ENUM_TYPE_DEFINITION]:R.b.ENUM_TYPE_EXTENSION,[R.b.INPUT_OBJECT_TYPE_DEFINITION]:R.b.INPUT_OBJECT_TYPE_EXTENSION};function ai(e){return{...an(e),Field:{leave(t){var a;let r=e.getFieldDef();if(!r)return!1;let i=new Set(null==(a=t.arguments)?void 0:a.map(e=>e.name.value));for(let a of r.args)if(!i.has(a.name)&&eR(a)){let i=(0,v.N)(a.type);e.reportError(new y.eO(`Field "${r.name}" argument "${a.name}" of type "${i}" is required, but it was not provided.`,{nodes:t}))}}}}}function an(e){var t,a;let r=Object.create(null),i=e.getSchema();for(let e of null!=(t=null==i?void 0:i.getDirectives())?t:ta)r[e.name]=T(e.args.filter(eR),e=>e.name);for(let t of e.getDocument().definitions)if(t.kind===R.b.DIRECTIVE_DEFINITION){let e=null!=(a=t.arguments)?a:[];r[t.name.value]=T(e.filter(ap),e=>e.name.value)}return{Directive:{leave(t){let a=t.name.value,i=r[a];if(i){var n;let r=new Set((null!=(n=t.arguments)?n:[]).map(e=>e.name.value));for(let[n,p]of Object.entries(i))if(!r.has(n)){let r=j(p.type)?(0,v.N)(p.type):(0,V.y)(p.type);e.reportError(new y.eO(`Directive "@${a}" argument "${n}" of type "${r}" is required, but it was not provided.`,{nodes:t}))}}}}}}function ap(e){return e.type.kind===R.b.NON_NULL_TYPE&&null==e.defaultValue}function ao(e){return{Field(t){let a=e.getType(),r=t.selectionSet;if(a)if(eo(eE(a))){if(r){let i=t.name.value,n=(0,v.N)(a);e.reportError(new y.eO(`Field "${i}" must not have a selection since type "${n}" has no subfields.`,{nodes:r}))}}else if(r){if(0===r.selections.length){let r=t.name.value,i=(0,v.N)(a);e.reportError(new y.eO(`Field "${r}" of type "${i}" must have at least one field selected.`,{nodes:t}))}}else{let r=t.name.value,i=(0,v.N)(a);e.reportError(new y.eO(`Field "${r}" of type "${i}" must have a selection of subfields. Did you mean "${r} { ... }"?`,{nodes:t}))}}}}function as(e){return e.map(e=>"number"==typeof e?"["+e.toString()+"]":"."+e).join("")}function ad(e,t,a){return{prev:e,key:t,typename:a}}function al(e){let t=[],a=e;for(;a;)t.push(a.key),a=a.prev;return t.reverse()}function au(e,t,a=ac){return function e(t,a,r,i){if(et(a))return null!=t?e(t,a.ofType,r,i):void r(al(i),t,new y.eO(`Expected non-nullable type "${(0,v.N)(a)}" not to be null.`));if(null==t)return null;if(X(a)){let n=a.ofType;return tn(t)?Array.from(t,(t,a)=>e(t,n,r,ad(i,a,void 0))):[e(t,n,r,i)]}if(J(a)){if(!(0,E.Z)(t)||Array.isArray(t))return void r(al(i),t,new y.eO(`Expected type "${a.name}" to be an object.`));let n={},p=a.getFields();for(let o of Object.values(p)){let p=t[o.name];if(void 0===p){if(void 0!==o.defaultValue)n[o.name]=o.defaultValue;else if(et(o.type)){let e=(0,v.N)(o.type);r(al(i),t,new y.eO(`Field "${o.name}" of required type "${e}" was not provided.`))}continue}n[o.name]=e(p,o.type,r,ad(i,o.name,a.name))}for(let e of Object.keys(t))if(!p[e]){let n=A(e,Object.keys(a.getFields()));r(al(i),t,new y.eO(`Field "${e}" is not defined by type "${a.name}".`+_(n)))}if(a.isOneOf){let e=Object.keys(n);1!==e.length&&r(al(i),t,new y.eO(`Exactly one key must be specified for OneOf type "${a.name}".`));let p=e[0],o=n[p];null===o&&r(al(i).concat(p),o,new y.eO(`Field "${p}" must be non-null.`))}return n}if(eo(a)){let e;try{e=a.parseValue(t)}catch(e){e instanceof y.eO?r(al(i),t,e):r(al(i),t,new y.eO(`Expected type "${a.name}". `+e.message,{originalError:e}));return}return void 0===e&&r(al(i),t,new y.eO(`Expected type "${a.name}".`)),e}(0,ti.V)(!1,"Unexpected input type: "+(0,v.N)(a))}(e,t,a,void 0)}function ac(e,t,a){let r="Invalid value "+(0,v.N)(t);throw e.length>0&&(r+=` at "value${as(e)}"`),a.message=r+": "+a.message,a}function am(e,t,a){if(e){if(e.kind===R.b.VARIABLE){let r=e.name.value;if(null==a||void 0===a[r])return;let i=a[r];if(null===i&&et(t))return;return i}if(et(t)){if(e.kind===R.b.NULL)return;return am(e,t.ofType,a)}if(e.kind===R.b.NULL)return null;if(X(t)){let r=t.ofType;if(e.kind===R.b.LIST){let t=[];for(let i of e.values)if(af(i,a)){if(et(r))return;t.push(null)}else{let e=am(i,r,a);if(void 0===e)return;t.push(e)}return t}let i=am(e,r,a);if(void 0===i)return;return[i]}if(J(t)){if(e.kind!==R.b.OBJECT)return;let r=Object.create(null),i=T(e.fields,e=>e.name.value);for(let e of Object.values(t.getFields())){let t=i[e.name];if(!t||af(t.value,a)){if(void 0!==e.defaultValue)r[e.name]=e.defaultValue;else if(et(e.type))return;continue}let n=am(t.value,e.type,a);if(void 0===n)return;r[e.name]=n}if(t.isOneOf){let e=Object.keys(r);if(1!==e.length||null===r[e[0]])return}return r}if(eo(t)){let r;try{r=t.parseLiteral(e,a)}catch(e){return}if(void 0===r)return;return r}(0,ti.V)(!1,"Unexpected input type: "+(0,v.N)(t))}}function af(e,t){return e.kind===R.b.VARIABLE&&(null==t||void 0===t[e.name.value])}function ah(e,t,a,r){let i=[],n=null==r?void 0:r.maxErrors;try{let r=function(e,t,a,r){let i={};for(let n of t){let t=n.variable.name.value,p=tV(e,n.type);if(!er(p)){let e=(0,V.y)(n.type);r(new y.eO(`Variable "$${t}" expected value of type "${e}" which cannot be used as an input type.`,{nodes:n.type}));continue}if(!ag(a,t)){if(n.defaultValue)i[t]=am(n.defaultValue,p);else if(et(p)){let e=(0,v.N)(p);r(new y.eO(`Variable "$${t}" of required type "${e}" was not provided.`,{nodes:n}))}continue}let o=a[t];if(null===o&&et(p)){let e=(0,v.N)(p);r(new y.eO(`Variable "$${t}" of non-null type "${e}" must not be null.`,{nodes:n}));continue}i[t]=au(o,p,(e,a,i)=>{let p=`Variable "$${t}" got invalid value `+(0,v.N)(a);e.length>0&&(p+=` at "${t}${as(e)}"`),r(new y.eO(p+"; "+i.message,{nodes:n,originalError:i}))})}return i}(e,t,a,e=>{if(null!=n&&i.length>=n)throw new y.eO("Too many errors processing variables, error limit reached. Execution aborted.");i.push(e)});if(0===i.length)return{coerced:r}}catch(e){i.push(e)}return{errors:i}}function av(e,t,a){var r;let i={},n=T(null!=(r=t.arguments)?r:[],e=>e.name.value);for(let r of e.args){let e=r.name,p=r.type,o=n[e];if(!o){if(void 0!==r.defaultValue)i[e]=r.defaultValue;else if(et(p))throw new y.eO(`Argument "${e}" of required type "${(0,v.N)(p)}" was not provided.`,{nodes:t});continue}let s=o.value,d=s.kind===R.b.NULL;if(s.kind===R.b.VARIABLE){let t=s.name.value;if(null==a||!ag(a,t)){if(void 0!==r.defaultValue)i[e]=r.defaultValue;else if(et(p))throw new y.eO(`Argument "${e}" of required type "${(0,v.N)(p)}" was provided the variable "$${t}" which was not provided a runtime value.`,{nodes:s});continue}d=null==a[t]}if(d&&et(p))throw new y.eO(`Argument "${e}" of non-null type "${(0,v.N)(p)}" must not be null.`,{nodes:s});let l=am(s,p,a);if(void 0===l)throw new y.eO(`Argument "${e}" has invalid value ${(0,V.y)(s)}.`,{nodes:s});i[e]=l}return i}function ay(e,t,a){var r;let i=null==(r=t.directives)?void 0:r.find(t=>t.name.value===e.name);if(i)return av(e,i,a)}function ag(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function a_(e,t,a,r,i){let n=new Map;return ab(e,t,a,r,i,n,new Set),n}function ab(e,t,a,r,i,n,p){for(let s of i.selections)switch(s.kind){case R.b.FIELD:{var o;if(!aw(a,s))continue;let e=(o=s).alias?o.alias.value:o.name.value,t=n.get(e);void 0!==t?t.push(s):n.set(e,[s]);break}case R.b.INLINE_FRAGMENT:if(!aw(a,s)||!aE(e,s,r))continue;ab(e,t,a,r,s.selectionSet,n,p);break;case R.b.FRAGMENT_SPREAD:{let i=s.name.value;if(p.has(i)||!aw(a,s))continue;p.add(i);let o=t[i];if(!o||!aE(e,o,r))continue;ab(e,t,a,r,o.selectionSet,n,p)}}}function aw(e,t){let a=ay(e5,t,e);if((null==a?void 0:a.if)===!0)return!1;let r=ay(e9,t,e);return(null==r?void 0:r.if)!==!1}function aE(e,t,a){let r=t.typeCondition;if(!r)return!0;let i=tV(e,r);return i===a||!!eu(i)&&e.isSubType(i,a)}function aT(e){return{OperationDefinition(t){if("subscription"===t.operation){let a=e.getSchema(),r=a.getSubscriptionType();if(r){let i=t.name?t.name.value:null,n=Object.create(null),p=e.getDocument(),o=Object.create(null);for(let e of p.definitions)e.kind===R.b.FRAGMENT_DEFINITION&&(o[e.name.value]=e);let s=a_(a,o,n,r,t.selectionSet);if(s.size>1){let t=[...s.values()].slice(1).flat();e.reportError(new y.eO(null!=i?`Subscription "${i}" must select only one top level field.`:"Anonymous Subscription must select only one top level field.",{nodes:t}))}for(let t of s.values())t[0].name.value.startsWith("__")&&e.reportError(new y.eO(null!=i?`Subscription "${i}" must not select an introspection top level field.`:"Anonymous Subscription must not select an introspection top level field.",{nodes:t}))}}}}}function aN(e,t){let a=new Map;for(let r of e){let e=t(r),i=a.get(e);void 0===i?a.set(e,[r]):i.push(r)}return a}function aS(e){return{DirectiveDefinition(e){var t;let r=null!=(t=e.arguments)?t:[];return a(`@${e.name.value}`,r)},InterfaceTypeDefinition:t,InterfaceTypeExtension:t,ObjectTypeDefinition:t,ObjectTypeExtension:t};function t(e){var t,r;let i=e.name.value;for(let n of null!=(t=e.fields)?t:[]){let e=n.name.value;a(`${i}.${e}`,null!=(r=n.arguments)?r:[])}return!1}function a(t,a){for(let[r,i]of aN(a,e=>e.name.value))i.length>1&&e.reportError(new y.eO(`Argument "${t}(${r}:)" can only be defined once.`,{nodes:i.map(e=>e.name)}));return!1}}function aO(e){return{Field:t,Directive:t};function t(t){var a;for(let[r,i]of aN(null!=(a=t.arguments)?a:[],e=>e.name.value))i.length>1&&e.reportError(new y.eO(`There can be only one argument named "${r}".`,{nodes:i.map(e=>e.name)}))}}function aI(e){let t=Object.create(null),a=e.getSchema();return{DirectiveDefinition(r){let i=r.name.value;return null!=a&&a.getDirective(i)?void e.reportError(new y.eO(`Directive "@${i}" already exists in the schema. It cannot be redefined.`,{nodes:r.name})):(t[i]?e.reportError(new y.eO(`There can be only one directive named "@${i}".`,{nodes:[t[i],r.name]})):t[i]=r.name,!1)}}}function aD(e){let t=Object.create(null),a=e.getSchema();for(let e of a?a.getDirectives():ta)t[e.name]=!e.isRepeatable;for(let a of e.getDocument().definitions)a.kind===R.b.DIRECTIVE_DEFINITION&&(t[a.name.value]=!a.repeatable);let r=Object.create(null),i=Object.create(null);return{enter(a){let n;if("directives"in a&&a.directives){if(a.kind===R.b.SCHEMA_DEFINITION||a.kind===R.b.SCHEMA_EXTENSION)n=r;else if((0,tL.a6)(a)||(0,tL.i7)(a)){let e=a.name.value;void 0===(n=i[e])&&(i[e]=n=Object.create(null))}else n=Object.create(null);for(let r of a.directives){let a=r.name.value;t[a]&&(n[a]?e.reportError(new y.eO(`The directive "@${a}" can only be used once at this location.`,{nodes:[n[a],r]})):n[a]=r)}}}}}function aA(e){let t=e.getSchema(),a=t?t.getTypeMap():Object.create(null),r=Object.create(null);return{EnumTypeDefinition:i,EnumTypeExtension:i};function i(t){var i;let n=t.name.value;r[n]||(r[n]=Object.create(null));let p=null!=(i=t.values)?i:[],o=r[n];for(let t of p){let r=t.name.value,i=a[n];W(i)&&i.getValue(r)?e.reportError(new y.eO(`Enum value "${n}.${r}" already exists in the schema. It cannot also be defined in this type extension.`,{nodes:t.name})):o[r]?e.reportError(new y.eO(`Enum value "${n}.${r}" can only be defined once.`,{nodes:[o[r],t.name]})):o[r]=t.name}return!1}}function ak(e){let t=e.getSchema(),a=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(t){var i,n,p;let o=t.name.value;r[o]||(r[o]=Object.create(null));let s=null!=(i=t.fields)?i:[],d=r[o];for(let t of s){let r=t.name.value;(n=a[o],p=r,(q(n)||Y(n)||J(n))&&null!=n.getFields()[p])?e.reportError(new y.eO(`Field "${o}.${r}" already exists in the schema. It cannot also be defined in this type extension.`,{nodes:t.name})):d[r]?e.reportError(new y.eO(`Field "${o}.${r}" can only be defined once.`,{nodes:[d[r],t.name]})):d[r]=t.name}return!1}}function ax(e){let t=Object.create(null);return{OperationDefinition:()=>!1,FragmentDefinition(a){let r=a.name.value;return t[r]?e.reportError(new y.eO(`There can be only one fragment named "${r}".`,{nodes:[t[r],a.name]})):t[r]=a.name,!1}}}function aC(e){let t=[],a=Object.create(null);return{ObjectValue:{enter(){t.push(a),a=Object.create(null)},leave(){let e=t.pop();e||(0,ti.V)(!1),a=e}},ObjectField(t){let r=t.name.value;a[r]?e.reportError(new y.eO(`There can be only one input field named "${r}".`,{nodes:[a[r],t.name]})):a[r]=t.name}}}function aR(e){let t=Object.create(null);return{OperationDefinition(a){let r=a.name;return r&&(t[r.value]?e.reportError(new y.eO(`There can be only one operation named "${r.value}".`,{nodes:[t[r.value],r]})):t[r.value]=r),!1},FragmentDefinition:()=>!1}}function aV(e){let t=e.getSchema(),a=Object.create(null),r=t?{query:t.getQueryType(),mutation:t.getMutationType(),subscription:t.getSubscriptionType()}:{};return{SchemaDefinition:i,SchemaExtension:i};function i(t){var i;for(let n of null!=(i=t.operationTypes)?i:[]){let t=n.operation,i=a[t];r[t]?e.reportError(new y.eO(`Type for ${t} already defined in the schema. It cannot be redefined.`,{nodes:n})):i?e.reportError(new y.eO(`There can be only one ${t} type in schema.`,{nodes:[i,n]})):a[t]=n}return!1}}function aF(e){let t=Object.create(null),a=e.getSchema();return{ScalarTypeDefinition:r,ObjectTypeDefinition:r,InterfaceTypeDefinition:r,UnionTypeDefinition:r,EnumTypeDefinition:r,InputObjectTypeDefinition:r};function r(r){let i=r.name.value;return null!=a&&a.getType(i)?void e.reportError(new y.eO(`Type "${i}" already exists in the schema. It cannot also be defined in this type definition.`,{nodes:r.name})):(t[i]?e.reportError(new y.eO(`There can be only one type named "${i}".`,{nodes:[t[i],r.name]})):t[i]=r.name,!1)}}function a$(e){return{OperationDefinition(t){var a;for(let[r,i]of aN(null!=(a=t.variableDefinitions)?a:[],e=>e.variable.name.value))i.length>1&&e.reportError(new y.eO(`There can be only one variable named "$${r}".`,{nodes:i.map(e=>e.variable.name)}))}}}function aP(e){let t={};return{OperationDefinition:{enter(){t={}}},VariableDefinition(e){t[e.variable.name.value]=e},ListValue(t){if(!X(e_(e.getParentInputType())))return aL(e,t),!1},ObjectValue(t){let a=eE(e.getInputType());if(!J(a))return aL(e,t),!1;let r=T(t.fields,e=>e.name.value);for(let i of Object.values(a.getFields()))if(!r[i.name]&&eB(i)){let r=(0,v.N)(i.type);e.reportError(new y.eO(`Field "${a.name}.${i.name}" of required type "${r}" was not provided.`,{nodes:t}))}a.isOneOf&&function(e,t,a,r){var i;let n=Object.keys(r);if(1!==n.length)return e.reportError(new y.eO(`OneOf Input Object "${a.name}" must specify exactly one key.`,{nodes:[t]}));let p=null==(i=r[n[0]])?void 0:i.value;p&&p.kind!==R.b.NULL||e.reportError(new y.eO(`Field "${a.name}.${n[0]}" must be non-null.`,{nodes:[t]}))}(e,t,a,r)},ObjectField(t){let a=eE(e.getParentInputType());if(!e.getInputType()&&J(a)){let r=A(t.name.value,Object.keys(a.getFields()));e.reportError(new y.eO(`Field "${t.name.value}" is not defined by type "${a.name}".`+_(r),{nodes:t}))}},NullValue(t){let a=e.getInputType();et(a)&&e.reportError(new y.eO(`Expected value of type "${(0,v.N)(a)}", found ${(0,V.y)(t)}.`,{nodes:t}))},EnumValue:t=>aL(e,t),IntValue:t=>aL(e,t),FloatValue:t=>aL(e,t),StringValue:t=>aL(e,t),BooleanValue:t=>aL(e,t)}}function aL(e,t){let a=e.getInputType();if(!a)return;let r=eE(a);if(!eo(r)){let r=(0,v.N)(a);e.reportError(new y.eO(`Expected value of type "${r}", found ${(0,V.y)(t)}.`,{nodes:t}));return}try{let i=r.parseLiteral(t,void 0);if(void 0===i){let r=(0,v.N)(a);e.reportError(new y.eO(`Expected value of type "${r}", found ${(0,V.y)(t)}.`,{nodes:t}))}}catch(i){let r=(0,v.N)(a);i instanceof y.eO?e.reportError(i):e.reportError(new y.eO(`Expected value of type "${r}", found ${(0,V.y)(t)}; `+i.message,{nodes:t,originalError:i}))}}function aj(e){return{VariableDefinition(t){let a=tV(e.getSchema(),t.type);if(void 0!==a&&!er(a)){let a=t.variable.name.value,r=(0,V.y)(t.type);e.reportError(new y.eO(`Variable "$${a}" cannot be non-input type "${r}".`,{nodes:t.type}))}}}}function aM(e){let t=Object.create(null);return{OperationDefinition:{enter(){t=Object.create(null)},leave(a){for(let{node:s,type:d,defaultValue:l,parentType:u}of e.getRecursiveVariableUsages(a)){let a=s.name.value,c=t[a];if(c&&d){var r,i,n,p,o;let t=e.getSchema(),m=tV(t,c.type);if(m&&(r=t,i=m,n=c.defaultValue,p=d,o=l,et(p)&&!et(i)?!((null!=n&&n.kind!==R.b.NULL||void 0!==o)&&eQ(r,i,p.ofType)):!eQ(r,i,p))){let t=(0,v.N)(m),r=(0,v.N)(d);e.reportError(new y.eO(`Variable "$${a}" of type "${t}" used in position expecting type "${r}".`,{nodes:[c,s]}))}J(u)&&u.isOneOf&&ey(m)&&e.reportError(new y.eO(`Variable "$${a}" is of type "${m}" but must be non-nullable to be used for OneOf Input Object "${u}".`,{nodes:[c,s]}))}}}},VariableDefinition(e){t[e.variable.name.value]=e}}}let aU=Object.freeze([tK]),aB=Object.freeze([tj,aR,tH,aT,tG,tU,aj,ao,tM,ax,tY,tX,at,tJ,a$,tZ,t1,tQ,aD,tB,aO,aP,ai,aM,t2,aC,...aU]),aq=Object.freeze([tW,aV,aF,aA,ak,aS,aI,tG,tQ,aD,aa,tq,aO,aC,an]);class aQ{constructor(e,t){this._ast=e,this._fragments=void 0,this._fragmentSpreads=new Map,this._recursivelyReferencedFragments=new Map,this._onError=t}get[Symbol.toStringTag](){return"ASTValidationContext"}reportError(e){this._onError(e)}getDocument(){return this._ast}getFragment(e){let t;if(this._fragments)t=this._fragments;else{for(let e of(t=Object.create(null),this.getDocument().definitions))e.kind===R.b.FRAGMENT_DEFINITION&&(t[e.name.value]=e);this._fragments=t}return t[e]}getFragmentSpreads(e){let t=this._fragmentSpreads.get(e);if(!t){let a;t=[];let r=[e];for(;a=r.pop();)for(let e of a.selections)e.kind===R.b.FRAGMENT_SPREAD?t.push(e):e.selectionSet&&r.push(e.selectionSet);this._fragmentSpreads.set(e,t)}return t}getRecursivelyReferencedFragments(e){let t=this._recursivelyReferencedFragments.get(e);if(!t){let a;t=[];let r=Object.create(null),i=[e.selectionSet];for(;a=i.pop();)for(let e of this.getFragmentSpreads(a)){let a=e.name.value;if(!0!==r[a]){r[a]=!0;let e=this.getFragment(a);e&&(t.push(e),i.push(e.selectionSet))}}this._recursivelyReferencedFragments.set(e,t)}return t}}class aY extends aQ{constructor(e,t,a){super(e,a),this._schema=t}get[Symbol.toStringTag](){return"SDLValidationContext"}getSchema(){return this._schema}}class aG extends aQ{constructor(e,t,a,r){super(t,r),this._schema=e,this._typeInfo=a,this._variableUsages=new Map,this._recursiveVariableUsages=new Map}get[Symbol.toStringTag](){return"ValidationContext"}getSchema(){return this._schema}getVariableUsages(e){let t=this._variableUsages.get(e);if(!t){let a=[],r=new tF(this._schema);(0,tR.YR)(e,tP(r,{VariableDefinition:()=>!1,Variable(e){a.push({node:e,type:r.getInputType(),defaultValue:r.getDefaultValue(),parentType:r.getParentInputType()})}})),t=a,this._variableUsages.set(e,t)}return t}getRecursiveVariableUsages(e){let t=this._recursiveVariableUsages.get(e);if(!t){for(let a of(t=this.getVariableUsages(e),this.getRecursivelyReferencedFragments(e)))t=t.concat(this.getVariableUsages(a));this._recursiveVariableUsages.set(e,t)}return t}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()}}function az(e,t,a=aB,r,i=new tF(e)){var n;let p=null!=(n=null==r?void 0:r.maxErrors)?n:100;t||(0,m.U)(!1,"Must provide document."),tO(e);let o=Object.freeze({}),s=[],d=new aG(e,t,i,e=>{if(s.length>=p)throw s.push(new y.eO("Too many validation errors, error limit reached. Validation aborted.")),o;s.push(e)}),l=(0,tR.oP)(a.map(e=>e(d)));try{(0,tR.YR)(t,tP(i,l))}catch(e){if(e!==o)throw e}return s}function aH(e,t,a=aq){let r=[],i=new aY(e,t,e=>{r.push(e)}),n=a.map(e=>e(i));return(0,tR.YR)(e,(0,tR.oP)(n)),r}function aW(e){return Promise.all(Object.values(e)).then(t=>{let a=Object.create(null);for(let[r,i]of Object.keys(e).entries())a[i]=t[r];return a})}class aK extends Error{constructor(e){super("Unexpected error value: "+(0,v.N)(e)),this.name="NonErrorThrown",this.thrownValue=e}}function aJ(e,t,a){var r;let i=e instanceof Error?e:new aK(e);return Array.isArray(i.path)?i:new y.eO(i.message,{nodes:null!=(r=i.nodes)?r:t,source:i.source,positions:i.positions,path:a,originalError:i})}let aZ=(o=(e,t,a)=>(function(e,t,a,r,i){let n=new Map,p=new Set;for(let o of i)o.selectionSet&&ab(e,t,a,r,o.selectionSet,n,p);return n})(e.schema,e.fragments,e.variableValues,t,a),function(e,t,a){void 0===r&&(r=new WeakMap);let i=r.get(e);void 0===i&&(i=new WeakMap,r.set(e,i));let n=i.get(t);void 0===n&&(n=new WeakMap,i.set(t,n));let p=n.get(a);return void 0===p&&(p=o(e,t,a),n.set(a,p)),p});function aX(e){arguments.length<2||(0,m.U)(!1,"graphql@16 dropped long-deprecated support for positional arguments, please pass an object instead.");let{schema:t,document:a,variableValues:r,rootValue:i}=e;a2(t,a,r);let n=a6(e);if(!("schema"in n))return{errors:n};try{let{operation:e}=n,t=function(e,t,a){let r=e.schema.getRootType(t.operation);if(null==r)throw new y.eO(`Schema is not configured to execute ${t.operation} operation.`,{nodes:t});let i=a_(e.schema,e.fragments,e.variableValues,r,t.selectionSet),n;switch(t.operation){case g.cE.QUERY:return a4(e,r,a,n,i);case g.cE.MUTATION:var p,o,s,d,l;return p=e,o=r,s=a,d=n,l=i,function(e,t,a){let r=a;for(let a of e)r=f(r)?r.then(e=>t(e,a)):t(r,a);return r}(l.entries(),(e,[t,a])=>{let r=ad(d,t,o.name),i=a3(p,o,s,a,r);return void 0===i?e:f(i)?i.then(a=>(e[t]=a,e)):(e[t]=i,e)},Object.create(null));case g.cE.SUBSCRIPTION:return a4(e,r,a,n,i)}}(n,e,i);if(f(t))return t.then(e=>a0(e,n.errors),e=>(n.errors.push(e),a0(null,n.errors)));return a0(t,n.errors)}catch(e){return n.errors.push(e),a0(null,n.errors)}}function a1(e){let t=aX(e);if(f(t))throw Error("GraphQL execution failed to complete synchronously.");return t}function a0(e,t){return 0===t.length?{data:e}:{errors:t,data:e}}function a2(e,t,a){t||(0,m.U)(!1,"Must provide document."),tO(e),null==a||(0,E.Z)(a)||(0,m.U)(!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 a6(e){var t,a,r;let i,{schema:n,document:p,rootValue:o,contextValue:s,variableValues:d,operationName:l,fieldResolver:u,typeResolver:c,subscribeFieldResolver:m,options:f}=e,h=Object.create(null);for(let e of p.definitions)switch(e.kind){case R.b.OPERATION_DEFINITION:if(null==l){if(void 0!==i)return[new y.eO("Must provide operation name if query contains multiple operations.")];i=e}else(null==(t=e.name)?void 0:t.value)===l&&(i=e);break;case R.b.FRAGMENT_DEFINITION:h[e.name.value]=e}if(!i)return null!=l?[new y.eO(`Unknown operation named "${l}".`)]:[new y.eO("Must provide an operation.")];let v=ah(n,null!=(a=i.variableDefinitions)?a:[],null!=d?d:{},{maxErrors:null!=(r=null==f?void 0:f.maxCoercionErrors)?r:50});return v.errors?v.errors:{schema:n,fragments:h,rootValue:o,contextValue:s,operation:i,variableValues:v.coerced,fieldResolver:null!=u?u:rr,typeResolver:null!=c?c:ra,subscribeFieldResolver:null!=m?m:rr,errors:[]}}function a4(e,t,a,r,i){let n=Object.create(null),p=!1;try{for(let[o,s]of i.entries()){let i=ad(r,o,t.name),d=a3(e,t,a,s,i);void 0!==d&&(n[o]=d,f(d)&&(p=!0))}}catch(e){if(p)return aW(n).finally(()=>{throw e});throw e}return p?aW(n):n}function a3(e,t,a,r,i){var n;let p=ri(e.schema,t,r[0]);if(!p)return;let o=p.type,s=null!=(n=p.resolve)?n:e.fieldResolver,d=a9(e,p,r,t,i);try{let t,n=av(p,r[0],e.variableValues),l=e.contextValue,u=s(a,n,l,d);if(t=f(u)?u.then(t=>a8(e,o,r,d,i,t)):a8(e,o,r,d,i,u),f(t))return t.then(void 0,t=>{let a=aJ(t,r,al(i));return a5(a,o,e)});return t}catch(t){return a5(aJ(t,r,al(i)),o,e)}}function a9(e,t,a,r,i){return{fieldName:t.name,fieldNodes:a,returnType:t.type,parentType:r,path:i,schema:e.schema,fragments:e.fragments,rootValue:e.rootValue,operation:e.operation,variableValues:e.variableValues}}function a5(e,t,a){if(et(t))throw e;return a.errors.push(e),null}function a8(e,t,a,r,i,n){var p,o,s,d,l,u,c;let m;if(n instanceof Error)throw n;if(et(t)){let p=a8(e,t.ofType,a,r,i,n);if(null===p)throw Error(`Cannot return null for non-nullable field ${r.parentType.name}.${r.fieldName}.`);return p}return null==n?null:X(t)?function(e,t,a,r,i,n){if(!tn(n))throw new y.eO(`Expected Iterable, but did not find one for field "${r.parentType.name}.${r.fieldName}".`);let p=t.ofType,o=!1,s=Array.from(n,(t,n)=>{let s=ad(i,n,void 0);try{let i;if(i=f(t)?t.then(t=>a8(e,p,a,r,s,t)):a8(e,p,a,r,s,t),f(i))return o=!0,i.then(void 0,t=>{let r=aJ(t,a,al(s));return a5(r,p,e)});return i}catch(t){return a5(aJ(t,a,al(s)),p,e)}});return o?Promise.all(s):s}(e,t,a,r,i,n):eo(t)?function(e,t){let a=e.serialize(t);if(null==a)throw Error(`Expected \`${(0,v.N)(e)}.serialize(${(0,v.N)(t)})\` to return non-nullable value, returned: ${(0,v.N)(a)}`);return a}(t,n):eu(t)?(p=e,o=t,s=a,d=r,l=i,u=n,f(m=(null!=(c=o.resolveType)?c:p.typeResolver)(u,p.contextValue,d,o))?m.then(e=>re(p,a7(e,p,o,s,d,u),s,d,l,u)):re(p,a7(m,p,o,s,d,u),s,d,l,u)):q(t)?re(e,t,a,r,i,n):void(0,ti.V)(!1,"Cannot complete value of unexpected output type: "+(0,v.N)(t))}function a7(e,t,a,r,i,n){if(null==e)throw new y.eO(`Abstract type "${a.name}" must resolve to an Object type at runtime for field "${i.parentType.name}.${i.fieldName}". Either the "${a.name}" type should provide a "resolveType" function or each possible type should provide an "isTypeOf" function.`,r);if(q(e))throw new y.eO("Support for returning GraphQLObjectType from resolveType was removed in graphql-js@16.0.0 please return type name instead.");if("string"!=typeof e)throw new y.eO(`Abstract type "${a.name}" must resolve to an Object type at runtime for field "${i.parentType.name}.${i.fieldName}" with value ${(0,v.N)(n)}, received "${(0,v.N)(e)}".`);let p=t.schema.getType(e);if(null==p)throw new y.eO(`Abstract type "${a.name}" was resolved to a type "${e}" that does not exist inside the schema.`,{nodes:r});if(!q(p))throw new y.eO(`Abstract type "${a.name}" was resolved to a non-object type "${e}".`,{nodes:r});if(!t.schema.isSubType(a,p))throw new y.eO(`Runtime Object type "${p.name}" is not a possible type for "${a.name}".`,{nodes:r});return p}function re(e,t,a,r,i,n){let p=aZ(e,t,a);if(t.isTypeOf){let o=t.isTypeOf(n,e.contextValue,r);if(f(o))return o.then(r=>{if(!r)throw rt(t,n,a);return a4(e,t,n,i,p)});if(!o)throw rt(t,n,a)}return a4(e,t,n,i,p)}function rt(e,t,a){return new y.eO(`Expected value of type "${e.name}" but got: ${(0,v.N)(t)}.`,{nodes:a})}let ra=function(e,t,a,r){if((0,E.Z)(e)&&"string"==typeof e.__typename)return e.__typename;let i=a.schema.getPossibleTypes(r),n=[];for(let r=0;r<i.length;r++){let p=i[r];if(p.isTypeOf){let i=p.isTypeOf(e,t,a);if(f(i))n[r]=i;else if(i)return n.length&&Promise.allSettled(n).catch(()=>{}),p.name}}if(n.length)return Promise.all(n).then(e=>{for(let t=0;t<e.length;t++)if(e[t])return i[t].name})},rr=function(e,t,a,r){if((0,E.Z)(e)||"function"==typeof e){let i=e[r.fieldName];return"function"==typeof i?e[r.fieldName](t,a,r):i}};function ri(e,t,a){let r=a.name.value;return r===tv.name&&e.getQueryType()===t?tv:r===ty.name&&e.getQueryType()===t?ty:r===tg.name?tg:t.getFields()[r]}function rn(e){return new Promise(t=>t(ro(e)))}function rp(e){let t=ro(e);if(f(t))throw Error("GraphQL execution failed to complete synchronously.");return t}function ro(e){let t;arguments.length<2||(0,m.U)(!1,"graphql@16 dropped long-deprecated support for positional arguments, please pass an object instead.");let{schema:a,source:r,rootValue:i,contextValue:n,variableValues:p,operationName:o,fieldResolver:s,typeResolver:d}=e,l=tS(a);if(l.length>0)return{errors:l};try{t=(0,h.qg)(r)}catch(e){return{errors:[e]}}let u=az(a,t);return u.length>0?{errors:u}:aX({schema:a,document:t,rootValue:i,contextValue:n,variableValues:p,operationName:o,fieldResolver:s,typeResolver:d})}var rs=a(39537),rd=a(73971),rl=a(8238),ru=a(98472),rc=a(12039);function rm(e){return"function"==typeof(null==e?void 0:e[Symbol.asyncIterator])}async function rf(e){arguments.length<2||(0,m.U)(!1,"graphql@16 dropped long-deprecated support for positional arguments, please pass an object instead.");let t=await rh(e);if(!rm(t))return t;let a=t[Symbol.asyncIterator]();async function r(t){if(t.done)return t;try{let a;return{value:await (a=t.value,aX({...e,rootValue:a})),done:!1}}catch(e){if("function"==typeof a.return)try{await a.return()}catch(e){}throw e}}return{next:async()=>r(await a.next()),return:async()=>"function"==typeof a.return?r(await a.return()):{value:void 0,done:!0},async throw(e){if("function"==typeof a.throw)return r(await a.throw(e));throw e},[Symbol.asyncIterator](){return this}}}async function rh(...e){let t,a=(t=e[0])&&"document"in t?t:{schema:t,document:e[1],rootValue:e[2],contextValue:e[3],variableValues:e[4],operationName:e[5],subscribeFieldResolver:e[6]},{schema:r,document:i,variableValues:n}=a;a2(r,i,n);let p=a6(a);if(!("schema"in p))return{errors:p};try{let e=await rv(p);if(!rm(e))throw Error(`Subscription field must return Async Iterable. Received: ${(0,v.N)(e)}.`);return e}catch(e){if(e instanceof y.eO)return{errors:[e]};throw e}}async function rv(e){let{schema:t,fragments:a,operation:r,variableValues:i,rootValue:n}=e,p=t.getSubscriptionType();if(null==p)throw new y.eO("Schema is not configured to execute subscription operation.",{nodes:r});let[o,s]=[...a_(t,a,i,p,r.selectionSet).entries()][0],d=ri(t,p,s[0]);if(!d){let e=s[0].name.value;throw new y.eO(`The subscription field "${e}" is not defined.`,{nodes:s})}let l=ad(void 0,o,p.name),u=a9(e,d,s,p,l);try{var c;let t=av(d,s[0],i),a=e.contextValue,r=null!=(c=d.subscribe)?c:e.subscribeFieldResolver,p=await r(n,t,a,u);if(p instanceof Error)throw p;return p}catch(e){throw aJ(e,s,al(l))}}function ry(e){return{Field(t){let a=e.getFieldDef(),r=null==a?void 0:a.deprecationReason;if(a&&null!=r){let i=e.getParentType();null!=i||(0,ti.V)(!1),e.reportError(new y.eO(`The field ${i.name}.${a.name} is deprecated. ${r}`,{nodes:t}))}},Argument(t){let a=e.getArgument(),r=null==a?void 0:a.deprecationReason;if(a&&null!=r){let i=e.getDirective();if(null!=i)e.reportError(new y.eO(`Directive "@${i.name}" argument "${a.name}" is deprecated. ${r}`,{nodes:t}));else{let i=e.getParentType(),n=e.getFieldDef();null!=i&&null!=n||(0,ti.V)(!1),e.reportError(new y.eO(`Field "${i.name}.${n.name}" argument "${a.name}" is deprecated. ${r}`,{nodes:t}))}}},ObjectField(t){let a=eE(e.getParentInputType());if(J(a)){let r=a.getFields()[t.name.value],i=null==r?void 0:r.deprecationReason;null!=i&&e.reportError(new y.eO(`The input field ${a.name}.${r.name} is deprecated. ${i}`,{nodes:t}))}},EnumValue(t){let a=e.getEnumValue(),r=null==a?void 0:a.deprecationReason;if(a&&null!=r){let i=eE(e.getInputType());null!=i||(0,ti.V)(!1),e.reportError(new y.eO(`The enum value "${i.name}.${a.name}" is deprecated. ${r}`,{nodes:t}))}}}}function rg(e){return{Field(t){let a=eE(e.getType());a&&tb(a)&&e.reportError(new y.eO(`GraphQL introspection has been disabled, but the requested query contained the field "${t.name.value}".`,{nodes:t}))}}}var r_=a(59841);function rb(e){let t={descriptions:!0,specifiedByUrl:!1,directiveIsRepeatable:!1,schemaDescription:!1,inputValueDeprecation:!1,oneOf:!1,...e},a=t.descriptions?"description":"",r=t.specifiedByUrl?"specifiedByURL":"",i=t.directiveIsRepeatable?"isRepeatable":"",n=t.schemaDescription?a:"";function p(e){return t.inputValueDeprecation?e:""}let o=t.oneOf?"isOneOf":"";return`
|
|
1477
|
+
</html>`,iJ=iK({title:"Signed in to BRICKS",heading:"Signed in to BRICKS",message:"You can close this tab now."}),iZ=e=>iK({title:"Sign-in failed",heading:"Sign-in failed",message:e}),iX="Sign-in cancelled",i1=(J=en(function*({onAuthorizeUrl:e,signal:t}={}){if(t?.aborted)throw Error(iX);var a,r,i,n,p,o,s,d=(a=a9.randomBytes(32).toString("base64url"),r=a9.createHash("sha256").update(a).digest("base64url"),{verifier:a,challenge:r}),l=d.verifier,u=d.challenge,c=a9.randomBytes(16).toString("base64url"),m=process.env.BRICKS_OAUTH_CALLBACK_PORT,f=null!=m&&""!==m?Number(m):8535,h=new Promise((e,t)=>{i=e,n=t}),v=tj.createServer((e,t)=>{var a=new URL(e.url,`http://${iq}`);if(a.pathname!==iB)return void t.writeHead(404).end();var r=a.searchParams.get("error"),p=a.searchParams.get("code");if(a.searchParams.get("state")!==c)return void t.writeHead(400,{"Content-Type":"text/html"}).end(iZ("Invalid state"));if(r){var o=a.searchParams.get("error_description")||r;t.writeHead(200,{"Content-Type":"text/html"}).end(iZ(o)),n(Error(o));return}if(!p){t.writeHead(400,{"Content-Type":"text/html"}).end(iZ("Invalid state")),n(Error("OAuth callback did not include an authorization code"));return}t.writeHead(200,{"Content-Type":"text/html"}).end(iJ),i(p)}),y=yield new Promise((e,t)=>{v.once("error",e=>{e?.code==="EADDRINUSE"?t(Error(`Callback port ${f} is already in use — is another sign-in in progress? Close it and retry.`)):t(e)}),v.listen(f,iq,()=>e(v.address().port))}),g=`http://${iq}:${y}${iB}`,_=(({redirectUri:e,state:t,challenge:a})=>{var r=new URL(`https://${iL}/authorize`);return r.searchParams.set("response_type","code"),r.searchParams.set("client_id",iU),r.searchParams.set("redirect_uri",e),r.searchParams.set("scope",iM),r.searchParams.set("audience",ij),r.searchParams.set("state",t),r.searchParams.set("code_challenge",a),r.searchParams.set("code_challenge_method","S256"),r.toString()})({redirectUri:g,state:c,challenge:u}),b=new Promise((e,t)=>{s=t}),w=()=>s(Error(iX));t?.addEventListener("abort",w,{once:!0});try{if(t?.aborted)throw Error(iX);var E=new Promise((e,t)=>{p=setTimeout(()=>t(Error("Timed out waiting for the browser sign-in (5 minutes)")),3e5)}),T=e?Promise.resolve().then(()=>e(_)):Promise.resolve(),N=yield Promise.race([Promise.all([T,h]),E,b]),S=aB(N,2)[1];o=yield iz("/oauth/token",{grant_type:"authorization_code",client_id:iU,code:S,code_verifier:l,redirect_uri:g},{signal:t})}catch(e){if(t?.aborted)throw Error(iX);throw e}finally{p&&clearTimeout(p),t?.removeEventListener("abort",w),yield new Promise(e=>{v.close(e),v.closeIdleConnections?.()})}if(t?.aborted)throw Error(iX);return o}),function(){return J.apply(this,arguments)}),i0=(Z=en(function*(){return yield iz("/oauth/device/code",{client_id:iU,scope:iM,audience:ij})}),function(){return Z.apply(this,arguments)}),i2=e=>new Promise(t=>setTimeout(t,e)),i6=(X=en(function*({device_code:e,interval:t=5,expires_in:a=900}){for(var r=Date.now()+1e3*a,i=1e3*t;Date.now()<r;){yield i2(i);try{return yield iz("/oauth/token",{grant_type:"urn:ietf:params:oauth:grant-type:device_code",client_id:iU,device_code:e})}catch(e){if("authorization_pending"===e.code)continue;if("slow_down"===e.code){i+=5e3;continue}throw e}}throw Error("Device authorization expired before the sign-in was confirmed")}),function(e){return X.apply(this,arguments)}),i4=(e,t=null,{preservePrevious:a=!1}={})=>{if(!e?.access_token)throw Error("OAuth token response did not include an access token");if(!a&&!e.id_token)throw Error("OAuth login response did not include an ID token");var r=e.id_token?iH(e.id_token):{};if(!a&&!r.sub)throw Error("OAuth ID token did not include a user subject");if(a&&r.sub&&t?.user?.sub&&r.sub!==t.user.sub)throw Error("OAuth refresh returned a different user identity");var i=a?t?.user:null;return{accessToken:e.access_token,refreshToken:e.refresh_token||(a?t?.refreshToken:null)||null,expiresAt:new Date(Date.now()+1e3*(e.expires_in||0)).toISOString(),user:{sub:r.sub||i?.sub||null,email:r.email||i?.email||null,name:r.name||i?.name||null,nickname:r.nickname||i?.nickname||null,picture:r.picture||i?.picture||null},audience:ij}},i3=null,i9=(ee=en(function*({forceRefresh:e=!1}={}){var t=rU();if(!t?.accessToken)return null;var a=new Date(t.expiresAt||0).getTime()-Date.now();if(!e&&a>3e5)return t;if(!t.refreshToken){if(a>0)return t;if(!(yield rH(t)))return rU();throw Error("OAuth session expired. Run `bricks auth login` again.")}var r=`${t.accessToken}\0${t.refreshToken}`;if(i3){var i=i3;return i.sessionKey===r?i.promise:(yield i.promise.catch(()=>{}),i9({forceRefresh:e}))}var n=rf(en(function*(){var a=rU();if(!a?.accessToken)return null;if(!t||!a||t.accessToken!==a.accessToken||t.refreshToken!==a.refreshToken)return a;var r=new Date(a.expiresAt||0).getTime()-Date.now();if(!e&&r>3e5)return a;if(!a.refreshToken){if(r>0)return a;if(!(yield rH(a)))return rU();throw Error("OAuth session expired. Run `bricks auth login` again.")}try{var i=yield iz("/oauth/token",{grant_type:"refresh_token",client_id:iU,refresh_token:a.refreshToken}),n=i4(i,a,{preservePrevious:!0});if(!(yield rz(a,n)))return rU();return n}catch(e){if("invalid_grant"===e.code){if(!(yield rH(a)))return rU();throw Error("OAuth session expired. Run `bricks auth login` again.")}throw e}}));i3={sessionKey:r,promise:n};try{return yield n}finally{i3?.promise===n&&(i3=null)}}),function(){return ee.apply(this,arguments)}),i5=(et=en(function*(e){if(e){var t=new AbortController,a=setTimeout(()=>t.abort(),5e3);try{yield iY("/oauth/revoke",{client_id:iU,token:e},{signal:t.signal})}catch{}finally{clearTimeout(a),t.abort()}}}),function(e){return et.apply(this,arguments)}),i8=(ea=en(function*(){var e=yield rY();return!!e?.accessToken&&(yield i5(e.refreshToken),!0)}),function(){return ea.apply(this,arguments)}),i7=e=>new Promise(t=>{var a=aB("darwin"===process.platform?["open",[e]]:"win32"===process.platform?["cmd",["/c","start","",e.replace(/&/g,"^&")]]:["xdg-open",[e]],2),r=a[0],i=a[1];try{var n=(0,iN.spawn)(r,i,{stdio:"ignore",detached:!0});n.once("error",()=>t(!1)),n.once("spawn",()=>{n.unref(),t(!0)})}catch{t(!1)}}),ne=(e,t)=>{if(!e)throw Error("Not logged in. Run `bricks auth login` first.");if(e.user?.sub!==t)throw Error("OAuth account changed. Re-select the workspace for the current account.");return e},nt=e=>{var t=((e="default")=>rN(e,rw.snapshot(["tokens","oauth","devtoolsTokens","baseUrl","activityLogBaseUrl"])))(e);return{...t,auth:(({tokenInfo:e,oauth:t})=>{if(!e)return null;if("oauth"===e.type){if(!t?.accessToken||!e.oauthSubject||e.oauthSubject!==t.user?.sub||!e.workspaceId)return null;var a,r,i,n,p=e.oauthSubject,o=(r=en(function*(){return ne((yield i9()),p).accessToken}),function(){return r.apply(this,arguments)});return{kind:"oauth",workspaceId:e.workspaceId,workspaceName:e.workspaceName,getAccessToken:o,getHeaders:(i=en(function*(){return{authorization:`Bearer ${yield o()}`,"x-bricks-workspace-id":String(e.workspaceId)}}),function(){return i.apply(this,arguments)}),refresh:(n=en(function*(){ne((yield i9({forceRefresh:!0})),p)}),function(){return n.apply(this,arguments)})}}return e.token?{kind:"token",token:e.token,workspaceId:e.workspaceId,workspaceName:e.workspaceName,getHeaders:(a=en(function*(){return{authorization:`Bearer ${e.token}`}}),function(){return a.apply(this,arguments)})}:null})(t)}},na=e=>nt(e).auth},48255(e,t,a){a.d(t,{Wk:()=>d,eO:()=>p,yJ:()=>s});var r=a(91070),i=a(73971),n=a(8238);class p extends Error{constructor(e,...t){var a,n,s;let d,{nodes:l,source:u,positions:c,path:m,originalError:f,extensions:h}=null==(d=t[0])||"kind"in d||"length"in d?{nodes:d,source:t[1],positions:t[2],path:t[3],originalError:t[4],extensions:t[5]}:d;super(e),this.name="GraphQLError",this.path=null!=m?m:void 0,this.originalError=null!=f?f:void 0,this.nodes=o(Array.isArray(l)?l:l?[l]:void 0);let v=o(null==(a=this.nodes)?void 0:a.map(e=>e.loc).filter(e=>null!=e));this.source=null!=u?u:null==v||null==(n=v[0])?void 0:n.source,this.positions=null!=c?c:null==v?void 0:v.map(e=>e.start),this.locations=c&&u?c.map(e=>(0,i.g)(u,e)):null==v?void 0:v.map(e=>(0,i.g)(e.source,e.start));let y=(0,r.Z)(null==f?void 0:f.extensions)?null==f?void 0:f.extensions:void 0;this.extensions=null!=(s=null!=h?h:y)?s: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}}),null!=f&&f.stack?Object.defineProperty(this,"stack",{value:f.stack,writable:!0,configurable:!0}):Error.captureStackTrace?Error.captureStackTrace(this,p):Object.defineProperty(this,"stack",{value:Error().stack,writable:!0,configurable:!0})}get[Symbol.toStringTag](){return"GraphQLError"}toString(){let e=this.message;if(this.nodes)for(let t of this.nodes)t.loc&&(e+="\n\n"+(0,n.V)(t.loc));else if(this.source&&this.locations)for(let t of this.locations)e+="\n\n"+(0,n.C)(this.source,t);return e}toJSON(){let e={message:this.message};return null!=this.locations&&(e.locations=this.locations),null!=this.path&&(e.path=this.path),null!=this.extensions&&Object.keys(this.extensions).length>0&&(e.extensions=this.extensions),e}}function o(e){return void 0===e||0===e.length?void 0:e}function s(e){return e.toString()}function d(e){return e.toJSON()}},59841(e,t,a){a.d(t,{I:()=>i});var r=a(48255);function i(e,t,a){return new r.eO(`Syntax Error: ${a}`,{source:e,positions:[t]})}},36869(e,t,a){let r;a.r(t),a.d(t,{VariablesAreInputTypesRule:()=>aj,SingleFieldSubscriptionsRule:()=>aT,UniqueVariableNamesRule:()=>a$,GraphQLDeprecatedDirective:()=>e7,GraphQLNonNull:()=>ef,__InputValue:()=>tm,createSourceEventStream:()=>rh,execute:()=>aX,isDefinitionNode:()=>tL.MD,isInterfaceType:()=>Y,isRequiredArgument:()=>eR,isValidNameError:()=>r1,parseValue:()=>h.$x,valueFromAST:()=>am,NoUnusedVariablesRule:()=>t1,__DirectiveLocation:()=>tl,findDangerousChanges:()=>r2,__TypeKind:()=>th,isSchema:()=>tw,UniqueTypeNamesRule:()=>aF,NoSchemaIntrospectionCustomRule:()=>rg,defaultTypeResolver:()=>ra,isType:()=>j,syntaxError:()=>r_.I,version:()=>i,UniqueFragmentNamesRule:()=>ax,assertWrappingType:()=>ev,getNullableType:()=>e_,isObjectType:()=>q,visitWithTypeInfo:()=>tP,assertEnumValueName:()=>L,printSchema:()=>rP,validate:()=>az,BREAK:()=>tR.sP,assertNonNullType:()=>ea,assertNullableType:()=>eg,executeSync:()=>a1,isLeafType:()=>eo,resolveSchemaCoordinate:()=>r8,assertOutputType:()=>ep,buildASTSchema:()=>rk,astFromValue:()=>tp,Kind:()=>R.b,ProvidedRequiredArgumentsRule:()=>ai,UniqueDirectiveNamesRule:()=>aI,KnownDirectivesRule:()=>tQ,DEFAULT_DEPRECATION_REASON:()=>e8,TypeKind:()=>l,assertInterfaceType:()=>G,isValueNode:()=>tL.aR,GraphQLSpecifiedByDirective:()=>te,GraphQLFloat:()=>eK,UniqueFieldDefinitionNamesRule:()=>ak,LoneAnonymousOperationRule:()=>tH,VariablesInAllowedPositionRule:()=>aM,assertInputType:()=>ei,formatError:()=>y.Wk,assertInputObjectType:()=>Z,isOutputType:()=>en,isWrappingType:()=>eh,assertLeafType:()=>es,assertValidSchema:()=>tO,FragmentsOnCompositeTypesRule:()=>tU,graphql:()=>rn,UniqueOperationTypesRule:()=>aV,parseSchemaCoordinate:()=>h.Ng,UniqueEnumValueNamesRule:()=>aA,isNonNullType:()=>et,isSelectionNode:()=>tL.VK,printError:()=>y.yJ,specifiedDirectives:()=>ta,visit:()=>tR.YR,GraphQLScalarType:()=>eS,assertEnumType:()=>K,UniqueDirectivesPerLocationRule:()=>aD,assertName:()=>P,getDirectiveValues:()=>ay,isConstValueNode:()=>tL.TZ,isEqualType:()=>eq,isNamedType:()=>eb,isTypeDefinitionNode:()=>tL.a6,validateSchema:()=>tS,parse:()=>h.qg,__Schema:()=>ts,isTypeSystemDefinitionNode:()=>tL.xu,valueFromASTUntyped:()=>F,LoneSchemaDefinitionRule:()=>tW,isTypeSubTypeOf:()=>eQ,UniqueArgumentNamesRule:()=>aO,UniqueInputFieldNamesRule:()=>aC,locatedError:()=>aJ,typeFromAST:()=>tV,printLocation:()=>rl.V,assertUnionType:()=>H,separateOperations:()=>rK,getVariableValues:()=>ah,Location:()=>g.aZ,GraphQLObjectType:()=>eO,UniqueArgumentDefinitionNamesRule:()=>aS,stripIgnoredCharacters:()=>rZ,GRAPHQL_MAX_INT:()=>ez,visitInParallel:()=>tR.oP,parseType:()=>h.Mb,isTypeNode:()=>tL.dI,PossibleTypeExtensionsRule:()=>aa,graphqlSync:()=>rp,isSchemaCoordinateNode:()=>tL.gj,DirectiveLocation:()=>eG.H,TypeNameMetaFieldDef:()=>tg,coerceInputValue:()=>au,GraphQLInt:()=>eW,resolveObjMapThunk:()=>eN,GraphQLInterfaceType:()=>eV,UniqueOperationNamesRule:()=>aR,GraphQLSkipDirective:()=>e5,isEnumType:()=>W,assertValidName:()=>rX,buildClientSchema:()=>rN,KnownArgumentNamesRule:()=>tB,ValuesOfCorrectTypeRule:()=>aP,isInputObjectType:()=>J,GraphQLID:()=>eX,NoUnusedFragmentsRule:()=>tX,isUnionType:()=>z,isSpecifiedScalarType:()=>e0,getArgumentValues:()=>av,printSourceLocation:()=>rl.C,__EnumValue:()=>tf,getOperationAST:()=>rw,isExecutableDefinitionNode:()=>tL._m,isAbstractType:()=>eu,assertAbstractType:()=>ec,isTypeExtensionNode:()=>tL.i7,GraphQLInputObjectType:()=>eM,getNamedType:()=>eE,parseConstValue:()=>h.u8,KnownFragmentNamesRule:()=>tY,isListType:()=>X,Lexer:()=>ru.JG,isSpecifiedDirective:()=>tr,responsePathAsArray:()=>al,isDirective:()=>e6,TypeInfo:()=>tF,assertScalarType:()=>B,extendSchema:()=>rS,isIntrospectionType:()=>tb,print:()=>V.y,getIntrospectionQuery:()=>rb,GraphQLBoolean:()=>eZ,KnownTypeNamesRule:()=>tG,assertListType:()=>ee,concatAST:()=>rW,NoDeprecatedCustomRule:()=>ry,defaultFieldResolver:()=>rr,GraphQLDirective:()=>e3,getLocation:()=>rd.g,TypeMetaFieldDef:()=>ty,GRAPHQL_MIN_INT:()=>eH,GraphQLIncludeDirective:()=>e9,ScalarLeafsRule:()=>ao,assertSchema:()=>tE,lexicographicSortSchema:()=>rC,GraphQLList:()=>em,isTypeSystemExtensionNode:()=>tL.fT,specifiedScalarTypes:()=>e1,BreakingChangeType:()=>u,ExecutableDefinitionsRule:()=>tj,assertDirective:()=>e4,__Field:()=>tc,getVisitFn:()=>tR.UY,recommendedRules:()=>aU,SchemaMetaFieldDef:()=>tv,assertCompositeType:()=>el,isRequiredInputField:()=>eB,Token:()=>g.ou,specifiedRules:()=>aB,DangerousChangeType:()=>c,GraphQLUnionType:()=>eF,isCompositeType:()=>ed,versionInfo:()=>n,FieldsOnCorrectTypeRule:()=>tM,GraphQLString:()=>eJ,assertType:()=>M,introspectionFromSchema:()=>rT,doTypesOverlap:()=>eY,GraphQLEnumType:()=>eP,resolveReadonlyArrayThunk:()=>eT,GraphQLOneOfDirective:()=>tt,NoFragmentCyclesRule:()=>tJ,findBreakingChanges:()=>r0,ValidationContext:()=>aG,OverlappingFieldsCanBeMergedRule:()=>t2,isScalarType:()=>U,MaxIntrospectionDepthRule:()=>tK,NoUndefinedVariablesRule:()=>tZ,assertObjectType:()=>Q,getOperationRootType:()=>rE,printType:()=>rU,OperationTypeNode:()=>g.cE,isInputType:()=>er,__Directive:()=>td,GraphQLSchema:()=>tT,Source:()=>rs.k,resolveASTSchemaCoordinate:()=>r7,GraphQLError:()=>y.eO,assertNamedType:()=>ew,buildSchema:()=>rx,introspectionTypes:()=>t_,PossibleFragmentSpreadsRule:()=>at,__Type:()=>tu,getEnterLeaveForKind:()=>tR.XO,TokenKind:()=>rc.Y,printIntrospectionSchema:()=>rL,isNullableType:()=>ey,subscribe:()=>rf});let i="16.12.0",n=Object.freeze({major:16,minor:12,patch:0,preReleaseTag:null});var p,o,s,d,l,u,c,m=a(93217);function f(e){return"function"==typeof(null==e?void 0:e.then)}var h=a(20186),v=a(35198),y=a(48255),g=a(59762);function _(e,t){let[a,r]=t?[e,t]:[void 0,e],i=" Did you mean ";a&&(i+=a+" ");let n=r.map(e=>`"${e}"`);switch(n.length){case 0:return"";case 1:return i+n[0]+"?";case 2:return i+n[0]+" or "+n[1]+"?"}let p=n.slice(0,5),o=p.pop();return i+p.join(", ")+", or "+o+"?"}function b(e){return e}var w=a(50792),E=a(91070);function T(e,t){let a=Object.create(null);for(let r of e)a[t(r)]=r;return a}function N(e,t,a){let r=Object.create(null);for(let i of e)r[t(i)]=a(i);return r}function S(e,t){let a=Object.create(null);for(let r of Object.keys(e))a[r]=t(e[r],r);return a}function O(e,t){let a=0,r=0;for(;a<e.length&&r<t.length;){let i=e.charCodeAt(a),n=t.charCodeAt(r);if(D(i)&&D(n)){let p=0;do++a,p=10*p+i-I,i=e.charCodeAt(a);while(D(i)&&p>0);let o=0;do++r,o=10*o+n-I,n=t.charCodeAt(r);while(D(n)&&o>0);if(p<o)return -1;if(p>o)return 1}else{if(i<n)return -1;if(i>n)return 1;++a,++r}}return e.length-t.length}let I=48;function D(e){return!isNaN(e)&&I<=e&&e<=57}function A(e,t){let a=Object.create(null),r=new k(e),i=Math.floor(.4*e.length)+1;for(let e of t){let t=r.measure(e,i);void 0!==t&&(a[e]=t)}return Object.keys(a).sort((e,t)=>{let r=a[e]-a[t];return 0!==r?r:O(e,t)})}class k{constructor(e){this._input=e,this._inputLowerCase=e.toLowerCase(),this._inputArray=x(this._inputLowerCase),this._rows=[Array(e.length+1).fill(0),Array(e.length+1).fill(0),Array(e.length+1).fill(0)]}measure(e,t){if(this._input===e)return 0;let a=e.toLowerCase();if(this._inputLowerCase===a)return 1;let r=x(a),i=this._inputArray;if(r.length<i.length){let e=r;r=i,i=e}let n=r.length,p=i.length;if(n-p>t)return;let o=this._rows;for(let e=0;e<=p;e++)o[0][e]=e;for(let e=1;e<=n;e++){let a=o[(e-1)%3],n=o[e%3],s=n[0]=e;for(let t=1;t<=p;t++){let p=+(r[e-1]!==i[t-1]),d=Math.min(a[t]+1,n[t-1]+1,a[t-1]+p);e>1&&t>1&&r[e-1]===i[t-2]&&r[e-2]===i[t-1]&&(d=Math.min(d,o[(e-2)%3][t-2]+1)),d<s&&(s=d),n[t]=d}if(s>t)return}let s=o[n%3][p];return s<=t?s:void 0}}function x(e){let t=e.length,a=Array(t);for(let r=0;r<t;++r)a[r]=e.charCodeAt(r);return a}function C(e){if(null==e)return Object.create(null);if(null===Object.getPrototypeOf(e))return e;let t=Object.create(null);for(let[a,r]of Object.entries(e))t[a]=r;return t}var R=a(42455),V=a(95818);function F(e,t){switch(e.kind){case R.b.NULL:return null;case R.b.INT:return parseInt(e.value,10);case R.b.FLOAT:return parseFloat(e.value);case R.b.STRING:case R.b.ENUM:case R.b.BOOLEAN:return e.value;case R.b.LIST:return e.values.map(e=>F(e,t));case R.b.OBJECT:return N(e.fields,e=>e.name.value,e=>F(e.value,t));case R.b.VARIABLE:return null==t?void 0:t[e.name.value]}}var $=a(25881);function P(e){if(null!=e||(0,m.U)(!1,"Must provide name."),"string"==typeof e||(0,m.U)(!1,"Expected name to be a string."),0===e.length)throw new y.eO("Expected name to be a non-empty string.");for(let t=1;t<e.length;++t)if(!(0,$.xr)(e.charCodeAt(t)))throw new y.eO(`Names must only contain [_a-zA-Z0-9] but "${e}" does not.`);if(!(0,$.un)(e.charCodeAt(0)))throw new y.eO(`Names must start with [_a-zA-Z] but "${e}" does not.`);return e}function L(e){if("true"===e||"false"===e||"null"===e)throw new y.eO(`Enum values cannot be named: ${e}`);return P(e)}function j(e){return U(e)||q(e)||Y(e)||z(e)||W(e)||J(e)||X(e)||et(e)}function M(e){if(!j(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL type.`);return e}function U(e){return(0,w.h)(e,eS)}function B(e){if(!U(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL Scalar type.`);return e}function q(e){return(0,w.h)(e,eO)}function Q(e){if(!q(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL Object type.`);return e}function Y(e){return(0,w.h)(e,eV)}function G(e){if(!Y(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL Interface type.`);return e}function z(e){return(0,w.h)(e,eF)}function H(e){if(!z(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL Union type.`);return e}function W(e){return(0,w.h)(e,eP)}function K(e){if(!W(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL Enum type.`);return e}function J(e){return(0,w.h)(e,eM)}function Z(e){if(!J(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL Input Object type.`);return e}function X(e){return(0,w.h)(e,em)}function ee(e){if(!X(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL List type.`);return e}function et(e){return(0,w.h)(e,ef)}function ea(e){if(!et(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL Non-Null type.`);return e}function er(e){return U(e)||W(e)||J(e)||eh(e)&&er(e.ofType)}function ei(e){if(!er(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL input type.`);return e}function en(e){return U(e)||q(e)||Y(e)||z(e)||W(e)||eh(e)&&en(e.ofType)}function ep(e){if(!en(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL output type.`);return e}function eo(e){return U(e)||W(e)}function es(e){if(!eo(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL leaf type.`);return e}function ed(e){return q(e)||Y(e)||z(e)}function el(e){if(!ed(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL composite type.`);return e}function eu(e){return Y(e)||z(e)}function ec(e){if(!eu(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL abstract type.`);return e}class em{constructor(e){j(e)||(0,m.U)(!1,`Expected ${(0,v.N)(e)} to be a GraphQL type.`),this.ofType=e}get[Symbol.toStringTag](){return"GraphQLList"}toString(){return"["+String(this.ofType)+"]"}toJSON(){return this.toString()}}class ef{constructor(e){ey(e)||(0,m.U)(!1,`Expected ${(0,v.N)(e)} to be a GraphQL nullable type.`),this.ofType=e}get[Symbol.toStringTag](){return"GraphQLNonNull"}toString(){return String(this.ofType)+"!"}toJSON(){return this.toString()}}function eh(e){return X(e)||et(e)}function ev(e){if(!eh(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL wrapping type.`);return e}function ey(e){return j(e)&&!et(e)}function eg(e){if(!ey(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL nullable type.`);return e}function e_(e){if(e)return et(e)?e.ofType:e}function eb(e){return U(e)||q(e)||Y(e)||z(e)||W(e)||J(e)}function ew(e){if(!eb(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL named type.`);return e}function eE(e){if(e){let t=e;for(;eh(t);)t=t.ofType;return t}}function eT(e){return"function"==typeof e?e():e}function eN(e){return"function"==typeof e?e():e}class eS{constructor(e){var t,a,r,i;let n=null!=(t=e.parseValue)?t:b;this.name=P(e.name),this.description=e.description,this.specifiedByURL=e.specifiedByURL,this.serialize=null!=(a=e.serialize)?a:b,this.parseValue=n,this.parseLiteral=null!=(r=e.parseLiteral)?r:(e,t)=>n(F(e,t)),this.extensions=C(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=null!=(i=e.extensionASTNodes)?i:[],null==e.specifiedByURL||"string"==typeof e.specifiedByURL||(0,m.U)(!1,`${this.name} must provide "specifiedByURL" as a string, but got: ${(0,v.N)(e.specifiedByURL)}.`),null==e.serialize||"function"==typeof e.serialize||(0,m.U)(!1,`${this.name} must provide "serialize" function. If this custom Scalar is also used as an input type, ensure "parseValue" and "parseLiteral" functions are also provided.`),e.parseLiteral&&("function"==typeof e.parseValue&&"function"==typeof e.parseLiteral||(0,m.U)(!1,`${this.name} must provide both "parseValue" and "parseLiteral" functions.`))}get[Symbol.toStringTag](){return"GraphQLScalarType"}toConfig(){return{name:this.name,description:this.description,specifiedByURL:this.specifiedByURL,serialize:this.serialize,parseValue:this.parseValue,parseLiteral:this.parseLiteral,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}class eO{constructor(e){var t;this.name=P(e.name),this.description=e.description,this.isTypeOf=e.isTypeOf,this.extensions=C(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=null!=(t=e.extensionASTNodes)?t:[],this._fields=()=>eD(e),this._interfaces=()=>eI(e),null==e.isTypeOf||"function"==typeof e.isTypeOf||(0,m.U)(!1,`${this.name} must provide "isTypeOf" as a function, but got: ${(0,v.N)(e.isTypeOf)}.`)}get[Symbol.toStringTag](){return"GraphQLObjectType"}getFields(){return"function"==typeof this._fields&&(this._fields=this._fields()),this._fields}getInterfaces(){return"function"==typeof this._interfaces&&(this._interfaces=this._interfaces()),this._interfaces}toConfig(){return{name:this.name,description:this.description,interfaces:this.getInterfaces(),fields:ex(this.getFields()),isTypeOf:this.isTypeOf,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}function eI(e){var t;let a=eT(null!=(t=e.interfaces)?t:[]);return Array.isArray(a)||(0,m.U)(!1,`${e.name} interfaces must be an Array or a function which returns an Array.`),a}function eD(e){let t=eN(e.fields);return ek(t)||(0,m.U)(!1,`${e.name} fields must be an object with field names as keys or a function which returns such an object.`),S(t,(t,a)=>{var r;ek(t)||(0,m.U)(!1,`${e.name}.${a} field config must be an object.`),null==t.resolve||"function"==typeof t.resolve||(0,m.U)(!1,`${e.name}.${a} field resolver must be a function if provided, but got: ${(0,v.N)(t.resolve)}.`);let i=null!=(r=t.args)?r:{};return ek(i)||(0,m.U)(!1,`${e.name}.${a} args must be an object with argument names as keys.`),{name:P(a),description:t.description,type:t.type,args:eA(i),resolve:t.resolve,subscribe:t.subscribe,deprecationReason:t.deprecationReason,extensions:C(t.extensions),astNode:t.astNode}})}function eA(e){return Object.entries(e).map(([e,t])=>({name:P(e),description:t.description,type:t.type,defaultValue:t.defaultValue,deprecationReason:t.deprecationReason,extensions:C(t.extensions),astNode:t.astNode}))}function ek(e){return(0,E.Z)(e)&&!Array.isArray(e)}function ex(e){return S(e,e=>({description:e.description,type:e.type,args:eC(e.args),resolve:e.resolve,subscribe:e.subscribe,deprecationReason:e.deprecationReason,extensions:e.extensions,astNode:e.astNode}))}function eC(e){return N(e,e=>e.name,e=>({description:e.description,type:e.type,defaultValue:e.defaultValue,deprecationReason:e.deprecationReason,extensions:e.extensions,astNode:e.astNode}))}function eR(e){return et(e.type)&&void 0===e.defaultValue}class eV{constructor(e){var t;this.name=P(e.name),this.description=e.description,this.resolveType=e.resolveType,this.extensions=C(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=null!=(t=e.extensionASTNodes)?t:[],this._fields=eD.bind(void 0,e),this._interfaces=eI.bind(void 0,e),null==e.resolveType||"function"==typeof e.resolveType||(0,m.U)(!1,`${this.name} must provide "resolveType" as a function, but got: ${(0,v.N)(e.resolveType)}.`)}get[Symbol.toStringTag](){return"GraphQLInterfaceType"}getFields(){return"function"==typeof this._fields&&(this._fields=this._fields()),this._fields}getInterfaces(){return"function"==typeof this._interfaces&&(this._interfaces=this._interfaces()),this._interfaces}toConfig(){return{name:this.name,description:this.description,interfaces:this.getInterfaces(),fields:ex(this.getFields()),resolveType:this.resolveType,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}class eF{constructor(e){var t;this.name=P(e.name),this.description=e.description,this.resolveType=e.resolveType,this.extensions=C(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=null!=(t=e.extensionASTNodes)?t:[],this._types=e$.bind(void 0,e),null==e.resolveType||"function"==typeof e.resolveType||(0,m.U)(!1,`${this.name} must provide "resolveType" as a function, but got: ${(0,v.N)(e.resolveType)}.`)}get[Symbol.toStringTag](){return"GraphQLUnionType"}getTypes(){return"function"==typeof this._types&&(this._types=this._types()),this._types}toConfig(){return{name:this.name,description:this.description,types:this.getTypes(),resolveType:this.resolveType,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}function e$(e){let t=eT(e.types);return Array.isArray(t)||(0,m.U)(!1,`Must provide Array of types or a function which returns such an array for Union ${e.name}.`),t}class eP{constructor(e){var t;this.name=P(e.name),this.description=e.description,this.extensions=C(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=null!=(t=e.extensionASTNodes)?t:[],this._values="function"==typeof e.values?e.values:ej(this.name,e.values),this._valueLookup=null,this._nameLookup=null}get[Symbol.toStringTag](){return"GraphQLEnumType"}getValues(){return"function"==typeof this._values&&(this._values=ej(this.name,this._values())),this._values}getValue(e){return null===this._nameLookup&&(this._nameLookup=T(this.getValues(),e=>e.name)),this._nameLookup[e]}serialize(e){null===this._valueLookup&&(this._valueLookup=new Map(this.getValues().map(e=>[e.value,e])));let t=this._valueLookup.get(e);if(void 0===t)throw new y.eO(`Enum "${this.name}" cannot represent value: ${(0,v.N)(e)}`);return t.name}parseValue(e){if("string"!=typeof e){let t=(0,v.N)(e);throw new y.eO(`Enum "${this.name}" cannot represent non-string value: ${t}.`+eL(this,t))}let t=this.getValue(e);if(null==t)throw new y.eO(`Value "${e}" does not exist in "${this.name}" enum.`+eL(this,e));return t.value}parseLiteral(e,t){if(e.kind!==R.b.ENUM){let t=(0,V.y)(e);throw new y.eO(`Enum "${this.name}" cannot represent non-enum value: ${t}.`+eL(this,t),{nodes:e})}let a=this.getValue(e.value);if(null==a){let t=(0,V.y)(e);throw new y.eO(`Value "${t}" does not exist in "${this.name}" enum.`+eL(this,t),{nodes:e})}return a.value}toConfig(){let e=N(this.getValues(),e=>e.name,e=>({description:e.description,value:e.value,deprecationReason:e.deprecationReason,extensions:e.extensions,astNode:e.astNode}));return{name:this.name,description:this.description,values:e,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}function eL(e,t){return _("the enum value",A(t,e.getValues().map(e=>e.name)))}function ej(e,t){return ek(t)||(0,m.U)(!1,`${e} values must be an object with value names as keys.`),Object.entries(t).map(([t,a])=>(ek(a)||(0,m.U)(!1,`${e}.${t} must refer to an object with a "value" key representing an internal value but got: ${(0,v.N)(a)}.`),{name:L(t),description:a.description,value:void 0!==a.value?a.value:t,deprecationReason:a.deprecationReason,extensions:C(a.extensions),astNode:a.astNode}))}class eM{constructor(e){var t,a;this.name=P(e.name),this.description=e.description,this.extensions=C(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=null!=(t=e.extensionASTNodes)?t:[],this.isOneOf=null!=(a=e.isOneOf)&&a,this._fields=eU.bind(void 0,e)}get[Symbol.toStringTag](){return"GraphQLInputObjectType"}getFields(){return"function"==typeof this._fields&&(this._fields=this._fields()),this._fields}toConfig(){let e=S(this.getFields(),e=>({description:e.description,type:e.type,defaultValue:e.defaultValue,deprecationReason:e.deprecationReason,extensions:e.extensions,astNode:e.astNode}));return{name:this.name,description:this.description,fields:e,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes,isOneOf:this.isOneOf}}toString(){return this.name}toJSON(){return this.toString()}}function eU(e){let t=eN(e.fields);return ek(t)||(0,m.U)(!1,`${e.name} fields must be an object with field names as keys or a function which returns such an object.`),S(t,(t,a)=>("resolve"in t&&(0,m.U)(!1,`${e.name}.${a} field has a resolve property, but Input Types cannot define resolvers.`),{name:P(a),description:t.description,type:t.type,defaultValue:t.defaultValue,deprecationReason:t.deprecationReason,extensions:C(t.extensions),astNode:t.astNode}))}function eB(e){return et(e.type)&&void 0===e.defaultValue}function eq(e,t){return e===t||!!(et(e)&&et(t)||X(e)&&X(t))&&eq(e.ofType,t.ofType)}function eQ(e,t,a){return t===a||(et(a)?!!et(t)&&eQ(e,t.ofType,a.ofType):et(t)?eQ(e,t.ofType,a):X(a)?!!X(t)&&eQ(e,t.ofType,a.ofType):!X(t)&&eu(a)&&(Y(t)||q(t))&&e.isSubType(a,t))}function eY(e,t,a){return t===a||(eu(t)?eu(a)?e.getPossibleTypes(t).some(t=>e.isSubType(a,t)):e.isSubType(t,a):!!eu(a)&&e.isSubType(a,t))}var eG=a(42868);let ez=0x7fffffff,eH=-0x80000000,eW=new eS({name:"Int",description:"The `Int` scalar type represents non-fractional signed whole numeric values. Int can represent values between -(2^31) and 2^31 - 1.",serialize(e){let t=e2(e);if("boolean"==typeof t)return+!!t;let a=t;if("string"==typeof t&&""!==t&&(a=Number(t)),"number"!=typeof a||!Number.isInteger(a))throw new y.eO(`Int cannot represent non-integer value: ${(0,v.N)(t)}`);if(a>ez||a<eH)throw new y.eO("Int cannot represent non 32-bit signed integer value: "+(0,v.N)(t));return a},parseValue(e){if("number"!=typeof e||!Number.isInteger(e))throw new y.eO(`Int cannot represent non-integer value: ${(0,v.N)(e)}`);if(e>ez||e<eH)throw new y.eO(`Int cannot represent non 32-bit signed integer value: ${e}`);return e},parseLiteral(e){if(e.kind!==R.b.INT)throw new y.eO(`Int cannot represent non-integer value: ${(0,V.y)(e)}`,{nodes:e});let t=parseInt(e.value,10);if(t>ez||t<eH)throw new y.eO(`Int cannot represent non 32-bit signed integer value: ${e.value}`,{nodes:e});return t}}),eK=new eS({name:"Float",description:"The `Float` scalar type represents signed double-precision fractional values as specified by [IEEE 754](https://en.wikipedia.org/wiki/IEEE_floating_point).",serialize(e){let t=e2(e);if("boolean"==typeof t)return+!!t;let a=t;if("string"==typeof t&&""!==t&&(a=Number(t)),"number"!=typeof a||!Number.isFinite(a))throw new y.eO(`Float cannot represent non numeric value: ${(0,v.N)(t)}`);return a},parseValue(e){if("number"!=typeof e||!Number.isFinite(e))throw new y.eO(`Float cannot represent non numeric value: ${(0,v.N)(e)}`);return e},parseLiteral(e){if(e.kind!==R.b.FLOAT&&e.kind!==R.b.INT)throw new y.eO(`Float cannot represent non numeric value: ${(0,V.y)(e)}`,e);return parseFloat(e.value)}}),eJ=new eS({name:"String",description:"The `String` scalar type represents textual data, represented as UTF-8 character sequences. The String type is most often used by GraphQL to represent free-form human-readable text.",serialize(e){let t=e2(e);if("string"==typeof t)return t;if("boolean"==typeof t)return t?"true":"false";if("number"==typeof t&&Number.isFinite(t))return t.toString();throw new y.eO(`String cannot represent value: ${(0,v.N)(e)}`)},parseValue(e){if("string"!=typeof e)throw new y.eO(`String cannot represent a non string value: ${(0,v.N)(e)}`);return e},parseLiteral(e){if(e.kind!==R.b.STRING)throw new y.eO(`String cannot represent a non string value: ${(0,V.y)(e)}`,{nodes:e});return e.value}}),eZ=new eS({name:"Boolean",description:"The `Boolean` scalar type represents `true` or `false`.",serialize(e){let t=e2(e);if("boolean"==typeof t)return t;if(Number.isFinite(t))return 0!==t;throw new y.eO(`Boolean cannot represent a non boolean value: ${(0,v.N)(t)}`)},parseValue(e){if("boolean"!=typeof e)throw new y.eO(`Boolean cannot represent a non boolean value: ${(0,v.N)(e)}`);return e},parseLiteral(e){if(e.kind!==R.b.BOOLEAN)throw new y.eO(`Boolean cannot represent a non boolean value: ${(0,V.y)(e)}`,{nodes:e});return e.value}}),eX=new eS({name:"ID",description:'The `ID` scalar type represents a unique identifier, often used to refetch an object or as key for a cache. The ID type appears in a JSON response as a String; however, it is not intended to be human-readable. When expected as an input type, any string (such as `"4"`) or integer (such as `4`) input value will be accepted as an ID.',serialize(e){let t=e2(e);if("string"==typeof t)return t;if(Number.isInteger(t))return String(t);throw new y.eO(`ID cannot represent value: ${(0,v.N)(e)}`)},parseValue(e){if("string"==typeof e)return e;if("number"==typeof e&&Number.isInteger(e))return e.toString();throw new y.eO(`ID cannot represent value: ${(0,v.N)(e)}`)},parseLiteral(e){if(e.kind!==R.b.STRING&&e.kind!==R.b.INT)throw new y.eO("ID cannot represent a non-string and non-integer value: "+(0,V.y)(e),{nodes:e});return e.value}}),e1=Object.freeze([eJ,eW,eK,eZ,eX]);function e0(e){return e1.some(({name:t})=>e.name===t)}function e2(e){if((0,E.Z)(e)){if("function"==typeof e.valueOf){let t=e.valueOf();if(!(0,E.Z)(t))return t}if("function"==typeof e.toJSON)return e.toJSON()}return e}function e6(e){return(0,w.h)(e,e3)}function e4(e){if(!e6(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL directive.`);return e}class e3{constructor(e){var t,a;this.name=P(e.name),this.description=e.description,this.locations=e.locations,this.isRepeatable=null!=(t=e.isRepeatable)&&t,this.extensions=C(e.extensions),this.astNode=e.astNode,Array.isArray(e.locations)||(0,m.U)(!1,`@${e.name} locations must be an Array.`);let r=null!=(a=e.args)?a:{};(0,E.Z)(r)&&!Array.isArray(r)||(0,m.U)(!1,`@${e.name} args must be an object with argument names as keys.`),this.args=eA(r)}get[Symbol.toStringTag](){return"GraphQLDirective"}toConfig(){return{name:this.name,description:this.description,locations:this.locations,args:eC(this.args),isRepeatable:this.isRepeatable,extensions:this.extensions,astNode:this.astNode}}toString(){return"@"+this.name}toJSON(){return this.toString()}}let e9=new e3({name:"include",description:"Directs the executor to include this field or fragment only when the `if` argument is true.",locations:[eG.H.FIELD,eG.H.FRAGMENT_SPREAD,eG.H.INLINE_FRAGMENT],args:{if:{type:new ef(eZ),description:"Included when true."}}}),e5=new e3({name:"skip",description:"Directs the executor to skip this field or fragment when the `if` argument is true.",locations:[eG.H.FIELD,eG.H.FRAGMENT_SPREAD,eG.H.INLINE_FRAGMENT],args:{if:{type:new ef(eZ),description:"Skipped when true."}}}),e8="No longer supported",e7=new e3({name:"deprecated",description:"Marks an element of a GraphQL schema as no longer supported.",locations:[eG.H.FIELD_DEFINITION,eG.H.ARGUMENT_DEFINITION,eG.H.INPUT_FIELD_DEFINITION,eG.H.ENUM_VALUE],args:{reason:{type:eJ,description:"Explains why this element was deprecated, usually also including a suggestion for how to access supported similar data. Formatted using the Markdown syntax, as specified by [CommonMark](https://commonmark.org/).",defaultValue:e8}}}),te=new e3({name:"specifiedBy",description:"Exposes a URL that specifies the behavior of this scalar.",locations:[eG.H.SCALAR],args:{url:{type:new ef(eJ),description:"The URL that specifies the behavior of this scalar."}}}),tt=new e3({name:"oneOf",description:"Indicates exactly one field must be supplied and this field must not be `null`.",locations:[eG.H.INPUT_OBJECT],args:{}}),ta=Object.freeze([e9,e5,e7,te,tt]);function tr(e){return ta.some(({name:t})=>t===e.name)}var ti=a(71306);function tn(e){return"object"==typeof e&&"function"==typeof(null==e?void 0:e[Symbol.iterator])}function tp(e,t){if(et(t)){let a=tp(e,t.ofType);return(null==a?void 0:a.kind)===R.b.NULL?null:a}if(null===e)return{kind:R.b.NULL};if(void 0===e)return null;if(X(t)){let a=t.ofType;if(tn(e)){let t=[];for(let r of e){let e=tp(r,a);null!=e&&t.push(e)}return{kind:R.b.LIST,values:t}}return tp(e,a)}if(J(t)){if(!(0,E.Z)(e))return null;let a=[];for(let r of Object.values(t.getFields())){let t=tp(e[r.name],r.type);t&&a.push({kind:R.b.OBJECT_FIELD,name:{kind:R.b.NAME,value:r.name},value:t})}return{kind:R.b.OBJECT,fields:a}}if(eo(t)){let a=t.serialize(e);if(null==a)return null;if("boolean"==typeof a)return{kind:R.b.BOOLEAN,value:a};if("number"==typeof a&&Number.isFinite(a)){let e=String(a);return to.test(e)?{kind:R.b.INT,value:e}:{kind:R.b.FLOAT,value:e}}if("string"==typeof a)return W(t)?{kind:R.b.ENUM,value:a}:t===eX&&to.test(a)?{kind:R.b.INT,value:a}:{kind:R.b.STRING,value:a};throw TypeError(`Cannot convert value to AST: ${(0,v.N)(a)}.`)}(0,ti.V)(!1,"Unexpected input type: "+(0,v.N)(t))}let to=/^-?(?:0|[1-9][0-9]*)$/,ts=new eO({name:"__Schema",description:"A GraphQL Schema defines the capabilities of a GraphQL server. It exposes all available types and directives on the server, as well as the entry points for query, mutation, and subscription operations.",fields:()=>({description:{type:eJ,resolve:e=>e.description},types:{description:"A list of all types supported by this server.",type:new ef(new em(new ef(tu))),resolve:e=>Object.values(e.getTypeMap())},queryType:{description:"The type that query operations will be rooted at.",type:new ef(tu),resolve:e=>e.getQueryType()},mutationType:{description:"If this server supports mutation, the type that mutation operations will be rooted at.",type:tu,resolve:e=>e.getMutationType()},subscriptionType:{description:"If this server support subscription, the type that subscription operations will be rooted at.",type:tu,resolve:e=>e.getSubscriptionType()},directives:{description:"A list of all directives supported by this server.",type:new ef(new em(new ef(td))),resolve:e=>e.getDirectives()}})}),td=new eO({name:"__Directive",description:"A Directive provides a way to describe alternate runtime execution and type validation behavior in a GraphQL document.\n\nIn 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 ef(eJ),resolve:e=>e.name},description:{type:eJ,resolve:e=>e.description},isRepeatable:{type:new ef(eZ),resolve:e=>e.isRepeatable},locations:{type:new ef(new em(new ef(tl))),resolve:e=>e.locations},args:{type:new ef(new em(new ef(tm))),args:{includeDeprecated:{type:eZ,defaultValue:!1}},resolve:(e,{includeDeprecated:t})=>t?e.args:e.args.filter(e=>null==e.deprecationReason)}})}),tl=new eP({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:eG.H.QUERY,description:"Location adjacent to a query operation."},MUTATION:{value:eG.H.MUTATION,description:"Location adjacent to a mutation operation."},SUBSCRIPTION:{value:eG.H.SUBSCRIPTION,description:"Location adjacent to a subscription operation."},FIELD:{value:eG.H.FIELD,description:"Location adjacent to a field."},FRAGMENT_DEFINITION:{value:eG.H.FRAGMENT_DEFINITION,description:"Location adjacent to a fragment definition."},FRAGMENT_SPREAD:{value:eG.H.FRAGMENT_SPREAD,description:"Location adjacent to a fragment spread."},INLINE_FRAGMENT:{value:eG.H.INLINE_FRAGMENT,description:"Location adjacent to an inline fragment."},VARIABLE_DEFINITION:{value:eG.H.VARIABLE_DEFINITION,description:"Location adjacent to a variable definition."},SCHEMA:{value:eG.H.SCHEMA,description:"Location adjacent to a schema definition."},SCALAR:{value:eG.H.SCALAR,description:"Location adjacent to a scalar definition."},OBJECT:{value:eG.H.OBJECT,description:"Location adjacent to an object type definition."},FIELD_DEFINITION:{value:eG.H.FIELD_DEFINITION,description:"Location adjacent to a field definition."},ARGUMENT_DEFINITION:{value:eG.H.ARGUMENT_DEFINITION,description:"Location adjacent to an argument definition."},INTERFACE:{value:eG.H.INTERFACE,description:"Location adjacent to an interface definition."},UNION:{value:eG.H.UNION,description:"Location adjacent to a union definition."},ENUM:{value:eG.H.ENUM,description:"Location adjacent to an enum definition."},ENUM_VALUE:{value:eG.H.ENUM_VALUE,description:"Location adjacent to an enum value definition."},INPUT_OBJECT:{value:eG.H.INPUT_OBJECT,description:"Location adjacent to an input object type definition."},INPUT_FIELD_DEFINITION:{value:eG.H.INPUT_FIELD_DEFINITION,description:"Location adjacent to an input object field definition."}}}),tu=new eO({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 ef(th),resolve:e=>U(e)?l.SCALAR:q(e)?l.OBJECT:Y(e)?l.INTERFACE:z(e)?l.UNION:W(e)?l.ENUM:J(e)?l.INPUT_OBJECT:X(e)?l.LIST:et(e)?l.NON_NULL:void(0,ti.V)(!1,`Unexpected type: "${(0,v.N)(e)}".`)},name:{type:eJ,resolve:e=>"name"in e?e.name:void 0},description:{type:eJ,resolve:e=>"description"in e?e.description:void 0},specifiedByURL:{type:eJ,resolve:e=>"specifiedByURL"in e?e.specifiedByURL:void 0},fields:{type:new em(new ef(tc)),args:{includeDeprecated:{type:eZ,defaultValue:!1}},resolve(e,{includeDeprecated:t}){if(q(e)||Y(e)){let a=Object.values(e.getFields());return t?a:a.filter(e=>null==e.deprecationReason)}}},interfaces:{type:new em(new ef(tu)),resolve(e){if(q(e)||Y(e))return e.getInterfaces()}},possibleTypes:{type:new em(new ef(tu)),resolve(e,t,a,{schema:r}){if(eu(e))return r.getPossibleTypes(e)}},enumValues:{type:new em(new ef(tf)),args:{includeDeprecated:{type:eZ,defaultValue:!1}},resolve(e,{includeDeprecated:t}){if(W(e)){let a=e.getValues();return t?a:a.filter(e=>null==e.deprecationReason)}}},inputFields:{type:new em(new ef(tm)),args:{includeDeprecated:{type:eZ,defaultValue:!1}},resolve(e,{includeDeprecated:t}){if(J(e)){let a=Object.values(e.getFields());return t?a:a.filter(e=>null==e.deprecationReason)}}},ofType:{type:tu,resolve:e=>"ofType"in e?e.ofType:void 0},isOneOf:{type:eZ,resolve:e=>{if(J(e))return e.isOneOf}}})}),tc=new eO({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 ef(eJ),resolve:e=>e.name},description:{type:eJ,resolve:e=>e.description},args:{type:new ef(new em(new ef(tm))),args:{includeDeprecated:{type:eZ,defaultValue:!1}},resolve:(e,{includeDeprecated:t})=>t?e.args:e.args.filter(e=>null==e.deprecationReason)},type:{type:new ef(tu),resolve:e=>e.type},isDeprecated:{type:new ef(eZ),resolve:e=>null!=e.deprecationReason},deprecationReason:{type:eJ,resolve:e=>e.deprecationReason}})}),tm=new eO({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 ef(eJ),resolve:e=>e.name},description:{type:eJ,resolve:e=>e.description},type:{type:new ef(tu),resolve:e=>e.type},defaultValue:{type:eJ,description:"A GraphQL-formatted string representing the default value for this input value.",resolve(e){let{type:t,defaultValue:a}=e,r=tp(a,t);return r?(0,V.y)(r):null}},isDeprecated:{type:new ef(eZ),resolve:e=>null!=e.deprecationReason},deprecationReason:{type:eJ,resolve:e=>e.deprecationReason}})}),tf=new eO({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 ef(eJ),resolve:e=>e.name},description:{type:eJ,resolve:e=>e.description},isDeprecated:{type:new ef(eZ),resolve:e=>null!=e.deprecationReason},deprecationReason:{type:eJ,resolve:e=>e.deprecationReason}})});(p=l||(l={})).SCALAR="SCALAR",p.OBJECT="OBJECT",p.INTERFACE="INTERFACE",p.UNION="UNION",p.ENUM="ENUM",p.INPUT_OBJECT="INPUT_OBJECT",p.LIST="LIST",p.NON_NULL="NON_NULL";let th=new eP({name:"__TypeKind",description:"An enum describing what kind of type a given `__Type` is.",values:{SCALAR:{value:l.SCALAR,description:"Indicates this type is a scalar."},OBJECT:{value:l.OBJECT,description:"Indicates this type is an object. `fields` and `interfaces` are valid fields."},INTERFACE:{value:l.INTERFACE,description:"Indicates this type is an interface. `fields`, `interfaces`, and `possibleTypes` are valid fields."},UNION:{value:l.UNION,description:"Indicates this type is a union. `possibleTypes` is a valid field."},ENUM:{value:l.ENUM,description:"Indicates this type is an enum. `enumValues` is a valid field."},INPUT_OBJECT:{value:l.INPUT_OBJECT,description:"Indicates this type is an input object. `inputFields` is a valid field."},LIST:{value:l.LIST,description:"Indicates this type is a list. `ofType` is a valid field."},NON_NULL:{value:l.NON_NULL,description:"Indicates this type is a non-null. `ofType` is a valid field."}}}),tv={name:"__schema",type:new ef(ts),description:"Access the current type schema of this server.",args:[],resolve:(e,t,a,{schema:r})=>r,deprecationReason:void 0,extensions:Object.create(null),astNode:void 0},ty={name:"__type",type:tu,description:"Request the type information of a single type.",args:[{name:"name",description:void 0,type:new ef(eJ),defaultValue:void 0,deprecationReason:void 0,extensions:Object.create(null),astNode:void 0}],resolve:(e,{name:t},a,{schema:r})=>r.getType(t),deprecationReason:void 0,extensions:Object.create(null),astNode:void 0},tg={name:"__typename",type:new ef(eJ),description:"The name of the current Object type at runtime.",args:[],resolve:(e,t,a,{parentType:r})=>r.name,deprecationReason:void 0,extensions:Object.create(null),astNode:void 0},t_=Object.freeze([ts,td,tl,tu,tc,tm,tf,th]);function tb(e){return t_.some(({name:t})=>e.name===t)}function tw(e){return(0,w.h)(e,tT)}function tE(e){if(!tw(e))throw Error(`Expected ${(0,v.N)(e)} to be a GraphQL schema.`);return e}class tT{constructor(e){var t,a;this.__validationErrors=!0===e.assumeValid?[]:void 0,(0,E.Z)(e)||(0,m.U)(!1,"Must provide configuration object."),!e.types||Array.isArray(e.types)||(0,m.U)(!1,`"types" must be Array if provided but got: ${(0,v.N)(e.types)}.`),!e.directives||Array.isArray(e.directives)||(0,m.U)(!1,`"directives" must be Array if provided but got: ${(0,v.N)(e.directives)}.`),this.description=e.description,this.extensions=C(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=null!=(t=e.extensionASTNodes)?t:[],this._queryType=e.query,this._mutationType=e.mutation,this._subscriptionType=e.subscription,this._directives=null!=(a=e.directives)?a:ta;let r=new Set(e.types);if(null!=e.types)for(let t of e.types)r.delete(t),tN(t,r);for(let e of(null!=this._queryType&&tN(this._queryType,r),null!=this._mutationType&&tN(this._mutationType,r),null!=this._subscriptionType&&tN(this._subscriptionType,r),this._directives))if(e6(e))for(let t of e.args)tN(t.type,r);for(let e of(tN(ts,r),this._typeMap=Object.create(null),this._subTypeMap=Object.create(null),this._implementationsMap=Object.create(null),r)){if(null==e)continue;let t=e.name;if(t||(0,m.U)(!1,"One of the provided types for building the Schema is missing a name."),void 0!==this._typeMap[t])throw Error(`Schema must contain uniquely named types but contains multiple types named "${t}".`);if(this._typeMap[t]=e,Y(e)){for(let t of e.getInterfaces())if(Y(t)){let a=this._implementationsMap[t.name];void 0===a&&(a=this._implementationsMap[t.name]={objects:[],interfaces:[]}),a.interfaces.push(e)}}else if(q(e)){for(let t of e.getInterfaces())if(Y(t)){let a=this._implementationsMap[t.name];void 0===a&&(a=this._implementationsMap[t.name]={objects:[],interfaces:[]}),a.objects.push(e)}}}}get[Symbol.toStringTag](){return"GraphQLSchema"}getQueryType(){return this._queryType}getMutationType(){return this._mutationType}getSubscriptionType(){return this._subscriptionType}getRootType(e){switch(e){case g.cE.QUERY:return this.getQueryType();case g.cE.MUTATION:return this.getMutationType();case g.cE.SUBSCRIPTION:return this.getSubscriptionType()}}getTypeMap(){return this._typeMap}getType(e){return this.getTypeMap()[e]}getPossibleTypes(e){return z(e)?e.getTypes():this.getImplementations(e).objects}getImplementations(e){let t=this._implementationsMap[e.name];return null!=t?t:{objects:[],interfaces:[]}}isSubType(e,t){let a=this._subTypeMap[e.name];if(void 0===a){if(a=Object.create(null),z(e))for(let t of e.getTypes())a[t.name]=!0;else{let t=this.getImplementations(e);for(let e of t.objects)a[e.name]=!0;for(let e of t.interfaces)a[e.name]=!0}this._subTypeMap[e.name]=a}return void 0!==a[t.name]}getDirectives(){return this._directives}getDirective(e){return this.getDirectives().find(t=>t.name===e)}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:void 0!==this.__validationErrors}}}function tN(e,t){let a=eE(e);if(!t.has(a)){if(t.add(a),z(a))for(let e of a.getTypes())tN(e,t);else if(q(a)||Y(a)){for(let e of a.getInterfaces())tN(e,t);for(let e of Object.values(a.getFields()))for(let a of(tN(e.type,t),e.args))tN(a.type,t)}else if(J(a))for(let e of Object.values(a.getFields()))tN(e.type,t)}return t}function tS(e){var t,a,r,i;let n,p,o,s;if(tE(e),e.__validationErrors)return e.__validationErrors;let d=new tI(e);(p=(n=(t=d).schema).getQueryType())?q(p)||t.reportError(`Query root type must be Object type, it cannot be ${(0,v.N)(p)}.`,null!=(a=tD(n,g.cE.QUERY))?a:p.astNode):t.reportError("Query root type must be provided.",n.astNode),(o=n.getMutationType())&&!q(o)&&t.reportError(`Mutation root type must be Object type if provided, it cannot be ${(0,v.N)(o)}.`,null!=(r=tD(n,g.cE.MUTATION))?r:o.astNode),(s=n.getSubscriptionType())&&!q(s)&&t.reportError(`Subscription root type must be Object type if provided, it cannot be ${(0,v.N)(s)}.`,null!=(i=tD(n,g.cE.SUBSCRIPTION))?i:s.astNode),function(e){for(let a of e.schema.getDirectives()){if(!e6(a)){e.reportError(`Expected directive but got: ${(0,v.N)(a)}.`,null==a?void 0:a.astNode);continue}for(let r of(tA(e,a),0===a.locations.length&&e.reportError(`Directive @${a.name} must include 1 or more locations.`,a.astNode),a.args))if(tA(e,r),er(r.type)||e.reportError(`The type of @${a.name}(${r.name}:) must be Input Type but got: ${(0,v.N)(r.type)}.`,r.astNode),eR(r)&&null!=r.deprecationReason){var t;e.reportError(`Required argument @${a.name}(${r.name}:) cannot be deprecated.`,[tC(r.astNode),null==(t=r.astNode)?void 0:t.type])}}}(d),function(e){var t;let a,r,i,n=(t=e,a=Object.create(null),r=[],i=Object.create(null),function e(n){if(!a[n.name]){for(let p of(a[n.name]=!0,i[n.name]=r.length,Object.values(n.getFields())))if(et(p.type)&&J(p.type.ofType)){let a=p.type.ofType,n=i[a.name];if(r.push(p),void 0===n)e(a);else{let e=r.slice(n),i=e.map(e=>e.name).join(".");t.reportError(`Cannot reference Input Object "${a.name}" within itself through a series of non-null fields: "${i}".`,e.map(e=>e.astNode))}r.pop()}i[n.name]=void 0}});for(let t of Object.values(e.schema.getTypeMap())){if(!eb(t)){e.reportError(`Expected GraphQL named type but got: ${(0,v.N)(t)}.`,t.astNode);continue}tb(t)||tA(e,t),q(t)||Y(t)?(function(e,t){let a=Object.values(t.getFields());for(let p of(0===a.length&&e.reportError(`Type ${t.name} must define one or more fields.`,[t.astNode,...t.extensionASTNodes]),a)){var r,i,n;for(let a of(tA(e,p),en(p.type)||e.reportError(`The type of ${t.name}.${p.name} must be Output Type but got: ${(0,v.N)(p.type)}.`,null==(r=p.astNode)?void 0:r.type),p.args)){let r=a.name;tA(e,a),er(a.type)||e.reportError(`The type of ${t.name}.${p.name}(${r}:) must be Input Type but got: ${(0,v.N)(a.type)}.`,null==(i=a.astNode)?void 0:i.type),eR(a)&&null!=a.deprecationReason&&e.reportError(`Required argument ${t.name}.${p.name}(${r}:) cannot be deprecated.`,[tC(a.astNode),null==(n=a.astNode)?void 0:n.type])}}}(e,t),function(e,t){let a=Object.create(null);for(let r of t.getInterfaces()){if(!Y(r)){e.reportError(`Type ${(0,v.N)(t)} must only implement Interface types, it cannot implement ${(0,v.N)(r)}.`,tk(t,r));continue}if(t===r){e.reportError(`Type ${t.name} cannot implement itself because it would create a circular reference.`,tk(t,r));continue}if(a[r.name]){e.reportError(`Type ${t.name} can only implement ${r.name} once.`,tk(t,r));continue}a[r.name]=!0,function(e,t,a){let r=t.getInterfaces();for(let i of a.getInterfaces())r.includes(i)||e.reportError(i===t?`Type ${t.name} cannot implement ${a.name} because it would create a circular reference.`:`Type ${t.name} must implement ${i.name} because it is implemented by ${a.name}.`,[...tk(a,i),...tk(t,a)])}(e,t,r),function(e,t,a){let r=t.getFields();for(let s of Object.values(a.getFields())){var i,n,p,o;let d=s.name,l=r[d];if(!l){e.reportError(`Interface field ${a.name}.${d} expected but ${t.name} does not provide it.`,[s.astNode,t.astNode,...t.extensionASTNodes]);continue}for(let r of(eQ(e.schema,l.type,s.type)||e.reportError(`Interface field ${a.name}.${d} expects type ${(0,v.N)(s.type)} but ${t.name}.${d} is type ${(0,v.N)(l.type)}.`,[null==(i=s.astNode)?void 0:i.type,null==(n=l.astNode)?void 0:n.type]),s.args)){let i=r.name,n=l.args.find(e=>e.name===i);if(!n){e.reportError(`Interface field argument ${a.name}.${d}(${i}:) expected but ${t.name}.${d} does not provide it.`,[r.astNode,l.astNode]);continue}eq(r.type,n.type)||e.reportError(`Interface field argument ${a.name}.${d}(${i}:) expects type ${(0,v.N)(r.type)} but ${t.name}.${d}(${i}:) is type ${(0,v.N)(n.type)}.`,[null==(p=r.astNode)?void 0:p.type,null==(o=n.astNode)?void 0:o.type])}for(let r of l.args){let i=r.name;!s.args.find(e=>e.name===i)&&eR(r)&&e.reportError(`Object field ${t.name}.${d} includes required argument ${i} that is missing from the Interface field ${a.name}.${d}.`,[r.astNode,s.astNode])}}}(e,t,r)}}(e,t)):z(t)?function(e,t){let a=t.getTypes();0===a.length&&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 a){if(r[i.name]){e.reportError(`Union type ${t.name} can only include type ${i.name} once.`,tx(t,i.name));continue}r[i.name]=!0,q(i)||e.reportError(`Union type ${t.name} can only include Object types, it cannot include ${(0,v.N)(i)}.`,tx(t,String(i)))}}(e,t):W(t)?function(e,t){let a=t.getValues();for(let r of(0===a.length&&e.reportError(`Enum type ${t.name} must define one or more values.`,[t.astNode,...t.extensionASTNodes]),a))tA(e,r)}(e,t):J(t)&&(function(e,t){let a=Object.values(t.getFields());for(let n of(0===a.length&&e.reportError(`Input Object type ${t.name} must define one or more fields.`,[t.astNode,...t.extensionASTNodes]),a)){var r,i;tA(e,n),er(n.type)||e.reportError(`The type of ${t.name}.${n.name} must be Input Type but got: ${(0,v.N)(n.type)}.`,null==(r=n.astNode)?void 0:r.type),eB(n)&&null!=n.deprecationReason&&e.reportError(`Required input field ${t.name}.${n.name} cannot be deprecated.`,[tC(n.astNode),null==(i=n.astNode)?void 0:i.type]),t.isOneOf&&function(e,t,a){if(et(t.type)){var r;a.reportError(`OneOf input field ${e.name}.${t.name} must be nullable.`,null==(r=t.astNode)?void 0:r.type)}void 0!==t.defaultValue&&a.reportError(`OneOf input field ${e.name}.${t.name} cannot have a default value.`,t.astNode)}(t,n,e)}}(e,t),n(t))}}(d);let l=d.getErrors();return e.__validationErrors=l,l}function tO(e){let t=tS(e);if(0!==t.length)throw Error(t.map(e=>e.message).join("\n\n"))}class tI{constructor(e){this._errors=[],this.schema=e}reportError(e,t){let a=Array.isArray(t)?t.filter(Boolean):t;this._errors.push(new y.eO(e,{nodes:a}))}getErrors(){return this._errors}}function tD(e,t){var a;return null==(a=[e.astNode,...e.extensionASTNodes].flatMap(e=>{var t;return null!=(t=null==e?void 0:e.operationTypes)?t:[]}).find(e=>e.operation===t))?void 0:a.type}function tA(e,t){t.name.startsWith("__")&&e.reportError(`Name "${t.name}" must not begin with "__", which is reserved by GraphQL introspection.`,t.astNode)}function tk(e,t){let{astNode:a,extensionASTNodes:r}=e;return(null!=a?[a,...r]:r).flatMap(e=>{var t;return null!=(t=e.interfaces)?t:[]}).filter(e=>e.name.value===t.name)}function tx(e,t){let{astNode:a,extensionASTNodes:r}=e;return(null!=a?[a,...r]:r).flatMap(e=>{var t;return null!=(t=e.types)?t:[]}).filter(e=>e.name.value===t)}function tC(e){var t;return null==e||null==(t=e.directives)?void 0:t.find(e=>e.name.value===e7.name)}var tR=a(90424);function tV(e,t){switch(t.kind){case R.b.LIST_TYPE:{let a=tV(e,t.type);return a&&new em(a)}case R.b.NON_NULL_TYPE:{let a=tV(e,t.type);return a&&new ef(a)}case R.b.NAMED_TYPE:return e.getType(t.name.value)}}class tF{constructor(e,t,a){this._schema=e,this._typeStack=[],this._parentTypeStack=[],this._inputTypeStack=[],this._fieldDefStack=[],this._defaultValueStack=[],this._directive=null,this._argument=null,this._enumValue=null,this._getFieldDef=null!=a?a:t$,t&&(er(t)&&this._inputTypeStack.push(t),ed(t)&&this._parentTypeStack.push(t),en(t)&&this._typeStack.push(t))}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(e){let t=this._schema;switch(e.kind){case R.b.SELECTION_SET:{let e=eE(this.getType());this._parentTypeStack.push(ed(e)?e:void 0);break}case R.b.FIELD:{let a,r,i=this.getParentType();i&&(a=this._getFieldDef(t,i,e))&&(r=a.type),this._fieldDefStack.push(a),this._typeStack.push(en(r)?r:void 0);break}case R.b.DIRECTIVE:this._directive=t.getDirective(e.name.value);break;case R.b.OPERATION_DEFINITION:{let a=t.getRootType(e.operation);this._typeStack.push(q(a)?a:void 0);break}case R.b.INLINE_FRAGMENT:case R.b.FRAGMENT_DEFINITION:{let a=e.typeCondition,r=a?tV(t,a):eE(this.getType());this._typeStack.push(en(r)?r:void 0);break}case R.b.VARIABLE_DEFINITION:{let a=tV(t,e.type);this._inputTypeStack.push(er(a)?a:void 0);break}case R.b.ARGUMENT:{var a;let t,r,i=null!=(a=this.getDirective())?a:this.getFieldDef();i&&(t=i.args.find(t=>t.name===e.name.value))&&(r=t.type),this._argument=t,this._defaultValueStack.push(t?t.defaultValue:void 0),this._inputTypeStack.push(er(r)?r:void 0);break}case R.b.LIST:{let e=e_(this.getInputType()),t=X(e)?e.ofType:e;this._defaultValueStack.push(void 0),this._inputTypeStack.push(er(t)?t:void 0);break}case R.b.OBJECT_FIELD:{let t,a,r=eE(this.getInputType());J(r)&&(a=r.getFields()[e.name.value])&&(t=a.type),this._defaultValueStack.push(a?a.defaultValue:void 0),this._inputTypeStack.push(er(t)?t:void 0);break}case R.b.ENUM:{let t,a=eE(this.getInputType());W(a)&&(t=a.getValue(e.value)),this._enumValue=t}}}leave(e){switch(e.kind){case R.b.SELECTION_SET:this._parentTypeStack.pop();break;case R.b.FIELD:this._fieldDefStack.pop(),this._typeStack.pop();break;case R.b.DIRECTIVE:this._directive=null;break;case R.b.OPERATION_DEFINITION:case R.b.INLINE_FRAGMENT:case R.b.FRAGMENT_DEFINITION:this._typeStack.pop();break;case R.b.VARIABLE_DEFINITION:this._inputTypeStack.pop();break;case R.b.ARGUMENT:this._argument=null,this._defaultValueStack.pop(),this._inputTypeStack.pop();break;case R.b.LIST:case R.b.OBJECT_FIELD:this._defaultValueStack.pop(),this._inputTypeStack.pop();break;case R.b.ENUM:this._enumValue=null}}}function t$(e,t,a){let r=a.name.value;return r===tv.name&&e.getQueryType()===t?tv:r===ty.name&&e.getQueryType()===t?ty:r===tg.name&&ed(t)?tg:q(t)||Y(t)?t.getFields()[r]:void 0}function tP(e,t){return{enter(...a){let r=a[0];e.enter(r);let i=(0,tR.XO)(t,r.kind).enter;if(i){let n=i.apply(t,a);return void 0!==n&&(e.leave(r),(0,g.Ll)(n)&&e.enter(n)),n}},leave(...a){let r,i=a[0],n=(0,tR.XO)(t,i.kind).leave;return n&&(r=n.apply(t,a)),e.leave(i),r}}}var tL=a(3420);function tj(e){return{Document(t){for(let a of t.definitions)if(!(0,tL._m)(a)){let t=a.kind===R.b.SCHEMA_DEFINITION||a.kind===R.b.SCHEMA_EXTENSION?"schema":'"'+a.name.value+'"';e.reportError(new y.eO(`The ${t} definition is not executable.`,{nodes:a}))}return!1}}}function tM(e){return{Field(t){let a=e.getParentType();if(a&&!e.getFieldDef()){var r,i;let n=e.getSchema(),p=t.name.value,o=_("to use an inline fragment on",function(e,t,a){if(!eu(t))return[];let r=new Set,i=Object.create(null);for(let p of e.getPossibleTypes(t))if(p.getFields()[a])for(let e of(r.add(p),i[p.name]=1,p.getInterfaces())){var n;e.getFields()[a]&&(r.add(e),i[e.name]=(null!=(n=i[e.name])?n:0)+1)}return[...r].sort((t,a)=>{let r=i[a.name]-i[t.name];return 0!==r?r:Y(t)&&e.isSubType(t,a)?-1:Y(a)&&e.isSubType(a,t)?1:O(t.name,a.name)}).map(e=>e.name)}(n,a,p));""===o&&(o=_((r=a,i=p,q(r)||Y(r)?A(i,Object.keys(r.getFields())):[]))),e.reportError(new y.eO(`Cannot query field "${p}" on type "${a.name}".`+o,{nodes:t}))}}}}function tU(e){return{InlineFragment(t){let a=t.typeCondition;if(a){let t=tV(e.getSchema(),a);if(t&&!ed(t)){let t=(0,V.y)(a);e.reportError(new y.eO(`Fragment cannot condition on non composite type "${t}".`,{nodes:a}))}}},FragmentDefinition(t){let a=tV(e.getSchema(),t.typeCondition);if(a&&!ed(a)){let a=(0,V.y)(t.typeCondition);e.reportError(new y.eO(`Fragment "${t.name.value}" cannot condition on non composite type "${a}".`,{nodes:t.typeCondition}))}}}}function tB(e){return{...tq(e),Argument(t){let a=e.getArgument(),r=e.getFieldDef(),i=e.getParentType();if(!a&&r&&i){let a=t.name.value,n=A(a,r.args.map(e=>e.name));e.reportError(new y.eO(`Unknown argument "${a}" on field "${i.name}.${r.name}".`+_(n),{nodes:t}))}}}}function tq(e){let t=Object.create(null),a=e.getSchema();for(let e of a?a.getDirectives():ta)t[e.name]=e.args.map(e=>e.name);for(let a of e.getDocument().definitions)if(a.kind===R.b.DIRECTIVE_DEFINITION){var r;let e=null!=(r=a.arguments)?r:[];t[a.name.value]=e.map(e=>e.name.value)}return{Directive(a){let r=a.name.value,i=t[r];if(a.arguments&&i)for(let t of a.arguments){let a=t.name.value;if(!i.includes(a)){let n=A(a,i);e.reportError(new y.eO(`Unknown argument "${a}" on directive "@${r}".`+_(n),{nodes:t}))}}return!1}}}function tQ(e){let t=Object.create(null),a=e.getSchema();for(let e of a?a.getDirectives():ta)t[e.name]=e.locations;for(let a of e.getDocument().definitions)a.kind===R.b.DIRECTIVE_DEFINITION&&(t[a.name.value]=a.locations.map(e=>e.value));return{Directive(a,r,i,n,p){let o=a.name.value,s=t[o];if(!s)return void e.reportError(new y.eO(`Unknown directive "@${o}".`,{nodes:a}));let d=function(e){let t=e[e.length-1];switch("kind"in t||(0,ti.V)(!1),t.kind){case R.b.OPERATION_DEFINITION:var a=t.operation;switch(a){case g.cE.QUERY:return eG.H.QUERY;case g.cE.MUTATION:return eG.H.MUTATION;case g.cE.SUBSCRIPTION:return eG.H.SUBSCRIPTION}return;case R.b.FIELD:return eG.H.FIELD;case R.b.FRAGMENT_SPREAD:return eG.H.FRAGMENT_SPREAD;case R.b.INLINE_FRAGMENT:return eG.H.INLINE_FRAGMENT;case R.b.FRAGMENT_DEFINITION:return eG.H.FRAGMENT_DEFINITION;case R.b.VARIABLE_DEFINITION:return eG.H.VARIABLE_DEFINITION;case R.b.SCHEMA_DEFINITION:case R.b.SCHEMA_EXTENSION:return eG.H.SCHEMA;case R.b.SCALAR_TYPE_DEFINITION:case R.b.SCALAR_TYPE_EXTENSION:return eG.H.SCALAR;case R.b.OBJECT_TYPE_DEFINITION:case R.b.OBJECT_TYPE_EXTENSION:return eG.H.OBJECT;case R.b.FIELD_DEFINITION:return eG.H.FIELD_DEFINITION;case R.b.INTERFACE_TYPE_DEFINITION:case R.b.INTERFACE_TYPE_EXTENSION:return eG.H.INTERFACE;case R.b.UNION_TYPE_DEFINITION:case R.b.UNION_TYPE_EXTENSION:return eG.H.UNION;case R.b.ENUM_TYPE_DEFINITION:case R.b.ENUM_TYPE_EXTENSION:return eG.H.ENUM;case R.b.ENUM_VALUE_DEFINITION:return eG.H.ENUM_VALUE;case R.b.INPUT_OBJECT_TYPE_DEFINITION:case R.b.INPUT_OBJECT_TYPE_EXTENSION:return eG.H.INPUT_OBJECT;case R.b.INPUT_VALUE_DEFINITION:{let t=e[e.length-3];return"kind"in t||(0,ti.V)(!1),t.kind===R.b.INPUT_OBJECT_TYPE_DEFINITION?eG.H.INPUT_FIELD_DEFINITION:eG.H.ARGUMENT_DEFINITION}default:(0,ti.V)(!1,"Unexpected kind: "+(0,v.N)(t.kind))}}(p);d&&!s.includes(d)&&e.reportError(new y.eO(`Directive "@${o}" may not be used on ${d}.`,{nodes:a}))}}}function tY(e){return{FragmentSpread(t){let a=t.name.value;e.getFragment(a)||e.reportError(new y.eO(`Unknown fragment "${a}".`,{nodes:t.name}))}}}function tG(e){let t=e.getSchema(),a=t?t.getTypeMap():Object.create(null),r=Object.create(null);for(let t of e.getDocument().definitions)(0,tL.a6)(t)&&(r[t.name.value]=!0);let i=[...Object.keys(a),...Object.keys(r)];return{NamedType(t,n,p,o,s){let d=t.name.value;if(!a[d]&&!r[d]){var l,u;let a=null!=(l=s[2])?l:p,r=null!=a&&"kind"in(u=a)&&((0,tL.xu)(u)||(0,tL.fT)(u));if(r&&tz.includes(d))return;let n=A(d,r?tz.concat(i):i);e.reportError(new y.eO(`Unknown type "${d}".`+_(n),{nodes:t}))}}}}let tz=[...e1,...t_].map(e=>e.name);function tH(e){let t=0;return{Document(e){t=e.definitions.filter(e=>e.kind===R.b.OPERATION_DEFINITION).length},OperationDefinition(a){!a.name&&t>1&&e.reportError(new y.eO("This anonymous operation must be the only defined operation.",{nodes:a}))}}}function tW(e){var t,a,r;let i=e.getSchema(),n=null!=(t=null!=(a=null!=(r=null==i?void 0:i.astNode)?r:null==i?void 0:i.getQueryType())?a:null==i?void 0:i.getMutationType())?t:null==i?void 0:i.getSubscriptionType(),p=0;return{SchemaDefinition(t){n?e.reportError(new y.eO("Cannot define a new schema within a schema extension.",{nodes:t})):(p>0&&e.reportError(new y.eO("Must provide only one schema definition.",{nodes:t})),++p)}}}function tK(e){return{Field(t){if(("__schema"===t.name.value||"__type"===t.name.value)&&function t(a,r=Object.create(null),i=0){if(a.kind===R.b.FRAGMENT_SPREAD){let n=a.name.value;if(!0===r[n])return!1;let p=e.getFragment(n);if(!p)return!1;try{return r[n]=!0,t(p,r,i)}finally{r[n]=void 0}}if(a.kind===R.b.FIELD&&("fields"===a.name.value||"interfaces"===a.name.value||"possibleTypes"===a.name.value||"inputFields"===a.name.value)&&++i>=3)return!0;if("selectionSet"in a&&a.selectionSet){for(let e of a.selectionSet.selections)if(t(e,r,i))return!0}return!1}(t))return e.reportError(new y.eO("Maximum introspection depth exceeded",{nodes:[t]})),!1}}}function tJ(e){let t=Object.create(null),a=[],r=Object.create(null);return{OperationDefinition:()=>!1,FragmentDefinition:i=>((function i(n){if(t[n.name.value])return;let p=n.name.value;t[p]=!0;let o=e.getFragmentSpreads(n.selectionSet);if(0!==o.length){for(let t of(r[p]=a.length,o)){let n=t.name.value,p=r[n];if(a.push(t),void 0===p){let t=e.getFragment(n);t&&i(t)}else{let t=a.slice(p),r=t.slice(0,-1).map(e=>'"'+e.name.value+'"').join(", ");e.reportError(new y.eO(`Cannot spread fragment "${n}" within itself`+(""!==r?` via ${r}.`:"."),{nodes:t}))}a.pop()}r[p]=void 0}})(i),!1)}}function tZ(e){let t=Object.create(null);return{OperationDefinition:{enter(){t=Object.create(null)},leave(a){for(let{node:r}of e.getRecursiveVariableUsages(a)){let i=r.name.value;!0!==t[i]&&e.reportError(new y.eO(a.name?`Variable "$${i}" is not defined by operation "${a.name.value}".`:`Variable "$${i}" is not defined.`,{nodes:[r,a]}))}}},VariableDefinition(e){t[e.variable.name.value]=!0}}}function tX(e){let t=[],a=[];return{OperationDefinition:e=>(t.push(e),!1),FragmentDefinition:e=>(a.push(e),!1),Document:{leave(){let r=Object.create(null);for(let a of t)for(let t of e.getRecursivelyReferencedFragments(a))r[t.name.value]=!0;for(let t of a){let a=t.name.value;!0!==r[a]&&e.reportError(new y.eO(`Fragment "${a}" is never used.`,{nodes:t}))}}}}}function t1(e){let t=[];return{OperationDefinition:{enter(){t=[]},leave(a){let r=Object.create(null);for(let{node:t}of e.getRecursiveVariableUsages(a))r[t.name.value]=!0;for(let i of t){let t=i.variable.name.value;!0!==r[t]&&e.reportError(new y.eO(a.name?`Variable "$${t}" is never used in operation "${a.name.value}".`:`Variable "$${t}" is never used.`,{nodes:i}))}}},VariableDefinition(e){t.push(e)}}}function t0(e){switch(e.kind){case R.b.OBJECT:return{...e,fields:e.fields.map(e=>({...e,value:t0(e.value)})).sort((e,t)=>O(e.name.value,t.name.value))};case R.b.LIST:return{...e,values:e.values.map(t0)};case R.b.INT:case R.b.FLOAT:case R.b.STRING:case R.b.BOOLEAN:case R.b.NULL:case R.b.ENUM:case R.b.VARIABLE:return e}}function t2(e){let t=new t7,a=new ae,r=new Map;return{SelectionSet(i){for(let[[n,p],o,s]of function(e,t,a,r,i,n){let p=[],[o,s]=t5(e,t,i,n);if(function(e,t,a,r,i,n){for(let[p,o]of Object.entries(n))if(o.length>1)for(let n=0;n<o.length;n++)for(let s=n+1;s<o.length;s++){let d=t9(e,a,r,i,!1,p,o[n],o[s]);d&&t.push(d)}}(e,p,t,a,r,o),0!==s.length)for(let i=0;i<s.length;i++){t6(e,p,t,a,r,!1,o,s[i]);for(let n=i+1;n<s.length;n++)t4(e,p,t,a,r,!1,s[i],s[n])}return p}(e,r,t,a,e.getParentType(),i)){let t=function e(t){return Array.isArray(t)?t.map(([t,a])=>`subfields "${t}" conflict because `+e(a)).join(" and "):t}(p);e.reportError(new y.eO(`Fields "${n}" conflict because ${t}. Use different aliases on the fields to fetch both if this was intentional.`,{nodes:o.concat(s)}))}}}}function t6(e,t,a,r,i,n,p,o){if(r.has(p,o,n))return;r.add(p,o,n);let s=e.getFragment(o);if(!s)return;let[d,l]=t8(e,a,s);if(p!==d)for(let o of(t3(e,t,a,r,i,n,p,d),l))t6(e,t,a,r,i,n,p,o)}function t4(e,t,a,r,i,n,p,o){if(p===o||i.has(p,o,n))return;i.add(p,o,n);let s=e.getFragment(p),d=e.getFragment(o);if(!s||!d)return;let[l,u]=t8(e,a,s),[c,m]=t8(e,a,d);for(let o of(t3(e,t,a,r,i,n,l,c),m))t4(e,t,a,r,i,n,p,o);for(let p of u)t4(e,t,a,r,i,n,p,o)}function t3(e,t,a,r,i,n,p,o){for(let[s,d]of Object.entries(p)){let p=o[s];if(p)for(let o of d)for(let d of p){let p=t9(e,a,r,i,n,s,o,d);p&&t.push(p)}}}function t9(e,t,a,r,i,n,p,o){let[s,d,l]=p,[u,c,m]=o,f=i||s!==u&&q(s)&&q(u);if(!f){let e=d.name.value,t=c.name.value;if(e!==t)return[[n,`"${e}" and "${t}" are different fields`],[d],[c]];if(!function(e,t){let a=e.arguments,r=t.arguments;if(void 0===a||0===a.length)return void 0===r||0===r.length;if(void 0===r||0===r.length||a.length!==r.length)return!1;let i=new Map(r.map(({name:e,value:t})=>[e.value,t]));return a.every(e=>{let t=e.value,a=i.get(e.name.value);return void 0!==a&&function(e){return(0,V.y)(t0(e))}(t)===function(e){return(0,V.y)(t0(e))}(a)})}(d,c))return[[n,"they have differing arguments"],[d],[c]]}let h=null==l?void 0:l.type,y=null==m?void 0:m.type;if(h&&y&&function e(t,a){return X(t)?!X(a)||e(t.ofType,a.ofType):!!X(a)||(et(t)?!et(a)||e(t.ofType,a.ofType):!!et(a)||!!(eo(t)||eo(a))&&t!==a)}(h,y))return[[n,`they return conflicting types "${(0,v.N)(h)}" and "${(0,v.N)(y)}"`],[d],[c]];let g=d.selectionSet,_=c.selectionSet;if(g&&_){var b=function(e,t,a,r,i,n,p,o,s){let d=[],[l,u]=t5(e,t,n,p),[c,m]=t5(e,t,o,s);for(let n of(t3(e,d,t,a,r,i,l,c),m))t6(e,d,t,a,r,i,l,n);for(let n of u)t6(e,d,t,a,r,i,c,n);for(let n of u)for(let p of m)t4(e,d,t,a,r,i,n,p);return d}(e,t,a,r,f,eE(h),g,eE(y),_),w=n,E=d,T=c;return b.length>0?[[w,b.map(([e])=>e)],[E,...b.map(([,e])=>e).flat()],[T,...b.map(([,,e])=>e).flat()]]:void 0}}function t5(e,t,a,r){let i=t.get(r);if(i)return i;let n=Object.create(null),p=Object.create(null);!function e(t,a,r,i,n){for(let p of r.selections)switch(p.kind){case R.b.FIELD:{let e,t=p.name.value;(q(a)||Y(a))&&(e=a.getFields()[t]);let r=p.alias?p.alias.value:t;i[r]||(i[r]=[]),i[r].push([a,p,e]);break}case R.b.FRAGMENT_SPREAD:n[p.name.value]=!0;break;case R.b.INLINE_FRAGMENT:{let r=p.typeCondition,o=r?tV(t.getSchema(),r):a;e(t,o,p.selectionSet,i,n)}}}(e,a,r,n,p);let o=[n,Object.keys(p)];return t.set(r,o),o}function t8(e,t,a){let r=t.get(a.selectionSet);if(r)return r;let i=tV(e.getSchema(),a.typeCondition);return t5(e,t,i,a.selectionSet)}class t7{constructor(){this._data=new Map}has(e,t,a){var r;let i=null==(r=this._data.get(e))?void 0:r.get(t);return void 0!==i&&(!!a||a===i)}add(e,t,a){let r=this._data.get(e);void 0===r?this._data.set(e,new Map([[t,a]])):r.set(t,a)}}class ae{constructor(){this._orderedPairSet=new t7}has(e,t,a){return e<t?this._orderedPairSet.has(e,t,a):this._orderedPairSet.has(t,e,a)}add(e,t,a){e<t?this._orderedPairSet.add(e,t,a):this._orderedPairSet.add(t,e,a)}}function at(e){return{InlineFragment(t){let a=e.getType(),r=e.getParentType();if(ed(a)&&ed(r)&&!eY(e.getSchema(),a,r)){let i=(0,v.N)(r),n=(0,v.N)(a);e.reportError(new y.eO(`Fragment cannot be spread here as objects of type "${i}" can never be of type "${n}".`,{nodes:t}))}},FragmentSpread(t){let a=t.name.value,r=function(e,t){let a=e.getFragment(t);if(a){let t=tV(e.getSchema(),a.typeCondition);if(ed(t))return t}}(e,a),i=e.getParentType();if(r&&i&&!eY(e.getSchema(),r,i)){let n=(0,v.N)(i),p=(0,v.N)(r);e.reportError(new y.eO(`Fragment "${a}" cannot be spread here as objects of type "${n}" can never be of type "${p}".`,{nodes:t}))}}}}function aa(e){let t=e.getSchema(),a=Object.create(null);for(let t of e.getDocument().definitions)(0,tL.a6)(t)&&(a[t.name.value]=t);return{ScalarTypeExtension:r,ObjectTypeExtension:r,InterfaceTypeExtension:r,UnionTypeExtension:r,EnumTypeExtension:r,InputObjectTypeExtension:r};function r(r){var i;let n,p=r.name.value,o=a[p],s=null==t?void 0:t.getType(p);if(o?n=ar[o.kind]:s&&(n=U(i=s)?R.b.SCALAR_TYPE_EXTENSION:q(i)?R.b.OBJECT_TYPE_EXTENSION:Y(i)?R.b.INTERFACE_TYPE_EXTENSION:z(i)?R.b.UNION_TYPE_EXTENSION:W(i)?R.b.ENUM_TYPE_EXTENSION:J(i)?R.b.INPUT_OBJECT_TYPE_EXTENSION:void(0,ti.V)(!1,"Unexpected type: "+(0,v.N)(i))),n){if(n!==r.kind){let t=function(e){switch(e){case R.b.SCALAR_TYPE_EXTENSION:return"scalar";case R.b.OBJECT_TYPE_EXTENSION:return"object";case R.b.INTERFACE_TYPE_EXTENSION:return"interface";case R.b.UNION_TYPE_EXTENSION:return"union";case R.b.ENUM_TYPE_EXTENSION:return"enum";case R.b.INPUT_OBJECT_TYPE_EXTENSION:return"input object";default:(0,ti.V)(!1,"Unexpected kind: "+(0,v.N)(e))}}(r.kind);e.reportError(new y.eO(`Cannot extend non-${t} type "${p}".`,{nodes:o?[o,r]:r}))}}else{let i=A(p,Object.keys({...a,...null==t?void 0:t.getTypeMap()}));e.reportError(new y.eO(`Cannot extend type "${p}" because it is not defined.`+_(i),{nodes:r.name}))}}}let ar={[R.b.SCALAR_TYPE_DEFINITION]:R.b.SCALAR_TYPE_EXTENSION,[R.b.OBJECT_TYPE_DEFINITION]:R.b.OBJECT_TYPE_EXTENSION,[R.b.INTERFACE_TYPE_DEFINITION]:R.b.INTERFACE_TYPE_EXTENSION,[R.b.UNION_TYPE_DEFINITION]:R.b.UNION_TYPE_EXTENSION,[R.b.ENUM_TYPE_DEFINITION]:R.b.ENUM_TYPE_EXTENSION,[R.b.INPUT_OBJECT_TYPE_DEFINITION]:R.b.INPUT_OBJECT_TYPE_EXTENSION};function ai(e){return{...an(e),Field:{leave(t){var a;let r=e.getFieldDef();if(!r)return!1;let i=new Set(null==(a=t.arguments)?void 0:a.map(e=>e.name.value));for(let a of r.args)if(!i.has(a.name)&&eR(a)){let i=(0,v.N)(a.type);e.reportError(new y.eO(`Field "${r.name}" argument "${a.name}" of type "${i}" is required, but it was not provided.`,{nodes:t}))}}}}}function an(e){var t,a;let r=Object.create(null),i=e.getSchema();for(let e of null!=(t=null==i?void 0:i.getDirectives())?t:ta)r[e.name]=T(e.args.filter(eR),e=>e.name);for(let t of e.getDocument().definitions)if(t.kind===R.b.DIRECTIVE_DEFINITION){let e=null!=(a=t.arguments)?a:[];r[t.name.value]=T(e.filter(ap),e=>e.name.value)}return{Directive:{leave(t){let a=t.name.value,i=r[a];if(i){var n;let r=new Set((null!=(n=t.arguments)?n:[]).map(e=>e.name.value));for(let[n,p]of Object.entries(i))if(!r.has(n)){let r=j(p.type)?(0,v.N)(p.type):(0,V.y)(p.type);e.reportError(new y.eO(`Directive "@${a}" argument "${n}" of type "${r}" is required, but it was not provided.`,{nodes:t}))}}}}}}function ap(e){return e.type.kind===R.b.NON_NULL_TYPE&&null==e.defaultValue}function ao(e){return{Field(t){let a=e.getType(),r=t.selectionSet;if(a)if(eo(eE(a))){if(r){let i=t.name.value,n=(0,v.N)(a);e.reportError(new y.eO(`Field "${i}" must not have a selection since type "${n}" has no subfields.`,{nodes:r}))}}else if(r){if(0===r.selections.length){let r=t.name.value,i=(0,v.N)(a);e.reportError(new y.eO(`Field "${r}" of type "${i}" must have at least one field selected.`,{nodes:t}))}}else{let r=t.name.value,i=(0,v.N)(a);e.reportError(new y.eO(`Field "${r}" of type "${i}" must have a selection of subfields. Did you mean "${r} { ... }"?`,{nodes:t}))}}}}function as(e){return e.map(e=>"number"==typeof e?"["+e.toString()+"]":"."+e).join("")}function ad(e,t,a){return{prev:e,key:t,typename:a}}function al(e){let t=[],a=e;for(;a;)t.push(a.key),a=a.prev;return t.reverse()}function au(e,t,a=ac){return function e(t,a,r,i){if(et(a))return null!=t?e(t,a.ofType,r,i):void r(al(i),t,new y.eO(`Expected non-nullable type "${(0,v.N)(a)}" not to be null.`));if(null==t)return null;if(X(a)){let n=a.ofType;return tn(t)?Array.from(t,(t,a)=>e(t,n,r,ad(i,a,void 0))):[e(t,n,r,i)]}if(J(a)){if(!(0,E.Z)(t)||Array.isArray(t))return void r(al(i),t,new y.eO(`Expected type "${a.name}" to be an object.`));let n={},p=a.getFields();for(let o of Object.values(p)){let p=t[o.name];if(void 0===p){if(void 0!==o.defaultValue)n[o.name]=o.defaultValue;else if(et(o.type)){let e=(0,v.N)(o.type);r(al(i),t,new y.eO(`Field "${o.name}" of required type "${e}" was not provided.`))}continue}n[o.name]=e(p,o.type,r,ad(i,o.name,a.name))}for(let e of Object.keys(t))if(!p[e]){let n=A(e,Object.keys(a.getFields()));r(al(i),t,new y.eO(`Field "${e}" is not defined by type "${a.name}".`+_(n)))}if(a.isOneOf){let e=Object.keys(n);1!==e.length&&r(al(i),t,new y.eO(`Exactly one key must be specified for OneOf type "${a.name}".`));let p=e[0],o=n[p];null===o&&r(al(i).concat(p),o,new y.eO(`Field "${p}" must be non-null.`))}return n}if(eo(a)){let e;try{e=a.parseValue(t)}catch(e){e instanceof y.eO?r(al(i),t,e):r(al(i),t,new y.eO(`Expected type "${a.name}". `+e.message,{originalError:e}));return}return void 0===e&&r(al(i),t,new y.eO(`Expected type "${a.name}".`)),e}(0,ti.V)(!1,"Unexpected input type: "+(0,v.N)(a))}(e,t,a,void 0)}function ac(e,t,a){let r="Invalid value "+(0,v.N)(t);throw e.length>0&&(r+=` at "value${as(e)}"`),a.message=r+": "+a.message,a}function am(e,t,a){if(e){if(e.kind===R.b.VARIABLE){let r=e.name.value;if(null==a||void 0===a[r])return;let i=a[r];if(null===i&&et(t))return;return i}if(et(t)){if(e.kind===R.b.NULL)return;return am(e,t.ofType,a)}if(e.kind===R.b.NULL)return null;if(X(t)){let r=t.ofType;if(e.kind===R.b.LIST){let t=[];for(let i of e.values)if(af(i,a)){if(et(r))return;t.push(null)}else{let e=am(i,r,a);if(void 0===e)return;t.push(e)}return t}let i=am(e,r,a);if(void 0===i)return;return[i]}if(J(t)){if(e.kind!==R.b.OBJECT)return;let r=Object.create(null),i=T(e.fields,e=>e.name.value);for(let e of Object.values(t.getFields())){let t=i[e.name];if(!t||af(t.value,a)){if(void 0!==e.defaultValue)r[e.name]=e.defaultValue;else if(et(e.type))return;continue}let n=am(t.value,e.type,a);if(void 0===n)return;r[e.name]=n}if(t.isOneOf){let e=Object.keys(r);if(1!==e.length||null===r[e[0]])return}return r}if(eo(t)){let r;try{r=t.parseLiteral(e,a)}catch(e){return}if(void 0===r)return;return r}(0,ti.V)(!1,"Unexpected input type: "+(0,v.N)(t))}}function af(e,t){return e.kind===R.b.VARIABLE&&(null==t||void 0===t[e.name.value])}function ah(e,t,a,r){let i=[],n=null==r?void 0:r.maxErrors;try{let r=function(e,t,a,r){let i={};for(let n of t){let t=n.variable.name.value,p=tV(e,n.type);if(!er(p)){let e=(0,V.y)(n.type);r(new y.eO(`Variable "$${t}" expected value of type "${e}" which cannot be used as an input type.`,{nodes:n.type}));continue}if(!ag(a,t)){if(n.defaultValue)i[t]=am(n.defaultValue,p);else if(et(p)){let e=(0,v.N)(p);r(new y.eO(`Variable "$${t}" of required type "${e}" was not provided.`,{nodes:n}))}continue}let o=a[t];if(null===o&&et(p)){let e=(0,v.N)(p);r(new y.eO(`Variable "$${t}" of non-null type "${e}" must not be null.`,{nodes:n}));continue}i[t]=au(o,p,(e,a,i)=>{let p=`Variable "$${t}" got invalid value `+(0,v.N)(a);e.length>0&&(p+=` at "${t}${as(e)}"`),r(new y.eO(p+"; "+i.message,{nodes:n,originalError:i}))})}return i}(e,t,a,e=>{if(null!=n&&i.length>=n)throw new y.eO("Too many errors processing variables, error limit reached. Execution aborted.");i.push(e)});if(0===i.length)return{coerced:r}}catch(e){i.push(e)}return{errors:i}}function av(e,t,a){var r;let i={},n=T(null!=(r=t.arguments)?r:[],e=>e.name.value);for(let r of e.args){let e=r.name,p=r.type,o=n[e];if(!o){if(void 0!==r.defaultValue)i[e]=r.defaultValue;else if(et(p))throw new y.eO(`Argument "${e}" of required type "${(0,v.N)(p)}" was not provided.`,{nodes:t});continue}let s=o.value,d=s.kind===R.b.NULL;if(s.kind===R.b.VARIABLE){let t=s.name.value;if(null==a||!ag(a,t)){if(void 0!==r.defaultValue)i[e]=r.defaultValue;else if(et(p))throw new y.eO(`Argument "${e}" of required type "${(0,v.N)(p)}" was provided the variable "$${t}" which was not provided a runtime value.`,{nodes:s});continue}d=null==a[t]}if(d&&et(p))throw new y.eO(`Argument "${e}" of non-null type "${(0,v.N)(p)}" must not be null.`,{nodes:s});let l=am(s,p,a);if(void 0===l)throw new y.eO(`Argument "${e}" has invalid value ${(0,V.y)(s)}.`,{nodes:s});i[e]=l}return i}function ay(e,t,a){var r;let i=null==(r=t.directives)?void 0:r.find(t=>t.name.value===e.name);if(i)return av(e,i,a)}function ag(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function a_(e,t,a,r,i){let n=new Map;return ab(e,t,a,r,i,n,new Set),n}function ab(e,t,a,r,i,n,p){for(let s of i.selections)switch(s.kind){case R.b.FIELD:{var o;if(!aw(a,s))continue;let e=(o=s).alias?o.alias.value:o.name.value,t=n.get(e);void 0!==t?t.push(s):n.set(e,[s]);break}case R.b.INLINE_FRAGMENT:if(!aw(a,s)||!aE(e,s,r))continue;ab(e,t,a,r,s.selectionSet,n,p);break;case R.b.FRAGMENT_SPREAD:{let i=s.name.value;if(p.has(i)||!aw(a,s))continue;p.add(i);let o=t[i];if(!o||!aE(e,o,r))continue;ab(e,t,a,r,o.selectionSet,n,p)}}}function aw(e,t){let a=ay(e5,t,e);if((null==a?void 0:a.if)===!0)return!1;let r=ay(e9,t,e);return(null==r?void 0:r.if)!==!1}function aE(e,t,a){let r=t.typeCondition;if(!r)return!0;let i=tV(e,r);return i===a||!!eu(i)&&e.isSubType(i,a)}function aT(e){return{OperationDefinition(t){if("subscription"===t.operation){let a=e.getSchema(),r=a.getSubscriptionType();if(r){let i=t.name?t.name.value:null,n=Object.create(null),p=e.getDocument(),o=Object.create(null);for(let e of p.definitions)e.kind===R.b.FRAGMENT_DEFINITION&&(o[e.name.value]=e);let s=a_(a,o,n,r,t.selectionSet);if(s.size>1){let t=[...s.values()].slice(1).flat();e.reportError(new y.eO(null!=i?`Subscription "${i}" must select only one top level field.`:"Anonymous Subscription must select only one top level field.",{nodes:t}))}for(let t of s.values())t[0].name.value.startsWith("__")&&e.reportError(new y.eO(null!=i?`Subscription "${i}" must not select an introspection top level field.`:"Anonymous Subscription must not select an introspection top level field.",{nodes:t}))}}}}}function aN(e,t){let a=new Map;for(let r of e){let e=t(r),i=a.get(e);void 0===i?a.set(e,[r]):i.push(r)}return a}function aS(e){return{DirectiveDefinition(e){var t;let r=null!=(t=e.arguments)?t:[];return a(`@${e.name.value}`,r)},InterfaceTypeDefinition:t,InterfaceTypeExtension:t,ObjectTypeDefinition:t,ObjectTypeExtension:t};function t(e){var t,r;let i=e.name.value;for(let n of null!=(t=e.fields)?t:[]){let e=n.name.value;a(`${i}.${e}`,null!=(r=n.arguments)?r:[])}return!1}function a(t,a){for(let[r,i]of aN(a,e=>e.name.value))i.length>1&&e.reportError(new y.eO(`Argument "${t}(${r}:)" can only be defined once.`,{nodes:i.map(e=>e.name)}));return!1}}function aO(e){return{Field:t,Directive:t};function t(t){var a;for(let[r,i]of aN(null!=(a=t.arguments)?a:[],e=>e.name.value))i.length>1&&e.reportError(new y.eO(`There can be only one argument named "${r}".`,{nodes:i.map(e=>e.name)}))}}function aI(e){let t=Object.create(null),a=e.getSchema();return{DirectiveDefinition(r){let i=r.name.value;return null!=a&&a.getDirective(i)?void e.reportError(new y.eO(`Directive "@${i}" already exists in the schema. It cannot be redefined.`,{nodes:r.name})):(t[i]?e.reportError(new y.eO(`There can be only one directive named "@${i}".`,{nodes:[t[i],r.name]})):t[i]=r.name,!1)}}}function aD(e){let t=Object.create(null),a=e.getSchema();for(let e of a?a.getDirectives():ta)t[e.name]=!e.isRepeatable;for(let a of e.getDocument().definitions)a.kind===R.b.DIRECTIVE_DEFINITION&&(t[a.name.value]=!a.repeatable);let r=Object.create(null),i=Object.create(null);return{enter(a){let n;if("directives"in a&&a.directives){if(a.kind===R.b.SCHEMA_DEFINITION||a.kind===R.b.SCHEMA_EXTENSION)n=r;else if((0,tL.a6)(a)||(0,tL.i7)(a)){let e=a.name.value;void 0===(n=i[e])&&(i[e]=n=Object.create(null))}else n=Object.create(null);for(let r of a.directives){let a=r.name.value;t[a]&&(n[a]?e.reportError(new y.eO(`The directive "@${a}" can only be used once at this location.`,{nodes:[n[a],r]})):n[a]=r)}}}}}function aA(e){let t=e.getSchema(),a=t?t.getTypeMap():Object.create(null),r=Object.create(null);return{EnumTypeDefinition:i,EnumTypeExtension:i};function i(t){var i;let n=t.name.value;r[n]||(r[n]=Object.create(null));let p=null!=(i=t.values)?i:[],o=r[n];for(let t of p){let r=t.name.value,i=a[n];W(i)&&i.getValue(r)?e.reportError(new y.eO(`Enum value "${n}.${r}" already exists in the schema. It cannot also be defined in this type extension.`,{nodes:t.name})):o[r]?e.reportError(new y.eO(`Enum value "${n}.${r}" can only be defined once.`,{nodes:[o[r],t.name]})):o[r]=t.name}return!1}}function ak(e){let t=e.getSchema(),a=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(t){var i,n,p;let o=t.name.value;r[o]||(r[o]=Object.create(null));let s=null!=(i=t.fields)?i:[],d=r[o];for(let t of s){let r=t.name.value;(n=a[o],p=r,(q(n)||Y(n)||J(n))&&null!=n.getFields()[p])?e.reportError(new y.eO(`Field "${o}.${r}" already exists in the schema. It cannot also be defined in this type extension.`,{nodes:t.name})):d[r]?e.reportError(new y.eO(`Field "${o}.${r}" can only be defined once.`,{nodes:[d[r],t.name]})):d[r]=t.name}return!1}}function ax(e){let t=Object.create(null);return{OperationDefinition:()=>!1,FragmentDefinition(a){let r=a.name.value;return t[r]?e.reportError(new y.eO(`There can be only one fragment named "${r}".`,{nodes:[t[r],a.name]})):t[r]=a.name,!1}}}function aC(e){let t=[],a=Object.create(null);return{ObjectValue:{enter(){t.push(a),a=Object.create(null)},leave(){let e=t.pop();e||(0,ti.V)(!1),a=e}},ObjectField(t){let r=t.name.value;a[r]?e.reportError(new y.eO(`There can be only one input field named "${r}".`,{nodes:[a[r],t.name]})):a[r]=t.name}}}function aR(e){let t=Object.create(null);return{OperationDefinition(a){let r=a.name;return r&&(t[r.value]?e.reportError(new y.eO(`There can be only one operation named "${r.value}".`,{nodes:[t[r.value],r]})):t[r.value]=r),!1},FragmentDefinition:()=>!1}}function aV(e){let t=e.getSchema(),a=Object.create(null),r=t?{query:t.getQueryType(),mutation:t.getMutationType(),subscription:t.getSubscriptionType()}:{};return{SchemaDefinition:i,SchemaExtension:i};function i(t){var i;for(let n of null!=(i=t.operationTypes)?i:[]){let t=n.operation,i=a[t];r[t]?e.reportError(new y.eO(`Type for ${t} already defined in the schema. It cannot be redefined.`,{nodes:n})):i?e.reportError(new y.eO(`There can be only one ${t} type in schema.`,{nodes:[i,n]})):a[t]=n}return!1}}function aF(e){let t=Object.create(null),a=e.getSchema();return{ScalarTypeDefinition:r,ObjectTypeDefinition:r,InterfaceTypeDefinition:r,UnionTypeDefinition:r,EnumTypeDefinition:r,InputObjectTypeDefinition:r};function r(r){let i=r.name.value;return null!=a&&a.getType(i)?void e.reportError(new y.eO(`Type "${i}" already exists in the schema. It cannot also be defined in this type definition.`,{nodes:r.name})):(t[i]?e.reportError(new y.eO(`There can be only one type named "${i}".`,{nodes:[t[i],r.name]})):t[i]=r.name,!1)}}function a$(e){return{OperationDefinition(t){var a;for(let[r,i]of aN(null!=(a=t.variableDefinitions)?a:[],e=>e.variable.name.value))i.length>1&&e.reportError(new y.eO(`There can be only one variable named "$${r}".`,{nodes:i.map(e=>e.variable.name)}))}}}function aP(e){let t={};return{OperationDefinition:{enter(){t={}}},VariableDefinition(e){t[e.variable.name.value]=e},ListValue(t){if(!X(e_(e.getParentInputType())))return aL(e,t),!1},ObjectValue(t){let a=eE(e.getInputType());if(!J(a))return aL(e,t),!1;let r=T(t.fields,e=>e.name.value);for(let i of Object.values(a.getFields()))if(!r[i.name]&&eB(i)){let r=(0,v.N)(i.type);e.reportError(new y.eO(`Field "${a.name}.${i.name}" of required type "${r}" was not provided.`,{nodes:t}))}a.isOneOf&&function(e,t,a,r){var i;let n=Object.keys(r);if(1!==n.length)return e.reportError(new y.eO(`OneOf Input Object "${a.name}" must specify exactly one key.`,{nodes:[t]}));let p=null==(i=r[n[0]])?void 0:i.value;p&&p.kind!==R.b.NULL||e.reportError(new y.eO(`Field "${a.name}.${n[0]}" must be non-null.`,{nodes:[t]}))}(e,t,a,r)},ObjectField(t){let a=eE(e.getParentInputType());if(!e.getInputType()&&J(a)){let r=A(t.name.value,Object.keys(a.getFields()));e.reportError(new y.eO(`Field "${t.name.value}" is not defined by type "${a.name}".`+_(r),{nodes:t}))}},NullValue(t){let a=e.getInputType();et(a)&&e.reportError(new y.eO(`Expected value of type "${(0,v.N)(a)}", found ${(0,V.y)(t)}.`,{nodes:t}))},EnumValue:t=>aL(e,t),IntValue:t=>aL(e,t),FloatValue:t=>aL(e,t),StringValue:t=>aL(e,t),BooleanValue:t=>aL(e,t)}}function aL(e,t){let a=e.getInputType();if(!a)return;let r=eE(a);if(!eo(r)){let r=(0,v.N)(a);e.reportError(new y.eO(`Expected value of type "${r}", found ${(0,V.y)(t)}.`,{nodes:t}));return}try{let i=r.parseLiteral(t,void 0);if(void 0===i){let r=(0,v.N)(a);e.reportError(new y.eO(`Expected value of type "${r}", found ${(0,V.y)(t)}.`,{nodes:t}))}}catch(i){let r=(0,v.N)(a);i instanceof y.eO?e.reportError(i):e.reportError(new y.eO(`Expected value of type "${r}", found ${(0,V.y)(t)}; `+i.message,{nodes:t,originalError:i}))}}function aj(e){return{VariableDefinition(t){let a=tV(e.getSchema(),t.type);if(void 0!==a&&!er(a)){let a=t.variable.name.value,r=(0,V.y)(t.type);e.reportError(new y.eO(`Variable "$${a}" cannot be non-input type "${r}".`,{nodes:t.type}))}}}}function aM(e){let t=Object.create(null);return{OperationDefinition:{enter(){t=Object.create(null)},leave(a){for(let{node:s,type:d,defaultValue:l,parentType:u}of e.getRecursiveVariableUsages(a)){let a=s.name.value,c=t[a];if(c&&d){var r,i,n,p,o;let t=e.getSchema(),m=tV(t,c.type);if(m&&(r=t,i=m,n=c.defaultValue,p=d,o=l,et(p)&&!et(i)?!((null!=n&&n.kind!==R.b.NULL||void 0!==o)&&eQ(r,i,p.ofType)):!eQ(r,i,p))){let t=(0,v.N)(m),r=(0,v.N)(d);e.reportError(new y.eO(`Variable "$${a}" of type "${t}" used in position expecting type "${r}".`,{nodes:[c,s]}))}J(u)&&u.isOneOf&&ey(m)&&e.reportError(new y.eO(`Variable "$${a}" is of type "${m}" but must be non-nullable to be used for OneOf Input Object "${u}".`,{nodes:[c,s]}))}}}},VariableDefinition(e){t[e.variable.name.value]=e}}}let aU=Object.freeze([tK]),aB=Object.freeze([tj,aR,tH,aT,tG,tU,aj,ao,tM,ax,tY,tX,at,tJ,a$,tZ,t1,tQ,aD,tB,aO,aP,ai,aM,t2,aC,...aU]),aq=Object.freeze([tW,aV,aF,aA,ak,aS,aI,tG,tQ,aD,aa,tq,aO,aC,an]);class aQ{constructor(e,t){this._ast=e,this._fragments=void 0,this._fragmentSpreads=new Map,this._recursivelyReferencedFragments=new Map,this._onError=t}get[Symbol.toStringTag](){return"ASTValidationContext"}reportError(e){this._onError(e)}getDocument(){return this._ast}getFragment(e){let t;if(this._fragments)t=this._fragments;else{for(let e of(t=Object.create(null),this.getDocument().definitions))e.kind===R.b.FRAGMENT_DEFINITION&&(t[e.name.value]=e);this._fragments=t}return t[e]}getFragmentSpreads(e){let t=this._fragmentSpreads.get(e);if(!t){let a;t=[];let r=[e];for(;a=r.pop();)for(let e of a.selections)e.kind===R.b.FRAGMENT_SPREAD?t.push(e):e.selectionSet&&r.push(e.selectionSet);this._fragmentSpreads.set(e,t)}return t}getRecursivelyReferencedFragments(e){let t=this._recursivelyReferencedFragments.get(e);if(!t){let a;t=[];let r=Object.create(null),i=[e.selectionSet];for(;a=i.pop();)for(let e of this.getFragmentSpreads(a)){let a=e.name.value;if(!0!==r[a]){r[a]=!0;let e=this.getFragment(a);e&&(t.push(e),i.push(e.selectionSet))}}this._recursivelyReferencedFragments.set(e,t)}return t}}class aY extends aQ{constructor(e,t,a){super(e,a),this._schema=t}get[Symbol.toStringTag](){return"SDLValidationContext"}getSchema(){return this._schema}}class aG extends aQ{constructor(e,t,a,r){super(t,r),this._schema=e,this._typeInfo=a,this._variableUsages=new Map,this._recursiveVariableUsages=new Map}get[Symbol.toStringTag](){return"ValidationContext"}getSchema(){return this._schema}getVariableUsages(e){let t=this._variableUsages.get(e);if(!t){let a=[],r=new tF(this._schema);(0,tR.YR)(e,tP(r,{VariableDefinition:()=>!1,Variable(e){a.push({node:e,type:r.getInputType(),defaultValue:r.getDefaultValue(),parentType:r.getParentInputType()})}})),t=a,this._variableUsages.set(e,t)}return t}getRecursiveVariableUsages(e){let t=this._recursiveVariableUsages.get(e);if(!t){for(let a of(t=this.getVariableUsages(e),this.getRecursivelyReferencedFragments(e)))t=t.concat(this.getVariableUsages(a));this._recursiveVariableUsages.set(e,t)}return t}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()}}function az(e,t,a=aB,r,i=new tF(e)){var n;let p=null!=(n=null==r?void 0:r.maxErrors)?n:100;t||(0,m.U)(!1,"Must provide document."),tO(e);let o=Object.freeze({}),s=[],d=new aG(e,t,i,e=>{if(s.length>=p)throw s.push(new y.eO("Too many validation errors, error limit reached. Validation aborted.")),o;s.push(e)}),l=(0,tR.oP)(a.map(e=>e(d)));try{(0,tR.YR)(t,tP(i,l))}catch(e){if(e!==o)throw e}return s}function aH(e,t,a=aq){let r=[],i=new aY(e,t,e=>{r.push(e)}),n=a.map(e=>e(i));return(0,tR.YR)(e,(0,tR.oP)(n)),r}function aW(e){return Promise.all(Object.values(e)).then(t=>{let a=Object.create(null);for(let[r,i]of Object.keys(e).entries())a[i]=t[r];return a})}class aK extends Error{constructor(e){super("Unexpected error value: "+(0,v.N)(e)),this.name="NonErrorThrown",this.thrownValue=e}}function aJ(e,t,a){var r;let i=e instanceof Error?e:new aK(e);return Array.isArray(i.path)?i:new y.eO(i.message,{nodes:null!=(r=i.nodes)?r:t,source:i.source,positions:i.positions,path:a,originalError:i})}let aZ=(o=(e,t,a)=>(function(e,t,a,r,i){let n=new Map,p=new Set;for(let o of i)o.selectionSet&&ab(e,t,a,r,o.selectionSet,n,p);return n})(e.schema,e.fragments,e.variableValues,t,a),function(e,t,a){void 0===r&&(r=new WeakMap);let i=r.get(e);void 0===i&&(i=new WeakMap,r.set(e,i));let n=i.get(t);void 0===n&&(n=new WeakMap,i.set(t,n));let p=n.get(a);return void 0===p&&(p=o(e,t,a),n.set(a,p)),p});function aX(e){arguments.length<2||(0,m.U)(!1,"graphql@16 dropped long-deprecated support for positional arguments, please pass an object instead.");let{schema:t,document:a,variableValues:r,rootValue:i}=e;a2(t,a,r);let n=a6(e);if(!("schema"in n))return{errors:n};try{let{operation:e}=n,t=function(e,t,a){let r=e.schema.getRootType(t.operation);if(null==r)throw new y.eO(`Schema is not configured to execute ${t.operation} operation.`,{nodes:t});let i=a_(e.schema,e.fragments,e.variableValues,r,t.selectionSet),n;switch(t.operation){case g.cE.QUERY:return a4(e,r,a,n,i);case g.cE.MUTATION:var p,o,s,d,l;return p=e,o=r,s=a,d=n,l=i,function(e,t,a){let r=a;for(let a of e)r=f(r)?r.then(e=>t(e,a)):t(r,a);return r}(l.entries(),(e,[t,a])=>{let r=ad(d,t,o.name),i=a3(p,o,s,a,r);return void 0===i?e:f(i)?i.then(a=>(e[t]=a,e)):(e[t]=i,e)},Object.create(null));case g.cE.SUBSCRIPTION:return a4(e,r,a,n,i)}}(n,e,i);if(f(t))return t.then(e=>a0(e,n.errors),e=>(n.errors.push(e),a0(null,n.errors)));return a0(t,n.errors)}catch(e){return n.errors.push(e),a0(null,n.errors)}}function a1(e){let t=aX(e);if(f(t))throw Error("GraphQL execution failed to complete synchronously.");return t}function a0(e,t){return 0===t.length?{data:e}:{errors:t,data:e}}function a2(e,t,a){t||(0,m.U)(!1,"Must provide document."),tO(e),null==a||(0,E.Z)(a)||(0,m.U)(!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 a6(e){var t,a,r;let i,{schema:n,document:p,rootValue:o,contextValue:s,variableValues:d,operationName:l,fieldResolver:u,typeResolver:c,subscribeFieldResolver:m,options:f}=e,h=Object.create(null);for(let e of p.definitions)switch(e.kind){case R.b.OPERATION_DEFINITION:if(null==l){if(void 0!==i)return[new y.eO("Must provide operation name if query contains multiple operations.")];i=e}else(null==(t=e.name)?void 0:t.value)===l&&(i=e);break;case R.b.FRAGMENT_DEFINITION:h[e.name.value]=e}if(!i)return null!=l?[new y.eO(`Unknown operation named "${l}".`)]:[new y.eO("Must provide an operation.")];let v=ah(n,null!=(a=i.variableDefinitions)?a:[],null!=d?d:{},{maxErrors:null!=(r=null==f?void 0:f.maxCoercionErrors)?r:50});return v.errors?v.errors:{schema:n,fragments:h,rootValue:o,contextValue:s,operation:i,variableValues:v.coerced,fieldResolver:null!=u?u:rr,typeResolver:null!=c?c:ra,subscribeFieldResolver:null!=m?m:rr,errors:[]}}function a4(e,t,a,r,i){let n=Object.create(null),p=!1;try{for(let[o,s]of i.entries()){let i=ad(r,o,t.name),d=a3(e,t,a,s,i);void 0!==d&&(n[o]=d,f(d)&&(p=!0))}}catch(e){if(p)return aW(n).finally(()=>{throw e});throw e}return p?aW(n):n}function a3(e,t,a,r,i){var n;let p=ri(e.schema,t,r[0]);if(!p)return;let o=p.type,s=null!=(n=p.resolve)?n:e.fieldResolver,d=a9(e,p,r,t,i);try{let t,n=av(p,r[0],e.variableValues),l=e.contextValue,u=s(a,n,l,d);if(t=f(u)?u.then(t=>a8(e,o,r,d,i,t)):a8(e,o,r,d,i,u),f(t))return t.then(void 0,t=>{let a=aJ(t,r,al(i));return a5(a,o,e)});return t}catch(t){return a5(aJ(t,r,al(i)),o,e)}}function a9(e,t,a,r,i){return{fieldName:t.name,fieldNodes:a,returnType:t.type,parentType:r,path:i,schema:e.schema,fragments:e.fragments,rootValue:e.rootValue,operation:e.operation,variableValues:e.variableValues}}function a5(e,t,a){if(et(t))throw e;return a.errors.push(e),null}function a8(e,t,a,r,i,n){var p,o,s,d,l,u,c;let m;if(n instanceof Error)throw n;if(et(t)){let p=a8(e,t.ofType,a,r,i,n);if(null===p)throw Error(`Cannot return null for non-nullable field ${r.parentType.name}.${r.fieldName}.`);return p}return null==n?null:X(t)?function(e,t,a,r,i,n){if(!tn(n))throw new y.eO(`Expected Iterable, but did not find one for field "${r.parentType.name}.${r.fieldName}".`);let p=t.ofType,o=!1,s=Array.from(n,(t,n)=>{let s=ad(i,n,void 0);try{let i;if(i=f(t)?t.then(t=>a8(e,p,a,r,s,t)):a8(e,p,a,r,s,t),f(i))return o=!0,i.then(void 0,t=>{let r=aJ(t,a,al(s));return a5(r,p,e)});return i}catch(t){return a5(aJ(t,a,al(s)),p,e)}});return o?Promise.all(s):s}(e,t,a,r,i,n):eo(t)?function(e,t){let a=e.serialize(t);if(null==a)throw Error(`Expected \`${(0,v.N)(e)}.serialize(${(0,v.N)(t)})\` to return non-nullable value, returned: ${(0,v.N)(a)}`);return a}(t,n):eu(t)?(p=e,o=t,s=a,d=r,l=i,u=n,f(m=(null!=(c=o.resolveType)?c:p.typeResolver)(u,p.contextValue,d,o))?m.then(e=>re(p,a7(e,p,o,s,d,u),s,d,l,u)):re(p,a7(m,p,o,s,d,u),s,d,l,u)):q(t)?re(e,t,a,r,i,n):void(0,ti.V)(!1,"Cannot complete value of unexpected output type: "+(0,v.N)(t))}function a7(e,t,a,r,i,n){if(null==e)throw new y.eO(`Abstract type "${a.name}" must resolve to an Object type at runtime for field "${i.parentType.name}.${i.fieldName}". Either the "${a.name}" type should provide a "resolveType" function or each possible type should provide an "isTypeOf" function.`,r);if(q(e))throw new y.eO("Support for returning GraphQLObjectType from resolveType was removed in graphql-js@16.0.0 please return type name instead.");if("string"!=typeof e)throw new y.eO(`Abstract type "${a.name}" must resolve to an Object type at runtime for field "${i.parentType.name}.${i.fieldName}" with value ${(0,v.N)(n)}, received "${(0,v.N)(e)}".`);let p=t.schema.getType(e);if(null==p)throw new y.eO(`Abstract type "${a.name}" was resolved to a type "${e}" that does not exist inside the schema.`,{nodes:r});if(!q(p))throw new y.eO(`Abstract type "${a.name}" was resolved to a non-object type "${e}".`,{nodes:r});if(!t.schema.isSubType(a,p))throw new y.eO(`Runtime Object type "${p.name}" is not a possible type for "${a.name}".`,{nodes:r});return p}function re(e,t,a,r,i,n){let p=aZ(e,t,a);if(t.isTypeOf){let o=t.isTypeOf(n,e.contextValue,r);if(f(o))return o.then(r=>{if(!r)throw rt(t,n,a);return a4(e,t,n,i,p)});if(!o)throw rt(t,n,a)}return a4(e,t,n,i,p)}function rt(e,t,a){return new y.eO(`Expected value of type "${e.name}" but got: ${(0,v.N)(t)}.`,{nodes:a})}let ra=function(e,t,a,r){if((0,E.Z)(e)&&"string"==typeof e.__typename)return e.__typename;let i=a.schema.getPossibleTypes(r),n=[];for(let r=0;r<i.length;r++){let p=i[r];if(p.isTypeOf){let i=p.isTypeOf(e,t,a);if(f(i))n[r]=i;else if(i)return n.length&&Promise.allSettled(n).catch(()=>{}),p.name}}if(n.length)return Promise.all(n).then(e=>{for(let t=0;t<e.length;t++)if(e[t])return i[t].name})},rr=function(e,t,a,r){if((0,E.Z)(e)||"function"==typeof e){let i=e[r.fieldName];return"function"==typeof i?e[r.fieldName](t,a,r):i}};function ri(e,t,a){let r=a.name.value;return r===tv.name&&e.getQueryType()===t?tv:r===ty.name&&e.getQueryType()===t?ty:r===tg.name?tg:t.getFields()[r]}function rn(e){return new Promise(t=>t(ro(e)))}function rp(e){let t=ro(e);if(f(t))throw Error("GraphQL execution failed to complete synchronously.");return t}function ro(e){let t;arguments.length<2||(0,m.U)(!1,"graphql@16 dropped long-deprecated support for positional arguments, please pass an object instead.");let{schema:a,source:r,rootValue:i,contextValue:n,variableValues:p,operationName:o,fieldResolver:s,typeResolver:d}=e,l=tS(a);if(l.length>0)return{errors:l};try{t=(0,h.qg)(r)}catch(e){return{errors:[e]}}let u=az(a,t);return u.length>0?{errors:u}:aX({schema:a,document:t,rootValue:i,contextValue:n,variableValues:p,operationName:o,fieldResolver:s,typeResolver:d})}var rs=a(39537),rd=a(73971),rl=a(8238),ru=a(98472),rc=a(12039);function rm(e){return"function"==typeof(null==e?void 0:e[Symbol.asyncIterator])}async function rf(e){arguments.length<2||(0,m.U)(!1,"graphql@16 dropped long-deprecated support for positional arguments, please pass an object instead.");let t=await rh(e);if(!rm(t))return t;let a=t[Symbol.asyncIterator]();async function r(t){if(t.done)return t;try{let a;return{value:await (a=t.value,aX({...e,rootValue:a})),done:!1}}catch(e){if("function"==typeof a.return)try{await a.return()}catch(e){}throw e}}return{next:async()=>r(await a.next()),return:async()=>"function"==typeof a.return?r(await a.return()):{value:void 0,done:!0},async throw(e){if("function"==typeof a.throw)return r(await a.throw(e));throw e},[Symbol.asyncIterator](){return this}}}async function rh(...e){let t,a=(t=e[0])&&"document"in t?t:{schema:t,document:e[1],rootValue:e[2],contextValue:e[3],variableValues:e[4],operationName:e[5],subscribeFieldResolver:e[6]},{schema:r,document:i,variableValues:n}=a;a2(r,i,n);let p=a6(a);if(!("schema"in p))return{errors:p};try{let e=await rv(p);if(!rm(e))throw Error(`Subscription field must return Async Iterable. Received: ${(0,v.N)(e)}.`);return e}catch(e){if(e instanceof y.eO)return{errors:[e]};throw e}}async function rv(e){let{schema:t,fragments:a,operation:r,variableValues:i,rootValue:n}=e,p=t.getSubscriptionType();if(null==p)throw new y.eO("Schema is not configured to execute subscription operation.",{nodes:r});let[o,s]=[...a_(t,a,i,p,r.selectionSet).entries()][0],d=ri(t,p,s[0]);if(!d){let e=s[0].name.value;throw new y.eO(`The subscription field "${e}" is not defined.`,{nodes:s})}let l=ad(void 0,o,p.name),u=a9(e,d,s,p,l);try{var c;let t=av(d,s[0],i),a=e.contextValue,r=null!=(c=d.subscribe)?c:e.subscribeFieldResolver,p=await r(n,t,a,u);if(p instanceof Error)throw p;return p}catch(e){throw aJ(e,s,al(l))}}function ry(e){return{Field(t){let a=e.getFieldDef(),r=null==a?void 0:a.deprecationReason;if(a&&null!=r){let i=e.getParentType();null!=i||(0,ti.V)(!1),e.reportError(new y.eO(`The field ${i.name}.${a.name} is deprecated. ${r}`,{nodes:t}))}},Argument(t){let a=e.getArgument(),r=null==a?void 0:a.deprecationReason;if(a&&null!=r){let i=e.getDirective();if(null!=i)e.reportError(new y.eO(`Directive "@${i.name}" argument "${a.name}" is deprecated. ${r}`,{nodes:t}));else{let i=e.getParentType(),n=e.getFieldDef();null!=i&&null!=n||(0,ti.V)(!1),e.reportError(new y.eO(`Field "${i.name}.${n.name}" argument "${a.name}" is deprecated. ${r}`,{nodes:t}))}}},ObjectField(t){let a=eE(e.getParentInputType());if(J(a)){let r=a.getFields()[t.name.value],i=null==r?void 0:r.deprecationReason;null!=i&&e.reportError(new y.eO(`The input field ${a.name}.${r.name} is deprecated. ${i}`,{nodes:t}))}},EnumValue(t){let a=e.getEnumValue(),r=null==a?void 0:a.deprecationReason;if(a&&null!=r){let i=eE(e.getInputType());null!=i||(0,ti.V)(!1),e.reportError(new y.eO(`The enum value "${i.name}.${a.name}" is deprecated. ${r}`,{nodes:t}))}}}}function rg(e){return{Field(t){let a=eE(e.getType());a&&tb(a)&&e.reportError(new y.eO(`GraphQL introspection has been disabled, but the requested query contained the field "${t.name.value}".`,{nodes:t}))}}}var r_=a(59841);function rb(e){let t={descriptions:!0,specifiedByUrl:!1,directiveIsRepeatable:!1,schemaDescription:!1,inputValueDeprecation:!1,oneOf:!1,...e},a=t.descriptions?"description":"",r=t.specifiedByUrl?"specifiedByURL":"",i=t.directiveIsRepeatable?"isRepeatable":"",n=t.schemaDescription?a:"";function p(e){return t.inputValueDeprecation?e:""}let o=t.oneOf?"isOneOf":"";return`
|
|
1478
1478
|
query IntrospectionQuery {
|
|
1479
1479
|
__schema {
|
|
1480
1480
|
${n}
|