"use strict";var X=Object.getOwnPropertyNames,re=(l,T)=>function(){return l&&(T=(0,l[X(l)[0]])(l=0)),T},K=(l,T)=>function(){return T||(0,l[X(l)[0]])((T={exports:{}}).exports,T),T.exports},L=re({""(){}}),ie=K({"src/common/parser-create-error.js"(l,T){"use strict";L();function a(p,r){let _=new SyntaxError(p+" ("+r.start.line+":"+r.start.column+")");return _.loc=r,_}T.exports=a}}),ae=K({"src/utils/try-combinations.js"(l,T){"use strict";L();function a(){let p;for(var r=arguments.length,_=new Array(r),E=0;E120){for(var t=Math.floor(i/80),s=i%80,y=[],f=0;f"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch{return!1}}function e(f){return Function.toString.call(f).indexOf("[native code]")!==-1}function n(f,m){return n=Object.setPrototypeOf||function(d,c){return d.__proto__=c,d},n(f,m)}function t(f){return t=Object.setPrototypeOf?Object.getPrototypeOf:function(o){return o.__proto__||Object.getPrototypeOf(o)},t(f)}var s=function(f){O(o,f);var m=S(o);function o(d,c,v,A,x,b,P){var U,q,V,G,C;k(this,o),C=m.call(this,d);var R=Array.isArray(c)?c.length!==0?c:void 0:c?[c]:void 0,Y=v;if(!Y&&R){var J;Y=(J=R[0].loc)===null||J===void 0?void 0:J.source}var F=A;!F&&R&&(F=R.reduce(function(w,M){return M.loc&&w.push(M.loc.start),w},[])),F&&F.length===0&&(F=void 0);var B;A&&v?B=A.map(function(w){return(0,r.getLocation)(v,w)}):R&&(B=R.reduce(function(w,M){return M.loc&&w.push((0,r.getLocation)(M.loc.source,M.loc.start)),w},[]));var j=P;if(j==null&&b!=null){var Q=b.extensions;(0,a.default)(Q)&&(j=Q)}return Object.defineProperties(h(C),{name:{value:"GraphQLError"},message:{value:d,enumerable:!0,writable:!0},locations:{value:(U=B)!==null&&U!==void 0?U:void 0,enumerable:B!=null},path:{value:x!=null?x:void 0,enumerable:x!=null},nodes:{value:R!=null?R:void 0},source:{value:(q=Y)!==null&&q!==void 0?q:void 0},positions:{value:(V=F)!==null&&V!==void 0?V:void 0},originalError:{value:b},extensions:{value:(G=j)!==null&&G!==void 0?G:void 0,enumerable:j!=null}}),b!=null&&b.stack?(Object.defineProperty(h(C),"stack",{value:b.stack,writable:!0,configurable:!0}),I(C)):(Error.captureStackTrace?Error.captureStackTrace(h(C),o):Object.defineProperty(h(C),"stack",{value:Error().stack,writable:!0,configurable:!0}),C)}return D(o,[{key:"toString",value:function(){return y(this)}},{key:p.SYMBOL_TO_STRING_TAG,get:function(){return"Object"}}]),o}(N(Error));l.GraphQLError=s;function y(f){var m=f.message;if(f.nodes)for(var o=0,d=f.nodes;o",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"});l.TokenKind=T}}),ne=K({"node_modules/graphql/jsutils/inspect.js"(l){"use strict";L(),Object.defineProperty(l,"__esModule",{value:!0}),l.default=E;var T=a(Z());function a(h){return h&&h.__esModule?h:{default:h}}function p(h){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?p=function(i){return typeof i}:p=function(i){return i&&typeof Symbol=="function"&&i.constructor===Symbol&&i!==Symbol.prototype?"symbol":typeof i},p(h)}var r=10,_=2;function E(h){return k(h,[])}function k(h,N){switch(p(h)){case"string":return JSON.stringify(h);case"function":return h.name?"[function ".concat(h.name,"]"):"[function]";case"object":return h===null?"null":g(h,N);default:return String(h)}}function g(h,N){if(N.indexOf(h)!==-1)return"[Circular]";var i=[].concat(N,[h]),u=S(h);if(u!==void 0){var e=u.call(h);if(e!==h)return typeof e=="string"?e:k(e,i)}else if(Array.isArray(h))return O(h,i);return D(h,i)}function D(h,N){var i=Object.keys(h);if(i.length===0)return"{}";if(N.length>_)return"["+I(h)+"]";var u=i.map(function(e){var n=k(h[e],N);return e+": "+n});return"{ "+u.join(", ")+" }"}function O(h,N){if(h.length===0)return"[]";if(N.length>_)return"[Array]";for(var i=Math.min(r,h.length),u=h.length-i,e=[],n=0;n1&&e.push("... ".concat(u," more items")),"["+e.join(", ")+"]"}function S(h){var N=h[String(T.default)];if(typeof N=="function")return N;if(typeof h.inspect=="function")return h.inspect}function I(h){var N=Object.prototype.toString.call(h).replace(/^\[object /,"").replace(/]$/,"");if(N==="Object"&&typeof h.constructor=="function"){var i=h.constructor.name;if(typeof i=="string"&&i!=="")return i}return N}}}),de=K({"node_modules/graphql/jsutils/devAssert.js"(l){"use strict";L(),Object.defineProperty(l,"__esModule",{value:!0}),l.default=T;function T(a,p){var r=Boolean(a);if(!r)throw new Error(p)}}}),he=K({"node_modules/graphql/jsutils/instanceOf.js"(l){"use strict";L(),Object.defineProperty(l,"__esModule",{value:!0}),l.default=void 0;var T=a(ne());function a(r){return r&&r.__esModule?r:{default:r}}var p=function(_,E){return _ instanceof E};l.default=p}}),ve=K({"node_modules/graphql/language/source.js"(l){"use strict";L(),Object.defineProperty(l,"__esModule",{value:!0}),l.isSource=D,l.Source=void 0;var T=H(),a=_(ne()),p=_(de()),r=_(he());function _(O){return O&&O.__esModule?O:{default:O}}function E(O,S){for(var I=0;I1&&arguments[1]!==void 0?arguments[1]:"GraphQL request",h=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{line:1,column:1};typeof S=="string"||(0,p.default)(0,"Body must be a string. Received: ".concat((0,a.default)(S),".")),this.body=S,this.name=I,this.locationOffset=h,this.locationOffset.line>0||(0,p.default)(0,"line in locationOffset is 1-indexed and must be positive."),this.locationOffset.column>0||(0,p.default)(0,"column in locationOffset is 1-indexed and must be positive.")}return k(O,[{key:T.SYMBOL_TO_STRING_TAG,get:function(){return"Source"}}]),O}();l.Source=g;function D(O){return(0,r.default)(O,g)}}}),Te=K({"node_modules/graphql/language/directiveLocation.js"(l){"use strict";L(),Object.defineProperty(l,"__esModule",{value:!0}),l.DirectiveLocation=void 0;var T=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"});l.DirectiveLocation=T}}),_e=K({"node_modules/graphql/language/blockString.js"(l){"use strict";L(),Object.defineProperty(l,"__esModule",{value:!0}),l.dedentBlockStringValue=T,l.getBlockStringIndentation=p,l.printBlockString=r;function T(_){var E=_.split(/\r\n|[\n\r]/g),k=p(_);if(k!==0)for(var g=1;gD&&a(E[O-1]);)--O;return E.slice(D,O).join(` `)}function a(_){for(var E=0;E<_.length;++E)if(_[E]!==" "&&_[E]!==" ")return!1;return!0}function p(_){for(var E,k=!0,g=!0,D=0,O=null,S=0;S<_.length;++S)switch(_.charCodeAt(S)){case 13:_.charCodeAt(S+1)===10&&++S;case 10:k=!1,g=!0,D=0;break;case 9:case 32:++D;break;default:g&&!k&&(O===null||D1&&arguments[1]!==void 0?arguments[1]:"",k=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,g=_.indexOf(` `)===-1,D=_[0]===" "||_[0]===" ",O=_[_.length-1]==='"',S=_[_.length-1]==="\\",I=!g||O||S||k,h="";return I&&!(g&&D)&&(h+=` `+E),h+=E?_.replace(/\n/g,` `+E):_,I&&(h+=` `),'"""'+h.replace(/"""/g,'\\"""')+'"""'}}}),Ee=K({"node_modules/graphql/language/lexer.js"(l){"use strict";L(),Object.defineProperty(l,"__esModule",{value:!0}),l.isPunctuatorTokenKind=E,l.Lexer=void 0;var T=W(),a=ee(),p=te(),r=_e(),_=function(){function t(y){var f=new a.Token(p.TokenKind.SOF,0,0,0,0,null);this.source=y,this.lastToken=f,this.token=f,this.line=1,this.lineStart=0}var s=t.prototype;return s.advance=function(){this.lastToken=this.token;var f=this.token=this.lookahead();return f},s.lookahead=function(){var f=this.token;if(f.kind!==p.TokenKind.EOF)do{var m;f=(m=f.next)!==null&&m!==void 0?m:f.next=g(this,f)}while(f.kind===p.TokenKind.COMMENT);return f},t}();l.Lexer=_;function E(t){return t===p.TokenKind.BANG||t===p.TokenKind.DOLLAR||t===p.TokenKind.AMP||t===p.TokenKind.PAREN_L||t===p.TokenKind.PAREN_R||t===p.TokenKind.SPREAD||t===p.TokenKind.COLON||t===p.TokenKind.EQUALS||t===p.TokenKind.AT||t===p.TokenKind.BRACKET_L||t===p.TokenKind.BRACKET_R||t===p.TokenKind.BRACE_L||t===p.TokenKind.PIPE||t===p.TokenKind.BRACE_R}function k(t){return isNaN(t)?p.TokenKind.EOF:t<127?JSON.stringify(String.fromCharCode(t)):'"\\u'.concat(("00"+t.toString(16).toUpperCase()).slice(-4),'"')}function g(t,s){for(var y=t.source,f=y.body,m=f.length,o=s.end;o31||d===9));return new a.Token(p.TokenKind.COMMENT,s,c,y,f,m,o.slice(s+1,c))}function S(t,s,y,f,m,o){var d=t.body,c=y,v=s,A=!1;if(c===45&&(c=d.charCodeAt(++v)),c===48){if(c=d.charCodeAt(++v),c>=48&&c<=57)throw(0,T.syntaxError)(t,v,"Invalid number, unexpected digit after 0: ".concat(k(c),"."))}else v=I(t,v,c),c=d.charCodeAt(v);if(c===46&&(A=!0,c=d.charCodeAt(++v),v=I(t,v,c),c=d.charCodeAt(v)),(c===69||c===101)&&(A=!0,c=d.charCodeAt(++v),(c===43||c===45)&&(c=d.charCodeAt(++v)),v=I(t,v,c),c=d.charCodeAt(v)),c===46||n(c))throw(0,T.syntaxError)(t,v,"Invalid number, expected digit but got: ".concat(k(c),"."));return new a.Token(A?p.TokenKind.FLOAT:p.TokenKind.INT,s,v,f,m,o,d.slice(s,v))}function I(t,s,y){var f=t.body,m=s,o=y;if(o>=48&&o<=57){do o=f.charCodeAt(++m);while(o>=48&&o<=57);return m}throw(0,T.syntaxError)(t,m,"Invalid number, expected digit but got: ".concat(k(o),"."))}function h(t,s,y,f,m){for(var o=t.body,d=s+1,c=d,v=0,A="";d=48&&t<=57?t-48:t>=65&&t<=70?t-55:t>=97&&t<=102?t-87:-1}function e(t,s,y,f,m){for(var o=t.body,d=o.length,c=s+1,v=0;c!==d&&!isNaN(v=o.charCodeAt(c))&&(v===95||v>=48&&v<=57||v>=65&&v<=90||v>=97&&v<=122);)++c;return new a.Token(p.TokenKind.NAME,s,c,y,f,m,o.slice(s,c))}function n(t){return t===95||t>=65&&t<=90||t>=97&&t<=122}}}),me=K({"node_modules/graphql/language/parser.js"(l){"use strict";L(),Object.defineProperty(l,"__esModule",{value:!0}),l.parse=g,l.parseValue=D,l.parseType=O,l.Parser=void 0;var T=W(),a=le(),p=ee(),r=te(),_=ve(),E=Te(),k=Ee();function g(N,i){var u=new S(N,i);return u.parseDocument()}function D(N,i){var u=new S(N,i);u.expectToken(r.TokenKind.SOF);var e=u.parseValueLiteral(!1);return u.expectToken(r.TokenKind.EOF),e}function O(N,i){var u=new S(N,i);u.expectToken(r.TokenKind.SOF);var e=u.parseTypeReference();return u.expectToken(r.TokenKind.EOF),e}var S=function(){function N(u,e){var n=(0,_.isSource)(u)?u:new _.Source(u);this._lexer=new k.Lexer(n),this._options=e}var i=N.prototype;return i.parseName=function(){var e=this.expectToken(r.TokenKind.NAME);return{kind:a.Kind.NAME,value:e.value,loc:this.loc(e)}},i.parseDocument=function(){var e=this._lexer.token;return{kind:a.Kind.DOCUMENT,definitions:this.many(r.TokenKind.SOF,this.parseDefinition,r.TokenKind.EOF),loc:this.loc(e)}},i.parseDefinition=function(){if(this.peek(r.TokenKind.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(r.TokenKind.BRACE_L))return this.parseOperationDefinition();if(this.peekDescription())return this.parseTypeSystemDefinition()}throw this.unexpected()},i.parseOperationDefinition=function(){var e=this._lexer.token;if(this.peek(r.TokenKind.BRACE_L))return{kind:a.Kind.OPERATION_DEFINITION,operation:"query",name:void 0,variableDefinitions:[],directives:[],selectionSet:this.parseSelectionSet(),loc:this.loc(e)};var n=this.parseOperationType(),t;return this.peek(r.TokenKind.NAME)&&(t=this.parseName()),{kind:a.Kind.OPERATION_DEFINITION,operation:n,name:t,variableDefinitions:this.parseVariableDefinitions(),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(e)}},i.parseOperationType=function(){var e=this.expectToken(r.TokenKind.NAME);switch(e.value){case"query":return"query";case"mutation":return"mutation";case"subscription":return"subscription"}throw this.unexpected(e)},i.parseVariableDefinitions=function(){return this.optionalMany(r.TokenKind.PAREN_L,this.parseVariableDefinition,r.TokenKind.PAREN_R)},i.parseVariableDefinition=function(){var e=this._lexer.token;return{kind:a.Kind.VARIABLE_DEFINITION,variable:this.parseVariable(),type:(this.expectToken(r.TokenKind.COLON),this.parseTypeReference()),defaultValue:this.expectOptionalToken(r.TokenKind.EQUALS)?this.parseValueLiteral(!0):void 0,directives:this.parseDirectives(!0),loc:this.loc(e)}},i.parseVariable=function(){var e=this._lexer.token;return this.expectToken(r.TokenKind.DOLLAR),{kind:a.Kind.VARIABLE,name:this.parseName(),loc:this.loc(e)}},i.parseSelectionSet=function(){var e=this._lexer.token;return{kind:a.Kind.SELECTION_SET,selections:this.many(r.TokenKind.BRACE_L,this.parseSelection,r.TokenKind.BRACE_R),loc:this.loc(e)}},i.parseSelection=function(){return this.peek(r.TokenKind.SPREAD)?this.parseFragment():this.parseField()},i.parseField=function(){var e=this._lexer.token,n=this.parseName(),t,s;return this.expectOptionalToken(r.TokenKind.COLON)?(t=n,s=this.parseName()):s=n,{kind:a.Kind.FIELD,alias:t,name:s,arguments:this.parseArguments(!1),directives:this.parseDirectives(!1),selectionSet:this.peek(r.TokenKind.BRACE_L)?this.parseSelectionSet():void 0,loc:this.loc(e)}},i.parseArguments=function(e){var n=e?this.parseConstArgument:this.parseArgument;return this.optionalMany(r.TokenKind.PAREN_L,n,r.TokenKind.PAREN_R)},i.parseArgument=function(){var e=this._lexer.token,n=this.parseName();return this.expectToken(r.TokenKind.COLON),{kind:a.Kind.ARGUMENT,name:n,value:this.parseValueLiteral(!1),loc:this.loc(e)}},i.parseConstArgument=function(){var e=this._lexer.token;return{kind:a.Kind.ARGUMENT,name:this.parseName(),value:(this.expectToken(r.TokenKind.COLON),this.parseValueLiteral(!0)),loc:this.loc(e)}},i.parseFragment=function(){var e=this._lexer.token;this.expectToken(r.TokenKind.SPREAD);var n=this.expectOptionalKeyword("on");return!n&&this.peek(r.TokenKind.NAME)?{kind:a.Kind.FRAGMENT_SPREAD,name:this.parseFragmentName(),directives:this.parseDirectives(!1),loc:this.loc(e)}:{kind:a.Kind.INLINE_FRAGMENT,typeCondition:n?this.parseNamedType():void 0,directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(e)}},i.parseFragmentDefinition=function(){var e,n=this._lexer.token;return this.expectKeyword("fragment"),((e=this._options)===null||e===void 0?void 0:e.experimentalFragmentVariables)===!0?{kind:a.Kind.FRAGMENT_DEFINITION,name:this.parseFragmentName(),variableDefinitions:this.parseVariableDefinitions(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(n)}:{kind:a.Kind.FRAGMENT_DEFINITION,name:this.parseFragmentName(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(n)}},i.parseFragmentName=function(){if(this._lexer.token.value==="on")throw this.unexpected();return this.parseName()},i.parseValueLiteral=function(e){var n=this._lexer.token;switch(n.kind){case r.TokenKind.BRACKET_L:return this.parseList(e);case r.TokenKind.BRACE_L:return this.parseObject(e);case r.TokenKind.INT:return this._lexer.advance(),{kind:a.Kind.INT,value:n.value,loc:this.loc(n)};case r.TokenKind.FLOAT:return this._lexer.advance(),{kind:a.Kind.FLOAT,value:n.value,loc:this.loc(n)};case r.TokenKind.STRING:case r.TokenKind.BLOCK_STRING:return this.parseStringLiteral();case r.TokenKind.NAME:switch(this._lexer.advance(),n.value){case"true":return{kind:a.Kind.BOOLEAN,value:!0,loc:this.loc(n)};case"false":return{kind:a.Kind.BOOLEAN,value:!1,loc:this.loc(n)};case"null":return{kind:a.Kind.NULL,loc:this.loc(n)};default:return{kind:a.Kind.ENUM,value:n.value,loc:this.loc(n)}}case r.TokenKind.DOLLAR:if(!e)return this.parseVariable();break}throw this.unexpected()},i.parseStringLiteral=function(){var e=this._lexer.token;return this._lexer.advance(),{kind:a.Kind.STRING,value:e.value,block:e.kind===r.TokenKind.BLOCK_STRING,loc:this.loc(e)}},i.parseList=function(e){var n=this,t=this._lexer.token,s=function(){return n.parseValueLiteral(e)};return{kind:a.Kind.LIST,values:this.any(r.TokenKind.BRACKET_L,s,r.TokenKind.BRACKET_R),loc:this.loc(t)}},i.parseObject=function(e){var n=this,t=this._lexer.token,s=function(){return n.parseObjectField(e)};return{kind:a.Kind.OBJECT,fields:this.any(r.TokenKind.BRACE_L,s,r.TokenKind.BRACE_R),loc:this.loc(t)}},i.parseObjectField=function(e){var n=this._lexer.token,t=this.parseName();return this.expectToken(r.TokenKind.COLON),{kind:a.Kind.OBJECT_FIELD,name:t,value:this.parseValueLiteral(e),loc:this.loc(n)}},i.parseDirectives=function(e){for(var n=[];this.peek(r.TokenKind.AT);)n.push(this.parseDirective(e));return n},i.parseDirective=function(e){var n=this._lexer.token;return this.expectToken(r.TokenKind.AT),{kind:a.Kind.DIRECTIVE,name:this.parseName(),arguments:this.parseArguments(e),loc:this.loc(n)}},i.parseTypeReference=function(){var e=this._lexer.token,n;return this.expectOptionalToken(r.TokenKind.BRACKET_L)?(n=this.parseTypeReference(),this.expectToken(r.TokenKind.BRACKET_R),n={kind:a.Kind.LIST_TYPE,type:n,loc:this.loc(e)}):n=this.parseNamedType(),this.expectOptionalToken(r.TokenKind.BANG)?{kind:a.Kind.NON_NULL_TYPE,type:n,loc:this.loc(e)}:n},i.parseNamedType=function(){var e=this._lexer.token;return{kind:a.Kind.NAMED_TYPE,name:this.parseName(),loc:this.loc(e)}},i.parseTypeSystemDefinition=function(){var e=this.peekDescription()?this._lexer.lookahead():this._lexer.token;if(e.kind===r.TokenKind.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)},i.peekDescription=function(){return this.peek(r.TokenKind.STRING)||this.peek(r.TokenKind.BLOCK_STRING)},i.parseDescription=function(){if(this.peekDescription())return this.parseStringLiteral()},i.parseSchemaDefinition=function(){var e=this._lexer.token,n=this.parseDescription();this.expectKeyword("schema");var t=this.parseDirectives(!0),s=this.many(r.TokenKind.BRACE_L,this.parseOperationTypeDefinition,r.TokenKind.BRACE_R);return{kind:a.Kind.SCHEMA_DEFINITION,description:n,directives:t,operationTypes:s,loc:this.loc(e)}},i.parseOperationTypeDefinition=function(){var e=this._lexer.token,n=this.parseOperationType();this.expectToken(r.TokenKind.COLON);var t=this.parseNamedType();return{kind:a.Kind.OPERATION_TYPE_DEFINITION,operation:n,type:t,loc:this.loc(e)}},i.parseScalarTypeDefinition=function(){var e=this._lexer.token,n=this.parseDescription();this.expectKeyword("scalar");var t=this.parseName(),s=this.parseDirectives(!0);return{kind:a.Kind.SCALAR_TYPE_DEFINITION,description:n,name:t,directives:s,loc:this.loc(e)}},i.parseObjectTypeDefinition=function(){var e=this._lexer.token,n=this.parseDescription();this.expectKeyword("type");var t=this.parseName(),s=this.parseImplementsInterfaces(),y=this.parseDirectives(!0),f=this.parseFieldsDefinition();return{kind:a.Kind.OBJECT_TYPE_DEFINITION,description:n,name:t,interfaces:s,directives:y,fields:f,loc:this.loc(e)}},i.parseImplementsInterfaces=function(){var e;if(!this.expectOptionalKeyword("implements"))return[];if(((e=this._options)===null||e===void 0?void 0:e.allowLegacySDLImplementsInterfaces)===!0){var n=[];this.expectOptionalToken(r.TokenKind.AMP);do n.push(this.parseNamedType());while(this.expectOptionalToken(r.TokenKind.AMP)||this.peek(r.TokenKind.NAME));return n}return this.delimitedMany(r.TokenKind.AMP,this.parseNamedType)},i.parseFieldsDefinition=function(){var e;return((e=this._options)===null||e===void 0?void 0:e.allowLegacySDLEmptyFields)===!0&&this.peek(r.TokenKind.BRACE_L)&&this._lexer.lookahead().kind===r.TokenKind.BRACE_R?(this._lexer.advance(),this._lexer.advance(),[]):this.optionalMany(r.TokenKind.BRACE_L,this.parseFieldDefinition,r.TokenKind.BRACE_R)},i.parseFieldDefinition=function(){var e=this._lexer.token,n=this.parseDescription(),t=this.parseName(),s=this.parseArgumentDefs();this.expectToken(r.TokenKind.COLON);var y=this.parseTypeReference(),f=this.parseDirectives(!0);return{kind:a.Kind.FIELD_DEFINITION,description:n,name:t,arguments:s,type:y,directives:f,loc:this.loc(e)}},i.parseArgumentDefs=function(){return this.optionalMany(r.TokenKind.PAREN_L,this.parseInputValueDef,r.TokenKind.PAREN_R)},i.parseInputValueDef=function(){var e=this._lexer.token,n=this.parseDescription(),t=this.parseName();this.expectToken(r.TokenKind.COLON);var s=this.parseTypeReference(),y;this.expectOptionalToken(r.TokenKind.EQUALS)&&(y=this.parseValueLiteral(!0));var f=this.parseDirectives(!0);return{kind:a.Kind.INPUT_VALUE_DEFINITION,description:n,name:t,type:s,defaultValue:y,directives:f,loc:this.loc(e)}},i.parseInterfaceTypeDefinition=function(){var e=this._lexer.token,n=this.parseDescription();this.expectKeyword("interface");var t=this.parseName(),s=this.parseImplementsInterfaces(),y=this.parseDirectives(!0),f=this.parseFieldsDefinition();return{kind:a.Kind.INTERFACE_TYPE_DEFINITION,description:n,name:t,interfaces:s,directives:y,fields:f,loc:this.loc(e)}},i.parseUnionTypeDefinition=function(){var e=this._lexer.token,n=this.parseDescription();this.expectKeyword("union");var t=this.parseName(),s=this.parseDirectives(!0),y=this.parseUnionMemberTypes();return{kind:a.Kind.UNION_TYPE_DEFINITION,description:n,name:t,directives:s,types:y,loc:this.loc(e)}},i.parseUnionMemberTypes=function(){return this.expectOptionalToken(r.TokenKind.EQUALS)?this.delimitedMany(r.TokenKind.PIPE,this.parseNamedType):[]},i.parseEnumTypeDefinition=function(){var e=this._lexer.token,n=this.parseDescription();this.expectKeyword("enum");var t=this.parseName(),s=this.parseDirectives(!0),y=this.parseEnumValuesDefinition();return{kind:a.Kind.ENUM_TYPE_DEFINITION,description:n,name:t,directives:s,values:y,loc:this.loc(e)}},i.parseEnumValuesDefinition=function(){return this.optionalMany(r.TokenKind.BRACE_L,this.parseEnumValueDefinition,r.TokenKind.BRACE_R)},i.parseEnumValueDefinition=function(){var e=this._lexer.token,n=this.parseDescription(),t=this.parseName(),s=this.parseDirectives(!0);return{kind:a.Kind.ENUM_VALUE_DEFINITION,description:n,name:t,directives:s,loc:this.loc(e)}},i.parseInputObjectTypeDefinition=function(){var e=this._lexer.token,n=this.parseDescription();this.expectKeyword("input");var t=this.parseName(),s=this.parseDirectives(!0),y=this.parseInputFieldsDefinition();return{kind:a.Kind.INPUT_OBJECT_TYPE_DEFINITION,description:n,name:t,directives:s,fields:y,loc:this.loc(e)}},i.parseInputFieldsDefinition=function(){return this.optionalMany(r.TokenKind.BRACE_L,this.parseInputValueDef,r.TokenKind.BRACE_R)},i.parseTypeSystemExtension=function(){var e=this._lexer.lookahead();if(e.kind===r.TokenKind.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)},i.parseSchemaExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("schema");var n=this.parseDirectives(!0),t=this.optionalMany(r.TokenKind.BRACE_L,this.parseOperationTypeDefinition,r.TokenKind.BRACE_R);if(n.length===0&&t.length===0)throw this.unexpected();return{kind:a.Kind.SCHEMA_EXTENSION,directives:n,operationTypes:t,loc:this.loc(e)}},i.parseScalarTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("scalar");var n=this.parseName(),t=this.parseDirectives(!0);if(t.length===0)throw this.unexpected();return{kind:a.Kind.SCALAR_TYPE_EXTENSION,name:n,directives:t,loc:this.loc(e)}},i.parseObjectTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("type");var n=this.parseName(),t=this.parseImplementsInterfaces(),s=this.parseDirectives(!0),y=this.parseFieldsDefinition();if(t.length===0&&s.length===0&&y.length===0)throw this.unexpected();return{kind:a.Kind.OBJECT_TYPE_EXTENSION,name:n,interfaces:t,directives:s,fields:y,loc:this.loc(e)}},i.parseInterfaceTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("interface");var n=this.parseName(),t=this.parseImplementsInterfaces(),s=this.parseDirectives(!0),y=this.parseFieldsDefinition();if(t.length===0&&s.length===0&&y.length===0)throw this.unexpected();return{kind:a.Kind.INTERFACE_TYPE_EXTENSION,name:n,interfaces:t,directives:s,fields:y,loc:this.loc(e)}},i.parseUnionTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("union");var n=this.parseName(),t=this.parseDirectives(!0),s=this.parseUnionMemberTypes();if(t.length===0&&s.length===0)throw this.unexpected();return{kind:a.Kind.UNION_TYPE_EXTENSION,name:n,directives:t,types:s,loc:this.loc(e)}},i.parseEnumTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("enum");var n=this.parseName(),t=this.parseDirectives(!0),s=this.parseEnumValuesDefinition();if(t.length===0&&s.length===0)throw this.unexpected();return{kind:a.Kind.ENUM_TYPE_EXTENSION,name:n,directives:t,values:s,loc:this.loc(e)}},i.parseInputObjectTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("input");var n=this.parseName(),t=this.parseDirectives(!0),s=this.parseInputFieldsDefinition();if(t.length===0&&s.length===0)throw this.unexpected();return{kind:a.Kind.INPUT_OBJECT_TYPE_EXTENSION,name:n,directives:t,fields:s,loc:this.loc(e)}},i.parseDirectiveDefinition=function(){var e=this._lexer.token,n=this.parseDescription();this.expectKeyword("directive"),this.expectToken(r.TokenKind.AT);var t=this.parseName(),s=this.parseArgumentDefs(),y=this.expectOptionalKeyword("repeatable");this.expectKeyword("on");var f=this.parseDirectiveLocations();return{kind:a.Kind.DIRECTIVE_DEFINITION,description:n,name:t,arguments:s,repeatable:y,locations:f,loc:this.loc(e)}},i.parseDirectiveLocations=function(){return this.delimitedMany(r.TokenKind.PIPE,this.parseDirectiveLocation)},i.parseDirectiveLocation=function(){var e=this._lexer.token,n=this.parseName();if(E.DirectiveLocation[n.value]!==void 0)return n;throw this.unexpected(e)},i.loc=function(e){var n;if(((n=this._options)===null||n===void 0?void 0:n.noLocation)!==!0)return new p.Location(e,this._lexer.lastToken,this._lexer.source)},i.peek=function(e){return this._lexer.token.kind===e},i.expectToken=function(e){var n=this._lexer.token;if(n.kind===e)return this._lexer.advance(),n;throw(0,T.syntaxError)(this._lexer.source,n.start,"Expected ".concat(h(e),", found ").concat(I(n),"."))},i.expectOptionalToken=function(e){var n=this._lexer.token;if(n.kind===e)return this._lexer.advance(),n},i.expectKeyword=function(e){var n=this._lexer.token;if(n.kind===r.TokenKind.NAME&&n.value===e)this._lexer.advance();else throw(0,T.syntaxError)(this._lexer.source,n.start,'Expected "'.concat(e,'", found ').concat(I(n),"."))},i.expectOptionalKeyword=function(e){var n=this._lexer.token;return n.kind===r.TokenKind.NAME&&n.value===e?(this._lexer.advance(),!0):!1},i.unexpected=function(e){var n=e!=null?e:this._lexer.token;return(0,T.syntaxError)(this._lexer.source,n.start,"Unexpected ".concat(I(n),"."))},i.any=function(e,n,t){this.expectToken(e);for(var s=[];!this.expectOptionalToken(t);)s.push(n.call(this));return s},i.optionalMany=function(e,n,t){if(this.expectOptionalToken(e)){var s=[];do s.push(n.call(this));while(!this.expectOptionalToken(t));return s}return[]},i.many=function(e,n,t){this.expectToken(e);var s=[];do s.push(n.call(this));while(!this.expectOptionalToken(t));return s},i.delimitedMany=function(e,n){this.expectOptionalToken(e);var t=[];do t.push(n.call(this));while(this.expectOptionalToken(e));return t},N}();l.Parser=S;function I(N){var i=N.value;return h(N.kind)+(i!=null?' "'.concat(i,'"'):"")}function h(N){return(0,k.isPunctuatorTokenKind)(N)?'"'.concat(N,'"'):N}}}),ye=K({"src/language-graphql/parser-graphql.js"(l,T){L();var a=ie(),p=ae(),{hasPragma:r}=oe(),{locStart:_,locEnd:E}=se();function k(I){let h=[],{startToken:N}=I.loc,{next:i}=N;for(;i.kind!=="";)i.kind==="Comment"&&(Object.assign(i,{column:i.column-1}),h.push(i)),i=i.next;return h}function g(I){if(I&&typeof I=="object"){delete I.startToken,delete I.endToken,delete I.prev,delete I.next;for(let h in I)g(I[h])}return I}var D={allowLegacySDLImplementsInterfaces:!1,experimentalFragmentVariables:!0};function O(I){let{GraphQLError:h}=$();if(I instanceof h){let{message:N,locations:[i]}=I;return a(N,{start:i})}return I}function S(I){let{parse:h}=me(),{result:N,error:i}=p(()=>h(I,Object.assign({},D)),()=>h(I,Object.assign(Object.assign({},D),{},{allowLegacySDLImplementsInterfaces:!0})));if(!N)throw O(i);return N.comments=k(N),g(N),N}T.exports={parsers:{graphql:{parse:S,astFormat:"graphql",hasPragma:r,locStart:_,locEnd:E}}}}}),ke=ye();export{ke as default};