PageSourceSearch

https://dashboard.m1.com/assets/apollo-CaoVZJxQ.js

js m1.com collected 2026-09-24 09:00:41 UTC 185,797 bytes, 49 lines download raw bytes

vendor: 8,221 bytes, line 1
1(function(){try{var e=typeof window<`u`?window:typeof global<`u`?global:typeof globalThis<`u`?globalThis:typeof self<`u`?self:{};e.SENTRY_RELEASE={id:`10.0.294`},e._sentryModuleMetadata=e._sentryModuleMetadata||{},e._sentryModuleMetadata[new e.Error().stack]=function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];if(n!=null)for(var r in n)n.hasOwnProperty(r)&&(e[r]=n[r])}return e}({},e._sentryModuleMetadata[new e.Error().stack],{"_sentryBundlerPluginAppKey:m1-web":!0});var t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]=`4bf67896-34f5-4d6f-aad8-627e72a97998`,e._sentryDebugIdIdentifier=`sentry-dbid-4bf67896-34f5-4d6f-aad8-627e72a97998`)}catch{}})();import{o as e,t}from"./rolldown-runtime-8uEnS_M4.js";var n=t((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.consumer`),s=Symbol.for(`react.context`),c=Symbol.for(`react.forward_ref`),l=Symbol.for(`react.suspense`),u=Symbol.for(`react.memo`),d=Symbol.for(`react.lazy`),f=Symbol.for(`react.activity`),p=Symbol.iterator;function m(e){return typeof e!=`object`||!e?null:(e=p&&e[p]||e[`@@iterator`],typeof e==`function`?e:null)}var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,_={};function v(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){if(typeof e!=`object`&&typeof e!=`function`&&e!=null)throw Error(`takes an object of state variables to update or a function which returns an object of state variables.`);this.updater.enqueueSetState(this,e,t,`setState`)},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,`forceUpdate`)};function y(){}y.prototype=v.prototype;function b(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}var ee=b.prototype=new y;ee.constructor=b,g(ee,v.prototype),ee.isPureReactComponent=!0;var te=Array.isArray;function ne(){}var x={H:null,A:null,T:null,S:null},re=Object.prototype.hasOwnProperty;function ie(e,n,r){var i=r.ref;return{$$typeof:t,type:e,key:n,ref:i===void 0?null:i,props:r}}function ae(e,t){return ie(e.type,t,e.props)}function oe(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function se(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var S=/\/+/g;function ce(e,t){return typeof e==`object`&&e&&e.key!=null?se(``+e.key):t.toString(36)}function C(e){switch(e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason;default:switch(typeof e.status==`string`?e.then(ne,ne):(e.status=`pending`,e.then(function(t){e.status===`pending`&&(e.status=`fulfilled`,e.value=t)},function(t){e.status===`pending`&&(e.status=`rejected`,e.reason=t)})),e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason}}throw e}function le(e,r,i,a,o){var s=typeof e;(s===`undefined`||s===`boolean`)&&(e=null);var c=!1;if(e===null)c=!0;else switch(s){case`bigint`:case`string`:case`number`:c=!0;break;case`object`:switch(e.$$typeof){case t:case n:c=!0;break;case d:return c=e._init,le(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+ce(e,0):a,te(o)?(i=``,c!=null&&(i=c.replace(S,`$&/`)+`/`),le(o,r,i,``,function(e){return e})):o!=null&&(oe(o)&&(o=ae(o,i+(o.key==null||e&&e.key===o.key?``:(``+o.key).replace(S,`$&/`)+`/`)+c)),r.push(o)),1;c=0;var l=a===``?`.`:a+`:`;if(te(e))for(var u=0;u<e.length;u++)a=e[u],s=l+ce(a,u),c+=le(a,r,i,s,o);else if(u=m(e),typeof u==`function`)for(e=u.call(e),u=0;!(a=e.next()).done;)a=a.value,s=l+ce(a,u++),c+=le(a,r,i,s,o);else if(s===`object`){if(typeof e.then==`function`)return le(C(e),r,i,a,o);throw r=String(e),Error(`Objects are not valid as a React child (found: `+(r===`[object Object]`?`object with keys {`+Object.keys(e).join(`, `)+`}`:r)+`). If you meant to render a collection of children, use an array instead.`)}return c}function ue(e,t,n){if(e==null)return e;var r=[],i=0;return le(e,r,``,``,function(e){return t.call(n,e,i++)}),r}function de(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(t){(e._status===0||e._status===-1)&&(e._status=1,e._result=t)},function(t){(e._status===0||e._status===-1)&&(e._status=2,e._result=t)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var fe=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},pe={map:ue,forEach:function(e,t,n){ue(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return ue(e,function(){t++}),t},toArray:function(e){return ue(e,function(e){return e})||[]},only:function(e){if(!oe(e))throw Error(`React.Children.only expected to receive a single React element child.`);return e}};e.Activity=f,e.Children=pe,e.Component=v,e.Fragment=r,e.Profiler=a,e.PureComponent=b,e.StrictMode=i,e.Suspense=l,e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=x,e.__COMPILER_RUNTIME={__proto__:null,c:function(e){return x.H.useMemoCache(e)}},e.cache=function(e){return function(){return e.apply(null,arguments)}},e.cacheSignal=function(){return null},e.cloneElement=function(e,t,n){if(e==null)throw Error(`The argument must be a React element, but you passed `+e+`.`);var r=g({},e.props),i=e.key;if(t!=null)for(a in t.key!==void 0&&(i=``+t.key),t)!re.call(t,a)||a===`key`||a===`__self`||a===`__source`||a===`ref`&&t.ref===void 0||(r[a]=t[a]);var a=arguments.length-2;if(a===1)r.children=n;else if(1<a){for(var o=Array(a),s=0;s<a;s++)o[s]=arguments[s+2];r.children=o}return ie(e.type,i,r)},e.createContext=function(e){return e={$$typeof:s,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:o,_context:e},e},e.createElement=function(e,t,n){var r,i={},a=null;if(t!=null)for(r in t.key!==void 0&&(a=``+t.key),t)re.call(t,r)&&r!==`key`&&r!==`__self`&&r!==`__source`&&(i[r]=t[r]);var o=arguments.length-2;if(o===1)i.children=n;else if(1<o){for(var s=Array(o),c=0;c<o;c++)s[c]=arguments[c+2];i.children=s}if(e&&e.defaultProps)for(r in o=e.defaultProps,o)i[r]===void 0&&(i[r]=o[r]);return ie(e,a,i)},e.createRef=function(){return{current:null}},e.forwardRef=function(e){return{$$typeof:c,render:e}},e.isValidElement=oe,e.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:de}},e.memo=function(e,t){return{$$typeof:u,type:e,compare:t===void 0?null:t}},e.startTransition=function(e){var t=x.T,n={};x.T=n;try{var r=e(),i=x.S;i!==null&&i(n,r),typeof r==`object`&&r&&typeof r.then==`function`&&r.then(ne,fe)}catch(e){fe(e)}finally{t!==null&&n.types!==null&&(t.types=n.types),x.T=t}},e.unstable_useCacheRefresh=function(){return x.H.useCacheRefresh()},e.use=function(e){return x.H.use(e)},e.useActionState=function(e,t,n){return x.H.useActionState(e,t,n)},e.useCallback=function(e,t){return x.H.useCallback(e,t)},e.useContext=function(e){return x.H.useContext(e)},e.useDebugValue=function(){},e.useDeferredValue=function(e,t){return x.H.useDeferredValue(e,t)},e.useEffect=function(e,t){return x.H.useEffect(e,t)},e.useEffectEvent=function(e){return x.H.useEffectEvent(e)},e.useId=function(){return x.H.useId()},e.useImperativeHandle=function(e,t,n){return x.H.useImperativeHandle(e,t,n)},e.useInsertionEffect=function(e,t){return x.H.useInsertionEffect(e,t)},e.useLayoutEffect=function(e,t){return x.H.useLayoutEffect(e,t)},e.useMemo=function(e,t){return x.H.useMemo(e,t)},e.useOptimistic=function(e,t){return x.H.useOptimistic(e,t)},e.useReducer=function(e,t,n){return x.H.useReducer(e,t,n)},e.useRef=function(e){return x.H.useRef(e)},e.useState=function(e){return x.H.useState(e)},e.useSyncExternalStore=function(e,t,n){return x.H.useSyncExternalStore(e,t,n)},e.useTransition=function(){return x.H.useTransition()}
1,e.version=`19.2.8`})),r=t(((e,t)=>{t.exports=n()})),i=e(r(),1);function a(e,t){return typeof e==`object`&&!!e&&e[Symbol.for(`apollo.error`)]===t}function o(e){Object.defineProperty(e,Symbol.for(`apollo.error`),{value:e.name,enumerable:!1,writable:!1,configurable:!1})}function s(e){return e.map(e=>e.message||`Error message not found.`).join(`
2`)}var c=class e extends Error{static is(e){return a(e,`CombinedProtocolErrors`)}static formatMessage=s;errors;constructor(t){super(e.formatMessage(t,{defaultFormatMessage:s})),this.name=`CombinedProtocolErrors`,this.errors=t,o(this),Object.setPrototypeOf(this,e.prototype)}};function l(e){return typeof e==`object`&&!!e&&typeof e.message==`string`&&typeof e.name==`string`&&(typeof e.stack==`string`||e.stack===void 0)}var u=class e extends Error{static is(e){return a(e,`UnconventionalError`)}constructor(t){super(`An error of unexpected shape occurred.`,{cause:t}),this.name=`UnconventionalError`,o(this),Object.setPrototypeOf(this,e.prototype)}};function d(e){return e.filter(e=>e).map(e=>e.message||`Error message not found.`).join(`
3`)}var f=class e extends Error{static is(e){return a(e,`CombinedGraphQLErrors`)}static formatMessage=d;errors;data;extensions;constructor(t,n=t.errors||[]){super(e.formatMessage(n,{result:t,defaultFormatMessage:d})),this.errors=n,this.data=t.data,this.extensions=t.extensions,this.name=`CombinedGraphQLErrors`,o(this),Object.setPrototypeOf(this,e.prototype)}},p=new WeakSet;function m(e){p.add(e)}var h=class e extends Error{static is(e){return a(e,`ServerError`)}response;statusCode;bodyText;constructor(t,n){super(t),this.name=`ServerError`,this.response=n.response,this.statusCode=n.response.status,this.bodyText=n.bodyText,o(this),Object.setPrototypeOf(this,e.prototype)}},g=class e extends Error{static is(e){return a(e,`ServerParseError`)}response;statusCode;bodyText;constructor(t,n){super(t instanceof Error?t.message:`Could not parse server response`,{cause:t}),this.name=`ServerParseError`,this.response=n.response,this.statusCode=n.response.status,this.bodyText=n.bodyText,o(this),Object.setPrototypeOf(this,e.prototype)}},_=Symbol();function v(e){return`extensions`in e&&c.is(e.extensions[_])}function y(e){return l(e)?e:typeof e==`string`?Error(e,{cause:e}):new u(e)}function b(e){try{return e()}catch{}}var ee=b(()=>globalThis)||b(()=>window)||b(()=>self)||b(()=>global)||b(function(){return b.constructor(`return this`)()}),te=`4.3.1`,ne=new Map;function x(e){let t=ne.get(e)||1;return ne.set(e,t+1),`${e}:${t}:${Math.random().toString(36).slice(2)}`}function re(e,t=0){let n=x(`stringifyForDisplay`);return JSON.stringify(e,(e,t)=>t===void 0?n:t,t).split(JSON.stringify(n)).join(`<undefined>`)}var ie=`Invariant Violation`,ae=class e extends Error{constructor(t=ie){super(t),this.name=ie,Object.setPrototypeOf(this,e.prototype)}},oe=[`debug`,`log`,`warn`,`error`,`silent`],se=oe.indexOf(`silent`);function S(e,...t){if(!e)throw C(...t)}function ce(e){return function(t,...n){if(oe.indexOf(e)>=se){let r=console[e]||console.log;if(typeof t==`number`){let e=t;t=de(e),t||(t=fe(e,n),n=[])}r(t,...n)}}}S.debug=ce(`debug`),S.log=ce(`log`),S.warn=ce(`warn`),S.error=ce(`error`);function C(e,...t){return new ae(de(e,t)||fe(e,t))}var le=Symbol.for(`ApolloErrorMessageHandler_`+te);function ue(e){if(typeof e==`string`)return e;try{return re(e,2).slice(0,1e3)}catch{return`<non-serializable>`}}function de(e,t=[]){if(e)return ee[le]&&ee[le](e,t.map(ue))}function fe(e,t=[]){if(e)return typeof e==`string`?t.reduce((e,t)=>e.replace(/%[sdfo]/,ue(t)),e):`An error occurred! For more details, see the full error text at https://go.apollo.dev/c/err#${encodeURIComponent(JSON.stringify({version:te,message:e,args:t.map(ue)}))}`}var pe=Symbol.for(`__APOLLO_CONTEXT__`);function me(){S(`createContext`in i,39);let e=i.createContext[pe];return e||(Object.defineProperty(i.createContext,pe,{value:e=i.createContext({}),enumerable:!1,writable:!1,configurable:!0}),e.displayName=`ApolloContext`),e}var he=({client:e,children:t})=>{let n=me(),r=i.useContext(n),a=i.useMemo(()=>({...r,client:e||r.client}),[r,e]);return S(a.client,40),i.createElement(n.Provider,{value:a},t)};function ge(e){let t=i.useContext(me()),n=e||t.client;return S(!!n,30),n}var{toString:_e,hasOwnProperty:ve}=Object.prototype,ye=Function.prototype.toString,be=new Map;function w(e,t){try{return xe(e,t)}finally{be.clear()}}function xe(e,t){if(e===t)return!0;let n=_e.call(e);
3if(n!==_e.call(t))return!1;switch(n){case`[object Array]`:if(e.length!==t.length)return!1;case`[object Object]`:{if(Ee(e,t))return!0;let n=Se(e),r=Se(t),i=n.length;if(i!==r.length)return!1;for(let e=0;e<i;++e)if(!ve.call(t,n[e]))return!1;for(let r=0;r<i;++r){let i=n[r];if(!xe(e[i],t[i]))return!1}return!0}case`[object Error]`:return e.name===t.name&&e.message===t.message;case`[object Number]`:if(e!==e)return t!==t;case`[object Boolean]`:case`[object Date]`:return+e==+t;case`[object RegExp]`:case`[object String]`:return e==`${t}`;case`[object Map]`:case`[object Set]`:{if(e.size!==t.size)return!1;if(Ee(e,t))return!0;let r=e.entries(),i=n===`[object Map]`;for(;;){let e=r.next();if(e.done)break;let[n,a]=e.value;if(!t.has(n)||i&&!xe(a,t.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]`:e=new Uint8Array(e),t=new Uint8Array(t);case`[object DataView]`:{let n=e.byteLength;if(n===t.byteLength)for(;n--&&e[n]===t[n];);return n===-1}case`[object AsyncFunction]`:case`[object GeneratorFunction]`:case`[object AsyncGeneratorFunction]`:case`[object Function]`:{let n=ye.call(e);return n===ye.call(t)&&!Te(n,we)}}return!1}function Se(e){return Object.keys(e).filter(Ce,e)}function Ce(e){return this[e]!==void 0}var we=`{ [native code] }`;function Te(e,t){let n=e.length-t.length;return n>=0&&e.indexOf(t,n)===n}function Ee(e,t){let n=be.get(e);if(n){if(n.has(t))return!0}else be.set(e,n=new Set);return n.add(t),!1}function De(e,t){if(!e)throw Error(t)}function Oe(e){return typeof e==`object`&&!!e}function ke(e,t){if(!e)throw Error(t??`Unexpected invariant triggered.`)}var Ae=/\r\n|[\n\r]/g;function je(e,t){let n=0,r=1;for(let i of e.body.matchAll(Ae)){if(typeof i.index==`number`||ke(!1),i.index>=t)break;n=i.index+i[0].length,r+=1}return{line:r,column:t+1-n}}function Me(e){return Ne(e.source,je(e.source,e.start))}function Ne(e,t){let n=e.locationOffset.column-1,r=``.padStart(n)+e.body,i=t.line-1,a=e.locationOffset.line-1,o=t.line+a,s=t.line===1?n:0,c=t.column+s,l=`${e.name}:${o}:${c}\n`,u=r.split(/\r\n|[\n\r]/g),d=u[i];if(d.length>120){let e=Math.floor(c/80),t=c%80,n=[];for(let e=0;e<d.length;e+=80)n.push(d.slice(e,e+80));return l+Pe([[`${o} |`,n[0]],...n.slice(1,e+1).map(e=>[`|`,e]),[`|`,`^`.padStart(t)],[`|`,n[e+1]]])}return l+Pe([[`${o-1} |`,u[i-1]],[`${o} |`,d],[`|`,`^`.padStart(c)],[`${o+1} |`,u[i+1]]])}function Pe(e){let t=e.filter(([e,t])=>t!==void 0),n=Math.max(...t.map(([e])=>e.length));return t.map(([e,t])=>e.padStart(n)+(t?` `+t:``)).join(`
4`)}function Fe(e){let t=e[0];return t==null||`kind`in t||`length`in t?{nodes:t,source:e[1],positions:e[2],path:e[3],originalError:e[4],extensions:e[5]}:t}var Ie=class e extends Error{constructor(t,...n){let{nodes:r,source:i,positions:a,path:o,originalError:s,extensions:c}=Fe(n);super(t),this.name=`GraphQLError`,this.path=o??void 0,this.originalError=s??void 0,this.nodes=Le(Array.isArray(r)?r:r?[r]:void 0);let l=Le(this.nodes?.map(e=>e.loc).filter(e=>e!=null));this.source=i??l?.[0]?.source,this.positions=a??l?.map(e=>e.start),this.locations=a&&i?a.map(e=>je(i,e)):l?.map(e=>je(e.source,e.start));let u=Oe(s?.extensions)?s?.extensions:void 0;this.extensions=c??u??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}}),s!=null&&s.stack?Object.defineProperty(this,"stack",{value:s.stack,writable:!0,configurable:!0}):Error.captureStackTrace?Error.captureStackTrace(this,e):Object.defineProperty(this,"stack",{value:Error().stack,writable:!0,configurable:!0})}get[Symbol.toStringTag](){return`GraphQLError`}toString(){let e=this.message;if(this.nodes)for(let t of this.nodes)t.loc&&(e+=`
5
6`+Me(t.loc));else if(this.source&&this.locations)for(let t of this.locations)e+=`
7
8`+Ne(this.source,t);return e}toJSON(){let e={message:this.message};return this.locations!=null&&(e.locations=this.locations),this.path!=null&&(e.path=this.path),this.extensions!=null&&Object.keys(this.extensions).length>0&&(e.extensions=this.extensions),e}};function Le(e){return e===void 0||e.length===0?void 0:e}var Re={Name:[],Document:[`definitions`],OperationDefinition:[`description`,`name`,`variableDefinitions`,`directives`,`selectionSet`],
8VariableDefinition:[`description`,`variable`,`type`,`defaultValue`,`directives`],Variable:[`name`],SelectionSet:[`selections`],Field:[`alias`,`name`,`arguments`,`directives`,`selectionSet`],Argument:[`name`,`value`],FragmentSpread:[`name`,`directives`],InlineFragment:[`typeCondition`,`directives`,`selectionSet`],FragmentDefinition:[`description`,`name`,`variableDefinitions`,`typeCondition`,`directives`,`selectionSet`],IntValue:[],FloatValue:[],StringValue:[],BooleanValue:[],NullValue:[],EnumValue:[],ListValue:[`values`],ObjectValue:[`fields`],ObjectField:[`name`,`value`],Directive:[`name`,`arguments`],NamedType:[`name`],ListType:[`type`],NonNullType:[`type`],SchemaDefinition:[`description`,`directives`,`operationTypes`],OperationTypeDefinition:[`type`],ScalarTypeDefinition:[`description`,`name`,`directives`],ObjectTypeDefinition:[`description`,`name`,`interfaces`,`directives`,`fields`],FieldDefinition:[`description`,`name`,`arguments`,`type`,`directives`],InputValueDefinition:[`description`,`name`,`type`,`defaultValue`,`directives`],InterfaceTypeDefinition:[`description`,`name`,`interfaces`,`directives`,`fields`],UnionTypeDefinition:[`description`,`name`,`directives`,`types`],EnumTypeDefinition:[`description`,`name`,`directives`,`values`],EnumValueDefinition:[`description`,`name`,`directives`],InputObjectTypeDefinition:[`description`,`name`,`directives`,`fields`],DirectiveDefinition:[`description`,`name`,`arguments`,`directives`,`locations`],SchemaExtension:[`directives`,`operationTypes`],DirectiveExtension:[`name`,`directives`],ScalarTypeExtension:[`name`,`directives`],ObjectTypeExtension:[`name`,`interfaces`,`directives`,`fields`],InterfaceTypeExtension:[`name`,`interfaces`,`directives`,`fields`],UnionTypeExtension:[`name`,`directives`,`types`],EnumTypeExtension:[`name`,`directives`,`values`],InputObjectTypeExtension:[`name`,`directives`,`fields`],TypeCoordinate:[`name`],MemberCoordinate:[`name`,`memberName`],ArgumentCoordinate:[`name`,`fieldName`,`argumentName`],DirectiveCoordinate:[`name`],DirectiveArgumentCoordinate:[`name`,`argumentName`]},ze=new Set(Object.keys(Re));function Be(e){let t=e?.kind;return typeof t==`string`&&ze.has(t)}var Ve;(function(e){e.QUERY=`query`,e.MUTATION=`mutation`,e.SUBSCRIPTION=`subscription`})(Ve||={});var T;(function(e){e.NAME=`Name`,e.DOCUMENT=`Document`,e.OPERATION_DEFINITION=`OperationDefinition`,e.VARIABLE_DEFINITION=`VariableDefinition`,e.SELECTION_SET=`SelectionSet`,e.FIELD=`Field`,e.ARGUMENT=`Argument`,e.FRAGMENT_SPREAD=`FragmentSpread`,e.INLINE_FRAGMENT=`InlineFragment`,e.FRAGMENT_DEFINITION=`FragmentDefinition`,e.VARIABLE=`Variable`,e.INT=`IntValue`,e.FLOAT=`FloatValue`,e.STRING=`StringValue`,e.BOOLEAN=`BooleanValue`,e.NULL=`NullValue`,e.ENUM=`EnumValue`,e.LIST=`ListValue`,e.OBJECT=`ObjectValue`,e.OBJECT_FIELD=`ObjectField`,e.DIRECTIVE=`Directive`,e.NAMED_TYPE=`NamedType`,e.LIST_TYPE=`ListType`,e.NON_NULL_TYPE=`NonNullType`,e.SCHEMA_DEFINITION=`SchemaDefinition`,e.OPERATION_TYPE_DEFINITION=`OperationTypeDefinition`,e.SCALAR_TYPE_DEFINITION=`ScalarTypeDefinition`,e.OBJECT_TYPE_DEFINITION=`ObjectTypeDefinition`,e.FIELD_DEFINITION=`FieldDefinition`,e.INPUT_VALUE_DEFINITION=`InputValueDefinition`,e.INTERFACE_TYPE_DEFINITION=`InterfaceTypeDefinition`,e.UNION_TYPE_DEFINITION=`UnionTypeDefinition`,e.ENUM_TYPE_DEFINITION=`EnumTypeDefinition`,e.ENUM_VALUE_DEFINITION=`EnumValueDefinition`,e.INPUT_OBJECT_TYPE_DEFINITION=`InputObjectTypeDefinition`,e.DIRECTIVE_DEFINITION=`DirectiveDefinition`,e.SCHEMA_EXTENSION=`SchemaExtension`,e.DIRECTIVE_EXTENSION=`DirectiveExtension`,e.SCALAR_TYPE_EXTENSION=`ScalarTypeExtension`,e.OBJECT_TYPE_EXTENSION=`ObjectTypeExtension`,e.INTERFACE_TYPE_EXTENSION=`InterfaceTypeExtension`,e.UNION_TYPE_EXTENSION=`UnionTypeExtension`,e.ENUM_TYPE_EXTENSION=`EnumTypeExtension`,e.INPUT_OBJECT_TYPE_EXTENSION=`InputObjectTypeExtension`,e.TYPE_COORDINATE=`TypeCoordinate`,e.MEMBER_COORDINATE=`MemberCoordinate`,e.ARGUMENT_COORDINATE=`ArgumentCoordinate`,e.DIRECTIVE_COORDINATE=`DirectiveCoordinate`,e.DIRECTIVE_ARGUMENT_COORDINATE=`DirectiveArgumentCoordinate`})(T||={});function He(e){return e===9||e===32}function Ue(e,t){let n=e.replace(/"""/g,`\\"""`),r=n.split(/\r\n|[\n\r]/g),i=r.length===1,a=r.length>1&&r.slice(1).every(e=>e.length===0||He(e.charCodeAt(0))),o=n.endsWith(`\\"""`),s=e.endsWith(`"`)&&!o,c=e.endsWith(`\\`),l=s||c,u=!(t!=null&&t.minimize)&&(!i||e.length>70||l||a||o),d=``,f=i&&He(e.charCodeAt(0));return(u&&!f||a)&&(d+=`
9`),d+=n,(u||l)&&(d+=`
10`),`"""`+d+`"""`}var We=10,Ge=2;function Ke(e){return qe(e,[])}function qe(e,t){switch(typeof e){case`string`:return JSON.stringify(e);case`function`:return e.name?`[function ${e.name}]`:`[function]`;case`object`:return Je(e,t);default:return String(e)}}function Je(e,t){if(e===null)return`null`;if(t.includes(e))return`[Circular]`;let n=[...t,e];if(Ye(e)){let t=e.toJSON();if(t!==e)return typeof t==`string`?t:qe(t,n)}else if(Array.isArray(e))return Ze(e,n);return Xe(e,n)}function Ye(e){return typeof e.toJSON==`function`}function Xe(e,t){let n=Object.entries(e);return n.length===0?`{}`:t.length>Ge?`[`+Qe(e)+`]`:`{ `+n.map(([e,n])=>e+`: `+qe(n,t)).join(`, `)+` }`}function Ze(e,t){if(e.length===0)return`[]`;if(t.length>Ge)return`[Array]`;let n=Math.min(We,e.length),r=e.length-n,i=[];for(let r=0;r<n;++r)i.push(qe(e[r],t));
10return r===1?i.push(`... 1 more item`):r>1&&i.push(`... ${r} more items`),`[`+i.join(`, `)+`]`}function Qe(e){let t=Object.prototype.toString.call(e).replace(/^\[object /,``).replace(/]$/,``);if(t===`Object`&&typeof e.constructor==`function`){let t=e.constructor.name;if(typeof t==`string`&&t!==``)return t}return t}function $e(e){return`"${e.replace(et,tt)}"`}var et=/[\x00-\x1f\x22\x5c\x7f-\x9f]/g;function tt(e){return nt[e.charCodeAt(0)]}var nt=`\\u0000.\\u0001.\\u0002.\\u0003.\\u0004.\\u0005.\\u0006.\\u0007.\\b.\\t.\\n.\\u000B.\\f.\\r.\\u000E.\\u000F.\\u0010.\\u0011.\\u0012.\\u0013.\\u0014.\\u0015.\\u0016.\\u0017.\\u0018.\\u0019.\\u001A.\\u001B.\\u001C.\\u001D.\\u001E.\\u001F...\\"..........................................................\\\\...................................\\u007F.\\u0080.\\u0081.\\u0082.\\u0083.\\u0084.\\u0085.\\u0086.\\u0087.\\u0088.\\u0089.\\u008A.\\u008B.\\u008C.\\u008D.\\u008E.\\u008F.\\u0090.\\u0091.\\u0092.\\u0093.\\u0094.\\u0095.\\u0096.\\u0097.\\u0098.\\u0099.\\u009A.\\u009B.\\u009C.\\u009D.\\u009E.\\u009F`.split(`.`),rt=Object.freeze({});function E(e,t,n=Re){let r=new Map;for(let e of Object.values(T))r.set(e,it(t,e));let i,a=Array.isArray(e),o=[e],s=-1,c=[],l=e,u,d,f=[],p=[];do{s++;let e=s===o.length,m=e&&c.length!==0;if(e){if(u=p.length===0?void 0:f[f.length-1],l=d,d=p.pop(),m){if(a){l=l.slice();let e=0;for(let[t,n]of c){let r=t-e;n===null?(l.splice(r,1),e++):l[r]=n}}else{l={...l};for(let[e,t]of c)l[e]=t}}s=i.index,o=i.keys,c=i.edits,a=i.inArray,i=i.prev}else if(d){if(u=a?s:o[s],l=d[u],l==null)continue;f.push(u)}let h;if(!Array.isArray(l)){if(Be(l)||De(!1,`Invalid AST Node: ${Ke(l)}.`),h=(e?r.get(l.kind)?.leave:r.get(l.kind)?.enter)?.call(t,l,u,d,f,p),h===rt)break;if(h===!1){if(!e){f.pop();continue}}else if(h!==void 0&&(c.push([u,h]),!e)){if(Be(h))l=h;else{f.pop();continue}}}h===void 0&&m&&c.push([u,l]),e?f.pop():(i={inArray:a,index:s,keys:o,edits:c,prev:i},a=Array.isArray(l),o=a?l:n[l.kind]??[],s=-1,c=[],d&&p.push(d),d=l)}while(i!==void 0);return c.length===0?e:c[c.length-1][1]}function it(e,t){let n=e[t];return typeof n==`object`?n:typeof n==`function`?{enter:n,leave:void 0}:{enter:e.enter,leave:e.leave}}function at(e){return E(e,st)}var ot=80,st={Name:{leave:e=>e.value},Variable:{leave:e=>`$`+e.name},Document:{leave:e=>D(e.definitions,`
11
12`)},OperationDefinition:{leave(e){let t=lt(e.variableDefinitions)?k(`(
13`,D(e.variableDefinitions,`
14`),`
15)`):k(`(`,D(e.variableDefinitions,`, `),`)`),n=k(``,e.description,`
16`)+D([e.operation,D([e.name,t]),D(e.directives,` `)],` `);return(n===`query`?``:n+` `)+e.selectionSet}},VariableDefinition:{leave:({variable:e,type:t,defaultValue:n,directives:r,description:i})=>k(``,i,`
17`)+e+`: `+t+k(` = `,n)+k(` `,D(r,` `))},SelectionSet:{leave:({selections:e})=>O(e)},Field:{leave({alias:e,name:t,arguments:n,directives:r,selectionSet:i}){let a=k(``,e,`: `)+t,o=a+k(`(`,D(n,`, `),`)`);return o.length>ot&&(o=a+k(`(
18`,ct(D(n,`
19`)),`
20)`)),D([o,D(r,` `),i],` `)}},Argument:{leave:({name:e,value:t})=>e+`: `+t},FragmentSpread:{leave:({name:e,directives:t})=>`...`+e+k(` `,D(t,` `))},InlineFragment:{leave:({typeCondition:e,directives:t,selectionSet:n})=>D([`...`,k(`on `,e),D(t,` `),n],` `)},FragmentDefinition:{leave:({name:e,typeCondition:t,variableDefinitions:n,directives:r,selectionSet:i,description:a})=>k(``,a,`
21`)+`fragment ${e}${k(`(`,D(n,`, `),`)`)} on ${t} ${k(``,D(r,` `),` `)}`+i},IntValue:{leave:({value:e})=>e},FloatValue:{leave:({value:e})=>e},StringValue:{leave:({value:e,block:t})=>t?Ue(e):$e(e)},BooleanValue:{leave:({value:e})=>e?`true`:`false`},NullValue:{leave:()=>`null`},EnumValue:{leave:({value:e})=>e},ListValue:{leave:({values:e})=>`[`+D(e,`, `)+`]`},ObjectValue:{leave:({fields:e})=>`{`+D(e,`, `)+`}`},ObjectField:{leave:({name:e,value:t})=>e+`: `+t},Directive:{leave:({name:e,arguments:t})=>`@`+e+k(`(`,D(t,`, `),`)`)},NamedType:{leave:({name:e})=>e},ListType:{leave:({type:e})=>`[`+e+`]`},NonNullType:{leave:({type:e})=>e+`!`},SchemaDefinition:{leave:({description:e,directives:t,operationTypes:n})=>k(``,e,`
22`)+D([`schema`,D(t,` `),O(n)],` `)},OperationTypeDefinition:{leave:({operation:e,type:t})=>e+`: `+t},ScalarTypeDefinition:{leave:({description:e,name:t,directives:n})=>k(``,e,`
23`)+D([`scalar`,t,D(n,` `)],` `)},ObjectTypeDefinition:{leave:({description:e,name:t,interfaces:n,directives:r,fields:i})=>k(``,e,`
24`)+D([`type`,t,k(`implements `,D(n,` & `)),D(r,` `),O(i)],` `)},FieldDefinition:{leave:({description:e,name:t,arguments:n,type:r,directives:i})=>k(``,e,`
25`)+t+(lt(n)?k(`(
26`,ct(D(n,`
27`)),`
28)`):k(`(`,D(n,`, `),`)`))+`: `+r+k(` `,D(i,` `))},InputValueDefinition:{leave:({description:e,name:t,type:n,defaultValue:r,directives:i})=>k(``,e,`
29`)+D([t+`: `+n,k(`= `,r),D(i,` `)],` `)},InterfaceTypeDefinition:{leave:({description:e,name:t,interfaces:n,directives:r,fields:i})=>k(``,e,`
30`)+D([`interface`,t,k(`implements `,D(n,` & `)),D(r,` `),O(i)],` `)},UnionTypeDefinition:{leave:({description:e,name:t,directives:n,types:r})=>k(``,e,`
31`)+D([`union`,t,D(n,` `),k(`= `,D(r,` | `))],` `)},EnumTypeDefinition:{leave:({description:e,name:t,directives:n,values:r})=>k(``,e,`
32`)+D([`enum`,t,D(n,` `),O(r)],` `)},EnumValueDefinition:{leave:({description:e,name:t,directives:n})=>k(``,e,`
33`)+D([t,D(n,` `)],` `)},InputObjectTypeDefinition:{leave:({description:e,name:t,directives:n,fields:r})=>k(``,e,`
34`)+D([`input`,t,D(n,` `),O(r)],` `)},DirectiveDefinition:{leave:({description:e,name:t,arguments:n,directives:r,repeatable:i,locations:a})=>k(``,e,`
35`)+`directive @`+t+(lt(n)?k(`(
36`,ct(D(n,`
37`)),`
38)`):k(`(`,D(n,`, `),`)`))+k(` `,D(r,` `))+(i?` repeatable`:``)+` on `+D(a,` | `)},SchemaExtension:{leave:({directives:e,operationTypes:t})=>D([`extend schema`,D(e,` `),O(t)],` `)},ScalarTypeExtension:{leave:({name:e,directives:t})=>D([`extend scalar`,e,D(t,` `)],` `)},ObjectTypeExtension:{leave:({name:e,interfaces:t,directives:n,fields:r})=>D([`extend type`,e,k(`implements `,D(t,` & `)),D(n,` `),O(r)],` `)},InterfaceTypeExtension:{leave:({name:e,interfaces:t,directives:n,fields:r})=>D([`extend interface`,e,k(`implements `,D(t,` & `)),D(n,` `),O(r)],` `)},UnionTypeExtension:{leave:({name:e,directives:t,types:n})=>D([`extend union`,e,D(t,` `),k(`= `,D(n,` | `))],` `)},EnumTypeExtension:{leave:({name:e,directives:t,values:n})=>D([`extend enum`,e,D(t,` `),O(n)],` `)},InputObjectTypeExtension:{leave:({name:e,directives:t,fields:n})=>D([`extend input`,e,D(t,` `),O(n)],` `)},DirectiveExtension:{leave:({name:e,directives:t})=>D([`extend directive @`+e,D(t,` `)],` `)},TypeCoordinate:{leave:({name:e})=>e},MemberCoordinate:{leave:({name:e,memberName:t})=>D([e,k(`.`,t)])},ArgumentCoordinate:{leave:({name:e,fieldName:t,argumentName:n})=>D([e,k(`.`,t),k(`(`,n,`:)`)])},DirectiveCoordinate:{leave:({name:e})=>D([`@`,e])},DirectiveArgumentCoordinate:{leave:({name:e,argumentName:t})=>D([`@`,e,k(`(`,t,`:)`)])}};function D(e,t=``){return e?.filter(e=>e).join(t)??``}function O(e){return k(`{
39`,ct(D(e,`
40`)),`
41}`)}function k(e,t,n=``){return t!=null&&t!==``?e+t+n:``}function ct(e){return k(`  `,e.replace(/\n/g,`
42  `))}function lt(e){return e?.some(e=>e.includes(`
43`))??!1}var ut=function(e,t){return ut=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},ut(e,t)};function A(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Class extends value `+String(t)+` is not a constructor or null`);ut(e,t);function n(){this.constructor=e}
vendor: 15,272 bytes, lines 43-45
43e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var dt=function(){return dt=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n],t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},dt.apply(this,arguments)};function ft(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function pt(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})}function mt(e,t){var n={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},r,i,a,o=Object.create((typeof Iterator==`function`?Iterator:Object).prototype);return o.next=s(0),o.throw=s(1),o.return=s(2),typeof Symbol==`function`&&(o[Symbol.iterator]=function(){return this}),o;function s(e){return function(t){return c([e,t])}}function c(s){if(r)throw TypeError(`Generator is already executing.`);for(;o&&(o=0,s[0]&&(n=0)),n;)try{if(r=1,i&&(a=s[0]&2?i.return:s[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,s[1])).done)return a;switch(i=0,a&&(s=[s[0]&2,a.value]),s[0]){case 0:case 1:a=s;break;case 4:return n.label++,{value:s[1],done:!1};case 5:n.label++,i=s[1],s=[0];continue;case 7:s=n.ops.pop(),n.trys.pop();continue;default:if(a=n.trys,!(a=a.length>0&&a[a.length-1])&&(s[0]===6||s[0]===2)){n=0;continue}if(s[0]===3&&(!a||s[1]>a[0]&&s[1]<a[3])){n.label=s[1];break}if(s[0]===6&&n.label<a[1]){n.label=a[1],a=s;break}if(a&&n.label<a[2]){n.label=a[2],n.ops.push(s);break}a[2]&&n.ops.pop(),n.trys.pop();continue}s=t.call(e,n)}catch(e){s=[6,e],i=0}finally{r=a=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}}function ht(e){var t=typeof Symbol==`function`&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&typeof e.length==`number`)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw TypeError(t?`Object is not iterable.`:`Symbol.iterator is not defined.`)}function j(e,t){var n=typeof Symbol==`function`&&e[Symbol.iterator];if(!n)return e;var r=n.call(e),i,a=[],o;try{for(;(t===void 0||t-->0)&&!(i=r.next()).done;)a.push(i.value)}catch(e){o={error:e}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(o)throw o.error}}return a}function M(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,a;r<i;r++)(a||!(r in t))&&(a||=Array.prototype.slice.call(t,0,r),a[r]=t[r]);return e.concat(a||Array.prototype.slice.call(t))}function gt(e){return this instanceof gt?(this.v=e,this):new gt(e)}function _t(e,t,n){if(!Symbol.asyncIterator)throw TypeError(`Symbol.asyncIterator is not defined.`);var r=n.apply(e,t||[]),i,a=[];return i=Object.create((typeof AsyncIterator==`function`?AsyncIterator:Object).prototype),s(`next`),s(`throw`),s(`return`,o),i[Symbol.asyncIterator]=function(){return this},i;function o(e){return function(t){return Promise.resolve(t).then(e,d)}}function s(e,t){r[e]&&(i[e]=function(t){return new Promise(function(n,r){a.push([e,t,n,r])>1||c(e,t)})},t&&(i[e]=t(i[e])))}function c(e,t){try{l(r[e](t))}catch(e){f(a[0][3],e)}}function l(e){e.value instanceof gt?Promise.resolve(e.value.v).then(u,d):f(a[0][2],e)}function u(e){c(`next`,e)}function d(e){c(`throw`,e)}function f(e,t){e(t),a.shift(),a.length&&c(a[0][0],a[0][1])}}function vt(e){if(!Symbol.asyncIterator)throw TypeError(`Symbol.asyncIterator is not defined.`);var t=e[Symbol.asyncIterator],n;return t?t.call(e):(e=typeof ht==`function`?ht(e):e[Symbol.iterator](),n={},r(`next`),r(`throw`),r(`return`),n[Symbol.asyncIterator]=function(){return this},n);function r(t){n[t]=e[t]&&function(n){return new Promise(function(r,a){n=e[t](n),i(r,a,n.done,n.value)})}}function i(e,t,n,r){Promise.resolve(r).then(function(t){e({value:t,done:n})},t)}}function N(e){return typeof e==`function`}function yt(e){var t=e(function(e){Error.call(e),e.stack=Error().stack});return t.prototype=Object.create(Error.prototype),t.prototype.constructor=t,t}var bt=yt(function(e){return function(t){e(this),this.message=t?t.length+` errors occurred during unsubscription:
44`+t.map(function(e,t){return t+1+`) `+e.toString()}).join(`
45  `):``,this.name=`UnsubscriptionError`,this.errors=t}});function xt(e,t){if(e){var n=e.indexOf(t);0<=n&&e.splice(n,1)}}var St=function(){function e(e){this.initialTeardown=e,this.closed=!1,this._parentage=null,this._finalizers=null}return e.prototype.unsubscribe=function(){var e,t,n,r,i;if(!this.closed){this.closed=!0;var a=this._parentage;if(a){if(this._parentage=null,Array.isArray(a))try{for(var o=ht(a),s=o.next();!s.done;s=o.next())s.value.remove(this)}catch(t){e={error:t}}finally{try{s&&!s.done&&(t=o.return)&&t.call(o)}finally{if(e)throw e.error}}else a.remove(this)}var c=this.initialTeardown;if(N(c))try{c()}catch(e){i=e instanceof bt?e.errors:[e]}var l=this._finalizers;if(l){this._finalizers=null;try{for(var u=ht(l),d=u.next();!d.done;d=u.next()){var f=d.value;try{Tt(f)}catch(e){i??=[],e instanceof bt?i=M(M([],j(i)),j(e.errors)):i.push(e)}}}catch(e){n={error:e}}finally{try{d&&!d.done&&(r=u.return)&&r.call(u)}finally{if(n)throw n.error}}}if(i)throw new bt(i)}},e.prototype.add=function(t){if(t&&t!==this){if(this.closed)Tt(t);else{if(t instanceof e){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=this._finalizers??[]).push(t)}}},e.prototype._hasParent=function(e){var t=this._parentage;return t===e||Array.isArray(t)&&t.includes(e)},e.prototype._addParent=function(e){var t=this._parentage;this._parentage=Array.isArray(t)?(t.push(e),t):t?[t,e]:e},e.prototype._removeParent=function(e){var t=this._parentage;t===e?this._parentage=null:Array.isArray(t)&&xt(t,e)},e.prototype.remove=function(t){var n=this._finalizers;n&&xt(n,t),t instanceof e&&t._removeParent(this)},e.EMPTY=(function(){var t=new e;return t.closed=!0,t})(),e}(),Ct=St.EMPTY;function wt(e){return e instanceof St||e&&`closed`in e&&N(e.remove)&&N(e.add)&&N(e.unsubscribe)}function Tt(e){N(e)?e():e.unsubscribe()}var Et={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Dt={setTimeout:function(e,t){var n=[...arguments].slice(2),r=Dt.delegate;return r?.setTimeout?r.setTimeout.apply(r,M([e,t],j(n))):setTimeout.apply(void 0,M([e,t],j(n)))},clearTimeout:function(e){return(Dt.delegate?.clearTimeout||clearTimeout)(e)},delegate:void 0};function Ot(e){Dt.setTimeout(function(){var t=Et.onUnhandledError;if(t)t(e);else throw e})}function kt(){}var At=(function(){return Nt(`C`,void 0,void 0)})();function jt(e){return Nt(`E`,void 0,e)}function Mt(e){return Nt(`N`,e,void 0)}function Nt(e,t,n){return{kind:e,value:t,error:n}}var Pt=null;function Ft(e){if(Et.useDeprecatedSynchronousErrorHandling){var t=!Pt;if(t&&(Pt={errorThrown:!1,error:null}),e(),t){var n=Pt,r=n.errorThrown,i=n.error;if(Pt=null,r)throw i}}else e()}function It(e){Et.useDeprecatedSynchronousErrorHandling&&Pt&&(Pt.errorThrown=!0,Pt.error=e)}var Lt=function(e){A(t,e);function t(t){var n=e.call(this)||this;return n.isStopped=!1,t?(n.destination=t,wt(t)&&t.add(n)):n.destination=Gt,n}return t.create=function(e,t,n){return new Vt(e,t,n)},t.prototype.next=function(e){this.isStopped?Wt(Mt(e),this):this._next(e)},t.prototype.error=function(e){this.isStopped?Wt(jt(e),this):(this.isStopped=!0,this._error(e))},t.prototype.complete=function(){this.isStopped?Wt(At,this):(this.isStopped=!0,this._complete())},t.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,e.prototype.unsubscribe.call(this),this.destination=null)},t.prototype._next=function(e){this.destination.next(e)},t.prototype._error=function(e){try{this.destination.error(e)}finally{this.unsubscribe()}},t.prototype._complete=function(){try{this.destination.complete()}finally{this.unsubscribe()}},t}(St),Rt=Function.prototype.bind;function zt(e,t){return Rt.call(e,t)}var Bt=function(){function e(e){this.partialObserver=e}return e.prototype.next=function(e){var t=this.partialObserver;if(t.next)try{t.next(e)}catch(e){Ht(e)}},e.prototype.error=function(e){var t=this.partialObserver;if(t.error)try{t.error(e)}catch(e){Ht(e)}else Ht(e)},e.prototype.complete=function(){var e=this.partialObserver;if(e.complete)try{e.complete()}catch(e){Ht(e)}},e}(),Vt=function(e){A(t,e);function t(t,n,r){var i=e.call(this)||this,a;if(N(t)||!t)a={next:t??void 0,error:n??void 0,complete:r??void 0};else{var o;i&&Et.useDeprecatedNextContext?(o=Object.create(t),o.unsubscribe=function(){return i.unsubscribe()},a={next:t.next&&zt(t.next,o),error:t.error&&zt(t.error,o),complete:t.complete&&zt(t.complete,o)}):a=t}return i.destination=new Bt(a),i}return t}(Lt);function Ht(e){Et.useDeprecatedSynchronousErrorHandling?It(e):Ot(e)}function Ut(e){throw e}function Wt(e,t){var n=Et.onStoppedNotification;n&&Dt.setTimeout(function(){return n(e,t)})}var Gt={closed:!0,next:kt,error:Ut,complete:kt},Kt=(function(){return typeof Symbol==`function`&&Symbol.observable||`@@observable`})();function qt(e){return e}function Jt(e){return e.length===0?qt:e.length===1?e[0]:function(t){return e.reduce(function(e,t){return t(e)},t)}}var P=function(){function e(e){e&&(this._subscribe=e)}return e.prototype.lift=function(t){var n=new e;return n.source=this,n.operator=t,n},e.prototype.subscribe=function(e,t,n){var r=this,i=Zt(e)?e:new Vt(e,t,n);return Ft(function(){var e=r,t=e.operator,n=e.source;i.add(t?t.call(i,n):n?r._subscribe(i):r._trySubscribe(i))}),i},e.prototype._trySubscribe=function(e){try{return this._subscribe(e)}catch(t){e.error(t)}},e.prototype.forEach=function(e,t){var n=this;return t=Yt(t),new t(function(t,r){var i=new Vt({next:function(t){try{e(t)}catch(e){r(e),i.unsubscribe()}},error:r,complete:t});n.subscribe(i)})},e.prototype._subscribe=function(e){return this.source?.subscribe(e)},e.prototype[Kt]=function(){return this},e.prototype.pipe=function(){return Jt([...arguments])(this)},e.prototype.toPromise=function(e){var t=this;return e=Yt(e),new e(function(e,n){var r;t.subscribe(function(e){return r=e},function(e){return n(e)},function(){return e(r)})})},e.create=function(t){return new e(t)},e}();function Yt(e){return e??Et.Promise??Promise}function Xt(e){return e&&N(e.next)&&N(e.error)&&N(e.complete)}function Zt(e){return e&&e instanceof Lt||Xt(e)&&wt(e)}function Qt(e){return N(e?.lift)}function F(e){return function(t){if(Qt(t))return t.lift(function(t){try{return e(t,this)}catch(e){this.error(e)}});throw TypeError(`Unable to lift unknown Observable type`)}}function I(e,t,n,r,i){return new $t(e,t,n,r,i)}var $t=function(e){A(t,e);function t(t,n,r,i,a,o){var s=e.call(this,t)||this;return s.onFinalize=a,s.shouldUnsubscribe=o,s._next=n?function(e){try{n(e)}catch(e){t.error(e)}}:e.prototype._next,s._error=i?function(e){try{i(e)}catch(e){t.error(e)}finally{this.unsubscribe()}}:e.prototype._error,s._complete=r?function(){try{r()}catch(e){t.error(e)}finally{this.unsubscribe()}}:e.prototype._complete,s}return t.prototype.unsubscribe=function(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){var n=this.closed;e.prototype.unsubscribe.call(this),!n&&((t=this.onFinalize)==null||t.call(this))}},t}(Lt),en=yt(function(e){return function(){e(this),this.name=`ObjectUnsubscribedError`,this.message=`object unsubscribed`}}),tn=function(e){A(t,e);function t(){var t=e.call(this)||this;return t.closed=!1,t.currentObservers=null,t.observers=[],t.isStopped=!1,t.hasError=!1,t.thrownError=null,t}return t.prototype.lift=function(e){var t=new nn(this,this);return t.operator=e,t},t.prototype._throwIfClosed=function(){if(this.closed)throw new en},t.prototype.next=function(e){var t=this;Ft(function(){var n,r;if(t._throwIfClosed(),!t.isStopped){t.currentObservers||=Array.from(t.observers);try{for(var i=ht(t.currentObservers),a=i.next();!a.done;a=i.next())a.value.next(e)}catch(e){n={error:e}}finally{try{a&&!a.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}}})},t.prototype.error=function(e){var t=this;Ft(function(){if(t._throwIfClosed(),!t.isStopped){t.hasError=t.isStopped=!0,t.thrownError=e;for(var n=t.observers;n.length;)n.shift().error(e)}})},t.prototype.complete=function(){var e=this;Ft(function(){if(e._throwIfClosed(),!e.isStopped){e.isStopped=!0;for(var t=e.observers;t.length;)t.shift().complete()}})},t.prototype.unsubscribe=function(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null},Object.defineProperty(t.prototype,"observed",{get:function(){return this.observers?.length>0},enumerable:!1,configurable:!0}),t.prototype._trySubscribe=function(t){return this._throwIfClosed(),e.prototype._trySubscribe.call(this,t)},t.prototype._subscribe=function(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)},t.prototype._innerSubscribe=function(e){var t=this,n=this,r=n.hasError,i=n.isStopped,a=n.observers;return r||i?Ct:(this.currentObservers=null,a.push(e),new St(function(){t.currentObservers=null,xt(a,e)}))},t.prototype._checkFinalizedStatuses=function(e){var t=this,n=t.hasError,r=t.thrownError,i=t.isStopped;n?e.error(r):i&&e.complete()},t.prototype.asObservable=function(){var e=new P;return e.source=this,e},t.create=function(e,t){return new nn(e,t)},t}(P),nn=function(e){A(t,e);function t(t,n){var r=e.call(this)||this;return r.destination=t,r.source=n,r}return t.prototype.next=function(e){var t,n;(n=(t=this.destination)?.next)==null||n.call(t,e)},t.prototype.error=function(e){var t,n;(n=(t=this.destination)?.error)==null||n.call(t,e)},t.prototype.complete=function(){var e,t;(t=(e=this.destination)?.complete)==null||t.call(e)},t.prototype._subscribe=function(e){return this.source?.subscribe(e)??Ct},t}(tn),rn=function(e){A(t,e);function t(t){var n=e.call(this)||this;return n._value=t,n}return Object.defineProperty(t.prototype,"value",{get:function(){return this.getValue()},enumerable:!1,configurable:!0}),t.prototype._subscribe=function(t){var n=e.prototype._subscribe.call(this,t);return!n.closed&&t.next(this._value),n},t.prototype.getValue=function(){var e=this,t=e.hasError,n=e.thrownError,r=e._value;if(t)throw n;return this._throwIfClosed(),r},t.prototype.next=function(t){e.prototype.next.call(this,this._value=t)},t}(tn),an={now:function(){return(an.delegate||Date).now()},delegate:void 0},on=function(e){A(t,e);function t(t,n,r){t===void 0&&(t=1/0),n===void 0&&(n=1/0),r===void 0&&(r=an);var i=e.call(this)||this;return i._bufferSize=t,i._windowTime=n,i._timestampProvider=r,i._buffer=[],i._infiniteTimeWindow=!0,i._infiniteTimeWindow=n===1/0,i._bufferSize=Math.max(1,t),i._windowTime=Math.max(1,n),i}return t.prototype.next=function(t){var n=this,r=n.isStopped,i=n._buffer,a=n._infiniteTimeWindow,o=n._timestampProvider,s=n._windowTime;r||(i.push(t),!a&&i.push(o.now()+s)),this._trimBuffer(),e.prototype.next.call(this,t)},t.prototype._subscribe=function(e){this._throwIfClosed(),this._trimBuffer();for(var t=this._innerSubscribe(e),n=this,r=n._infiniteTimeWindow,i=n._buffer.slice(),a=0;a<i.length&&!e.closed;
45a+=r?1:2)e.next(i[a]);return this._checkFinalizedStatuses(e),t},t.prototype._trimBuffer=function(){var e=this,t=e._bufferSize,n=e._timestampProvider,r=e._buffer,i=e._infiniteTimeWindow,a=(i?1:2)*t;if(t<1/0&&a<r.length&&r.splice(0,r.length-a),!i){for(var o=n.now(),s=0,c=1;c<r.length&&r[c]<=o;c+=2)s=c;s&&r.splice(0,s+1)}},t}(tn),sn=function(e){A(t,e);function t(t,n){return e.call(this)||this}return t.prototype.schedule=function(e,t){return t===void 0&&(t=0),this},t}(St),cn={setInterval:function(e,t){var n=[...arguments].slice(2),r=cn.delegate;return r?.setInterval?r.setInterval.apply(r,M([e,t],j(n))):setInterval.apply(void 0,M([e,t],j(n)))},clearInterval:function(e){return(cn.delegate?.clearInterval||clearInterval)(e)},delegate:void 0},ln=function(e){A(t,e);function t(t,n){var r=e.call(this,t,n)||this;return r.scheduler=t,r.work=n,r.pending=!1,r}return t.prototype.schedule=function(e,t){if(t===void 0&&(t=0),this.closed)return this;this.state=e;var n=this.id,r=this.scheduler;return n!=null&&(this.id=this.recycleAsyncId(r,n,t)),this.pending=!0,this.delay=t,this.id=this.id??this.requestAsyncId(r,this.id,t),this},t.prototype.requestAsyncId=function(e,t,n){return n===void 0&&(n=0),cn.setInterval(e.flush.bind(e,this),n)},t.prototype.recycleAsyncId=function(e,t,n){if(n===void 0&&(n=0),n!=null&&this.delay===n&&this.pending===!1)return t;t!=null&&cn.clearInterval(t)},t.prototype.execute=function(e,t){if(this.closed)return Error(`executing a cancelled action`);this.pending=!1;var n=this._execute(e,t);if(n)return n;this.pending===!1&&this.id!=null&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))},t.prototype._execute=function(e,t){var n=!1,r;try{this.work(e)}catch(e){n=!0,r=e||Error(`Scheduled action threw falsy error`)}if(n)return this.unsubscribe(),r},t.prototype.unsubscribe=function(){if(!this.closed){var t=this,n=t.id,r=t.scheduler,i=r.actions;this.work=this.state=this.scheduler=null,this.pending=!1,xt(i,this),n!=null&&(this.id=this.recycleAsyncId(r,n,null)),this.delay=null,e.prototype.unsubscribe.call(this)}},t}(sn),un=1,dn,fn={};function pn(e){return e in fn&&(delete fn[e],!0)}var mn={setImmediate:function(e){var t=un++;return fn[t]=!0,dn||=Promise.resolve(),dn.then(function(){return pn(t)&&e()}),t},clearImmediate:function(e){pn(e)}},hn=mn.setImmediate,gn=mn.clearImmediate,_n={setImmediate:function(){var e=[...arguments];return(_n.delegate?.setImmediate||hn).apply(void 0,M([],j(e)))},clearImmediate:function(e){return(_n.delegate?.clearImmediate||gn)(e)},delegate:void 0},vn=function(e){A(t,e);function t(t,n){var r=e.call(this,t,n)||this;return r.scheduler=t,r.work=n,r}return t.prototype.requestAsyncId=function(t,n,r){return r===void 0&&(r=0),r!==null&&r>0?e.prototype.requestAsyncId.call(this,t,n,r):(t.actions.push(this),t._scheduled||=_n.setImmediate(t.flush.bind(t,void 0)))},t.prototype.recycleAsyncId=function(t,n,r){if(r===void 0&&(r=0),r==null?this.delay>0:r>0)return e.prototype.recycleAsyncId.call(this,t,n,r);var i=t.actions;n!=null&&i[i.length-1]?.id!==n&&(_n.clearImmediate(n),t._scheduled===n&&(t._scheduled=void 0))},t}(ln),yn=function(){function e(t,n){n===void 0&&(n=e.now),this.schedulerActionCtor=t,this.now=n}return e.prototype.schedule=function(e,t,n){return t===void 0&&(t=0),new this.schedulerActionCtor(this,e).schedule(n,t)},e.now=an.now,e}(),bn=function(e){A(t,e);function t(t,n){n===void 0&&(n=yn.now);var r=e.call(this,t,n)||this;return r.actions=[],r._active=!1,r}return t.prototype.flush=function(e){var t=this.actions;if(this._active){t.push(e);return}var n;this._active=!0;do if(n=e.execute(e.state,e.delay))break;while(e=t.shift());if(this._active=!1,n){for(;e=t.shift();)e.unsubscribe();throw n}},t}(yn),xn=new(function(e){A(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.flush=function(e){this._active=!0;var t=this._scheduled;this._scheduled=void 0;var n=this.actions,r;e||=n.shift();do if(r=e.execute(e.state,e.delay))break;while((e=n[0])&&e.id===t&&n.shift());if(this._active=!1,r){for(;(e=n[0])&&e.id===t&&n.shift();)e.unsubscribe();throw r}},t}(bn))(vn),Sn=new bn(ln),Cn=new P(function(e){return e.complete()});function wn(e){return e&&N(e.schedule)}function Tn(e){return e[e.length-1]}function En(e){return wn(Tn(e))?e.pop():void 0}var Dn=(function(e){return e&&typeof e.length==`number`&&typeof e!=`function`});function On(e){return N(e?.then)}function kn(e){return N(e[Kt])}function An(e){return Symbol.asyncIterator&&N(e?.[Symbol.asyncIterator])}function jn(e){return TypeError(`You provided `+(typeof e==`object`&&e?`an invali
45d object`:`'`+e+`'`)+` where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.`)}function Mn(){return typeof Symbol!=`function`||!Symbol.iterator?`@@iterator`:Symbol.iterator}var Nn=Mn();function Pn(e){return N(e?.[Nn])}function Fn(e){return _t(this,arguments,function(){var t,n,r,i;return mt(this,function(a){switch(a.label){case 0:t=e.getReader(),a.label=1;case 1:a.trys.push([1,,9,10]),a.label=2;case 2:return[4,gt(t.read())];case 3:return n=a.sent(),r=n.value,i=n.done,i?[4,gt(void 0)]:[3,5];case 4:return[2,a.sent()];case 5:return[4,gt(r)];case 6:return[4,a.sent()];case 7:return a.sent(),[3,2];case 8:return[3,10];case 9:return t.releaseLock(),[7];case 10:return[2]}})})}function In(e){return N(e?.getReader)}function Ln(e){if(e instanceof P)return e;if(e!=null){if(kn(e))return Rn(e);if(Dn(e))return zn(e);if(On(e))return Bn(e);if(An(e))return Hn(e);if(Pn(e))return Vn(e);if(In(e))return Un(e)}throw jn(e)}function Rn(e){return new P(function(t){var n=e[Kt]();if(N(n.subscribe))return n.subscribe(t);throw TypeError(`Provided object does not correctly implement Symbol.observable`)})}function zn(e){return new P(function(t){for(var n=0;n<e.length&&!t.closed;n++)t.next(e[n]);t.complete()})}function Bn(e){return new P(function(t){e.then(function(e){t.closed||(t.next(e),t.complete())},function(e){return t.error(e)}).then(null,Ot)})}function Vn(e){return new P(function(t){var n,r;try{for(var i=ht(e),a=i.next();!a.done;a=i.next()){var o=a.value;if(t.next(o),t.closed)return}}catch(e){n={error:e}}finally{try{a&&!a.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}t.complete()})}function Hn(e){return new P(function(t){Wn(e,t).catch(function(e){return t.error(e)})})}function Un(e){return Hn(Fn(e))}function Wn(e,t){var n,r,i,a;return pt(this,void 0,void 0,function(){var o,s;return mt(this,function(c){switch(c.label){case 0:c.trys.push([0,5,6,11]),n=vt(e),c.label=1;case 1:return[4,n.next()];case 2:if(r=c.sent(),r.done)return[3,4];if(o=r.value,t.next(o),t.closed)return[2];c.label=3;case 3:return[3,1];case 4:return[3,11];case 5:return s=c.sent(),i={error:s},[3,11];case 6:return c.trys.push([6,,9,10]),r&&!r.done&&(a=n.return)?[4,a.call(n)]:[3,8];case 7:c.sent(),c.label=8;case 8:return[3,10];case 9:if(i)throw i.error;return[7];case 10:return[7];case 11:return t.complete(),[2]}})})}function Gn(e,t,n,r,i){r===void 0&&(r=0),i===void 0&&(i=!1);var a=t.schedule(function(){n(),i?e.add(this.schedule(null,r)):this.unsubscribe()},r);if(e.add(a),!i)return a}function Kn(e,t){return t===void 0&&(t=0),F(function(n,r){n.subscribe(I(r,function(n){return Gn(r,e,function(){return r.next(n)},t)},function(){return Gn(r,e,function(){return r.complete()},t)},function(n){return Gn(r,e,function(){return r.error(n)},t)}))})}function qn(e,t){return t===void 0&&(t=0),F(function(n,r){r.add(e.schedule(function(){return n.subscribe(r)},t))})}function Jn(e,t){return Ln(e).pipe(qn(t),Kn(t))}function Yn(e,t){return Ln(e).pipe(qn(t),Kn(t))}function Xn(e,t){return new P(function(n){var r=0;return t.schedule(function(){r===e.length?n.complete():(n.next(e[r++]),n.closed||this.schedule())})})}function Zn(e,t){return new P(function(n){var r;return Gn(n,t,function(){r=e[Nn](),Gn(n,t,function(){var e,t,i;try{e=r.next(),t=e.value,i=e.done}catch(e){n.error(e);return}i?n.complete():n.next(t)},0,!0)}),function(){return N(r?.return)&&r.return()}})}function Qn(e,t){if(!e)throw Error(`Iterable cannot be null`);return new P(function(n){Gn(n,t,function(){var r=e[Symbol.asyncIterator]();Gn(n,t,function(){r.next().then(function(e){e.done?n.complete():n.next(e.value)})},0,!0)})})}function $n(e,t){return Qn(Fn(e),t)}function er(e,t){if(e!=null){if(kn(e))return Jn(e,t);if(Dn(e))return Xn(e,t);if(On(e))return Yn(e,t);if(An(e))return Qn(e,t);if(Pn(e))return Zn(e,t);if(In(e))return $n(e,t)}throw jn(e)}function tr(e,t){return t?er(e,t):Ln(e)}function nr(){var e=[...arguments];return tr(e,En(e))}function rr(e,t){var n=N(e)?e:function(){return e},r=function(e){return e.error(n())};return new P(t?function(e){return t.schedule(r,0,e)}:r)}var ir;(function(e){e.NEXT=`N`,e.ERROR=`E`,e.COMPLETE=`C`})(ir||={});var ar=function(){function e(e,t,n){this.kind=e,this.value=t,this.error=n,this.hasValue=e===`N`}return e.prototype.observe=function(e){return or(this,e)},e.prototype.do=function(e,t,n){var r=this,i=r.kind,a=r.value,o=r.error;return i===`N`?e?.(a):i===`E`?t?.(o):n?.()},e.prototype.accept=function(e,t,n){return N(e?.next)?this.observe(e):this.do(e,t,n
45)},e.prototype.toObservable=function(){var e=this,t=e.kind,n=e.value,r=e.error,i=t===`N`?nr(n):t===`E`?rr(function(){return r}):t===`C`?Cn:0;if(!i)throw TypeError(`Unexpected notification kind `+t);return i},e.createNext=function(t){return new e(`N`,t)},e.createError=function(t){return new e(`E`,void 0,t)},e.createComplete=function(){return e.completeNotification},e.completeNotification=new e(`C`),e}();function or(e,t){var n,r,i,a=e,o=a.kind,s=a.value,c=a.error;if(typeof o!=`string`)throw TypeError(`Invalid notification, missing "kind"`);o===`N`?(n=t.next)==null||n.call(t,s):o===`E`?(r=t.error)==null||r.call(t,c):(i=t.complete)==null||i.call(t)}var sr=yt(function(e){return function(){e(this),this.name=`EmptyError`,this.message=`no elements in sequence`}});function cr(e,t){var n=typeof t==`object`;return new Promise(function(r,i){var a=!1,o;e.subscribe({next:function(e){o=e,a=!0},error:i,complete:function(){a?r(o):n?r(t.defaultValue):i(new sr)}})})}function lr(e){return e instanceof Date&&!isNaN(e)}function L(e,t){return F(function(n,r){var i=0;n.subscribe(I(r,function(n){r.next(e.call(t,n,i++))}))})}function ur(e,t,n,r,i,a,o,s){var c=[],l=0,u=0,d=!1,f=function(){d&&!c.length&&!l&&t.complete()},p=function(e){return l<r?m(e):c.push(e)},m=function(e){a&&t.next(e),l++;var s=!1;Ln(n(e,u++)).subscribe(I(t,function(e){i?.(e),a?p(e):t.next(e)},function(){s=!0},void 0,function(){if(s)try{l--;for(var e=function(){var e=c.shift();o?Gn(t,o,function(){return m(e)}):m(e)};c.length&&l<r;)e();f()}catch(e){t.error(e)}}))};return e.subscribe(I(t,p,function(){d=!0,f()})),function(){s?.()}}function dr(e,t,n){return n===void 0&&(n=1/0),N(t)?dr(function(n,r){return L(function(e,i){return t(n,e,r,i)})(Ln(e(n,r)))},n):(typeof t==`number`&&(n=t),F(function(t,r){return ur(t,r,e,n)}))}function fr(e){return e===void 0&&(e=1/0),dr(qt,e)}function pr(){return fr(1)}function mr(){var e=[...arguments];return pr()(tr(e,En(e)))}function hr(e,t,n){e===void 0&&(e=0),n===void 0&&(n=Sn);var r=-1;return t!=null&&(wn(t)?n=t:r=t),new P(function(t){var i=lr(e)?+e-n.now():e;i<0&&(i=0);var a=0;return n.schedule(function(){t.closed||(t.next(a++),0<=r?this.schedule(void 0,r):t.complete())},i)})}function gr(e,t){return F(function(n,r){var i=0;n.subscribe(I(r,function(n){return e.call(t,n,i++)&&r.next(n)}))})}function _r(e){return F(function(t,n){var r=null,i=!1,a;r=t.subscribe(I(n,void 0,void 0,function(o){a=Ln(e(o,_r(e)(t))),r?(r.unsubscribe(),r=null,a.subscribe(n)):i=!0})),i&&(r.unsubscribe(),r=null,a.subscribe(n))})}function vr(e,t){return t===void 0&&(t=qt),e??=yr,F(function(n,r){var i,a=!0;n.subscribe(I(r,function(n){var o=t(n);(a||!e(i,o))&&(a=!1,i=o,r.next(n))}))})}function yr(e,t){return e===t}function br(e){return F(function(t,n){try{t.subscribe(n)}finally{n.add(e)}})}function xr(){return F(function(e,t){e.subscribe(I(t,function(e){t.next(ar.createNext(e))},function(){t.next(ar.createComplete()),t.complete()},function(e){t.next(ar.createError(e)),t.complete()}))})}function Sr(e){e===void 0&&(e={});var t=e.connector,n=t===void 0?function(){return new tn}:t,r=e.resetOnError,i=r===void 0||r,a=e.resetOnComplete,o=a===void 0||a,s=e.resetOnRefCountZero,c=s===void 0||s;return function(e){var t,r,a,s=0,l=!1,u=!1,d=function(){r?.unsubscribe(),r=void 0},f=function(){d(),t=a=void 0,l=u=!1},p=function(){var e=t;f(),e?.unsubscribe()};return F(function(e,m){s++,!u&&!l&&d();var h=a??=n();m.add(function(){s--,s===0&&!u&&!l&&(r=Cr(p,c))}),h.subscribe(m),!t&&s>0&&(t=new Vt({next:function(e){return h.next(e)},error:function(e){u=!0,d(),r=Cr(f,i,e),h.error(e)},complete:function(){l=!0,d(),r=Cr(f,o),h.complete()}}),Ln(e).subscribe(t))})(e)}}function Cr(e,t){var n=[...arguments].slice(2);if(t===!0){e();return}if(t!==!1){var r=new Vt({next:function(){r.unsubscribe(),e()}});return Ln(t.apply(void 0,M([],j(n)))).subscribe(r)}}function wr(e,t,n){var r,i,a,o,s=!1;return e&&typeof e==`object`?(r=e.bufferSize,o=r===void 0?1/0:r,i=e.windowTime,t=i===void 0?1/0:i,a=e.refCount,s=a!==void 0&&a,n=e.scheduler):o=e??1/0,Sr({connector:function(){return new on(o,t,n)},resetOnError:!0,resetOnComplete:!1,resetOnRefCountZero:s})}function Tr(e,t,n){var r=N(e)||t||n?{next:e,error:t,complete:n}:e;return r?F(function(e,t){var n;(n=r.subscribe)==null||n.call(r);var i=!0;e.subscribe(I(t,function(e){var n;(n=r.next)==null||n.call(r,e),t.next(e)},function(){var e;i=!1,(e=r.complete)==null||e.call(r),t.complete()},function(e){var n;i=!1,(n=r.error)==null||n.call(r,e),t.error(e)},function(){var e,t;i&&((e=r.unsubscribe)==null||e.call(r)),(t=r.finalize)==null||t.call(r)}))}):qt}function Er(e,t,n){let r=e.arguments?.find(e=>e.name.value===t);if(r&&r.value.kind===n)switch(r.value.kind){case T.STRING:return r.value.value}}function Dr(e,t,n,r){if(n.kind===T.INT||n.kind===T.FLOAT)e[t.value]=Number(n.value);else if(n.kind===T.BOOLEAN||n.kind===T.STRING)e[t.value]=n.value;else if(n.kind===T.OBJECT){let i={};n.fields.map(e=>Dr(i,e.name,e.value,r)),e[t.value]=i}else if(n.kind===T.VARIABLE){let i=(r||{})[n.name.value];e[t.value]=i}else if(n.kind===T.LIST)e[t.value]=n.values.map(e=>{let n={};return Dr(n,t,e,r),n[t.value]});else if(n.kind===T.ENUM)e[t.value]=n.value;else if(n.kind===T.NULL)e[t.value]=null;else throw C(21,t.value,n.kind)}function Or(e,t){if(e.arguments&&e.arguments.length){let n={};
45return e.arguments.forEach(({name:e,value:r})=>Dr(n,e,r,t)),n}return null}function kr(e){return e[0].toUpperCase()+e.slice(1)}var Ar=typeof b(()=>window.document.createElement)==`function`,R={...ee[Symbol.for(`apollo.cacheSize`)]};function jr(e,t){return e.definitions.find(e=>e.kind===`OperationDefinition`&&!!e.name)?.name.value??t}var Mr=()=>Object.create(null),{forEach:Nr,slice:Pr}=Array.prototype,{hasOwnProperty:Fr}=Object.prototype,z=class e{constructor(e=!0,t=Mr){this.weakness=e,this.makeData=t}lookup(){return this.lookupArray(arguments)}lookupArray(e){let t=this;return Nr.call(e,e=>t=t.getChildTrie(e)),Fr.call(t,`data`)?t.data:t.data=this.makeData(Pr.call(e))}peek(){return this.peekArray(arguments)}peekArray(e){let t=this;for(let n=0,r=e.length;t&&n<r;++n){let r=t.mapFor(e[n],!1);t=r&&r.get(e[n])}return t&&t.data}remove(){return this.removeArray(arguments)}removeArray(e){let t;if(e.length){let n=e[0],r=this.mapFor(n,!1),i=r&&r.get(n);i&&(t=i.removeArray(Pr.call(e,1)),!i.data&&!i.weak&&!(i.strong&&i.strong.size)&&r.delete(n))}else t=this.data,delete this.data;return t}getChildTrie(t){let n=this.mapFor(t,!0),r=n.get(t);return r||n.set(t,r=new e(this.weakness,this.makeData)),r}mapFor(e,t){return this.weakness&&Ir(e)?this.weak||(t?this.weak=new WeakMap:void 0):this.strong||(t?this.strong=new Map:void 0)}};function Ir(e){switch(typeof e){case`object`:if(e===null)break;case`function`:return!0}return!1}function Lr(){}var Rr=class{constructor(e=1/0,t=Lr){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:n}=t;n&&(n.older=e),e&&(e.newer=n),t.older=this.newest,t.older.newer=t,t.newer=null,this.newest=t,t===this.oldest&&(this.oldest=n)}return t}set(e,t){let n=this.getNode(e);return n?n.value=t:(n={key:e,value:t,newer:null,older:this.newest},this.newest&&(this.newest.newer=n),this.newest=n,this.oldest=this.oldest||n,this.map.set(e,n),n.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):!1}};function zr(){}var Br=zr,Vr=typeof WeakRef<`u`?WeakRef:function(e){return{deref:()=>e}},Hr=typeof WeakMap<`u`?WeakMap:Map,Ur=typeof FinalizationRegistry<`u`?FinalizationRegistry:function(){return{register:zr,unregister:zr}},Wr=10024,Gr=class{constructor(e=1/0,t=Br){this.max=e,this.dispose=t,this.map=new Hr,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<Wr;t++){let t=e.next().value;if(!t)break;this.unfinalizedNodes.delete(t);let n=t.key;delete t.key,t.keyRef=new Vr(n),this.registry.register(n,t,t)}this.unfinalizedNodes.size>0?queueMicrotask(this.finalize):this.finalizationScheduled=!1},this.registry=new Ur(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:n}=t;n&&(n.older=e),e&&(e.newer=n),t.older=this.newest,t.older.newer=t,t.newer=null,this.newest=t,t===this.oldest&&(this.oldest=n)}return t}set(e,t){let n=this.getNode(e);return n?n.value=t:(n={key:e,value:t,newer:null,older:this.newest},this.newest&&(this.newest.newer=n),this.newest=n,this.oldest=this.oldest||n,this.scheduleFinalization(n),this.map.set(e,n),this.size++,n.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):!1}scheduleFinalization(e){this.unfinalizedNodes.add(e),this.finalizationScheduled||(this.finalizationScheduled=!0,queueMicrotask(this.finalize))}},Kr=new WeakSet;function qr(e){e.size<=(e.max||-1)||Kr.has(e)||(Kr.add(e),setTimeout(()=>{e.clean(),Kr.delete(e)},100))}var Jr=function(e,t){let n=new Gr(e,t);return n.set=function(e,t){let n=Gr.prototype.set.call(this,e,t);return qr(this),n},n},Yr=function(e,t){let n=new Rr(e,t);return n.set=function(e,t){let n=Rr.prototype.set.call(this,e,t);return qr(this),n},n};function Xr(e,{max:t,makeCacheKey:n=e=>e}){let r=new z(!0),i=new Jr(t);return(...t)=>{let a=r.lookupArray(n(t)),o=i.get(a);if(o){if(o.error)throw o.error;return o.result}let s=i.set(a,{});try{return s.result=e(...t)}catch(e){throw s.error=e,e}}}var B=Xr((e,t)=>{S(e&&e.kind===`Document`,1);let n=e.definitions.filter(e=>e.kind===`OperationDefinition`);t&&S(n.length==1&&n[0].operation===t,4,t,t,n[0].operation),E(e,{Field(t,r,i,a){if(t.alias&&(t.alias.value===`__typename`||t.alias.value.startsWith(`__ac_`))&&t.alias.value!==t.name.value){let r=e,i=[];for(let e of a)r=r[e],r.kind===T.FIELD&&i.push(r.alias?.value||r.name.value);throw i.splice(-1,1,t.name.value),C(5,t.alias.value,i.join(`.`),n[0].operation,jr(e,`(anonymous)`))}}})},{max:R.checkDocument||2e3}),{toString:Zr}=Object.prototype;function Qr(e=[]){let t={};
45return e.forEach(e=>{t[e.name.value]=e}),t}function $r(e){return e.definitions.filter(e=>e.kind===`FragmentDefinition`)}function ei(e,t){switch(e.kind){case`InlineFragment`:return e;case`FragmentSpread`:{let n=e.name.value;if(typeof t==`function`)return t(n);let r=t&&t[n];return S(r,11,n),r}default:return null}}function ti(e){B(e);let t;for(let n of e.definitions){if(n.kind===`OperationDefinition`)return n;n.kind===`FragmentDefinition`&&!t&&(t=n)}if(t)return t;throw C(14)}function V(e){return B(e),e.definitions.filter(e=>e.kind===`OperationDefinition`)[0]}function ni(e){return e.kind===`Field`}function ri(e){return e.match(/^\[(.*)\]$/)}function H(e){return e.alias?e.alias.value:e.name.value}function ii(e){return e.replace(/[[\]]/g,``)}function ai(e,t,n){let r=V(t)?.operation,i=Qr($r(t));S(r,6);function a(e,t,n,r){let i=!1,a=t.map(t=>{let a=o(e,t,n,r);return i||=a!==t,a});return i?a:t}function o(e,t,r,i){if(Array.isArray(t)&&!i)return a(e,t,r,i);if(e.selectionSet)return s(e.selectionSet,t);if(t===null||!r)return t;if(i){let o=ri(i);if(o&&Array.isArray(t))return a(e,t,r,o[1]);let s=n.getScalar(ii(i));if(s)return s.coerceToParsed(t)}return t}function s(e,t,r){if(typeof t!=`object`||!t)return t;let a={...t},s=!1;Object.hasOwn(t,`__typename`)&&(r=t.__typename);let c=new Set(e.selections);return c.forEach(e=>{if(ni(e)){let i=H(e);if(!Object.hasOwn(t,i))return;let c=t[i],l=o(e,c,r,r?n.getScalarTypeForField(r,e.name.value):void 0);s||=l!==c,a[i]=l}else{let t=ei(e,i);t&&r&&n.fragmentMatches(t,r)&&t.selectionSet.selections.forEach(e=>c.add(e))}}),s?a:t}return s(ti(t).selectionSet,e,n.getRootTypename(r))}function oi(e){return e.length===0?Cn:new P(t=>{let{length:n}=e,r=Array(n),i=new Map;e.forEach((e,t)=>{i.has(e)||i.set(e,new Set),i.get(e).add(t)});let a=i.size,o=i.size,s;i.forEach((n,i)=>{let c=!1,l=i.subscribe({next:a=>{n.forEach(e=>r[e]=a),c||(c=!0,o--),o||(s||=new Set(e.filter(e=>e.dirty)),s.delete(i),s.size||(t.next(r.slice()),s=void 0))},complete:()=>{a--,a||t.complete()},error:t.error.bind(t)});t.add(l)})})}function U(...e){let t={};return e.forEach(e=>{e&&Reflect.ownKeys(e).forEach(n=>{let r=e[n];r!==void 0&&(t[n]=r)})}),t}function W(e){return typeof e==`object`&&!!e}var{hasOwnProperty:si}=Object.prototype,ci=function(e,t,n){return this.merge(e[n],t[n])},li=e=>isNaN(+e)?{}:[],ui=class{options;reconciler;constructor(e={}){this.options=e,this.reconciler=e.reconciler||ci}merge(e,t,n={}){let r=n.atPath;if(r?.length){let[i,...a]=r;e===void 0&&(e=li(i));let o=e[i];o===void 0&&a.length&&(o=li(a[0]));let s=this.merge(o,t,{...n,atPath:a});return o!==s&&(e=this.shallowCopyForMerge(e),e[i]=s),e}return Array.isArray(e)&&Array.isArray(t)&&this.options.arrayMerge===`truncate`&&e.length>t.length&&(e=e.slice(0,t.length),this.pastCopies.add(e)),W(t)&&W(e)?(Object.keys(t).forEach(n=>{if(si.call(e,n)){let r=e[n];if(t[n]!==r){let i=this.reconciler(e,t,n);i!==r&&(e=this.shallowCopyForMerge(e),e[n]=i)}}else e=this.shallowCopyForMerge(e),e[n]=t[n]}),e):t}isObject=W;pastCopies=new Set;shallowCopyForMerge(e){return W(e)&&(this.pastCopies.has(e)||(e=Array.isArray(e)?e.slice(0):{__proto__:Object.getPrototypeOf(e),...e},this.pastCopies.add(e))),e}};function di(e){let t={},n=e&&e.variableDefinitions;return n&&n.length&&n.forEach(e=>{e.defaultValue&&Dr(t,e.variable.name,e.defaultValue)}),t}function fi(e,t){let n=t,r=[];return e.definitions.forEach(e=>{if(e.kind===`OperationDefinition`)throw C(12,e.operation,e.name?` named '${e.name.value}'`:``);e.kind===`FragmentDefinition`&&r.push(e)}),n===void 0&&(S(r.length===1,13,r.length),n=r[0].name.value),{...e,definitions:[{kind:`OperationDefinition`,operation:`query`,selectionSet:{kind:`SelectionSet`,selections:[{kind:`FragmentSpread`,name:{kind:`Name`,value:n}}]}},...e.definitions]}}function pi(e){S(e.kind===`Document`,8),S(e.definitions.length<=1,9);let t=e.definitions[0];return S(t.kind===`FragmentDefinition`,10),t}function mi(e){let t=V(e);return S(t&&t.operation===`query`,15),t}var G=Object.assign(function(e){return JSON.stringify(e,gi)},{reset(){hi=new Yr(R.canonicalStringify||1e3)}}),hi;G.reset();function gi(e,t){if(t&&typeof t==`object`){let e=Object.getPrototypeOf(t);if(e===Object.prototype||e===null){let n=Object.keys(t);if(n.every(_i))return t;let r=JSON.stringify(n),i=hi.get(r);if(!i){n.sort();let e=JSON.stringify(n);i=hi.get(e)||n,hi.set(r,i),hi.set(e,i)}let a=Object.create(e);
45return i.forEach(e=>{a[e]=t[e]}),a}}return t}function _i(e,t,n){return t===0||n[t-1]<=e}var vi=[`connection`,`include`,`skip`,`client`,`rest`,`export`,`nonreactive`,`stream`],yi=G,bi=Object.assign(function(e,t,n){if(t&&n&&n.connection&&n.connection.key){if(n.connection.filter&&n.connection.filter.length>0){let e=n.connection.filter?n.connection.filter:[];e.sort();let r={};e.forEach(e=>{r[e]=t[e]});let i=yi(r);if(i!==`{}`)return`${n.connection.key}(${i})`}return n.connection.key}let r=e;if(t){let e=yi(t);e!==`{}`&&(r+=`(${e})`)}return n&&Object.keys(n).forEach(e=>{vi.indexOf(e)===-1&&(n[e]&&Object.keys(n[e]).length?r+=`@${e}(${yi(n[e])})`:r+=`@${e}`)}),r},{setStringify(e){let t=yi;return yi=e,t}});function xi(e){return!!e.errors?.length}function Si(e,t,n){let r=new Set(e),i=r.size;return E(t,{Directive(e){if(r.delete(e.name.value)&&(!n||!r.size))return rt}}),n?!r.size:r.size<i}function Ci(e){let t=!1;return E(e,{Directive:{enter(e){if(e.name.value===`client`&&e.arguments&&(t=e.arguments.some(e=>e.name.value===`always`&&e.value.kind===`BooleanValue`&&e.value.value===!0),t))return rt}}}),t}var K=Array.isArray,wi=Xr(function(e,t){return!!e.directives?.some(e=>{if(e.name.value!==`defer`)return!1;for(let n of e.arguments??[])if(n.name.value===`if`)switch(n.value.kind){case T.BOOLEAN:return n.value.value;case T.VARIABLE:return!!t?.[n.value.name.value]}return!0})},{max:R.isDeferredFragment||2e3,makeCacheKey:([e,t])=>[e,G(t)]});function Ti(e){return W(e)&&e.kind===`Document`&&Array.isArray(e.definitions)}function Ei(e){return Array.isArray(e)&&e.length>0}function Di(e){return typeof e==`object`&&!!e&&(Object.getPrototypeOf(e)===Object.prototype||Object.getPrototypeOf(e)===null)}var Oi=Xr(function(e,t){return!!e.directives?.some(e=>{if(e.name.value!==`stream`)return!1;for(let n of e.arguments??[])if(n.name.value===`if`)switch(n.value.kind){case T.BOOLEAN:return n.value.value;case T.VARIABLE:return!!t?.[n.value.name.value]}return!0})},{max:R.isStreamField||2e3,makeCacheKey:([e,t])=>[e,G(t)]}),ki=()=>Object.create(null),{forEach:Ai,slice:ji}=Array.prototype,{hasOwnProperty:Mi}=Object.prototype,Ni=class e{constructor(e=!0,t=ki){this.weakness=e,this.makeData=t}lookup(...e){return this.lookupArray(e)}lookupArray(e){let t=this;return Ai.call(e,e=>t=t.getChildTrie(e)),Mi.call(t,`data`)?t.data:t.data=this.makeData(ji.call(e))}peek(...e){return this.peekArray(e)}peekArray(e){let t=this;for(let n=0,r=e.length;t&&n<r;++n){let r=this.weakness&&Pi(e[n])?t.weak:t.strong;t=r&&r.get(e[n])}return t&&t.data}getChildTrie(t){let n=this.weakness&&Pi(t)?this.weak||=new WeakMap:this.strong||=new Map,r=n.get(t);return r||n.set(t,r=new e(this.weakness,this.makeData)),r}};function Pi(e){switch(typeof e){case`object`:if(e===null)break;case`function`:return!0}return!1}var q=null,Fi={},Ii=1,Li=()=>class{constructor(){this.id=[`slot`,Ii++,Date.now(),Math.random().toString(36).slice(2)].join(`:`)}hasValue(){for(let e=q;e;e=e.parent)if(this.id in e.slots){let t=e.slots[this.id];if(t===Fi)break;return e!==q&&(q.slots[this.id]=t),!0}return q&&(q.slots[this.id]=Fi),!1}getValue(){if(this.hasValue())return q.slots[this.id]}withValue(e,t,n,r){let i={__proto__:null,[this.id]:e},a=q;q={parent:a,slots:i};try{return t.apply(r,n)}finally{q=a}}static bind(e){let t=q;return function(){let n=q;try{return q=t,e.apply(this,arguments)}finally{q=n}}}static noContext(e,t,n){if(q){let r=q;try{return q=null,e.apply(n,t)}finally{q=r}}else return e.apply(n,t)}};function Ri(e){try{return e()}catch{}}var zi=`@wry/context:Slot`,Bi=Ri(()=>globalThis)||Ri(()=>global)||Object.create(null),Vi=Bi[zi]||Array[zi]||(function(e){try{Object.defineProperty(Bi,zi,{value:e,enumerable:!1,writable:!1,configurable:!0})}finally{return e}})(Li()),{bind:Hi,noContext:Ui}=Vi,Wi=new Vi,{hasOwnProperty:Gi}=Object.prototype,Ki=Array.from||function(e){let t=[];return e.forEach(e=>t.push(e)),t};function qi(e){let{unsubscribe:t}=e;typeof t==`function`&&(e.unsubscribe=void 0,t())}var Ji=[],Yi=100;function Xi(e,t){if(!e)throw Error(t||`assertion failure`)}function Zi(e,t){let n=e.length;return n>0&&n===t.length&&e[n-1]===t[n-1]}function Qi(e){switch(e.length){case 0:throw Error(`unknown value`);case 1:return e[0];case 2:throw e[1]}}function $i(e){return e.slice(0)}var ea=class e{constructor(t){this.fn=t,this.parents=new Set,this.childValues=new Map,this.dirtyChildren=null,this.dirty=!0,this.recomputing=!1,this.value=[],this.deps=null,++e.count}peek(){if(this.value.length===1&&!J(this))return ta(this),this.value[0]}recompute(e){return Xi(!this.recomputing,`already recomputing`),ta(this),J(this)?na(this,e):Qi(this.value)}setDirty(){this.dirty||(this.dirty=!0,aa(this),qi(this))}dispose(){this.setDirty(),da(this),sa(this,(e,t)=>{e.setDirty(),fa(e,this)})}forget(){this.dispose()}dependOn(e){e.add(this),this.deps||=Ji.pop()||new Set,this.deps.add(e)}
45forgetDeps(){this.deps&&=(Ki(this.deps).forEach(e=>e.delete(this)),this.deps.clear(),Ji.push(this.deps),null)}};ea.count=0;function ta(e){let t=Wi.getValue();if(t)return e.parents.add(t),t.childValues.has(e)||t.childValues.set(e,[]),J(e)?ca(t,e):la(t,e),t}function na(e,t){return da(e),Wi.withValue(e,ra,[e,t]),pa(e,t)&&ia(e),Qi(e.value)}function ra(e,t){e.recomputing=!0;let{normalizeResult:n}=e,r;n&&e.value.length===1&&(r=$i(e.value)),e.value.length=0;try{if(e.value[0]=e.fn.apply(null,t),n&&r&&!Zi(r,e.value))try{e.value[0]=n(e.value[0],r[0])}catch{}}catch(t){e.value[1]=t}e.recomputing=!1}function J(e){return e.dirty||!!(e.dirtyChildren&&e.dirtyChildren.size)}function ia(e){e.dirty=!1,!J(e)&&oa(e)}function aa(e){sa(e,ca)}function oa(e){sa(e,la)}function sa(e,t){let n=e.parents.size;if(n){let r=Ki(e.parents);for(let i=0;i<n;++i)t(r[i],e)}}function ca(e,t){Xi(e.childValues.has(t)),Xi(J(t));let n=!J(e);if(!e.dirtyChildren)e.dirtyChildren=Ji.pop()||new Set;else if(e.dirtyChildren.has(t))return;e.dirtyChildren.add(t),n&&aa(e)}function la(e,t){Xi(e.childValues.has(t)),Xi(!J(t));let n=e.childValues.get(t);n.length===0?e.childValues.set(t,$i(t.value)):Zi(n,t.value)||e.setDirty(),ua(e,t),!J(e)&&oa(e)}function ua(e,t){let n=e.dirtyChildren;n&&(n.delete(t),n.size===0&&(Ji.length<Yi&&Ji.push(n),e.dirtyChildren=null))}function da(e){e.childValues.size>0&&e.childValues.forEach((t,n)=>{fa(e,n)}),e.forgetDeps(),Xi(e.dirtyChildren===null)}function fa(e,t){t.parents.delete(e),e.childValues.delete(t),ua(e,t)}function pa(e,t){if(typeof e.subscribe==`function`)try{qi(e),e.unsubscribe=e.subscribe.apply(null,t)}catch{return e.setDirty(),!1}return!0}var ma={setDirty:!0,dispose:!0,forget:!0};function ha(e){let t=new Map,n=e&&e.subscribe;function r(e){let r=Wi.getValue();if(r){let i=t.get(e);i||t.set(e,i=new Set),r.dependOn(i),typeof n==`function`&&(qi(i),i.unsubscribe=n(e))}}return r.dirty=function(e,n){let r=t.get(e);if(r){let i=n&&Gi.call(ma,n)?n:`setDirty`;Ki(r).forEach(e=>e[i]()),t.delete(e),qi(r)}},r}var ga;function _a(...e){return(ga||=new Ni(typeof WeakMap==`function`)).lookupArray(e)}var va=new Set;function ya(e,{max:t=2**16,keyArgs:n,makeCacheKey:r=_a,normalizeResult:i,subscribe:a,cache:o=Rr}=Object.create(null)){let s=typeof o==`function`?new o(t,e=>e.dispose()):o,c=function(){let t=r.apply(null,n?n.apply(null,arguments):arguments);if(t===void 0)return e.apply(null,arguments);let o=s.get(t);o||(s.set(t,o=new ea(e)),o.normalizeResult=i,o.subscribe=a,o.forget=()=>s.delete(t));let c=o.recompute(Array.prototype.slice.call(arguments));return s.set(t,o),va.add(s),Wi.hasValue()||(va.forEach(e=>e.clean()),va.clear()),c};Object.defineProperty(c,"size",{get:()=>s.size,configurable:!1,enumerable:!1}),Object.freeze(c.options={max:t,keyArgs:n,makeCacheKey:r,normalizeResult:i,subscribe:a,cache:s});function l(e){let t=e&&s.get(e);t&&t.setDirty()}c.dirtyKey=l,c.dirty=function(){l(r.apply(null,arguments))};function u(e){let t=e&&s.get(e);if(t)return t.peek()}c.peekKey=u,c.peek=function(){return u(r.apply(null,arguments))};function d(e){return e?s.delete(e):!1}return c.forgetKey=d,c.forget=function(){return d(r.apply(null,arguments))},c.makeCacheKey=r,c.getKey=n?function(){return r.apply(null,n.apply(null,arguments))}:r,Object.freeze(c)}function ba(e){return{__ref:String(e)}}function xa(e){return e}function Sa(e){let t=e[0]||{},n=e.length;if(n>1){let r=new ui;for(let i=1;i<n;++i)t=r.merge(t,e[i])}return t}function Ca(...e){return Sa(e)}function wa(e,t){return U(e,t,t.variables&&{variables:U({...e&&e.variables,...t.variables})})}function Ta(e,t){return Ea(e,t)}function Ea(e,t,n=new Map){if(n.has(e))return n.get(e);let r=!1;if(Array.isArray(e)){let i=[];if(n.set(e,i),e.forEach((e,a)=>{let o=Ea(e,t,n);r||=o!==e,i[a]=o}),r)return i}else if(Di(e)){let i=Object.create(Object.getPrototypeOf(e));if(n.set(e,i),Object.keys(e).forEach(a=>{if(a===t){r=!0;return}let o=Ea(e[a],t,n);r||=o!==e[a],i[a]=o}),r)return i}return e}function Da(e){return e.catch(()=>{}),e}function Oa(e,t){B(t);let n=ka(``),r=ka(``),i=e=>{for(let t=0,i;t<e.length&&(i=e[t]);++t)if(!K(i)){if(i.kind===T.OPERATION_DEFINITION)return n(i.name&&i.name.value);if(i.kind===T.FRAGMENT_DEFINITION)return r(i.name.value)}return S.error(16),null},a=0;for(let e=t.definitions.length-1;e>=0;--e)t.definitions[e].kind===T.OPERATION_DEFINITION&&++a;let o=Aa(e),s=e=>Ei(e)&&e.map(o).some(e=>e&&e.remove),c=new Map,l=!1,u={enter(e){if(s(e.directives))return l=!0,null}},d=E(t,{Field:u,InlineFragment:u,VariableDefinition:{enter(){return!1}},Variable:{enter(e,t,n,r,a){let o=i(a);o&&o.variables.add(e.name.value)}},FragmentSpread:{enter(e,t,n,r,a){if(s(e.directives))return l=!0,null;let o=i(a);o&&o.fragmentSpreads.add(e.name.value)}},FragmentDefinition:{enter(e,t,n,r){c.set(JSON.stringify(r),e)},leave(e,t,n,i){if(e===c.get(JSON.stringify(i)))return e;if(a>0&&e.selectionSet.selections.every(e=>e.kind===T.FIELD&&e.name.value===`__typename`))return r(e.name.value).removed=!0,l=!0,null}},Directive:{leave(e){if(o(e))return l=!0,null}}});if(!l)return t;let f=e=>(e.transitiveVars||(e.transitiveVars=new Set(e.variables),e.removed||e.fragmentSpreads.forEach(t=>
45{f(r(t)).transitiveVars.forEach(t=>{e.transitiveVars.add(t)})})),e),p=new Set;d.definitions.forEach(e=>{e.kind===T.OPERATION_DEFINITION?f(n(e.name&&e.name.value)).fragmentSpreads.forEach(e=>{p.add(e)}):e.kind===T.FRAGMENT_DEFINITION&&a===0&&!r(e.name.value).removed&&p.add(e.name.value)}),p.forEach(e=>{f(r(e)).fragmentSpreads.forEach(e=>{p.add(e)})});let m=e=>!(p.has(e)&&!r(e).removed),h={enter(e){if(m(e.name.value))return null}};return Ma(E(d,{FragmentSpread:h,FragmentDefinition:h,OperationDefinition:{leave(e){if(e.variableDefinitions){let t=f(n(e.name&&e.name.value)).transitiveVars;if(t.size<e.variableDefinitions.length)return{...e,variableDefinitions:e.variableDefinitions.filter(e=>t.has(e.variable.name.value))}}}}}))}function ka(e){let t=new Map;return function(n=e){let r=t.get(n);return r||t.set(n,r={variables:new Set,fragmentSpreads:new Set}),r}}function Aa(e){let t=new Map,n=new Map;return e.forEach(e=>{e&&(e.name?t.set(e.name,e):e.test&&n.set(e.test,e))}),e=>{let r=t.get(e.name.value);return!r&&n.size&&n.forEach((t,n)=>{n(e)&&(r=t)}),r}}function ja(e,t){return!e||e.selectionSet.selections.every(e=>e.kind===T.FRAGMENT_SPREAD&&ja(t[e.name.value],t))}function Ma(e){return ja(V(e)||pi(e),Qr($r(e)))?null:e}function Na(e){return E(e,{FragmentSpread(e){if(!e.directives?.some(({name:e})=>e.value===`unmask`))return null}})}function Pa({directives:e},t){return!e||!e.length||Ia(e).every(({directive:e,ifArgument:n})=>{let r=!1;return n.value.kind===`Variable`?(r=t&&t[n.value.name.value],S(r!==void 0,17,e.name.value)):r=n.value.value,e.name.value===`skip`?!r:r})}function Fa({name:{value:e}}){return e===`skip`||e===`include`}function Ia(e){let t=[];return e&&e.length&&e.forEach(e=>{if(!Fa(e))return;let n=e.arguments,r=e.name.value;S(n&&n.length===1,18,r);let i=n[0];S(i.name&&i.name.value===`if`,19,r);let a=i.value;S(a&&(a.kind===`Variable`||a.kind===`BooleanValue`),20,r),t.push({directive:e,ifArgument:i})}),t}function La(e,t){let n=null;e.directives&&(n={},e.directives.forEach(e=>{n[e.name.value]={},e.arguments&&e.arguments.forEach(({name:r,value:i})=>Dr(n[e.name.value],r,i,t))}));let r=null;return e.arguments&&e.arguments.length&&(r={},e.arguments.forEach(({name:e,value:n})=>Dr(r,e,n,t))),bi(e.name.value,r,n)}function Ra(e){return`dataState`in e?e:{...e,dataState:e.complete?`complete`:e.result===null?`empty`:`partial`}}function za(e){let t={data:e.data};return e.error&&(t.error=e.error),t}function Ba(e,t=()=>void 0){return n=>new P(r=>{let i=t();return n.subscribe({next(t){let n;try{n=e(t,i)}catch(e){r.error(e)}n!==void 0&&r.next(n)},error(e){r.error(e)},complete(){r.complete()}})})}function Va(e,{data:t,...n},{data:r,...i},a){return w(n,i)&&Ha(ti(e).selectionSet,t,r,{fragmentMap:Qr($r(e)),variables:a})}function Ha(e,t,n,r){if(t===n)return!0;let i=new Set;return e.selections.every(e=>{if(i.has(e)||(i.add(e),!Pa(e,r.variables))||Ua(e))return!0;if(ni(e)){let i=H(e),a=t&&t[i],o=n&&n[i],s=e.selectionSet;if(!s)return w(a,o);let c=Array.isArray(a),l=Array.isArray(o);if(c!==l)return!1;if(c&&l){let e=a.length;if(o.length!==e)return!1;for(let t=0;t<e;++t)if(!Ha(s,a[t],o[t],r))return!1;return!0}return Ha(s,a,o,r)}{let i=ei(e,r.fragmentMap);if(i)return Ua(i)?!0:Ha(i.selectionSet,t,n,r)}})}function Ua(e){return!!e.directives&&e.directives.some(Wa)}function Wa(e){return e.name.value===`nonreactive`}function Ga(e,t){let n,r;function i(e){return e!==n&&(n=e,r=t(n)),r}return Object.assign(e.pipe(L(i),wr({bufferSize:1,refCount:!0})),{getCurrentResult:()=>i(e.getCurrentResult())})}var Ka=Xr(function(e,t,n){return Ga(e,n)},{max:1,makeCacheKey:e=>e.slice(0,2)}),qa=Symbol.for(`apollo.result.extensions`),Ja=Symbol.for(`apollo.result.streamInfo`),Ya=Symbol.for(`apollo.observableQuery.variablesUnknown`),Xa=Symbol.for(`apollo.cache.handleIncremental`);function Za(...e){return _a.bind(null,...e)}var Qa=class{isIncrementalResult(e){return!1}prepareRequest(e){return S(!Si([`defer`,`stream`],e.query),69),e}extractErrors(){}startRequest=void 0};function $a(e){return e}var eo=class e{transform;cached;resultCache=new WeakSet;getCacheKey(e){return[e]}static identity(){return new e($a,{cache:!1})}static split(t,n,r=e.identity()){return Object.assign(new e(e=>(t(e)?n:r).transformDocument(e),{cache:!1}),{left:n,right:r})}constructor(e,t={}){this.transform=e,t.getCacheKey&&(this.getCacheKey=t.getCacheKey),this.cached=t.cache!==!1,this.resetCache()}resetCache(){if(this.cached){let t=new z;this.performWork=ya(e.prototype.performWork.bind(this),{makeCacheKey:e=>{let n=this.getCacheKey(e);if(n)return S(Array.isArray(n),22),t.lookupArray(n)},max:R[`documentTransform.cache`],cache:Gr})}}performWork(e){return B(e),this.transform(e)}transformDocument(e){if(this.resultCache.has(e))return e;let t=this.performWork(e);return this.resultCache.add(t),t}concat(t){return Object.assign(new e(e=>t.transformDocument(this.transformDocument(e)),{cache:!1}),{left:this,right:t})}left;
45right},to,no=Object.assign(e=>{let t=to.get(e);return t||(t=at(e),to.set(e,t)),t},{reset(){to=new Jr(R.print||2e3)}});no.reset();function Y(e){return!!(e&&typeof e==`object`&&typeof e.__ref==`string`)}var ro={kind:T.FIELD,name:{kind:T.NAME,value:`__typename`}},io=Object.assign(function(e){return E(e,{SelectionSet:{enter(e,t,n){if(n&&n.kind===T.OPERATION_DEFINITION)return;let{selections:r}=e;if(!r||r.some(e=>e.kind===T.FIELD&&(e.name.value===`__typename`||e.name.value.lastIndexOf(`__`,0)===0)))return;let i=n;if(!(i.kind===T.FIELD&&i.directives&&i.directives.some(e=>e.name.value===`export`)))return{...e,selections:[...r,ro]}}}})},{added(e){return e===ro}});function ao(e,t){return V(e)?.operation===t}function oo(e){return ao(e,`mutation`)}function so(e){return ao(e,`subscription`)}function co(e=!1){return{keyArgs:e,read(e,{canRead:t,readField:n}){if(!e)return e;let r=[],i=``,a=``;e.edges.forEach(e=>{t(n(`node`,e))&&(r.push(e),e.cursor&&(i=i||e.cursor||``,a=e.cursor||a))}),r.length>1&&i===a&&(i=``);let{startCursor:o,endCursor:s}=e.pageInfo||{};return{...lo(e),edges:r,pageInfo:{...e.pageInfo,startCursor:o||i,endCursor:s||a}}},merge(e,t,{args:n,isReference:r,readField:i}){if(e||=fo(),!t)return e;let a=t.edges?t.edges.map(e=>(r(e={...e})&&(e.cursor=i(`cursor`,e)),e)):[];if(t.pageInfo){let{pageInfo:e}=t,{startCursor:n,endCursor:r}=e,i=a[0],o=a[a.length-1];i&&n&&(i.cursor=n),o&&r&&(o.cursor=r);let s=i&&i.cursor;s&&!n&&(t=Ca(t,{pageInfo:{startCursor:s}}));let c=o&&o.cursor;c&&!r&&(t=Ca(t,{pageInfo:{endCursor:c}}))}let o=e.edges,s=[];if(n&&n.after){let e=o.findIndex(e=>e.cursor===n.after);e>=0&&(o=o.slice(0,e+1))}else if(n&&n.before){let e=o.findIndex(e=>e.cursor===n.before);s=e<0?o:o.slice(e),o=[]}else t.edges&&(o=[]);let c=[...o,...a,...s],l={...t.pageInfo,...e.pageInfo};if(t.pageInfo){let{hasPreviousPage:e,hasNextPage:n,startCursor:r,endCursor:i,...a}=t.pageInfo;Object.assign(l,a),o.length||(e!==void 0&&(l.hasPreviousPage=e),r!==void 0&&(l.startCursor=r)),s.length||(n!==void 0&&(l.hasNextPage=n),i!==void 0&&(l.endCursor=i))}return{...lo(e),...lo(t),edges:c,pageInfo:l}}}}var lo=e=>ft(e,uo),uo=[`edges`,`pageInfo`];function fo(){return{edges:[],pageInfo:{hasPreviousPage:!1,hasNextPage:!0,startCursor:``,endCursor:``}}}function po(e){return Ta(e,`__typename`)}function mo(e){return e===7||e===8}function ho(e){return!mo(e)}function go(e,{client:t}){let n={query:e.query,variables:e.variables||{},extensions:e.extensions||{},operationName:jr(e.query),operationType:V(e.query).operation},r={...e.context},i=e=>{r=typeof e==`function`?{...r,...e(a())}:{...r,...e}},a=()=>Object.freeze({...r});return Object.defineProperty(n,"setContext",{enumerable:!1,value:i}),Object.defineProperty(n,"getContext",{enumerable:!1,value:a}),Object.defineProperty(n,"client",{enumerable:!1,value:t}),n}function _o(e,t){let n={...e},r=new Set(Object.keys(e));return E(t,{Variable(e,t,n){n&&n.kind!==`VariableDefinition`&&r.delete(e.name.value)}}),r.forEach(e=>{delete n[e]}),n}var X=class e{static empty(){return new e(()=>Cn)}static from(t){if(t.length===0)return e.empty();let[n,...r]=t;return n.concat(...r)}static split(t,n,r=new e((e,t)=>t(e))){let i=new e((e,i)=>t(e)?n.request(e,i):r.request(e,i));return Object.assign(i,{left:n,right:r})}static execute(e,t,n){return e.request(go(t,n),()=>Cn)}static concat(...t){return e.from(t)}constructor(e){e&&(this.request=e)}split(t,n,r){return this.concat(e.split(t,n,r))}concat(...e){return e.length===0?this:e.reduce(this.combine.bind(this),this)}combine(t,n){let r=new e((e,r)=>t.request(e,e=>n.request(e,r)));return Object.assign(r,{left:t,right:n})}request(e,t){throw C(67)}left;right},vo=X.execute,yo=class{assumeImmutableResults=!1;lookupFragment(e){return null}getRootTypename(e){return kr(e)}getScalar(e){}getScalarTypeForField(e,t){}configuresScalars(){return!1}serializeVariables(e,t){return t}batch(e){let t=typeof e.optimistic==`string`?e.optimistic:e.optimistic===!1?null:void 0,n;return this.performTransaction(()=>n=e.update(this),t),n}recordOptimisticTransaction(e,t){this.performTransaction(e,t)}transformDocument(e){return e}transformForLink(e){return e}identify(e){}gc(){return[]}modify(e){return!1}readQuery(e,t=!!e.optimistic){return this.read({...e,rootId:e.id||`ROOT_QUERY`,optimistic:t})}fragmentWatches=new z(!0);watchFragment(e){let{fragment:t,fragmentName:n,from:r}=e,i=this.getFragmentDoc(t,n),a=(Array.isArray(r)?r:[r]).map(e=>e==null?e:this.toCacheId(e));if(!Array.isArray(r)){let t=this.watchSingleFragment(a[0],i,e);return r===null?t:Ka(t,Symbol.for(`apollo.transform.individualResult`),e=>({...e,data:e.data??{}}))}let o;
45function s(e){let t=e.reduce((e,t,n)=>(e.data.push(t.data),e.complete&&=t.complete,e.dataState=e.complete?`complete`:`partial`,t.missing&&(e.missing||={},e.missing[n]=t.missing),e),{data:[],dataState:`complete`,complete:!0});return w(o,t)||(o=t),o}if(a.length===0)return Co;let c=!1,l=a.map(t=>this.watchSingleFragment(t,i,e)),u=oi(l).pipe(L(s),Tr({subscribe:()=>c=!0,unsubscribe:()=>c=!1}),wr({bufferSize:1,refCount:!0}));return Object.assign(u,{getCurrentResult:()=>c&&o?o:s(l.map(e=>e.getCurrentResult()))})}onAfterBroadcast=e=>e();watchSingleFragment(e,t,n){if(e===null)return xo;let{optimistic:r=!0,variables:i}=n,a=[t,G({id:e,optimistic:r,variables:i})],o=this.fragmentWatches.lookupArray(a);if(!o.observable){let s=!1,c;function l(e){let r=e.result;return(!c||!Va(t,{data:c.data},{data:r},n.variables))&&(c={data:r,dataState:e.complete?`complete`:`partial`,complete:e.complete},e.missing&&(c.missing=e.missing.missing)),c}let u=new P(n=>{s=!0;let o=this.watch({variables:i,returnPartialData:!0,id:e,query:t,optimistic:r,immediate:!0,callback:e=>{u.dirty=!0,this.onAfterBroadcast(()=>{n.next(l(e)),u.dirty=!1})}});return()=>{s=!1,o(),this.fragmentWatches.removeArray(a)}}).pipe(vr(),Sr({connector:()=>new on(1),resetOnRefCountZero:()=>hr(0)}));o.observable=Object.assign(u,{dirty:!1,getCurrentResult:()=>s&&c?c:l(this.diff({id:e,query:t,returnPartialData:!0,optimistic:r,variables:i}))})}return o.observable}getFragmentDoc=ya(fi,{max:R[`cache.fragmentQueryDocuments`]||1e3,cache:Gr,makeCacheKey:Za(this)});readFragment(e,t=!!e.optimistic){let n=e.from===void 0?e.id:this.toCacheId(e.from);return this.read({...e,query:this.getFragmentDoc(e.fragment,e.fragmentName),rootId:n,optimistic:t})}writeQuery({id:e,data:t,...n}){return this.write(Object.assign(n,{dataId:e||`ROOT_QUERY`,result:t}))}writeFragment({data:e,fragment:t,fragmentName:n,...r}){let i=r.from===void 0?r.id:this.toCacheId(r.from);return this.write(Object.assign(r,{query:this.getFragmentDoc(t,n),dataId:i,result:e}))}updateQuery(e,t){return this.batch({update(n){let r=n.readQuery(e),i=t(r);return i==null?r:(n.writeQuery({...e,data:i}),i)}})}updateFragment(e,t){return this.batch({update(n){let r=n.readFragment(e),i=t(r);return i==null?r:(n.writeFragment({...e,data:i}),i)}})}toCacheId(e){return typeof e==`string`?e:this.identify(e)}},bo=Object.freeze({data:null,dataState:`complete`,complete:!0}),xo=Object.assign(new P(e=>{e.next(bo)}),{dirty:!1,getCurrentResult:()=>bo}),So=Object.freeze({data:[],dataState:`complete`,complete:!0}),Co=Object.assign(new P(e=>{e.next(So)}),{getCurrentResult:()=>So}),wo=class e extends Error{message;path;query;variables;constructor(t,n,r,i){if(super(t),this.message=t,this.path=n,this.query=r,this.variables=i,this.name=`MissingFieldError`,Array.isArray(this.path)){this.missing=this.message;for(let e=this.path.length-1;e>=0;--e)this.missing={[this.path[e]]:this.missing}}else this.missing=this.path;this.__proto__=e.prototype}missing},{hasOwnProperty:Z}=Object.prototype;function To({__typename:e,id:t,_id:n},r){if(typeof e==`string`&&(r&&(r.keyObject=t==null?n==null?void 0:{_id:n}:{id:t}),t==null&&n!=null&&(t=n),t!=null))return`${e}:${typeof t==`number`||typeof t==`string`?t:JSON.stringify(t)}`}var Eo={dataIdFromObject:To,resultCaching:!0};function Do(e){return U(Eo,e)}var Oo=/^[_a-z][_0-9a-z]*/i;function ko(e){let t=e.match(Oo);return t?t[0]:e}function Ao(e,t,n){return W(t)?K(t)?t.every(t=>Ao(e,t,n)):e.selections.every(e=>{if(ni(e)&&Pa(e,n)){let r=H(e);return Z.call(t,r)&&(!e.selectionSet||Ao(e.selectionSet,t[r],n))}return!0}):!1}function jo(e){return W(e)&&!Y(e)&&!K(e)}function Mo(){return new ui}function No(e,t){let n=Qr($r(e));return{fragmentMap:n,lookupFragment(e){let r=n[e];return!r&&t&&(r=t.lookup(e)),r||null}}}function Po(e){switch(e.kind){case T.NAMED_TYPE:return e.name.value;case T.LIST_TYPE:return`[${Po(e.type)}]`;case T.NON_NULL_TYPE:return Po(e.type)}}var Fo={},Io=()=>Fo,Lo={},Ro=class{policies;group;data={};constructor(e,t){this.policies=e,this.group=t}toObject(){return{...this.data}}has(e){return this.lookup(e,!0)!==void 0}get(e,t){if(this.group.depend(e,t),Z.call(this.data,e)){let n=this.data[e];if(n&&Z.call(n,t))return n[t]}if(t===`__typename`&&Z.call(this.policies.rootTypenamesById,e))return this.policies.rootTypenamesById[e];if(this instanceof Ho)return this.parent.get(e,t)}lookup(e,t){if(t&&this.group.depend(e,`__exists`),Z.call(this.data,e))return this.data[e];if(this instanceof Ho)return this.parent.lookup(e,t);if(this.policies.rootTypenamesById[e])return{}}merge(e,t){let n;Y(e)&&(e=e.__ref),Y(t)&&(t=t.__ref);let r=typeof e==`string`?this.lookup(n=e):e,i=typeof t==`string`?this.lookup(n=t):t;if(!i)return;S(typeof n==`string`,108),i=this.coerceStoreObject(i,(e,t)=>e.coerceToParsed(t),i.__typename||r?.__typename||this.policies.rootTypenamesById[n]);let a=new ui({reconciler:Wo}).merge(r,i);if(this.data[n]=a,a!==r&&(delete this.refs[n],this.group.caching)){let e={};
45r||(e.__exists=1),Object.keys(i).forEach(t=>{if(!r||r[t]!==a[t]){e[t]=1;let n=ko(t);n!==t&&!this.policies.hasKeyArgs(a.__typename,n)&&(e[n]=1),a[t]===void 0&&!(this instanceof Ho)&&delete a[t]}}),e.__typename&&!(r&&r.__typename)&&this.policies.rootTypenamesById[n]===a.__typename&&delete e.__typename,Object.keys(e).forEach(e=>this.group.dirty(n,e))}}modify(e,t,n){let r=this.lookup(e);if(r){let i={},a=!1,o=!0,s={DELETE:Fo,INVALIDATE:Lo,isReference:Y,toReference:this.toReference,canRead:this.canRead,readField:(t,n)=>this.policies.readField(typeof t==`string`?{fieldName:t,from:n||ba(e)}:t,{store:this})};if(Object.keys(r).forEach(c=>{let l=ko(c),u=r[c];if(u===void 0)return;let d=typeof t==`function`?t:t[c]||(n?void 0:t[l]);if(d){let t=d===Io?Fo:d(xa(u),{...s,fieldName:l,storeFieldName:c,storage:this.getStorage(e,c)});t===Lo?this.group.dirty(e,c):(t===Fo&&(t=void 0),t!==u&&(i[c]=t,a=!0,u=t))}u!==void 0&&(o=!1)}),a)return this.merge(e,i),o&&(this instanceof Ho?this.data[e]=void 0:delete this.data[e],this.group.dirty(e,`__exists`)),!0}return!1}delete(e,t,n){let r=this.lookup(e);if(r){let i=this.getFieldValue(r,`__typename`),a=t&&n?this.policies.getStoreFieldName({typename:i,fieldName:t,args:n}):t;return this.modify(e,a?{[a]:Io}:Io,!!n)}return!1}evict(e,t){let n=!1;return e.id&&(Z.call(this.data,e.id)&&(n=this.delete(e.id,e.fieldName,e.args)),this instanceof Ho&&this!==t&&(n=this.parent.evict(e,t)||n),(e.fieldName||n)&&this.group.dirty(e.id,e.fieldName||`__exists`)),n}clear(){this.replace(null)}extract(){let e=this.toObject();this.hasScalarConfig()&&(e=Object.fromEntries(Object.entries(e).map(([e,t])=>[e,t&&this.coerceStoreObject(t,(e,t)=>e.coerceToSerialized(t),t?.__typename||this.policies.rootTypenamesById[e])])));let t=[];return this.getRootIdSet().forEach(e=>{Z.call(this.policies.rootTypenamesById,e)||t.push(e)}),t.length&&(e.__META={extraRootIds:t.sort()}),e}hasScalarConfig(){return!!this.policies.cache.config.scalars}coerceStoreObject(e,t,n=e.__typename){if(!n||!this.hasScalarConfig())return e;let r=!1,i=Object.entries(e).map(([e,i])=>{let a=ko(e),o=this.policies.getScalarTypeForField(n,a),s=this.coerceValue(i,t,o,`${n}.${a}`);return r||=s!==i,[e,s]});return r?Object.fromEntries(i):e}coerceValue(e,t,n,r){if(e==null)return e;if(n){let i=ri(n);if(i&&Array.isArray(e))return e.map(e=>this.coerceValue(e,t,i[1],r));let a=this.policies.cache.getScalar(ii(n));if(a)return t(a,e)}return Array.isArray(e)?e.map(e=>this.coerceValue(e,t,n,r)):Di(e)&&`__typename`in e?this.coerceStoreObject(e,t):e}replace(e){if(Object.keys(this.data).forEach(t=>{e&&Z.call(e,t)||this.delete(t)}),e){let{__META:t,...n}=e;Object.keys(n).forEach(e=>{this.merge(e,n[e])}),t&&t.extraRootIds.forEach(this.retain,this)}}rootIds={};retain(e){return this.rootIds[e]=(this.rootIds[e]||0)+1}release(e){if(this.rootIds[e]>0){let t=--this.rootIds[e];return t||delete this.rootIds[e],t}return 0}getRootIdSet(e=new Set){return Object.keys(this.rootIds).forEach(e.add,e),this instanceof Ho?this.parent.getRootIdSet(e):Object.keys(this.policies.rootTypenamesById).forEach(e.add,e),e}gc(){let e=this.getRootIdSet(),t=this.toObject();e.forEach(n=>{Z.call(t,n)&&(Object.keys(this.findChildRefIds(n)).forEach(e.add,e),delete t[n])});let n=Object.keys(t);if(n.length){let e=this;for(;e instanceof Ho;)e=e.parent;n.forEach(t=>e.delete(t))}return n}refs={};findChildRefIds(e){if(!Z.call(this.refs,e)){let t=this.refs[e]={},n=this.data[e];if(!n)return t;let r=new Set([n]);r.forEach(e=>{Y(e)&&(t[e.__ref]=!0),W(e)&&Object.keys(e).forEach(t=>{let n=e[t];W(n)&&r.add(n)})})}return this.refs[e]}makeCacheKey(){return this.group.keyMaker.lookupArray(arguments)}getFieldValue=(e,t)=>xa(Y(e)?this.get(e.__ref,t):e&&e[t]);canRead=e=>Y(e)?this.has(e.__ref):typeof e==`object`;toReference=(e,t)=>{if(typeof e==`string`)return ba(e);if(Y(e))return e;let[n]=this.policies.identify(e);if(n){let r=ba(n);return t&&this.merge(n,e),r}};get supportsResultCaching(){return this.group.caching}},zo=class{caching;parent;d=null;keyMaker;constructor(e,t=null){this.caching=e,this.parent=t,this.resetCaching()}resetCaching(){this.d=this.caching?ha():null,this.keyMaker=new z}depend(e,t){if(this.d){this.d(Bo(e,t));let n=ko(t);n!==t&&this.d(Bo(e,n)),this.parent&&this.parent.depend(e,t)}}dirty(e,t){this.d&&this.d.dirty(Bo(e,t),t===`__exists`?`forget`:`setDirty`)}};function Bo(e,t){return t+`#`+e}function Vo(e,t){Go(e)&&e.group.depend(t,`__exists`)}Ro.Root=class extends Ro{constructor({policies:e,resultCaching:t=!0,seed:n}){super(e,new zo(t)),n&&this.replace(n)}stump=new Uo(this);addLayer(e,t){return this.stump.addLayer(e,t)}removeLayer(){return this}storageTrie=new z;getStorage(){return this.storageTrie.lookupArray(arguments)}};var Ho=class e extends Ro{id;parent;replay;group;constructor(e,t,n,r){super(t.policies,r),this.id=e,this.parent=t,this.replay=n,this.group=r,n(this)}addLayer(t,n){return new e(t,this,n,this.group)}removeLayer(e){let t=this.parent.removeLayer(e);return e===this.id?(this.group.caching&&Object.keys(this.data).forEac
45h(e=>{let n=this.data[e],r=t.lookup(e);r?n?n!==r&&Object.keys(n).forEach(t=>{w(n[t],r[t])||this.group.dirty(e,t)}):(this.group.dirty(e,`__exists`),Object.keys(r).forEach(t=>{this.group.dirty(e,t)})):this.delete(e)}),t):t===this.parent?this:t.addLayer(this.id,this.replay)}toObject(){return{...this.parent.toObject(),...this.data}}findChildRefIds(e){let t=this.parent.findChildRefIds(e);return Z.call(this.data,e)?{...t,...super.findChildRefIds(e)}:t}getStorage(...e){let t=this.parent;for(;t.parent;)t=t.parent;return t.getStorage(...e)}},Uo=class extends Ho{constructor(e){super(`EntityStore.Stump`,e,()=>{},new zo(e.group.caching,e.group))}removeLayer(){return this}merge(e,t){return this.parent.merge(e,t)}};function Wo(e,t,n){let r=e[n],i=t[n];return w(r,i)?r:i}function Go(e){return!!(e&&e.supportsResultCaching)}var Ko=new Vi;function qo(e){let t=e.directives?.find(({name:e})=>e.value===`unmask`);if(!t)return`mask`;let n=t.arguments?.find(({name:e})=>e.value===`mode`);return n&&`value`in n.value&&n.value.value===`migrate`?`migrate`:`unmask`}function Jo(e,t,n){return Ko.withValue(!0,()=>{let r=Xo(e,t,n,!1);return Object.isFrozen(e),r})}function Yo(e,t){if(t.has(e))return t.get(e);let n=Array.isArray(e)?[]:{};return t.set(e,n),n}function Xo(e,t,n,r,i){let{knownChanged:a}=n,o=Yo(e,n.mutableTargets);if(Array.isArray(e)){for(let[i,s]of Array.from(e.entries())){if(s===null){o[i]=null;continue}let e=Xo(s,t,n,r,void 0);a.has(e)&&a.add(o),o[i]=e}return a.has(o)?o:e}for(let s of t.selections){let t;if(r&&a.add(o),s.kind===T.FIELD){let i=H(s),c=s.selectionSet;if(t=o[i]||e[i],t===void 0)continue;if(c&&t!==null){let o=Xo(e[i],c,n,r,void 0);a.has(o)&&(t=o)}o[i]=t}if(s.kind===T.INLINE_FRAGMENT&&(!s.typeCondition||n.cache.fragmentMatches(s,e.__typename))&&(t=Xo(e,s.selectionSet,n,r,i)),s.kind===T.FRAGMENT_SPREAD){let r=s.name.value,a=n.fragmentMap[r]||(n.fragmentMap[r]=n.cache.lookupFragment(r));S(a,41,r);let o=qo(s);o!==`mask`&&(t=Xo(e,a.selectionSet,n,o===`migrate`,i))}a.has(t)&&a.add(o)}return`__typename`in e&&!(`__typename`in o)&&(o.__typename=e.__typename),Object.keys(o).length!==Object.keys(e).length&&a.add(o),a.has(o)?o:e}function Zo(e,t,n,r){let i=t.definitions.filter(e=>e.kind===T.FRAGMENT_DEFINITION);r===void 0&&(S(i.length===1,43,i.length),r=i[0].name.value);let a=i.find(e=>e.name.value===r);return S(!!a,44,r),e==null||w(e,{})?e:Jo(e,a.selectionSet,{operationType:`fragment`,operationName:a.name.value,fragmentMap:Qr($r(t)),cache:n,mutableTargets:new WeakMap,knownChanged:new WeakSet})}function Qo(e,t,n){let r=V(t);return S(r,45),e==null?e:Jo(e,r.selectionSet,{operationType:r.operation,operationName:r.name?.value,fragmentMap:Qr($r(t)),cache:n,mutableTargets:new WeakMap,knownChanged:new WeakSet})}var $o={};function es(e){let t=JSON.stringify(e);return $o[t]||($o[t]={})}function ts(e){let t=es(e);return t.keyFieldsFn||=(t,n)=>{let r=(e,t)=>n.readField(t,e),i=n.keyObject=rs(e,e=>{let i=os(n.storeObject,e,r);return i===void 0&&t!==n.storeObject&&Z.call(t,e[0])&&(i=os(t,e,as)),S(i!==void 0,113,e.join(`.`),t),i});return`${n.typename}:${JSON.stringify(i)}`}}function ns(e){let t=es(e);return t.keyArgsFn||=(t,{field:n,variables:r,fieldName:i})=>{let a=rs(e,e=>{let i=e[0],a=i.charAt(0);if(a===`@`){if(n&&Ei(n.directives)){let t=i.slice(1),a=n.directives.find(e=>e.name.value===t),o=a&&Or(a,r);return o&&os(o,e.slice(1))}return}if(a===`$`){let t=i.slice(1);if(r&&Z.call(r,t)){let n=e.slice(0);return n[0]=t,os(r,n)}return}if(t)return os(t,e)}),o=JSON.stringify(a);return(t||o!==`{}`)&&(i+=`:`+o),i}}function rs(e,t){let n=new ui;return is(e).reduce((e,r)=>{let i=t(r);if(i!==void 0){for(let e=r.length-1;e>=0;--e)i={[r[e]]:i};e=n.merge(e,i)}return e},{})}function is(e){let t=es(e);if(!t.paths){let n=t.paths=[],r=[];e.forEach((t,i)=>{K(t)?(is(t).forEach(e=>n.push(r.concat(e))),r.length=0):(r.push(t),K(e[i+1])||(n.push(r.slice(0)),r.length=0))})}return t.paths}function as(e,t){return e[t]}function os(e,t,n){return n||=as,ss(t.reduce(function e(t,r){return K(t)?t.map(t=>e(t,r)):t&&n(t,r)},e))}function ss(e){return W(e)?K(e)?e.map(ss):rs(Object.keys(e).sort(),t=>os(e,t)):e}var cs=new Vi,ls=new WeakMap;function us(e){let t=ls.get(e);return t||ls.set(e,t={vars:new Set,dep:ha()}),t}
45function ds(e){us(e).vars.forEach(t=>t.forgetCache(e))}function fs(e){us(e).vars.forEach(t=>t.attachCache(e))}function ps(e){let t=new Set,n=new Set,r=function(a){if(arguments.length>0){if(e!==a){e=a,t.forEach(e=>{us(e).dep.dirty(r),ms(e)});let i=Array.from(n);n.clear(),i.forEach(t=>t(e))}}else{let e=cs.getValue();e&&(i(e),us(e).dep(r))}return e};r.onNextChange=e=>(n.add(e),()=>{n.delete(e)});let i=r.attachCache=e=>(t.add(e),us(e).vars.add(r),r);return r.forgetCache=e=>t.delete(e),r}function ms(e){e.broadcastWatches&&e.broadcastWatches()}function hs(e){return e.args===void 0?e.field?Or(e.field,e.variables):null:e.args}var gs=()=>void 0,_s=(e,t)=>t.fieldName,vs=(e,t,{mergeObjects:n})=>n(e,t),ys=(e,t)=>t,bs=(e,t,{streamFieldInfo:n,existingData:r})=>{if(!e&&!r)return t;let i=[],a=e??r,o=n?.isLastChunk?t.length:Math.max(a.length,t.length);for(let e=0;e<o;e++)i[e]=t[e]===void 0?a[e]:t[e];return i},xs=class{config;typePolicies={};toBeAdded={};supertypeMap=new Map;fuzzySubtypes=new Map;cache;rootIdsByTypename={};rootTypenamesById={};usingPossibleTypes=!1;constructor(e){this.config=e,this.config={dataIdFromObject:To,...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)}identify(e,t){let n=this,r=t&&(t.typename||t.storeObject?.__typename)||e.__typename;if(r===this.rootTypenamesById.ROOT_QUERY)return[`ROOT_QUERY`];let i=t&&t.storeObject||e,a={...t,typename:r,storeObject:i,readField:t&&t.readField||((...e)=>{let t=ws(e,i);return n.readField(t,{store:n.cache.data,variables:t.variables})})},o,s=r&&this.getTypePolicy(r),c=s&&s.keyFn||this.config.dataIdFromObject;return Ko.withValue(!0,()=>{for(;c;){let t=c({...e,...i},a);if(K(t))c=ts(t);else{o=t;break}}}),o=o?String(o):void 0,a.keyObject?[o,a.keyObject]:[o]}addTypePolicies(e){Object.keys(e).forEach(t=>{let{queryType:n,mutationType:r,subscriptionType:i,...a}=e[t];n&&this.setRootTypename(`Query`,t),r&&this.setRootTypename(`Mutation`,t),i&&this.setRootTypename(`Subscription`,t),Z.call(this.toBeAdded,t)?this.toBeAdded[t].push(a):this.toBeAdded[t]=[a]})}updateTypePolicy(e,t,n){let r=this.getTypePolicy(e),{keyFields:i,fields:a}=t;function o(e,t){e.merge=typeof t==`function`?t:t===!0?vs:t===!1?ys:e.merge}o(r,t.merge),r.keyFn=i===!1?gs:K(i)?ts(i):typeof i==`function`?i:r.keyFn,a&&Object.keys(a).forEach(t=>{let r=n[t];(!r||r?.typename!==e)&&(r=n[t]={typename:e});let i=a[t];if(typeof i==`function`)r.scalar||(r.read=i);else{let{keyArgs:e,read:t,merge:n,scalar:a}=i;a&&(r.scalar=a),r.scalar&&(r.read=t=void 0,r.merge=n=void 0),r.keyFn=e===!1?_s:K(e)?ns(e):typeof e==`function`?e:r.keyFn,typeof t==`function`&&(r.read=t),o(r,n)}r.read&&r.merge&&(r.keyFn=r.keyFn||_s)})}setRootTypename(e,t=e){let n=`ROOT_`+e.toUpperCase(),r=this.rootTypenamesById[n];t!==r&&(S(!r||r===e,114,e),r&&delete this.rootIdsByTypename[r],this.rootIdsByTypename[t]=n,this.rootTypenamesById[n]=t)}addPossibleTypes(e){this.usingPossibleTypes=!0,Object.keys(e).forEach(t=>{this.getSupertypeSet(t,!0),e[t].forEach(e=>{this.getSupertypeSet(e,!0).add(t);let n=e.match(Oo);(!n||n[0]!==e)&&this.fuzzySubtypes.set(e,new RegExp(e))})})}getTypePolicy(e){if(!Z.call(this.typePolicies,e)){let t=this.typePolicies[e]={};t.fields={};let n=this.supertypeMap.get(e);!n&&this.fuzzySubtypes.size&&(n=this.getSupertypeSet(e,!0),this.fuzzySubtypes.forEach((t,r)=>{if(t.test(e)){let e=this.supertypeMap.get(r);e&&e.forEach(e=>n.add(e))}})),n&&n.size&&n.forEach(e=>{let{fields:n,...r}=this.getTypePolicy(e);Object.assign(t,r),Object.assign(t.fields,n)})}let t=this.toBeAdded[e];return t&&t.length&&t.splice(0).forEach(t=>{this.updateTypePolicy(e,t,this.typePolicies[e].fields)}),this.typePolicies[e]}getFieldPolicy(e,t){if(e)return this.getTypePolicy(e).fields[t]}getSupertypeSet(e,t){let n=this.supertypeMap.get(e);return!n&&t&&this.supertypeMap.set(e,n=new Set),n}fragmentMatches(e,t,n,r){if(!e.typeCondition)return!0;if(!t)return!1;let i=e.typeCondition.name.value;if(t===i)return!0;if(this.usingPossibleTypes&&this.supertypeMap.has(i)){let a=this.getSupertypeSet(t,!0),o=[a],s=e=>{let t=this.getSupertypeSet(e,!1);t&&t.size&&o.indexOf(t)<0&&o.push(t)},c=!!(n&&this.fuzzySubtypes.size);for(let l=0;l<o.length;++l){let u=o[l];if(u.has(i))return a.has(i)||a.add(i),!0;u.forEach(s),c&&l===o.length-1&&Ao(e.selectionSet,n,r)&&(c=!1,this.fuzzySubtypes.forEac
45h((e,n)=>{let r=t.match(e);r&&r[0]===t&&s(n)}))}}return!1}hasKeyArgs(e,t){let n=this.getFieldPolicy(e,t);return!!(n&&n.keyFn)}getStoreFieldName(e){let{typename:t,fieldName:n}=e,r=this.getFieldPolicy(t,n),i,a=r&&r.keyFn;if(a&&t){let r={typename:t,fieldName:n,field:e.field||null,variables:e.variables},o=hs(e);for(;a;){let e=a(o,r);if(K(e))a=ns(e);else{i=e||n;break}}}return i===void 0&&(i=e.field?La(e.field,e.variables):bi(n,hs(e))),i===!1?n:n===ko(i)?i:n+`:`+i}getScalarTypeForField(e,t){return this.getFieldPolicy(e,t)?.scalar}readField(e,t){let n=e.from;if(!n||!(e.field||e.fieldName))return;if(e.typename===void 0){let r=t.store.getFieldValue(n,`__typename`);r&&(e.typename=r)}let r=this.getStoreFieldName(e),i=ko(r),a=t.store.getFieldValue(n,r),o=this.getFieldPolicy(e.typename,i),s=o&&o.read;if(s){let i=Ss(this,n,e,t,t.store.getStorage(Y(n)?n.__ref:n,r));return cs.withValue(this.cache,s,[a,i])}return a}getReadFunction(e,t){let n=this.getFieldPolicy(e,t);return n&&n.read}getMergeFunction(e,t,n){let r=this.getFieldPolicy(e,t),i=r&&r.merge;return!i&&n&&(r=this.getTypePolicy(n),i=r&&r.merge),i}runMergeFunction(e,t,{field:n,typename:r,merge:i,path:a},o,s){let c=e;if(i===vs)return Ts(o.store)(e,t);if(i===ys)return t;o.overwrite&&(e=void 0);let l=o.extensions?.[Ja]?.deref()?.peekArray(a);if(l){let{current:e,previous:n}=l;if(n&&w(n.incoming,t)&&w(n.streamFieldInfo,e))return n.result}let u=i(e,t,Cs(this,void 0,{typename:r,fieldName:n.name.value,field:n,variables:o.variables,path:a},o,s||{},c));return l&&(l.previous={incoming:t,streamFieldInfo:l.current,result:u}),u}};function Ss(e,t,n,r,i){let a=e.getStoreFieldName(n),o=ko(a),s=n.variables||r.variables,{toReference:c,canRead:l}=r.store;return{args:hs(n),field:n.field||null,fieldName:o,storeFieldName:a,variables:s,isReference:Y,toReference:c,storage:i,cache:e.cache,canRead:l,readField(...n){return e.readField(ws(n,t,s),r)},mergeObjects:Ts(r.store)}}function Cs(e,t,n,r,i,a){let o={...Ss(e,t,n,r,i),extensions:r.extensions,existingData:a},s=r.extensions;if(s&&Ja in s){let{[Ja]:e,...t}=s,r=e?.deref()?.peekArray(n.path);r&&(o.streamFieldInfo=r.current),o.extensions=Object.keys(t).length===0?void 0:t}return o}function ws(e,t,n){let{0:r,1:i,length:a}=e,o;return typeof r==`string`?o={fieldName:r,from:a>1?i:t}:(o={...r},Z.call(o,`from`)||(o.from=t)),o.variables===void 0&&(o.variables=n),o}function Ts(e){return function(t,n){if(K(t)||K(n))throw C(117);if(W(t)&&W(n)){let r=e.getFieldValue(t,`__typename`),i=e.getFieldValue(n,`__typename`);if(r&&i&&r!==i)return n;if(Y(t)&&jo(n))return e.merge(t.__ref,n),t;if(jo(t)&&Y(n))return e.merge(t,n.__ref),n;if(jo(t)&&jo(n))return{...t,...n}}return n}}function Es(e){return[e.selectionSet,e.objectOrReference,e.context]}var Ds=class{executeSelectionSet;executeSubSelectedArray;prunePartialStreamArray;prunePartialBoundaries;config;knownResults=new WeakMap;keyMaker=new z;constructor(e){this.config=e,this.executeSelectionSet=ya(e=>{let t=Es(e);return this.executeSelectionSet.peek(...t)||(Vo(e.context.store,e.enclosingRef.__ref),this.execSelectionSetImpl(e))},{max:R[`inMemoryCache.executeSelectionSet`]||5e4,keyArgs:Es,makeCacheKey(e,t,n){if(Go(n.store))return n.store.makeCacheKey(e,Y(t)?t.__ref:t,n.varString)}}),this.executeSubSelectedArray=ya(e=>(Vo(e.context.store,e.enclosingRef.__ref),this.execSubSelectedArrayImpl(e)),{max:R[`inMemoryCache.executeSubSelectedArray`]||1e4,makeCacheKey({field:e,array:t,context:n}){if(Go(n.store))return n.store.makeCacheKey(e,t,n.varString)}}),this.prunePartialBoundaries=ya(e=>this.prunePartialBoundariesImpl(e),{max:R[`inMemoryCache.prunePartialBoundaries`]||2e4,makeCacheKey:({boundaries:e,context:t,selectionSet:n})=>{if(Go(t.store))return this.keyMaker.lookup(n,e,t.streamInfo,t.deferInfo)}}),this.prunePartialStreamArray=ya(e=>{let{field:t,context:n,path:r}=e;return Oi(t,n.variables)&&n.streamInfo?.lookupArray(r).state.depend(),this.prunePartialStreamArrayImpl(e)},{max:R[`inMemoryCache.prunePartialStreamArray`]||2e4,makeCacheKey:({field:e,context:t,boundaries:n})=>{if(Go(t.store))return this.keyMaker.lookup(e,n,t.streamInfo,t.deferInfo)}})}diffQueryAgainstStore({store:e,query:t,rootId:n=`ROOT_QUERY`,variables:r,returnPartialData:i=!0,...a}){let o=Object.hasOwn(a,Xa),s=this.config.cache.policies;r=U(di(mi(t)),r);let c=ba(n),l={store:e,query:t,policies:s,variables:r,varString:G(r),...No(t,this.config.fragments),...a[Xa]},u=this.executeSelectionSet({selectionSet:ti(t).selectionSet,objectOrReference:c,enclosingRef:c,context:l});if(o&&As(u,l)){let e=this.prunePartialBoundaries({selectionSet:ti(t).selectionSet,data:u.result,boundaries:u.partialBoundaries,context:l,path:[]});(u.result===e.result||!i)&&(u={result:e.result,partialBoundaries:u.partialBoundaries,dataState:e.dataState})}let{result:d,dataState:f,missing:p}
45=u,m=!!p&&(f!==`streaming`||!o);f===`streaming`&&Object.keys(d).length===0&&(f=`empty`);let h;(f===`deferPartial`||f===`streamPartial`||f===`streaming`&&!o)&&(f=`partial`),f===`partial`&&!i&&(f=`empty`);let g=f===`complete`,_={result:g||f===`streaming`||i&&Object.keys(d).length?d:null,complete:g,get missing(){return m&&(h||=new wo(Os(p),p,t,r)),h}};return o&&(_.dataState=f),_}isFresh(e,t,n,r){if(Go(r.store)&&this.knownResults.get(e)===n){let i=this.executeSelectionSet.peek(n,t,r);if(i&&e===i.result)return!0}return!1}execSelectionSetImpl({selectionSet:e,objectOrReference:t,enclosingRef:n,context:r}){if(Y(t)&&!r.policies.rootTypenamesById[t.__ref]&&!r.store.has(t.__ref))return{result:{},dataState:`empty`,missing:`Dangling reference to missing ${t.__ref} object`,partialBoundaries:new ks};let{variables:i,policies:a,store:o}=r,s=o.getFieldValue(t,`__typename`),c=[],l,u,d=new ui,f=new ks;typeof s==`string`&&!a.rootIdsByTypename[s]&&c.push({__typename:s});function p(e,t){return e.missing&&(u=d.merge(u,{[t]:e.missing})),e}new Set(e.selections).forEach(e=>{if(Pa(e,i)){if(ni(e)){let i=a.readField({fieldName:e.name.value,field:e,variables:r.variables,from:t},r),o=H(e);if(i===void 0){if(!io.added(e)){let n=Y(t)?t.__ref:t?a.identify(t)[0]:void 0;u=d.merge(u,{[o]:`Can't find field '${e.name.value}' on ${n?`${n} object`:`object ${JSON.stringify(t||{},null,2)}`}`}),l=Q(l,`empty`)}}else if(K(i)){if(i.length>0){let t=p(this.executeSubSelectedArray({field:e,array:i,enclosingRef:n,context:r}),o);i=t.result,l=Q(l,t.dataState),f.set(o,t.partialBoundaries)}else l=Q(l,`complete`)}else if(!e.selectionSet)io.added(e)||(l=Q(l,`complete`));else if(i!=null){let t=p(this.executeSelectionSet({selectionSet:e.selectionSet,objectOrReference:i,enclosingRef:Y(i)?i:n,context:r}),o);i=t.result,f.set(o,t.partialBoundaries),l=Q(l,t.dataState===`empty`?`partial`:t.dataState)}i!==void 0&&c.push({[o]:i})}else{let i=ei(e,r.lookupFragment);if(!i&&e.kind===T.FRAGMENT_SPREAD)throw C(120,e.name.value);if(i&&a.fragmentMatches(i,s)){let a=wi(e,r.variables),o=this.execSelectionSetImpl({selectionSet:i.selectionSet,objectOrReference:t,enclosingRef:n,context:r}),{result:s,dataState:p}=o;f.merge(o.partialBoundaries),s!==void 0&&c.push(s),o.missing&&(u=d.merge(u,o.missing)),a&&(p===`partial`||p===`empty`)&&f.add(e),l=Q(l,a?p===`empty`?`streaming`:p===`partial`?`deferPartial`:p:p)}}}}),l||=`complete`;let m=xa({result:Sa(c),missing:u,dataState:l,partialBoundaries:f});return m.result&&this.knownResults.set(m.result,e),m}execSubSelectedArrayImpl({field:e,array:t,enclosingRef:n,context:r}){let i=`complete`,a,o=new ui,s=new ks,c=Oi(e,r.variables);function l(e,t){return e.missing&&(a=o.merge(a,{[t]:e.missing})),e.result}return e.selectionSet&&(t=t.filter(e=>e===void 0||r.store.canRead(e))),t=t.map((t,a)=>{if(t===null)return null;let o;if(K(t)?o=this.executeSubSelectedArray({field:e,array:t,enclosingRef:n,context:r}):e.selectionSet&&(o=this.executeSelectionSet({selectionSet:e.selectionSet,objectOrReference:t,enclosingRef:Y(t)?t:n,context:r})),o){let{dataState:t}=o;return s.set(a,t===`partial`?o.partialBoundaries.clone().add(e):o.partialBoundaries),i=Q(i,c&&t===`partial`?`streamPartial`:t),l(o,a)}return t}),{result:t,dataState:i,missing:a,partialBoundaries:s}}prunePartialBoundariesImpl({boundaries:e,context:t,data:n,path:r,selectionSet:i}){let{variables:a,lookupFragment:o,policies:s}=t;if(n==null||!e)return{result:n,dataState:`complete`};let c=new ui,l=!1,u=`complete`,d={};Object.hasOwn(n,`__typename`)&&(d.__typename=n.__typename);let f=new Set(i.selections);return f.forEach(i=>{if(!Pa(i,a))return;if(ni(i)){let a=H(i);if(!Object.hasOwn(n,a))return;let o=n[a];if(Array.isArray(o)){let n=this.prunePartialStreamArray({field:i,array:o,boundaries:e.getChild(a),context:t,path:r.concat(a)});l||=n.result!==o,d[a]=n.result,u=Q(u,n.dataState)}else if(!i.selectionSet)d[a]=o;else{let n=this.prunePartialBoundaries({data:o,selectionSet:i.selectionSet,boundaries:e.getChild(a),context:t,path:r.concat(a)});l||=n.result!==o,u=Q(u,n.dataState),d[a]=Object.hasOwn(d,a)?c.merge(d[a],n.result):n.result}return}let p=ei(i,o),m=!1;if(t.deferInfo&&wi(i,a)){let e=i.directives?.find(e=>e.name.value===`defer`),n=e&&Er(e,`label`,T.STRING);m=!!t.deferInfo.peekArray(r.concat(n||[]))}p&&s.fragmentMatches(p,n.__typename)&&(e.has(i)||m?u=Q(u,`streaming`):p.selectionSet.selections.forEach(f.add,f))}),Object.keys(d).length===Object.keys(n).length?l&&e.hasSelections()&&(l=!w(d,n)):l=!0,{result:l?d:n,dataState:u}}prunePartialStreamArrayImpl({field:e,array:t,boundaries:n,context:r,path:i}){if(!n)return{result:t,dataState:`complete`};let a=!1,o=`complete`,s=[],c=r.streamInfo?.peekArray(i)?.state,l=Math.min(t.length,c?.truncate?c.streamPosition:2**53-1);for(let u=0;u<l;u++){let l=t[u],d={result:l,dataState:`complete`};if(n.getChild(u)?.has(e)){c?(c.truncate=!0,s=s.slice(0,c.streamPosition)):(s=[],o=`complete`);break}Array.isArray(l)?d=this.prunePartialStreamArray({field:e,array:l,boundaries:n.getChild(u),context:r,path:i.concat(u)}):e.selectionSet&&(d=this.prunePartialBoundaries({data:l,selectionSet:e.selectionSet,boundaries:n.getChild(u),context:r,path:i.concat(u)})),s.push(d.result),a||=d.result!==l,o=Q(o,d.dataState)}return a||=s.length!==t.length,{result:a?s:t,dataState:o}}};function Os(e){try{JSON.stringify(e,(e,t)=>{if(typeof t==`string`)throw t;return t})}catch(e){return e}}var ks=class e{selections=new Set;children=new Map;add(e){return this.selections.add(e),this}has(e){return this.selections.has(e)}hasSelections(){return this.selections.size>0}getChild(e){return this.children.get(e)}clone(){return new e().merge(this)}set(e,t){let n=this.getChild(e);this.children.set(e,n?n.clone().merge(t):t)}
45merge(e){return e.selections.forEach(e=>this.add(e)),e.children.forEach((e,t)=>this.set(t,e)),this}};function As({dataState:e},t){return e===`deferPartial`||e===`streamPartial`?!0:e===`complete`||e===`streaming`?!!(t.streamInfo||t.deferInfo):!1}var js={empty:{complete:`partial`,deferPartial:`partial`,streaming:`partial`,streamPartial:`partial`},deferPartial:{empty:`partial`},streamPartial:{deferPartial:`deferPartial`,empty:`partial`},streaming:{deferPartial:`deferPartial`,empty:`partial`,streamPartial:`streamPartial`},complete:{deferPartial:`deferPartial`,streaming:`streaming`,streamPartial:`streamPartial`,empty:`partial`},partial:{}};function Q(e,t){return t===`partial`?`partial`:!e||e===t?t:js[e][t]||e}function Ms(e,t,n){let r=`${t}${n}`,i=e.flavors.get(r);return i||e.flavors.set(r,i=e.clientOnly===t&&e.deferred===n?e:{...e,clientOnly:t,deferred:n}),i}var Ns=class{cache;reader;fragments;constructor(e,t,n){this.cache=e,this.reader=t,this.fragments=n}writeToStore(e,{query:t,result:n,dataId:r,variables:i,overwrite:a,extensions:o}){let s=V(t),c=Mo();i={...di(s),...i};let l={store:e,written:{}
45,merge(e,t){return c.merge(e,t)},variables:i,varString:G(i),...No(t,this.fragments),overwrite:!!a,incomingById:new Map,clientOnly:!1,deferred:!1,flavors:new Map,extensions:o},u=this.processSelectionSet({result:n||{},dataId:r,selectionSet:s.selectionSet,mergeTree:{map:new Map},context:l,path:[]});if(!Y(u))throw C(122,n);return l.incomingById.forEach(({storeObject:t,mergeTree:n,fieldNodeSet:r},i)=>{let a=ba(i);if(n&&n.map.size){let e=this.applyMerges(n,a,t,l);if(Y(e))return;t=e}e.merge(i,t)}),e.retain(u.__ref),u}processSelectionSet({dataId:e,result:t,selectionSet:n,context:r,mergeTree:i,path:a}){let{policies:o}=this.cache,s={},c=e&&o.rootTypenamesById[e]||zs(t,n,r.fragmentMap)||e&&r.store.get(e,`__typename`);typeof c==`string`&&(s.__typename=c);let l=(...e)=>{let t=ws(e,s,r.variables);if(Y(t.from)){let e=r.incomingById.get(t.from.__ref);if(e){let n=o.readField({...t,from:e.storeObject},r);if(n!==void 0)return n}}return o.readField(t,r)},u=new Set;this.flattenFields(n,t,r,c).forEach((e,n)=>{let r=t[H(n)],d=[...a,n.name.value];if(u.add(n),r!==void 0){let t=o.getStoreFieldName({typename:c,fieldName:n.name.value,field:n,variables:e.variables}),a=Fs(i,t),u=this.processFieldValue(r,n,n.selectionSet?Ms(e,!1,!1):e,a,d),f;n.selectionSet&&(Y(u)||jo(u))&&(f=l(`__typename`,u));let p=o.getMergeFunction(c,n.name.value,f);p?a.info={field:n,typename:c,merge:p,path:d}:e.extensions?.[Ja]&&Array.isArray(u)&&Oi(n,e.variables)?a.info={field:n,typename:c,merge:bs,path:d}:Rs(i,t),s=e.merge(s,{[t]:u})}});try{let[i,a]=o.identify(t,{typename:c,selectionSet:n,fragmentMap:r.fragmentMap,storeObject:s,readField:l});e||=i,a&&(s=r.merge(s,a))}catch(t){if(!e)throw t}if(typeof e==`string`){let a=ba(e),o=r.written[e]||(r.written[e]=[]);if(o.indexOf(n)>=0||(o.push(n),this.reader&&this.reader.isFresh(t,a,n,r)))return a;let c=r.incomingById.get(e);return c?(c.storeObject=r.merge(c.storeObject,s),c.mergeTree=Is(c.mergeTree,i),u.forEach(e=>c.fieldNodeSet.add(e))):r.incomingById.set(e,{storeObject:s,mergeTree:Ls(i)?void 0:i,fieldNodeSet:u}),a}return s}processFieldValue(e,t,n,r,i){return!t.selectionSet||e===null?e:K(e)?e.map((e,a)=>{let o=this.processFieldValue(e,t,n,Fs(r,a),[...i,a]);return Rs(r,a),o}):this.processSelectionSet({result:e,selectionSet:t.selectionSet,context:n,mergeTree:r,path:i})}flattenFields(e,t,n,r=zs(t,e,n.fragmentMap)){let i=new Map,{policies:a}=this.cache,o=new z(!1);return(function e(s,c){let l=o.lookup(s,c.clientOnly,c.deferred);l.visited||(l.visited=!0,s.selections.forEach(o=>{if(!Pa(o,n.variables))return;let{clientOnly:s,deferred:l}=c;if(!(s&&l)&&Ei(o.directives)&&o.directives.forEach(e=>{let t=e.name.value;if(t===`client`&&(s=!0),t===`defer`){let t=Or(e,n.variables);(!t||t.if!==!1)&&(l=!0)}}),ni(o)){let e=i.get(o);e&&(s&&=e.clientOnly,l&&=e.deferred),i.set(o,Ms(n,s,l))}else{let i=ei(o,n.lookupFragment);if(!i&&o.kind===T.FRAGMENT_SPREAD)throw C(124,o.name.value);i&&a.fragmentMatches(i,r,t,n.variables)&&e(i.selectionSet,Ms(n,s,l))}}))})(e,n),i}applyMerges(e,t,n,r,i){if(e.map.size&&!Y(n)){let a=!K(n)&&(Y(t)||jo(t))?t:void 0,o=n;a&&!i&&(i=[Y(a)?a.__ref:a]);let s,c=(e,t)=>K(e)?typeof t==`number`?e[t]:void 0:r.store.getFieldValue(e,String(t));e.map.forEach((e,t)=>{let n=c(a,t),l=c(o,t);if(l===void 0)return;i&&i.push(t);let u=this.applyMerges(e,n,l,r,i);u!==l&&(s||=new Map,s.set(t,u)),i&&S(i.pop()===t)}),s&&(n=K(o)?o.slice(0):{...o},s.forEach((e,t)=>{n[t]=e}))}return e.info?this.cache.policies.runMergeFunction(t,n,e.info,r,i&&r.store.getStorage(...i)):n}},Ps=[];function Fs({map:e},t){return e.has(t)||e.set(t,Ps.pop()||{map:new Map}),e.get(t)}function Is(e,t){if(e===t||!t||Ls(t))return e;if(!e||Ls(e))return t;let n=e.info&&t.info?{...e.info,...t.info}:e.info||t.info,r=e.map.size&&t.map.size,i={info:n,map:r?new Map:e.map.size?e.map:t.map};if(r){let n=new Set(t.map.keys());e.map.forEach((e,r)=>{i.map.set(r,Is(e,t.map.get(r))),n.delete(r)}),n.forEach(n=>{i.map.set(n,Is(t.map.get(n),e.map.get(n)))})}return i}function Ls(e){return!e||!(e.info||e.map.size)}function Rs({map:e},t){let n=e.get(t);n&&Ls(n)&&(Ps.push(n),e.delete(t))}function zs(e,t,n){let r;for(let n of t.selections)if(ni(n)){if(n.name.value===`__typename`)return e[H(n)]}else r?r.push(n):r=[n];if(typeof e.__typename==`string`)return e.__typename;if(r)for(let t of r){let r=zs(e,ei(t,n).selectionSet,n);if(typeof r==`string`)return r}}var Bs=class extends yo{data;optimisticData;config;watches=new Set;storeReader;storeWriter;addTypenameTransform=new eo(io);maybeBroadcastWatch;assumeImmutableResults=!0;policies;makeVar=ps;constructor(...e){super(),this.config=Do(e[0]??{}),this.policies=new xs({cache:this,dataIdFromObject:this.config.dataIdFromObject,possibleTypes:this.config.possibleTypes,typePolicies:this.config.typePolicies}),this.init()}init(){let e=this.data=new Ro.Root({policies:this.policies,resultCaching:this.config.resultCaching});this.optimisticData=e.stump,this.resetResultCache()}resetResultCache(){let{fragments:e}=this.config;this.addTypenameTransform.resetCache(),e?.resetCaches(),this.storeWriter=new Ns(this,this.storeReader=new Ds({cache:this,fragments:e}),e),this.maybeBroadcastWatch=ya((e,t)=>this.broadcastWatch(e,t),{max:R[`inMemoryCache.maybeBroadcastWatch`]||5e3,makeCacheKey:e=>{let t=e.optimistic?this.optimisticData:this.data;if(Go(t)){let{optimistic:n,id:r,variables:i}=e;return t.makeCacheKey(e.query,e.callback,G({optimistic:n,id:r,variables:i}))}}}
45),new Set([this.data.group,this.optimisticData.group]).forEach(e=>e.resetCaching())}getRootTypename(e){return this.policies.rootTypenamesById[`ROOT_${e.toUpperCase()}`]}getScalar(e){return this.config.scalars?.[e]}getScalarTypeForField(e,t){return this.policies.getScalarTypeForField(e,t)}configuresScalars(){return!!this.config.scalars}serializeVariables(e,t){if(!t||Object.keys(t).length===0||!this.config.scalars&&!this.config.inputObjects)return t;let n=V(e)?.variableDefinitions?.reduce((e,t)=>(e[t.variable.name.value]=Po(t.type),e),{});return!n||Object.keys(n).length===0?t:this.serializeVariablesValue(t,n)}serializeVariablesValue(e,t,n,r){if(e==null)return e;if(n){let i=ri(n);if(i&&Array.isArray(e))return this.serializeInputArray(e,t,i[1],r);let a=this.getScalar(ii(n));if(a)return a.coerceToSerialized(e)}return Array.isArray(e)?this.serializeInputArray(e,t,void 0,r):Di(e)?this.serializeInputObject(e,t,r):e}serializeInputArray(e,t,n,r){let i=!1,a=e.map(e=>{let a=this.serializeVariablesValue(e,t,n,r);return i||=a!==e,a});return i?a:e}serializeInputObject(e,t,n){let r=!1,i=Object.entries(e).map(([e,i])=>{let a=t[e],o=n?`${n}.${e}`:e;if(!a)return[e,i];let s=this.config.inputObjects?.[ii(a)];if(s){let t=this.serializeVariablesValue(i,s.fields,void 0,o);return r||=t!==i,[e,t]}let c=this.serializeVariablesValue(i,t,a,o);return r||=c!==i,[e,c]});return r?Object.fromEntries(i):e}restore(e){return this.init(),e&&this.data.replace(e),this}extract(e=!1){return(e?this.optimisticData:this.data).extract()}read(e){let{query:t,variables:n,returnPartialData:r=!1}=e;return this.storeReader.diffQueryAgainstStore({...e,variables:this.serializeVariables(t,n),store:e.optimistic?this.optimisticData:this.data,config:this.config,returnPartialData:r}).result}write(e){let{query:t,variables:n}=e;try{return++this.txCount,this.storeWriter.writeToStore(this.data,{...e,variables:this.serializeVariables(t,n)})}finally{!--this.txCount&&e.broadcast!==!1&&this.broadcastWatches()}}modify(e){if(Z.call(e,`id`)&&!e.id)return!1;let t=e.optimistic?this.optimisticData:this.data;try{return++this.txCount,t.modify(e.id||`ROOT_QUERY`,e.fields,!1)}finally{!--this.txCount&&e.broadcast!==!1&&this.broadcastWatches()}}diff(e){let{variables:t}=e;return this.storeReader.diffQueryAgainstStore({...e,variables:this.serializeVariables(e.query,t),store:e.optimistic?this.optimisticData:this.data,rootId:e.id||`ROOT_QUERY`,config:this.config})}watch(e){return this.watches.size||fs(this),this.watches.add(e),e.immediate&&this.maybeBroadcastWatch(e),()=>{this.watches.delete(e)&&!this.watches.size&&ds(this),this.maybeBroadcastWatch.forget(e)}}gc(e){G.reset(),no.reset();let t=this.optimisticData.gc();return e&&!this.txCount&&e.resetResultCache&&this.resetResultCache(),t}retain(e,t){return(t?this.optimisticData:this.data).retain(e)}release(e,t){return(t?this.optimisticData:this.data).release(e)}identify(e){if(Y(e))return e.__ref;try{return this.policies.identify(e)[0]}catch{}}evict(e){if(!e.id){if(Z.call(e,`id`))return!1;e={...e,id:`ROOT_QUERY`}}try{return++this.txCount,this.optimisticData.evict(e,this.data)}finally{!--this.txCount&&e.broadcast!==!1&&this.broadcastWatches()}}reset(e){return this.init(),G.reset(),e&&e.discardWatches?(this.watches.forEach(e=>this.maybeBroadcastWatch.forget(e)),this.watches.clear(),ds(this)):this.broadcastWatches(),Promise.resolve()}removeOptimistic(e){let t=this.optimisticData.removeLayer(e);t!==this.optimisticData&&(this.optimisticData=t,this.broadcastWatches())}txCount=0;batch(e){let{update:t,optimistic:n=!0,removeOptimistic:r,onWatchUpdated:i}=e,a,o=e=>{let{data:n,optimisticData:r}=this;++this.txCount,e&&(this.data=this.optimisticData=e);try{return a=t(this)}finally{--this.txCount,this.data=n,this.optimisticData=r}},s=new Set;return i&&!this.txCount&&this.broadcastWatches({...e,onWatchUpdated(e){return s.add(e),!1}}),typeof n==`string`?this.optimisticData=this.optimisticData.addLayer(n,o):n===!1?o(this.data):o(),typeof r==`string`&&(this.optimisticData=this.optimisticData.removeLayer(r)),i&&s.size?(this.broadcastWatches({...e,onWatchUpdated(e,t){let n=i.call(this,e,t);return n!==!1&&s.delete(e),n}}
45),s.size&&s.forEach(e=>this.maybeBroadcastWatch.dirty(e))):this.broadcastWatches(e),a}performTransaction(e,t){return this.batch({update:e,optimistic:t||t!==null})}transformDocument(e){return this.addTypenameTransform.transformDocument(this.addFragmentsToDocument(e))}fragmentMatches(e,t){return this.policies.fragmentMatches(e,t)}lookupFragment(e){return this.config.fragments?.lookup(e)||null}resolvesClientField(e,t){return!!this.policies.getReadFunction(e,t)}broadcastWatches(e){if(!this.txCount){let t=this.onAfterBroadcast,n=new Set;this.onAfterBroadcast=e=>{n.add(e)};try{this.watches.forEach(t=>this.maybeBroadcastWatch(t,e)),n.forEach(e=>e())}finally{this.onAfterBroadcast=t}}}addFragmentsToDocument(e){let{fragments:t}=this.config;return t?t.transform(e):e}broadcastWatch(e,t){let{lastDiff:n}=e,r=this.diff(e);t&&(e.optimistic&&typeof t.optimistic==`string`&&(r.fromOptimisticTransaction=!0),t.onWatchUpdated&&t.onWatchUpdated.call(this,e,r,n)===!1)||(!n||!w(n.result,r.result))&&e.callback(e.lastDiff=r,n)}},Vs=new WeakMap,$;(function(e){e[e.loading=1]=`loading`,e[e.setVariables=2]=`setVariables`,e[e.fetchMore=3]=`fetchMore`,e[e.refetch=4]=`refetch`,e[e.poll=6]=`poll`,e[e.ready=7]=`ready`,e[e.error=8]=`error`,e[e.streaming=9]=`streaming`})($||={});var{assign:Hs,hasOwnProperty:Us}=Object,Ws={loading:!0,networkStatus:$.loading,data:void 0,dataState:`empty`,partial:!0},Gs={loading:!1,networkStatus:$.ready,data:void 0,dataState:`empty`,partial:!0},Ks=new WeakMap;function qs(e,t){let n=e[t];typeof n==`function`&&(e[t]=function(){return Ks.set(e,(Ks.get(e)+1)%0x38d7ea4c68000),n.apply(this,arguments)})}var Js=class{options;queryName;variablesUnknown=!1;didWarnOnFeud=!1;lastMissing;get query(){return this.lastQuery}get variables(){return this.options.variables}unsubscribeFromCache;input;subject;isTornDown;queryManager;subscriptions=new Set;waitForNetworkResult;lastQuery;linkSubscription;pollingInfo;get networkStatus(){return this.subject.getValue().result.networkStatus}get cache(){return this.queryManager.cache}constructor({queryManager:e,options:t,transformedQuery:n=e.transform(t.query)}){this.queryManager=e;let{cache:r}=e;Ks.has(r)||(Ks.set(r,0),qs(r,`evict`),qs(r,`modify`),qs(r,`reset`)),this.waitForNetworkResult=t.fetchPolicy===`network-only`,this.isTornDown=!1,this.subscribeToMore=this.subscribeToMore.bind(this),this.maskResult=this.maskResult.bind(this);let{watchQuery:{fetchPolicy:i=`cache-first`}={}}=e.defaultOptions,{fetchPolicy:a=i,initialFetchPolicy:o=a===`standby`?i:a}=t;t[Ya]&&(S(a===`standby`,84),this.variablesUnknown=!0),this.lastQuery=n,this.options={...t,initialFetchPolicy:o,fetchPolicy:a,variables:this.getVariablesWithDefaults(t.variables)},this.initializeObservablesQueue(),this[`@@observable`]=()=>this,Symbol.observable&&(this[Symbol.observable]=()=>this);let s=V(this.query);this.queryName=s&&s.name&&s.name.value}initializeObservablesQueue(){this.subject=new rn({query:this.query,variables:this.variables,result:Ws,meta:{}});let e=this.subject.pipe(Tr({subscribe:()=>{this.subject.observed||(this.reobserve(),setTimeout(()=>this.updatePolling()))},unsubscribe:()=>{this.subject.observed||this.tearDownQuery()}}),Ba(({query:e,variables:t,result:n,meta:r},i)=>{let{shouldEmit:a}=r;if(n===Ws&&(i.previous=void 0,i.previousVariables=void 0),this.options.fetchPolicy===`standby`||a===2)return;if(a===1)return c();let{previous:o,previousVariables:s}=i;if(o){let r=this.queryManager.getDocumentInfo(e),i=this.queryManager.dataMasking,a=i?r.nonReactiveQuery:e;if((i||r.hasNonreactiveDirective?Va(a,o,n,t):w(o,n))&&w(s,t))return}return a===3&&(!this.options.notifyOnNetworkStatusChange||w(o,n))?void 0:c();function c(){return i.previous=n,i.previousVariables=t,n}},()=>({})));this.pipe=e.pipe.bind(e),this.subscribe=e.subscribe.bind(e),this.input=new tn,this.input.complete=()=>{},this.input.pipe(this.operator).subscribe(this.subject)}subscribe;pipe;[Symbol.observable];"@@observable";getCacheDiff({optimistic:e=!0}={}){return Ra(this.cache.diff({query:this.query,variables:this.variables,returnPartialData:!0,optimistic:e,[Xa]:void 0}))}getInitialResult(e){let t=e||this.options.fetchPolicy;this.queryManager.prioritizeCacheValues&&(t===`network-only`||t===`cache-and-network`)&&(t=`cache-first`);let n=()=>{let e=this.getCacheDiff(),{dataState:t}=e,n=this.options.returnPartialData||e.complete?e.result??void 0:void 0;return n===void 0&&(t=`empty`),this.maskResult({data:n,dataState:t,loading:!e.complete,networkStatus:e.complete?$.ready:$.loading,partial:!e.complete})};switch(t){case`cache-only`:return{...n(),loading:!1,networkStatus:$.ready};case`cache-first`:return n();case`cache-and-network`:return{...n(),loading:!0,networkStatus:$.loading};case`standby`:return Gs;default:return Ws}}resubscribeCache(){let{variables:e,fetchPolicy:t}=this.options,n=this.query,r=t===`standby`||t===`no-cache`||this.waitForNetworkResult,i=!Ys({query:n,variables:e},this.unsubscribeFromCache)&&!this.waitForNetworkResult;if((r||i)&&this.unsubscribeFromCache?.(),r||!i)return;let a={query:n,variables:e,optimistic:!0,watcher:this,callback:e=>{let t=this.queryManager.getDocumentInfo(n);
45if((t.hasClientExports||t.hasForcedResolvers)&&(a.lastDiff=void 0),a.lastOwnDiff===e)return;let{result:r}=this.subject.getValue();(e.complete||!r.error&&r!==Ws&&r!==Gs)&&(w(r.data,e.result)||this.scheduleNotify())}},o=this.cache.watch(a);this.unsubscribeFromCache=Object.assign(()=>{this.unsubscribeFromCache=void 0,o()},{query:n,variables:e})}stableLastResult;getCurrentResult(){let{result:e}=this.subject.getValue(),t=e.networkStatus===$.error||this.hasObservers()||this.options.fetchPolicy===`no-cache`?e:this.getInitialResult();return t===Ws&&(t=this.getInitialResult()),w(this.stableLastResult,t)||(this.stableLastResult=t),this.stableLastResult}refetch(e){let{fetchPolicy:t}=this.options,n={pollInterval:0};return n.fetchPolicy=t===`no-cache`?`no-cache`:`network-only`,e&&!w(this.variables,e)&&(n.variables=this.options.variables=this.getVariablesWithDefaults({...this.variables,...e})),this._reobserve(n,{newNetworkStatus:$.refetch})}fetchMore({query:e,variables:t,context:n,errorPolicy:r,updateQuery:i}){S(this.options.fetchPolicy!==`cache-only`,86,jr(this.query,`(anonymous)`));let a={...U(this.options,{errorPolicy:`none`},{query:e,context:n,errorPolicy:r}),variables:e?t:{...this.variables,...t},fetchPolicy:`no-cache`,notifyOnNetworkStatusChange:this.options.notifyOnNetworkStatusChange};a.query=this.transformDocument(a.query),this.lastQuery=e?this.transformDocument(this.options.query):a.query;let o=!1,s=this.options.fetchPolicy!==`no-cache`;s||S(i,87);let{finalize:c,pushNotification:l}=this.pushOperation($.fetchMore);l({source:`newNetworkStatus`,kind:`N`,value:{}},{shouldEmit:3});let{promise:u,operator:d}=Xs(),{observable:f}=this.queryManager.fetchObservableWithInfo(a,{networkStatus:$.fetchMore,exposeExtensions:!0}),p=f.pipe(d,gr(e=>e.kind===`N`&&e.source===`network`)).subscribe({next:e=>{o=!1;let t=e.value,n=t[qa];if(mo(e.value.networkStatus)&&c(),s){let e=this.getCacheDiff();this.cache.batch({update:e=>{i?e.updateQuery({query:this.query,variables:this.variables,returnPartialData:!0,optimistic:!1,extensions:n},e=>i(e,{fetchMoreResult:t.data,variables:a.variables})):e.writeQuery({query:a.query,variables:a.variables,data:t.data,extensions:n})},onWatchUpdated:(n,r)=>{if(n.watcher===this&&!w(r.result,e.result)){o=!0;let e=this.getCurrentResult();ho(t.networkStatus)&&l({kind:`N`,source:`network`,value:{...e,networkStatus:t.networkStatus===$.error?$.ready:t.networkStatus,loading:!1,data:r.result,dataState:r.complete?`complete`:`streaming`}})}}})}else{let e=this.getCurrentResult(),n=i(e.data,{fetchMoreResult:t.data,variables:a.variables});l({kind:`N`,value:{...e,networkStatus:$.ready,loading:!1,data:n,dataState:e.dataState===`streaming`?`streaming`:`complete`},source:`network`})}}});return Da(u.then(e=>za(this.maskResult(e))).finally(()=>{if(p.unsubscribe(),c(),s&&!o){let e=this.getCurrentResult();e.dataState===`streaming`?l({kind:`N`,source:`network`,value:{...e,dataState:`complete`,networkStatus:$.ready}}):l({kind:`N`,source:`newNetworkStatus`,value:{}},{shouldEmit:1})}}))}subscribeToMore(e){let t=this.queryManager.startGraphQLSubscription({query:e.document,variables:e.variables,context:e.context}).subscribe({next:t=>{let{updateQuery:n,onError:r}=e,{error:i}=t;if(i){r?r(i):S.error(88,i);return}n&&this.updateQuery((e,r)=>n(e,{subscriptionData:t,...r}))}});return this.subscriptions.add(t),()=>{this.subscriptions.delete(t)&&t.unsubscribe()}}applyOptions(e){let t=U(this.options,e||{});Hs(this.options,t),this.updatePolling()}async setVariables(e){return e=this.getVariablesWithDefaults(e),w(this.variables,e)||(this.options.variables=e,!this.hasObservers())?za(this.getCurrentResult()):this._reobserve({fetchPolicy:this.options.initialFetchPolicy,variables:e},{newNetworkStatus:$.setVariables})}updateQuery(e){let{queryManager:t}=this,{result:n,complete:r}=this.getCacheDiff({optimistic:!1}),i=e(n,{variables:this.variables,complete:!!r,previousData:n});i&&(this.cache.writeQuery({query:this.options.query,data:i,variables:this.variables}),t.broadcastQueries())}startPolling(e){this.options.pollInterval=e,this.updatePolling()}stopPolling(){this.options.pollInterval=0,this.updatePolling()}applyNextFetchPolicy(e,t){if(t.nextFetchPolicy){let{fetchPolicy:n=`cache-first`,initialFetchPolicy:r=n}=t;n===`standby`||(t.fetchPolicy=typeof t.nextFetchPolicy==`function`?t.nextFetchPolicy.call(t,n,{reason:e,options:t,observable:this,initialFetchPolicy:r}):e===`variables-changed`?r:t.nextFetchPolicy)}return t.fetchPolicy}fetch(e,t,n,r){let i=this.options.fetchPolicy;e.context??={};let a=!1,{observable:o,fromLink:s}=this.queryManager.fetchObservableWithInfo(e,{networkStatus:t,query:n,onCacheHit:()=>{a=!0},fetchQueryOperator:e=>new P(n=>{try{return e.subscribe({next(e){a=!0,n.next(e)},error:e=>n.error(e),complete:()=>n.complete()})}finally{a||(u.override=t,this.input.next({kind:`N`,source:`newNetworkStatus`,value:{resetError:!0},query:c,variables:l,meta:{shouldEmit:3,fetchPolicy:i}}))}}),observableQuery:this}),{query:c,variables:l}=this,u={abort:()=>{f.unsubscribe()},query:c,variables:l};this.activeOperations.add(u);let d=t==$.refetch||t==$.setVariables;o=o.pipe(r,Sr());let f=o.pipe(Tr({next:e=>{e.source===`newNetworkStatus`||e.kind===`N`&&e.value.loading?u.override=t:delete u.override},finalize:()=>this.activeOperations.delete(u)})).subscribe({next:e=>{let t={};d&&e.kind===`N`&&`loading`in e.value&&!e.value.loading&&(d=!1,t.shouldEmit=1),this.input.next({...e,query:c,variables:l,meta:t})}});return{fromLink:s,subscription:f,observable:o}}didWarnCacheOnlyPolling=!1;updatePolling(){if(this.queryManager.ssrMode)return;let{pollingInfo:e,options:{fetchPolicy:t,pollInterval:n}}=this,r=()=>{let{options:e}=this;return!e.pollInterval||!this.hasObservers()||e.fetchPolicy===`cache-only`||e.fetchPolicy===`standby`};
45if(r()){this.cancelPolling();return}if(e?.interval===n)return;let i=e||(this.pollingInfo={});i.interval=n;let a=()=>{if(r())return this.cancelPolling();this.pollingInfo&&(!ho(this.networkStatus)&&!this.options.skipPollAttempt?.()?this._reobserve({fetchPolicy:this.options.initialFetchPolicy===`no-cache`?`no-cache`:`network-only`},{newNetworkStatus:$.poll}).then(o,o):o())},o=()=>{let e=this.pollingInfo;e&&(clearTimeout(e.timeout),e.timeout=setTimeout(a,e.interval))};o()}cancelPolling(){this.pollingInfo&&(clearTimeout(this.pollingInfo.timeout),delete this.pollingInfo)}reobserve(e){return this._reobserve(e)}_reobserve(e,t){this.isTornDown=!1;let{newNetworkStatus:n,keepLastMissing:r}=t||{};r||(this.lastMissing=void 0),this.queryManager.obsQueries.add(this);let i=n===$.refetch||n===$.poll,a=this.variables,o=this.options.fetchPolicy,s=U(this.options,e||{});this.variablesUnknown&&=s.fetchPolicy===`standby`;let c=i?s:Hs(this.options,s),l=this.transformDocument(c.query);this.lastQuery=l,e&&`variables`in e&&(c.variables=this.getVariablesWithDefaults(e.variables)),i||(this.updatePolling(),e&&e.variables&&!w(e.variables,a)&&c.fetchPolicy!==`standby`&&(c.fetchPolicy===o||typeof c.nextFetchPolicy==`function`)&&(this.applyNextFetchPolicy(`variables-changed`,c),n===void 0&&(n=$.setVariables)));let u=this.networkStatus;n||(n=$.loading,u!==$.loading&&e?.variables&&!w(e.variables,a)&&(n=$.setVariables),c.fetchPolicy===`standby`&&(n=$.ready)),c.fetchPolicy===`standby`&&this.cancelPolling(),this.resubscribeCache();let{promise:d,operator:f}=Xs(c.fetchPolicy===`standby`?{data:void 0}:void 0),{subscription:p,observable:m,fromLink:h}=this.fetch(c,n,l,f);!i&&(h||!this.linkSubscription)&&(this.linkSubscription&&this.linkSubscription.unsubscribe(),this.linkSubscription=p);let g=Object.assign(Da(d.then(e=>za(this.maskResult(e))).finally(()=>{!this.hasObservers()&&this.activeOperations.size===0&&this.tearDownQuery()})),{retain:()=>{let e=m.subscribe({}),t=()=>e.unsubscribe();return d.then(t,t),g}});return g}hasObservers(){return this.subject.observed}stop(){this.subject.complete(),this.initializeObservablesQueue(),this.tearDownQuery()}tearDownQuery(){this.isTornDown||(this.resetNotifications(),this.unsubscribeFromCache?.(),this.linkSubscription&&(this.linkSubscription.unsubscribe(),delete this.linkSubscription),this.stopPolling(),this.subscriptions.forEach(e=>e.unsubscribe()),this.subscriptions.clear(),this.queryManager.obsQueries.delete(this),this.isTornDown=!0,this.abortActiveOperations(),this.lastMissing=void 0)}transformDocument(e){return this.queryManager.transform(e)}maskResult(e){let t=this.queryManager.maskOperation({document:this.query,data:e.data,fetchPolicy:this.options.fetchPolicy,cause:this});return t===e.data?e:{...e,data:t}}dirty=!1;notifyTimeout;resetNotifications(){this.notifyTimeout&&=(clearTimeout(this.notifyTimeout),void 0),this.dirty=!1}scheduleNotify(){this.dirty||(this.dirty=!0,this.notifyTimeout||=setTimeout(()=>this.notify(!0),0))}notify(e=!1){if(!e){let e=this.queryManager.getDocumentInfo(this.query);if(e.hasClientExports||e.hasForcedResolvers)return}let{dirty:t,lastMissing:n}=this,{fetchPolicy:r}=this.options;if(this.resetNotifications(),!t||r!==`cache-only`&&r!==`cache-and-network`&&this.activeOperations.size)return;let i=this.getCacheDiff(),a=this.getCurrentResult();if(!w(i.result,this.getCacheDiff({optimistic:!1}).result)||!i.complete&&a.networkStatus===$.streaming){this.deliverCacheDiff(i);return}if(i.complete)this.lastMissing=void 0;else if(!n||n.dmCount!==Ks.get(this.cache)||!w(n.variables,this.variables)||!w(n.missing,i.missing?.missing))this.didWarnOnFeud=!1,this.lastMissing={variables:this.variables,missing:i.missing?.missing,dmCount:Ks.get(this.cache)};else if(r!==`cache-only`){a.dataState===`partial`&&this.deliverCacheDiff(i);return}this.reobserveCacheFirst()}deliverCacheDiff(e){let t=this.getCurrentResult();this.input.next({kind:`N`,value:{data:e.result,dataState:e.dataState,networkStatus:t.networkStatus,loading:t.loading,error:void 0,partial:!e.complete},source:`cache`,query:this.query,variables:this.variables,meta:{}})}activeOperations=new Set;pushOperation(e){let t=!1,{query:n,variables:r}=this,i=()=>{this.activeOperations.delete(a)},a={override:e,abort:()=>{t=!0,i()},query:n,variables:r};return this.activeOperations.add(a),{finalize:i,pushNotification:(e,i)=>{t||this.input.next({...e,query:n,variables:r,meta:{...i}})}}}calculateNetworkStatus(e){return e===$.streaming?e:Array.from(this.activeOperations.values()).reverse().find(e=>Ys(e,this)&&e.override!==void 0)?.override??e}
45abortActiveOperations(){this.activeOperations.forEach(e=>e.abort())}reset(){let e=this.options.fetchPolicy===`cache-only`;this.lastMissing=void 0,this.setResult(e?Gs:Ws,{shouldEmit:e?1:2}),this.abortActiveOperations()}setResult(e,t){this.input.next({source:`setResult`,kind:`N`,value:e,query:this.query,variables:this.variables,meta:{...t}})}operator=Ba(e=>{let{query:t,meta:n}=e;if(e.source===`setResult`)return{query:t,variables:this.variables,result:e.value,meta:n};if(e.kind===`C`)return;let r=`resolvedVariables`in e?e.resolvedVariables:void 0;if(e.query!==this.query)return;if(!w(r,this.variables)){if(!w(e.variables,this.variables))return;r&&(this.options.variables=r,this.resubscribeCache())}let i=this.variables,a,o=this.subject.getValue();if(e.source===`cache`){if(a=e.value,a.networkStatus===$.ready&&a.dataState===`partial`&&(!this.options.returnPartialData||o.result.networkStatus===$.error)&&this.options.fetchPolicy!==`cache-only`)return}else if(e.source===`network`)this.waitForNetworkResult&&(this.waitForNetworkResult=!1,this.resubscribeCache()),a=e.kind===`E`?{...Ys(o,e)||r&&w(r,o.variables)?o.result:{data:void 0,dataState:`empty`,partial:!0},error:e.error,networkStatus:$.error,loading:!1}:e.value,e.kind===`E`&&a.dataState===`streaming`&&(a.dataState=Vs.get(e.error)??`complete`),a.error&&(n.shouldEmit=1);else if(e.source===`newNetworkStatus`){let t=Ys(o,e)?o.result:this.getInitialResult(n.fetchPolicy),{resetError:r}=e.value,i=r?void 0:t.error,s=i?$.error:$.ready;a={...t,error:i,networkStatus:s}}return S(a),a.error||delete a.error,a.networkStatus=this.calculateNetworkStatus(a.networkStatus),a.loading=ho(a.networkStatus),a=this.maskResult(a),o.result.data!==void 0&&a.data!==o.result.data&&w(a.data,o.result.data)&&(a.data=o.result.data),{query:t,variables:i,result:a,meta:n}});reobserveCacheFirst(){let{fetchPolicy:e,nextFetchPolicy:t}=this.options;e===`cache-and-network`||e===`network-only`?this._reobserve({fetchPolicy:`cache-first`,nextFetchPolicy(n,r){return this.nextFetchPolicy=t,typeof this.nextFetchPolicy==`function`?this.nextFetchPolicy(n,r):e}},{keepLastMissing:!0}):this._reobserve(void 0,{keepLastMissing:!0})}getVariablesWithDefaults(e){return this.queryManager.getVariables(this.query,e)}};function Ys(e,t){return!!(e&&t&&e.query===t.query&&w(e.variables,t.variables))}function Xs(e){let t=e,n,r;return{promise:new Promise((e,t)=>{n=e,r=t}),operator:Tr({next(e){if(e.kind===`E`)return r(e.error);e.kind===`N`&&e.source!==`newNetworkStatus`&&!e.value.loading&&(t=e.value)},finalize:()=>{if(t)n(t);else{let e=`The operation was aborted.`,t=`AbortError`;r(typeof DOMException<`u`?new DOMException(e,t):Object.assign(Error(e),{name:t}))}}})}}var Zs={},Qs=new WeakMap,$s=class{cache;queryManager;id;observableQuery;incremental;constructor(e,t){this.cache=e.cache;let n=(Qs.get(e)||0)+1;Qs.set(e,n),this.id=n+``,this.observableQuery=t,this.queryManager=e}get hasNext(){return this.incremental?this.incremental.hasNext:!1}get incrementalHandler(){return this.queryManager.incrementalHandler}maybeHandleIncrementalResult(e,t,n){return this.incrementalHandler.isIncrementalResult(t)?(this.incremental||=this.incrementalHandler.startRequest({query:n}),this.incremental.handle(e,t)):t}markQueryResult(e,{document:t,variables:n,errorPolicy:r,cacheWriteBehavior:i,returnPartialData:a,fetchPolicy:o,networkStatus:s,prunePendingDeferFragments:c}){let l={query:t,variables:n,optimistic:!0};this.observableQuery?.resetNotifications();let u=i===0,d=u?void 0:this.getDiff({...l,returnPartialData:r!==`none`||!this.incrementalHandler.extractErrors(e)?.length},this.getIncrementalInfo({prune:c})),f=this.maybeHandleIncrementalResult(d?.result,e,t),p={...f,dataState:f.data==null?`empty`:`complete`};return(this.incremental?.getPendingWithInfo?.().some(e=>e.type===`defer`&&!e.delivered)||!this.incremental?.getPendingWithInfo&&this.hasNext&&Si([`defer`],t))&&(p.dataState=`streaming`),u||!ec(p,r)||this.cache.batch({onWatchUpdated:(e,t)=>{e.watcher===this.observableQuery&&(e.lastOwnDiff=t)}
45,update:e=>{e.writeQuery({query:t,data:p.data,variables:n,overwrite:i===1,extensions:p.extensions});let{dataState:r,result:u}=this.getDiff({...l,returnPartialData:a&&(o!==`network-only`||s===$.refetch)},this.getIncrementalInfo({prune:c}));(r===`complete`||r===`streaming`||a&&r===`partial`)&&(p={...p,data:u,dataState:r})}}),p}getIncrementalInfo({prune:e}){let t=this.incremental?.getPendingWithInfo?.()??[],n=this.incremental?.streamInfo,r={streamInfo:n};if(e)for(let e of t)e.type===`defer`&&!e.delivered?(r.deferInfo||=new z(!0,()=>!0),r.deferInfo.lookupArray(e.path.concat(e.label||[]))):n&&e.type===`stream`&&(n.lookupArray(e.path).state.truncate=!0);return r}getDiff(e,t){return Ra(this.cache.diff({...e,[Xa]:t}))}markMutationResult(e,t,n=this.cache){let r=[],i=t.cacheWriteBehavior===0,a=this.maybeHandleIncrementalResult(i?void 0:n.diff({id:`ROOT_MUTATION`,query:this.queryManager.getDocumentInfo(t.document).asQuery,variables:t.variables,optimistic:!1,returnPartialData:!0}).result,e,t.document);if(t.errorPolicy===`ignore`&&(a={...a,errors:[]}),xi(a)&&t.errorPolicy===`none`)return Promise.resolve(a);let o=()=>({...a,dataState:this.hasNext?`streaming`:`complete`});if(!i&&ec(a,t.errorPolicy)){r.push({result:a.data,dataId:`ROOT_MUTATION`,query:t.document,variables:t.variables,extensions:a.extensions});let{updateQueries:e}=t;e&&this.queryManager.getObservableQueries(`all`).forEach(t=>{let n=t&&t.queryName;if(!n||!Object.hasOwnProperty.call(e,n))return;let i=e[n],{query:a,variables:s}=t,{result:c,complete:l}=t.getCacheDiff({optimistic:!1});if(l&&c){let e=i(c,{mutationResult:o(),queryName:a&&jr(a)||void 0,queryVariables:s});e&&r.push({result:e,dataId:`ROOT_QUERY`,query:a,variables:s})}})}let s=t.refetchQueries;if(typeof s==`function`&&(s=s(o())),r.length>0||(s||``).length>0||t.update||t.onQueryUpdated||t.removeOptimistic){let e=[];
45if(this.queryManager.refetchQueries({updateCache:e=>{i||r.forEach(t=>e.write(t));let{update:n}=t;if(!i){let n=e.diff({id:`ROOT_MUTATION`,query:this.queryManager.getDocumentInfo(t.document).asQuery,variables:t.variables,optimistic:!1,returnPartialData:!0});n.complete&&(a={...a,data:n.result})}n&&!this.hasNext&&n(e,a,{context:t.context,variables:t.variables}),!i&&!t.keepRootFields&&!this.hasNext&&e.modify({id:`ROOT_MUTATION`,fields(e,{fieldName:t,DELETE:n}){return t===`__typename`?e:n}})},include:s,optimistic:!1,removeOptimistic:t.removeOptimistic,onQueryUpdated:t.onQueryUpdated||null}).forEach(t=>e.push(t)),t.awaitRefetchQueries||t.onQueryUpdated)return Promise.all(e).then(()=>a)}return Promise.resolve(a)}markMutationOptimistic(e,t){let n=typeof e==`function`?e(t.variables,{IGNORE:Zs}):e;return n!==Zs&&(this.cache.recordOptimisticTransaction(e=>{try{this.markMutationResult({data:n},t,e)}catch(e){S.error(e)}},this.id),!0)}markSubscriptionResult(e,{document:t,variables:n,errorPolicy:r,cacheWriteBehavior:i}){if(i!==0){if(ec(e,r)){this.cache.write({query:t,result:e.data,dataId:`ROOT_SUBSCRIPTION`,variables:n,extensions:e.extensions});let r=this.cache.diff({query:this.queryManager.getDocumentInfo(t).asQuery,id:`ROOT_SUBSCRIPTION`,variables:n,optimistic:!1,returnPartialData:!0});r.complete&&(e.data=r.result)}this.queryManager.broadcastQueries()}}};function ec(e,t=`none`){let n=t===`ignore`||t===`all`,r=!xi(e);return!r&&n&&e.data&&(r=!0),r}var tc=class{defaultOptions;client;clientOptions;assumeImmutableResults;documentTransform;ssrMode;defaultContext;dataMasking;incrementalHandler;localState;queryDeduplication;prioritizeCacheValues=!1;onBroadcast;mutationStore;obsQueries=new Set;fetchCancelFns=new Map;constructor(e){let t=new eo(e=>this.cache.transformDocument(e),{cache:!1});this.client=e.client,this.defaultOptions=e.defaultOptions,this.queryDeduplication=e.queryDeduplication,this.clientOptions=e.clientOptions,this.ssrMode=e.ssrMode,this.assumeImmutableResults=e.assumeImmutableResults,this.dataMasking=e.dataMasking,this.localState=e.localState,this.incrementalHandler=e.incrementalHandler;let n=e.documentTransform;this.documentTransform=n?t.concat(n).concat(t):t,this.incrementalHandler.documentTransform&&(this.documentTransform=this.documentTransform.concat(this.incrementalHandler.documentTransform)),this.defaultContext=e.defaultContext||{},(this.onBroadcast=e.onBroadcast)&&(this.mutationStore={})}get link(){return this.client.link}get cache(){return this.client.cache}stop(){this.obsQueries.forEach(e=>e.stop()),this.cancelPendingFetches(C(93))}cancelPendingFetches(e){this.fetchCancelFns.forEach(t=>t(e)),this.fetchCancelFns.clear()}async mutate({mutation:e,variables:t,optimisticResponse:n,updateQueries:r,refetchQueries:i=[],awaitRefetchQueries:a=!1,update:o,onQueryUpdated:s,fetchPolicy:c,errorPolicy:l,keepRootFields:u,context:d}){let p=new $s(this);e=this.cache.transformForLink(this.transform(e));let{hasClientExports:m}=this.getDocumentInfo(e);t=this.getVariables(e,t),m&&(t=await this.localState.getExportedVariables({client:this.client,document:e,variables:t,context:d}));let h=this.mutationStore&&(this.mutationStore[p.id]={mutation:e,variables:this.cache.serializeVariables(e,t),loading:!0,error:null}),g=n&&p.markMutationOptimistic(n,{document:e,variables:t,cacheWriteBehavior:c===`no-cache`?0:2,errorPolicy:l,context:d,updateQueries:r,update:o,keepRootFields:u});return this.broadcastQueries(),new Promise((m,_)=>{let v={};return this.getObservableFromLink(e,{...d,optimisticResponse:g?n:void 0},t,c,{},!1).observable.pipe(nc(),dr(n=>{let f={...n};return tr(p.markMutationResult(f,{document:e,variables:t,cacheWriteBehavior:c===`no-cache`?0:2,errorPolicy:l,context:d,update:o,updateQueries:r,awaitRefetchQueries:a,refetchQueries:i,removeOptimistic:g?p.id:void 0,onQueryUpdated:s,keepRootFields:u}))})).pipe(L(e=>{if(xi(e)&&l===`none`)throw new f(ic(e));return h&&(h.loading=!1,h.error=null),e})).subscribe({next:t=>{if(this.broadcastQueries(),!p.hasNext){let n={data:this.maskOperation({document:e,data:t.data,fetchPolicy:c,cause:v})};xi(t)&&(n.error=new f(t)),Object.keys(t.extensions||{}).length&&(n.extensions=t.extensions),m(n)}},error:e=>{if(h&&(h.loading=!1,h.error=e),g&&this.cache.removeOptimistic(p.id),this.broadcastQueries(),l===`ignore`)return m({data:void 0});if(l===`all`)return m({data:void 0,error:e});_(e)}})})}fetchQuery(e,t){return B(e.query,Ve.QUERY),(async()=>cr(this.fetchObservableWithInfo(e,{networkStatus:t}).observable.pipe(Ba(e=>{switch(e.kind){case`E`:throw e.error;case`N`:if(e.source!==`newNetworkStatus`)return za(e.value)}})),{defaultValue:{data:void 0}}))()}transform(e){return this.documentTransform.transformDocument(e)}transformCache=new Jr(R[`queryManager.getDocumentInfo`]||2e3);getDocumentInfo(e){let{transformCache:t}=this;if(!t.has(e)){let n=V(e),r={hasClientExports:Si([`client`,`export`],e,!0),hasForcedResolvers:Ci(e),hasNonreactiveDirective:Si([`nonreactive`],e),hasIncrementalDirective:Si([`defer`],e),nonReactiveQuery:rc(e),clientQuery:Si([`client`],e)?e:null,serverQuery:Oa([{name:`client`,remove:!0},{name:`connection`},{name:`nonreactive`},{name:`unmask`}],e),operationType:n?.operation,defaultVars:di(n),asQuery:{...e,definitions:e.definitions.map(e=>e.kind===`OperationDefinition`&&e.operation!==`query`?{...e,operation:`query`}:e)}};t.set(e,r)}let n=t.get(e);if(n.violation)throw n.violation;return n}getVariables(e,t){let n=this.getDocumentInfo(e).defaultVars,r=Object.entries(t??{}).map(([e,t])=>[e,t===void 0?n[e]:t]);return{...n,...Object.fromEntries(r)}}watchQuery(e){B(e.query,Ve.QUERY);let t=this.transform(e.query);return e={...e,variables:this.getVariables(t,e.variables)},e.notifyOnNetworkStatusChange===void 0&&(e.notifyOnNetworkStatusChange=!0),new Js({queryManager:this,options:e,transformedQuery:t})}query(e){let t=this.transform(e.query);return this.fetchQuery({...e,query:t}).then(n=>({...n,data:this.maskOperation({document:t,data:n?.data,fetchPolicy:e.fetchPolicy})}))}clearStore(e={discardWatches:!0}){return this.cancelPendingFetches(C(95)),this.obsQueries.forEac
45h(e=>{e.reset()}),this.mutationStore&&={},this.cache.reset(e)}getObservableQueries(e=`active`){let t=new Set,n=new Map,r=new Map,i=new Set;return Array.isArray(e)&&e.forEach(e=>{if(typeof e==`string`)n.set(e,e),r.set(e,!1);else if(Ti(e)){let t=no(this.transform(e));n.set(t,jr(e)),r.set(t,!1)}else W(e)&&e.query&&i.add(e)}),this.obsQueries.forEach(n=>{let i=no(this.transform(n.options.query));if(e===`all`){t.add(n);return}let{queryName:a,options:{fetchPolicy:o}}=n;(e!==`active`||o!==`standby`)&&(e===`active`||a&&r.has(a)||i&&r.has(i))&&(t.add(n),a&&r.set(a,!0),i&&r.set(i,!0))}),i.size&&i.forEach(e=>{let n=new Js({queryManager:this,options:{...wa(this.defaultOptions.watchQuery,e),fetchPolicy:`network-only`}});t.add(n)}),t}refetchObservableQueries(e=!1){let t=[];return this.getObservableQueries(e?`all`:`active`).forEach(n=>{let{fetchPolicy:r}=n.options;(e||r!==`standby`)&&r!==`cache-only`&&t.push(n.refetch())}),this.broadcastQueries(),Promise.all(t)}startGraphQLSubscription(e){let{query:t,variables:n}=e,{fetchPolicy:r=`cache-first`,errorPolicy:i=`none`,context:a={},extensions:o={}}=e;B(t,Ve.SUBSCRIPTION),t=this.transform(t),n=this.getVariables(t,n);let s,c=(this.getDocumentInfo(t).hasClientExports?tr(this.localState.getExportedVariables({client:this.client,document:t,variables:n,context:a})):nr(n)).pipe(dr(e=>{let{observable:n,restart:c}=this.getObservableFromLink(t,a,e,r,o),l=new $s(this);return s=c,n.pipe(L(n=>{l.markSubscriptionResult(n,{document:t,variables:e,errorPolicy:i,cacheWriteBehavior:r===`no-cache`?0:2});let a={data:n.data??void 0};return xi(n)?a.error=new f(n):v(n)&&(a.error=n.extensions[_],delete n.extensions[_]),n.extensions&&Object.keys(n.extensions).length&&(a.extensions=n.extensions),a.error&&i===`none`&&(a.data=void 0),i===`ignore`&&delete a.error,a}),_r(e=>nr(i===`ignore`?{data:void 0}:{data:void 0,error:e})),gr(e=>!!(e.data||e.error)))}));return Object.assign(c,{restart:()=>s?.()})}broadcastQueries(){this.onBroadcast&&this.onBroadcast(),this.obsQueries.forEach(e=>e.notify())}inFlightLinkObservables=new z(!1);getObservableFromLink(e,t,n,r,i,a=t?.queryDeduplication??this.queryDeduplication){let o={},{serverQuery:s,clientQuery:c,operationType:l,hasIncrementalDirective:u}=this.getDocumentInfo(e),d=jr(e),f={client:this.client};if(n=this.cache.serializeVariables(e,n),s){let{inFlightLinkObservables:e,link:r}=this;try{let c=this.incrementalHandler.prepareRequest({query:s,variables:n,context:{...this.defaultContext,...t,queryDeduplication:a},extensions:i});t=c.context;function u(e){return new P(t=>{function n(){return e.subscribe({next:t.next.bind(t),complete:t.complete.bind(t),error:t.error.bind(t)})}let r=n();return o.restart||=()=>{r.unsubscribe(),r=n()},()=>{r.unsubscribe(),o.restart=void 0}})}if(a){let t=no(s),i=G(n);o=e.lookup(t,i),o.observable||(o.observable=vo(r,c,f).pipe(u,br(()=>{e.peek(t,i)===o&&e.remove(t,i)}),l===Ve.SUBSCRIPTION?Sr():wr({refCount:!0})))}else o.observable=vo(r,c,f).pipe(u)}catch(e){o.observable=rr(()=>e)}}else o.observable=nr({data:{}});if(c){let{operation:i}=V(e);S(!u,100,i[0].toUpperCase()+i.slice(1),d??`(anonymous)`),o.observable=o.observable.pipe(dr(e=>tr(this.localState.execute({client:this.client,document:c,remoteResult:e,context:t,variables:n,fetchPolicy:r}))))}return{restart:()=>o.restart?.(),observable:o.observable.pipe(_r(e=>{throw e=y(e),m(e),e}))}}getResultsFromLink(e,{queryInfo:t,cacheWriteBehavior:n,observableQuery:r,exposeExtensions:i,prunePendingDeferFragments:a}){let{errorPolicy:o}=e,s=this.cache.transformForLink(e.query);return this.getObservableFromLink(s,e.context,e.variables,e.fetchPolicy).observable.pipe(L(c=>{let{dataState:l,...u}=t.markQueryResult(c,{...e,document:s,cacheWriteBehavior:n,returnPartialData:e.returnPartialData,prunePendingDeferFragments:a}),d=xi(u);if(d&&o===`none`){r?.resetNotifications();let e=new f(ic(u));throw Vs.set(e,l),e}let p=l!==`complete`,m={data:u.data,...t.hasNext?{loading:!0,networkStatus:$.streaming,dataState:l,partial:p}:{dataState:l,loading:!1,networkStatus:$.ready,partial:p}};return i&&`extensions`in u&&(m[qa]=u.extensions),d&&o!==`ignore`&&(m.error=new f(ic(u)),m.networkStatus!==$.streaming&&(m.networkStatus=$.error)),m}),_r(e=>{if(o===`none`)throw r?.resetNotifications(),e;let t={data:void 0,dataState:`empty`,loading:!1,networkStatus:$.ready,partial:!0};return o!==`ignore`&&(t.error=e,t.networkStatus=$.error),nr(t)}))}fetchObservableWithInfo(e,{networkStatus:t=$.loading,query:n=e.query,fetchQueryOperator:r=e=>e,onCacheHit:i=()=>{},observableQuery:a,exposeExtensions:o}){let s=this.getVariables(n,e.variables),{fetchPolicy:c=`cache-first`,errorPolicy:l=`none`,returnPartialData:u=!1,notifyOnNetworkStatusChange:d=!0,context:f={}}=e;this.prioritizeCacheValues&&(c===`network-only`||c===`cache-and-network`)&&(c=`cache-first`);let p=Object.assign({},e,{query:n,variables:s,fetchPolicy:c,errorPolicy:l,returnPartialData:u,networkStatus:t,notifyOnNetworkStatusChange:d,context:f}),m=new $s(this,a),h=n=>{p.variables=n;let s=c===`no-cache`?0:t===$.refetch&&p.refetchWritePolicy!==`merge`?1:2,l=this.fetchQueryByPolicy(p,{queryInfo:m,cacheWriteBehavior:s,onCacheHit:i,observableQuery:a,exposeExtensions:o});return l.observable=l.observable.pipe(r),p.fetchPolicy!==`standby`&&a?.applyNextFetchPolicy(`after-fetch`,e),l},g=()=>{this.fetchCancelFns.delete(m.id)};this.fetchCancelFns.set(m.id,e=>{_.next({kind:`E`,error:e,source:`network`})});let _=new tn,v,y;
45if(this.getDocumentInfo(p.query).hasClientExports)v=tr(this.localState.getExportedVariables({client:this.client,document:p.query,variables:p.variables,context:p.context})).pipe(dr(e=>h(e).observable)),y=!0;else{let e=h(p.variables);y=e.fromLink,v=e.observable}return{observable:new P(e=>{e.add(g),v.subscribe(e),_.subscribe(e)}).pipe(Sr()),fromLink:y}}refetchQueries({updateCache:e,include:t,optimistic:n=!1,removeOptimistic:r=n?x(`refetchQueries`):void 0,onQueryUpdated:i}){let a=new Map;t&&this.getObservableQueries(t).forEach(e=>{if(e.options.fetchPolicy===`cache-only`||e.variablesUnknown)return;let t=e.getCurrentResult();a.set(e,{oq:e,lastDiff:{result:t?.data,complete:!t?.partial}})});let o=new Map;if(e){let t=new Set;this.cache.batch({update:e,optimistic:n&&r||!1,removeOptimistic:r,onWatchUpdated(e,n,r){let s=e.watcher;if(s instanceof Js&&!t.has(s)){if(t.add(s),i){a.delete(s);let e=i(s,n,r);return e===!0&&(e=s.refetch().retain()),e!==!1&&o.set(s,e),e}i!==null&&s.options.fetchPolicy!==`cache-only`&&a.set(s,{oq:s,lastDiff:r,diff:n})}}})}return a.size&&a.forEach(({oq:e,lastDiff:t,diff:n})=>{let r;i&&(n||=e.getCacheDiff(),r=i(e,n,t)),(!i||r===!0)&&(r=e.refetch().retain()),r!==!1&&o.set(e,r)}),r&&this.cache.removeOptimistic(r),o}noCacheWarningsByCause=new WeakSet;maskOperation(e){let{document:t,data:n}=e;return this.dataMasking?Qo(n,t,this.cache):n}maskFragment(e){let{data:t,fragment:n,fragmentName:r}=e;return this.dataMasking?Zo(t,n,this.cache,r):t}fetchQueryByPolicy({query:e,variables:t,fetchPolicy:n,errorPolicy:r,returnPartialData:i,context:a,networkStatus:o},{cacheWriteBehavior:s,onCacheHit:c,queryInfo:l,observableQuery:u,exposeExtensions:d}){let f=()=>l.getDiff({query:e,variables:t,returnPartialData:!0,optimistic:!0}),p=(o,s)=>{let l=o.result,u=(e,t=o.dataState)=>(!o.complete&&!i&&(e=void 0,t=`empty`),{data:e,dataState:t,loading:ho(s),networkStatus:s,partial:!o.complete}),d=e=>nr({kind:`N`,value:u(e),resolvedVariables:t,source:`cache`});return(o.complete||i)&&this.getDocumentInfo(e).hasForcedResolvers?(c(),tr(this.localState.execute({client:this.client,document:e,remoteResult:l?{data:l}:void 0,context:a,variables:t,onlyRunForcedResolvers:!0,returnPartialData:!0,fetchPolicy:n}).then(e=>({kind:`N`,value:u(e.data||void 0,o.complete?`complete`:e.data?`partial`:`empty`),resolvedVariables:t,source:`cache`})))):r===`none`&&s===$.refetch&&o.missing?d(void 0):d(l||void 0)},m=({prunePendingDeferFragments:c=!0}={})=>this.getResultsFromLink({query:e,variables:t,context:a,fetchPolicy:n,errorPolicy:r,returnPartialData:i,networkStatus:o},{cacheWriteBehavior:s,queryInfo:l,observableQuery:u,exposeExtensions:d,prunePendingDeferFragments:c}).pipe(nc(),xr(),L(e=>({...e,resolvedVariables:t,source:`network`})));switch(n){default:case`cache-first`:{let e=f();return e.complete?{fromLink:!1,observable:p(e,$.ready)}:i?{fromLink:!0,observable:mr(p(e,$.loading),m())}:{fromLink:!0,observable:m()}}case`cache-and-network`:{let e=f();return e.complete||i?{fromLink:!0,observable:mr(p(e,$.loading),m({prunePendingDeferFragments:!1}))}:{fromLink:!0,observable:m()}}case`cache-only`:return{fromLink:!1,observable:mr(p(f(),$.ready))};case`network-only`:return{fromLink:!0,observable:m({prunePendingDeferFragments:o!==$.refetch})};case`no-cache`:return{fromLink:!0,observable:m().pipe(L(t=>(t.kind===`N`&&t.value.data!=null&&this.cache.configuresScalars()&&(t.value.data=ai(t.value.data,e,this.cache)),t)))};case`standby`:return{fromLink:!1,observable:Cn}}}};function nc(){let e=!1;return Tr({next(){e=!0},complete(){S(e,104)}})}function rc(e){return E(e,{FragmentSpread:e=>{if(!e.directives?.some(e=>e.name.value===`unmask`))return{...e,directives:[...e.directives||[],{kind:T.DIRECTIVE,name:{kind:T.NAME,value:`nonreactive`}}]}}})}function ic(e){if(e.extensions?.[Ja]==null)return e;let{extensions:{[Ja]:t,...n},...r}=e;return Object.keys(n).length>0&&(r.extensions=n),r}var ac=class{link;cache;disableNetworkFetches;set prioritizeCacheValues(e){this.queryManager.prioritizeCacheValues=e}get prioritizeCacheValues(){return this.queryManager.prioritizeCacheValues}version;queryDeduplication;defaultOptions;devtoolsConfig;refetchEventManager;queryManager;devToolsHookCb;resetStoreCallbacks=[];clearStoreCallbacks=[];constructor(e){let{cache:t,documentTransform:n,ssrMode:r=!1,ssrForceFetchDelay:i=0,queryDeduplication:a=!0,defaultOptions:o,defaultContext:s,assumeImmutableResults:c=t.assumeImmutableResults,localState:l,devtools:u,dataMasking:d,link:f,incrementalHandler:p=new Qa,experiments:m=[],refetchEventManager:h}=e;this.link=f,this.cache=t,this.queryDeduplication=a,this.defaultOptions=o||{},this.devtoolsConfig={...u,enabled:u?.enabled??!1},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=this.refetchObservableQueries.bind(this),this.version=te,this.queryManager=new tc({client:this,defaultOptions:this.defaultOptions,defaultContext:s,documentTransform:n,queryDeduplication:a,ssrMode:r,dataMasking:!!d,clientOptions:e,incrementalHandler:p,assumeImmutableResults:c,onBroadcast:this.devtoolsConfig.enabled?()=>{this.devToolsHookCb&&this.devToolsHookCb()}:void 0,localState:l}),this.prioritizeCacheValues=r||i>0,i&&setTimeout(()=>{this.prioritizeCacheValues=!1},i),this.devtoolsConfig.enabled&&this.connectToDevTools(),m.forEach(t=>t.call(this,e)),this.refetchEventManager=h,this.refetchEventManager?.connect(this)}connectToDevTools(){if(typeof window>`u`)return;let e=window,t=Symbol.for(`apollo.devtools`);(e[t]=e[t]||[]).push(this),e.__APOLLO_CLIENT__=this}get documentTransform(){return this.queryManager.documentTransform}get localState(){return this.queryManager.localState}set localState(e){this.queryManager.localState=e}stop(){this.queryManager.stop(),this.refetchEventManager?.disconnect(this)}watchQuery(e){let{refetchOn:t}=e;if(this.defaultOptions.watchQuery){let n=this.defaultOptions.watchQuery.refetchOn,r;t&&typeof t==`object`&&(typeof n==`object`?r={...n,...t}:n!=null&&(r=e=>{let r=t[e.source]??n;return typeof r==`function`?r(e):r})),e=wa(this.defaultOptions.watchQuery,e),r&&(e.refetchOn=r)}return this.queryManager.watchQuery(e)}query=e=>(this.defaultOptions.query&&(e=wa(this.defaultOptions.query,e)),this.queryManager.query(e));mutate=e=>{let t=wa(U({fetchPolicy:`network-only`,errorPolicy:`none`},this.defaultOptions.mutate),e);return B(t.mutation,Ve.MUTATION),this.queryManager.mutate(t)};subscribe(e){let t={},n=this.queryManager.startGraphQLSubscription(e),r=n.pipe(L(n=>({...n,data:this.queryManager.maskOperation({document:e.query,data:n.data,fetchPolicy:e.fetchPolicy,cause:t})})));return Object.assign(r,{restart:n.restart})}readQuery(e,t=!!e.optimistic){return this.cache.readQuery({...e,query:this.transform(e.query)},t)}watchFragment(e){let t=this.queryManager.dataMasking;return this.cache.watchFragment({...e,fragment:this.transform(e.fragment,t)})}
45readFragment(e,t=!!e.optimistic){return this.cache.readFragment({...e,fragment:this.transform(e.fragment)},t)}writeQuery(e){let t=this.cache.writeQuery(e);return e.broadcast!==!1&&this.queryManager.broadcastQueries(),t}writeFragment(e){let t=this.cache.writeFragment(e);return e.broadcast!==!1&&this.queryManager.broadcastQueries(),t}__actionHookForDevTools(e){this.devToolsHookCb=e}__requestRaw(e){return vo(this.link,e,{client:this})}resetStore(){return Promise.resolve().then(()=>this.queryManager.clearStore({discardWatches:!1})).then(()=>Promise.all(this.resetStoreCallbacks.map(e=>e()))).then(()=>this.refetchObservableQueries())}clearStore(){return Promise.resolve().then(()=>this.queryManager.clearStore({discardWatches:!0})).then(()=>Promise.all(this.clearStoreCallbacks.map(e=>e())))}onResetStore(e){return this.resetStoreCallbacks.push(e),()=>{this.resetStoreCallbacks=this.resetStoreCallbacks.filter(t=>t!==e)}}onClearStore(e){return this.clearStoreCallbacks.push(e),()=>{this.clearStoreCallbacks=this.clearStoreCallbacks.filter(t=>t!==e)}}reFetchObservableQueries;refetchObservableQueries(e){return this.queryManager.refetchObservableQueries(e)}refetchQueries(e){let t=this.queryManager.refetchQueries(e),n=[],r=[];t.forEach((e,t)=>{n.push(t),r.push(e)});let i=Promise.all(r);return i.queries=n,i.results=r,i.catch(e=>{}),i}getObservableQueries(e=`active`){return this.queryManager.getObservableQueries(e)}extract(e){return this.cache.extract(e)}restore(e){return this.cache.restore(e)}setLink(e){this.link=e}get defaultContext(){return this.queryManager.defaultContext}maskedFragmentTransform=new eo(Na);transform(e,t=!1){let n=this.queryManager.transform(e);return t?this.maskedFragmentTransform.transformDocument(n):n}},{hasOwnProperty:oc}=Object.prototype;function sc(e){return W(e)&&`payload`in e}async function*cc(e){let t=new TextDecoder(`utf-8`),n=(e.headers?.get(`content-type`))?.match(/;\s*boundary=(?:'([^']+)'|"([^"]+)"|([^"'].+?))\s*(?:;|$)/i),r=`\r
46--`+(n?n[1]??n[2]??n[3]??`-`:`-`),i=``;S(e.body&&typeof e.body.getReader==`function`,64);let a=e.body.getReader(),o=!1,s=!1,c,l=()=>s&&i[0]==`-`&&i[1]==`-`;try{for(;!o;){({value:c,done:o}=await a.read());let e=typeof c==`string`?c:t.decode(c,{stream:!o}),n=i.length-r.length+1;i+=e;let u=i.indexOf(r,n);for(;u>-1&&!l();){s=!0;let e;[e,i]=[i.slice(0,u),i.slice(u+r.length)];let t=e.indexOf(`\r
47\r
48`),n=uc(e.slice(0,t))[`content-type`];if(n&&n.toLowerCase().indexOf(`application/json`)===-1)throw Error(`Unsupported patch content type: application/json is required.`);let a=e.slice(t);a&&(yield a),u=i.indexOf(r)}if(l())return}throw Error(`premature end of multipart body`)}finally{a.cancel()}}async function lc(e,t){for await(let n of cc(e)){let r=dc(e,n);if(Object.keys(r).length!=0){if(sc(r)){if(Object.keys(r).length===1&&r.payload===null)return;let e={...r.payload};`errors`in r&&(e.extensions={...e.extensions,[_]:new c(r.errors??[])}),t(e)}else t(r)}}}function uc(e){let t={};return e.split(`
49`).forEach(e=>{let n=e.indexOf(`:`);if(n>-1){let r=e.slice(0,n).trim().toLowerCase(),i=e.slice(n+1).trim();t[r]=i}}),t}function dc(e,t){if(e.status>=300)throw new h(`Response not successful: Received status code ${e.status}`,{response:e,bodyText:t});try{return JSON.parse(t)}catch(n){throw new g(n,{response:e,bodyText:t})}}function fc(e,t){try{return JSON.parse(t)}catch(n){throw new g(n,{response:e,bodyText:t})}}function pc(e,t){return e.headers.get(`content-type`)?.includes(`application/graphql-response+json`)?fc(e,t):dc(e,t)}function mc(e){return t=>t.text().then(n=>{let r=pc(t,n);if(!Array.isArray(r)&&!oc.call(r,`data`)&&!oc.call(r,`errors`))throw new h(`Server response was malformed for query '${Array.isArray(e)?e.map(e=>e.operationName):e.operationName}'.`,{response:t,bodyText:n});return r})}var hc={http:{includeQuery:!0,includeExtensions:!0,preserveHeaderCase:!1},headers:{accept:`application/graphql-response+json,application/json;q=0.9`,"content-type":`application/json`},options:{method:`POST`}},gc=(e,t)=>t(e);function _c(e,t,...n){let r={},i={};n.forEach(e=>{r={...r,...e.options,headers:{...r.headers,...e.headers}},e.credentials&&(r.credentials=e.credentials),r.headers.accept=(e.http?.accept||[]).concat(r.headers.accept).join(`,`),i={...i,...e.http}}),r.headers=vc(r.headers,i.preserveHeaderCase);let{operationName:a,extensions:o,variables:s,query:c}=e,l={operationName:a,variables:s};return i.includeExtensions&&Object.keys(o||{}).length&&(l.extensions=o),i.includeQuery&&(l.query=t(c,no)),{options:r,body:l}}function vc(e,t){if(!t){let t={};
49return Object.keys(Object(e)).forEach(n=>{t[n.toLowerCase()]=e[n]}),t}let n={};Object.keys(Object(e)).forEach(t=>{n[t.toLowerCase()]={originalName:t,value:e[t]}});let r={};return Object.keys(n).forEach(e=>{r[n[e].originalName]=n[e].value}),r}var yc=(e,t)=>e.getContext().uri||(typeof t==`function`?t(e):t||`/graphql`);function bc(e,t){let n=[],r=(e,t)=>{n.push(`${e}=${encodeURIComponent(t)}`)};if(`query`in t&&r(`query`,t.query),t.operationName&&r(`operationName`,t.operationName),t.variables){let e;try{e=JSON.stringify(t.variables)}catch(e){return{parseError:e}}r(`variables`,e)}if(t.extensions){let e;try{e=JSON.stringify(t.extensions)}catch(e){return{parseError:e}}r(`extensions`,e)}let i=``,a=e,o=e.indexOf(`#`);o!==-1&&(i=e.substr(o),a=e.substr(0,o));let s=a.indexOf(`?`)===-1?`?`:`&`;return{newURI:a+s+n.join(`&`)+i}}var xc=b(()=>fetch);function Sc(){}var Cc=class extends X{constructor(e={}){let{uri:t=`/graphql`,fetch:n,print:r=gc,includeExtensions:i,preserveHeaderCase:a,useGETForQueries:o,includeUnusedVariables:s=!1,...c}=e,l={http:U({includeExtensions:i,preserveHeaderCase:a}),options:c.fetchOptions,credentials:c.credentials,headers:c.headers};super(e=>{let i=yc(e,t),a=e.getContext(),c={...a.http};so(e.query)&&(c.accept=[`multipart/mixed;boundary=graphql;subscriptionSpec=1.0`,...c.accept||[]]);let u={http:c,options:a.fetchOptions,credentials:a.credentials,headers:a.headers},{options:d,body:f}=_c(e,r,hc,l,u);f.variables&&!s&&(f.variables=_o(f.variables,e.query));let p=new AbortController,m=()=>{p=void 0};if(d.signal){let e=d.signal,t=()=>{p?.abort(e.reason)};e.addEventListener(`abort`,t,{once:!0}),m=()=>{p?.signal.removeEventListener(`abort`,m),p=void 0,e.removeEventListener(`abort`,t),m=Sc},p.signal.addEventListener(`abort`,m,{once:!0})}return d.signal=p.signal,o&&!oo(e.query)&&(d.method=`GET`),new P(t=>{if(d.method===`GET`){let{newURI:e,parseError:t}=bc(i,f);if(t)throw t;i=e}else d.body=JSON.stringify(f);let r=n||b(()=>fetch)||xc,a=t.next.bind(t);return r(i,d).then(t=>{e.setContext({response:t});let n=t.headers?.get(`content-type`);return n!==null&&/^multipart\/mixed/i.test(n)?lc(t,a):mc(e)(t).then(a)}).then(()=>{m(),t.complete()}).catch(e=>{m(),t.error(e)}),()=>{p&&p.abort()}})})}},wc=class extends X{constructor(e={}){super((t,n)=>{let r=t.client,i=r.queryManager.clientOptions,a=t.getContext();{let{name:n,version:r,transport:o=`headers`}=U({},i.clientAwareness,e.clientAwareness,a.clientAwareness);o===`headers`&&t.setContext(({headers:e})=>({headers:U({"apollographql-client-name":n,"apollographql-client-version":r},e)}))}{let{transport:n=`extensions`}=U({},i.enhancedClientAwareness,e.enhancedClientAwareness);n===`extensions`&&(t.extensions=U({clientLibrary:{name:`@apollo/client`,version:r.version}},t.extensions)),n===`headers`&&t.setContext(({headers:e})=>({headers:U({"apollographql-library-name":`@apollo/client`,"apollographql-library-version":r.version},e)}))}return n(t)})}},Tc=class extends X{constructor(e={}){let{left:t,right:n,request:r}=X.from([new wc(e),new Cc(e)]);super(r),Object.assign(this,{left:t,right:n})}};function Ec(e,t){let n=i.useRef(void 0);return(!n.current||!w(n.current.deps,t))&&(n.current={value:e(),deps:t}),n.current.value}var Dc;function Oc(){}function kc(){return Dc||=i.createContext(null),i.useCallback(()=>{let e=console.error;try{return console.error=Oc,i.useContext(Dc),!0}catch{return!1}finally{console.error=e}},[])}var Ac=Symbol.for(`apollo.skipToken`),jc=Symbol.for(`apollo.hook.wrappers`);function Mc(e,t,n){let r=[n.queryManager,e.startsWith(`use`)?i.useContext(me()):void 0],a=t;for(let t of r){let n=t?.[jc]?.[e];n&&(a=n(a))}return a}var Nc=Ar?i.useLayoutEffect:i.useEffect,Pc=i.useSyncExternalStore,Fc=b(()=>navigator.product)==`ReactNative`,Ic=b(()=>navigator.userAgent.indexOf(`jsdom`)>=0)||!1,Lc=(Ar||Fc)&&!Ic,Rc=Pc||((e,t,n)=>{let r=t(),[{inst:a},o]=i.useState({inst:{value:r,getSnapshot:t}});return Lc?i.useLayoutEffect(()=>{Object.assign(a,{value:r,getSnapshot:t}),zc(a)&&o({inst:a})},[e,r,t]):Object.assign(a,{value:r,getSnapshot:t}),i.useEffect(()=>(zc(a)&&o({inst:a}),e(function(){zc(a)&&o({inst:a})})),[e]),r});function zc({value:e,getSnapshot:t}){try{return e!==t()}catch{return!0}}var Bc=[`refetch`,`fetchMore`,`updateQuery`,`startPolling`,`stopPolling`,`subscribeToMore`],Vc=function(e,t){let n=ge(t?.client),r=i.useRef(void 0),a=i.useRef(void 0),o=i.useRef(()=>{}),s=Ec(()=>t,[t]),c=kc();function l(){return n.watchQuery({...t,query:e,initialFetchPolicy:t?.fetchPolicy,fetchPolicy:`standby`,[Ya]:!0})}let[u,d]=i.useState(n),[f,p]=i.useState(l);u!==n&&(d(n),p(l()));let m=i.useCallback((e,t)=>{let n=a.current?.data;n&&!w(n,e.data)&&(r.current=n),a.current=e,t()},[]),h=Rc(i.useCallback(e=>{o.current=e;let t=f.subscribe(t=>{w(a.current,t)||m(t,e)});return()=>{t.unsubscribe()}},[f,m]),()=>a.current||Hc,()=>Hc),g=i.useMemo(()=>{let e={};for(let t of Bc)e[t]=function(...e){return S(a.current,31,t),f[t](...e)};return e},[f]);i.useEffect(()=>{let n={query:e,errorPolicy:s?.errorPolicy,refetchOn:s?.refetchOn,refetchWritePolicy:s?.refetchWritePolicy,returnPartialData:s?.returnPartialData,notifyOnNetworkStatusChange:s?.notifyOnNetworkStatusChange,pollInterval:s?.pollInterval,nextFetchPolicy:t?.nextFetchPolicy,skipPollAttempt:t?.skipPollAttempt};f.options.fetchPolicy!==`standby`&&s?.fetchPolicy&&(n.fetchPolicy=s.fetchPolicy),f.applyOptions(n)},[e,f,s,t?.nextFetchPolicy,t?.skipPollAttempt]);let _=i.useCallback((...e)=>{S(!c(),32);let[t]=e,n=f.options.fetchPolicy;n===`standby`&&(n=f.options.initialFetchPolicy);let r=a.current,i=f.variables,s=f.reobserve({fetchPolicy:n,variables:t?.variables,context:t?.context??{}});return f.options.notifyOnNetworkStatusChange&&a.current===r&&!w(f.variables,i)&&(a.current&&={...a.current},o.current()),s},[f,c]),v=i.useRef(_);return Nc(()=>{v.current=_}),[i.useCallback((...e)=>v.current(...e),[]),i.useMemo(()=>{let{partial:e,...t}=h;return{...g,...t,client:n,previousData:r.current,variables:f.variables,observable:f,called:!!a.current}},[n,h,g,f])]},Hc=xa({data:void 0,dataState:`empty`,loading:!1,networkStatus:$.ready,partial:!0}),Uc=function(e,t){let n=ge(t?.client),[r,a]=i.useState(()=>Wc(n)),o=i.useRef({result:r,mutationId:0,isMounted:!0,client:n,mutation:e,options:t});Nc(()=>{Object.assign(o.current,{client:n,options:t,mutation:e})});let s=i.useCallback((e={})=>{let{options:t,mutation:n}=o.current,r={...t,mutation:n},i=e.client||o.current.client,s=typeof e.context==`function`?e.context(t?.context):e.context;!o.current.result.loading&&o.current.isMounted&&a(o.current.result={loading:!0,error:void 0,data:void 0,called:!0,client:i});let c=++o.current.mutationId,l=wa(r,{...e,context:s});return Da(i.mutate(l).then(t=>{let{data:n,error:r}=t,s=e.onError||o.current.options?.onError;if(r&&s&&s(r,l),c===o.current.mutationId){let e={called:!0,loading:!1,data:n,error:r,client:i};o.current.isMounted&&!w(o.current.result,e)&&a(o.current.result=e)}let u=e.onCompleted||o.current.options?.onCompleted;return r||u?.(t.data,l),t},t=>{if(c===o.current.mutationId&&o.current.isMounted){let e={loading:!1,error:t,data:void 0,called:!0,client:i};w(o.current.result,e)||a(o.current.result=e)}let n=e.onError||o.current.options?.onError;throw n&&n(t,l),t}))},[]),c=i.useCallback(()=>
49{if(o.current.isMounted){let e=Wc(o.current.client);Object.assign(o.current,{mutationId:0,result:e}),a(e)}},[]);return i.useEffect(()=>{let e=o.current;return e.isMounted=!0,()=>{e.isMounted=!1}},[]),[s,{reset:c,...r}]};function Wc(e){return{data:void 0,error:void 0,called:!1,loading:!1,client:e}}var Gc=Symbol(),Kc=function(e,...[t]){"use no memo";return Mc(`useQuery`,qc,ge(typeof t==`object`?t.client:void 0))(e,t)};function qc(e,t={}){let n=ge(typeof t==`object`?t.client:void 0),{ssr:r}=typeof t==`object`?t:{},a=Yc(e,t,n.defaultOptions.watchQuery);function o(t){let r=n.watchQuery(a);return{client:n,query:e,observable:r,resultData:{current:r.getCurrentResult(),previousData:t?.resultData.current.data,variables:r.variables}}}let[s,c]=i.useState(o);(n!==s.client||e!==s.query)&&c(s=o(s));let{observable:l,resultData:u}=s;Xc(a,l),Qc(u,l,a);let d=Zc(l,u,r),f=i.useMemo(()=>({refetch:l.refetch.bind(l),fetchMore:l.fetchMore.bind(l),updateQuery:l.updateQuery.bind(l),startPolling:l.startPolling.bind(l),stopPolling:l.stopPolling.bind(l),subscribeToMore:l.subscribeToMore.bind(l)}),[l]),p=u.previousData;return i.useMemo(()=>{let{partial:e,...t}=d;return{...t,client:n,observable:l,variables:l.variables,previousData:p,...f}},[d,n,l,p,f])}var Jc=Symbol();function Yc(e,t,n){return Ec(()=>
49{if(t===Ac){let t={...wa(n,{query:e,fetchPolicy:`standby`}),[Ya]:!0};return t[Jc]=!0,t}let r=wa(n,{...t,query:e});return t.skip&&(r.initialFetchPolicy=t.initialFetchPolicy||t.fetchPolicy,r.fetchPolicy=`standby`),r},[e,t,n])}function Xc(e,t){"use no memo";e.fetchPolicy||=t.options.initialFetchPolicy}function Zc(e,t,n){"use no memo";let r=e.options.fetchPolicy;return Rc(i.useCallback(n=>{let r=e.pipe(Kn(xn)).subscribe(r=>{let i=t.current;w(i,r)&&w(t.variables,e.variables)||(t.variables=e.variables,i.data&&!w(i.data,r.data)&&(t.previousData=i.data),t.current=r,n())});return()=>{setTimeout(()=>r.unsubscribe())}},[e,t]),()=>t.current,()=>r!==`standby`&&n===!1||r===`no-cache`?Kc.ssrDisabledResult:t.current)}function Qc(e,t,n){"use no memo";if(t[Gc]&&!w(t[Gc],n)){t[Gc][Jc]&&!n.initialFetchPolicy&&(n.initialFetchPolicy=n.fetchPolicy),$c(t[Gc],n)?t.reobserve(n):t.applyOptions(n);let r=t.getCurrentResult();w(r.data,e.current.data)||(e.previousData=e.current.data||e.previousData),e.current=r,e.variables=t.variables}t[Gc]=n}function $c(e,t){return e.query!==t.query||!w(e.variables,t.variables)||e.fetchPolicy!==t.fetchPolicy&&(t.fetchPolicy===`standby`||e.fetchPolicy===`standby`)}Kc.ssrDisabledResult=xa({loading:!0,data:void 0,dataState:`empty`,error:void 0,networkStatus:$.loading,partial:!0});function el(e){return Rc(i.useCallback(t=>e.onNextChange(function n(){t(),e.onNextChange(n)}),[e]),e,e)}function tl(e){"use no memo";return Mc(`useFragment`,nl,ge(e.client))(e)}function nl(e){let t=ge(e.client),{from:n,...r}=e,{cache:a}=t,o=Ec(()=>{let e=(Array.isArray(n)?n:[n]).map(e=>typeof e==`string`?e:e===null?null:a.identify(e));return Array.isArray(n)?e:e[0]},[a,n]),s=Ec(()=>({...r,from:o}),[r,o]),c=i.useMemo(()=>t.watchFragment(s),[t,s]),l=i.useCallback(()=>n===null?rl:c.getCurrentResult(),[n,c]);return Rc(i.useCallback(e=>{let t=0,n=c.subscribe({next:()=>{clearTimeout(t),t=setTimeout(e)}});return()=>{n.unsubscribe(),clearTimeout(t)}},[c]),l,l)}var rl=Object.freeze({data:{},dataState:`partial`,complete:!1}),il=class extends X{constructor(e){super((t,n)=>{let{...r}=t;return Object.defineProperty(r,"client",{enumerable:!1,value:t.client}),new P(i=>{let a=!1;return Promise.resolve(r).then(n=>e(t.getContext(),n)).then(t.setContext).then(()=>{a||n(t).subscribe(i)}).catch(i.error.bind(i)),()=>{a=!0}})})}},al=class extends X{constructor(e){super((t,n)=>new P(r=>{let i,a,o;try{i=n(t).subscribe({next:i=>{let s=t.client.queryManager.incrementalHandler,c=s.isIncrementalResult(i)?s.extractErrors(i):i.errors;c?o=e({error:new f(i,c),result:i,operation:t,forward:n}):v(i)&&(o=e({error:i.extensions[_],result:i,operation:t,forward:n})),a=o?.subscribe(r),a||r.next(i)},error:i=>{o=e({operation:t,error:y(i),forward:n}),a=o?.subscribe(r),a||r.error(i)},complete:()=>{o||r.complete()}})}catch(i){e({error:y(i),operation:t,forward:n}),r.error(i)}return()=>{i&&i.unsubscribe(),a&&a.unsubscribe()}}))}},ol=class extends X{constructor(e={}){return super((t,n)=>{let{except:r}=e,{query:i,variables:a}=t;return a&&(t.variables=r?this.maybeStripTypenameUsingConfig(i,a,r):po(a)),n(t)}),Object.assign(this,{})}maybeStripTypenameUsingConfig(e,t,n){let r=this.getVariableDefinitions(e);return Object.fromEntries(Object.entries(t).map(e=>{let[t,i]=e,a=n[r[t]];return e[1]=a?this.maybeStripTypename(i,a):po(i),e}))}maybeStripTypename(e,t){if(t===`__KEEP`)return e;if(Array.isArray(e))return e.map(e=>this.maybeStripTypename(e,t));if(Di(e)){let n={};return Object.keys(e).forEach(r=>{let i=e[r];if(r===`__typename`)return;let a=t[r];n[r]=a?this.maybeStripTypename(i,a):po(i)}),n}return e}getVariableDefinitions=ya(e=>{let t={};return E(e,{VariableDefinition(e){t[e.variable.name.value]=sl(e.type)}}),t},{max:R[`removeTypenameFromVariables.getVariableDefinitions`]||2e3,cache:Gr,makeCacheKey:Za(this)})};function sl(e){switch(e.kind){case T.NON_NULL_TYPE:return sl(e.type);case T.LIST_TYPE:return sl(e.type);case T.NAMED_TYPE:return e.name.value}}export{ht as A,gt as C,j as D,mt as E,r as F,ge as M,he as N,ft as O,f as P,vt as S,A as T,K as _,el as a,dt as b,Vc as c,ac as d,$ as f,co as g,X as h,tl as i,Ie as j,M as k,Ac as l,ps as m,al as n,Kc as o,Bs as p,il as r,Uc as s,ol as t,Tc as u,L as v,pt as w,_t as x,P as y};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.