@graphitation/supermassive 3.0.1 → 3.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (59) hide show
  1. package/.eslintcache +1 -1
  2. package/CHANGELOG.md +10 -2
  3. package/lib/index.d.ts +17 -14
  4. package/lib/index.d.ts.map +1 -1
  5. package/lib/index.js +24 -8
  6. package/lib/index.js.map +3 -3
  7. package/lib/index.mjs +24 -18
  8. package/lib/index.mjs.map +3 -3
  9. package/lib/legacyAST/TypedAST.d.ts +366 -0
  10. package/lib/legacyAST/TypedAST.d.ts.map +1 -0
  11. package/lib/legacyAST/TypedAST.js +16 -0
  12. package/lib/legacyAST/TypedAST.js.map +7 -0
  13. package/lib/legacyAST/TypedAST.mjs +0 -0
  14. package/lib/legacyAST/TypedAST.mjs.map +7 -0
  15. package/lib/legacyAST/addTypesToRequestDocument.d.ts +6 -0
  16. package/lib/legacyAST/addTypesToRequestDocument.d.ts.map +1 -0
  17. package/lib/legacyAST/addTypesToRequestDocument.js +161 -0
  18. package/lib/legacyAST/addTypesToRequestDocument.js.map +7 -0
  19. package/lib/legacyAST/addTypesToRequestDocument.mjs +153 -0
  20. package/lib/legacyAST/addTypesToRequestDocument.mjs.map +7 -0
  21. package/lib/legacyAST/annotateDocumentGraphQLTransform.d.ts +3 -0
  22. package/lib/legacyAST/annotateDocumentGraphQLTransform.d.ts.map +1 -0
  23. package/lib/legacyAST/annotateDocumentGraphQLTransform.js +34 -0
  24. package/lib/legacyAST/annotateDocumentGraphQLTransform.js.map +7 -0
  25. package/lib/legacyAST/annotateDocumentGraphQLTransform.mjs +17 -0
  26. package/lib/legacyAST/annotateDocumentGraphQLTransform.mjs.map +7 -0
  27. package/lib/legacyAST/index.d.ts +4 -0
  28. package/lib/legacyAST/index.d.ts.map +1 -0
  29. package/lib/legacyAST/index.js +26 -0
  30. package/lib/legacyAST/index.js.map +7 -0
  31. package/lib/legacyAST/index.mjs +7 -0
  32. package/lib/legacyAST/index.mjs.map +7 -0
  33. package/lib/schema/definition.d.ts +31 -2
  34. package/lib/schema/definition.d.ts.map +1 -1
  35. package/lib/schema/definition.js +67 -5
  36. package/lib/schema/definition.js.map +3 -3
  37. package/lib/schema/definition.mjs +67 -4
  38. package/lib/schema/definition.mjs.map +2 -2
  39. package/lib/schema/directives.d.ts.map +1 -1
  40. package/lib/schema/directives.js +22 -1
  41. package/lib/schema/directives.js.map +2 -2
  42. package/lib/schema/directives.mjs +23 -1
  43. package/lib/schema/directives.mjs.map +2 -2
  44. package/lib/utilities/encodeASTSchema.d.ts.map +1 -1
  45. package/lib/utilities/encodeASTSchema.js +16 -1
  46. package/lib/utilities/encodeASTSchema.js.map +3 -3
  47. package/lib/utilities/encodeASTSchema.mjs +18 -2
  48. package/lib/utilities/encodeASTSchema.mjs.map +3 -3
  49. package/lib/utilities/extractMinimalViableSchemaForRequestDocument.d.ts.map +1 -1
  50. package/lib/utilities/extractMinimalViableSchemaForRequestDocument.js +2 -2
  51. package/lib/utilities/extractMinimalViableSchemaForRequestDocument.js.map +2 -2
  52. package/lib/utilities/extractMinimalViableSchemaForRequestDocument.mjs +3 -2
  53. package/lib/utilities/extractMinimalViableSchemaForRequestDocument.mjs.map +2 -2
  54. package/lib/values.d.ts.map +1 -1
  55. package/lib/values.js +1 -1
  56. package/lib/values.js.map +2 -2
  57. package/lib/values.mjs +4 -3
  58. package/lib/values.mjs.map +2 -2
  59. package/package.json +1 -1
