text: (window.webpackJsonp=window.webpackJsonp||[]).push([[42],{18:function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return f})),r.d(t,"b",(function(){return A})),r.d(t,"c",(function(){return T})),r.d(t,"d",(function(){return H})),r.d(t,"e",(function(){return E})),r.d(t,"f",(function(){return P})),r.d(t,"g",(function(){return S})),r.d(t,"h",(function(){return R})),r.d(t,"i",(function(){return w})),r.d(t,"j",(function(){return k})),r.d(t,"k",(function(){return G})),r.d(t,"l",(function(){return O})),r.d(t,"m",(function(){return m})),r.d(t,"n",(function(){return d})),r.d(t,"o",(function(){return v})),r.d(t,"p",(function(){return J})),r.d(t,"q",(function(){return Y})),r.d(t,"r",(function(){return N})),r.d(t,"s",(function(){return L})),r.d(t,"t",(function(){return h})),r.d(t,"u",(function(){return y})),r.d(t,"v",(function(){return z}));var n=r(6),o=r(2),c=r(0);r(61),r(38);function l(e,t,r,n){if(function(e){return"IntValue"===e.kind}(r)||function(e){return"FloatValue"===e.kind}(r))e[t.value]=Number(r.value);else if(function(e){return"BooleanValue"===e.kind}(r)||function(e){return"StringValue"===e.kind}(r))e[t.value]=r.value;else if(function(e){return"ObjectValue"===e.kind}(r)){var c={};r.fields.map((function(e){return l(c,e.name,e.value,n)})),e[t.value]=c}else if(function(e){return"Variable"===e.kind}(r)){var f=(n||{})[r.name.value];e[t.value]=f}else if(function(e){return"ListValue"===e.kind}(r))e[t.value]=r.values.map((function(e){var r={};return l(r,t,e,n),r[t.value]}));else if(function(e){return"EnumValue"===e.kind}(r))e[t.value]=r.value;else{if(!function(e){return"NullValue"===e.kind}(r))throw new o.a(17);e[t.value]=null}}function f(e,t){if(e.arguments&&e.arguments.length){var r={};return e.arguments.forEach((function(e){var n=e.name,o=e.value;return l(r,n,o,t)})),r}return null}function h(e){return e.alias?e.alias.value:e.name.value}function d(e){return"Field"===e.kind}function v(e){return"InlineFragment"===e.kind}function y(e,t){return void 0===t&&(t={}),(r=e.directives,r?r.filter(Q).map((function(e){var t=e.arguments;e.name.value,Object(o.b)(t&&1===t.length,14);var r=t[0];Object(o.b)(r.name&&"if"===r.name.value,15);var n=r.value;return Object(o.b)(n&&("Variable"===n.kind||"BooleanValue"===n.kind),16),{directive:e,ifArgument:r}})):[]).every((function(e){var r=e.directive,n=e.ifArgument,c=!1;return"Variable"===n.value.kind?(c=t[n.value.name.value],Object(o.b)(void 0!==c,13)):c=n.value.value,"skip"===r.name.value?!c:c}));var r}function m(e,t){return function(e){var t=[];return Object(n.b)(e,{Directive:function(e){t.push(e.name.value)}}),t}(t).some((function(t){return e.indexOf(t)>-1}))}function O(e){return e&&m(["client"],e)&&m(["export"],e)}function Q(e){var t=e.name.value;return"skip"===t||"include"===t}function j(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];return t.forEach((function(source){null!=source&&Object.keys(source).forEach((function(t){e[t]=source[t]}))})),e}function _(e){Object(o.b)(e&&"Document"===e.kind,2);var t=e.definitions.filter((function(e){return"FragmentDefinition"!==e.kind})).map((function(e){if("OperationDefinition"!==e.kind)throw new o.a(3);return e}));return Object(o.b)(t.length<=1,4),e}function w(e){return _(e),e.definitions.filter((function(e){return"OperationDefinition"===e.kind}))[0]}function k(e){return e.definitions.filter((function(e){return"OperationDefinition"===e.kind&&e.name})).map((function(e){return e.name.value}))[0]||null}function S(e){return e.definitions.filter((function(e){return"FragmentDefinition"===e.kind}))}function R(e){var t;_(e);for(var r=0,n=e.definitions;r<n.length;r++){var c=n[r];if("OperationDefinition"===c.kind){var l=c.operation;if("query"===l||"mutation"===l||"subscription"===l)return c}"FragmentDefinition"!==c.kind||t||(t=c)}if(t)return t;throw new o.a(10)}function E(e){void 0===e&&(e=[]);var t={};return e.forEach((function(e){t[e.name.value]=e})),t}function P(e){if(e&&e.variableDefinitions&&e.variableDefinitions.length){var t=e.variableDefinitions.filter((function(e){return e.defaultValue})).map((function(e){var t=e.variable,r=e.defaultValue,n={};return l(n,t.name,r),n}));return j.apply(void 0,Object(c.__spreadArrays)([{}],t))}return{}}function M(e,t,r){var n=0;return e.forEach((function(r,i){t.call(this,r,i,e)&&(e[n++]=r)}),r),e.length=n,e}function I(e,t){return e.selectionSet.selections.every((function(e){return"FragmentSpread"===e.kind&&I(t[e.name.value],t)}))}function x(e){return I(w(e)||function(e){Object(o.b)("Document"===e.kind,7),Object(o.b)(e.definitions.length<=1,8);var t=e.definitions[0];return Object(o.b)("FragmentDefinition"===t.kind,9),t}(e),E(S(e)))?null:e}function F(e){return function(t){return e.some((function(e){return e.name&&e.name===t.name.value||e.test&&e.test(t)}))}}function C(e,t){var r=Object.create(null),o=[],l=Object.create(null),f=[],h=x(Object(n.b)(t,{Variable:{enter:function(e,t,n){"VariableDefinition"!==n.kind&&(r[e.name.value]=!0)}},Field:{enter:function(t){if(e&&t.directives&&(e.some((function(e){return e.remove}))&&t.directives&&t.directives.some(F(e))))return t.arguments&&t.arguments.forEach((function(e){"Variable"===e.value.kind&&o.push({name:e.value.name.value})})),t.selectionSet&&V(t.selectionSet).forEach((function(e){f.push({name:e.name.value})})),null}},FragmentSpread:{enter:function(e){l[e.name.value]=!0}},Directive:{enter:function(t){if(F(e)(t))return null}}}));return h&&M(o,(function(e){return!r[e.name]})).length&&(h=function(e,t){var r=function(e){return function(t){return e.some((function(e){return t.value&&"Variable"===t.value.kind&&t.value.name&&(e.name===t.value.name.value||e.test&&e.test(t))}))}}(e);return x(Object(n.b)(t,{OperationDefinition:{enter:function(t){return Object(c.__assign)(Object(c.__assign)({},t),{variableDefinitions:t.variableDefinitions.filter((function(t){return!e.some((function(e){return e.name===t.variable.name.value}))}))})}},Field:{enter:function(t){if(e.some((function(e){return e.remove}))){var n=0;if(t.arguments.forEach((function(e){r(e)&&(n+=1)})),1===n)return null}}},Argument:{enter:function(e){if(r(e))return null}}}))}(o,h)),h&&M(f,(function(e){return!l[e.name]})).length&&(h=function(e,t){function r(t){if(e.some((function(e){return e.name===t.name.value})))return null}return x(Object(n.b)(t,{FragmentSpread:{enter:r},FragmentDefinition:{enter:r}}))}(f,h)),h}var D={test:function(e){var t="connection"===e.name.value;return t&&(!e.arguments||e.arguments.some((function(e){return"key"===e.name.value}))),t}};function L(e){return C([D],_(e))}function V(e){var t=[];return e.selections.forEach((function(e){(d(e)||v(e))&&e.selectionSet?V(e.selectionSet).forEach((function(e){return t.push(e)})):"FragmentSpread"===e.kind&&t.push(e)})),t}function A(e){return"query"===R(e).operation?e:Object(n.b)(e,{OperationDefinition:{enter:function(e){return Object(c.__assign)(Object(c.__assign)({},e),{operation:"query"})}}})}function N(e){_(e);var t=C([{test:function(e){return"client"===e.name.value},remove:!0}],e);return t&&(t=Object(n.b)(t,{FragmentDefinition:{enter:function(e){if(e.selectionSet&&e.selectionSet.selections.every((function(e){return d(e)&&"__typename"===e.name.value})))return null}}})),t}var T="function"==typeof WeakMap&&!("object"==typeof navigator&&"ReactNative"===navigator.product),B=Object.prototype.toString;function H(e){return U(e,new Map)}function U(e,t){switch(B.call(e)){case"[object Array]":if(t.has(e))return t.get(e);var r=e.slice(0);return t.set(e,r),r.forEach((function(e,i){r[i]=U(e,t)})),r;case"[object Object]":if(t.has(e))return t.get(e);var n=Object.create(Object.getPrototypeOf(e));return t.set(e,n),Object.keys(e).forEach((function(r){n[r]=U(e[r],t)})),n;default:return e}}function z(e){try{return e()}catch(e){console.error&&console.error(e)}}function G(e){return e.errors&&e.errors.length}var W=Object.prototype.hasOwnProperty;function J(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return Y(e)}function Y(e){var t=e[0]||{},r=e.length;if(r>1){var n=[];t=X(t,n);for(var i=1;i<r;++i)t=$(t,e[i],n)}return t}function K(e){return null!==e&&"object"==typeof e}function $(e,source,t){return K(source)&&K(e)?(Object.isExtensible&&!Object.isExtensible(e)&&(e=X(e,t)),Object.keys(source).forEach((function(r){var n=source[r];if(W.call(e,r)){var o=e[r];n!==o&&(e[r]=$(X(o,t),n,t))}else e[r]=n})),e):source}function X(e,t){return null!==e&&"object"==typeof e&&t.indexOf(e)<0&&(e=Array.isArray(e)?e.slice(0):Object(c.__assign)({__proto__:Object.getPrototypeOf(e)},e),t.push(e)),e}Object.create({})}).call(this,r(70))},273:function(e,t,r){"use strict";r.d(t,"a",(function(){return O}));var n=r(39),o=r(40),c=r(127),l=r(402),f={generateHash:function(e){return l().update(Object(c.print)(e)).digest("hex")},disable:function(e){var t=e.graphQLErrors,r=e.operation;if(t&&t.some((function(e){return"PersistedQueryNotSupported"===e.message})))return!0;var n=r.getContext().response;return!(!n||!n.status||400!==n.status&&500!==n.status)},useGETForHashedQueries:!1};function h(e){return"OperationDefinition"===e.kind&&"mutation"===e.operation}var d=Object.prototype.hasOwnProperty,v="__createPersistedQueryLink_hashes",y="function"==typeof Symbol?Symbol.for(v):v,m=0,O=function(e){void 0===e&&(e={});var t=Object.assign({},f,e),r=t.generateHash,c=t.disable,l=t.useGETForHashedQueries,v=!0,O="forLink"+m++;function Q(e){if(!e||"object"!=typeof e)return r(e);d.call(e,y)||Object.defineProperty(e,y,{value:Object.create(null),enumerable:!1});var t=e[y];return d.call(t,O)?t[O]:t[O]=r(e)}return new n.ApolloLink((function(e,t){if(!t)throw new Error("PersistedQueryLink cannot be the last link in the chain.");var r,n=e.query;if(v)try{e.extensions.persistedQuery={version:1,sha256Hash:Q(n)}}catch(e){r=e}return new o.a((function(n){if(!r){var o,f,d=!1,y=!1,m=function(r,n){var l=r.response,h=r.networkError;if(!d&&(l&&l.errors||h)){d=!0;var m={response:l,networkError:h,operation:e,graphQLErrors:l?l.errors:void 0};if(v=!c(m),l&&l.errors&&l.errors.some((function(e){return"PersistedQueryNotFound"===e.message}))||!v)return o&&o.unsubscribe(),e.setContext({http:{includeQuery:!0,includeExtensions:v}}),y&&e.setContext({fetchOptions:f}),void(o=t(e).subscribe(O))}n()},O={next:function(e){m({response:e},(function(){return n.next(e)}))},error:function(e){m({networkError:e},(function(){return n.error(e)}))},complete:n.complete.bind(n)};return e.setContext({http:{includeQuery:!v,includeExtensions:v}}),l&&v&&function(e){return!e.query.definitions.some(h)}(e)&&(e.setContext((function(e){var t=e.fetchOptions,r=void 0===t?{}:t;return f=r,{fetchOptions:Object.assign({},r,{method:"GET"})}})),y=!0),o=t(e).subscribe(O),function(){o&&o.unsubscribe()}}n.error(r)}))}))}},277:function(e,t,r){"use strict";r.d(t,"a",(function(){return l}));var n=r(0),o=r(39),c=r(40);function l(e){return new o.ApolloLink((function(t,r){var o=Object(n.__rest)(t,[]);return new c.a((function(n){var c;return Promise.resolve(o).then((function(r){return e(r,t.getContext())})).then(t.setContext).then((function(){c=r(t).subscribe({next:n.next.bind(n),error:n.error.bind(n),complete:n.complete.bind(n)})})).catch(n.error.bind(n)),function(){c&&c.unsubscribe()}}))}))}},278:function(e,t,r){"use strict";r.d(t,"a",(function(){return l}));var n=r(0),o=r(39),c=r(132),l=function(e){function t(t){var r=e.call(this)||this;return t instanceof c.SubscriptionClient?r.subscriptionClient=t:r.subscriptionClient=new c.SubscriptionClient(t.uri,t.options,t.webSocketImpl),r}return Object(n.__extends)(t,e),t.prototype.request=function(e){return this.subscriptionClient.request(e)},t}(o.ApolloLink)},280:function(e,t,r){"use strict";r.d(t,"a",(function(){return D}));var n,o=r(0),c=r(18),l=r(38),f=r(40),h=r(39),d=r(203),v=r(2),y=r(6);function m(e){return e<7}!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"}(n||(n={}));var O=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Object(o.__extends)(t,e),t.prototype[d.default]=function(){return this},t.prototype["@@observable"]=function(){return this},t}(f.a);function Q(e){return Array.isArray(e)&&e.length>0}var j,_=function(e){function t(r){var n,o,c=r.graphQLErrors,l=r.networkError,f=r.errorMessage,h=r.extraInfo,d=e.call(this,f)||this;return d.graphQLErrors=c||[],d.networkError=l||null,d.message=f||(o="",Q((n=d).graphQLErrors)&&n.graphQLErrors.forEach((function(e){var t=e?e.message:"Error message not found.";o+="GraphQL error: "+t+"\n"})),n.networkError&&(o+="Network error: "+n.networkError.message+"\n"),o=o.replace(/\n$/,"")),d.extraInfo=h,d.__proto__=t.prototype,d}return Object(o.__extends)(t,e),t}(Error);!function(e){e[e.normal=1]="normal",e[e.refetch=2]="refetch",e[e.poll=3]="poll"}(j||(j={}));var w=function(e){function t(t){var r=t.queryManager,n=t.options,o=t.shouldSubscribe,l=void 0===o||o,f=e.call(this,(function(e){return f.onSubscribe(e)}))||this;f.observers=new Set,f.subscriptions=new Set,f.isTornDown=!1,f.options=n,f.variables=n.variables||{},f.queryId=r.generateQueryId(),f.shouldSubscribe=l;var h=Object(c.i)(n.query);return f.queryName=h&&h.name&&h.name.value,f.queryManager=r,f}return Object(o.__extends)(t,e),t.prototype.result=function(){var e=this;return new Promise((function(t,r){var n={next:function(r){t(r),e.observers.delete(n),e.observers.size||e.queryManager.removeQuery(e.queryId),setTimeout((function(){o.unsubscribe()}),0)},error:r},o=e.subscribe(n)}))},t.prototype.currentResult=function(){var e=this.getCurrentResult();return void 0===e.data&&(e.data={}),e},t.prototype.getCurrentResult=function(){if(this.isTornDown){var e=this.lastResult;return{data:!this.lastError&&e&&e.data||void 0,error:this.lastError,loading:!1,networkStatus:n.error}}var t,r,c,l=this.queryManager.getCurrentQueryResult(this),data=l.data,f=l.partial,h=this.queryManager.queryStore.get(this.queryId),d=this.options.fetchPolicy,v="network-only"===d||"no-cache"===d;if(h){var y=h.networkStatus;if(r=h,void 0===(c=this.options.errorPolicy)&&(c="none"),r&&(r.networkError||"none"===c&&Q(r.graphQLErrors)))return{data:void 0,loading:!1,networkStatus:y,error:new _({graphQLErrors:h.graphQLErrors,networkError:h.networkError})};h.variables&&(this.options.variables=Object(o.__assign)(Object(o.__assign)({},this.options.variables),h.variables),this.variables=this.options.variables),t={data:data,loading:m(y),networkStatus:y},h.graphQLErrors&&"all"===this.options.errorPolicy&&(t.errors=h.graphQLErrors)}else{var O=v||f&&"cache-only"!==d;t={data:data,loading:O,networkStatus:O?n.loading:n.ready}}return f||this.updateLastResult(Object(o.__assign)(Object(o.__assign)({},t),{stale:!1})),Object(o.__assign)(Object(o.__assign)({},t),{partial:f})},t.prototype.isDifferentFromLastResult=function(e){var t=this.lastResultSnapshot;return!(t&&e&&t.networkStatus===e.networkStatus&&t.stale===e.stale&&Object(l.a)(t.data,e.data))},t.prototype.getLastResult=function(){return this.lastResult},t.prototype.getLastError=function(){return this.lastError},t.prototype.resetLastResults=function(){delete this.lastResult,delete this.lastResultSnapshot,delete this.lastError,this.isTornDown=!1},t.prototype.resetQueryStoreErrors=function(){var e=this.queryManager.queryStore.get(this.queryId);e&&(e.networkError=null,e.graphQLErrors=[])},t.prototype.refetch=function(e){var t=this.options.fetchPolicy;return"cache-only"===t?Promise.reject(new v.a(1)):("no-cache"!==t&&"cache-and-network"!==t&&(t="network-only"),Object(l.a)(this.variables,e)||(this.variables=Object(o.__assign)(Object(o.__assign)({},this.variables),e)),Object(l.a)(this.options.variables,this.variables)||(this.options.variables=Object(o.__assign)(Object(o.__assign)({},this.options.variables),this.variables)),this.queryManager.fetchQuery(this.queryId,Object(o.__assign)(Object(o.__assign)({},this.options),{fetchPolicy:t}),j.refetch))},t.prototype.fetchMore=function(e){var t=this;Object(v.b)(e.updateQuery,2);var r=Object(o.__assign)(Object(o.__assign)({},e.query?e:Object(o.__assign)(Object(o.__assign)(Object(o.__assign)({},this.options),e),{variables:Object(o.__assign)(Object(o.__assign)({},this.variables),e.variables)})),{fetchPolicy:"network-only"}),n=this.queryManager.generateQueryId();return this.queryManager.fetchQuery(n,r,j.normal,this.queryId).then((function(o){return t.updateQuery((function(t){return e.updateQuery(t,{fetchMoreResult:o.data,variables:r.variables})})),t.queryManager.stopQuery(n),o}),(function(e){throw t.queryManager.stopQuery(n),e}))},t.prototype.subscribeToMore=function(e){var t=this,r=this.queryManager.startGraphQLSubscription({query:e.document,variables:e.variables}).subscribe({next:function(r){var n=e.updateQuery;n&&t.updateQuery((function(e,t){var o=t.variables;return n(e,{subscriptionData:r,variables:o})}))},error:function(t){e.onError&&e.onError(t)}});return this.subscriptions.add(r),function(){t.subscriptions.delete(r)&&r.unsubscribe()}},t.prototype.setOptions=function(e){var t=this.options.fetchPolicy;this.options=Object(o.__assign)(Object(o.__assign)({},this.options),e),e.pollInterval?this.startPolling(e.pollInterval):0===e.pollInterval&&this.stopPolling();var r=e.fetchPolicy;return this.setVariables(this.options.variables,t!==r&&("cache-only"===t||"standby"===t||"network-only"===r),e.fetchResults)},t.prototype.setVariables=function(e,t,r){return void 0===t&&(t=!1),void 0===r&&(r=!0),this.isTornDown=!1,e=e||this.variables,!t&&Object(l.a)(e,this.variables)?this.observers.size&&r?this.result():Promise.resolve():(this.variables=this.options.variables=e,this.observers.size?this.queryManager.fetchQuery(this.queryId,this.options):Promise.resolve())},t.prototype.updateQuery=function(e){var t=this.queryManager,r=t.getQueryWithPreviousResult(this.queryId),n=r.previousResult,o=r.variables,l=r.document,f=Object(c.v)((function(){return e(n,{variables:o})}));f&&(t.dataStore.markUpdateQueryResult(l,o,f),t.broadcastQueries())},t.prototype.stopPolling=function(){this.queryManager.stopPollingQuery(this.queryId),this.options.pollInterval=void 0},t.prototype.startPolling=function(e){R(this),this.options.pollInterval=e,this.queryManager.startPollingQuery(this.options,this.queryId)},t.prototype.updateLastResult=function(e){var t=this.lastResult;return this.lastResult=e,this.lastResultSnapshot=this.queryManager.assumeImmutableResults?e:Object(c.d)(e),t},t.prototype.onSubscribe=function(e){var t=this;try{var r=e._subscription._observer;r&&!r.error&&(r.error=k)}catch(e){}var n=!this.observers.size;return this.observers.add(e),e.next&&this.lastResult&&e.next(this.lastResult),e.error&&this.lastError&&e.error(this.lastError),n&&this.setUpQuery(),function(){t.observers.delete(e)&&!t.observers.size&&t.tearDownQuery()}},t.prototype.setUpQuery=function(){var e=this,t=this.queryManager,r=this.queryId;this.shouldSubscribe&&t.addObservableQuery(r,this),this.options.pollInterval&&(R(this),t.startPollingQuery(this.options,r));var c=function(t){e.updateLastResult(Object(o.__assign)(Object(o.__assign)({},e.lastResult),{errors:t.graphQLErrors,networkStatus:n.error,loading:!1})),S(e.observers,"error",e.lastError=t)};t.observeQuery(r,this.options,{next:function(r){if(e.lastError||e.isDifferentFromLastResult(r)){var n=e.updateLastResult(r),o=e.options,c=o.query,f=o.variables,h=o.fetchPolicy;t.transform(c).hasClientExports?t.getLocalState().addExportedVariables(c,f).then((function(o){var f=e.variables;e.variables=e.options.variables=o,!r.loading&&n&&"cache-only"!==h&&t.transform(c).serverQuery&&!Object(l.a)(f,o)?e.refetch():S(e.observers,"next",r)})):S(e.observers,"next",r)}},error:c}).catch(c)},t.prototype.tearDownQuery=function(){var e=this.queryManager;this.isTornDown=!0,e.stopPollingQuery(this.queryId),this.subscriptions.forEach((function(sub){return sub.unsubscribe()})),this.subscriptions.clear(),e.removeObservableQuery(this.queryId),e.stopQuery(this.queryId),this.observers.clear()},t}(O);function k(e){}function S(e,t,r){var n=[];e.forEach((function(e){return e[t]&&n.push(e)})),n.forEach((function(e){return e[t](r)}))}function R(e){var t=e.options.fetchPolicy;Object(v.b)("cache-first"!==t&&"cache-only"!==t,3)}var E=function(){function e(){this.store={}}return e.prototype.getStore=function(){return this.store},e.prototype.get=function(e){return this.store[e]},e.prototype.initMutation=function(e,t,r){this.store[e]={mutation:t,variables:r||{},loading:!0,error:null}},e.prototype.markMutationError=function(e,t){var r=this.store[e];r&&(r.loading=!1,r.error=t)},e.prototype.markMutationResult=function(e){var t=this.store[e];t&&(t.loading=!1,t.error=null)},e.prototype.reset=function(){this.store={}},e}(),P=function(){function e(){this.store={}}return e.prototype.getStore=function(){return this.store},e.prototype.get=function(e){return this.store[e]},e.prototype.initQuery=function(e){var t=this.store[e.queryId];Object(v.b)(!t||t.document===e.document||Object(l.a)(t.document,e.document),19);var r,o=!1,c=null;e.storePreviousVariables&&t&&t.networkStatus!==n.loading&&(Object(l.a)(t.variables,e.variables)||(o=!0,c=t.variables)),r=o?n.setVariables:e.isPoll?n.poll:e.isRefetch?n.refetch:n.loading;var f=[];t&&t.graphQLErrors&&(f=t.graphQLErrors),this.store[e.queryId]={document:e.document,variables:e.variables,previousVariables:c,networkError:null,graphQLErrors:f,networkStatus:r,metadata:e.metadata},"string"==typeof e.fetchMoreForQueryId&&this.store[e.fetchMoreForQueryId]&&(this.store[e.fetchMoreForQueryId].networkStatus=n.fetchMore)},e.prototype.markQueryResult=function(e,t,r){this.store&&this.store[e]&&(this.store[e].networkError=null,this.store[e].graphQLErrors=Q(t.errors)?t.errors:[],this.store[e].previousVariables=null,this.store[e].networkStatus=n.ready,"string"==typeof r&&this.store[r]&&(this.store[r].networkStatus=n.ready))},e.prototype.markQueryError=function(e,t,r){this.store&&this.store[e]&&(this.store[e].networkError=t,this.store[e].networkStatus=n.error,"string"==typeof r&&this.markQueryResultClient(r,!0))},e.prototype.markQueryResultClient=function(e,t){var r=this.store&&this.store[e];r&&(r.networkError=null,r.previousVariables=null,t&&(r.networkStatus=n.ready))},e.prototype.stopQuery=function(e){delete this.store[e]},e.prototype.reset=function(e){var t=this;Object.keys(this.store).forEach((function(r){e.indexOf(r)<0?t.stopQuery(r):t.store[r].networkStatus=n.loading}))},e}();var M=function(){function e(e){var t=e.cache,r=e.client,n=e.resolvers,o=e.fragmentMatcher;this.cache=t,r&&(this.client=r),n&&this.addResolvers(n),o&&this.setFragmentMatcher(o)}return e.prototype.addResolvers=function(e){var t=this;this.resolvers=this.resolvers||{},Array.isArray(e)?e.forEach((function(e){t.resolvers=Object(c.p)(t.resolvers,e)})):this.resolvers=Object(c.p)(this.resolvers,e)},e.prototype.setResolvers=function(e){this.resolvers={},this.addResolvers(e)},e.prototype.getResolvers=function(){return this.resolvers||{}},e.prototype.runResolvers=function(e){var t=e.document,r=e.remoteResult,n=e.context,c=e.variables,l=e.onlyRunForcedResolvers,f=void 0!==l&&l;return Object(o.__awaiter)(this,void 0,void 0,(function(){return Object(o.__generator)(this,(function(e){return t?[2,this.resolveDocument(t,r.data,n,c,this.fragmentMatcher,f).then((function(e){return Object(o.__assign)(Object(o.__assign)({},r),{data:e.result})}))]:[2,r]}))}))},e.prototype.setFragmentMatcher=function(e){this.fragmentMatcher=e},e.prototype.getFragmentMatcher=function(){return this.fragmentMatcher},e.prototype.clientQuery=function(e){return Object(c.m)(["client"],e)&&this.resolvers?e:null},e.prototype.serverQuery=function(e){return this.resolvers?Object(c.r)(e):e},e.prototype.prepareContext=function(e){void 0===e&&(e={});var t=this.cache;return Object(o.__assign)(Object(o.__assign)({},e),{cache:t,getCacheKey:function(e){if(t.config)return t.config.dataIdFromObject(e);Object(v.b)(!1,6)}})},e.prototype.addExportedVariables=function(e,t,r){return void 0===t&&(t={}),void 0===r&&(r={}),Object(o.__awaiter)(this,void 0,void 0,(function(){return Object(o.__generator)(this,(function(n){return e?[2,this.resolveDocument(e,this.buildRootValueFromCache(e,t)||{},this.prepareContext(r),t).then((function(data){return Object(o.__assign)(Object(o.__assign)({},t),data.exportedVariables)}))]:[2,Object(o.__assign)({},t)]}))}))},e.prototype.shouldForceResolvers=function(e){var t=!1;return Object(y.b)(e,{Directive:{enter:function(e){if("client"===e.name.value&&e.arguments&&(t=e.arguments.some((function(e){return"always"===e.name.value&&"BooleanValue"===e.value.kind&&!0===e.value.value}))))return y.a}}}),t},e.prototype.buildRootValueFromCache=function(e,t){return this.cache.diff({query:Object(c.b)(e),variables:t,returnPartialData:!0,optimistic:!1}).result},e.prototype.resolveDocument=function(e,t,r,n,l,f){return void 0===r&&(r={}),void 0===n&&(n={}),void 0===l&&(l=function(){return!0}),void 0===f&&(f=!1),Object(o.__awaiter)(this,void 0,void 0,(function(){var h,d,v,y,m,O,Q,j,_;return Object(o.__generator)(this,(function(w){var k;return h=Object(c.h)(e),d=Object(c.g)(e),v=Object(c.e)(d),y=h.operation,m=y?(k=y).charAt(0).toUpperCase()+k.slice(1):"Query",Q=(O=this).cache,j=O.client,_={fragmentMap:v,context:Object(o.__assign)(Object(o.__assign)({},r),{cache:Q,client:j}),variables:n,fragmentMatcher:l,defaultOperationType:m,exportedVariables:{},onlyRunForcedResolvers:f},[2,this.resolveSelectionSet(h.selectionSet,t,_).then((function(e){return{result:e,exportedVariables:_.exportedVariables}}))]}))}))},e.prototype.resolveSelectionSet=function(e,t,r){return Object(o.__awaiter)(this,void 0,void 0,(function(){var n,l,f,h,d,y=this;return Object(o.__generator)(this,(function(m){return n=r.fragmentMap,l=r.context,f=r.variables,h=[t],d=function(e){return Object(o.__awaiter)(y,void 0,void 0,(function(){var d,y;return Object(o.__generator)(this,(function(o){return Object(c.u)(e,f)?Object(c.n)(e)?[2,this.resolveField(e,t,r).then((function(t){var r;void 0!==t&&h.push(((r={})[Object(c.t)(e)]=t,r))}))]:(Object(c.o)(e)?d=e:(d=n[e.name.value],Object(v.b)(d,7)),d&&d.typeCondition&&(y=d.typeCondition.name.value,r.fragmentMatcher(t,y,l))?[2,this.resolveSelectionSet(d.selectionSet,t,r).then((function(e){h.push(e)}))]:[2]):[2]}))}))},[2,Promise.all(e.selections.map(d)).then((function(){return Object(c.q)(h)}))]}))}))},e.prototype.resolveField=function(e,t,r){return Object(o.__awaiter)(this,void 0,void 0,(function(){var n,l,f,h,d,v,y,m,O,Q=this;return Object(o.__generator)(this,(function(o){return n=r.variables,l=e.name.value,f=Object(c.t)(e),h=l!==f,d=t[f]||t[l],v=Promise.resolve(d),r.onlyRunForcedResolvers&&!this.shouldForceResolvers(e)||(y=t.__typename||r.defaultOperationType,(m=this.resolvers&&this.resolvers[y])&&(O=m[h?l:f])&&(v=Promise.resolve(O(t,Object(c.a)(e,n),r.context,{field:e,fragmentMap:r.fragmentMap})))),[2,v.then((function(t){return void 0===t&&(t=d),e.directives&&e.directives.forEach((function(e){"export"===e.name.value&&e.arguments&&e.arguments.forEach((function(e){"as"===e.name.value&&"StringValue"===e.value.kind&&(r.exportedVariables[e.value.value]=t)}))})),e.selectionSet?null==t?t:Array.isArray(t)?Q.resolveSubSelectedArray(e,t,r):e.selectionSet?Q.resolveSelectionSet(e.selectionSet,t,r):void 0:t}))]}))}))},e.prototype.resolveSubSelectedArray=function(e,t,r){var n=this;return Promise.all(t.map((function(t){return null===t?null:Array.isArray(t)?n.resolveSubSelectedArray(e,t,r):e.selectionSet?n.resolveSelectionSet(e.selectionSet,t,r):void 0})))},e}();function I(e){var t=new Set,sub=null;return new O((function(r){return t.add(r),sub=sub||e.subscribe({next:function(e){t.forEach((function(t){return t.next&&t.next(e)}))},error:function(e){t.forEach((function(t){return t.error&&t.error(e)}))},complete:function(){t.forEach((function(e){return e.complete&&e.complete()}))}}),function(){t.delete(r)&&!t.size&&sub&&(sub.unsubscribe(),sub=null)}}))}var x=Object.prototype.hasOwnProperty,F=function(){function e(e){var link=e.link,t=e.queryDeduplication,r=void 0!==t&&t,n=e.store,o=e.onBroadcast,l=void 0===o?function(){}:o,f=e.ssrMode,h=void 0!==f&&f,d=e.clientAwareness,v=void 0===d?{}:d,y=e.localState,m=e.assumeImmutableResults;this.mutationStore=new E,this.queryStore=new P,this.clientAwareness={},this.idCounter=1,this.queries=new Map,this.fetchQueryRejectFns=new Map,this.transformCache=new(c.c?WeakMap:Map),this.inFlightLinkObservables=new Map,this.pollingInfoByQueryId=new Map,this.link=link,this.queryDeduplication=r,this.dataStore=n,this.onBroadcast=l,this.clientAwareness=v,this.localState=y||new M({cache:n.getCache()}),this.ssrMode=h,this.assumeImmutableResults=!!m}return e.prototype.stop=function(){var e=this;this.queries.forEach((function(t,r){e.stopQueryNoBroadcast(r)})),this.fetchQueryRejectFns.forEach((function(e){e(new v.a(8))}))},e.prototype.mutate=function(e){var t=e.mutation,r=e.variables,n=e.optimisticResponse,l=e.updateQueries,f=e.refetchQueries,h=void 0===f?[]:f,d=e.awaitRefetchQueries,y=void 0!==d&&d,m=e.update,O=e.errorPolicy,j=void 0===O?"none":O,w=e.fetchPolicy,k=e.context,S=void 0===k?{}:k;return Object(o.__awaiter)(this,void 0,void 0,(function(){var e,f,d,O=this;return Object(o.__generator)(this,(function(k){switch(k.label){case 0:return Object(v.b)(t,9),Object(v.b)(!w||"no-cache"===w,10),e=this.generateQueryId(),t=this.transform(t).document,this.setQuery(e,(function(){return{document:t}})),r=this.getVariables(t,r),this.transform(t).hasClientExports?[4,this.localState.addExportedVariables(t,r,S)]:[3,2];case 1:r=k.sent(),k.label=2;case 2:return f=function(){var e={};return l&&O.queries.forEach((function(t,r){var n=t.observableQuery;if(n){var o=n.queryName;o&&x.call(l,o)&&(e[r]={updater:l[o],query:O.queryStore.get(r)})}})),e},this.mutationStore.initMutation(e,t,r),this.dataStore.markMutationInit({mutationId:e,document:t,variables:r,updateQueries:f(),update:m,optimisticResponse:n}),this.broadcastQueries(),d=this,[2,new Promise((function(l,v){var O,k;d.getObservableFromLink(t,Object(o.__assign)(Object(o.__assign)({},S),{optimisticResponse:n}),r,!1).subscribe({next:function(n){Object(c.k)(n)&&"none"===j?k=new _({graphQLErrors:n.errors}):(d.mutationStore.markMutationResult(e),"no-cache"!==w&&d.dataStore.markMutationResult({mutationId:e,result:n,document:t,variables:r,updateQueries:f(),update:m}),O=n)},error:function(t){d.mutationStore.markMutationError(e,t),d.dataStore.markMutationComplete({mutationId:e,optimisticResponse:n}),d.broadcastQueries(),d.setQuery(e,(function(){return{document:null}})),v(new _({networkError:t}))},complete:function(){if(k&&d.mutationStore.markMutationError(e,k),d.dataStore.markMutationComplete({mutationId:e,optimisticResponse:n}),d.broadcastQueries(),k)v(k);else{"function"==typeof h&&(h=h(O));var t=[];Q(h)&&h.forEach((function(e){if("string"==typeof e)d.queries.forEach((function(r){var n=r.observableQuery;n&&n.queryName===e&&t.push(n.refetch())}));else{var r={query:e.query,variables:e.variables,fetchPolicy:"network-only"};e.context&&(r.context=e.context),t.push(d.query(r))}})),Promise.all(y?t:[]).then((function(){d.setQuery(e,(function(){return{document:null}})),"ignore"===j&&O&&Object(c.k)(O)&&delete O.errors,l(O)}))}}})}))]}}))}))},e.prototype.fetchQuery=function(e,t,r,n){return Object(o.__awaiter)(this,void 0,void 0,(function(){var l,f,h,d,v,y,m,O,Q,w,k,S,R,E,P,M,I,x,F=this;return Object(o.__generator)(this,(function(C){switch(C.label){case 0:return l=t.metadata,f=void 0===l?null:l,h=t.fetchPolicy,d=void 0===h?"cache-first":h,v=t.context,y=void 0===v?{}:v,m=this.transform(t.query).document,O=this.getVariables(m,t.variables),this.transform(m).hasClientExports?[4,this.localState.addExportedVariables(m,O,y)]:[3,2];case 1:O=C.sent(),C.label=2;case 2:if(t=Object(o.__assign)(Object(o.__assign)({},t),{variables:O}),k=w="network-only"===d||"no-cache"===d,w||(S=this.dataStore.getCache().diff({query:m,variables:O,returnPartialData:!0,optimistic:!1}),R=S.complete,E=S.result,k=!R||"cache-and-network"===d,Q=E),P=k&&"cache-only"!==d&&"standby"!==d,Object(c.m)(["live"],m)&&(P=!0),M=this.idCounter++,I="no-cache"!==d?this.updateQueryWatch(e,m,t):void 0,this.setQuery(e,(function(){return{document:m,lastRequestId:M,invalidated:!0,cancel:I}})),this.invalidate(n),this.queryStore.initQuery({queryId:e,document:m,storePreviousVariables:P,variables:O,isPoll:r===j.poll,isRefetch:r===j.refetch,metadata:f,fetchMoreForQueryId:n}),this.broadcastQueries(),P){if(x=this.fetchRequest({requestId:M,queryId:e,document:m,options:t,fetchMoreForQueryId:n}).catch((function(t){throw t.hasOwnProperty("graphQLErrors")?t:(M>=F.getQuery(e).lastRequestId&&(F.queryStore.markQueryError(e,t,n),F.invalidate(e),F.invalidate(n),F.broadcastQueries()),new _({networkError:t}))})),"cache-and-network"!==d)return[2,x];x.catch((function(){}))}return this.queryStore.markQueryResultClient(e,!P),this.invalidate(e),this.invalidate(n),this.transform(m).hasForcedResolvers?[2,this.localState.runResolvers({document:m,remoteResult:{data:Q},context:y,variables:O,onlyRunForcedResolvers:!0}).then((function(r){return F.markQueryResult(e,r,t,n),F.broadcastQueries(),r}))]:(this.broadcastQueries(),[2,{data:Q}])}}))}))},e.prototype.markQueryResult=function(e,t,r,n){var o=r.fetchPolicy,c=r.variables,l=r.errorPolicy;"no-cache"===o?this.setQuery(e,(function(){return{newData:{result:t.data,complete:!0}}})):this.dataStore.markQueryResult(t,this.getQuery(e).document,c,n,"ignore"===l||"all"===l)},e.prototype.queryListenerForObserver=function(e,t,r){var n=this;function o(e,t){if(r[e])try{r[e](t)}catch(e){}}return function(r,c){if(n.invalidate(e,!1),r){var l=n.getQuery(e),f=l.observableQuery,h=l.document,d=f?f.options.fetchPolicy:t.fetchPolicy;if("standby"!==d){var v=m(r.networkStatus),y=f&&f.getLastResult(),O=!(!y||y.networkStatus===r.networkStatus),j=t.returnPartialData||!c&&r.previousVariables||O&&t.notifyOnNetworkStatusChange||"cache-only"===d||"cache-and-network"===d;if(!v||j){var w=Q(r.graphQLErrors),k=f&&f.options.errorPolicy||t.errorPolicy||"none";if("none"===k&&w||r.networkError)return o("error",new _({graphQLErrors:r.graphQLErrors,networkError:r.networkError}));try{var data=void 0,S=void 0;if(c)"no-cache"!==d&&"network-only"!==d&&n.setQuery(e,(function(){return{newData:null}})),data=c.result,S=!c.complete;else{var R=f&&f.getLastError(),E="none"!==k&&(R&&R.graphQLErrors)!==r.graphQLErrors;if(y&&y.data&&!E)data=y.data,S=!1;else{var P=n.dataStore.getCache().diff({query:h,variables:r.previousVariables||r.variables,returnPartialData:!0,optimistic:!0});data=P.result,S=!P.complete}}var M=S&&!(t.returnPartialData||"cache-only"===d),I={data:M?y&&y.data:data,loading:v,networkStatus:r.networkStatus,stale:M};"all"===k&&w&&(I.errors=r.graphQLErrors),o("next",I)}catch(e){o("error",new _({networkError:e}))}}}}}},e.prototype.transform=function(e){var t=this.transformCache;if(!t.has(e)){var r=this.dataStore.getCache(),n=r.transformDocument(e),o=Object(c.s)(r.transformForLink(n)),l=this.localState.clientQuery(n),f=this.localState.serverQuery(o),h={document:n,hasClientExports:Object(c.l)(n),hasForcedResolvers:this.localState.shouldForceResolvers(n),clientQuery:l,serverQuery:f,defaultVars:Object(c.f)(Object(c.i)(n))},d=function(e){e&&!t.has(e)&&t.set(e,h)};d(e),d(n),d(l),d(f)}return t.get(e)},e.prototype.getVariables=function(e,t){return Object(o.__assign)(Object(o.__assign)({},this.transform(e).defaultVars),t)},e.prototype.watchQuery=function(e,t){void 0===t&&(t=!0),Object(v.b)("standby"!==e.fetchPolicy,11),e.variables=this.getVariables(e.query,e.variables),void 0===e.notifyOnNetworkStatusChange&&(e.notifyOnNetworkStatusChange=!1);var r=Object(o.__assign)({},e);return new w({queryManager:this,options:r,shouldSubscribe:t})},e.prototype.query=function(e){var t=this;return Object(v.b)(e.query,12),Object(v.b)("Document"===e.query.kind,13),Object(v.b)(!e.returnPartialData,14),Object(v.b)(!e.pollInterval,15),new Promise((function(r,n){var o=t.watchQuery(e,!1);t.fetchQueryRejectFns.set("query:"+o.queryId,n),o.result().then(r,n).then((function(){return t.fetchQueryRejectFns.delete("query:"+o.queryId)}))}))},e.prototype.generateQueryId=function(){return String(this.idCounter++)},e.prototype.stopQueryInStore=function(e){this.stopQueryInStoreNoBroadcast(e),this.broadcastQueries()},e.prototype.stopQueryInStoreNoBroadcast=function(e){this.stopPollingQuery(e),this.queryStore.stopQuery(e),this.invalidate(e)},e.prototype.addQueryListener=function(e,t){this.setQuery(e,(function(e){return e.listeners.add(t),{invalidated:!1}}))},e.prototype.updateQueryWatch=function(e,t,r){var n=this,o=this.getQuery(e).cancel;o&&o();return this.dataStore.getCache().watch({query:t,variables:r.variables,optimistic:!0,previousResult:function(){var t=null,r=n.getQuery(e).observableQuery;if(r){var o=r.getLastResult();o&&(t=o.data)}return t},callback:function(t){n.setQuery(e,(function(){return{invalidated:!0,newData:t}}))}})},e.prototype.addObservableQuery=function(e,t){this.setQuery(e,(function(){return{observableQuery:t}}))},e.prototype.removeObservableQuery=function(e){var t=this.getQuery(e).cancel;this.setQuery(e,(function(){return{observableQuery:null}})),t&&t()},e.prototype.clearStore=function(){this.fetchQueryRejectFns.forEach((function(e){e(new v.a(16))}));var e=[];return this.queries.forEach((function(t,r){t.observableQuery&&e.push(r)})),this.queryStore.reset(e),this.mutationStore.reset(),this.dataStore.reset()},e.prototype.resetStore=function(){var e=this;return this.clearStore().then((function(){return e.reFetchObservableQueries()}))},e.prototype.reFetchObservableQueries=function(e){var t=this;void 0===e&&(e=!1);var r=[];return this.queries.forEach((function(n,o){var c=n.observableQuery;if(c){var l=c.options.fetchPolicy;c.resetLastResults(),"cache-only"===l||!e&&"standby"===l||r.push(c.refetch()),t.setQuery(o,(function(){return{newData:null}})),t.invalidate(o)}})),this.broadcastQueries(),Promise.all(r)},e.prototype.observeQuery=function(e,t,r){return this.addQueryListener(e,this.queryListenerForObserver(e,t,r)),this.fetchQuery(e,t)},e.prototype.startQuery=function(e,t,r){return this.addQueryListener(e,r),this.fetchQuery(e,t).catch((function(){})),e},e.prototype.startGraphQLSubscription=function(e){var t=this,r=e.query,n=e.fetchPolicy,o=e.variables;r=this.transform(r).document,o=this.getVariables(r,o);var l=function(e){return t.getObservableFromLink(r,{},e,!1).map((function(o){if(n&&"no-cache"===n||(t.dataStore.markSubscriptionResult(o,r,e),t.broadcastQueries()),Object(c.k)(o))throw new _({graphQLErrors:o.errors});return o}))};if(this.transform(r).hasClientExports){var f=this.localState.addExportedVariables(r,o).then(l);return new O((function(e){var sub=null;return f.then((function(t){return sub=t.subscribe(e)}),e.error),function(){return sub&&sub.unsubscribe()}}))}return l(o)},e.prototype.stopQuery=function(e){this.stopQueryNoBroadcast(e),this.broadcastQueries()},e.prototype.stopQueryNoBroadcast=function(e){this.stopQueryInStoreNoBroadcast(e),this.removeQuery(e)},e.prototype.removeQuery=function(e){this.fetchQueryRejectFns.delete("query:"+e),this.fetchQueryRejectFns.delete("fetchRequest:"+e),this.getQuery(e).subscriptions.forEach((function(e){return e.unsubscribe()})),this.queries.delete(e)},e.prototype.getCurrentQueryResult=function(e,t){void 0===t&&(t=!0);var r=e.options,n=r.variables,o=r.query,c=r.fetchPolicy,l=r.returnPartialData,f=e.getLastResult(),h=this.getQuery(e.queryId).newData;if(h&&h.complete)return{data:h.result,partial:!1};if("no-cache"===c||"network-only"===c)return{data:void 0,partial:!1};var d=this.dataStore.getCache().diff({query:o,variables:n,previousResult:f?f.data:void 0,returnPartialData:!0,optimistic:t}),v=d.result,y=d.complete;return{data:y||l?v:void 0,partial:!y}},e.prototype.getQueryWithPreviousResult=function(e){var t;if("string"==typeof e){var r=this.getQuery(e).observableQuery;Object(v.b)(r,17),t=r}else t=e;var n=t.options,o=n.variables,c=n.query;return{previousResult:this.getCurrentQueryResult(t,!1).data,variables:o,document:c}},e.prototype.broadcastQueries=function(){var e=this;this.onBroadcast(),this.queries.forEach((function(t,r){t.invalidated&&t.listeners.forEach((function(n){n&&n(e.queryStore.get(r),t.newData)}))}))},e.prototype.getLocalState=function(){return this.localState},e.prototype.getObservableFromLink=function(e,t,r,n){var l,f=this;void 0===n&&(n=this.queryDeduplication);var d=this.transform(e).serverQuery;if(d){var v=this.inFlightLinkObservables,link=this.link,y={query:d,variables:r,operationName:Object(c.j)(d)||void 0,context:this.prepareContext(Object(o.__assign)(Object(o.__assign)({},t),{forceFetch:!n}))};if(t=y.context,n){var m=v.get(d)||new Map;v.set(d,m);var Q=JSON.stringify(r);if(!(l=m.get(Q))){m.set(Q,l=I(Object(h.execute)(link,y)));var j=function(){m.delete(Q),m.size||v.delete(d),_.unsubscribe()},_=l.subscribe({next:j,error:j,complete:j})}}else l=I(Object(h.execute)(link,y))}else l=O.of({data:{}}),t=this.prepareContext(t);var w=this.transform(e).clientQuery;return w&&(l=function(e,t){return new O((function(r){var n=r.next,o=r.error,c=r.complete,l=0,f=!1,h={next:function(e){++l,new Promise((function(r){r(t(e))})).then((function(e){--l,n&&n.call(r,e),f&&h.complete()}),(function(e){--l,o&&o.call(r,e)}))},error:function(e){o&&o.call(r,e)},complete:function(){f=!0,l||c&&c.call(r)}},sub=e.subscribe(h);return function(){return sub.unsubscribe()}}))}(l,(function(e){return f.localState.runResolvers({document:w,remoteResult:e,context:t,variables:r})}))),l},e.prototype.fetchRequest=function(e){var t,r,o=this,c=e.requestId,l=e.queryId,f=e.document,h=e.options,d=e.fetchMoreForQueryId,v=h.variables,y=h.errorPolicy,m=void 0===y?"none":y,O=h.fetchPolicy;return new Promise((function(e,y){var j=o.getObservableFromLink(f,h.context,v),w="fetchRequest:"+l;o.fetchQueryRejectFns.set(w,y);var k=function(){o.fetchQueryRejectFns.delete(w),o.setQuery(l,(function(e){e.subscriptions.delete(S)}))},S=j.map((function(e){if(c>=o.getQuery(l).lastRequestId&&(o.markQueryResult(l,e,h,d),o.queryStore.markQueryResult(l,e,d),o.invalidate(l),o.invalidate(d),o.broadcastQueries()),"none"===m&&Q(e.errors))return y(new _({graphQLErrors:e.errors}));if("all"===m&&(r=e.errors),d||"no-cache"===O)t=e.data;else{var n=o.dataStore.getCache().diff({variables:v,query:f,optimistic:!1,returnPartialData:!0}),j=n.result;(n.complete||h.returnPartialData)&&(t=j)}})).subscribe({error:function(e){k(),y(e)},complete:function(){k(),e({data:t,errors:r,loading:!1,networkStatus:n.ready,stale:!1})}});o.setQuery(l,(function(e){e.subscriptions.add(S)}))}))},e.prototype.getQuery=function(e){return this.queries.get(e)||{listeners:new Set,invalidated:!1,document:null,newData:null,lastRequestId:1,observableQuery:null,subscriptions:new Set}},e.prototype.setQuery=function(e,t){var r=this.getQuery(e),n=Object(o.__assign)(Object(o.__assign)({},r),t(r));this.queries.set(e,n)},e.prototype.invalidate=function(e,t){void 0===t&&(t=!0),e&&this.setQuery(e,(function(){return{invalidated:t}}))},e.prototype.prepareContext=function(e){void 0===e&&(e={});var t=this.localState.prepareContext(e);return Object(o.__assign)(Object(o.__assign)({},t),{clientAwareness:this.clientAwareness})},e.prototype.checkInFlight=function(e){var t=this.queryStore.get(e);return t&&t.networkStatus!==n.ready&&t.networkStatus!==n.error},e.prototype.startPollingQuery=function(e,t,r){var n=this,c=e.pollInterval;if(Object(v.b)(c,18),!this.ssrMode){var l=this.pollingInfoByQueryId.get(t);l||this.pollingInfoByQueryId.set(t,l={}),l.interval=c,l.options=Object(o.__assign)(Object(o.__assign)({},e),{fetchPolicy:"network-only"});var f=function(){var e=n.pollingInfoByQueryId.get(t);e&&(n.checkInFlight(t)?h():n.fetchQuery(t,e.options,j.poll).then(h,h))},h=function(){var e=n.pollingInfoByQueryId.get(t);e&&(clearTimeout(e.timeout),e.timeout=setTimeout(f,e.interval))};r&&this.addQueryListener(t,r),h()}return t},e.prototype.stopPollingQuery=function(e){this.pollingInfoByQueryId.delete(e)},e}(),C=function(){function e(e){this.cache=e}return e.prototype.getCache=function(){return this.cache},e.prototype.markQueryResult=function(e,t,r,n,o){void 0===o&&(o=!1);var l=!Object(c.k)(e);o&&Object(c.k)(e)&&e.data&&(l=!0),!n&&l&&this.cache.write({result:e.data,dataId:"ROOT_QUERY",query:t,variables:r})},e.prototype.markSubscriptionResult=function(e,t,r){Object(c.k)(e)||this.cache.write({result:e.data,dataId:"ROOT_SUBSCRIPTION",query:t,variables:r})},e.prototype.markMutationInit=function(e){var t,r=this;e.optimisticResponse&&(t="function"==typeof e.optimisticResponse?e.optimisticResponse(e.variables):e.optimisticResponse,this.cache.recordOptimisticTransaction((function(n){var o=r.cache;r.cache=n;try{r.markMutationResult({mutationId:e.mutationId,result:{data:t},document:e.document,variables:e.variables,updateQueries:e.updateQueries,update:e.update})}finally{r.cache=o}}),e.mutationId))},e.prototype.markMutationResult=function(e){var t=this;if(!Object(c.k)(e.result)){var r=[{result:e.result.data,dataId:"ROOT_MUTATION",query:e.document,variables:e.variables}],n=e.updateQueries;n&&Object.keys(n).forEach((function(o){var l=n[o],f=l.query,h=l.updater,d=t.cache.diff({query:f.document,variables:f.variables,returnPartialData:!0,optimistic:!1}),v=d.result;if(d.complete){var y=Object(c.v)((function(){return h(v,{mutationResult:e.result,queryName:Object(c.j)(f.document)||void 0,queryVariables:f.variables})}));y&&r.push({result:y,dataId:"ROOT_QUERY",query:f.document,variables:f.variables})}})),this.cache.performTransaction((function(t){r.forEach((function(e){return t.write(e)}));var n=e.update;n&&Object(c.v)((function(){return n(t,e.result)}))}))}},e.prototype.markMutationComplete=function(e){var t=e.mutationId;e.optimisticResponse&&this.cache.removeOptimistic(t)},e.prototype.markUpdateQueryResult=function(e,t,r){this.cache.write({result:r,dataId:"ROOT_QUERY",variables:t,query:e})},e.prototype.reset=function(){return this.cache.reset()},e}(),D=function(){function e(e){var t=this;this.defaultOptions={},this.resetStoreCallbacks=[],this.clearStoreCallbacks=[];var r=e.cache,n=e.ssrMode,o=void 0!==n&&n,c=e.ssrForceFetchDelay,l=void 0===c?0:c,f=e.connectToDevTools,d=e.queryDeduplication,y=void 0===d||d,m=e.defaultOptions,O=e.assumeImmutableResults,Q=void 0!==O&&O,j=e.resolvers,_=e.typeDefs,w=e.fragmentMatcher,k=e.name,S=e.version,link=e.link;if(!link&&j&&(link=h.ApolloLink.empty()),!link||!r)throw new v.a(4);this.link=link,this.cache=r,this.store=new C(r),this.disableNetworkFetches=o||l>0,this.queryDeduplication=y,this.defaultOptions=m||{},this.typeDefs=_,l&&setTimeout((function(){return t.disableNetworkFetches=!1}),l),this.watchQuery=this.watchQuery.bind(this),this.query=this.query.bind(this),this.mutate=this.mutate.bind(this),this.resetStore=this.resetStore.bind(this),this.reFetchObservableQueries=this.reFetchObservableQueries.bind(this);void 0!==f&&(f&&"undefined"!=typeof window)&&(window.__APOLLO_CLIENT__=this),this.version="2.6.10",this.localState=new M({cache:r,client:this,resolvers:j,fragmentMatcher:w}),this.queryManager=new F({link:this.link,store:this.store,queryDeduplication:y,ssrMode:o,clientAwareness:{name:k,version:S},localState:this.localState,assumeImmutableResults:Q,onBroadcast:function(){t.devToolsHookCb&&t.devToolsHookCb({action:{},state:{queries:t.queryManager.queryStore.getStore(),mutations:t.queryManager.mutationStore.getStore()},dataWithOptimisticResults:t.cache.extract(!0)})}})}return e.prototype.stop=function(){this.queryManager.stop()},e.prototype.watchQuery=function(e){return this.defaultOptions.watchQuery&&(e=Object(o.__assign)(Object(o.__assign)({},this.defaultOptions.watchQuery),e)),!this.disableNetworkFetches||"network-only"!==e.fetchPolicy&&"cache-and-network"!==e.fetchPolicy||(e=Object(o.__assign)(Object(o.__assign)({},e),{fetchPolicy:"cache-first"})),this.queryManager.watchQuery(e)},e.prototype.query=function(e){return this.defaultOptions.query&&(e=Object(o.__assign)(Object(o.__assign)({},this.defaultOptions.query),e)),Object(v.b)("cache-and-network"!==e.fetchPolicy,5),this.disableNetworkFetches&&"network-only"===e.fetchPolicy&&(e=Object(o.__assign)(Object(o.__assign)({},e),{fetchPolicy:"cache-first"})),this.queryManager.query(e)},e.prototype.mutate=function(e){return this.defaultOptions.mutate&&(e=Object(o.__assign)(Object(o.__assign)({},this.defaultOptions.mutate),e)),this.queryManager.mutate(e)},e.prototype.subscribe=function(e){return this.queryManager.startGraphQLSubscription(e)},e.prototype.readQuery=function(e,t){return void 0===t&&(t=!1),this.cache.readQuery(e,t)},e.prototype.readFragment=function(e,t){return void 0===t&&(t=!1),this.cache.readFragment(e,t)},e.prototype.writeQuery=function(e){var t=this.cache.writeQuery(e);return this.queryManager.broadcastQueries(),t},e.prototype.writeFragment=function(e){var t=this.cache.writeFragment(e);return this.queryManager.broadcastQueries(),t},e.prototype.writeData=function(e){var t=this.cache.writeData(e);return this.queryManager.broadcastQueries(),t},e.prototype.__actionHookForDevTools=function(e){this.devToolsHookCb=e},e.prototype.__requestRaw=function(e){return Object(h.execute)(this.link,e)},e.prototype.initQueryManager=function(){return this.queryManager},e.prototype.resetStore=function(){var e=this;return Promise.resolve().then((function(){return e.queryManager.clearStore()})).then((function(){return Promise.all(e.resetStoreCallbacks.map((function(e){return e()})))})).then((function(){return e.reFetchObservableQueries()}))},e.prototype.clearStore=function(){var e=this;return Promise.resolve().then((function(){return e.queryManager.clearStore()})).then((function(){return Promise.all(e.clearStoreCallbacks.map((function(e){return e()})))}))},e.prototype.onResetStore=function(e){var t=this;return this.resetStoreCallbacks.push(e),function(){t.resetStoreCallbacks=t.resetStoreCallbacks.filter((function(t){return t!==e}))}},e.prototype.onClearStore=function(e){var t=this;return this.clearStoreCallbacks.push(e),function(){t.clearStoreCallbacks=t.clearStoreCallbacks.filter((function(t){return t!==e}))}},e.prototype.reFetchObservableQueries=function(e){return this.queryManager.reFetchObservableQueries(e)},e.prototype.extract=function(e){return this.cache.extract(e)},e.prototype.restore=function(e){return this.cache.restore(e)},e.prototype.addResolvers=function(e){this.localState.addResolvers(e)},e.prototype.setResolvers=function(e){this.localState.setResolvers(e)},e.prototype.getResolvers=function(){return this.localState.getResolvers()},e.prototype.setLocalStateFragmentMatcher=function(e){this.localState.setFragmentMatcher(e)},e}()},289:function(e,t,r){"use strict";r.d(t,"a",(function(){return O}));var n=r(40),o=r(39),c=r(72),l=r(275),f=r(127),h={test:function(e){return"client"===e.name.value},remove:!0},d=new Map;var v,y=(v=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,b){e.__proto__=b}||function(e,b){for(var p in b)b.hasOwnProperty(p)&&(e[p]=b[p])},function(e,b){function t(){this.constructor=e}v(e,b),e.prototype=null===b?Object.create(b):(t.prototype=b.prototype,new t)}),m=l.graphql,O=function(e){void 0===e&&(e={resolvers:{},defaults:{}});var t=e.defaults,r=e.cache,l=e.typeDefs,v=e.fragmentMatcher;return r&&t&&r.writeData({data:t}),new(function(o){function O(){return null!==o&&o.apply(this,arguments)||this}return y(O,o),O.prototype.writeDefaults=function(){r&&t&&r.writeData({data:t})},O.prototype.request=function(r,o){if(void 0===o&&(o=function(){return n.a.of({data:{}})}),l){var y=function(e){return(Array.isArray(e)?e:[e]).map((function(e){return"string"==typeof e?e:Object(f.print)(e)})).map((function(e){return e.trim()})).join("\n")}(l);r.setContext((function(e){var t=e.schemas;return{schemas:(void 0===t?[]:t).concat([{definition:y,directives:"directive @client on FIELD"}])}}))}if(!Object(c.d)(["client"],r.query))return o(r);var O,Q="function"==typeof e.resolvers?e.resolvers():e.resolvers,j=function(e){var t=d.get(e);if(t)return t;Object(c.a)(e);var r=Object(c.e)([h],e);return d.set(e,r),r}(r.query),_=r.query,w=(O=(Object(c.b)(_)||{}).operation).charAt(0).toUpperCase()+O.slice(1)||"Query",k=function(e,r,n,o,c){void 0===r&&(r={});var l=c.resultKey,f=r[l],h=r[e],d=l!==e;if(void 0!==f||void 0!==h)return f||h;var v=Q[r.__typename||w];if(v){var y=v[e];if(y)return y(r,n,o,c)}return(d?f:h)||(t||{})[e]};j&&(r.query=j);var S=j&&o?o(r):n.a.of({data:{}});return new n.a((function(e){var t=!1,n=!1;S.subscribe({next:function(o){var data=o.data,c=o.errors,l=e.error.bind(e),f=r.getContext();n=!0,m(k,_,data,f,r.variables,{fragmentMatcher:v}).then((function(r){e.next({data:r,errors:c}),t&&e.complete(),n=!1})).catch(l)},error:e.error.bind(e),complete:function(){n||e.complete(),t=!0}})}))},O}(o.ApolloLink))}},410:function(e,t,r){"use strict";r.r(t),r.d(t,"checkFetcher",(function(){return d})),r.d(t,"createSignalIfSupported",(function(){return v})),r.d(t,"fallbackHttpConfig",(function(){return l})),r.d(t,"parseAndCheckHttpResponse",(function(){return h})),r.d(t,"selectHttpOptionsAndBody",(function(){return y})),r.d(t,"selectURI",(function(){return O})),r.d(t,"serializeFetchParameter",(function(){return m})),r.d(t,"throwServerError",(function(){return f}));var n=r(0),o=r(127),c=r(2),l={http:{includeQuery:!0,includeExtensions:!1},headers:{accept:"*/*","content-type":"application/json"},options:{method:"POST"}},f=function(e,t,r){var n=new Error(r);throw n.name="ServerError",n.response=e,n.statusCode=e.status,n.result=t,n},h=function(e){return function(t){return t.text().then((function(e){try{return JSON.parse(e)}catch(n){var r=n;return r.name="ServerParseError",r.response=t,r.statusCode=t.status,r.bodyText=e,Promise.reject(r)}})).then((function(r){return t.status>=300&&f(t,r,"Response not successful: Received status code "+t.status),Array.isArray(r)||r.hasOwnProperty("data")||r.hasOwnProperty("errors")||f(t,r,"Server response was missing for query '"+(Array.isArray(e)?e.map((function(e){return e.operationName})):e.operationName)+"'."),r}))}},d=function(e){if(!e&&"undefined"==typeof fetch){throw"undefined"==typeof window&&"node-fetch",new c.a(1)}},v=function(){if("undefined"==typeof AbortController)return{controller:!1,signal:!1};var e=new AbortController;return{controller:e,signal:e.signal}},y=function(e,t){for(var r=[],c=2;c<arguments.length;c++)r[c-2]=arguments[c];var l=Object(n.__assign)({},t.options,{headers:t.headers,credentials:t.credentials}),f=t.http;r.forEach((function(e){l=Object(n.__assign)({},l,e.options,{headers:Object(n.__assign)({},l.headers,e.headers)}),e.credentials&&(l.credentials=e.credentials),f=Object(n.__assign)({},f,e.http)}));var h=e.operationName,d=e.extensions,v=e.variables,y=e.query,body={operationName:h,variables:v};return f.includeExtensions&&(body.extensions=d),f.includeQuery&&(body.query=Object(o.print)(y)),{options:l,body:body}},m=function(p,label){var e;try{e=JSON.stringify(p)}catch(e){var t=new c.a(2);throw t.parseError=e,t}return e},O=function(e,t){var r=e.getContext().uri;return r||("function"==typeof t?t(e):t||"/graphql")}}}]);