web-ggf 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -0
- package/bin/init/index.cjs +16 -0
- package/dist/apollo-nextjs-client/index.cjs.js +2 -0
- package/dist/apollo-nextjs-client/index.cjs.js.map +1 -0
- package/dist/apollo-nextjs-client/index.esm.js +2 -0
- package/dist/apollo-nextjs-client/index.esm.js.map +1 -0
- package/dist/apollo-nextjs-wrapper/index.cjs.js +2 -0
- package/dist/apollo-nextjs-wrapper/index.cjs.js.map +1 -0
- package/dist/apollo-nextjs-wrapper/index.esm.js +2 -0
- package/dist/apollo-nextjs-wrapper/index.esm.js.map +1 -0
- package/dist/nextjs-middleware/index.cjs +2 -0
- package/dist/nextjs-middleware/index.cjs.map +1 -0
- package/dist/nextjs-middleware/index.mjs +2 -0
- package/dist/nextjs-middleware/index.mjs.map +1 -0
- package/dist/test/index.cjs.js +2 -0
- package/dist/test/index.cjs.js.map +1 -0
- package/dist/test/index.esm.js +2 -0
- package/dist/test/index.esm.js.map +1 -0
- package/dist/types/client/apollo-nextjs/client.d.ts +2 -0
- package/dist/types/client/apollo-nextjs/wrapper.d.ts +15 -0
- package/dist/types/client/test/index.d.ts +10 -0
- package/dist/types/server/index.d.ts +25 -0
- package/dist/types/server/is-protected.d.ts +1 -0
- package/package.json +78 -0
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import e from"react";import{ServerError as t,HttpLink as n,ApolloLink as r}from"@apollo/client";import{EMPTY as i,Observable as o}from"rxjs";import{InMemoryCache as s,ApolloNextAppProvider as a,ApolloClient as c}from"@apollo/client-integration-nextjs";function u(e,t){if(!Boolean(e))throw new Error(t)}const l={Name:[],Document:["definitions"],OperationDefinition:["description","name","variableDefinitions","directives","selectionSet"],VariableDefinition:["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","locations"],SchemaExtension:["directives","operationTypes"],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"]},p=new Set(Object.keys(l));function f(e){const t=null==e?void 0:e.kind;return"string"==typeof t&&p.has(t)}var d,h;function y(e){return 9===e||32===e}!function(e){e.QUERY="query",e.MUTATION="mutation",e.SUBSCRIPTION="subscription"}(d||(d={})),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.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"}(h||(h={}));function m(e){return v(e,[])}function v(e,t){switch(typeof e){case"string":return JSON.stringify(e);case"function":return e.name?`[function ${e.name}]`:"[function]";case"object":return function(e,t){if(null===e)return"null";if(t.includes(e))return"[Circular]";const n=[...t,e];if(function(e){return"function"==typeof e.toJSON}(e)){const t=e.toJSON();if(t!==e)return"string"==typeof t?t:v(t,n)}else if(Array.isArray(e))return function(e,t){if(0===e.length)return"[]";if(t.length>2)return"[Array]";const n=Math.min(10,e.length),r=e.length-n,i=[];for(let r=0;r<n;++r)i.push(v(e[r],t));1===r?i.push("... 1 more item"):r>1&&i.push(`... ${r} more items`);return"["+i.join(", ")+"]"}(e,n);return function(e,t){const n=Object.entries(e);if(0===n.length)return"{}";if(t.length>2)return"["+function(e){const t=Object.prototype.toString.call(e).replace(/^\[object /,"").replace(/]$/,"");if("Object"===t&&"function"==typeof e.constructor){const t=e.constructor.name;if("string"==typeof t&&""!==t)return t}return t}(e)+"]";const r=n.map(([e,n])=>e+": "+v(n,t));return"{ "+r.join(", ")+" }"}(e,n)}(e,t);default:return String(e)}}const g=/[\x00-\x1f\x22\x5c\x7f-\x9f]/g;function b(e){return E[e.charCodeAt(0)]}const E=["\\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"],O=Object.freeze({});function T(e,t,n=l){const r=new Map;for(const e of Object.values(h))r.set(e,N(t,e));let i,o,s,a=Array.isArray(e),c=[e],p=-1,d=[],y=e;const v=[],g=[];do{p++;const e=p===c.length,l=e&&0!==d.length;if(e){if(o=0===g.length?void 0:v[v.length-1],y=s,s=g.pop(),l)if(a){y=y.slice();let e=0;for(const[t,n]of d){const r=t-e;null===n?(y.splice(r,1),e++):y[r]=n}}else{y={...y};for(const[e,t]of d)y[e]=t}p=i.index,c=i.keys,d=i.edits,a=i.inArray,i=i.prev}else if(s){if(o=a?p:c[p],y=s[o],null==y)continue;v.push(o)}let h;if(!Array.isArray(y)){var b,E;f(y)||u(!1,`Invalid AST Node: ${m(y)}.`);const n=e?null===(b=r.get(y.kind))||void 0===b?void 0:b.leave:null===(E=r.get(y.kind))||void 0===E?void 0:E.enter;if(h=null==n?void 0:n.call(t,y,o,s,v,g),h===O)break;if(!1===h){if(!e){v.pop();continue}}else if(void 0!==h&&(d.push([o,h]),!e)){if(!f(h)){v.pop();continue}y=h}}var T;if(void 0===h&&l&&d.push([o,y]),e)v.pop();else i={inArray:a,index:p,keys:c,edits:d,prev:i},a=Array.isArray(y),c=a?y:null!==(T=n[y.kind])&&void 0!==T?T:[],p=-1,d=[],s&&g.push(s),s=y}while(void 0!==i);return 0!==d.length?d[d.length-1][1]:e}function N(e,t){const n=e[t];return"object"==typeof n?n:"function"==typeof n?{enter:n,leave:void 0}:{enter:e.enter,leave:e.leave}}const w={Name:{leave:e=>e.value},Variable:{leave:e=>"$"+e.name},Document:{leave:e=>I(e.definitions,"\n\n")},OperationDefinition:{leave(e){const t=A(e.variableDefinitions)?S("(\n",I(e.variableDefinitions,"\n"),"\n)"):S("(",I(e.variableDefinitions,", "),")"),n=S("",e.description,"\n")+I([e.operation,I([e.name,t]),I(e.directives," ")]," ");return("query"===n?"":n+" ")+e.selectionSet}},VariableDefinition:{leave:({variable:e,type:t,defaultValue:n,directives:r,description:i})=>S("",i,"\n")+e+": "+t+S(" = ",n)+S(" ",I(r," "))},SelectionSet:{leave:({selections:e})=>x(e)},Field:{leave({alias:e,name:t,arguments:n,directives:r,selectionSet:i}){const o=S("",e,": ")+t;let s=o+S("(",I(n,", "),")");return s.length>80&&(s=o+S("(\n",D(I(n,"\n")),"\n)")),I([s,I(r," "),i]," ")}},Argument:{leave:({name:e,value:t})=>e+": "+t},FragmentSpread:{leave:({name:e,directives:t})=>"..."+e+S(" ",I(t," "))},InlineFragment:{leave:({typeCondition:e,directives:t,selectionSet:n})=>I(["...",S("on ",e),I(t," "),n]," ")},FragmentDefinition:{leave:({name:e,typeCondition:t,variableDefinitions:n,directives:r,selectionSet:i,description:o})=>S("",o,"\n")+`fragment ${e}${S("(",I(n,", "),")")} `+`on ${t} ${S("",I(r," ")," ")}`+i},IntValue:{leave:({value:e})=>e},FloatValue:{leave:({value:e})=>e},StringValue:{leave:({value:e,block:t})=>t?function(e){const t=e.replace(/"""/g,'\\"""'),n=t.split(/\r\n|[\n\r]/g),r=1===n.length,i=n.length>1&&n.slice(1).every(e=>0===e.length||y(e.charCodeAt(0))),o=t.endsWith('\\"""'),s=e.endsWith('"')&&!o,a=e.endsWith("\\"),c=s||a,u=!r||e.length>70||c||i||o;let l="";const p=r&&y(e.charCodeAt(0));return(u&&!p||i)&&(l+="\n"),l+=t,(u||c)&&(l+="\n"),'"""'+l+'"""'}(e):`"${e.replace(g,b)}"`},BooleanValue:{leave:({value:e})=>e?"true":"false"},NullValue:{leave:()=>"null"},EnumValue:{leave:({value:e})=>e},ListValue:{leave:({values:e})=>"["+I(e,", ")+"]"},ObjectValue:{leave:({fields:e})=>"{"+I(e,", ")+"}"},ObjectField:{leave:({name:e,value:t})=>e+": "+t},Directive:{leave:({name:e,arguments:t})=>"@"+e+S("(",I(t,", "),")")},NamedType:{leave:({name:e})=>e},ListType:{leave:({type:e})=>"["+e+"]"},NonNullType:{leave:({type:e})=>e+"!"},SchemaDefinition:{leave:({description:e,directives:t,operationTypes:n})=>S("",e,"\n")+I(["schema",I(t," "),x(n)]," ")},OperationTypeDefinition:{leave:({operation:e,type:t})=>e+": "+t},ScalarTypeDefinition:{leave:({description:e,name:t,directives:n})=>S("",e,"\n")+I(["scalar",t,I(n," ")]," ")},ObjectTypeDefinition:{leave:({description:e,name:t,interfaces:n,directives:r,fields:i})=>S("",e,"\n")+I(["type",t,S("implements ",I(n," & ")),I(r," "),x(i)]," ")},FieldDefinition:{leave:({description:e,name:t,arguments:n,type:r,directives:i})=>S("",e,"\n")+t+(A(n)?S("(\n",D(I(n,"\n")),"\n)"):S("(",I(n,", "),")"))+": "+r+S(" ",I(i," "))},InputValueDefinition:{leave:({description:e,name:t,type:n,defaultValue:r,directives:i})=>S("",e,"\n")+I([t+": "+n,S("= ",r),I(i," ")]," ")},InterfaceTypeDefinition:{leave:({description:e,name:t,interfaces:n,directives:r,fields:i})=>S("",e,"\n")+I(["interface",t,S("implements ",I(n," & ")),I(r," "),x(i)]," ")},UnionTypeDefinition:{leave:({description:e,name:t,directives:n,types:r})=>S("",e,"\n")+I(["union",t,I(n," "),S("= ",I(r," | "))]," ")},EnumTypeDefinition:{leave:({description:e,name:t,directives:n,values:r})=>S("",e,"\n")+I(["enum",t,I(n," "),x(r)]," ")},EnumValueDefinition:{leave:({description:e,name:t,directives:n})=>S("",e,"\n")+I([t,I(n," ")]," ")},InputObjectTypeDefinition:{leave:({description:e,name:t,directives:n,fields:r})=>S("",e,"\n")+I(["input",t,I(n," "),x(r)]," ")},DirectiveDefinition:{leave:({description:e,name:t,arguments:n,repeatable:r,locations:i})=>S("",e,"\n")+"directive @"+t+(A(n)?S("(\n",D(I(n,"\n")),"\n)"):S("(",I(n,", "),")"))+(r?" repeatable":"")+" on "+I(i," | ")},SchemaExtension:{leave:({directives:e,operationTypes:t})=>I(["extend schema",I(e," "),x(t)]," ")},ScalarTypeExtension:{leave:({name:e,directives:t})=>I(["extend scalar",e,I(t," ")]," ")},ObjectTypeExtension:{leave:({name:e,interfaces:t,directives:n,fields:r})=>I(["extend type",e,S("implements ",I(t," & ")),I(n," "),x(r)]," ")},InterfaceTypeExtension:{leave:({name:e,interfaces:t,directives:n,fields:r})=>I(["extend interface",e,S("implements ",I(t," & ")),I(n," "),x(r)]," ")},UnionTypeExtension:{leave:({name:e,directives:t,types:n})=>I(["extend union",e,I(t," "),S("= ",I(n," | "))]," ")},EnumTypeExtension:{leave:({name:e,directives:t,values:n})=>I(["extend enum",e,I(t," "),x(n)]," ")},InputObjectTypeExtension:{leave:({name:e,directives:t,fields:n})=>I(["extend input",e,I(t," "),x(n)]," ")},TypeCoordinate:{leave:({name:e})=>e},MemberCoordinate:{leave:({name:e,memberName:t})=>I([e,S(".",t)])},ArgumentCoordinate:{leave:({name:e,fieldName:t,argumentName:n})=>I([e,S(".",t),S("(",n,":)")])},DirectiveCoordinate:{leave:({name:e})=>I(["@",e])},DirectiveArgumentCoordinate:{leave:({name:e,argumentName:t})=>I(["@",e,S("(",t,":)")])}};function I(e,t=""){var n;return null!==(n=null==e?void 0:e.filter(e=>e).join(t))&&void 0!==n?n:""}function x(e){return S("{\n",D(I(e,"\n")),"\n}")}function S(e,t,n=""){return null!=t&&""!==t?e+t+n:""}function D(e){return S(" ",e.replace(/\n/g,"\n "))}function A(e){var t;return null!==(t=null==e?void 0:e.some(e=>e.includes("\n")))&&void 0!==t&&t}function C(e){try{return e()}catch{}}var _=C(()=>globalThis)||C(()=>window)||C(()=>self)||C(()=>global)||C(function(){return C.constructor("return this")()});const j="4.1.6",F=new Map;function P(e,t=0){const n=function(e){const t=F.get(e)||1;return F.set(e,t+1),`${e}:${t}:${Math.random().toString(36).slice(2)}`}("stringifyForDisplay");return JSON.stringify(e,(e,t)=>void 0===t?n:t,t).split(JSON.stringify(n)).join("<undefined>")}const k="Invariant Violation";class V extends Error{constructor(e=k){super(e),this.name=k,Object.setPrototypeOf(this,V.prototype)}}const M=["debug","log","warn","error","silent"];let R=M.indexOf("silent");function L(e,...t){if(!e)throw q(...t)}function U(e){return function(t,...n){if(M.indexOf(e)>=R){const r=console[e]||console.log;if("number"==typeof t){const e=t;(t=$(e))||(t=Y(e,n),n=[])}r(t,...n)}}}function q(e,...t){return new V($(e,t)||Y(e,t))}L.debug=U("debug"),L.log=U("log"),L.warn=U("warn"),L.error=U("error");const z=Symbol.for("ApolloErrorMessageHandler_"+j);function B(e){if("string"==typeof e)return e;try{return P(e,2).slice(0,1e3)}catch{return"<non-serializable>"}}function $(e,t=[]){if(e)return _[z]&&_[z](e,t.map(B))}function Y(e,t=[]){if(e)return"string"==typeof e?t.reduce((e,t)=>e.replace(/%[sdfo]/,B(t)),e):`An error occurred! For more details, see the full error text at https://go.apollo.dev/c/err#${encodeURIComponent(JSON.stringify({version:j,message:e,args:t.map(B)}))}`}const J=Symbol.for("apollo.cacheSize"),G={..._[J]};function W(e,t){return e.definitions.find(e=>"OperationDefinition"===e.kind&&!!e.name)?.name.value??t}const Q=()=>Object.create(null),{forEach:X,slice:H}=Array.prototype,{hasOwnProperty:K}=Object.prototype;class Z{constructor(e=!0,t=Q){this.weakness=e,this.makeData=t}lookup(){return this.lookupArray(arguments)}lookupArray(e){let t=this;return X.call(e,e=>t=t.getChildTrie(e)),K.call(t,"data")?t.data:t.data=this.makeData(H.call(e))}peek(){return this.peekArray(arguments)}peekArray(e){let t=this;for(let n=0,r=e.length;t&&n<r;++n){const 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){const n=e[0],r=this.mapFor(n,!1),i=r&&r.get(n);i&&(t=i.removeArray(H.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(e){const t=this.mapFor(e,!0);let n=t.get(e);return n||t.set(e,n=new Z(this.weakness,this.makeData)),n}mapFor(e,t){return this.weakness&&function(e){switch(typeof e){case"object":if(null===e)break;case"function":return!0}return!1}(e)?this.weak||(t?this.weak=new WeakMap:void 0):this.strong||(t?this.strong=new Map:void 0)}}function ee(){}const te=ee,ne="undefined"!=typeof WeakRef?WeakRef:function(e){return{deref:()=>e}},re="undefined"!=typeof WeakMap?WeakMap:Map,ie="undefined"!=typeof FinalizationRegistry?FinalizationRegistry:function(){return{register:ee,unregister:ee}};class oe{constructor(e=1/0,t=te){this.max=e,this.dispose=t,this.map=new re,this.newest=null,this.oldest=null,this.unfinalizedNodes=new Set,this.finalizationScheduled=!1,this.size=0,this.finalize=()=>{const e=this.unfinalizedNodes.values();for(let t=0;t<10024;t++){const t=e.next().value;if(!t)break;this.unfinalizedNodes.delete(t);const n=t.key;delete t.key,t.keyRef=new ne(n),this.registry.register(n,t,t)}this.unfinalizedNodes.size>0?queueMicrotask(this.finalize):this.finalizationScheduled=!1},this.registry=new ie(this.deleteNode.bind(this))}has(e){return this.map.has(e)}get(e){const t=this.getNode(e);return t&&t.value}getNode(e){const t=this.map.get(e);if(t&&t!==this.newest){const{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--;const 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){const t=this.map.get(e);return!!t&&(this.deleteNode(t),!0)}scheduleFinalization(e){this.unfinalizedNodes.add(e),this.finalizationScheduled||(this.finalizationScheduled=!0,queueMicrotask(this.finalize))}}const se=new WeakSet;const ae=function(e,t){const n=new oe(e,t);return n.set=function(e,t){const n=oe.prototype.set.call(this,e,t);return function(e){e.size<=(e.max||-1)||se.has(e)||(se.add(e),setTimeout(()=>{e.clean(),se.delete(e)},100))}(this),n},n};const ce=function(e,{max:t,makeCacheKey:n=e=>e}){const r=new Z(!0),i=new ae(t);return(...t)=>{const o=r.lookupArray(n(t)),s=i.get(o);if(s){if(s.error)throw s.error;return s.result}const a=i.set(o,{});try{return a.result=e(...t)}catch(e){throw a.error=e,e}}}((e,t)=>{L(e&&"Document"===e.kind,1);const n=e.definitions.filter(e=>"OperationDefinition"===e.kind);t&&L(1==n.length&&n[0].operation===t,4,t,t,n[0].operation),T(e,{Field(t,r,i,o){if(t.alias&&("__typename"===t.alias.value||t.alias.value.startsWith("__ac_"))&&t.alias.value!==t.name.value){let r=e,i=[];for(const e of o)r=r[e],r.kind===h.FIELD&&i.push(r.alias?.value||r.name.value);throw i.splice(-1,1,t.name.value),q(5,t.alias.value,i.join("."),n[0].operation,W(e,"(anonymous)"))}}})},{max:G.checkDocument||2e3});function ue(e){return null!==e&&"object"==typeof e}const{hasOwnProperty:le}=Object.prototype,pe=function(e,t,n){return this.merge(e[n],t[n])},fe=e=>isNaN(+e)?{}:[];class de{options;reconciler;constructor(e={}){this.options=e,this.reconciler=e.reconciler||pe}merge(e,t,n={}){const r=n.atPath;if(r?.length){const[i,...o]=r;void 0===e&&(e=fe(i));let s=e[i];void 0===s&&o.length&&(s=fe(o[0]));const a=this.merge(s,t,{...n,atPath:o});return s!==a&&((e=this.shallowCopyForMerge(e))[i]=a),e}return Array.isArray(e)&&Array.isArray(t)&&"truncate"===this.options.arrayMerge&&e.length>t.length&&(e=e.slice(0,t.length),this.pastCopies.add(e)),ue(t)&&ue(e)?(Object.keys(t).forEach(n=>{if(le.call(e,n)){const r=e[n];if(t[n]!==r){const i=this.reconciler(e,t,n);i!==r&&((e=this.shallowCopyForMerge(e))[n]=i)}}else(e=this.shallowCopyForMerge(e))[n]=t[n]}),e):t}isObject=ue;pastCopies=new Set;shallowCopyForMerge(e){return ue(e)&&(this.pastCopies.has(e)||(e=Array.isArray(e)?e.slice(0):{__proto__:Object.getPrototypeOf(e),...e},this.pastCopies.add(e))),e}}function he(...e){return function(e){let t=e[0]||{};const n=e.length;if(n>1){const r=new de;for(let i=1;i<n;++i)t=r.merge(t,e[i])}return t}(e)}class ye{static empty(){return new ye(()=>i)}static from(e){if(0===e.length)return ye.empty();const[t,...n]=e;return t.concat(...n)}static split(e,t,n=new ye((e,t)=>t(e))){const r=new ye((r,i)=>e(r)?t.request(r,i):n.request(r,i));return Object.assign(r,{left:t,right:n})}static execute(e,t,n){return e.request(function(e,{client:t}){const n={query:e.query,variables:e.variables||{},extensions:e.extensions||{},operationName:W(e.query),operationType:(r=e.query,ce(r),r.definitions.filter(e=>"OperationDefinition"===e.kind)[0]).operation};var r;let i={...e.context};const o=()=>Object.freeze({...i});return Object.defineProperty(n,"setContext",{enumerable:!1,value:e=>{i="function"==typeof e?{...i,...e(o())}:{...i,...e}}}),Object.defineProperty(n,"getContext",{enumerable:!1,value:o}),Object.defineProperty(n,"client",{enumerable:!1,value:t}),n}(t,n),()=>i)}static concat(...e){return ye.from(e)}constructor(e){e&&(this.request=e)}split(e,t,n){return this.concat(ye.split(e,t,n))}concat(...e){return 0===e.length?this:e.reduce(this.combine.bind(this),this)}combine(e,t){const n=new ye((n,r)=>e.request(n,e=>t.request(e,r)));return Object.assign(n,{left:e,right:t})}request(e,t){throw q(65)}left;right}class me extends ye{constructor(e){super((t,n)=>{const{...r}=t;return Object.defineProperty(r,"client",{enumerable:!1,value:t.client}),new o(i=>{let o=!1;return Promise.resolve(r).then(n=>e(t.getContext(),n)).then(t.setContext).then(()=>{o||n(t).subscribe(i)}).catch(i.error.bind(i)),()=>{o=!0}})})}}function ve(e,t){return"object"==typeof e&&null!==e&&e[Symbol.for("apollo.error")]===t}function ge(e){Object.defineProperty(e,Symbol.for("apollo.error"),{value:e.name,enumerable:!1,writable:!1,configurable:!1})}function be(e){return e.map(e=>e.message||"Error message not found.").join("\n")}class Ee extends Error{static is(e){return ve(e,"CombinedProtocolErrors")}static formatMessage=be;errors;constructor(e){super(Ee.formatMessage(e,{defaultFormatMessage:be})),this.name="CombinedProtocolErrors",this.errors=e,ge(this),Object.setPrototypeOf(this,Ee.prototype)}}class Oe extends Error{static is(e){return ve(e,"UnconventionalError")}constructor(e){super("An error of unexpected shape occurred.",{cause:e}),this.name="UnconventionalError",ge(this),Object.setPrototypeOf(this,Oe.prototype)}}function Te(e){return e.filter(e=>e).map(e=>e.message||"Error message not found.").join("\n")}class Ne extends Error{static is(e){return ve(e,"CombinedGraphQLErrors")}static formatMessage=Te;errors;data;extensions;constructor(e,t=e.errors||[]){super(Ne.formatMessage(t,{result:e,defaultFormatMessage:Te})),this.errors=t,this.data=e.data,this.extensions=e.extensions,this.name="CombinedGraphQLErrors",ge(this),Object.setPrototypeOf(this,Ne.prototype)}}class we extends Error{static is(e){return ve(e,"ServerError")}response;statusCode;bodyText;constructor(e,t){super(e),this.name="ServerError",this.response=t.response,this.statusCode=t.response.status,this.bodyText=t.bodyText,ge(this),Object.setPrototypeOf(this,we.prototype)}}class Ie extends Error{static is(e){return ve(e,"ServerParseError")}response;statusCode;bodyText;constructor(e,t){super(e instanceof Error?e.message:"Could not parse server response",{cause:e}),this.name="ServerParseError",this.response=t.response,this.statusCode=t.response.status,this.bodyText=t.bodyText,ge(this),Object.setPrototypeOf(this,Ie.prototype)}}const xe=Symbol();function Se(e){return function(e){return null!==e&&"object"==typeof e&&"string"==typeof e.message&&"string"==typeof e.name&&("string"==typeof e.stack||void 0===e.stack)}(e)?e:"string"==typeof e?new Error(e,{cause:e}):new Oe(e)}class De extends ye{constructor(e){super((t,n)=>new o(r=>{let i,o,s;try{i=n(t).subscribe({next:i=>{const a=t.client.queryManager.incrementalHandler,c=a.isIncrementalResult(i)?a.extractErrors(i):i.errors;c?s=e({error:new Ne(i,c),result:i,operation:t,forward:n}):function(e){return"extensions"in e&&Ee.is(e.extensions[xe])}(i)&&(s=e({error:i.extensions[xe],result:i,operation:t,forward:n})),o=s?.subscribe(r),o||r.next(i)},error:i=>{s=e({operation:t,error:Se(i),forward:n}),o=s?.subscribe(r),o||r.error(i)},complete:()=>{s||r.complete()}})}catch(i){e({error:Se(i),operation:t,forward:n}),r.error(i)}return()=>{i&&i.unsubscribe(),o&&o.unsubscribe()}}))}}let Ae;const Ce=Object.assign(e=>{let t=Ae.get(e);return t||(t=function(e){return T(e,w)}(e),Ae.set(e,t)),t},{reset(){Ae=new ae(G.print||2e3)}});Ce.reset();var _e=function(e,t){return _e=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])},_e(e,t)};function je(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}_e(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}function Fe(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function Pe(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),s=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)s.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return s}function ke(e,t,n){if(n||2===arguments.length)for(var r,i=0,o=t.length;i<o;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))}function Ve(e=!1){return{keyArgs:e,read(e,{canRead:t,readField:n}){if(!e)return e;const r=[];let i="",o="";e.edges.forEach(e=>{t(n("node",e))&&(r.push(e),e.cursor&&(i=i||e.cursor||"",o=e.cursor||o))}),r.length>1&&i===o&&(i="");const{startCursor:s,endCursor:a}=e.pageInfo||{};return{...Me(e),edges:r,pageInfo:{...e.pageInfo,startCursor:s||i,endCursor:a||o}}},merge(e,t,{args:n,isReference:r,readField:i}){if(e||(e={edges:[],pageInfo:{hasPreviousPage:!1,hasNextPage:!0,startCursor:"",endCursor:""}}),!t)return e;const o=t.edges?t.edges.map(e=>(r(e={...e})&&(e.cursor=i("cursor",e)),e)):[];if(t.pageInfo){const{pageInfo:e}=t,{startCursor:n,endCursor:r}=e,i=o[0],s=o[o.length-1];i&&n&&(i.cursor=n),s&&r&&(s.cursor=r);const a=i&&i.cursor;a&&!n&&(t=he(t,{pageInfo:{startCursor:a}}));const c=s&&s.cursor;c&&!r&&(t=he(t,{pageInfo:{endCursor:c}}))}let s=e.edges,a=[];if(n&&n.after){const e=s.findIndex(e=>e.cursor===n.after);e>=0&&(s=s.slice(0,e+1))}else if(n&&n.before){const e=s.findIndex(e=>e.cursor===n.before);a=e<0?s:s.slice(e),s=[]}else t.edges&&(s=[]);const c=[...s,...o,...a],u={...t.pageInfo,...e.pageInfo};if(t.pageInfo){const{hasPreviousPage:e,hasNextPage:n,startCursor:r,endCursor:i,...o}=t.pageInfo;Object.assign(u,o),s.length||(void 0!==e&&(u.hasPreviousPage=e),void 0!==r&&(u.startCursor=r)),a.length||(void 0!==n&&(u.hasNextPage=n),void 0!==i&&(u.endCursor=i))}return{...Me(e),...Me(t),edges:c,pageInfo:u}}}}"function"==typeof SuppressedError&&SuppressedError;const Me=e=>function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(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}(e,Re),Re=["edges","pageInfo"];const{hasOwnProperty:Le}=Object.prototype;function Ue(e,t){const n=e.headers.get("content-type");return n?.includes("application/graphql-response+json")?function(e,t){try{return JSON.parse(t)}catch(n){throw new Ie(n,{response:e,bodyText:t})}}(e,t):function(e,t){if(e.status>=300)throw new we(`Response not successful: Received status code ${e.status}`,{response:e,bodyText:t});try{return JSON.parse(t)}catch(n){throw new Ie(n,{response:e,bodyText:t})}}(e,t)}const qe={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"}},ze=(e,t)=>t(e);function Be(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=function(e,t){if(!t){const t={};return Object.keys(Object(e)).forEach(n=>{t[n.toLowerCase()]=e[n]}),t}const n={};Object.keys(Object(e)).forEach(t=>{n[t.toLowerCase()]={originalName:t,value:e[t]}});const r={};return Object.keys(n).forEach(e=>{r[n[e].originalName]=n[e].value}),r}(r.headers,i.preserveHeaderCase);const{operationName:o,extensions:s,variables:a,query:c}=e,u={operationName:o,variables:a};return i.includeExtensions&&Object.keys(s||{}).length&&(u.extensions=s),i.includeQuery&&(u.query=t(c,Ce)),{options:r,body:u}}function $e(e,t,n=""){if(!arguments.length)throw new TypeError("Argument 1 `value` is required.");if("function"!=typeof t)throw new TypeError("Argument 2 `isExtractable` must be a function.");if("string"!=typeof n)throw new TypeError("Argument 3 `path` must be a string.");const r=new Map,i=new Map;return{clone:function e(n,o,s){if(t(n)){const e=i.get(n);return e?e.push(o):i.set(n,[o]),null}const a=Array.isArray(n)||"undefined"!=typeof FileList&&n instanceof FileList,c=function(e){if("object"!=typeof e||null===e)return!1;const t=Object.getPrototypeOf(e);return!(null!==t&&t!==Object.prototype&&null!==Object.getPrototypeOf(t)||Symbol.toStringTag in e||Symbol.iterator in e)}(n);if(a||c){let t=r.get(n);const i=!t;if(i&&(t=a?[]:n instanceof Object?{}:Object.create(null),r.set(n,t)),!s.has(n)){const r=o?`${o}.`:"",c=new Set(s).add(n);if(a){let o=0;for(const s of n){const n=e(s,r+o++,c);i&&t.push(n)}}else for(const o in n){const s=e(n[o],r+o,c);i&&(t[o]=s)}}return t}return n}(e,n,new Set),files:i}}function Ye(e){return"function"==typeof e}var Je,Ge=((Je=function(e){return function(t){e(this),this.message=t?t.length+" errors occurred during unsubscription:\n"+t.map(function(e,t){return t+1+") "+e.toString()}).join("\n "):"",this.name="UnsubscriptionError",this.errors=t}}(function(e){Error.call(e),e.stack=(new Error).stack})).prototype=Object.create(Error.prototype),Je.prototype.constructor=Je,Je);function We(e,t){if(e){var n=e.indexOf(t);0<=n&&e.splice(n,1)}}var Qe=function(){function e(e){this.initialTeardown=e,this.closed=!1,this._parentage=null,this._teardowns=null}var t;return e.prototype.unsubscribe=function(){var e,t,n,r,i;if(!this.closed){this.closed=!0;var o=this._parentage;if(o)if(this._parentage=null,Array.isArray(o))try{for(var s=Fe(o),a=s.next();!a.done;a=s.next()){a.value.remove(this)}}catch(t){e={error:t}}finally{try{a&&!a.done&&(t=s.return)&&t.call(s)}finally{if(e)throw e.error}}else o.remove(this);var c=this.initialTeardown;if(Ye(c))try{c()}catch(e){i=e instanceof Ge?e.errors:[e]}var u=this._teardowns;if(u){this._teardowns=null;try{for(var l=Fe(u),p=l.next();!p.done;p=l.next()){var f=p.value;try{He(f)}catch(e){i=null!=i?i:[],e instanceof Ge?i=ke(ke([],Pe(i)),Pe(e.errors)):i.push(e)}}}catch(e){n={error:e}}finally{try{p&&!p.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}}if(i)throw new Ge(i)}},e.prototype.add=function(t){var n;if(t&&t!==this)if(this.closed)He(t);else{if(t instanceof e){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._teardowns=null!==(n=this._teardowns)&&void 0!==n?n:[]).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)&&We(t,e)},e.prototype.remove=function(t){var n=this._teardowns;n&&We(n,t),t instanceof e&&t._removeParent(this)},e.EMPTY=((t=new e).closed=!0,t),e}();function Xe(e){return e instanceof Qe||e&&"closed"in e&&Ye(e.remove)&&Ye(e.add)&&Ye(e.unsubscribe)}function He(e){Ye(e)?e():e.unsubscribe()}Qe.EMPTY;var Ke={Promise:void 0},Ze=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return setTimeout.apply(void 0,ke([],Pe(e)))};function et(){}var tt=function(e){function t(t){var n=e.call(this)||this;return n.isStopped=!1,t?(n.destination=t,Xe(t)&&t.add(n)):n.destination=ot,n}return je(t,e),t.create=function(e,t,n){return new nt(e,t,n)},t.prototype.next=function(e){this.isStopped||this._next(e)},t.prototype.error=function(e){this.isStopped||(this.isStopped=!0,this._error(e))},t.prototype.complete=function(){this.isStopped||(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}(Qe),nt=function(e){function t(t,n,r){var i,o=e.call(this)||this;if(Ye(t))i=t;else if(t){var s;i=t.next,n=t.error,r=t.complete,s=t,i=null==i?void 0:i.bind(s),n=null==n?void 0:n.bind(s),r=null==r?void 0:r.bind(s)}return o.destination={next:i?rt(i):et,error:rt(null!=n?n:it),complete:r?rt(r):et},o}return je(t,e),t}(tt);function rt(e,t){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];try{e.apply(void 0,ke([],Pe(t)))}catch(e){!function(e){Ze(function(){throw e})}(e)}}}function it(e){throw e}var ot={closed:!0,next:et,error:it,complete:et},st="function"==typeof Symbol&&Symbol.observable||"@@observable";function at(e){return e}var ct=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,i=this,o=(r=e)&&r instanceof tt||function(e){return e&&Ye(e.next)&&Ye(e.error)&&Ye(e.complete)}(r)&&Xe(r)?e:new nt(e,t,n);return function(){var e=i,t=e.operator,n=e.source;o.add(t?t.call(o,n):n?i._subscribe(o):i._trySubscribe(o))}(),o},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 new(t=ut(t))(function(t,r){var i;i=n.subscribe(function(t){try{e(t)}catch(e){r(e),null==i||i.unsubscribe()}},r,t)})},e.prototype._subscribe=function(e){var t;return null===(t=this.source)||void 0===t?void 0:t.subscribe(e)},e.prototype[st]=function(){return this},e.prototype.pipe=function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return(0===(e=t).length?at:1===e.length?e[0]:function(t){return e.reduce(function(e,t){return t(e)},t)})(this)},e.prototype.toPromise=function(e){var t=this;return new(e=ut(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 ut(e){var t;return null!==(t=null!=e?e:Ke.Promise)&&void 0!==t?t:Promise}function lt(e,t,n){"name"in n?e.append(t,n,n.name):e.append(t,n)}function pt(e){return"undefined"!=typeof File&&e instanceof File||"undefined"!=typeof Blob&&e instanceof Blob}class ft extends ye{constructor({uri:e="/graphql",useGETForQueries:t,isExtractableFile:n=pt,FormData:r,formDataAppendFile:i=lt,print:o=ze,fetch:s,fetchOptions:a,credentials:c,headers:u,includeExtensions:l,includeUnusedVariables:p=!1}={}){super(f=>new ct(d=>{const h=f.getContext(),{options:y,body:m}=Be(f,o,qe,{http:{includeExtensions:l},options:a,credentials:c,headers:u},{http:h.http,options:h.fetchOptions,credentials:h.credentials,headers:h.headers});m.variables&&!p&&(m.variables=function(e,t){const n={...e},r=new Set(Object.keys(e));return T(t,{Variable(e,t,n){n&&"VariableDefinition"!==n.kind&&r.delete(e.name.value)}}),r.forEach(e=>{delete n[e]}),n}(m.variables,f.query));const{clone:v,files:g}=$e(m,n,"");let b,E=((e,t)=>{const n=e.getContext().uri;return n||("function"==typeof t?t(e):t||"/graphql")})(f,e);if(g.size){y.headers&&delete y.headers["content-type"];const e=new(r||FormData);e.append("operations",JSON.stringify(v));const t={};let n=0;g.forEach(e=>{t[++n]=e}),e.append("map",JSON.stringify(t)),n=0,g.forEach((t,r)=>{i(e,String(++n),r)}),y.body=e}else if(t&&!f.query.definitions.some(e=>"OperationDefinition"===e.kind&&"mutation"===e.operation)&&(y.method="GET"),"GET"===y.method){const e=function(e,t){const 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="",o=e;const s=e.indexOf("#");-1!==s&&(i=e.substr(s),o=e.substr(0,s));const a=-1===o.indexOf("?")?"?":"&";return{newURI:o+a+n.join("&")+i}}(E,m);if("parseError"in e)throw e.parseError;E=e.newURI}else y.body=JSON.stringify(v);"undefined"!=typeof AbortController&&(b=new AbortController,y.signal&&(y.signal.aborted?b.abort():y.signal.addEventListener("abort",()=>{b.abort()},{once:!0})),y.signal=b.signal);let O;var N;return(s||fetch)(E,y).then(e=>(f.setContext({response:e}),e)).then((N=f,e=>e.text().then(t=>{const n=Ue(e,t);if(!Array.isArray(n)&&!Le.call(n,"data")&&!Le.call(n,"errors"))throw new we(`Server response was malformed for query '${Array.isArray(N)?N.map(e=>e.operationName):N.operationName}'.`,{response:e,bodyText:t});return n}))).then(e=>{d.next(e),d.complete()}).catch(e=>{O||d.error(e)}),()=>{O=!0,b&&b.abort()}}))}}function dt({children:t,makeClient:n}){return e.createElement(a,{makeClient:n},e.createElement(e.Fragment,null,t))}class ht extends c{constructor(e){const i=new me(async t=>({credentials:"include",headers:{"Accept-Language":"mn",authorization:`Bearer ${e.getToken()}`,...t.headers}})),o=new De(({error:e})=>{t.is(e)&&e.statusCode}),s=new n({uri:`${e.host}/graphql`,fetchOptions:{}}),a=new ft({uri:`${e.host}/graphql`,headers:{"Apollo-Require-Preflight":"true"}});super({cache:e.cache||yt,link:r.from([a,s,i,e.error||o])})}}const yt=new s({typePolicies:{Website:{fields:{orders:Ve(["filter","sort","status"]),lineItems:Ve(["filter","sort"])}},Query:{fields:{products:Ve(["filter","sort"]),orders:Ve(["filter","sort"])}}}});export{dt as ApolloWrapper,ht as GenerateMakeClient};
|
|
2
|
+
//# sourceMappingURL=index.esm.js.map
|