@@ -0,0 +1,366 @@
1
+ /**
2
+ * Taken from node_modules/graphql/language/ast.d.ts
3
+ * License: MIT License
4
+ * Copyright (c): GraphQL Contributors
5
+ *
6
+ * Our changes MUST be annotated inline for ease of future merging.
7
+ */
8
+ /**
9
+ * [SUPERMASSIVE]
10
+ *
11
+ * We don't need `Location`, `Token`, and `isNode` , so remove it and its dependencies.
12
+ */
13
+ type Location = unknown;
14
+ /**
15
+ * The list of all possible AST node types.
16
+ */
17
+ export type ASTNode = NameNode | DocumentNode | OperationDefinitionNode | VariableDefinitionNode | VariableNode | SelectionSetNode | FieldNode | ArgumentNode | FragmentSpreadNode | InlineFragmentNode | FragmentDefinitionNode | IntValueNode | FloatValueNode | StringValueNode | BooleanValueNode | NullValueNode | EnumValueNode | ListValueNode | ObjectValueNode | ObjectFieldNode | DirectiveNode | NamedTypeNode | ListTypeNode | NonNullTypeNode | SchemaDefinitionNode | OperationTypeDefinitionNode | ScalarTypeDefinitionNode | ObjectTypeDefinitionNode | FieldDefinitionNode | InputValueDefinitionNode | InterfaceTypeDefinitionNode | UnionTypeDefinitionNode | EnumTypeDefinitionNode | EnumValueDefinitionNode | InputObjectTypeDefinitionNode | DirectiveDefinitionNode | SchemaExtensionNode | ScalarTypeExtensionNode | ObjectTypeExtensionNode | InterfaceTypeExtensionNode | UnionTypeExtensionNode | EnumTypeExtensionNode | InputObjectTypeExtensionNode;
18
+ /**
19
+ * Utility type listing all nodes indexed by their kind.
20
+ */
21
+ export interface ASTKindToNode {
22
+ Name: NameNode;
23
+ Document: DocumentNode;
24
+ OperationDefinition: OperationDefinitionNode;
25
+ VariableDefinition: VariableDefinitionNode;
26
+ Variable: VariableNode;
27
+ SelectionSet: SelectionSetNode;
28
+ Field: FieldNode;
29
+ Argument: ArgumentNode;
30
+ FragmentSpread: FragmentSpreadNode;
31
+ InlineFragment: InlineFragmentNode;
32
+ FragmentDefinition: FragmentDefinitionNode;
33
+ IntValue: IntValueNode;
34
+ FloatValue: FloatValueNode;
35
+ StringValue: StringValueNode;
36
+ BooleanValue: BooleanValueNode;
37
+ NullValue: NullValueNode;
38
+ EnumValue: EnumValueNode;
39
+ ListValue: ListValueNode;
40
+ ObjectValue: ObjectValueNode;
41
+ ObjectField: ObjectFieldNode;
42
+ Directive: DirectiveNode;
43
+ NamedType: NamedTypeNode;
44
+ ListType: ListTypeNode;
45
+ NonNullType: NonNullTypeNode;
46
+ SchemaDefinition: SchemaDefinitionNode;
47
+ OperationTypeDefinition: OperationTypeDefinitionNode;
48
+ ScalarTypeDefinition: ScalarTypeDefinitionNode;
49
+ ObjectTypeDefinition: ObjectTypeDefinitionNode;
50
+ FieldDefinition: FieldDefinitionNode;
51
+ InputValueDefinition: InputValueDefinitionNode;
52
+ InterfaceTypeDefinition: InterfaceTypeDefinitionNode;
53
+ UnionTypeDefinition: UnionTypeDefinitionNode;
54
+ EnumTypeDefinition: EnumTypeDefinitionNode;
55
+ EnumValueDefinition: EnumValueDefinitionNode;
56
+ InputObjectTypeDefinition: InputObjectTypeDefinitionNode;
57
+ DirectiveDefinition: DirectiveDefinitionNode;
58
+ SchemaExtension: SchemaExtensionNode;
59
+ ScalarTypeExtension: ScalarTypeExtensionNode;
60
+ ObjectTypeExtension: ObjectTypeExtensionNode;
61
+ InterfaceTypeExtension: InterfaceTypeExtensionNode;
62
+ UnionTypeExtension: UnionTypeExtensionNode;
63
+ EnumTypeExtension: EnumTypeExtensionNode;
64
+ InputObjectTypeExtension: InputObjectTypeExtensionNode;
65
+ }
66
+ export interface NameNode {
67
+ readonly kind: "Name";
68
+ readonly loc?: Location;
69
+ readonly value: string;
70
+ }
71
+ export interface DocumentNode {
72
+ readonly kind: "Document";
73
+ readonly loc?: Location;
74
+ readonly definitions: ReadonlyArray<DefinitionNode>;
75
+ }
76
+ export type DefinitionNode = ExecutableDefinitionNode | TypeSystemDefinitionNode | TypeSystemExtensionNode;
77
+ export type ExecutableDefinitionNode = OperationDefinitionNode | FragmentDefinitionNode;
78
+ export interface OperationDefinitionNode {
79
+ readonly kind: "OperationDefinition";
80
+ readonly loc?: Location;
81
+ readonly operation: OperationTypeNode;
82
+ readonly name?: NameNode;
83
+ readonly variableDefinitions?: ReadonlyArray<VariableDefinitionNode>;
84
+ readonly directives?: ReadonlyArray<DirectiveNode>;
85
+ readonly selectionSet: SelectionSetNode;
86
+ }
87
+ export type OperationTypeNode = "query" | "mutation" | "subscription";
88
+ export interface VariableDefinitionNode {
89
+ readonly kind: "VariableDefinition";
90
+ readonly loc?: Location;
91
+ readonly variable: VariableNode;
92
+ readonly type: TypeNode;
93
+ readonly defaultValue?: ValueNode;
94
+ readonly directives?: ReadonlyArray<DirectiveNode>;
95
+ }
96
+ export interface VariableNode {
97
+ readonly kind: "Variable";
98
+ readonly loc?: Location;
99
+ readonly name: NameNode;
100
+ }
101
+ export interface SelectionSetNode {
102
+ kind: "SelectionSet";
103
+ loc?: Location;
104
+ selections: ReadonlyArray<SelectionNode>;
105
+ }
106
+ export type SelectionNode = FieldNode | FragmentSpreadNode | InlineFragmentNode;
107
+ export interface FieldNode {
108
+ readonly __type: TypeNode;
109
+ readonly kind: "Field";
110
+ readonly loc?: Location;
111
+ readonly alias?: NameNode;
112
+ readonly name: NameNode;
113
+ readonly arguments?: ReadonlyArray<ArgumentNode>;
114
+ readonly directives?: ReadonlyArray<DirectiveNode>;
115
+ readonly selectionSet?: SelectionSetNode;
116
+ }
117
+ export interface ArgumentNode {
118
+ readonly __type: TypeNode;
119
+ readonly __defaultValue?: ValueNode | null;
120
+ readonly kind: "Argument";
121
+ readonly loc?: Location;
122
+ readonly name: NameNode;
123
+ readonly value: ValueNode;
124
+ }
125
+ export interface FragmentSpreadNode {
126
+ readonly kind: "FragmentSpread";
127
+ readonly loc?: Location;
128
+ readonly name: NameNode;
129
+ readonly directives?: ReadonlyArray<DirectiveNode>;
130
+ }
131
+ export interface InlineFragmentNode {
132
+ readonly kind: "InlineFragment";
133
+ readonly loc?: Location;
134
+ readonly typeCondition?: NamedTypeNode;
135
+ readonly directives?: ReadonlyArray<DirectiveNode>;
136
+ readonly selectionSet: SelectionSetNode;
137
+ }
138
+ export interface FragmentDefinitionNode {
139
+ readonly kind: "FragmentDefinition";
140
+ readonly loc?: Location;
141
+ readonly name: NameNode;
142
+ readonly variableDefinitions?: ReadonlyArray<VariableDefinitionNode>;
143
+ readonly typeCondition: NamedTypeNode;
144
+ readonly directives?: ReadonlyArray<DirectiveNode>;
145
+ readonly selectionSet: SelectionSetNode;
146
+ }
147
+ export type ValueNode = VariableNode | IntValueNode | FloatValueNode | StringValueNode | BooleanValueNode | NullValueNode | EnumValueNode | ListValueNode | ObjectValueNode;
148
+ export interface IntValueNode {
149
+ readonly kind: "IntValue";
150
+ readonly loc?: Location;
151
+ readonly value: string;
152
+ }
153
+ export interface FloatValueNode {
154
+ readonly kind: "FloatValue";
155
+ readonly loc?: Location;
156
+ readonly value: string;
157
+ }
158
+ export interface StringValueNode {
159
+ readonly kind: "StringValue";
160
+ readonly loc?: Location;
161
+ readonly value: string;
162
+ readonly block?: boolean;
163
+ }
164
+ export interface BooleanValueNode {
165
+ readonly kind: "BooleanValue";
166
+ readonly loc?: Location;
167
+ readonly value: boolean;
168
+ }
169
+ export interface NullValueNode {
170
+ readonly kind: "NullValue";
171
+ readonly loc?: Location;
172
+ }
173
+ export interface EnumValueNode {
174
+ readonly kind: "EnumValue";
175
+ readonly loc?: Location;
176
+ readonly value: string;
177
+ }
178
+ export interface ListValueNode {
179
+ readonly kind: "ListValue";
180
+ readonly loc?: Location;
181
+ readonly values: ReadonlyArray<ValueNode>;
182
+ }
183
+ export interface ObjectValueNode {
184
+ readonly kind: "ObjectValue";
185
+ readonly loc?: Location;
186
+ readonly fields: ReadonlyArray<ObjectFieldNode>;
187
+ }
188
+ export interface ObjectFieldNode {
189
+ readonly kind: "ObjectField";
190
+ readonly loc?: Location;
191
+ readonly name: NameNode;
192
+ readonly value: ValueNode;
193
+ }
194
+ export interface DirectiveNode {
195
+ readonly kind: "Directive";
196
+ readonly loc?: Location;
197
+ readonly name: NameNode;
198
+ readonly arguments?: ReadonlyArray<ArgumentNode>;
199
+ }
200
+ export type TypeNode = NamedTypeNode | ListTypeNode | NonNullTypeNode;
201
+ export interface NamedTypeNode {
202
+ readonly kind: "NamedType";
203
+ readonly loc?: Location;
204
+ readonly name: NameNode;
205
+ }
206
+ export interface ListTypeNode {
207
+ readonly kind: "ListType";
208
+ readonly loc?: Location;
209
+ readonly type: TypeNode;
210
+ }
211
+ export interface NonNullTypeNode {
212
+ readonly kind: "NonNullType";
213
+ readonly loc?: Location;
214
+ readonly type: NamedTypeNode | ListTypeNode;
215
+ }
216
+ export type TypeSystemDefinitionNode = SchemaDefinitionNode | TypeDefinitionNode | DirectiveDefinitionNode;
217
+ export interface SchemaDefinitionNode {
218
+ readonly kind: "SchemaDefinition";
219
+ readonly loc?: Location;
220
+ readonly description?: StringValueNode;
221
+ readonly directives?: ReadonlyArray<DirectiveNode>;
222
+ readonly operationTypes: ReadonlyArray<OperationTypeDefinitionNode>;
223
+ }
224
+ export interface OperationTypeDefinitionNode {
225
+ readonly kind: "OperationTypeDefinition";
226
+ readonly loc?: Location;
227
+ readonly operation: OperationTypeNode;
228
+ readonly type: NamedTypeNode;
229
+ }
230
+ export type TypeDefinitionNode = ScalarTypeDefinitionNode | ObjectTypeDefinitionNode | InterfaceTypeDefinitionNode | UnionTypeDefinitionNode | EnumTypeDefinitionNode | InputObjectTypeDefinitionNode;
231
+ export interface ScalarTypeDefinitionNode {
232
+ readonly kind: "ScalarTypeDefinition";
233
+ readonly loc?: Location;
234
+ readonly description?: StringValueNode;
235
+ readonly name: NameNode;
236
+ readonly directives?: ReadonlyArray<DirectiveNode>;
237
+ }
238
+ export interface ObjectTypeDefinitionNode {
239
+ readonly kind: "ObjectTypeDefinition";
240
+ readonly loc?: Location;
241
+ readonly description?: StringValueNode;
242
+ readonly name: NameNode;
243
+ readonly interfaces?: ReadonlyArray<NamedTypeNode>;
244
+ readonly directives?: ReadonlyArray<DirectiveNode>;
245
+ readonly fields?: ReadonlyArray<FieldDefinitionNode>;
246
+ }
247
+ export interface FieldDefinitionNode {
248
+ readonly kind: "FieldDefinition";
249
+ readonly loc?: Location;
250
+ readonly description?: StringValueNode;
251
+ readonly name: NameNode;
252
+ readonly arguments?: ReadonlyArray<InputValueDefinitionNode>;
253
+ readonly type: TypeNode;
254
+ readonly directives?: ReadonlyArray<DirectiveNode>;
255
+ }
256
+ export interface InputValueDefinitionNode {
257
+ readonly kind: "InputValueDefinition";
258
+ readonly loc?: Location;
259
+ readonly description?: StringValueNode;
260
+ readonly name: NameNode;
261
+ readonly type: TypeNode;
262
+ readonly defaultValue?: ValueNode;
263
+ readonly directives?: ReadonlyArray<DirectiveNode>;
264
+ }
265
+ export interface InterfaceTypeDefinitionNode {
266
+ readonly kind: "InterfaceTypeDefinition";
267
+ readonly loc?: Location;
268
+ readonly description?: StringValueNode;
269
+ readonly name: NameNode;
270
+ readonly interfaces?: ReadonlyArray<NamedTypeNode>;
271
+ readonly directives?: ReadonlyArray<DirectiveNode>;
272
+ readonly fields?: ReadonlyArray<FieldDefinitionNode>;
273
+ }
274
+ export interface UnionTypeDefinitionNode {
275
+ readonly kind: "UnionTypeDefinition";
276
+ readonly loc?: Location;
277
+ readonly description?: StringValueNode;
278
+ readonly name: NameNode;
279
+ readonly directives?: ReadonlyArray<DirectiveNode>;
280
+ readonly types?: ReadonlyArray<NamedTypeNode>;
281
+ }
282
+ export interface EnumTypeDefinitionNode {
283
+ readonly kind: "EnumTypeDefinition";
284
+ readonly loc?: Location;
285
+ readonly description?: StringValueNode;
286
+ readonly name: NameNode;
287
+ readonly directives?: ReadonlyArray<DirectiveNode>;
288
+ readonly values?: ReadonlyArray<EnumValueDefinitionNode>;
289
+ }
290
+ export interface EnumValueDefinitionNode {
291
+ readonly kind: "EnumValueDefinition";
292
+ readonly loc?: Location;
293
+ readonly description?: StringValueNode;
294
+ readonly name: NameNode;
295
+ readonly directives?: ReadonlyArray<DirectiveNode>;
296
+ }
297
+ export interface InputObjectTypeDefinitionNode {
298
+ readonly kind: "InputObjectTypeDefinition";
299
+ readonly loc?: Location;
300
+ readonly description?: StringValueNode;
301
+ readonly name: NameNode;
302
+ readonly directives?: ReadonlyArray<DirectiveNode>;
303
+ readonly fields?: ReadonlyArray<InputValueDefinitionNode>;
304
+ }
305
+ export interface DirectiveDefinitionNode {
306
+ readonly kind: "DirectiveDefinition";
307
+ readonly loc?: Location;
308
+ readonly description?: StringValueNode;
309
+ readonly name: NameNode;
310
+ readonly arguments?: ReadonlyArray<InputValueDefinitionNode>;
311
+ readonly repeatable: boolean;
312
+ readonly locations: ReadonlyArray<NameNode>;
313
+ }
314
+ export type TypeSystemExtensionNode = SchemaExtensionNode | TypeExtensionNode;
315
+ export interface SchemaExtensionNode {
316
+ readonly kind: "SchemaExtension";
317
+ readonly loc?: Location;
318
+ readonly directives?: ReadonlyArray<DirectiveNode>;
319
+ readonly operationTypes?: ReadonlyArray<OperationTypeDefinitionNode>;
320
+ }
321
+ export type TypeExtensionNode = ScalarTypeExtensionNode | ObjectTypeExtensionNode | InterfaceTypeExtensionNode | UnionTypeExtensionNode | EnumTypeExtensionNode | InputObjectTypeExtensionNode;
322
+ export interface ScalarTypeExtensionNode {
323
+ readonly kind: "ScalarTypeExtension";
324
+ readonly loc?: Location;
325
+ readonly name: NameNode;
326
+ readonly directives?: ReadonlyArray<DirectiveNode>;
327
+ }
328
+ export interface ObjectTypeExtensionNode {
329
+ readonly kind: "ObjectTypeExtension";
330
+ readonly loc?: Location;
331
+ readonly name: NameNode;
332
+ readonly interfaces?: ReadonlyArray<NamedTypeNode>;
333
+ readonly directives?: ReadonlyArray<DirectiveNode>;
334
+ readonly fields?: ReadonlyArray<FieldDefinitionNode>;
335
+ }
336
+ export interface InterfaceTypeExtensionNode {
337
+ readonly kind: "InterfaceTypeExtension";
338
+ readonly loc?: Location;
339
+ readonly name: NameNode;
340
+ readonly interfaces?: ReadonlyArray<NamedTypeNode>;
341
+ readonly directives?: ReadonlyArray<DirectiveNode>;
342
+ readonly fields?: ReadonlyArray<FieldDefinitionNode>;
343
+ }
344
+ export interface UnionTypeExtensionNode {
345
+ readonly kind: "UnionTypeExtension";
346
+ readonly loc?: Location;
347
+ readonly name: NameNode;
348
+ readonly directives?: ReadonlyArray<DirectiveNode>;
349
+ readonly types?: ReadonlyArray<NamedTypeNode>;
350
+ }
351
+ export interface EnumTypeExtensionNode {
352
+ readonly kind: "EnumTypeExtension";
353
+ readonly loc?: Location;
354
+ readonly name: NameNode;
355
+ readonly directives?: ReadonlyArray<DirectiveNode>;
356
+ readonly values?: ReadonlyArray<EnumValueDefinitionNode>;
357
+ }
358
+ export interface InputObjectTypeExtensionNode {
359
+ readonly kind: "InputObjectTypeExtension";
360
+ readonly loc?: Location;
361
+ readonly name: NameNode;
362
+ readonly directives?: ReadonlyArray<DirectiveNode>;
363
+ readonly fields?: ReadonlyArray<InputValueDefinitionNode>;
364
+ }
365
+ export {};
366
+ //# sourceMappingURL=TypedAST.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TypedAST.d.ts","sourceRoot":"","sources":["../../src/legacyAST/TypedAST.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH;;;;GAIG;AACH,KAAK,QAAQ,GAAG,OAAO,CAAC;AAExB;;GAEG;AACH,MAAM,MAAM,OAAO,GACf,QAAQ,GACR,YAAY,GACZ,uBAAuB,GACvB,sBAAsB,GACtB,YAAY,GACZ,gBAAgB,GAChB,SAAS,GACT,YAAY,GACZ,kBAAkB,GAClB,kBAAkB,GAClB,sBAAsB,GACtB,YAAY,GACZ,cAAc,GACd,eAAe,GACf,gBAAgB,GAChB,aAAa,GACb,aAAa,GACb,aAAa,GACb,eAAe,GACf,eAAe,GACf,aAAa,GACb,aAAa,GACb,YAAY,GACZ,eAAe,GACf,oBAAoB,GACpB,2BAA2B,GAC3B,wBAAwB,GACxB,wBAAwB,GACxB,mBAAmB,GACnB,wBAAwB,GACxB,2BAA2B,GAC3B,uBAAuB,GACvB,sBAAsB,GACtB,uBAAuB,GACvB,6BAA6B,GAC7B,uBAAuB,GACvB,mBAAmB,GACnB,uBAAuB,GACvB,uBAAuB,GACvB,0BAA0B,GAC1B,sBAAsB,GACtB,qBAAqB,GACrB,4BAA4B,CAAC;AAEjC;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,QAAQ,CAAC;IACf,QAAQ,EAAE,YAAY,CAAC;IACvB,mBAAmB,EAAE,uBAAuB,CAAC;IAC7C,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nC,QAAQ,CAAC,GAAG,CAAC,EAAE,QAAQ,CAAC;IACxB,QAAQ,CAAC,IAAI,EAAE,QAAQ,CAAC;IACxB,QAAQ,CAAC,UAAU,CAAC,EAAE,aAAa,CAAC,aAAa,CAAC,CAAC;IACnD,QAAQ,CAAC,MAAM,CAAC,EAAE,aAAa,CAAC,uBAAuB,CAAC,CAAC;CAC1D;AAED,MAAM,WAAW,4BAA4B;IAC3C,QAAQ,CAAC,IAAI,EAAE,0BAA0B,CAAC;IAC1C,QAAQ,CAAC,GAAG,CAAC,EAAE,QAAQ,CAAC;IACxB,QAAQ,CAAC,IAAI,EAAE,QAAQ,CAAC;IACxB,QAAQ,CAAC,UAAU,CAAC,EAAE,aAAa,CAAC,aAAa,CAAC,CAAC;IACnD,QAAQ,CAAC,MAAM,CAAC,EAAE,aAAa,CAAC,wBAAwB,CAAC,CAAC;CAC3D"}
@@ -0,0 +1,16 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __copyProps = (to, from, except, desc) => {
7
+ if (from && typeof from === "object" || typeof from === "function") {
8
+ for (let key of __getOwnPropNames(from))
9
+ if (!__hasOwnProp.call(to, key) && key !== except)
10
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
11
+ }
12
+ return to;
13
+ };
14
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
15
+ var TypedAST_exports = {};
16
+ module.exports = __toCommonJS(TypedAST_exports);
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/legacyAST/TypedAST.ts"],
4
+ "sourcesContent": ["/**\n * Taken from node_modules/graphql/language/ast.d.ts\n * License: MIT License\n * Copyright (c): GraphQL Contributors\n *\n * Our changes MUST be annotated inline for ease of future merging.\n */\n\n/**\n * [SUPERMASSIVE]\n *\n * We don't need `Location`, `Token`, and `isNode` , so remove it and its dependencies.\n */\ntype Location = unknown;\n\n/**\n * The list of all possible AST node types.\n */\nexport type ASTNode =\n | NameNode\n | DocumentNode\n | OperationDefinitionNode\n | VariableDefinitionNode\n | VariableNode\n | SelectionSetNode\n | FieldNode\n | ArgumentNode\n | FragmentSpreadNode\n | InlineFragmentNode\n | FragmentDefinitionNode\n | IntValueNode\n | FloatValueNode\n | StringValueNode\n | BooleanValueNode\n | NullValueNode\n | EnumValueNode\n | ListValueNode\n | ObjectValueNode\n | ObjectFieldNode\n | DirectiveNode\n | NamedTypeNode\n | ListTypeNode\n | NonNullTypeNode\n | SchemaDefinitionNode\n | OperationTypeDefinitionNode\n | ScalarTypeDefinitionNode\n | ObjectTypeDefinitionNode\n | FieldDefinitionNode\n | InputValueDefinitionNode\n | InterfaceTypeDefinitionNode\n | UnionTypeDefinitionNode\n | EnumTypeDefinitionNode\n | EnumValueDefinitionNode\n | InputObjectTypeDefinitionNode\n | DirectiveDefinitionNode\n | SchemaExtensionNode\n | ScalarTypeExtensionNode\n | ObjectTypeExtensionNode\n | InterfaceTypeExtensionNode\n | UnionTypeExtensionNode\n | EnumTypeExtensionNode\n | InputObjectTypeExtensionNode;\n\n/**\n * Utility type listing all nodes indexed by their kind.\n */\nexport interface ASTKindToNode {\n Name: NameNode;\n Document: DocumentNode;\n OperationDefinition: OperationDefinitionNode;\n VariableDefinition: VariableDefinitionNode;\n Variable: VariableNode;\n SelectionSet: SelectionSetNode;\n Field: FieldNode;\n Argument: ArgumentNode;\n FragmentSpread: FragmentSpreadNode;\n InlineFragment: InlineFragmentNode;\n FragmentDefinition: FragmentDefinitionNode;\n IntValue: IntValueNode;\n FloatValue: FloatValueNode;\n StringValue: StringValueNode;\n BooleanValue: BooleanValueNode;\n NullValue: NullValueNode;\n EnumValue: EnumValueNode;\n ListValue: ListValueNode;\n ObjectValue: ObjectValueNode;\n ObjectField: ObjectFieldNode;\n Directive: DirectiveNode;\n NamedType: NamedTypeNode;\n ListType: ListTypeNode;\n NonNullType: NonNullTypeNode;\n SchemaDefinition: SchemaDefinitionNode;\n OperationTypeDefinition: OperationTypeDefinitionNode;\n ScalarTypeDefinition: ScalarTypeDefinitionNode;\n ObjectTypeDefinition: ObjectTypeDefinitionNode;\n FieldDefinition: FieldDefinitionNode;\n InputValueDefinition: InputValueDefinitionNode;\n InterfaceTypeDefinition: InterfaceTypeDefinitionNode;\n UnionTypeDefinition: UnionTypeDefinitionNode;\n EnumTypeDefinition: EnumTypeDefinitionNode;\n EnumValueDefinition: EnumValueDefinitionNode;\n InputObjectTypeDefinition: InputObjectTypeDefinitionNode;\n DirectiveDefinition: DirectiveDefinitionNode;\n SchemaExtension: SchemaExtensionNode;\n ScalarTypeExtension: ScalarTypeExtensionNode;\n ObjectTypeExtension: ObjectTypeExtensionNode;\n InterfaceTypeExtension: InterfaceTypeExtensionNode;\n UnionTypeExtension: UnionTypeExtensionNode;\n EnumTypeExtension: EnumTypeExtensionNode;\n InputObjectTypeExtension: InputObjectTypeExtensionNode;\n}\n\n// Name\n\nexport interface NameNode {\n readonly kind: \"Name\";\n readonly loc?: Location;\n readonly value: string;\n}\n\n// Document\n\nexport interface DocumentNode {\n readonly kind: \"Document\";\n readonly loc?: Location;\n readonly definitions: ReadonlyArray<DefinitionNode>;\n}\n\nexport type DefinitionNode =\n | ExecutableDefinitionNode\n | TypeSystemDefinitionNode\n | TypeSystemExtensionNode;\n\nexport type ExecutableDefinitionNode =\n | OperationDefinitionNode\n | FragmentDefinitionNode;\n\nexport interface OperationDefinitionNode {\n readonly kind: \"OperationDefinition\";\n readonly loc?: Location;\n readonly operation: OperationTypeNode;\n readonly name?: NameNode;\n readonly variableDefinitions?: ReadonlyArray<VariableDefinitionNode>;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n readonly selectionSet: SelectionSetNode;\n}\n\nexport type OperationTypeNode = \"query\" | \"mutation\" | \"subscription\";\n\nexport interface VariableDefinitionNode {\n readonly kind: \"VariableDefinition\";\n readonly loc?: Location;\n readonly variable: VariableNode;\n readonly type: TypeNode;\n readonly defaultValue?: ValueNode;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n}\n\nexport interface VariableNode {\n readonly kind: \"Variable\";\n readonly loc?: Location;\n readonly name: NameNode;\n}\n\nexport interface SelectionSetNode {\n kind: \"SelectionSet\";\n loc?: Location;\n selections: ReadonlyArray<SelectionNode>;\n}\n\nexport type SelectionNode = FieldNode | FragmentSpreadNode | InlineFragmentNode;\n\nexport interface FieldNode {\n readonly __type: TypeNode; // [SUPERMASSIVE] Add the return type\n readonly kind: \"Field\";\n readonly loc?: Location;\n readonly alias?: NameNode;\n readonly name: NameNode;\n readonly arguments?: ReadonlyArray<ArgumentNode>;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n readonly selectionSet?: SelectionSetNode;\n}\n\nexport interface ArgumentNode {\n readonly __type: TypeNode; // [SUPERMASSIVE] Add the value type\n readonly __defaultValue?: ValueNode | null; // [SUPERMASSIVE] Add default value\n readonly kind: \"Argument\";\n readonly loc?: Location;\n readonly name: NameNode;\n readonly value: ValueNode;\n}\n\n// Fragments\n\nexport interface FragmentSpreadNode {\n readonly kind: \"FragmentSpread\";\n readonly loc?: Location;\n readonly name: NameNode;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n}\n\nexport interface InlineFragmentNode {\n readonly kind: \"InlineFragment\";\n readonly loc?: Location;\n readonly typeCondition?: NamedTypeNode;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n readonly selectionSet: SelectionSetNode;\n}\n\nexport interface FragmentDefinitionNode {\n readonly kind: \"FragmentDefinition\";\n readonly loc?: Location;\n readonly name: NameNode;\n // Note: fragment variable definitions are experimental and may be changed\n // or removed in the future.\n readonly variableDefinitions?: ReadonlyArray<VariableDefinitionNode>;\n readonly typeCondition: NamedTypeNode;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n readonly selectionSet: SelectionSetNode;\n}\n\n// Values\n\nexport type ValueNode =\n | VariableNode\n | IntValueNode\n | FloatValueNode\n | StringValueNode\n | BooleanValueNode\n | NullValueNode\n | EnumValueNode\n | ListValueNode\n | ObjectValueNode;\n\nexport interface IntValueNode {\n readonly kind: \"IntValue\";\n readonly loc?: Location;\n readonly value: string;\n}\n\nexport interface FloatValueNode {\n readonly kind: \"FloatValue\";\n readonly loc?: Location;\n readonly value: string;\n}\n\nexport interface StringValueNode {\n readonly kind: \"StringValue\";\n readonly loc?: Location;\n readonly value: string;\n readonly block?: boolean;\n}\n\nexport interface BooleanValueNode {\n readonly kind: \"BooleanValue\";\n readonly loc?: Location;\n readonly value: boolean;\n}\n\nexport interface NullValueNode {\n readonly kind: \"NullValue\";\n readonly loc?: Location;\n}\n\nexport interface EnumValueNode {\n readonly kind: \"EnumValue\";\n readonly loc?: Location;\n readonly value: string;\n}\n\nexport interface ListValueNode {\n readonly kind: \"ListValue\";\n readonly loc?: Location;\n readonly values: ReadonlyArray<ValueNode>;\n}\n\nexport interface ObjectValueNode {\n readonly kind: \"ObjectValue\";\n readonly loc?: Location;\n readonly fields: ReadonlyArray<ObjectFieldNode>;\n}\n\nexport interface ObjectFieldNode {\n readonly kind: \"ObjectField\";\n readonly loc?: Location;\n readonly name: NameNode;\n readonly value: ValueNode;\n}\n\n// Directives\n\nexport interface DirectiveNode {\n readonly kind: \"Directive\";\n readonly loc?: Location;\n readonly name: NameNode;\n readonly arguments?: ReadonlyArray<ArgumentNode>;\n}\n\n// Type Reference\n\nexport type TypeNode = NamedTypeNode | ListTypeNode | NonNullTypeNode;\n\nexport interface NamedTypeNode {\n readonly kind: \"NamedType\";\n readonly loc?: Location;\n readonly name: NameNode;\n}\n\nexport interface ListTypeNode {\n readonly kind: \"ListType\";\n readonly loc?: Location;\n readonly type: TypeNode;\n}\n\nexport interface NonNullTypeNode {\n readonly kind: \"NonNullType\";\n readonly loc?: Location;\n readonly type: NamedTypeNode | ListTypeNode;\n}\n\n// Type System Definition\n\nexport type TypeSystemDefinitionNode =\n | SchemaDefinitionNode\n | TypeDefinitionNode\n | DirectiveDefinitionNode;\n\nexport interface SchemaDefinitionNode {\n readonly kind: \"SchemaDefinition\";\n readonly loc?: Location;\n readonly description?: StringValueNode;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n readonly operationTypes: ReadonlyArray<OperationTypeDefinitionNode>;\n}\n\nexport interface OperationTypeDefinitionNode {\n readonly kind: \"OperationTypeDefinition\";\n readonly loc?: Location;\n readonly operation: OperationTypeNode;\n readonly type: NamedTypeNode;\n}\n\n// Type Definition\n\nexport type TypeDefinitionNode =\n | ScalarTypeDefinitionNode\n | ObjectTypeDefinitionNode\n | InterfaceTypeDefinitionNode\n | UnionTypeDefinitionNode\n | EnumTypeDefinitionNode\n | InputObjectTypeDefinitionNode;\n\nexport interface ScalarTypeDefinitionNode {\n readonly kind: \"ScalarTypeDefinition\";\n readonly loc?: Location;\n readonly description?: StringValueNode;\n readonly name: NameNode;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n}\n\nexport interface ObjectTypeDefinitionNode {\n readonly kind: \"ObjectTypeDefinition\";\n readonly loc?: Location;\n readonly description?: StringValueNode;\n readonly name: NameNode;\n readonly interfaces?: ReadonlyArray<NamedTypeNode>;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n readonly fields?: ReadonlyArray<FieldDefinitionNode>;\n}\n\nexport interface FieldDefinitionNode {\n readonly kind: \"FieldDefinition\";\n readonly loc?: Location;\n readonly description?: StringValueNode;\n readonly name: NameNode;\n readonly arguments?: ReadonlyArray<InputValueDefinitionNode>;\n readonly type: TypeNode;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n}\n\nexport interface InputValueDefinitionNode {\n readonly kind: \"InputValueDefinition\";\n readonly loc?: Location;\n readonly description?: StringValueNode;\n readonly name: NameNode;\n readonly type: TypeNode;\n readonly defaultValue?: ValueNode;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n}\n\nexport interface InterfaceTypeDefinitionNode {\n readonly kind: \"InterfaceTypeDefinition\";\n readonly loc?: Location;\n readonly description?: StringValueNode;\n readonly name: NameNode;\n readonly interfaces?: ReadonlyArray<NamedTypeNode>;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n readonly fields?: ReadonlyArray<FieldDefinitionNode>;\n}\n\nexport interface UnionTypeDefinitionNode {\n readonly kind: \"UnionTypeDefinition\";\n readonly loc?: Location;\n readonly description?: StringValueNode;\n readonly name: NameNode;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n readonly types?: ReadonlyArray<NamedTypeNode>;\n}\n\nexport interface EnumTypeDefinitionNode {\n readonly kind: \"EnumTypeDefinition\";\n readonly loc?: Location;\n readonly description?: StringValueNode;\n readonly name: NameNode;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n readonly values?: ReadonlyArray<EnumValueDefinitionNode>;\n}\n\nexport interface EnumValueDefinitionNode {\n readonly kind: \"EnumValueDefinition\";\n readonly loc?: Location;\n readonly description?: StringValueNode;\n readonly name: NameNode;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n}\n\nexport interface InputObjectTypeDefinitionNode {\n readonly kind: \"InputObjectTypeDefinition\";\n readonly loc?: Location;\n readonly description?: StringValueNode;\n readonly name: NameNode;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n readonly fields?: ReadonlyArray<InputValueDefinitionNode>;\n}\n\n// Directive Definitions\n\nexport interface DirectiveDefinitionNode {\n readonly kind: \"DirectiveDefinition\";\n readonly loc?: Location;\n readonly description?: StringValueNode;\n readonly name: NameNode;\n readonly arguments?: ReadonlyArray<InputValueDefinitionNode>;\n readonly repeatable: boolean;\n readonly locations: ReadonlyArray<NameNode>;\n}\n\n// Type System Extensions\n\nexport type TypeSystemExtensionNode = SchemaExtensionNode | TypeExtensionNode;\n\nexport interface SchemaExtensionNode {\n readonly kind: \"SchemaExtension\";\n readonly loc?: Location;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n readonly operationTypes?: ReadonlyArray<OperationTypeDefinitionNode>;\n}\n\n// Type Extensions\n\nexport type TypeExtensionNode =\n | ScalarTypeExtensionNode\n | ObjectTypeExtensionNode\n | InterfaceTypeExtensionNode\n | UnionTypeExtensionNode\n | EnumTypeExtensionNode\n | InputObjectTypeExtensionNode;\n\nexport interface ScalarTypeExtensionNode {\n readonly kind: \"ScalarTypeExtension\";\n readonly loc?: Location;\n readonly name: NameNode;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n}\n\nexport interface ObjectTypeExtensionNode {\n readonly kind: \"ObjectTypeExtension\";\n readonly loc?: Location;\n readonly name: NameNode;\n readonly interfaces?: ReadonlyArray<NamedTypeNode>;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n readonly fields?: ReadonlyArray<FieldDefinitionNode>;\n}\n\nexport interface InterfaceTypeExtensionNode {\n readonly kind: \"InterfaceTypeExtension\";\n readonly loc?: Location;\n readonly name: NameNode;\n readonly interfaces?: ReadonlyArray<NamedTypeNode>;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n readonly fields?: ReadonlyArray<FieldDefinitionNode>;\n}\n\nexport interface UnionTypeExtensionNode {\n readonly kind: \"UnionTypeExtension\";\n readonly loc?: Location;\n readonly name: NameNode;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n readonly types?: ReadonlyArray<NamedTypeNode>;\n}\n\nexport interface EnumTypeExtensionNode {\n readonly kind: \"EnumTypeExtension\";\n readonly loc?: Location;\n readonly name: NameNode;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n readonly values?: ReadonlyArray<EnumValueDefinitionNode>;\n}\n\nexport interface InputObjectTypeExtensionNode {\n readonly kind: \"InputObjectTypeExtension\";\n readonly loc?: Location;\n readonly name: NameNode;\n readonly directives?: ReadonlyArray<DirectiveNode>;\n readonly fields?: ReadonlyArray<InputValueDefinitionNode>;\n}\n"],
5
+ "mappings": ";;;;;;;;;;;;;;AAAA;AAAA;",
6
+ "names": []
7
+ }
File without changes
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": [],
4
+ "sourcesContent": [],
5
+ "mappings": "",
6
+ "names": []
7
+ }
@@ -0,0 +1,6 @@
1
+ import { GraphQLSchema } from "graphql";
2
+ import * as TypelessAST from "graphql/language/ast";
3
+ import * as TypedAST from "./TypedAST";
4
+ export * from "./TypedAST";
5
+ export declare function addTypesToRequestDocument(schema: GraphQLSchema, document: TypelessAST.DocumentNode): TypedAST.DocumentNode;
6
+ //# sourceMappingURL=addTypesToRequestDocument.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"addTypesToRequestDocument.d.ts","sourceRoot":"","sources":["../../src/legacyAST/addTypesToRequestDocument.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,aAAa,EAUd,MAAM,SAAS,CAAC;AAEjB,OAAO,KAAK,WAAW,MAAM,sBAAsB,CAAC;AACpD,OAAO,KAAK,QAAQ,MAAM,YAAY,CAAC;AACvC,cAAc,YAAY,CAAC;AAE3B,wBAAgB,yBAAyB,CACvC,MAAM,EAAE,aAAa,EACrB,QAAQ,EAAE,WAAW,CAAC,YAAY,GACjC,QAAQ,CAAC,YAAY,CA+FvB"}
@@ -0,0 +1,161 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __defProps = Object.defineProperties;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
6
+ var __getOwnPropNames = Object.getOwnPropertyNames;
7
+ var __getOwnPropSymbols = Object.getOwnPropertySymbols;
8
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
9
+ var __propIsEnum = Object.prototype.propertyIsEnumerable;
10
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
11
+ var __spreadValues = (a, b) => {
12
+ for (var prop in b || (b = {}))
13
+ if (__hasOwnProp.call(b, prop))
14
+ __defNormalProp(a, prop, b[prop]);
15
+ if (__getOwnPropSymbols)
16
+ for (var prop of __getOwnPropSymbols(b)) {
17
+ if (__propIsEnum.call(b, prop))
18
+ __defNormalProp(a, prop, b[prop]);
19
+ }
20
+ return a;
21
+ };
22
+ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
23
+ var __export = (target, all) => {
24
+ for (var name in all)
25
+ __defProp(target, name, { get: all[name], enumerable: true });
26
+ };
27
+ var __copyProps = (to, from, except, desc) => {
28
+ if (from && typeof from === "object" || typeof from === "function") {
29
+ for (let key of __getOwnPropNames(from))
30
+ if (!__hasOwnProp.call(to, key) && key !== except)
31
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
32
+ }
33
+ return to;
34
+ };
35
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
36
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
37
+ var addTypesToRequestDocument_exports = {};
38
+ __export(addTypesToRequestDocument_exports, {
39
+ addTypesToRequestDocument: () => addTypesToRequestDocument
40
+ });
41
+ module.exports = __toCommonJS(addTypesToRequestDocument_exports);
42
+ var import_graphql = require("graphql");
43
+ __reExport(addTypesToRequestDocument_exports, require("./TypedAST"), module.exports);
44
+ function addTypesToRequestDocument(schema, document) {
45
+ const typeInfo = new import_graphql.TypeInfo(schema);
46
+ return (0, import_graphql.visit)(
47
+ document,
48
+ (0, import_graphql.visitWithTypeInfo)(typeInfo, {
49
+ Argument: {
50
+ leave(node, _key, _parent, _path, ancestors) {
51
+ const argument = typeInfo.getArgument();
52
+ if (argument) {
53
+ const typeNode = generateTypeNode(argument.type);
54
+ const newNode = __spreadProps(__spreadValues({}, node), {
55
+ __type: typeNode
56
+ });
57
+ if (argument.defaultValue && node.value.kind === import_graphql.Kind.VARIABLE) {
58
+ newNode.__defaultValue = (0, import_graphql.astFromValue)(
59
+ argument.defaultValue,
60
+ argument.type
61
+ );
62
+ }
63
+ return newNode;
64
+ }
65
+ const errorPath = makeReadableErrorPath(ancestors);
66
+ throw new Error(
67
+ `Cannot find type for argument: ${errorPath.join(".")}.${node.name.value}`
68
+ );
69
+ }
70
+ },
71
+ Field: {
72
+ leave(node, _key, _parent, _path, ancestors) {
73
+ const fieldDef = typeInfo.getFieldDef();
74
+ if (fieldDef) {
75
+ const type = fieldDef.type;
76
+ if (type) {
77
+ const typeNode = generateTypeNode(type);
78
+ const missingArgs = fieldDef.args.filter(
79
+ (argDef) => {
80
+ var _a;
81
+ return argDef.defaultValue != null && ((_a = node.arguments) == null ? void 0 : _a.findIndex(
82
+ (arg) => arg.name.value === argDef.name
83
+ )) === -1;
84
+ }
85
+ );
86
+ const newNode = __spreadProps(__spreadValues({}, node), {
87
+ __type: typeNode
88
+ });
89
+ if (missingArgs) {
90
+ newNode.arguments = (newNode.arguments || []).concat(
91
+ missingArgs.map((arg) => ({
92
+ __type: generateTypeNode(arg.type),
93
+ kind: import_graphql.Kind.ARGUMENT,
94
+ name: {
95
+ kind: import_graphql.Kind.NAME,
96
+ value: arg.name
97
+ },
98
+ value: (0, import_graphql.astFromValue)(
99
+ arg.defaultValue,
100
+ arg.type
101
+ )
102
+ }))
103
+ );
104
+ }
105
+ return newNode;
106
+ }
107
+ }
108
+ const errorPath = makeReadableErrorPath(ancestors);
109
+ throw new Error(
110
+ `Cannot find type for field: ${errorPath.join(".")}.${node.name.value}`
111
+ );
112
+ }
113
+ }
114
+ })
115
+ );
116
+ }
117
+ function generateTypeNode(type) {
118
+ if ((0, import_graphql.isNonNullType)(type)) {
119
+ const typeNode = generateTypeNode(type.ofType);
120
+ return {
121
+ kind: "NonNullType",
122
+ type: typeNode
123
+ };
124
+ } else if ((0, import_graphql.isListType)(type)) {
125
+ const typeNode = generateTypeNode(type.ofType);
126
+ return {
127
+ kind: "ListType",
128
+ type: typeNode
129
+ };
130
+ } else if ((0, import_graphql.isNamedType)(type)) {
131
+ return {
132
+ kind: "NamedType",
133
+ name: {
134
+ kind: "Name",
135
+ value: type.name
136
+ }
137
+ };
138
+ }
139
+ throw new Error(`Can't generate TypeNode for type: ${type}`);
140
+ }
141
+ function makeReadableErrorPath(ancestors) {
142
+ const path = [];
143
+ ancestors.forEach((ancestorOrArray) => {
144
+ let ancestor;
145
+ if (!Array.isArray(ancestorOrArray)) {
146
+ ancestor = ancestorOrArray;
147
+ if (ancestor && ancestor.kind === import_graphql.Kind.FIELD) {
148
+ path.push(ancestor.name.value);
149
+ } else if (ancestor && ancestor.kind === import_graphql.Kind.OPERATION_DEFINITION) {
150
+ let name;
151
+ if (ancestor.name) {
152
+ name = `${ancestor.operation} ${ancestor.name.value}`;
153
+ } else {
154
+ name = ancestor.operation;
155
+ }
156
+ path.push(name);
157
+ }
158
+ }
159
+ });
160
+ return path;
161
+ }
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/legacyAST/addTypesToRequestDocument.ts"],
4
+ "sourcesContent": ["import {\n GraphQLType,\n GraphQLSchema,\n isListType,\n isNamedType,\n isNonNullType,\n TypeInfo,\n visit,\n visitWithTypeInfo,\n Kind,\n astFromValue,\n GraphQLArgument,\n} from \"graphql\";\n\nimport * as TypelessAST from \"graphql/language/ast\";\nimport * as TypedAST from \"./TypedAST\";\nexport * from \"./TypedAST\";\n\nexport function addTypesToRequestDocument(\n schema: GraphQLSchema,\n document: TypelessAST.DocumentNode,\n): TypedAST.DocumentNode {\n const typeInfo = new TypeInfo(schema);\n return visit(\n document,\n visitWithTypeInfo(typeInfo, {\n Argument: {\n leave(node, _key, _parent, _path, ancestors) {\n const argument = typeInfo.getArgument();\n if (argument) {\n const typeNode = generateTypeNode(argument.type);\n const newNode: TypedAST.ArgumentNode = {\n ...node,\n __type: typeNode,\n };\n // We only need default value for arguments with variable values\n if (argument.defaultValue && node.value.kind === Kind.VARIABLE) {\n (newNode.__defaultValue as\n | TypedAST.ValueNode\n | null\n | undefined) = astFromValue(\n argument.defaultValue,\n argument.type,\n );\n }\n return newNode;\n }\n const errorPath = makeReadableErrorPath(ancestors);\n throw new Error(\n `Cannot find type for argument: ${errorPath.join(\".\")}.${\n node.name.value\n }`,\n );\n },\n },\n Field: {\n leave(\n node: Omit<TypelessAST.FieldNode, \"selectionSet\" | \"directives\">,\n _key,\n _parent,\n _path,\n ancestors,\n ) {\n const fieldDef = typeInfo.getFieldDef();\n if (fieldDef) {\n const type = fieldDef.type;\n if (type) {\n const typeNode = generateTypeNode(type);\n const missingArgs: Array<GraphQLArgument> = fieldDef.args.filter(\n (argDef) =>\n argDef.defaultValue != null &&\n node.arguments?.findIndex(\n (arg) => arg.name.value === argDef.name,\n ) === -1,\n );\n const newNode: TypedAST.FieldNode = {\n ...(node as Omit<\n TypelessAST.FieldNode,\n \"selectionSet\" | \"arguments\" | \"directives\"\n >),\n __type: typeNode,\n };\n if (missingArgs) {\n (newNode.arguments as TypedAST.ArgumentNode[]) = (\n newNode.arguments || []\n ).concat(\n missingArgs.map((arg) => ({\n __type: generateTypeNode(arg.type),\n kind: Kind.ARGUMENT,\n name: {\n kind: Kind.NAME,\n value: arg.name,\n },\n value: astFromValue(\n arg.defaultValue,\n arg.type,\n ) as TypedAST.ValueNode,\n })),\n );\n }\n return newNode;\n }\n }\n\n const errorPath = makeReadableErrorPath(ancestors);\n\n // This happens whenever a new field is requested that hasn't been defined in schema\n throw new Error(\n `Cannot find type for field: ${errorPath.join(\".\")}.${\n node.name.value\n }`,\n );\n },\n },\n }),\n );\n}\n\nfunction generateTypeNode(type: GraphQLType): TypedAST.TypeNode {\n if (isNonNullType(type)) {\n const typeNode = generateTypeNode(type.ofType) as\n | TypedAST.NamedTypeNode\n | TypedAST.ListTypeNode;\n return {\n kind: \"NonNullType\",\n type: typeNode,\n };\n } else if (isListType(type)) {\n const typeNode = generateTypeNode(type.ofType) as\n | TypedAST.NamedTypeNode\n | TypedAST.NonNullTypeNode;\n return {\n kind: \"ListType\",\n type: typeNode,\n };\n } else if (isNamedType(type)) {\n return {\n kind: \"NamedType\",\n name: {\n kind: \"Name\",\n value: type.name,\n },\n };\n }\n throw new Error(`Can't generate TypeNode for type: ${type}`);\n}\n\nfunction makeReadableErrorPath(\n ancestors: ReadonlyArray<\n readonly TypelessAST.ASTNode[] | TypelessAST.ASTNode\n >,\n): string[] {\n const path: string[] = [];\n ancestors.forEach((ancestorOrArray) => {\n let ancestor: TypelessAST.ASTNode;\n if (!Array.isArray(ancestorOrArray)) {\n ancestor = ancestorOrArray as TypelessAST.ASTNode;\n if (ancestor && ancestor.kind === Kind.FIELD) {\n path.push(ancestor.name.value);\n } else if (ancestor && ancestor.kind === Kind.OPERATION_DEFINITION) {\n let name;\n if (ancestor.name) {\n name = `${ancestor.operation} ${ancestor.name.value}`;\n } else {\n name = ancestor.operation;\n }\n path.push(name);\n }\n }\n });\n return path;\n}\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,qBAYO;AAIP,8CAAc,uBAhBd;AAkBO,SAAS,0BACd,QACA,UACuB;AACvB,QAAM,WAAW,IAAI,wBAAS,MAAM;AACpC,aAAO;AAAA,IACL;AAAA,QACA,kCAAkB,UAAU;AAAA,MAC1B,UAAU;AAAA,QACR,MAAM,MAAM,MAAM,SAAS,OAAO,WAAW;AAC3C,gBAAM,WAAW,SAAS,YAAY;AACtC,cAAI,UAAU;AACZ,kBAAM,WAAW,iBAAiB,SAAS,IAAI;AAC/C,kBAAM,UAAiC,iCAClC,OADkC;AAAA,cAErC,QAAQ;AAAA,YACV;AAEA,gBAAI,SAAS,gBAAgB,KAAK,MAAM,SAAS,oBAAK,UAAU;AAC9D,cAAC,QAAQ,qBAGQ;AAAA,gBACf,SAAS;AAAA,gBACT,SAAS;AAAA,cACX;AAAA,YACF;AACA,mBAAO;AAAA,UACT;AACA,gBAAM,YAAY,sBAAsB,SAAS;AACjD,gBAAM,IAAI;AAAA,YACR,kCAAkC,UAAU,KAAK,GAAG,KAClD,KAAK,KAAK;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