All Downloads are FREE. Search and download functionalities are using the official Maven repository.

static.vendor.altair.0-es2018.worker.js Maven / Gradle / Ivy

!function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,(function(t){return e[t]}).bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s="qFDF")}({qFDF:function(e,t,n){"use strict";n.r(t);const r=Symbol("Comlink.proxy"),i=Symbol("Comlink.endpoint"),a=Symbol("Comlink.releaseProxy"),o=Symbol("Comlink.thrown"),s=e=>"object"==typeof e&&null!==e||"function"==typeof e,c=new Map([["proxy",{canHandle:e=>s(e)&&e[r],serialize(e){const{port1:t,port2:n}=new MessageChannel;return u(e,t),[n,[n]]},deserialize:e=>(e.start(),function e(t,n=[],r=function(){}){let o=!1;const s=new Proxy(r,{get(r,i){if(p(o),i===a)return()=>m(t,{type:5,path:n.map(e=>e.toString())}).then(()=>{l(t),o=!0});if("then"===i){if(0===n.length)return{then:()=>s};const e=m(t,{type:0,path:n.map(e=>e.toString())}).then(v);return e.then.bind(e)}return e(t,[...n,i])},set(e,r,i){p(o);const[a,s]=h(i);return m(t,{type:1,path:[...n,r].map(e=>e.toString()),value:a},s).then(v)},apply(r,a,s){p(o);const c=n[n.length-1];if(c===i)return m(t,{type:4}).then(v);if("bind"===c)return e(t,n.slice(0,-1));const[u,l]=f(s);return m(t,{type:2,path:n.map(e=>e.toString()),argumentList:u},l).then(v)},construct(e,r){p(o);const[i,a]=f(r);return m(t,{type:3,path:n.map(e=>e.toString()),argumentList:i},a).then(v)}});return s}(e,[],void 0))}],["throw",{canHandle:e=>s(e)&&o in e,serialize({value:e}){let t;return t=e instanceof Error?{isError:!0,value:{message:e.message,name:e.name,stack:e.stack}}:{isError:!1,value:e},[t,[]]},deserialize(e){if(e.isError)throw Object.assign(new Error(e.value.message),e.value);throw e.value}}]]);function u(e,t=self){t.addEventListener("message",(function n(i){if(!i||!i.data)return;const{id:a,type:s,path:c}=Object.assign({path:[]},i.data),p=(i.data.argumentList||[]).map(v);let f;try{const t=c.slice(0,-1).reduce((e,t)=>e[t],e),n=c.reduce((e,t)=>e[t],e);switch(s){case 0:f=n;break;case 1:t[c.slice(-1)[0]]=v(i.data.value),f=!0;break;case 2:f=n.apply(t,p);break;case 3:f=function(e){return Object.assign(e,{[r]:!0})}(new n(...p));break;case 4:{const{port1:t,port2:n}=new MessageChannel;u(e,n),f=function(e,t){return d.set(e,t),e}(t,[t])}break;case 5:f=void 0}}catch(m){f={value:m,[o]:0}}Promise.resolve(f).catch(e=>({value:e,[o]:0})).then(e=>{const[r,i]=h(e);t.postMessage(Object.assign(Object.assign({},r),{id:a}),i),5===s&&(t.removeEventListener("message",n),l(t))})})),t.start&&t.start()}function l(e){(function(e){return"MessagePort"===e.constructor.name})(e)&&e.close()}function p(e){if(e)throw new Error("Proxy has been released and is not useable")}function f(e){const t=e.map(h);return[t.map(e=>e[0]),(n=t.map(e=>e[1]),Array.prototype.concat.apply([],n))];var n}const d=new WeakMap;function h(e){for(const[t,n]of c)if(n.canHandle(e)){const[r,i]=n.serialize(e);return[{type:3,name:t,value:r},i]}return[{type:0,value:e},d.get(e)||[]]}function v(e){switch(e.type){case 3:return c.get(e.name).deserialize(e.value);case 0:return e.value}}function m(e,t,n){return new Promise(r=>{const i=new Array(4).fill(0).map(()=>Math.floor(Math.random()*Number.MAX_SAFE_INTEGER).toString(16)).join("-");e.addEventListener("message",(function t(n){n.data&&n.data.id&&n.data.id===i&&(e.removeEventListener("message",t),r(n.data))})),e.start&&e.start(),e.postMessage(Object.assign({id:i},t),n)})}var y=Object.values||function(e){return Object.keys(e).map((function(t){return e[t]}))};function E(e,t){return e.reduce((function(e,n){return e[t(n)]=n,e}),Object.create(null))}var T="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):void 0;function N(e){return(N="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function g(e){return function e(t,n){switch(N(t)){case"string":return JSON.stringify(t);case"function":return t.name?"[function ".concat(t.name,"]"):"[function]";case"object":return null===t?"null":function(t,n){if(-1!==n.indexOf(t))return"[Circular]";var r=[].concat(n,[t]),i=function(e){var t=e[String(T)];return"function"==typeof t?t:"function"==typeof e.inspect?e.inspect:void 0}(t);if(void 0!==i){var a=i.call(t);if(a!==t)return"string"==typeof a?a:e(a,r)}else if(Array.isArray(t))return function(t,n){if(0===t.length)return"[]";if(n.length>2)return"[Array]";for(var r=Math.min(10,t.length),i=t.length-r,a=[],o=0;o1&&a.push("... ".concat(i," more items")),"["+a.join(", ")+"]"}(t,r);return function(t,n){var r=Object.keys(t);return 0===r.length?"{}":n.length>2?"["+function(e){var t=Object.prototype.toString.call(e).replace(/^\[object /,"").replace(/]$/,"");if("Object"===t&&"function"==typeof e.constructor){var n=e.constructor.name;if("string"==typeof n&&""!==n)return n}return t}(t)+"]":"{ "+r.map((function(r){return r+": "+e(t[r],n)})).join(", ")+" }"}(t,r)}(t,n);default:return String(t)}}(e,[])}function I(e,t){if(!Boolean(e))throw new Error(t||"Unexpected invariant triggered")}function O(e,t){if(!Boolean(e))throw new Error(t)}function _(e,t,n){return e.reduce((function(e,r){return e[t(r)]=n(r),e}),Object.create(null))}var b=Object.freeze({NAME:"Name",DOCUMENT:"Document",OPERATION_DEFINITION:"OperationDefinition",VARIABLE_DEFINITION:"VariableDefinition",SELECTION_SET:"SelectionSet",FIELD:"Field",ARGUMENT:"Argument",FRAGMENT_SPREAD:"FragmentSpread",INLINE_FRAGMENT:"InlineFragment",FRAGMENT_DEFINITION:"FragmentDefinition",VARIABLE:"Variable",INT:"IntValue",FLOAT:"FloatValue",STRING:"StringValue",BOOLEAN:"BooleanValue",NULL:"NullValue",ENUM:"EnumValue",LIST:"ListValue",OBJECT:"ObjectValue",OBJECT_FIELD:"ObjectField",DIRECTIVE:"Directive",NAMED_TYPE:"NamedType",LIST_TYPE:"ListType",NON_NULL_TYPE:"NonNullType",SCHEMA_DEFINITION:"SchemaDefinition",OPERATION_TYPE_DEFINITION:"OperationTypeDefinition",SCALAR_TYPE_DEFINITION:"ScalarTypeDefinition",OBJECT_TYPE_DEFINITION:"ObjectTypeDefinition",FIELD_DEFINITION:"FieldDefinition",INPUT_VALUE_DEFINITION:"InputValueDefinition",INTERFACE_TYPE_DEFINITION:"InterfaceTypeDefinition",UNION_TYPE_DEFINITION:"UnionTypeDefinition",ENUM_TYPE_DEFINITION:"EnumTypeDefinition",ENUM_VALUE_DEFINITION:"EnumValueDefinition",INPUT_OBJECT_TYPE_DEFINITION:"InputObjectTypeDefinition",DIRECTIVE_DEFINITION:"DirectiveDefinition",SCHEMA_EXTENSION:"SchemaExtension",SCALAR_TYPE_EXTENSION:"ScalarTypeExtension",OBJECT_TYPE_EXTENSION:"ObjectTypeExtension",INTERFACE_TYPE_EXTENSION:"InterfaceTypeExtension",UNION_TYPE_EXTENSION:"UnionTypeExtension",ENUM_TYPE_EXTENSION:"EnumTypeExtension",INPUT_OBJECT_TYPE_EXTENSION:"InputObjectTypeExtension"}),D=Object.freeze({SOF:"",EOF:"",BANG:"!",DOLLAR:"$",AMP:"&",PAREN_L:"(",PAREN_R:")",SPREAD:"...",COLON:":",EQUALS:"=",AT:"@",BRACKET_L:"[",BRACKET_R:"]",BRACE_L:"{",PIPE:"|",BRACE_R:"}",NAME:"Name",INT:"Int",FLOAT:"Float",STRING:"String",BLOCK_STRING:"BlockString",COMMENT:"Comment"});function A(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e.prototype.toString;e.prototype.toJSON=t,e.prototype.inspect=t,T&&(e.prototype[T]=t)}function S(e){return(S="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function x(e){return"object"==S(e)&&null!==e}function w(e,t){for(var n,r=/\r\n|[\n\r]/g,i=1,a=t+1;(n=r.exec(e.body))&&n.index120){for(var l=Math.floor(o/80),p=o%80,f=[],d=0;d0||O(0,"line in locationOffset is 1-indexed and must be positive"),this.locationOffset.column>0||O(0,"column in locationOffset is 1-indexed and must be positive")};function M(e){var t=e.split(/\r\n|[\n\r]/g),n=function(e){for(var t=null,n=1;n0&&V(t[0]);)t.shift();for(;t.length>0&&V(t[t.length-1]);)t.pop();return t.join("\n")}function U(e){for(var t=0;t=i)return new G(D.EOF,i,i,o,s,t);var c=r.charCodeAt(a);switch(c){case 33:return new G(D.BANG,a,a+1,o,s,t);case 35:return function(e,t,n,r,i){var a,o=e.body,s=t;do{a=o.charCodeAt(++s)}while(!isNaN(a)&&(a>31||9===a));return new G(D.COMMENT,t,s,n,r,i,o.slice(t+1,s))}(n,a,o,s,t);case 36:return new G(D.DOLLAR,a,a+1,o,s,t);case 38:return new G(D.AMP,a,a+1,o,s,t);case 40:return new G(D.PAREN_L,a,a+1,o,s,t);case 41:return new G(D.PAREN_R,a,a+1,o,s,t);case 46:if(46===r.charCodeAt(a+1)&&46===r.charCodeAt(a+2))return new G(D.SPREAD,a,a+3,o,s,t);break;case 58:return new G(D.COLON,a,a+1,o,s,t);case 61:return new G(D.EQUALS,a,a+1,o,s,t);case 64:return new G(D.AT,a,a+1,o,s,t);case 91:return new G(D.BRACKET_L,a,a+1,o,s,t);case 93:return new G(D.BRACKET_R,a,a+1,o,s,t);case 123:return new G(D.BRACE_L,a,a+1,o,s,t);case 124:return new G(D.PIPE,a,a+1,o,s,t);case 125:return new G(D.BRACE_R,a,a+1,o,s,t);case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 95:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:return function(e,t,n,r,i){for(var a=e.body,o=a.length,s=t+1,c=0;s!==o&&!isNaN(c=a.charCodeAt(s))&&(95===c||c>=48&&c<=57||c>=65&&c<=90||c>=97&&c<=122);)++s;return new G(D.NAME,t,s,n,r,i,a.slice(t,s))}(n,a,o,s,t);case 45:case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return function(e,t,n,r,i,a){var o=e.body,s=n,c=t,u=!1;if(45===s&&(s=o.charCodeAt(++c)),48===s){if((s=o.charCodeAt(++c))>=48&&s<=57)throw C(e,c,"Invalid number, unexpected digit after 0: ".concat(J(s),"."))}else c=K(e,c,s),s=o.charCodeAt(c);if(46===s&&(u=!0,s=o.charCodeAt(++c),c=K(e,c,s),s=o.charCodeAt(c)),69!==s&&101!==s||(u=!0,43!==(s=o.charCodeAt(++c))&&45!==s||(s=o.charCodeAt(++c)),c=K(e,c,s),s=o.charCodeAt(c)),46===s||69===s||101===s)throw C(e,c,"Invalid number, expected digit but got: ".concat(J(s),"."));return new G(u?D.FLOAT:D.INT,t,c,r,i,a,o.slice(t,c))}(n,a,c,o,s,t);case 34:return 34===r.charCodeAt(a+1)&&34===r.charCodeAt(a+2)?function(e,t,n,r,i,a){for(var o=e.body,s=t+3,c=s,u=0,l="";s=48&&a<=57){do{a=r.charCodeAt(++i)}while(a>=48&&a<=57);return i}throw C(e,i,"Invalid number, expected digit but got: ".concat(J(a),"."))}function q(e){return e>=48&&e<=57?e-48:e>=65&&e<=70?e-55:e>=97&&e<=102?e-87:-1}j(P),A(G,(function(){return{kind:this.kind,value:this.value,line:this.line,column:this.column}}));var Q=Object.freeze({QUERY:"QUERY",MUTATION:"MUTATION",SUBSCRIPTION:"SUBSCRIPTION",FIELD:"FIELD",FRAGMENT_DEFINITION:"FRAGMENT_DEFINITION",FRAGMENT_SPREAD:"FRAGMENT_SPREAD",INLINE_FRAGMENT:"INLINE_FRAGMENT",VARIABLE_DEFINITION:"VARIABLE_DEFINITION",SCHEMA:"SCHEMA",SCALAR:"SCALAR",OBJECT:"OBJECT",FIELD_DEFINITION:"FIELD_DEFINITION",ARGUMENT_DEFINITION:"ARGUMENT_DEFINITION",INTERFACE:"INTERFACE",UNION:"UNION",ENUM:"ENUM",ENUM_VALUE:"ENUM_VALUE",INPUT_OBJECT:"INPUT_OBJECT",INPUT_FIELD_DEFINITION:"INPUT_FIELD_DEFINITION"}),z=function(){function e(e,t){var n="string"==typeof e?new P(e):e;n instanceof P||O(0,"Must provide Source. Received: ".concat(g(n))),this._lexer=function(e,t){var n=new G(D.SOF,0,0,0,0,null);return{source:e,options:void 0,lastToken:n,token:n,line:1,lineStart:0,advance:B,lookahead:Y}}(n),this._options=t||{}}var t=e.prototype;return t.parseName=function(){var e=this.expectToken(D.NAME);return{kind:b.NAME,value:e.value,loc:this.loc(e)}},t.parseDocument=function(){var e=this._lexer.token;return{kind:b.DOCUMENT,definitions:this.many(D.SOF,this.parseDefinition,D.EOF),loc:this.loc(e)}},t.parseDefinition=function(){if(this.peek(D.NAME))switch(this._lexer.token.value){case"query":case"mutation":case"subscription":return this.parseOperationDefinition();case"fragment":return this.parseFragmentDefinition();case"schema":case"scalar":case"type":case"interface":case"union":case"enum":case"input":case"directive":return this.parseTypeSystemDefinition();case"extend":return this.parseTypeSystemExtension()}else{if(this.peek(D.BRACE_L))return this.parseOperationDefinition();if(this.peekDescription())return this.parseTypeSystemDefinition()}throw this.unexpected()},t.parseOperationDefinition=function(){var e=this._lexer.token;if(this.peek(D.BRACE_L))return{kind:b.OPERATION_DEFINITION,operation:"query",name:void 0,variableDefinitions:[],directives:[],selectionSet:this.parseSelectionSet(),loc:this.loc(e)};var t,n=this.parseOperationType();return this.peek(D.NAME)&&(t=this.parseName()),{kind:b.OPERATION_DEFINITION,operation:n,name:t,variableDefinitions:this.parseVariableDefinitions(),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(e)}},t.parseOperationType=function(){var e=this.expectToken(D.NAME);switch(e.value){case"query":return"query";case"mutation":return"mutation";case"subscription":return"subscription"}throw this.unexpected(e)},t.parseVariableDefinitions=function(){return this.optionalMany(D.PAREN_L,this.parseVariableDefinition,D.PAREN_R)},t.parseVariableDefinition=function(){var e=this._lexer.token;return{kind:b.VARIABLE_DEFINITION,variable:this.parseVariable(),type:(this.expectToken(D.COLON),this.parseTypeReference()),defaultValue:this.expectOptionalToken(D.EQUALS)?this.parseValueLiteral(!0):void 0,directives:this.parseDirectives(!0),loc:this.loc(e)}},t.parseVariable=function(){var e=this._lexer.token;return this.expectToken(D.DOLLAR),{kind:b.VARIABLE,name:this.parseName(),loc:this.loc(e)}},t.parseSelectionSet=function(){var e=this._lexer.token;return{kind:b.SELECTION_SET,selections:this.many(D.BRACE_L,this.parseSelection,D.BRACE_R),loc:this.loc(e)}},t.parseSelection=function(){return this.peek(D.SPREAD)?this.parseFragment():this.parseField()},t.parseField=function(){var e,t,n=this._lexer.token,r=this.parseName();return this.expectOptionalToken(D.COLON)?(e=r,t=this.parseName()):t=r,{kind:b.FIELD,alias:e,name:t,arguments:this.parseArguments(!1),directives:this.parseDirectives(!1),selectionSet:this.peek(D.BRACE_L)?this.parseSelectionSet():void 0,loc:this.loc(n)}},t.parseArguments=function(e){return this.optionalMany(D.PAREN_L,e?this.parseConstArgument:this.parseArgument,D.PAREN_R)},t.parseArgument=function(){var e=this._lexer.token,t=this.parseName();return this.expectToken(D.COLON),{kind:b.ARGUMENT,name:t,value:this.parseValueLiteral(!1),loc:this.loc(e)}},t.parseConstArgument=function(){var e=this._lexer.token;return{kind:b.ARGUMENT,name:this.parseName(),value:(this.expectToken(D.COLON),this.parseValueLiteral(!0)),loc:this.loc(e)}},t.parseFragment=function(){var e=this._lexer.token;this.expectToken(D.SPREAD);var t=this.expectOptionalKeyword("on");return!t&&this.peek(D.NAME)?{kind:b.FRAGMENT_SPREAD,name:this.parseFragmentName(),directives:this.parseDirectives(!1),loc:this.loc(e)}:{kind:b.INLINE_FRAGMENT,typeCondition:t?this.parseNamedType():void 0,directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(e)}},t.parseFragmentDefinition=function(){var e=this._lexer.token;return this.expectKeyword("fragment"),this._options.experimentalFragmentVariables?{kind:b.FRAGMENT_DEFINITION,name:this.parseFragmentName(),variableDefinitions:this.parseVariableDefinitions(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(e)}:{kind:b.FRAGMENT_DEFINITION,name:this.parseFragmentName(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(e)}},t.parseFragmentName=function(){if("on"===this._lexer.token.value)throw this.unexpected();return this.parseName()},t.parseValueLiteral=function(e){var t=this._lexer.token;switch(t.kind){case D.BRACKET_L:return this.parseList(e);case D.BRACE_L:return this.parseObject(e);case D.INT:return this._lexer.advance(),{kind:b.INT,value:t.value,loc:this.loc(t)};case D.FLOAT:return this._lexer.advance(),{kind:b.FLOAT,value:t.value,loc:this.loc(t)};case D.STRING:case D.BLOCK_STRING:return this.parseStringLiteral();case D.NAME:return"true"===t.value||"false"===t.value?(this._lexer.advance(),{kind:b.BOOLEAN,value:"true"===t.value,loc:this.loc(t)}):"null"===t.value?(this._lexer.advance(),{kind:b.NULL,loc:this.loc(t)}):(this._lexer.advance(),{kind:b.ENUM,value:t.value,loc:this.loc(t)});case D.DOLLAR:if(!e)return this.parseVariable()}throw this.unexpected()},t.parseStringLiteral=function(){var e=this._lexer.token;return this._lexer.advance(),{kind:b.STRING,value:e.value,block:e.kind===D.BLOCK_STRING,loc:this.loc(e)}},t.parseList=function(e){var t=this,n=this._lexer.token;return{kind:b.LIST,values:this.any(D.BRACKET_L,(function(){return t.parseValueLiteral(e)}),D.BRACKET_R),loc:this.loc(n)}},t.parseObject=function(e){var t=this,n=this._lexer.token;return{kind:b.OBJECT,fields:this.any(D.BRACE_L,(function(){return t.parseObjectField(e)}),D.BRACE_R),loc:this.loc(n)}},t.parseObjectField=function(e){var t=this._lexer.token,n=this.parseName();return this.expectToken(D.COLON),{kind:b.OBJECT_FIELD,name:n,value:this.parseValueLiteral(e),loc:this.loc(t)}},t.parseDirectives=function(e){for(var t=[];this.peek(D.AT);)t.push(this.parseDirective(e));return t},t.parseDirective=function(e){var t=this._lexer.token;return this.expectToken(D.AT),{kind:b.DIRECTIVE,name:this.parseName(),arguments:this.parseArguments(e),loc:this.loc(t)}},t.parseTypeReference=function(){var e,t=this._lexer.token;return this.expectOptionalToken(D.BRACKET_L)?(e=this.parseTypeReference(),this.expectToken(D.BRACKET_R),e={kind:b.LIST_TYPE,type:e,loc:this.loc(t)}):e=this.parseNamedType(),this.expectOptionalToken(D.BANG)?{kind:b.NON_NULL_TYPE,type:e,loc:this.loc(t)}:e},t.parseNamedType=function(){var e=this._lexer.token;return{kind:b.NAMED_TYPE,name:this.parseName(),loc:this.loc(e)}},t.parseTypeSystemDefinition=function(){var e=this.peekDescription()?this._lexer.lookahead():this._lexer.token;if(e.kind===D.NAME)switch(e.value){case"schema":return this.parseSchemaDefinition();case"scalar":return this.parseScalarTypeDefinition();case"type":return this.parseObjectTypeDefinition();case"interface":return this.parseInterfaceTypeDefinition();case"union":return this.parseUnionTypeDefinition();case"enum":return this.parseEnumTypeDefinition();case"input":return this.parseInputObjectTypeDefinition();case"directive":return this.parseDirectiveDefinition()}throw this.unexpected(e)},t.peekDescription=function(){return this.peek(D.STRING)||this.peek(D.BLOCK_STRING)},t.parseDescription=function(){if(this.peekDescription())return this.parseStringLiteral()},t.parseSchemaDefinition=function(){var e=this._lexer.token;this.expectKeyword("schema");var t=this.parseDirectives(!0),n=this.many(D.BRACE_L,this.parseOperationTypeDefinition,D.BRACE_R);return{kind:b.SCHEMA_DEFINITION,directives:t,operationTypes:n,loc:this.loc(e)}},t.parseOperationTypeDefinition=function(){var e=this._lexer.token,t=this.parseOperationType();this.expectToken(D.COLON);var n=this.parseNamedType();return{kind:b.OPERATION_TYPE_DEFINITION,operation:t,type:n,loc:this.loc(e)}},t.parseScalarTypeDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("scalar");var n=this.parseName(),r=this.parseDirectives(!0);return{kind:b.SCALAR_TYPE_DEFINITION,description:t,name:n,directives:r,loc:this.loc(e)}},t.parseObjectTypeDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("type");var n=this.parseName(),r=this.parseImplementsInterfaces(),i=this.parseDirectives(!0),a=this.parseFieldsDefinition();return{kind:b.OBJECT_TYPE_DEFINITION,description:t,name:n,interfaces:r,directives:i,fields:a,loc:this.loc(e)}},t.parseImplementsInterfaces=function(){var e=[];if(this.expectOptionalKeyword("implements")){this.expectOptionalToken(D.AMP);do{e.push(this.parseNamedType())}while(this.expectOptionalToken(D.AMP)||this._options.allowLegacySDLImplementsInterfaces&&this.peek(D.NAME))}return e},t.parseFieldsDefinition=function(){return this._options.allowLegacySDLEmptyFields&&this.peek(D.BRACE_L)&&this._lexer.lookahead().kind===D.BRACE_R?(this._lexer.advance(),this._lexer.advance(),[]):this.optionalMany(D.BRACE_L,this.parseFieldDefinition,D.BRACE_R)},t.parseFieldDefinition=function(){var e=this._lexer.token,t=this.parseDescription(),n=this.parseName(),r=this.parseArgumentDefs();this.expectToken(D.COLON);var i=this.parseTypeReference(),a=this.parseDirectives(!0);return{kind:b.FIELD_DEFINITION,description:t,name:n,arguments:r,type:i,directives:a,loc:this.loc(e)}},t.parseArgumentDefs=function(){return this.optionalMany(D.PAREN_L,this.parseInputValueDef,D.PAREN_R)},t.parseInputValueDef=function(){var e=this._lexer.token,t=this.parseDescription(),n=this.parseName();this.expectToken(D.COLON);var r,i=this.parseTypeReference();this.expectOptionalToken(D.EQUALS)&&(r=this.parseValueLiteral(!0));var a=this.parseDirectives(!0);return{kind:b.INPUT_VALUE_DEFINITION,description:t,name:n,type:i,defaultValue:r,directives:a,loc:this.loc(e)}},t.parseInterfaceTypeDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("interface");var n=this.parseName(),r=this.parseDirectives(!0),i=this.parseFieldsDefinition();return{kind:b.INTERFACE_TYPE_DEFINITION,description:t,name:n,directives:r,fields:i,loc:this.loc(e)}},t.parseUnionTypeDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("union");var n=this.parseName(),r=this.parseDirectives(!0),i=this.parseUnionMemberTypes();return{kind:b.UNION_TYPE_DEFINITION,description:t,name:n,directives:r,types:i,loc:this.loc(e)}},t.parseUnionMemberTypes=function(){var e=[];if(this.expectOptionalToken(D.EQUALS)){this.expectOptionalToken(D.PIPE);do{e.push(this.parseNamedType())}while(this.expectOptionalToken(D.PIPE))}return e},t.parseEnumTypeDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("enum");var n=this.parseName(),r=this.parseDirectives(!0),i=this.parseEnumValuesDefinition();return{kind:b.ENUM_TYPE_DEFINITION,description:t,name:n,directives:r,values:i,loc:this.loc(e)}},t.parseEnumValuesDefinition=function(){return this.optionalMany(D.BRACE_L,this.parseEnumValueDefinition,D.BRACE_R)},t.parseEnumValueDefinition=function(){var e=this._lexer.token,t=this.parseDescription(),n=this.parseName(),r=this.parseDirectives(!0);return{kind:b.ENUM_VALUE_DEFINITION,description:t,name:n,directives:r,loc:this.loc(e)}},t.parseInputObjectTypeDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("input");var n=this.parseName(),r=this.parseDirectives(!0),i=this.parseInputFieldsDefinition();return{kind:b.INPUT_OBJECT_TYPE_DEFINITION,description:t,name:n,directives:r,fields:i,loc:this.loc(e)}},t.parseInputFieldsDefinition=function(){return this.optionalMany(D.BRACE_L,this.parseInputValueDef,D.BRACE_R)},t.parseTypeSystemExtension=function(){var e=this._lexer.lookahead();if(e.kind===D.NAME)switch(e.value){case"schema":return this.parseSchemaExtension();case"scalar":return this.parseScalarTypeExtension();case"type":return this.parseObjectTypeExtension();case"interface":return this.parseInterfaceTypeExtension();case"union":return this.parseUnionTypeExtension();case"enum":return this.parseEnumTypeExtension();case"input":return this.parseInputObjectTypeExtension()}throw this.unexpected(e)},t.parseSchemaExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("schema");var t=this.parseDirectives(!0),n=this.optionalMany(D.BRACE_L,this.parseOperationTypeDefinition,D.BRACE_R);if(0===t.length&&0===n.length)throw this.unexpected();return{kind:b.SCHEMA_EXTENSION,directives:t,operationTypes:n,loc:this.loc(e)}},t.parseScalarTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("scalar");var t=this.parseName(),n=this.parseDirectives(!0);if(0===n.length)throw this.unexpected();return{kind:b.SCALAR_TYPE_EXTENSION,name:t,directives:n,loc:this.loc(e)}},t.parseObjectTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("type");var t=this.parseName(),n=this.parseImplementsInterfaces(),r=this.parseDirectives(!0),i=this.parseFieldsDefinition();if(0===n.length&&0===r.length&&0===i.length)throw this.unexpected();return{kind:b.OBJECT_TYPE_EXTENSION,name:t,interfaces:n,directives:r,fields:i,loc:this.loc(e)}},t.parseInterfaceTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("interface");var t=this.parseName(),n=this.parseDirectives(!0),r=this.parseFieldsDefinition();if(0===n.length&&0===r.length)throw this.unexpected();return{kind:b.INTERFACE_TYPE_EXTENSION,name:t,directives:n,fields:r,loc:this.loc(e)}},t.parseUnionTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("union");var t=this.parseName(),n=this.parseDirectives(!0),r=this.parseUnionMemberTypes();if(0===n.length&&0===r.length)throw this.unexpected();return{kind:b.UNION_TYPE_EXTENSION,name:t,directives:n,types:r,loc:this.loc(e)}},t.parseEnumTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("enum");var t=this.parseName(),n=this.parseDirectives(!0),r=this.parseEnumValuesDefinition();if(0===n.length&&0===r.length)throw this.unexpected();return{kind:b.ENUM_TYPE_EXTENSION,name:t,directives:n,values:r,loc:this.loc(e)}},t.parseInputObjectTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("input");var t=this.parseName(),n=this.parseDirectives(!0),r=this.parseInputFieldsDefinition();if(0===n.length&&0===r.length)throw this.unexpected();return{kind:b.INPUT_OBJECT_TYPE_EXTENSION,name:t,directives:n,fields:r,loc:this.loc(e)}},t.parseDirectiveDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("directive"),this.expectToken(D.AT);var n=this.parseName(),r=this.parseArgumentDefs(),i=this.expectOptionalKeyword("repeatable");this.expectKeyword("on");var a=this.parseDirectiveLocations();return{kind:b.DIRECTIVE_DEFINITION,description:t,name:n,arguments:r,repeatable:i,locations:a,loc:this.loc(e)}},t.parseDirectiveLocations=function(){this.expectOptionalToken(D.PIPE);var e=[];do{e.push(this.parseDirectiveLocation())}while(this.expectOptionalToken(D.PIPE));return e},t.parseDirectiveLocation=function(){var e=this._lexer.token,t=this.parseName();if(void 0!==Q[t.value])return t;throw this.unexpected(e)},t.loc=function(e){if(!this._options.noLocation)return new H(e,this._lexer.lastToken,this._lexer.source)},t.peek=function(e){return this._lexer.token.kind===e},t.expectToken=function(e){var t=this._lexer.token;if(t.kind===e)return this._lexer.advance(),t;throw C(this._lexer.source,t.start,"Expected ".concat(e,", found ").concat($(t)))},t.expectOptionalToken=function(e){var t=this._lexer.token;if(t.kind===e)return this._lexer.advance(),t},t.expectKeyword=function(e){var t=this._lexer.token;if(t.kind!==D.NAME||t.value!==e)throw C(this._lexer.source,t.start,'Expected "'.concat(e,'", found ').concat($(t)));this._lexer.advance()},t.expectOptionalKeyword=function(e){var t=this._lexer.token;return t.kind===D.NAME&&t.value===e&&(this._lexer.advance(),!0)},t.unexpected=function(e){var t=e||this._lexer.token;return C(this._lexer.source,t.start,"Unexpected ".concat($(t)))},t.any=function(e,t,n){this.expectToken(e);for(var r=[];!this.expectOptionalToken(n);)r.push(t.call(this));return r},t.optionalMany=function(e,t,n){if(this.expectOptionalToken(e)){var r=[];do{r.push(t.call(this))}while(!this.expectOptionalToken(n));return r}return[]},t.many=function(e,t,n){this.expectToken(e);var r=[];do{r.push(t.call(this))}while(!this.expectOptionalToken(n));return r},e}();function H(e,t,n){this.start=e.start,this.end=t.end,this.startToken=e,this.endToken=t,this.source=n}function $(e){var t=e.value;return t?"".concat(e.kind,' "').concat(t,'"'):e.kind}function W(e){return e.kind===b.OPERATION_DEFINITION||e.kind===b.FRAGMENT_DEFINITION}function Z(e){return e.kind===b.SCALAR_TYPE_DEFINITION||e.kind===b.OBJECT_TYPE_DEFINITION||e.kind===b.INTERFACE_TYPE_DEFINITION||e.kind===b.UNION_TYPE_DEFINITION||e.kind===b.ENUM_TYPE_DEFINITION||e.kind===b.INPUT_OBJECT_TYPE_DEFINITION}A(H,(function(){return{start:this.start,end:this.end}}));var ee={Name:[],Document:["definitions"],OperationDefinition:["name","variableDefinitions","directives","selectionSet"],VariableDefinition:["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:["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:["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","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","directives","fields"],UnionTypeExtension:["name","directives","types"],EnumTypeExtension:["name","directives","values"],InputObjectTypeExtension:["name","directives","fields"]},te=Object.freeze({});function ne(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:ee,r=void 0,i=Array.isArray(e),a=[e],o=-1,s=[],c=void 0,u=void 0,l=void 0,p=[],f=[],d=e;do{var h=++o===a.length,v=h&&0!==s.length;if(h){if(u=0===f.length?void 0:p[p.length-1],c=l,l=f.pop(),v){if(i)c=c.slice();else{for(var m={},y=0,E=Object.keys(c);y0?e:void 0}Se.prototype.toString=function(){return"["+String(this.ofType)+"]"},j(Se),A(Se),xe.prototype.toString=function(){return String(this.ofType)+"!"},j(xe),A(xe);var Re=function(){function e(e){var t=e.parseValue||pe;this.name=e.name,this.description=e.description,this.serialize=e.serialize||pe,this.parseValue=t,this.parseLiteral=e.parseLiteral||function(e){return t(function e(t,n){switch(t.kind){case b.NULL:return null;case b.INT:return parseInt(t.value,10);case b.FLOAT:return parseFloat(t.value);case b.STRING:case b.ENUM:case b.BOOLEAN:return t.value;case b.LIST:return t.values.map((function(t){return e(t,n)}));case b.OBJECT:return _(t.fields,(function(e){return e.name.value}),(function(t){return e(t.value,n)}));case b.VARIABLE:var r=t.name.value;return n&&!fe(n[r])?n[r]:void 0}I(!1,"Unexpected value node: "+g(t))}(e))},this.extensions=e.extensions&&ue(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=Le(e.extensionASTNodes),"string"==typeof e.name||O(0,"Must provide name."),null==e.serialize||"function"==typeof e.serialize||O(0,"".concat(this.name,' must provide "serialize" function. If this custom Scalar is also used as an input type, ensure "parseValue" and "parseLiteral" functions are also provided.')),e.parseLiteral&&("function"==typeof e.parseValue&&"function"==typeof e.parseLiteral||O(0,"".concat(this.name,' must provide both "parseValue" and "parseLiteral" functions.')))}var t=e.prototype;return t.toConfig=function(){return{name:this.name,description:this.description,serialize:this.serialize,parseValue:this.parseValue,parseLiteral:this.parseLiteral,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes||[]}},t.toString=function(){return this.name},e}();j(Re),A(Re);var Ce=function(){function e(e){this.name=e.name,this.description=e.description,this.isTypeOf=e.isTypeOf,this.extensions=e.extensions&&ue(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=Le(e.extensionASTNodes),this._fields=Pe.bind(void 0,e),this._interfaces=je.bind(void 0,e),"string"==typeof e.name||O(0,"Must provide name."),null==e.isTypeOf||"function"==typeof e.isTypeOf||O(0,"".concat(this.name,' must provide "isTypeOf" as a function, ')+"but got: ".concat(g(e.isTypeOf),"."))}var t=e.prototype;return t.getFields=function(){return"function"==typeof this._fields&&(this._fields=this._fields()),this._fields},t.getInterfaces=function(){return"function"==typeof this._interfaces&&(this._interfaces=this._interfaces()),this._interfaces},t.toConfig=function(){return{name:this.name,description:this.description,interfaces:this.getInterfaces(),fields:Ue(this.getFields()),isTypeOf:this.isTypeOf,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes||[]}},t.toString=function(){return this.name},e}();function je(e){var t=Fe(e.interfaces)||[];return Array.isArray(t)||O(0,"".concat(e.name," interfaces must be an Array or a function which returns an Array.")),t}function Pe(e){var t=Fe(e.fields)||{};return Me(t)||O(0,"".concat(e.name," fields must be an object with field names as keys or a function which returns such an object.")),ce(t,(function(t,n){Me(t)||O(0,"".concat(e.name,".").concat(n," field config must be an object")),!("isDeprecated"in t)||O(0,"".concat(e.name,".").concat(n,' should provide "deprecationReason" instead of "isDeprecated".')),null==t.resolve||"function"==typeof t.resolve||O(0,"".concat(e.name,".").concat(n," field resolver must be a function if ")+"provided, but got: ".concat(g(t.resolve),"."));var r=t.args||{};Me(r)||O(0,"".concat(e.name,".").concat(n," args must be an object with argument names as keys."));var i=se(r).map((function(e){var t=e[1];return{name:e[0],description:void 0===t.description?null:t.description,type:t.type,defaultValue:t.defaultValue,extensions:t.extensions&&ue(t.extensions),astNode:t.astNode}}));return he({},t,{name:n,description:t.description,type:t.type,args:i,resolve:t.resolve,subscribe:t.subscribe,isDeprecated:Boolean(t.deprecationReason),deprecationReason:t.deprecationReason,extensions:t.extensions&&ue(t.extensions),astNode:t.astNode})}))}function Me(e){return x(e)&&!Array.isArray(e)}function Ue(e){return ce(e,(function(e){return{description:e.description,type:e.type,args:Ve(e.args),resolve:e.resolve,subscribe:e.subscribe,deprecationReason:e.deprecationReason,extensions:e.extensions,astNode:e.astNode}}))}function Ve(e){return _(e,(function(e){return e.name}),(function(e){return{description:e.description,type:e.type,defaultValue:e.defaultValue,extensions:e.extensions,astNode:e.astNode}}))}function Be(e){return _e(e.type)&&void 0===e.defaultValue}j(Ce),A(Ce);var Ye=function(){function e(e){this.name=e.name,this.description=e.description,this.resolveType=e.resolveType,this.extensions=e.extensions&&ue(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=Le(e.extensionASTNodes),this._fields=Pe.bind(void 0,e),"string"==typeof e.name||O(0,"Must provide name."),null==e.resolveType||"function"==typeof e.resolveType||O(0,"".concat(this.name,' must provide "resolveType" as a function, ')+"but got: ".concat(g(e.resolveType),"."))}var t=e.prototype;return t.getFields=function(){return"function"==typeof this._fields&&(this._fields=this._fields()),this._fields},t.toConfig=function(){return{name:this.name,description:this.description,fields:Ue(this.getFields()),resolveType:this.resolveType,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes||[]}},t.toString=function(){return this.name},e}();j(Ye),A(Ye);var Ge=function(){function e(e){this.name=e.name,this.description=e.description,this.resolveType=e.resolveType,this.extensions=e.extensions&&ue(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=Le(e.extensionASTNodes),this._types=Je.bind(void 0,e),"string"==typeof e.name||O(0,"Must provide name."),null==e.resolveType||"function"==typeof e.resolveType||O(0,"".concat(this.name,' must provide "resolveType" as a function, ')+"but got: ".concat(g(e.resolveType),"."))}var t=e.prototype;return t.getTypes=function(){return"function"==typeof this._types&&(this._types=this._types()),this._types},t.toConfig=function(){return{name:this.name,description:this.description,types:this.getTypes(),resolveType:this.resolveType,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes||[]}},t.toString=function(){return this.name},e}();function Je(e){var t=Fe(e.types)||[];return Array.isArray(t)||O(0,"Must provide Array of types or a function which returns such an array for Union ".concat(e.name,".")),t}j(Ge),A(Ge);var Xe=function(){function e(e){var t,n;this.name=e.name,this.description=e.description,this.extensions=e.extensions&&ue(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=Le(e.extensionASTNodes),this._values=(t=this.name,Me(n=e.values)||O(0,"".concat(t," values must be an object with value names as keys.")),se(n).map((function(e){var n=e[0],r=e[1];return Me(r)||O(0,"".concat(t,".").concat(n,' must refer to an object with a "value" key ')+"representing an internal value but got: ".concat(g(r),".")),!("isDeprecated"in r)||O(0,"".concat(t,".").concat(n,' should provide "deprecationReason" instead of "isDeprecated".')),{name:n,description:r.description,value:"value"in r?r.value:n,isDeprecated:Boolean(r.deprecationReason),deprecationReason:r.deprecationReason,extensions:r.extensions&&ue(r.extensions),astNode:r.astNode}}))),this._valueLookup=new Map(this._values.map((function(e){return[e.value,e]}))),this._nameLookup=E(this._values,(function(e){return e.name})),"string"==typeof e.name||O(0,"Must provide name.")}var t=e.prototype;return t.getValues=function(){return this._values},t.getValue=function(e){return this._nameLookup[e]},t.serialize=function(e){var t=this._valueLookup.get(e);if(t)return t.name},t.parseValue=function(e){if("string"==typeof e){var t=this.getValue(e);if(t)return t.value}},t.parseLiteral=function(e,t){if(e.kind===b.ENUM){var n=this.getValue(e.value);if(n)return n.value}},t.toConfig=function(){var e=_(this.getValues(),(function(e){return e.name}),(function(e){return{description:e.description,value:e.value,deprecationReason:e.deprecationReason,extensions:e.extensions,astNode:e.astNode}}));return{name:this.name,description:this.description,values:e,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes||[]}},t.toString=function(){return this.name},e}();j(Xe),A(Xe);var Ke=function(){function e(e){this.name=e.name,this.description=e.description,this.extensions=e.extensions&&ue(e.extensions),this.astNode=e.astNode,this.extensionASTNodes=Le(e.extensionASTNodes),this._fields=qe.bind(void 0,e),"string"==typeof e.name||O(0,"Must provide name.")}var t=e.prototype;return t.getFields=function(){return"function"==typeof this._fields&&(this._fields=this._fields()),this._fields},t.toConfig=function(){var e=ce(this.getFields(),(function(e){return{description:e.description,type:e.type,defaultValue:e.defaultValue,extensions:e.extensions,astNode:e.astNode}}));return{name:this.name,description:this.description,fields:e,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes||[]}},t.toString=function(){return this.name},e}();function qe(e){var t=Fe(e.fields)||{};return Me(t)||O(0,"".concat(e.name," fields must be an object with field names as keys or a function which returns such an object.")),ce(t,(function(t,n){return!("resolve"in t)||O(0,"".concat(e.name,".").concat(n," field has a resolve property, but Input Types cannot define resolvers.")),he({},t,{name:n,description:t.description,type:t.type,defaultValue:t.defaultValue,extensions:t.extensions&&ue(t.extensions),astNode:t.astNode})}))}function Qe(e,t,n){return t===n||(_e(n)?!!_e(t)&&Qe(e,t.ofType,n.ofType):_e(t)?Qe(e,t.ofType,n):Oe(n)?!!Oe(t)&&Qe(e,t.ofType,n.ofType):!Oe(t)&&!!(Ae(n)&&Ee(t)&&e.isPossibleType(n,t)))}function ze(e,t,n){return t===n||(Ae(t)?Ae(n)?e.getPossibleTypes(t).some((function(t){return e.isPossibleType(n,t)})):e.isPossibleType(t,n):!!Ae(n)&&e.isPossibleType(n,t))}j(Ke),A(Ke);var He=Number.isFinite||function(e){return"number"==typeof e&&isFinite(e)},$e=Number.isInteger||function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e},We=new Re({name:"Int",description:"The `Int` scalar type represents non-fractional signed whole numeric values. Int can represent values between -(2^31) and 2^31 - 1.",serialize:function(e){if("boolean"==typeof e)return e?1:0;var t=e;if("string"==typeof e&&""!==e&&(t=Number(e)),!$e(t))throw new TypeError("Int cannot represent non-integer value: ".concat(g(e)));if(t>2147483647||t<-2147483648)throw new TypeError("Int cannot represent non 32-bit signed integer value: ".concat(g(e)));return t},parseValue:function(e){if(!$e(e))throw new TypeError("Int cannot represent non-integer value: ".concat(g(e)));if(e>2147483647||e<-2147483648)throw new TypeError("Int cannot represent non 32-bit signed integer value: ".concat(g(e)));return e},parseLiteral:function(e){if(e.kind===b.INT){var t=parseInt(e.value,10);if(t<=2147483647&&t>=-2147483648)return t}}}),Ze=new Re({name:"Float",description:"The `Float` scalar type represents signed double-precision fractional values as specified by [IEEE 754](https://en.wikipedia.org/wiki/IEEE_floating_point).",serialize:function(e){if("boolean"==typeof e)return e?1:0;var t=e;if("string"==typeof e&&""!==e&&(t=Number(e)),!He(t))throw new TypeError("Float cannot represent non numeric value: ".concat(g(e)));return t},parseValue:function(e){if(!He(e))throw new TypeError("Float cannot represent non numeric value: ".concat(g(e)));return e},parseLiteral:function(e){return e.kind===b.FLOAT||e.kind===b.INT?parseFloat(e.value):void 0}});function et(e){if(x(e)){if("function"==typeof e.valueOf){var t=e.valueOf();if(!x(t))return t}if("function"==typeof e.toJSON)return e.toJSON()}return e}var tt=new Re({name:"String",description:"The `String` scalar type represents textual data, represented as UTF-8 character sequences. The String type is most often used by GraphQL to represent free-form human-readable text.",serialize:function(e){var t=et(e);if("string"==typeof t)return t;if("boolean"==typeof t)return t?"true":"false";if(He(t))return t.toString();throw new TypeError("String cannot represent value: ".concat(g(e)))},parseValue:function(e){if("string"!=typeof e)throw new TypeError("String cannot represent a non string value: ".concat(g(e)));return e},parseLiteral:function(e){return e.kind===b.STRING?e.value:void 0}}),nt=new Re({name:"Boolean",description:"The `Boolean` scalar type represents `true` or `false`.",serialize:function(e){if("boolean"==typeof e)return e;if(He(e))return 0!==e;throw new TypeError("Boolean cannot represent a non boolean value: ".concat(g(e)))},parseValue:function(e){if("boolean"!=typeof e)throw new TypeError("Boolean cannot represent a non boolean value: ".concat(g(e)));return e},parseLiteral:function(e){return e.kind===b.BOOLEAN?e.value:void 0}}),rt=new Re({name:"ID",description:'The `ID` scalar type represents a unique identifier, often used to refetch an object or as key for a cache. The ID type appears in a JSON response as a String; however, it is not intended to be human-readable. When expected as an input type, any string (such as `"4"`) or integer (such as `4`) input value will be accepted as an ID.',serialize:function(e){var t=et(e);if("string"==typeof t)return t;if($e(t))return String(t);throw new TypeError("ID cannot represent value: ".concat(g(e)))},parseValue:function(e){if("string"==typeof e)return e;if($e(e))return e.toString();throw new TypeError("ID cannot represent value: ".concat(g(e)))},parseLiteral:function(e){return e.kind===b.STRING||e.kind===b.INT?e.value:void 0}}),it=Object.freeze([tt,We,Ze,nt,rt]),at=function(){function e(e){this.name=e.name,this.description=e.description,this.locations=e.locations,this.isRepeatable=null!=e.isRepeatable&&e.isRepeatable,this.extensions=e.extensions&&ue(e.extensions),this.astNode=e.astNode,e.name||O(0,"Directive must be named."),Array.isArray(e.locations)||O(0,"@".concat(e.name," locations must be an Array."));var t=e.args||{};x(t)&&!Array.isArray(t)||O(0,"@".concat(e.name," args must be an object with argument names as keys.")),this.args=se(t).map((function(e){var t=e[1];return{name:e[0],description:void 0===t.description?null:t.description,type:t.type,defaultValue:t.defaultValue,extensions:t.extensions&&ue(t.extensions),astNode:t.astNode}}))}var t=e.prototype;return t.toString=function(){return"@"+this.name},t.toConfig=function(){return{name:this.name,description:this.description,locations:this.locations,args:Ve(this.args),isRepeatable:this.isRepeatable,extensions:this.extensions,astNode:this.astNode}},e}();j(at),A(at);var ot=new at({name:"include",description:"Directs the executor to include this field or fragment only when the `if` argument is true.",locations:[Q.FIELD,Q.FRAGMENT_SPREAD,Q.INLINE_FRAGMENT],args:{if:{type:xe(nt),description:"Included when true."}}}),st=new at({name:"skip",description:"Directs the executor to skip this field or fragment when the `if` argument is true.",locations:[Q.FIELD,Q.FRAGMENT_SPREAD,Q.INLINE_FRAGMENT],args:{if:{type:xe(nt),description:"Skipped when true."}}}),ct=new at({name:"deprecated",description:"Marks an element of a GraphQL schema as no longer supported.",locations:[Q.FIELD_DEFINITION,Q.ENUM_VALUE],args:{reason:{type:tt,description:"Explains why this element was deprecated, usually also including a suggestion for how to access supported similar data. Formatted using the Markdown syntax (as specified by [CommonMark](https://commonmark.org/).",defaultValue:"No longer supported"}}}),ut=Object.freeze([ot,st,ct]);function lt(e){return ne(e,{leave:pt})}var pt={Name:function(e){return e.value},Variable:function(e){return"$"+e.name},Document:function(e){return dt(e.definitions,"\n\n")+"\n"},OperationDefinition:function(e){var t=e.operation,n=e.name,r=vt("(",dt(e.variableDefinitions,", "),")"),i=dt(e.directives," "),a=e.selectionSet;return n||i||r||"query"!==t?dt([t,dt([n,r]),i,a]," "):a},VariableDefinition:function(e){var t=e.directives;return e.variable+": "+e.type+vt(" = ",e.defaultValue)+vt(" ",dt(t," "))},SelectionSet:function(e){return ht(e.selections)},Field:function(e){var t=e.name,n=e.arguments,r=e.directives,i=e.selectionSet;return dt([vt("",e.alias,": ")+t+vt("(",dt(n,", "),")"),dt(r," "),i]," ")},Argument:function(e){return e.name+": "+e.value},FragmentSpread:function(e){return"..."+e.name+vt(" ",dt(e.directives," "))},InlineFragment:function(e){var t=e.directives,n=e.selectionSet;return dt(["...",vt("on ",e.typeCondition),dt(t," "),n]," ")},FragmentDefinition:function(e){var t=e.typeCondition,n=e.variableDefinitions,r=e.directives,i=e.selectionSet;return"fragment ".concat(e.name).concat(vt("(",dt(n,", "),")")," ")+"on ".concat(t," ").concat(vt("",dt(r," ")," "))+i},IntValue:function(e){return e.value},FloatValue:function(e){return e.value},StringValue:function(e,t){var n=e.value;return e.block?function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=-1===e.indexOf("\n"),i=" "===e[0]||"\t"===e[0],a='"'===e[e.length-1],o=!r||a||n,s="";return!o||r&&i||(s+="\n"+t),s+=t?e.replace(/\n/g,"\n"+t):e,o&&(s+="\n"),'"""'+s.replace(/"""/g,'\\"""')+'"""'}(n,"description"===t?"":"  "):JSON.stringify(n)},BooleanValue:function(e){return e.value?"true":"false"},NullValue:function(){return"null"},EnumValue:function(e){return e.value},ListValue:function(e){return"["+dt(e.values,", ")+"]"},ObjectValue:function(e){return"{"+dt(e.fields,", ")+"}"},ObjectField:function(e){return e.name+": "+e.value},Directive:function(e){return"@"+e.name+vt("(",dt(e.arguments,", "),")")},NamedType:function(e){return e.name},ListType:function(e){return"["+e.type+"]"},NonNullType:function(e){return e.type+"!"},SchemaDefinition:function(e){var t=e.operationTypes;return dt(["schema",dt(e.directives," "),ht(t)]," ")},OperationTypeDefinition:function(e){return e.operation+": "+e.type},ScalarTypeDefinition:ft((function(e){return dt(["scalar",e.name,dt(e.directives," ")]," ")})),ObjectTypeDefinition:ft((function(e){var t=e.directives,n=e.fields;return dt(["type",e.name,vt("implements ",dt(e.interfaces," & ")),dt(t," "),ht(n)]," ")})),FieldDefinition:ft((function(e){var t=e.arguments,n=e.type,r=e.directives;return e.name+(Et(t)?vt("(\n",mt(dt(t,"\n")),"\n)"):vt("(",dt(t,", "),")"))+": "+n+vt(" ",dt(r," "))})),InputValueDefinition:ft((function(e){var t=e.directives;return dt([e.name+": "+e.type,vt("= ",e.defaultValue),dt(t," ")]," ")})),InterfaceTypeDefinition:ft((function(e){var t=e.fields;return dt(["interface",e.name,dt(e.directives," "),ht(t)]," ")})),UnionTypeDefinition:ft((function(e){var t=e.types;return dt(["union",e.name,dt(e.directives," "),t&&0!==t.length?"= "+dt(t," | "):""]," ")})),EnumTypeDefinition:ft((function(e){var t=e.values;return dt(["enum",e.name,dt(e.directives," "),ht(t)]," ")})),EnumValueDefinition:ft((function(e){return dt([e.name,dt(e.directives," ")]," ")})),InputObjectTypeDefinition:ft((function(e){var t=e.fields;return dt(["input",e.name,dt(e.directives," "),ht(t)]," ")})),DirectiveDefinition:ft((function(e){var t=e.arguments,n=e.repeatable,r=e.locations;return"directive @"+e.name+(Et(t)?vt("(\n",mt(dt(t,"\n")),"\n)"):vt("(",dt(t,", "),")"))+(n?" repeatable":"")+" on "+dt(r," | ")})),SchemaExtension:function(e){var t=e.operationTypes;return dt(["extend schema",dt(e.directives," "),ht(t)]," ")},ScalarTypeExtension:function(e){return dt(["extend scalar",e.name,dt(e.directives," ")]," ")},ObjectTypeExtension:function(e){var t=e.directives,n=e.fields;return dt(["extend type",e.name,vt("implements ",dt(e.interfaces," & ")),dt(t," "),ht(n)]," ")},InterfaceTypeExtension:function(e){var t=e.fields;return dt(["extend interface",e.name,dt(e.directives," "),ht(t)]," ")},UnionTypeExtension:function(e){var t=e.types;return dt(["extend union",e.name,dt(e.directives," "),t&&0!==t.length?"= "+dt(t," | "):""]," ")},EnumTypeExtension:function(e){var t=e.values;return dt(["extend enum",e.name,dt(e.directives," "),ht(t)]," ")},InputObjectTypeExtension:function(e){var t=e.fields;return dt(["extend input",e.name,dt(e.directives," "),ht(t)]," ")}};function ft(e){return function(t){return dt([t.description,e(t)],"\n")}}function dt(e,t){return e?e.filter((function(e){return e})).join(t||""):""}function ht(e){return e&&0!==e.length?"{\n"+mt(dt(e,"\n"))+"\n}":""}function vt(e,t,n){return t?e+t+(n||""):""}function mt(e){return e&&"  "+e.replace(/\n/g,"\n  ")}function yt(e){return-1!==e.indexOf("\n")}function Et(e){return e&&e.some(yt)}var Tt="function"==typeof Symbol?Symbol:void 0,Nt=Tt&&Tt.iterator;function gt(e){var t=null!=e&&e.length;return"number"==typeof t&&t>=0&&t%1==0}function It(e){if(null!=e){var t=Nt&&e[Nt]||e["@@iterator"];if("function"==typeof t)return t}}function Ot(e){this._o=e,this._i=0}function _t(e){this._i=e}function bt(e,t,n){var r;return new Promise((function(i){i((r=e[t](n)).value)})).then((function(e){return{value:e,done:r.done}}))}Ot.prototype[Nt||"@@iterator"]=function(){return this},Ot.prototype.next=function(){return void 0===this._o||this._i>=this._o.length?(this._o=void 0,{value:void 0,done:!0}):{value:this._o[this._i++],done:!1}},_t.prototype[Tt&&Tt.asyncIterator||"@@asyncIterator"]=function(){return this},_t.prototype.next=function(e){return bt(this._i,"next",e)},_t.prototype.return=function(e){return this._i.return?bt(this._i,"return",e):Promise.resolve({value:e,done:!0})},_t.prototype.throw=function(e){return this._i.throw?bt(this._i,"throw",e):Promise.reject(e)};var Dt=/^-?(?:0|[1-9][0-9]*)$/,At=new Ce({name:"__Schema",description:"A GraphQL Schema defines the capabilities of a GraphQL server. It exposes all available types and directives on the server, as well as the entry points for query, mutation, and subscription operations.",fields:function(){return{types:{description:"A list of all types supported by this server.",type:xe(Se(xe(wt))),resolve:function(e){return y(e.getTypeMap())}},queryType:{description:"The type that query operations will be rooted at.",type:xe(wt),resolve:function(e){return e.getQueryType()}},mutationType:{description:"If this server supports mutation, the type that mutation operations will be rooted at.",type:wt,resolve:function(e){return e.getMutationType()}},subscriptionType:{description:"If this server support subscription, the type that subscription operations will be rooted at.",type:wt,resolve:function(e){return e.getSubscriptionType()}},directives:{description:"A list of all directives supported by this server.",type:xe(Se(xe(St))),resolve:function(e){return e.getDirectives()}}}}}),St=new Ce({name:"__Directive",description:"A Directive provides a way to describe alternate runtime execution and type validation behavior in a GraphQL document.\n\nIn some cases, you need to provide options to alter GraphQL's execution behavior in ways field arguments will not suffice, such as conditionally including or skipping a field. Directives provide this by describing additional information to the executor.",fields:function(){return{name:{type:xe(tt),resolve:function(e){return e.name}},description:{type:tt,resolve:function(e){return e.description}},locations:{type:xe(Se(xe(xt))),resolve:function(e){return e.locations}},args:{type:xe(Se(xe(Ft))),resolve:function(e){return e.args}}}}}),xt=new Xe({name:"__DirectiveLocation",description:"A Directive can be adjacent to many parts of the GraphQL language, a __DirectiveLocation describes one such possible adjacencies.",values:{QUERY:{value:Q.QUERY,description:"Location adjacent to a query operation."},MUTATION:{value:Q.MUTATION,description:"Location adjacent to a mutation operation."},SUBSCRIPTION:{value:Q.SUBSCRIPTION,description:"Location adjacent to a subscription operation."},FIELD:{value:Q.FIELD,description:"Location adjacent to a field."},FRAGMENT_DEFINITION:{value:Q.FRAGMENT_DEFINITION,description:"Location adjacent to a fragment definition."},FRAGMENT_SPREAD:{value:Q.FRAGMENT_SPREAD,description:"Location adjacent to a fragment spread."},INLINE_FRAGMENT:{value:Q.INLINE_FRAGMENT,description:"Location adjacent to an inline fragment."},VARIABLE_DEFINITION:{value:Q.VARIABLE_DEFINITION,description:"Location adjacent to a variable definition."},SCHEMA:{value:Q.SCHEMA,description:"Location adjacent to a schema definition."},SCALAR:{value:Q.SCALAR,description:"Location adjacent to a scalar definition."},OBJECT:{value:Q.OBJECT,description:"Location adjacent to an object type definition."},FIELD_DEFINITION:{value:Q.FIELD_DEFINITION,description:"Location adjacent to a field definition."},ARGUMENT_DEFINITION:{value:Q.ARGUMENT_DEFINITION,description:"Location adjacent to an argument definition."},INTERFACE:{value:Q.INTERFACE,description:"Location adjacent to an interface definition."},UNION:{value:Q.UNION,description:"Location adjacent to a union definition."},ENUM:{value:Q.ENUM,description:"Location adjacent to an enum definition."},ENUM_VALUE:{value:Q.ENUM_VALUE,description:"Location adjacent to an enum value definition."},INPUT_OBJECT:{value:Q.INPUT_OBJECT,description:"Location adjacent to an input object type definition."},INPUT_FIELD_DEFINITION:{value:Q.INPUT_FIELD_DEFINITION,description:"Location adjacent to an input object field definition."}}}),wt=new Ce({name:"__Type",description:"The fundamental unit of any GraphQL Schema is the type. There are many kinds of types in GraphQL as represented by the `__TypeKind` enum.\n\nDepending on the kind of a type, certain fields describe information about that type. Scalar types provide no information beyond a name and description, while Enum types provide their values. Object and Interface types provide the fields they describe. Abstract types, Union and Interface, provide the Object types possible at runtime. List and NonNull types compose other types.",fields:function(){return{kind:{type:xe(Ct),resolve:function(e){return ye(e)?Rt.SCALAR:Ee(e)?Rt.OBJECT:Te(e)?Rt.INTERFACE:Ne(e)?Rt.UNION:ge(e)?Rt.ENUM:Ie(e)?Rt.INPUT_OBJECT:Oe(e)?Rt.LIST:_e(e)?Rt.NON_NULL:void I(!1,'Unexpected type: "'.concat(g(e),'".'))}},name:{type:tt,resolve:function(e){return void 0!==e.name?e.name:void 0}},description:{type:tt,resolve:function(e){return void 0!==e.description?e.description:void 0}},fields:{type:Se(xe(kt)),args:{includeDeprecated:{type:nt,defaultValue:!1}},resolve:function(e,t){var n=t.includeDeprecated;if(Ee(e)||Te(e)){var r=y(e.getFields());return n||(r=r.filter((function(e){return!e.deprecationReason}))),r}return null}},interfaces:{type:Se(xe(wt)),resolve:function(e){if(Ee(e))return e.getInterfaces()}},possibleTypes:{type:Se(xe(wt)),resolve:function(e,t,n,r){var i=r.schema;if(Ae(e))return i.getPossibleTypes(e)}},enumValues:{type:Se(xe(Lt)),args:{includeDeprecated:{type:nt,defaultValue:!1}},resolve:function(e,t){var n=t.includeDeprecated;if(ge(e)){var r=e.getValues();return n||(r=r.filter((function(e){return!e.deprecationReason}))),r}}},inputFields:{type:Se(xe(Ft)),resolve:function(e){if(Ie(e))return y(e.getFields())}},ofType:{type:wt,resolve:function(e){return void 0!==e.ofType?e.ofType:void 0}}}}}),kt=new Ce({name:"__Field",description:"Object and Interface types are described by a list of Fields, each of which has a name, potentially a list of arguments, and a return type.",fields:function(){return{name:{type:xe(tt),resolve:function(e){return e.name}},description:{type:tt,resolve:function(e){return e.description}},args:{type:xe(Se(xe(Ft))),resolve:function(e){return e.args}},type:{type:xe(wt),resolve:function(e){return e.type}},isDeprecated:{type:xe(nt),resolve:function(e){return e.isDeprecated}},deprecationReason:{type:tt,resolve:function(e){return e.deprecationReason}}}}}),Ft=new Ce({name:"__InputValue",description:"Arguments provided to Fields or Directives and the input fields of an InputObject are represented as Input Values which describe their type and optionally a default value.",fields:function(){return{name:{type:xe(tt),resolve:function(e){return e.name}},description:{type:tt,resolve:function(e){return e.description}},type:{type:xe(wt),resolve:function(e){return e.type}},defaultValue:{type:tt,description:"A GraphQL-formatted string representing the default value for this input value.",resolve:function(e){var t=function e(t,n){if(_e(n)){var r=e(t,n.ofType);return r&&r.kind===b.NULL?null:r}if(null===t)return{kind:b.NULL};if(fe(t))return null;if(Oe(n)){var i=n.ofType;if(o=t,Object(o)===o&&(gt(o)||function(e){return!!It(e)}(o))){var a=[];return function(e,t,n){if(null!=e){if("function"==typeof e.forEach)return e.forEach(t,n);var r=0,i=function(e){var t=It(e);if(t)return t.call(e)}(e);if(i){for(var a;!(a=i.next()).done;)if(t.call(n,a.value,r++,e),r>9999999)throw new TypeError("Near-infinite iteration.")}else if(gt(e))for(;r1&&l>1&&r[u-1]===i[l-2]&&r[u-2]===i[l-1]&&(n[u][l]=Math.min(n[u][l],n[u-2][l-2]+p))}return n[a][o]}function Jt(e){for(var t=e.getSchema(),n=t?t.getTypeMap():Object.create(null),r=Object.create(null),i=0,a=e.getDocument().definitions;i0)return[[t,e.map((function(e){return e[0]}))],e.reduce((function(e,t){return e.concat(t[1])}),[n]),e.reduce((function(e,t){return e.concat(t[2])}),[r])]}(function(e,t,n,r,i,a,o,s){var c=[],u=Tn(e,t,i,a),l=u[0],p=u[1],f=Tn(e,t,o,s),d=f[0],h=f[1];if(yn(e,c,t,n,r,l,d),0!==h.length)for(var v=Object.create(null),m=0;m1&&e.reportError(new R("This anonymous operation must be the only defined operation.",n))}}},function(e){return{OperationDefinition:function(t){var n;"subscription"===t.operation&&1!==t.selectionSet.selections.length&&e.reportError(new R((n=t.name&&t.name.value)?'Subscription "'.concat(n,'" must select only one top level field.'):"Anonymous Subscription must select only one top level field.",t.selectionSet.selections.slice(1)))}}},Jt,function(e){return{InlineFragment:function(t){var n=t.typeCondition;if(n){var r=Vt(e.getSchema(),n);r&&!De(r)&&e.reportError(new R(function(e){return'Fragment cannot condition on non composite type "'.concat(e,'".')}(lt(n)),n))}},FragmentDefinition:function(t){var n=Vt(e.getSchema(),t.typeCondition);n&&!De(n)&&e.reportError(new R(function(e,t){return'Fragment "'.concat(e,'" cannot condition on non composite type "').concat(t,'".')}(t.name.value,lt(t.typeCondition)),t.typeCondition))}}},function(e){return{VariableDefinition:function(t){var n,r,i=Vt(e.getSchema(),t.type);i&&!function e(t){return ye(t)||ge(t)||Ie(t)||we(t)&&e(t.ofType)}(i)&&e.reportError(new R((n=t.variable.name.value,r=lt(t.type),'Variable "$'.concat(n,'" cannot be non-input type "').concat(r,'".')),t.type))}}},function(e){return{Field:function(t){var n=e.getType(),r=t.selectionSet;n&&(be(ke(n))?r&&e.reportError(new R(function(e,t){return'Field "'.concat(e,'" must not have a selection since type "').concat(t,'" has no subfields.')}(t.name.value,g(n)),r)):r||e.reportError(new R(function(e,t){return'Field "'.concat(e,'" of type "').concat(t,'" must have a selection of subfields. Did you mean "').concat(e,' { ... }"?')}(t.name.value,g(n)),t)))}}},function(e){return{Field:function(t){var n=e.getParentType();if(n&&!e.getFieldDef()){var r=e.getSchema(),i=t.name.value,a=function(e,t,n){if(Ae(t)){for(var r=[],i=Object.create(null),a=0,o=e.getPossibleTypes(t);a1)for(var l=0;l0&&e.reportError(new R("Must provide only one schema definition.",t)),++r)}}},function(e){var t=e.getSchema(),n=Object.create(null),r=t?{query:t.getQueryType(),mutation:t.getMutationType(),subscription:t.getSubscriptionType()}:{};return{SchemaDefinition:i,SchemaExtension:i};function i(t){if(t.operationTypes)for(var i=0,a=t.operationTypes||[];i0?function(){return n.map((function(e){return t.getNamedType(e)}))}:[],a=r&&r.length>0?function(){return Yn(r,(function(e){return t.buildField(e)}))}:Object.create(null);return new Ce({name:e.name.value,description:Jn(e,this._options),interfaces:i,fields:a,astNode:e})},t._makeInterfaceDef=function(e){var t=this,n=e.fields,r=n&&n.length>0?function(){return Yn(n,(function(e){return t.buildField(e)}))}:Object.create(null);return new Ye({name:e.name.value,description:Jn(e,this._options),fields:r,astNode:e})},t._makeEnumDef=function(e){var t=this,n=e.values||[];return new Xe({name:e.name.value,description:Jn(e,this._options),values:Yn(n,(function(e){return t.buildEnumValue(e)})),astNode:e})},t._makeUnionDef=function(e){var t=this,n=e.types,r=n&&n.length>0?function(){return n.map((function(e){return t.getNamedType(e)}))}:[];return new Ge({name:e.name.value,description:Jn(e,this._options),types:r,astNode:e})},t._makeScalarDef=function(e){return new Re({name:e.name.value,description:Jn(e,this._options),astNode:e})},t._makeInputObjectDef=function(e){var t=this,n=e.fields;return new Ke({name:e.name.value,description:Jn(e,this._options),fields:n?function(){return Yn(n,(function(e){return t.buildInputField(e)}))}:Object.create(null),astNode:e})},e}();function Yn(e,t){return _(e,(function(e){return e.name.value}),t)}function Gn(e){var t=function(e,t,n){var r=t.directives&&oe(t.directives,(function(t){return t.name.value===e.name}));if(r)return function(e,t,n){for(var r={},i=E(t.arguments||[],(function(e){return e.name.value})),a=0,o=e.args;a2&&void 0!==arguments[2]?arguments[2]:jn,r=[],i=new Pn(e,t,(function(e){r.push(e)})),a=n.map((function(e){return e(i)}));return ne(e,ie(a)),r}(e);if(0!==t.length)throw new Error(t.map((function(e){return e.message})).join("\n\n"))}(e);for(var r=[],i=[],a=0,o=e.definitions;a=(i.addQueryDepthLimit||0))return{query:"",meta:{}};var d=f&&f.getFields&&f.getFields(),h="";return d&&(h=Object.keys(d).reduce((function(t,o){if(n.filter((function(e){return e.name===o&&e.type===p})).length)return"";var s=a.generateFieldData(o,p,Kn(n,[{name:e,type:p}]),r+1,i);if(!s)return t;var c=s.query;return u.hasArgs=u.hasArgs||s.meta.hasArgs||!1,c?t+"\n"+c:t}),"").substring(1)),h&&(l+="{\n"+h+"\n",l+=" ".repeat(r*o)+"}"),{query:l,meta:u}},e}())}});




© 2015 - 2024 Weber Informatics LLC | Privacy Policy