houdini 1.2.4 → 1.2.6-next.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 (47) hide show
  1. package/build/cmd-cjs/index.js +610 -555
  2. package/build/cmd-esm/index.js +610 -555
  3. package/build/codegen/generators/artifacts/selection.d.ts +1 -3
  4. package/build/codegen-cjs/index.js +595 -542
  5. package/build/codegen-esm/index.js +595 -542
  6. package/build/lib-cjs/index.js +38 -3
  7. package/build/lib-esm/index.js +38 -3
  8. package/build/runtime/cache/cache.d.ts +1 -0
  9. package/build/runtime/cache/gc.d.ts +1 -0
  10. package/build/runtime/cache/lists.d.ts +1 -0
  11. package/build/runtime/cache/staleManager.d.ts +1 -0
  12. package/build/runtime/cache/storage.d.ts +1 -0
  13. package/build/runtime/cache/subscription.d.ts +2 -1
  14. package/build/runtime/public/cache.d.ts +4 -0
  15. package/build/runtime-cjs/cache/cache.d.ts +1 -0
  16. package/build/runtime-cjs/cache/cache.js +10 -2
  17. package/build/runtime-cjs/cache/gc.d.ts +1 -0
  18. package/build/runtime-cjs/cache/gc.js +3 -0
  19. package/build/runtime-cjs/cache/lists.d.ts +1 -0
  20. package/build/runtime-cjs/cache/lists.js +4 -0
  21. package/build/runtime-cjs/cache/staleManager.d.ts +1 -0
  22. package/build/runtime-cjs/cache/staleManager.js +3 -0
  23. package/build/runtime-cjs/cache/storage.d.ts +1 -0
  24. package/build/runtime-cjs/cache/storage.js +3 -0
  25. package/build/runtime-cjs/cache/subscription.d.ts +2 -1
  26. package/build/runtime-cjs/cache/subscription.js +13 -0
  27. package/build/runtime-cjs/public/cache.d.ts +4 -0
  28. package/build/runtime-cjs/public/cache.js +3 -0
  29. package/build/runtime-esm/cache/cache.d.ts +1 -0
  30. package/build/runtime-esm/cache/cache.js +10 -2
  31. package/build/runtime-esm/cache/gc.d.ts +1 -0
  32. package/build/runtime-esm/cache/gc.js +3 -0
  33. package/build/runtime-esm/cache/lists.d.ts +1 -0
  34. package/build/runtime-esm/cache/lists.js +4 -0
  35. package/build/runtime-esm/cache/staleManager.d.ts +1 -0
  36. package/build/runtime-esm/cache/staleManager.js +3 -0
  37. package/build/runtime-esm/cache/storage.d.ts +1 -0
  38. package/build/runtime-esm/cache/storage.js +3 -0
  39. package/build/runtime-esm/cache/subscription.d.ts +2 -1
  40. package/build/runtime-esm/cache/subscription.js +13 -0
  41. package/build/runtime-esm/public/cache.d.ts +4 -0
  42. package/build/runtime-esm/public/cache.js +3 -0
  43. package/build/test-cjs/index.js +600 -545
  44. package/build/test-esm/index.js +600 -545
  45. package/build/vite-cjs/index.js +615 -560
  46. package/build/vite-esm/index.js +615 -560
  47. package/package.json +1 -1
@@ -3725,12 +3725,12 @@ var require_parser = __commonJS({
3725
3725
  return [];
3726
3726
  }
3727
3727
  if (((_this$_options2 = this._options) === null || _this$_options2 === void 0 ? void 0 : _this$_options2.allowLegacySDLImplementsInterfaces) === true) {
3728
- var types18 = [];
3728
+ var types17 = [];
3729
3729
  this.expectOptionalToken(_tokenKind.TokenKind.AMP);
3730
3730
  do {
3731
- types18.push(this.parseNamedType());
3731
+ types17.push(this.parseNamedType());
3732
3732
  } while (this.expectOptionalToken(_tokenKind.TokenKind.AMP) || this.peek(_tokenKind.TokenKind.NAME));
3733
- return types18;
3733
+ return types17;
3734
3734
  }
3735
3735
  return this.delimitedMany(_tokenKind.TokenKind.AMP, this.parseNamedType);
3736
3736
  };
@@ -3809,13 +3809,13 @@ var require_parser = __commonJS({
3809
3809
  this.expectKeyword("union");
3810
3810
  var name = this.parseName();
3811
3811
  var directives = this.parseDirectives(true);
3812
- var types18 = this.parseUnionMemberTypes();
3812
+ var types17 = this.parseUnionMemberTypes();
3813
3813
  return {
3814
3814
  kind: _kinds.Kind.UNION_TYPE_DEFINITION,
3815
3815
  description,
3816
3816
  name,
3817
3817
  directives,
3818
- types: types18,
3818
+ types: types17,
3819
3819
  loc: this.loc(start)
3820
3820
  };
3821
3821
  };
@@ -3973,15 +3973,15 @@ var require_parser = __commonJS({
3973
3973
  this.expectKeyword("union");
3974
3974
  var name = this.parseName();
3975
3975
  var directives = this.parseDirectives(true);
3976
- var types18 = this.parseUnionMemberTypes();
3977
- if (directives.length === 0 && types18.length === 0) {
3976
+ var types17 = this.parseUnionMemberTypes();
3977
+ if (directives.length === 0 && types17.length === 0) {
3978
3978
  throw this.unexpected();
3979
3979
  }
3980
3980
  return {
3981
3981
  kind: _kinds.Kind.UNION_TYPE_EXTENSION,
3982
3982
  name,
3983
3983
  directives,
3984
- types: types18,
3984
+ types: types17,
3985
3985
  loc: this.loc(start)
3986
3986
  };
3987
3987
  };
@@ -4959,8 +4959,8 @@ var require_printer = __commonJS({
4959
4959
  return join3(["interface", name, wrap2("implements ", join3(interfaces, " & ")), join3(directives, " "), block2(fields)], " ");
4960
4960
  }),
4961
4961
  UnionTypeDefinition: addDescription2(function(_ref27) {
4962
- var name = _ref27.name, directives = _ref27.directives, types18 = _ref27.types;
4963
- return join3(["union", name, join3(directives, " "), types18 && types18.length !== 0 ? "= " + join3(types18, " | ") : ""], " ");
4962
+ var name = _ref27.name, directives = _ref27.directives, types17 = _ref27.types;
4963
+ return join3(["union", name, join3(directives, " "), types17 && types17.length !== 0 ? "= " + join3(types17, " | ") : ""], " ");
4964
4964
  }),
4965
4965
  EnumTypeDefinition: addDescription2(function(_ref28) {
4966
4966
  var name = _ref28.name, directives = _ref28.directives, values = _ref28.values;
@@ -4995,8 +4995,8 @@ var require_printer = __commonJS({
4995
4995
  return join3(["extend interface", name, wrap2("implements ", join3(interfaces, " & ")), join3(directives, " "), block2(fields)], " ");
4996
4996
  },
4997
4997
  UnionTypeExtension: function UnionTypeExtension(_ref36) {
4998
- var name = _ref36.name, directives = _ref36.directives, types18 = _ref36.types;
4999
- return join3(["extend union", name, join3(directives, " "), types18 && types18.length !== 0 ? "= " + join3(types18, " | ") : ""], " ");
4998
+ var name = _ref36.name, directives = _ref36.directives, types17 = _ref36.types;
4999
+ return join3(["extend union", name, join3(directives, " "), types17 && types17.length !== 0 ? "= " + join3(types17, " | ") : ""], " ");
5000
5000
  },
5001
5001
  EnumTypeExtension: function EnumTypeExtension(_ref37) {
5002
5002
  var name = _ref37.name, directives = _ref37.directives, values = _ref37.values;
@@ -5667,9 +5667,9 @@ var require_definition = __commonJS({
5667
5667
  exports.GraphQLUnionType = GraphQLUnionType3;
5668
5668
  (0, _defineInspect.default)(GraphQLUnionType3);
5669
5669
  function defineTypes(config2) {
5670
- var types18 = resolveThunk(config2.types);
5671
- Array.isArray(types18) || (0, _devAssert.default)(0, "Must provide Array of types or a function which returns such an array for Union ".concat(config2.name, "."));
5672
- return types18;
5670
+ var types17 = resolveThunk(config2.types);
5671
+ Array.isArray(types17) || (0, _devAssert.default)(0, "Must provide Array of types or a function which returns such an array for Union ".concat(config2.name, "."));
5672
+ return types17;
5673
5673
  }
5674
5674
  var GraphQLEnumType4 = /* @__PURE__ */ function() {
5675
5675
  function GraphQLEnumType5(config2) {
@@ -13306,7 +13306,7 @@ var require_buildClientSchema = __commonJS({
13306
13306
  return new _definition.GraphQLUnionType({
13307
13307
  name: unionIntrospection.name,
13308
13308
  description: unionIntrospection.description,
13309
- types: function types18() {
13309
+ types: function types17() {
13310
13310
  return unionIntrospection.possibleTypes.map(getObjectType);
13311
13311
  }
13312
13312
  });
@@ -13651,7 +13651,7 @@ var require_extendSchema = __commonJS({
13651
13651
  var config2 = type.toConfig();
13652
13652
  var extensions = (_typeExtensionsMap$co5 = typeExtensionsMap[config2.name]) !== null && _typeExtensionsMap$co5 !== void 0 ? _typeExtensionsMap$co5 : [];
13653
13653
  return new _definition.GraphQLUnionType(_objectSpread(_objectSpread({}, config2), {}, {
13654
- types: function types18() {
13654
+ types: function types17() {
13655
13655
  return [].concat(type.getTypes().map(replaceNamedType), buildUnionTypes(extensions));
13656
13656
  },
13657
13657
  extensionASTNodes: config2.extensionASTNodes.concat(extensions)
@@ -13799,17 +13799,17 @@ var require_extendSchema = __commonJS({
13799
13799
  return interfaces;
13800
13800
  }
13801
13801
  function buildUnionTypes(nodes) {
13802
- var types18 = [];
13802
+ var types17 = [];
13803
13803
  for (var _i32 = 0; _i32 < nodes.length; _i32++) {
13804
13804
  var _node$types;
13805
13805
  var node = nodes[_i32];
13806
13806
  var typeNodes = (_node$types = node.types) !== null && _node$types !== void 0 ? _node$types : [];
13807
13807
  for (var _i34 = 0; _i34 < typeNodes.length; _i34++) {
13808
13808
  var type = typeNodes[_i34];
13809
- types18.push(getNamedType5(type));
13809
+ types17.push(getNamedType5(type));
13810
13810
  }
13811
13811
  }
13812
- return types18;
13812
+ return types17;
13813
13813
  }
13814
13814
  function buildType(astNode) {
13815
13815
  var _typeExtensionsMap$na;
@@ -13866,7 +13866,7 @@ var require_extendSchema = __commonJS({
13866
13866
  return new _definition.GraphQLUnionType({
13867
13867
  name: name2,
13868
13868
  description,
13869
- types: function types18() {
13869
+ types: function types17() {
13870
13870
  return buildUnionTypes(_allNodes3);
13871
13871
  },
13872
13872
  astNode,
@@ -14164,7 +14164,7 @@ var require_lexicographicSortSchema = __commonJS({
14164
14164
  if ((0, _definition.isUnionType)(type)) {
14165
14165
  var _config22 = type.toConfig();
14166
14166
  return new _definition.GraphQLUnionType(_objectSpread(_objectSpread({}, _config22), {}, {
14167
- types: function types18() {
14167
+ types: function types17() {
14168
14168
  return sortTypes(_config22.types);
14169
14169
  }
14170
14170
  }));
@@ -14249,10 +14249,10 @@ var require_printSchema = __commonJS({
14249
14249
  }
14250
14250
  function printFilteredSchema(schema, directiveFilter, typeFilter, options) {
14251
14251
  var directives = schema.getDirectives().filter(directiveFilter);
14252
- var types18 = (0, _objectValues.default)(schema.getTypeMap()).filter(typeFilter);
14252
+ var types17 = (0, _objectValues.default)(schema.getTypeMap()).filter(typeFilter);
14253
14253
  return [printSchemaDefinition(schema)].concat(directives.map(function(directive) {
14254
14254
  return printDirective(directive, options);
14255
- }), types18.map(function(type) {
14255
+ }), types17.map(function(type) {
14256
14256
  return printType(type, options);
14257
14257
  })).filter(Boolean).join("\n\n") + "\n";
14258
14258
  }
@@ -14327,8 +14327,8 @@ var require_printSchema = __commonJS({
14327
14327
  return printDescription(options, type) + "interface ".concat(type.name) + printImplementedInterfaces(type) + printFields(options, type);
14328
14328
  }
14329
14329
  function printUnion(type, options) {
14330
- var types18 = type.getTypes();
14331
- var possibleTypes = types18.length ? " = " + types18.join(" | ") : "";
14330
+ var types17 = type.getTypes();
14331
+ var possibleTypes = types17.length ? " = " + types17.join(" | ") : "";
14332
14332
  return printDescription(options, type) + "union " + type.name + possibleTypes;
14333
14333
  }
14334
14334
  function printEnum(type, options) {
@@ -30007,14 +30007,14 @@ var require_lib3 = __commonJS({
30007
30007
  this.preserveSpace = !!preserveSpace;
30008
30008
  }
30009
30009
  };
30010
- var types18 = {
30010
+ var types17 = {
30011
30011
  brace: new TokContext("{"),
30012
30012
  j_oTag: new TokContext("<tag"),
30013
30013
  j_cTag: new TokContext("</tag"),
30014
30014
  j_expr: new TokContext("<tag>...</tag>", true)
30015
30015
  };
30016
30016
  {
30017
- types18.template = new TokContext("`", true);
30017
+ types17.template = new TokContext("`", true);
30018
30018
  }
30019
30019
  var beforeExpr = true;
30020
30020
  var startsExpr = true;
@@ -30546,17 +30546,17 @@ var require_lib3 = __commonJS({
30546
30546
  context.pop();
30547
30547
  };
30548
30548
  tokenTypes[5].updateContext = tokenTypes[7].updateContext = tokenTypes[23].updateContext = (context) => {
30549
- context.push(types18.brace);
30549
+ context.push(types17.brace);
30550
30550
  };
30551
30551
  tokenTypes[22].updateContext = (context) => {
30552
- if (context[context.length - 1] === types18.template) {
30552
+ if (context[context.length - 1] === types17.template) {
30553
30553
  context.pop();
30554
30554
  } else {
30555
- context.push(types18.template);
30555
+ context.push(types17.template);
30556
30556
  }
30557
30557
  };
30558
30558
  tokenTypes[140].updateContext = (context) => {
30559
- context.push(types18.j_expr, types18.j_oTag);
30559
+ context.push(types17.j_expr, types17.j_oTag);
30560
30560
  };
30561
30561
  }
30562
30562
  var nonASCIIidentifierStartChars = "\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u0870-\u0887\u0889-\u088E\u08A0-\u08C9\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D04-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u1711\u171F-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1878\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4C\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5\u1CF6\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309B-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u31BF\u31F0-\u31FF\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7CA\uA7D0\uA7D1\uA7D3\uA7D5-\uA7D9\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB69\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC";
@@ -31197,7 +31197,7 @@ var require_lib3 = __commonJS({
31197
31197
  this.lastTokEndLoc = null;
31198
31198
  this.lastTokStartLoc = null;
31199
31199
  this.lastTokStart = 0;
31200
- this.context = [types18.brace];
31200
+ this.context = [types17.brace];
31201
31201
  this.canStartJSXElement = true;
31202
31202
  this.containsEsc = false;
31203
31203
  this.firstInvalidTemplateEscapePos = null;
@@ -35121,7 +35121,7 @@ var require_lib3 = __commonJS({
35121
35121
  context
35122
35122
  } = this.state;
35123
35123
  const currentContext = context[context.length - 1];
35124
- if (currentContext === types18.j_oTag || currentContext === types18.j_expr) {
35124
+ if (currentContext === types17.j_oTag || currentContext === types17.j_expr) {
35125
35125
  context.pop();
35126
35126
  }
35127
35127
  }
@@ -36181,9 +36181,9 @@ var require_lib3 = __commonJS({
36181
36181
  switch (this.state.type) {
36182
36182
  case 5:
36183
36183
  node = this.startNode();
36184
- this.setContext(types18.brace);
36184
+ this.setContext(types17.brace);
36185
36185
  this.next();
36186
- node = this.jsxParseExpressionContainer(node, types18.j_oTag);
36186
+ node = this.jsxParseExpressionContainer(node, types17.j_oTag);
36187
36187
  if (node.expression.type === "JSXEmptyExpression") {
36188
36188
  this.raise(JsxErrors.AttributeIsEmpty, {
36189
36189
  at: node
@@ -36206,7 +36206,7 @@ var require_lib3 = __commonJS({
36206
36206
  jsxParseSpreadChild(node) {
36207
36207
  this.next();
36208
36208
  node.expression = this.parseExpression();
36209
- this.setContext(types18.j_expr);
36209
+ this.setContext(types17.j_expr);
36210
36210
  this.state.canStartJSXElement = true;
36211
36211
  this.expect(8);
36212
36212
  return this.finishNode(node, "JSXSpreadChild");
@@ -36226,11 +36226,11 @@ var require_lib3 = __commonJS({
36226
36226
  jsxParseAttribute() {
36227
36227
  const node = this.startNode();
36228
36228
  if (this.match(5)) {
36229
- this.setContext(types18.brace);
36229
+ this.setContext(types17.brace);
36230
36230
  this.next();
36231
36231
  this.expect(21);
36232
36232
  node.argument = this.parseMaybeAssignAllowIn();
36233
- this.setContext(types18.j_oTag);
36233
+ this.setContext(types17.j_oTag);
36234
36234
  this.state.canStartJSXElement = true;
36235
36235
  this.expect(8);
36236
36236
  return this.finishNode(node, "JSXSpreadAttribute");
@@ -36289,12 +36289,12 @@ var require_lib3 = __commonJS({
36289
36289
  break;
36290
36290
  case 5: {
36291
36291
  const node2 = this.startNode();
36292
- this.setContext(types18.brace);
36292
+ this.setContext(types17.brace);
36293
36293
  this.next();
36294
36294
  if (this.match(21)) {
36295
36295
  children.push(this.jsxParseSpreadChild(node2));
36296
36296
  } else {
36297
- children.push(this.jsxParseExpressionContainer(node2, types18.j_expr));
36297
+ children.push(this.jsxParseExpressionContainer(node2, types17.j_expr));
36298
36298
  }
36299
36299
  break;
36300
36300
  }
@@ -36365,10 +36365,10 @@ var require_lib3 = __commonJS({
36365
36365
  }
36366
36366
  getTokenFromCode(code) {
36367
36367
  const context = this.curContext();
36368
- if (context === types18.j_expr) {
36368
+ if (context === types17.j_expr) {
36369
36369
  return this.jsxReadToken();
36370
36370
  }
36371
- if (context === types18.j_oTag || context === types18.j_cTag) {
36371
+ if (context === types17.j_oTag || context === types17.j_cTag) {
36372
36372
  if (isIdentifierStart(code)) {
36373
36373
  return this.jsxReadWord();
36374
36374
  }
@@ -36376,7 +36376,7 @@ var require_lib3 = __commonJS({
36376
36376
  ++this.state.pos;
36377
36377
  return this.finishToken(141);
36378
36378
  }
36379
- if ((code === 34 || code === 39) && context === types18.j_oTag) {
36379
+ if ((code === 34 || code === 39) && context === types17.j_oTag) {
36380
36380
  return this.jsxReadString(code);
36381
36381
  }
36382
36382
  }
@@ -36392,17 +36392,17 @@ var require_lib3 = __commonJS({
36392
36392
  type
36393
36393
  } = this.state;
36394
36394
  if (type === 56 && prevType === 140) {
36395
- context.splice(-2, 2, types18.j_cTag);
36395
+ context.splice(-2, 2, types17.j_cTag);
36396
36396
  this.state.canStartJSXElement = false;
36397
36397
  } else if (type === 140) {
36398
- context.push(types18.j_oTag);
36398
+ context.push(types17.j_oTag);
36399
36399
  } else if (type === 141) {
36400
36400
  const out = context[context.length - 1];
36401
- if (out === types18.j_oTag && prevType === 56 || out === types18.j_cTag) {
36401
+ if (out === types17.j_oTag && prevType === 56 || out === types17.j_cTag) {
36402
36402
  context.pop();
36403
- this.state.canStartJSXElement = context[context.length - 1] === types18.j_expr;
36403
+ this.state.canStartJSXElement = context[context.length - 1] === types17.j_expr;
36404
36404
  } else {
36405
- this.setContext(types18.j_expr);
36405
+ this.setContext(types17.j_expr);
36406
36406
  this.state.canStartJSXElement = true;
36407
36407
  }
36408
36408
  } else {
@@ -37410,14 +37410,14 @@ var require_lib3 = __commonJS({
37410
37410
  tsParseUnionOrIntersectionType(kind, parseConstituentType, operator) {
37411
37411
  const node = this.startNode();
37412
37412
  const hasLeadingOperator = this.eat(operator);
37413
- const types19 = [];
37413
+ const types18 = [];
37414
37414
  do {
37415
- types19.push(parseConstituentType());
37415
+ types18.push(parseConstituentType());
37416
37416
  } while (this.eat(operator));
37417
- if (types19.length === 1 && !hasLeadingOperator) {
37418
- return types19[0];
37417
+ if (types18.length === 1 && !hasLeadingOperator) {
37418
+ return types18[0];
37419
37419
  }
37420
- node.types = types19;
37420
+ node.types = types18;
37421
37421
  return this.finishNode(node, kind);
37422
37422
  }
37423
37423
  tsParseIntersectionTypeOrHigher() {
@@ -38646,7 +38646,7 @@ var require_lib3 = __commonJS({
38646
38646
  context
38647
38647
  } = this.state;
38648
38648
  const currentContext = context[context.length - 1];
38649
- if (currentContext === types18.j_oTag || currentContext === types18.j_expr) {
38649
+ if (currentContext === types17.j_oTag || currentContext === types17.j_expr) {
38650
38650
  context.pop();
38651
38651
  }
38652
38652
  }
@@ -44285,9 +44285,9 @@ var require_shared = __commonJS({
44285
44285
  var tslib_1 = require_tslib();
44286
44286
  var types_1 = tslib_1.__importDefault(require_types());
44287
44287
  function default_1(fork) {
44288
- var types18 = fork.use(types_1.default);
44289
- var Type = types18.Type;
44290
- var builtin = types18.builtInTypes;
44288
+ var types17 = fork.use(types_1.default);
44289
+ var Type = types17.Type;
44290
+ var builtin = types17.builtInTypes;
44291
44291
  var isNumber = builtin.number;
44292
44292
  function geq(than) {
44293
44293
  return Type.from(function(value) {
@@ -44437,9 +44437,9 @@ var require_types = __commonJS({
44437
44437
  }(BaseType);
44438
44438
  var OrType = function(_super) {
44439
44439
  tslib_1.__extends(OrType2, _super);
44440
- function OrType2(types18) {
44440
+ function OrType2(types17) {
44441
44441
  var _this = _super.call(this) || this;
44442
- _this.types = types18;
44442
+ _this.types = types17;
44443
44443
  _this.kind = "OrType";
44444
44444
  return _this;
44445
44445
  }
@@ -44580,11 +44580,11 @@ var require_types = __commonJS({
44580
44580
  function typesPlugin(_fork) {
44581
44581
  var Type = {
44582
44582
  or: function() {
44583
- var types18 = [];
44583
+ var types17 = [];
44584
44584
  for (var _i = 0; _i < arguments.length; _i++) {
44585
- types18[_i] = arguments[_i];
44585
+ types17[_i] = arguments[_i];
44586
44586
  }
44587
- return new OrType(types18.map(function(type) {
44587
+ return new OrType(types17.map(function(type) {
44588
44588
  return Type.from(type);
44589
44589
  }));
44590
44590
  },
@@ -45029,9 +45029,9 @@ var require_path2 = __commonJS({
45029
45029
  var Op = Object.prototype;
45030
45030
  var hasOwn = Op.hasOwnProperty;
45031
45031
  function pathPlugin(fork) {
45032
- var types18 = fork.use(types_1.default);
45033
- var isArray = types18.builtInTypes.array;
45034
- var isNumber = types18.builtInTypes.number;
45032
+ var types17 = fork.use(types_1.default);
45033
+ var isArray = types17.builtInTypes.array;
45034
+ var isNumber = types17.builtInTypes.number;
45035
45035
  var Path = function Path2(value, parentPath, name) {
45036
45036
  if (!(this instanceof Path2)) {
45037
45037
  throw new Error("Path constructor cannot be invoked without 'new'");
@@ -45333,13 +45333,13 @@ var require_scope = __commonJS({
45333
45333
  var types_1 = tslib_1.__importDefault(require_types());
45334
45334
  var hasOwn = Object.prototype.hasOwnProperty;
45335
45335
  function scopePlugin(fork) {
45336
- var types18 = fork.use(types_1.default);
45337
- var Type = types18.Type;
45338
- var namedTypes = types18.namedTypes;
45336
+ var types17 = fork.use(types_1.default);
45337
+ var Type = types17.Type;
45338
+ var namedTypes = types17.namedTypes;
45339
45339
  var Node = namedTypes.Node;
45340
45340
  var Expression = namedTypes.Expression;
45341
- var isArray = types18.builtInTypes.array;
45342
- var b = types18.builders;
45341
+ var isArray = types17.builtInTypes.array;
45342
+ var b = types17.builders;
45343
45343
  var Scope = function Scope2(path2, parentScope) {
45344
45344
  if (!(this instanceof Scope2)) {
45345
45345
  throw new Error("Scope constructor cannot be invoked without 'new'");
@@ -45402,7 +45402,7 @@ var require_scope = __commonJS({
45402
45402
  ++index;
45403
45403
  }
45404
45404
  var name = prefix + index;
45405
- return this.bindings[name] = types18.builders.identifier(name);
45405
+ return this.bindings[name] = types17.builders.identifier(name);
45406
45406
  };
45407
45407
  Sp.injectTemporary = function(identifier, init2) {
45408
45408
  identifier || (identifier = this.declareTemporary());
@@ -45478,7 +45478,7 @@ var require_scope = __commonJS({
45478
45478
  bindings
45479
45479
  );
45480
45480
  } else if (Node.check(node) && !Expression.check(node)) {
45481
- types18.eachField(node, function(name, child) {
45481
+ types17.eachField(node, function(name, child) {
45482
45482
  var childPath = path2.get(name);
45483
45483
  if (!pathHasValue(childPath, child)) {
45484
45484
  throw new Error("");
@@ -45556,24 +45556,24 @@ var require_scope = __commonJS({
45556
45556
  addPattern(patternPath.get("argument"), bindings);
45557
45557
  }
45558
45558
  }
45559
- function addTypePattern(patternPath, types19) {
45559
+ function addTypePattern(patternPath, types18) {
45560
45560
  var pattern = patternPath.value;
45561
45561
  namedTypes.Pattern.assert(pattern);
45562
45562
  if (namedTypes.Identifier.check(pattern)) {
45563
- if (hasOwn.call(types19, pattern.name)) {
45564
- types19[pattern.name].push(patternPath);
45563
+ if (hasOwn.call(types18, pattern.name)) {
45564
+ types18[pattern.name].push(patternPath);
45565
45565
  } else {
45566
- types19[pattern.name] = [patternPath];
45566
+ types18[pattern.name] = [patternPath];
45567
45567
  }
45568
45568
  }
45569
45569
  }
45570
- function addTypeParameter(parameterPath, types19) {
45570
+ function addTypeParameter(parameterPath, types18) {
45571
45571
  var parameter = parameterPath.value;
45572
45572
  FlowOrTSTypeParameterType.assert(parameter);
45573
- if (hasOwn.call(types19, parameter.name)) {
45574
- types19[parameter.name].push(parameterPath);
45573
+ if (hasOwn.call(types18, parameter.name)) {
45574
+ types18[parameter.name].push(parameterPath);
45575
45575
  } else {
45576
- types19[parameter.name] = [parameterPath];
45576
+ types18[parameter.name] = [parameterPath];
45577
45577
  }
45578
45578
  }
45579
45579
  Sp.lookup = function(name) {
@@ -45614,11 +45614,11 @@ var require_node_path = __commonJS({
45614
45614
  var scope_1 = tslib_1.__importDefault(require_scope());
45615
45615
  var shared_1 = require_shared();
45616
45616
  function nodePathPlugin(fork) {
45617
- var types18 = fork.use(types_1.default);
45618
- var n = types18.namedTypes;
45619
- var b = types18.builders;
45620
- var isNumber = types18.builtInTypes.number;
45621
- var isArray = types18.builtInTypes.array;
45617
+ var types17 = fork.use(types_1.default);
45618
+ var n = types17.namedTypes;
45619
+ var b = types17.builders;
45620
+ var isNumber = types17.builtInTypes.number;
45621
+ var isArray = types17.builtInTypes.array;
45622
45622
  var Path = fork.use(path_1.default);
45623
45623
  var Scope = fork.use(scope_1.default);
45624
45624
  var NodePath = function NodePath2(value, parentPath, name) {
@@ -45709,7 +45709,7 @@ var require_node_path = __commonJS({
45709
45709
  return scope || null;
45710
45710
  };
45711
45711
  NPp.getValueProperty = function(name) {
45712
- return types18.getFieldValue(this.value, name);
45712
+ return types17.getFieldValue(this.value, name);
45713
45713
  };
45714
45714
  NPp.needsParens = function(assumeExpressionContext) {
45715
45715
  var pp = this.parentPath;
@@ -45851,7 +45851,7 @@ var require_node_path = __commonJS({
45851
45851
  return node.some(containsCallExpression);
45852
45852
  }
45853
45853
  if (n.Node.check(node)) {
45854
- return types18.someField(node, function(_name, child) {
45854
+ return types17.someField(node, function(_name, child) {
45855
45855
  return containsCallExpression(child);
45856
45856
  });
45857
45857
  }
@@ -45972,11 +45972,11 @@ var require_path_visitor = __commonJS({
45972
45972
  var shared_1 = require_shared();
45973
45973
  var hasOwn = Object.prototype.hasOwnProperty;
45974
45974
  function pathVisitorPlugin(fork) {
45975
- var types18 = fork.use(types_1.default);
45975
+ var types17 = fork.use(types_1.default);
45976
45976
  var NodePath = fork.use(node_path_1.default);
45977
- var isArray = types18.builtInTypes.array;
45978
- var isObject2 = types18.builtInTypes.object;
45979
- var isFunction = types18.builtInTypes.function;
45977
+ var isArray = types17.builtInTypes.array;
45978
+ var isObject2 = types17.builtInTypes.object;
45979
+ var isFunction = types17.builtInTypes.function;
45980
45980
  var undefined2;
45981
45981
  var PathVisitor = function PathVisitor2() {
45982
45982
  if (!(this instanceof PathVisitor2)) {
@@ -45996,7 +45996,7 @@ var require_path_visitor = __commonJS({
45996
45996
  typeNames[methodName.slice("visit".length)] = true;
45997
45997
  }
45998
45998
  }
45999
- var supertypeTable = types18.computeSupertypeLookupTable(typeNames);
45999
+ var supertypeTable = types17.computeSupertypeLookupTable(typeNames);
46000
46000
  var methodNameTable = /* @__PURE__ */ Object.create(null);
46001
46001
  var typeNameKeys = Object.keys(supertypeTable);
46002
46002
  var typeNameCount = typeNameKeys.length;
@@ -46115,7 +46115,7 @@ var require_path_visitor = __commonJS({
46115
46115
  path2.each(visitor.visitWithoutReset, visitor);
46116
46116
  } else if (!isObject2.check(value)) {
46117
46117
  } else {
46118
- var childNames = types18.getFieldNames(value);
46118
+ var childNames = types17.getFieldNames(value);
46119
46119
  if (visitor._shouldVisitComments && value.comments && childNames.indexOf("comments") < 0) {
46120
46120
  childNames.push("comments");
46121
46121
  }
@@ -46124,7 +46124,7 @@ var require_path_visitor = __commonJS({
46124
46124
  for (var i2 = 0; i2 < childCount; ++i2) {
46125
46125
  var childName = childNames[i2];
46126
46126
  if (!hasOwn.call(value, childName)) {
46127
- value[childName] = types18.getFieldValue(value, childName);
46127
+ value[childName] = types17.getFieldValue(value, childName);
46128
46128
  }
46129
46129
  childPaths.push(path2.get(childName));
46130
46130
  }
@@ -46267,13 +46267,13 @@ var require_equiv = __commonJS({
46267
46267
  var shared_1 = require_shared();
46268
46268
  var types_1 = tslib_1.__importDefault(require_types());
46269
46269
  function default_1(fork) {
46270
- var types18 = fork.use(types_1.default);
46271
- var getFieldNames = types18.getFieldNames;
46272
- var getFieldValue = types18.getFieldValue;
46273
- var isArray = types18.builtInTypes.array;
46274
- var isObject2 = types18.builtInTypes.object;
46275
- var isDate = types18.builtInTypes.Date;
46276
- var isRegExp = types18.builtInTypes.RegExp;
46270
+ var types17 = fork.use(types_1.default);
46271
+ var getFieldNames = types17.getFieldNames;
46272
+ var getFieldValue = types17.getFieldValue;
46273
+ var isArray = types17.builtInTypes.array;
46274
+ var isObject2 = types17.builtInTypes.object;
46275
+ var isDate = types17.builtInTypes.Date;
46276
+ var isRegExp = types17.builtInTypes.RegExp;
46277
46277
  var hasOwn = Object.prototype.hasOwnProperty;
46278
46278
  function astNodesAreEquivalent(a, b, problemPath) {
46279
46279
  if (isArray.check(problemPath)) {
@@ -46426,24 +46426,24 @@ var require_fork = __commonJS({
46426
46426
  var shared_1 = require_shared();
46427
46427
  function default_1(plugins) {
46428
46428
  var fork = createFork();
46429
- var types18 = fork.use(types_1.default);
46429
+ var types17 = fork.use(types_1.default);
46430
46430
  plugins.forEach(fork.use);
46431
- types18.finalize();
46431
+ types17.finalize();
46432
46432
  var PathVisitor = fork.use(path_visitor_1.default);
46433
46433
  return {
46434
- Type: types18.Type,
46435
- builtInTypes: types18.builtInTypes,
46436
- namedTypes: types18.namedTypes,
46437
- builders: types18.builders,
46438
- defineMethod: types18.defineMethod,
46439
- getFieldNames: types18.getFieldNames,
46440
- getFieldValue: types18.getFieldValue,
46441
- eachField: types18.eachField,
46442
- someField: types18.someField,
46443
- getSupertypeNames: types18.getSupertypeNames,
46444
- getBuilderName: types18.getBuilderName,
46434
+ Type: types17.Type,
46435
+ builtInTypes: types17.builtInTypes,
46436
+ namedTypes: types17.namedTypes,
46437
+ builders: types17.builders,
46438
+ defineMethod: types17.defineMethod,
46439
+ getFieldNames: types17.getFieldNames,
46440
+ getFieldValue: types17.getFieldValue,
46441
+ eachField: types17.eachField,
46442
+ someField: types17.someField,
46443
+ getSupertypeNames: types17.getSupertypeNames,
46444
+ getBuilderName: types17.getBuilderName,
46445
46445
  astNodesAreEquivalent: fork.use(equiv_1.default),
46446
- finalize: types18.finalize,
46446
+ finalize: types17.finalize,
46447
46447
  Path: fork.use(path_1.default),
46448
46448
  NodePath: fork.use(node_path_1.default),
46449
46449
  PathVisitor,
@@ -46613,8 +46613,8 @@ var require_core2 = __commonJS({
46613
46613
  var types_1 = tslib_1.__importDefault(require_types());
46614
46614
  var shared_1 = tslib_1.__importStar(require_shared());
46615
46615
  function default_1(fork) {
46616
- var types18 = fork.use(types_1.default);
46617
- var Type = types18.Type;
46616
+ var types17 = fork.use(types_1.default);
46617
+ var Type = types17.Type;
46618
46618
  var def = Type.def;
46619
46619
  var or = Type.or;
46620
46620
  var shared = fork.use(shared_1.default);
@@ -46706,9 +46706,9 @@ var require_es6 = __commonJS({
46706
46706
  var shared_1 = tslib_1.__importStar(require_shared());
46707
46707
  function default_1(fork) {
46708
46708
  fork.use(core_1.default);
46709
- var types18 = fork.use(types_1.default);
46710
- var def = types18.Type.def;
46711
- var or = types18.Type.or;
46709
+ var types17 = fork.use(types_1.default);
46710
+ var def = types17.Type.def;
46711
+ var or = types17.Type.or;
46712
46712
  var defaults = fork.use(shared_1.default).defaults;
46713
46713
  def("Function").field("generator", Boolean, defaults["false"]).field("expression", Boolean, defaults["false"]).field("defaults", [or(def("Expression"), null)], defaults.emptyArray).field("rest", or(def("Identifier"), null), defaults["null"]);
46714
46714
  def("RestElement").bases("Pattern").build("argument").field("argument", def("Pattern")).field(
@@ -46798,8 +46798,8 @@ var require_es2017 = __commonJS({
46798
46798
  var shared_1 = tslib_1.__importStar(require_shared());
46799
46799
  function default_1(fork) {
46800
46800
  fork.use(es2016_1.default);
46801
- var types18 = fork.use(types_1.default);
46802
- var def = types18.Type.def;
46801
+ var types17 = fork.use(types_1.default);
46802
+ var def = types17.Type.def;
46803
46803
  var defaults = fork.use(shared_1.default).defaults;
46804
46804
  def("Function").field("async", Boolean, defaults["false"]);
46805
46805
  def("AwaitExpression").bases("Expression").build("argument").field("argument", def("Expression"));
@@ -46822,9 +46822,9 @@ var require_es2018 = __commonJS({
46822
46822
  var shared_1 = tslib_1.__importStar(require_shared());
46823
46823
  function default_1(fork) {
46824
46824
  fork.use(es2017_1.default);
46825
- var types18 = fork.use(types_1.default);
46826
- var def = types18.Type.def;
46827
- var or = types18.Type.or;
46825
+ var types17 = fork.use(types_1.default);
46826
+ var def = types17.Type.def;
46827
+ var or = types17.Type.or;
46828
46828
  var defaults = fork.use(shared_1.default).defaults;
46829
46829
  def("ForOfStatement").field("await", Boolean, defaults["false"]);
46830
46830
  def("SpreadProperty").bases("Node").build("argument").field("argument", def("Expression"));
@@ -46855,9 +46855,9 @@ var require_es2019 = __commonJS({
46855
46855
  var shared_1 = tslib_1.__importStar(require_shared());
46856
46856
  function default_1(fork) {
46857
46857
  fork.use(es2018_1.default);
46858
- var types18 = fork.use(types_1.default);
46859
- var def = types18.Type.def;
46860
- var or = types18.Type.or;
46858
+ var types17 = fork.use(types_1.default);
46859
+ var def = types17.Type.def;
46860
+ var or = types17.Type.or;
46861
46861
  var defaults = fork.use(shared_1.default).defaults;
46862
46862
  def("CatchClause").field("param", or(def("Pattern"), null), defaults["null"]);
46863
46863
  }
@@ -46881,9 +46881,9 @@ var require_es20202 = __commonJS({
46881
46881
  function default_1(fork) {
46882
46882
  fork.use(es2020_1.default);
46883
46883
  fork.use(es2019_1.default);
46884
- var types18 = fork.use(types_1.default);
46885
- var def = types18.Type.def;
46886
- var or = types18.Type.or;
46884
+ var types17 = fork.use(types_1.default);
46885
+ var def = types17.Type.def;
46886
+ var or = types17.Type.or;
46887
46887
  var shared = fork.use(shared_1.default);
46888
46888
  var defaults = shared.defaults;
46889
46889
  def("ImportExpression").bases("Expression").build("source").field("source", def("Expression"));
@@ -46933,8 +46933,8 @@ var require_es2022 = __commonJS({
46933
46933
  var shared_1 = require_shared();
46934
46934
  function default_1(fork) {
46935
46935
  fork.use(es2021_1.default);
46936
- var types18 = fork.use(types_1.default);
46937
- var def = types18.Type.def;
46936
+ var types17 = fork.use(types_1.default);
46937
+ var def = types17.Type.def;
46938
46938
  def("StaticBlock").bases("Declaration").build("body").field("body", [def("Statement")]);
46939
46939
  }
46940
46940
  exports.default = default_1;
@@ -46955,9 +46955,9 @@ var require_es_proposals = __commonJS({
46955
46955
  var es2022_1 = tslib_1.__importDefault(require_es2022());
46956
46956
  function default_1(fork) {
46957
46957
  fork.use(es2022_1.default);
46958
- var types18 = fork.use(types_1.default);
46959
- var Type = types18.Type;
46960
- var def = types18.Type.def;
46958
+ var types17 = fork.use(types_1.default);
46959
+ var Type = types17.Type;
46960
+ var def = types17.Type.def;
46961
46961
  var or = Type.or;
46962
46962
  var shared = fork.use(shared_1.default);
46963
46963
  var defaults = shared.defaults;
@@ -46997,9 +46997,9 @@ var require_jsx = __commonJS({
46997
46997
  var shared_1 = tslib_1.__importStar(require_shared());
46998
46998
  function default_1(fork) {
46999
46999
  fork.use(es_proposals_1.default);
47000
- var types18 = fork.use(types_1.default);
47001
- var def = types18.Type.def;
47002
- var or = types18.Type.or;
47000
+ var types17 = fork.use(types_1.default);
47001
+ var def = types17.Type.def;
47002
+ var or = types17.Type.or;
47003
47003
  var defaults = fork.use(shared_1.default).defaults;
47004
47004
  def("JSXAttribute").bases("Node").build("name", "value").field("name", or(def("JSXIdentifier"), def("JSXNamespacedName"))).field("value", or(
47005
47005
  def("Literal"),
@@ -47057,9 +47057,9 @@ var require_type_annotations = __commonJS({
47057
47057
  var types_1 = tslib_1.__importDefault(require_types());
47058
47058
  var shared_1 = tslib_1.__importStar(require_shared());
47059
47059
  function default_1(fork) {
47060
- var types18 = fork.use(types_1.default);
47061
- var def = types18.Type.def;
47062
- var or = types18.Type.or;
47060
+ var types17 = fork.use(types_1.default);
47061
+ var def = types17.Type.def;
47062
+ var or = types17.Type.or;
47063
47063
  var defaults = fork.use(shared_1.default).defaults;
47064
47064
  var TypeAnnotation = or(def("TypeAnnotation"), def("TSTypeAnnotation"), null);
47065
47065
  var TypeParamDecl = or(def("TypeParameterDeclaration"), def("TSTypeParameterDeclaration"), null);
@@ -47094,9 +47094,9 @@ var require_flow = __commonJS({
47094
47094
  function default_1(fork) {
47095
47095
  fork.use(es_proposals_1.default);
47096
47096
  fork.use(type_annotations_1.default);
47097
- var types18 = fork.use(types_1.default);
47098
- var def = types18.Type.def;
47099
- var or = types18.Type.or;
47097
+ var types17 = fork.use(types_1.default);
47098
+ var def = types17.Type.def;
47099
+ var or = types17.Type.or;
47100
47100
  var defaults = fork.use(shared_1.default).defaults;
47101
47101
  def("Flow").bases("Node");
47102
47102
  def("FlowType").bases("Flow");
@@ -47210,10 +47210,10 @@ var require_esprima = __commonJS({
47210
47210
  var shared_1 = tslib_1.__importStar(require_shared());
47211
47211
  function default_1(fork) {
47212
47212
  fork.use(es_proposals_1.default);
47213
- var types18 = fork.use(types_1.default);
47213
+ var types17 = fork.use(types_1.default);
47214
47214
  var defaults = fork.use(shared_1.default).defaults;
47215
- var def = types18.Type.def;
47216
- var or = types18.Type.or;
47215
+ var def = types17.Type.def;
47216
+ var or = types17.Type.or;
47217
47217
  def("VariableDeclaration").field("declarations", [or(
47218
47218
  def("VariableDeclarator"),
47219
47219
  def("Identifier")
@@ -47258,11 +47258,11 @@ var require_babel_core = __commonJS({
47258
47258
  function default_1(fork) {
47259
47259
  var _a, _b, _c, _d, _e;
47260
47260
  fork.use(es_proposals_1.default);
47261
- var types18 = fork.use(types_1.default);
47261
+ var types17 = fork.use(types_1.default);
47262
47262
  var defaults = fork.use(shared_1.default).defaults;
47263
- var def = types18.Type.def;
47264
- var or = types18.Type.or;
47265
- var isUndefined = types18.builtInTypes.undefined;
47263
+ var def = types17.Type.def;
47264
+ var or = types17.Type.or;
47265
+ var isUndefined = types17.builtInTypes.undefined;
47266
47266
  def("Noop").bases("Statement").build();
47267
47267
  def("DoExpression").bases("Expression").build("body").field("body", [def("Statement")]);
47268
47268
  def("BindExpression").bases("Expression").build("object", "callee").field("object", or(def("Expression"), null)).field("callee", def("Expression"));
@@ -47287,7 +47287,7 @@ var require_babel_core = __commonJS({
47287
47287
  raw: String
47288
47288
  },
47289
47289
  function getDefault() {
47290
- var value = types18.getFieldValue(this, "value");
47290
+ var value = types17.getFieldValue(this, "value");
47291
47291
  return {
47292
47292
  rawValue: value,
47293
47293
  raw: toRaw ? toRaw(value) : String(value)
@@ -47390,8 +47390,8 @@ var require_babel = __commonJS({
47390
47390
  var flow_1 = tslib_1.__importDefault(require_flow());
47391
47391
  var shared_1 = require_shared();
47392
47392
  function default_1(fork) {
47393
- var types18 = fork.use(types_1.default);
47394
- var def = types18.Type.def;
47393
+ var types17 = fork.use(types_1.default);
47394
+ var def = types17.Type.def;
47395
47395
  fork.use(babel_core_1.default);
47396
47396
  fork.use(flow_1.default);
47397
47397
  def("V8IntrinsicIdentifier").bases("Expression").build("name").field("name", String);
@@ -47417,12 +47417,12 @@ var require_typescript = __commonJS({
47417
47417
  function default_1(fork) {
47418
47418
  fork.use(babel_core_1.default);
47419
47419
  fork.use(type_annotations_1.default);
47420
- var types18 = fork.use(types_1.default);
47421
- var n = types18.namedTypes;
47422
- var def = types18.Type.def;
47423
- var or = types18.Type.or;
47420
+ var types17 = fork.use(types_1.default);
47421
+ var n = types17.namedTypes;
47422
+ var def = types17.Type.def;
47423
+ var or = types17.Type.or;
47424
47424
  var defaults = fork.use(shared_1.default).defaults;
47425
- var StringLiteral = types18.Type.from(function(value, deep) {
47425
+ var StringLiteral = types17.Type.from(function(value, deep) {
47426
47426
  if (n.StringLiteral && n.StringLiteral.check(value, deep)) {
47427
47427
  return true;
47428
47428
  }
@@ -49398,8 +49398,8 @@ var require_util2 = __commonJS({
49398
49398
  exports.isTrailingCommaEnabled = exports.getParentExportDeclaration = exports.isExportDeclaration = exports.fixFaultyLocations = exports.getTrueLoc = exports.composeSourceMaps = exports.copyPos = exports.comparePos = exports.getUnionOfKeys = exports.getOption = exports.isBrowser = exports.getLineTerminator = void 0;
49399
49399
  var tslib_1 = require_tslib();
49400
49400
  var assert_1 = tslib_1.__importDefault(require("assert"));
49401
- var types18 = tslib_1.__importStar(require_main());
49402
- var n = types18.namedTypes;
49401
+ var types17 = tslib_1.__importStar(require_main());
49402
+ var n = types17.namedTypes;
49403
49403
  var source_map_1 = tslib_1.__importDefault(require_source_map());
49404
49404
  var SourceMapConsumer = source_map_1.default.SourceMapConsumer;
49405
49405
  var SourceMapGenerator = source_map_1.default.SourceMapGenerator;
@@ -56717,10 +56717,10 @@ var require_comments = __commonJS({
56717
56717
  exports.printComments = exports.attach = void 0;
56718
56718
  var tslib_1 = require_tslib();
56719
56719
  var assert_1 = tslib_1.__importDefault(require("assert"));
56720
- var types18 = tslib_1.__importStar(require_main());
56721
- var n = types18.namedTypes;
56722
- var isArray = types18.builtInTypes.array;
56723
- var isObject2 = types18.builtInTypes.object;
56720
+ var types17 = tslib_1.__importStar(require_main());
56721
+ var n = types17.namedTypes;
56722
+ var isArray = types17.builtInTypes.array;
56723
+ var isObject2 = types17.builtInTypes.object;
56724
56724
  var lines_1 = require_lines();
56725
56725
  var util_1 = require_util2();
56726
56726
  var childNodesCache = /* @__PURE__ */ new WeakMap();
@@ -56751,7 +56751,7 @@ var require_comments = __commonJS({
56751
56751
  if (isArray.check(node)) {
56752
56752
  names = Object.keys(node);
56753
56753
  } else if (isObject2.check(node)) {
56754
- names = types18.getFieldNames(node);
56754
+ names = types17.getFieldNames(node);
56755
56755
  } else {
56756
56756
  return resultArray;
56757
56757
  }
@@ -56929,7 +56929,7 @@ var require_comments = __commonJS({
56929
56929
  function printComments(path2, print9) {
56930
56930
  var value = path2.getValue();
56931
56931
  var innerLines = print9(path2);
56932
- var comments = n.Node.check(value) && types18.getFieldValue(value, "comments");
56932
+ var comments = n.Node.check(value) && types17.getFieldValue(value, "comments");
56933
56933
  if (!comments || comments.length === 0) {
56934
56934
  return innerLines;
56935
56935
  }
@@ -56937,8 +56937,8 @@ var require_comments = __commonJS({
56937
56937
  var trailingParts = [innerLines];
56938
56938
  path2.each(function(commentPath) {
56939
56939
  var comment = commentPath.getValue();
56940
- var leading = types18.getFieldValue(comment, "leading");
56941
- var trailing = types18.getFieldValue(comment, "trailing");
56940
+ var leading = types17.getFieldValue(comment, "leading");
56941
+ var trailing = types17.getFieldValue(comment, "trailing");
56942
56942
  if (leading || trailing && !(n.Statement.check(value) || comment.type === "Block" || comment.type === "CommentBlock")) {
56943
56943
  leadingParts.push(printLeadingComment(commentPath, print9));
56944
56944
  } else if (trailing) {
@@ -56960,10 +56960,10 @@ var require_parser2 = __commonJS({
56960
56960
  exports.parse = void 0;
56961
56961
  var tslib_1 = require_tslib();
56962
56962
  var assert_1 = tslib_1.__importDefault(require("assert"));
56963
- var types18 = tslib_1.__importStar(require_main());
56964
- var b = types18.builders;
56965
- var isObject2 = types18.builtInTypes.object;
56966
- var isArray = types18.builtInTypes.array;
56963
+ var types17 = tslib_1.__importStar(require_main());
56964
+ var b = types17.builders;
56965
+ var isObject2 = types17.builtInTypes.object;
56966
+ var isArray = types17.builtInTypes.array;
56967
56967
  var options_1 = require_options();
56968
56968
  var lines_1 = require_lines();
56969
56969
  var comments_1 = require_comments();
@@ -57149,11 +57149,11 @@ var require_fast_path = __commonJS({
57149
57149
  Object.defineProperty(exports, "__esModule", { value: true });
57150
57150
  var tslib_1 = require_tslib();
57151
57151
  var assert_1 = tslib_1.__importDefault(require("assert"));
57152
- var types18 = tslib_1.__importStar(require_main());
57152
+ var types17 = tslib_1.__importStar(require_main());
57153
57153
  var util = tslib_1.__importStar(require_util2());
57154
- var n = types18.namedTypes;
57155
- var isArray = types18.builtInTypes.array;
57156
- var isNumber = types18.builtInTypes.number;
57154
+ var n = types17.namedTypes;
57155
+ var isArray = types17.builtInTypes.array;
57156
+ var isNumber = types17.builtInTypes.number;
57157
57157
  var PRECEDENCE = {};
57158
57158
  [
57159
57159
  ["??"],
@@ -57182,7 +57182,7 @@ var require_fast_path = __commonJS({
57182
57182
  if (obj instanceof FastPath) {
57183
57183
  return obj.copy();
57184
57184
  }
57185
- if (obj instanceof types18.NodePath) {
57185
+ if (obj instanceof types17.NodePath) {
57186
57186
  var copy = Object.create(FastPath.prototype);
57187
57187
  var stack = [obj.value];
57188
57188
  for (var pp = void 0; pp = obj.parentPath; obj = pp)
@@ -57493,7 +57493,7 @@ var require_fast_path = __commonJS({
57493
57493
  return node.some(containsCallExpression);
57494
57494
  }
57495
57495
  if (n.Node.check(node)) {
57496
- return types18.someField(node, function(_name, child) {
57496
+ return types17.someField(node, function(_name, child) {
57497
57497
  return containsCallExpression(child);
57498
57498
  });
57499
57499
  }
@@ -57583,16 +57583,16 @@ var require_patcher = __commonJS({
57583
57583
  var tslib_1 = require_tslib();
57584
57584
  var assert_1 = tslib_1.__importDefault(require("assert"));
57585
57585
  var linesModule = tslib_1.__importStar(require_lines());
57586
- var types18 = tslib_1.__importStar(require_main());
57587
- var Printable = types18.namedTypes.Printable;
57588
- var Expression = types18.namedTypes.Expression;
57589
- var ReturnStatement = types18.namedTypes.ReturnStatement;
57590
- var SourceLocation = types18.namedTypes.SourceLocation;
57586
+ var types17 = tslib_1.__importStar(require_main());
57587
+ var Printable = types17.namedTypes.Printable;
57588
+ var Expression = types17.namedTypes.Expression;
57589
+ var ReturnStatement = types17.namedTypes.ReturnStatement;
57590
+ var SourceLocation = types17.namedTypes.SourceLocation;
57591
57591
  var util_1 = require_util2();
57592
57592
  var fast_path_1 = tslib_1.__importDefault(require_fast_path());
57593
- var isObject2 = types18.builtInTypes.object;
57594
- var isArray = types18.builtInTypes.array;
57595
- var isString = types18.builtInTypes.string;
57593
+ var isObject2 = types17.builtInTypes.object;
57594
+ var isArray = types17.builtInTypes.array;
57595
+ var isString = types17.builtInTypes.string;
57596
57596
  var riskyAdjoiningCharExp = /[0-9a-z_$]/i;
57597
57597
  var Patcher = function Patcher2(lines) {
57598
57598
  assert_1.default.ok(this instanceof Patcher2);
@@ -57862,8 +57862,8 @@ var require_patcher = __commonJS({
57862
57862
  if (k.charAt(0) === "_") {
57863
57863
  continue;
57864
57864
  }
57865
- newPath.stack.push(k, types18.getFieldValue(newNode, k));
57866
- oldPath.stack.push(k, types18.getFieldValue(oldNode, k));
57865
+ newPath.stack.push(k, types17.getFieldValue(newNode, k));
57866
+ oldPath.stack.push(k, types17.getFieldValue(oldNode, k));
57867
57867
  var canReprint = findAnyReprints(newPath, oldPath, reprints);
57868
57868
  newPath.stack.length -= 2;
57869
57869
  oldPath.stack.length -= 2;
@@ -57887,16 +57887,16 @@ var require_printer2 = __commonJS({
57887
57887
  exports.Printer = void 0;
57888
57888
  var tslib_1 = require_tslib();
57889
57889
  var assert_1 = tslib_1.__importDefault(require("assert"));
57890
- var types18 = tslib_1.__importStar(require_main());
57890
+ var types17 = tslib_1.__importStar(require_main());
57891
57891
  var comments_1 = require_comments();
57892
57892
  var fast_path_1 = tslib_1.__importDefault(require_fast_path());
57893
57893
  var lines_1 = require_lines();
57894
57894
  var options_1 = require_options();
57895
57895
  var patcher_1 = require_patcher();
57896
57896
  var util = tslib_1.__importStar(require_util2());
57897
- var namedTypes = types18.namedTypes;
57898
- var isString = types18.builtInTypes.string;
57899
- var isObject2 = types18.builtInTypes.object;
57897
+ var namedTypes = types17.namedTypes;
57898
+ var isString = types17.builtInTypes.string;
57899
+ var isObject2 = types17.builtInTypes.object;
57900
57900
  var PrintResult = function PrintResult2(code, sourceMap) {
57901
57901
  assert_1.default.ok(this instanceof PrintResult2);
57902
57902
  isString.assert(code);
@@ -58058,7 +58058,7 @@ var require_printer2 = __commonJS({
58058
58058
  case "OptionalMemberExpression": {
58059
58059
  parts.push(path2.call(print9, "object"));
58060
58060
  var property = path2.call(print9, "property");
58061
- var optional = types18.getFieldValue(n, "optional");
58061
+ var optional = types17.getFieldValue(n, "optional");
58062
58062
  if (n.computed) {
58063
58063
  parts.push(optional ? "?.[" : "[", property, "]");
58064
58064
  } else {
@@ -58329,7 +58329,7 @@ var require_printer2 = __commonJS({
58329
58329
  if (n.typeArguments) {
58330
58330
  parts.push(path2.call(print9, "typeArguments"));
58331
58331
  }
58332
- if (types18.getFieldValue(n, "optional")) {
58332
+ if (types17.getFieldValue(n, "optional")) {
58333
58333
  parts.push("?.");
58334
58334
  }
58335
58335
  parts.push(printArgumentsList(path2, options, print9));
@@ -60008,8 +60008,8 @@ var require_printer2 = __commonJS({
60008
60008
  });
60009
60009
  }
60010
60010
  function getPossibleRaw(node) {
60011
- var value = types18.getFieldValue(node, "value");
60012
- var extra = types18.getFieldValue(node, "extra");
60011
+ var value = types17.getFieldValue(node, "value");
60012
+ var extra = types17.getFieldValue(node, "extra");
60013
60013
  if (extra && typeof extra.raw === "string" && value == extra.rawValue) {
60014
60014
  return extra.raw;
60015
60015
  }
@@ -60057,8 +60057,8 @@ var require_main2 = __commonJS({
60057
60057
  exports.run = exports.prettyPrint = exports.print = exports.visit = exports.types = exports.parse = void 0;
60058
60058
  var tslib_1 = require_tslib();
60059
60059
  var fs_1 = tslib_1.__importDefault(require("fs"));
60060
- var types18 = tslib_1.__importStar(require_main());
60061
- exports.types = types18;
60060
+ var types17 = tslib_1.__importStar(require_main());
60061
+ exports.types = types17;
60062
60062
  var parser_1 = require_parser2();
60063
60063
  Object.defineProperty(exports, "parse", { enumerable: true, get: function() {
60064
60064
  return parser_1.parse;
@@ -66134,7 +66134,7 @@ var printDocASTReducer = {
66134
66134
  leave: ({ name, interfaces, directives, fields }) => join(["interface", name, wrap("implements ", join(interfaces, " & ")), join(directives, " "), block(fields)], " ")
66135
66135
  },
66136
66136
  UnionTypeDefinition: {
66137
- leave: ({ name, directives, types: types18 }) => join(["union", name, join(directives, " "), wrap("= ", join(types18, " | "))], " ")
66137
+ leave: ({ name, directives, types: types17 }) => join(["union", name, join(directives, " "), wrap("= ", join(types17, " | "))], " ")
66138
66138
  },
66139
66139
  EnumTypeDefinition: {
66140
66140
  leave: ({ name, directives, values }) => join(["enum", name, join(directives, " "), block(values)], " ")
@@ -66161,7 +66161,7 @@ var printDocASTReducer = {
66161
66161
  leave: ({ name, interfaces, directives, fields }) => join(["extend interface", name, wrap("implements ", join(interfaces, " & ")), join(directives, " "), block(fields)], " ")
66162
66162
  },
66163
66163
  UnionTypeExtension: {
66164
- leave: ({ name, directives, types: types18 }) => join(["extend union", name, join(directives, " "), wrap("= ", join(types18, " | "))], " ")
66164
+ leave: ({ name, directives, types: types17 }) => join(["extend union", name, join(directives, " "), wrap("= ", join(types17, " | "))], " ")
66165
66165
  },
66166
66166
  EnumTypeExtension: {
66167
66167
  leave: ({ name, directives, values }) => join(["extend enum", name, join(directives, " "), block(values)], " ")
@@ -67041,8 +67041,8 @@ function healTypes(originalTypeMap, directives) {
67041
67041
  }
67042
67042
  }
67043
67043
  function healUnderlyingTypes(type) {
67044
- const types18 = type.getTypes();
67045
- types18.push(...types18.splice(0).map((t2) => healType(t2)).filter(Boolean));
67044
+ const types17 = type.getTypes();
67045
+ types17.push(...types17.splice(0).map((t2) => healType(t2)).filter(Boolean));
67046
67046
  }
67047
67047
  function healType(type) {
67048
67048
  if ((0, import_graphql11.isListType)(type)) {
@@ -67826,11 +67826,11 @@ function mergeEnum(e1, e2, config2) {
67826
67826
 
67827
67827
  // ../../node_modules/.pnpm/@graphql-tools+merge@8.3.14_graphql@15.8.0/node_modules/@graphql-tools/merge/esm/typedefs-mergers/utils.js
67828
67828
  var import_graphql20 = __toESM(require_graphql2(), 1);
67829
- function isStringTypes(types18) {
67830
- return typeof types18 === "string";
67829
+ function isStringTypes(types17) {
67830
+ return typeof types17 === "string";
67831
67831
  }
67832
- function isSourceTypes(types18) {
67833
- return types18 instanceof import_graphql20.Source;
67832
+ function isSourceTypes(types17) {
67833
+ return types17 instanceof import_graphql20.Source;
67834
67834
  }
67835
67835
  function extractType(type) {
67836
67836
  let visitedType = type;
@@ -70200,6 +70200,9 @@ var GarbageCollector = class {
70200
70200
  constructor(cache) {
70201
70201
  this.cache = cache;
70202
70202
  }
70203
+ reset() {
70204
+ this.lifetimes.clear();
70205
+ }
70203
70206
  resetLifetime(id, field) {
70204
70207
  if (!this.lifetimes.get(id)) {
70205
70208
  this.lifetimes.set(id, /* @__PURE__ */ new Map());
@@ -70319,6 +70322,10 @@ var ListManager = class {
70319
70322
  }
70320
70323
  this.listsByField.get(parentID).delete(field);
70321
70324
  }
70325
+ reset() {
70326
+ this.lists.clear();
70327
+ this.listsByField.clear();
70328
+ }
70322
70329
  };
70323
70330
  var List = class {
70324
70331
  recordID;
@@ -70701,6 +70708,9 @@ var StaleManager = class {
70701
70708
  }
70702
70709
  }
70703
70710
  }
70711
+ reset() {
70712
+ this.fieldsTime.clear();
70713
+ }
70704
70714
  };
70705
70715
 
70706
70716
  // src/runtime/cache/storage.ts
@@ -70881,6 +70891,9 @@ var InMemoryStorage = class {
70881
70891
  layer.fields = fields;
70882
70892
  layer.links = links;
70883
70893
  }
70894
+ reset() {
70895
+ this.data = [];
70896
+ }
70884
70897
  };
70885
70898
  var Layer = class {
70886
70899
  id;
@@ -71326,6 +71339,18 @@ var InMemorySubscriptions = class {
71326
71339
  this.remove(linkedRecordID, linkFields, targets, visited);
71327
71340
  }
71328
71341
  }
71342
+ reset() {
71343
+ const subscribers = Object.entries(this.subscribers).filter(
71344
+ ([id]) => !id.startsWith(rootID)
71345
+ );
71346
+ for (const [id, _fields] of subscribers) {
71347
+ delete this.subscribers[id];
71348
+ }
71349
+ const subscriptionSpecs = subscribers.flatMap(
71350
+ ([_id, fields]) => Object.values(fields).flatMap((field) => field.map(([spec]) => spec))
71351
+ );
71352
+ return subscriptionSpecs;
71353
+ }
71329
71354
  removeSubscribers(id, fieldName, specs) {
71330
71355
  let targets = [];
71331
71356
  for (const spec of specs) {
@@ -71515,6 +71540,14 @@ var Cache = class {
71515
71540
  }
71516
71541
  this.#notifySubscribers(toNotify);
71517
71542
  }
71543
+ reset() {
71544
+ const subSpecs = this._internal_unstable.subscriptions.reset();
71545
+ this._internal_unstable.staleManager.reset();
71546
+ this._internal_unstable.lifetimes.reset();
71547
+ this._internal_unstable.lists.reset();
71548
+ this._internal_unstable.storage.reset();
71549
+ this.#notifySubscribers(subSpecs);
71550
+ }
71518
71551
  #notifySubscribers(subs) {
71519
71552
  if (subs.length === 0) {
71520
71553
  return;
@@ -71697,7 +71730,7 @@ var CacheInternal = class {
71697
71730
  forceNotify
71698
71731
  });
71699
71732
  }
71700
- } else if (Array.isArray(value) && (typeof previousValue === "undefined" || Array.isArray(previousValue))) {
71733
+ } else if (Array.isArray(value) && (typeof previousValue === "undefined" || previousValue === null || Array.isArray(previousValue))) {
71701
71734
  let oldIDs = [...previousValue || []];
71702
71735
  const emptyEdges = !updates ? [] : oldIDs.map((id) => {
71703
71736
  if (!id) {
@@ -71770,7 +71803,7 @@ var CacheInternal = class {
71770
71803
  } else {
71771
71804
  linkedIDs = nestedIDs;
71772
71805
  }
71773
- const contentChanged = !deepEquals(linkedIDs, oldIDs);
71806
+ const contentChanged = !deepEquals(linkedIDs, oldIDs) || previousValue === null;
71774
71807
  if (contentChanged || forceNotify) {
71775
71808
  toNotify.push(...currentSubscribers);
71776
71809
  }
@@ -72490,7 +72523,7 @@ var Config = class {
72490
72523
  defaultListTarget = null,
72491
72524
  defaultPaginateMode = PaginateMode.Infinite,
72492
72525
  defaultKeys,
72493
- types: types18 = {},
72526
+ types: types17 = {},
72494
72527
  logLevel,
72495
72528
  defaultFragmentMasking = "enable",
72496
72529
  watchSchema,
@@ -72534,10 +72567,10 @@ var Config = class {
72534
72567
  if (defaultKeys) {
72535
72568
  this.defaultKeys = defaultKeys;
72536
72569
  }
72537
- if (types18) {
72570
+ if (types17) {
72538
72571
  this.typeConfig = {
72539
72572
  ...this.typeConfig,
72540
- ...types18
72573
+ ...types17
72541
72574
  };
72542
72575
  }
72543
72576
  }
@@ -72745,6 +72778,8 @@ var Config = class {
72745
72778
  root = this.projectRoot,
72746
72779
  ignore_plugins = false
72747
72780
  } = {}) {
72781
+ const parsed = parse2(filepath);
72782
+ filepath = `${parsed.dir}/${parsed.name}${parsed.ext.split("?")[0]}`;
72748
72783
  let included = false;
72749
72784
  for (const plugin2 of ignore_plugins ? [] : this.plugins) {
72750
72785
  if (!plugin2.include) {
@@ -73432,7 +73467,7 @@ function deepMerge2(filepath, ...targets) {
73432
73467
  // src/lib/parse.ts
73433
73468
  function parseJS(str, config2) {
73434
73469
  const defaultConfig = {
73435
- plugins: ["typescript", "importAssertions"],
73470
+ plugins: ["typescript", "importAssertions", "decorators"],
73436
73471
  sourceType: "module"
73437
73472
  };
73438
73473
  return (0, import_parser.parse)(str || "", config2 ? deepMerge2("", defaultConfig, config2) : defaultConfig).program;
@@ -73734,7 +73769,7 @@ var graphql27 = __toESM(require_graphql2(), 1);
73734
73769
 
73735
73770
  // src/codegen/generators/artifacts/index.ts
73736
73771
  var graphql14 = __toESM(require_graphql2(), 1);
73737
- var recast6 = __toESM(require_main2(), 1);
73772
+ var recast5 = __toESM(require_main2(), 1);
73738
73773
 
73739
73774
  // src/codegen/utils/commonjs.ts
73740
73775
  var cjsIndexFilePreamble = `"use strict";
@@ -74921,7 +74956,6 @@ function ancestorKey(ancestors) {
74921
74956
 
74922
74957
  // src/codegen/generators/artifacts/selection.ts
74923
74958
  var graphql13 = __toESM(require_graphql2(), 1);
74924
- var recast5 = __toESM(require_main2(), 1);
74925
74959
 
74926
74960
  // ../../node_modules/.pnpm/@kitql+helper@0.5.0/node_modules/@kitql/helper/index.mjs
74927
74961
  var config = {
@@ -75868,15 +75902,12 @@ function fieldKey(config2, field) {
75868
75902
  }
75869
75903
 
75870
75904
  // src/codegen/generators/artifacts/selection.ts
75871
- var AST5 = recast5.types.builders;
75872
75905
  function selection_default(args) {
75873
- const typeMap = {};
75874
- const abstractTypes = [];
75875
75906
  return mergeSelection({
75876
- object: prepareSelection({ ...args, typeMap, abstractTypes }),
75877
- filepath: args.filepath,
75878
- typeMap,
75879
- abstractTypes
75907
+ config: args.config,
75908
+ rootType: args.rootType,
75909
+ object: prepareSelection(args),
75910
+ filepath: args.filepath
75880
75911
  });
75881
75912
  }
75882
75913
  function prepareSelection({
@@ -75888,8 +75919,6 @@ function prepareSelection({
75888
75919
  path: path2 = [],
75889
75920
  document,
75890
75921
  inConnection,
75891
- typeMap,
75892
- abstractTypes,
75893
75922
  globalLoading,
75894
75923
  includeFragments
75895
75924
  }) {
@@ -75909,8 +75938,6 @@ function prepareSelection({
75909
75938
  selections: field.selectionSet.selections,
75910
75939
  path: path2,
75911
75940
  document,
75912
- typeMap,
75913
- abstractTypes,
75914
75941
  globalLoading,
75915
75942
  includeFragments
75916
75943
  }).fields || {}
@@ -75922,32 +75949,7 @@ function prepareSelection({
75922
75949
  typeMap: {}
75923
75950
  };
75924
75951
  }
75925
- const parentType = config2.schema.getType(rootType);
75926
75952
  const typeConditionName = field.typeCondition.name.value;
75927
- const typeCondition = config2.schema.getType(typeConditionName);
75928
- const possibleTypes = [];
75929
- if (!graphql13.isAbstractType(typeCondition)) {
75930
- } else if (graphql13.isAbstractType(parentType)) {
75931
- const possibleParentTypes = config2.schema.getPossibleTypes(parentType).map((type) => type.name);
75932
- for (const possible of config2.schema.getPossibleTypes(typeCondition)) {
75933
- if (possibleParentTypes.includes(possible.name)) {
75934
- possibleTypes.push(possible.name);
75935
- }
75936
- }
75937
- } else {
75938
- possibleTypes.push(rootType);
75939
- }
75940
- if (possibleTypes.length > 0) {
75941
- for (const type of possibleTypes) {
75942
- const existing = typeMap[type];
75943
- if (!existing || !existing.includes(type)) {
75944
- typeMap[type] = [typeConditionName].concat(existing || []);
75945
- }
75946
- if (!abstractTypes.includes(typeConditionName)) {
75947
- abstractTypes.push(typeConditionName);
75948
- }
75949
- }
75950
- }
75951
75953
  object.abstractFields.fields = {
75952
75954
  ...object.abstractFields.fields,
75953
75955
  [typeConditionName]: prepareSelection({
@@ -75958,8 +75960,6 @@ function prepareSelection({
75958
75960
  selections: field.selectionSet.selections,
75959
75961
  path: path2,
75960
75962
  document,
75961
- typeMap,
75962
- abstractTypes,
75963
75963
  globalLoading,
75964
75964
  includeFragments
75965
75965
  }).fields
@@ -75971,19 +75971,38 @@ function prepareSelection({
75971
75971
  } else if (field.kind === "Field") {
75972
75972
  const type = config2.schema.getType(rootType);
75973
75973
  if (!type) {
75974
- throw new HoudiniError({ filepath, message: "Could not find type" });
75974
+ throw new HoudiniError({
75975
+ filepath,
75976
+ message: "Could not find type. Looking for " + JSON.stringify(rootType)
75977
+ });
75975
75978
  }
75976
75979
  const attributeName = field.alias?.value || field.name.value;
75977
- let fieldType;
75980
+ let fieldType = null;
75978
75981
  let nullable = false;
75979
75982
  if (field.name.value === "__typename") {
75980
75983
  fieldType = config2.schema.getType("String");
75981
- } else {
75984
+ } else if ("getFields" in type) {
75982
75985
  let typeRef = type.getFields()[field.name.value].type;
75983
75986
  fieldType = getRootType(typeRef);
75984
75987
  nullable = !graphql13.isNonNullType(typeRef);
75988
+ } else if (graphql13.isAbstractType(type)) {
75989
+ for (const possible of config2.schema.getPossibleTypes(type)) {
75990
+ if (graphql13.isObjectType(possible)) {
75991
+ if (possible.getFields()[field.name.value]) {
75992
+ fieldType = possible.getFields()[field.name.value].type;
75993
+ nullable = !graphql13.isNonNullType(fieldType);
75994
+ break;
75995
+ }
75996
+ }
75997
+ }
75998
+ }
75999
+ if (!fieldType) {
76000
+ throw {
76001
+ message: "Could not identify field's type",
76002
+ description: `Missing definition for ${field.name.value} in ${type.name}`
76003
+ };
75985
76004
  }
75986
- const typeName = fieldType.toString();
76005
+ const typeName = getRootType(fieldType).name;
75987
76006
  const pathSoFar = path2.concat(attributeName);
75988
76007
  const keys2 = config2.keyFieldsForType(rootType);
75989
76008
  let fieldObj = {
@@ -76077,8 +76096,6 @@ function prepareSelection({
76077
76096
  path: pathSoFar,
76078
76097
  document,
76079
76098
  inConnection: connectionState,
76080
- typeMap,
76081
- abstractTypes,
76082
76099
  globalLoading: forceLoading,
76083
76100
  includeFragments
76084
76101
  });
@@ -76164,69 +76181,107 @@ function prepareSelection({
76164
76181
  return object;
76165
76182
  }
76166
76183
  function mergeSelection({
76184
+ config: config2,
76167
76185
  filepath,
76168
76186
  object,
76169
- typeMap,
76170
- abstractTypes
76187
+ rootType
76171
76188
  }) {
76172
76189
  if (Object.keys(object.fields || {}).length > 0 && object.abstractFields && Object.keys(object.abstractFields.fields).length > 0) {
76173
- for (const [typeName, possibles] of Object.entries(typeMap)) {
76174
- let overlap = false;
76190
+ const abstractSelection = {
76191
+ fields: {},
76192
+ typeMap: {}
76193
+ };
76194
+ const possibleSelectionTypes = {};
76195
+ for (const [typeName, typeSelection] of Object.entries(object.abstractFields.fields)) {
76196
+ const gqlType = config2.schema.getType(typeName);
76197
+ abstractSelection.fields[typeName] = deepMerge2(
76198
+ filepath,
76199
+ typeSelection,
76200
+ abstractSelection.fields[typeName] ?? {}
76201
+ );
76202
+ if (graphql13.isAbstractType(gqlType)) {
76203
+ for (const possible of config2.schema.getPossibleTypes(gqlType)) {
76204
+ if (!possibleSelectionTypes[typeName]) {
76205
+ possibleSelectionTypes[typeName] = [];
76206
+ }
76207
+ possibleSelectionTypes[typeName].push(possible.name);
76208
+ }
76209
+ }
76210
+ }
76211
+ const concreteSelectionImplements = {};
76212
+ for (const [typeName, possibles] of Object.entries(possibleSelectionTypes)) {
76213
+ for (const possible of possibles) {
76214
+ if (!concreteSelectionImplements[possible]) {
76215
+ concreteSelectionImplements[possible] = [];
76216
+ }
76217
+ concreteSelectionImplements[possible].push(typeName);
76218
+ }
76219
+ }
76220
+ for (const [concrete, implementations] of Object.entries(concreteSelectionImplements)) {
76221
+ if (implementations.length > 1) {
76222
+ abstractSelection.fields[concrete] = {};
76223
+ }
76224
+ }
76225
+ for (const [typeName, possibles] of Object.entries(possibleSelectionTypes)) {
76175
76226
  for (const possible of possibles) {
76176
- if (object.abstractFields.fields[typeName]) {
76177
- object.abstractFields.fields[typeName] = deepMerge2(
76227
+ if (abstractSelection.fields[possible]) {
76228
+ abstractSelection.fields[possible] = deepMerge2(
76178
76229
  filepath,
76179
- object.abstractFields.fields[typeName] ?? {},
76180
- object.abstractFields.fields[possible] ?? {}
76230
+ abstractSelection.fields[typeName] ?? {},
76231
+ abstractSelection.fields[possible] ?? {}
76181
76232
  );
76182
- overlap = true;
76183
76233
  }
76184
76234
  }
76185
- if (overlap) {
76186
- delete typeMap[typeName];
76187
- }
76188
76235
  }
76189
- for (const [type, options] of Object.entries(typeMap)) {
76190
- if (options.length > 1) {
76191
- object.abstractFields.fields[type] = deepMerge2(
76192
- filepath,
76193
- ...options.map((opt) => object.abstractFields.fields[opt] || {})
76194
- );
76195
- delete typeMap[type];
76236
+ const parentType = config2.schema.getType(rootType);
76237
+ const possibleParents = graphql13.isAbstractType(parentType) ? config2.schema.getPossibleTypes(parentType)?.map((t2) => t2.name) : [parentType.name];
76238
+ for (const key of Object.keys(abstractSelection.typeMap)) {
76239
+ if (!possibleParents.includes(key) && rootType !== key || abstractSelection.fields[key]) {
76240
+ delete abstractSelection.typeMap[key];
76196
76241
  }
76197
76242
  }
76198
- for (const [type, sel] of Object.entries(object.abstractFields?.fields || {})) {
76199
- object.abstractFields.fields[type] = deepMerge2(filepath, sel || {}, object.fields);
76243
+ for (const [type, sel] of Object.entries(abstractSelection.fields || {})) {
76244
+ abstractSelection.fields[type] = deepMerge2(filepath, sel || {}, object.fields);
76200
76245
  }
76201
- for (const [type, options] of Object.entries(typeMap)) {
76202
- object.abstractFields.typeMap[type] = options[0];
76246
+ for (const [typename, possibles] of Object.entries(possibleSelectionTypes)) {
76247
+ if (possibles.every((p) => abstractSelection.fields[p])) {
76248
+ delete abstractSelection.fields[typename];
76249
+ }
76203
76250
  }
76204
- const usedTypes = Object.values(object.abstractFields.typeMap);
76205
- for (const type of abstractTypes) {
76206
- if (!usedTypes.includes(type)) {
76207
- delete object.abstractFields.fields[type];
76251
+ for (const possible of possibleParents) {
76252
+ if (abstractSelection.fields[possible]) {
76253
+ continue;
76254
+ }
76255
+ for (const [abstractType, abstractTypeMembers] of Object.entries(
76256
+ possibleSelectionTypes
76257
+ )) {
76258
+ if (abstractTypeMembers.includes(possible)) {
76259
+ abstractSelection.typeMap[possible] = abstractType;
76260
+ break;
76261
+ }
76208
76262
  }
76209
76263
  }
76264
+ object.abstractFields = abstractSelection;
76210
76265
  }
76211
- for (const [key, value] of Object.entries(object.fields ?? {})) {
76266
+ for (const value of Object.values(object.fields ?? {})) {
76212
76267
  const selection = value.selection;
76213
76268
  if (selection) {
76214
76269
  mergeSelection({
76270
+ config: config2,
76271
+ rootType: value.type,
76215
76272
  filepath,
76216
- typeMap,
76217
- abstractTypes,
76218
76273
  object: selection
76219
76274
  });
76220
76275
  }
76221
76276
  }
76222
76277
  for (const [type, selection] of Object.entries(object.abstractFields?.fields ?? {})) {
76223
- for (const [key, value] of Object.entries(selection ?? {})) {
76278
+ for (const value of Object.values(selection ?? {})) {
76224
76279
  const selection2 = value.selection;
76225
76280
  if (selection2) {
76226
76281
  mergeSelection({
76282
+ config: config2,
76283
+ rootType: value.type,
76227
76284
  filepath,
76228
- typeMap,
76229
- abstractTypes,
76230
76285
  object: selection2
76231
76286
  });
76232
76287
  }
@@ -76236,7 +76291,7 @@ function mergeSelection({
76236
76291
  }
76237
76292
 
76238
76293
  // src/codegen/generators/artifacts/index.ts
76239
- var AST6 = recast6.types.builders;
76294
+ var AST5 = recast5.types.builders;
76240
76295
  function artifactGenerator(stats) {
76241
76296
  return async function(config2, docs) {
76242
76297
  const filterTypes = {};
@@ -76504,10 +76559,10 @@ function artifactGenerator(stats) {
76504
76559
  }
76505
76560
  plugin2.artifactEnd({ config: config2, document: doc });
76506
76561
  }
76507
- const file = AST6.program([
76562
+ const file = AST5.program([
76508
76563
  moduleExport(config2, "default", serializeValue(artifact)),
76509
- AST6.expressionStatement(
76510
- AST6.stringLiteral(`HoudiniHash=${hash({ config: config2, document: doc })}`)
76564
+ AST5.expressionStatement(
76565
+ AST5.stringLiteral(`HoudiniHash=${hash({ config: config2, document: doc })}`)
76511
76566
  )
76512
76567
  ]);
76513
76568
  const artifactPath = config2.artifactPath(document);
@@ -76587,8 +76642,8 @@ function applyMask(config2, target, mask) {
76587
76642
  }
76588
76643
 
76589
76644
  // src/codegen/generators/runtime/graphqlFunction.ts
76590
- var recast7 = __toESM(require_main2(), 1);
76591
- var AST7 = recast7.types.builders;
76645
+ var recast6 = __toESM(require_main2(), 1);
76646
+ var AST6 = recast6.types.builders;
76592
76647
  async function generateGraphqlReturnTypes(config2, docs) {
76593
76648
  const indexPath = path_exports.join(config2.runtimeDirectory, "index.d.ts");
76594
76649
  const fileContent = await fs_exports.readFile(indexPath) || "";
@@ -76623,18 +76678,18 @@ async function generateGraphqlReturnTypes(config2, docs) {
76623
76678
  continue;
76624
76679
  }
76625
76680
  for (const [queryString, returnValue] of Object.entries(overloaded_returns)) {
76626
- const input = AST7.identifier("str");
76627
- input.typeAnnotation = AST7.tsTypeAnnotation(
76628
- AST7.tsLiteralType(AST7.stringLiteral(queryString))
76681
+ const input = AST6.identifier("str");
76682
+ input.typeAnnotation = AST6.tsTypeAnnotation(
76683
+ AST6.tsLiteralType(AST6.stringLiteral(queryString))
76629
76684
  );
76630
76685
  script.body.splice(
76631
76686
  i2,
76632
76687
  0,
76633
- AST7.exportNamedDeclaration(
76634
- AST7.tsDeclareFunction(
76635
- AST7.identifier("graphql"),
76688
+ AST6.exportNamedDeclaration(
76689
+ AST6.tsDeclareFunction(
76690
+ AST6.identifier("graphql"),
76636
76691
  [input],
76637
- AST7.tsTypeAnnotation(AST7.tsTypeReference(AST7.identifier(returnValue)))
76692
+ AST6.tsTypeAnnotation(AST6.tsTypeReference(AST6.identifier(returnValue)))
76638
76693
  )
76639
76694
  )
76640
76695
  );
@@ -76797,20 +76852,20 @@ async function generatePluginRuntime({
76797
76852
  }
76798
76853
 
76799
76854
  // src/codegen/generators/typescript/documentTypes.ts
76800
- var recast13 = __toESM(require_main2(), 1);
76855
+ var recast12 = __toESM(require_main2(), 1);
76801
76856
 
76802
76857
  // src/codegen/generators/typescript/addReferencedInputTypes.ts
76803
76858
  var graphql17 = __toESM(require_graphql2(), 1);
76804
- var recast10 = __toESM(require_main2(), 1);
76859
+ var recast9 = __toESM(require_main2(), 1);
76805
76860
 
76806
76861
  // src/codegen/generators/typescript/typeReference.ts
76807
76862
  var graphql16 = __toESM(require_graphql2(), 1);
76808
- var recast9 = __toESM(require_main2(), 1);
76863
+ var recast8 = __toESM(require_main2(), 1);
76809
76864
 
76810
76865
  // src/codegen/generators/typescript/types.ts
76811
76866
  var graphql15 = __toESM(require_graphql2(), 1);
76812
- var recast8 = __toESM(require_main2(), 1);
76813
- var AST8 = recast8.types.builders;
76867
+ var recast7 = __toESM(require_main2(), 1);
76868
+ var AST7 = recast7.types.builders;
76814
76869
  function readonlyProperty(prop, enable = true) {
76815
76870
  if (enable) {
76816
76871
  prop.readonly = true;
@@ -76818,28 +76873,28 @@ function readonlyProperty(prop, enable = true) {
76818
76873
  return prop;
76819
76874
  }
76820
76875
  function nullableField(inner, input = false) {
76821
- const members = [inner, AST8.tsNullKeyword()];
76876
+ const members = [inner, AST7.tsNullKeyword()];
76822
76877
  if (input) {
76823
- members.push(AST8.tsUndefinedKeyword());
76878
+ members.push(AST7.tsUndefinedKeyword());
76824
76879
  }
76825
- return AST8.tsUnionType(members);
76880
+ return AST7.tsUnionType(members);
76826
76881
  }
76827
76882
  function scalarPropertyValue(config2, missingScalars, target) {
76828
76883
  switch (target.name) {
76829
76884
  case "String": {
76830
- return AST8.tsStringKeyword();
76885
+ return AST7.tsStringKeyword();
76831
76886
  }
76832
76887
  case "Int": {
76833
- return AST8.tsNumberKeyword();
76888
+ return AST7.tsNumberKeyword();
76834
76889
  }
76835
76890
  case "Float": {
76836
- return AST8.tsNumberKeyword();
76891
+ return AST7.tsNumberKeyword();
76837
76892
  }
76838
76893
  case "Boolean": {
76839
- return AST8.tsBooleanKeyword();
76894
+ return AST7.tsBooleanKeyword();
76840
76895
  }
76841
76896
  case "ID": {
76842
- return AST8.tsStringKeyword();
76897
+ return AST7.tsStringKeyword();
76843
76898
  }
76844
76899
  default: {
76845
76900
  if (graphql15.isNonNullType(target) && "ofType" in target) {
@@ -76850,16 +76905,16 @@ function scalarPropertyValue(config2, missingScalars, target) {
76850
76905
  );
76851
76906
  }
76852
76907
  if (config2.scalars?.[target.name]) {
76853
- return AST8.tsTypeReference(AST8.identifier(config2.scalars?.[target.name].type));
76908
+ return AST7.tsTypeReference(AST7.identifier(config2.scalars?.[target.name].type));
76854
76909
  }
76855
76910
  missingScalars.add(target.name);
76856
- return AST8.tsAnyKeyword();
76911
+ return AST7.tsAnyKeyword();
76857
76912
  }
76858
76913
  }
76859
76914
  }
76860
76915
 
76861
76916
  // src/codegen/generators/typescript/typeReference.ts
76862
- var AST9 = recast9.types.builders;
76917
+ var AST8 = recast8.types.builders;
76863
76918
  function tsTypeReference(config2, missingScalars, definition, body) {
76864
76919
  const { type, wrappers } = unwrapType(config2, definition.type);
76865
76920
  let result;
@@ -76868,7 +76923,7 @@ function tsTypeReference(config2, missingScalars, definition, body) {
76868
76923
  } else if (graphql16.isEnumType(type)) {
76869
76924
  result = enumReference(config2, body, type.name);
76870
76925
  } else {
76871
- result = AST9.tsTypeReference(AST9.identifier(type.name));
76926
+ result = AST8.tsTypeReference(AST8.identifier(type.name));
76872
76927
  }
76873
76928
  for (const toWrap of wrappers) {
76874
76929
  if (toWrap === "NonNull" /* NonNull */) {
@@ -76876,7 +76931,7 @@ function tsTypeReference(config2, missingScalars, definition, body) {
76876
76931
  } else if (toWrap === "Nullable" /* Nullable */) {
76877
76932
  result = nullableField(result, true);
76878
76933
  } else if (toWrap === "List" /* List */) {
76879
- result = AST9.tsArrayType(AST9.tsParenthesizedType(result));
76934
+ result = AST8.tsArrayType(AST8.tsParenthesizedType(result));
76880
76935
  }
76881
76936
  }
76882
76937
  return result;
@@ -76889,14 +76944,14 @@ function enumReference(config2, body, name) {
76889
76944
  importKind: "type",
76890
76945
  sourceModule: "$houdini/runtime/lib/types"
76891
76946
  });
76892
- return AST9.tsTypeReference(
76893
- AST9.identifier("ValueOf"),
76894
- AST9.tsTypeParameterInstantiation([AST9.tsTypeQuery(AST9.identifier(name))])
76947
+ return AST8.tsTypeReference(
76948
+ AST8.identifier("ValueOf"),
76949
+ AST8.tsTypeParameterInstantiation([AST8.tsTypeQuery(AST8.identifier(name))])
76895
76950
  );
76896
76951
  }
76897
76952
 
76898
76953
  // src/codegen/generators/typescript/addReferencedInputTypes.ts
76899
- var AST10 = recast10.types.builders;
76954
+ var AST9 = recast9.types.builders;
76900
76955
  function addReferencedInputTypes(config2, filepath, body, visitedTypes, missingScalars, rootType) {
76901
76956
  const { type } = unwrapType(config2, rootType);
76902
76957
  if (graphql17.isScalarType(type)) {
@@ -76923,20 +76978,20 @@ function addReferencedInputTypes(config2, filepath, body, visitedTypes, missingS
76923
76978
  for (const field of Object.values(type.getFields())) {
76924
76979
  addReferencedInputTypes(config2, filepath, body, visitedTypes, missingScalars, field.type);
76925
76980
  members.push(
76926
- AST10.tsPropertySignature(
76927
- AST10.identifier(field.name),
76928
- AST10.tsTypeAnnotation(tsTypeReference(config2, missingScalars, field, body)),
76981
+ AST9.tsPropertySignature(
76982
+ AST9.identifier(field.name),
76983
+ AST9.tsTypeAnnotation(tsTypeReference(config2, missingScalars, field, body)),
76929
76984
  graphql17.isNullableType(field.type)
76930
76985
  )
76931
76986
  );
76932
76987
  }
76933
- body.push(AST10.tsTypeAliasDeclaration(AST10.identifier(type.name), AST10.tsTypeLiteral(members)));
76988
+ body.push(AST9.tsTypeAliasDeclaration(AST9.identifier(type.name), AST9.tsTypeLiteral(members)));
76934
76989
  }
76935
76990
 
76936
76991
  // src/codegen/generators/typescript/inlineType.ts
76937
76992
  var graphql18 = __toESM(require_graphql2(), 1);
76938
- var recast11 = __toESM(require_main2(), 1);
76939
- var AST11 = recast11.types.builders;
76993
+ var recast10 = __toESM(require_main2(), 1);
76994
+ var AST10 = recast10.types.builders;
76940
76995
  var fragmentKey2 = " $fragments";
76941
76996
  function inlineType({
76942
76997
  config: config2,
@@ -77034,7 +77089,7 @@ function inlineType({
77034
77089
  {}
77035
77090
  )
77036
77091
  );
77037
- result = AST11.tsTypeLiteral([
77092
+ result = AST10.tsTypeLiteral([
77038
77093
  ...fields.map((selection) => {
77039
77094
  const { field } = selectionTypeInfo(config2.schema, filepath, rootObj, selection);
77040
77095
  const attributeName = selection.alias?.value || selection.name.value;
@@ -77062,12 +77117,12 @@ function inlineType({
77062
77117
  (directive) => directive.name.value === "include" || directive.name.value === "skip"
77063
77118
  ).length > 0;
77064
77119
  if (hasIncludeOrSkipDirective) {
77065
- attributeType = AST11.tsUnionType([attributeType, AST11.tsUndefinedKeyword()]);
77120
+ attributeType = AST10.tsUnionType([attributeType, AST10.tsUndefinedKeyword()]);
77066
77121
  }
77067
77122
  const prop = readonlyProperty(
77068
- AST11.tsPropertySignature(
77069
- AST11.identifier(attributeName),
77070
- AST11.tsTypeAnnotation(attributeType)
77123
+ AST10.tsPropertySignature(
77124
+ AST10.identifier(attributeName),
77125
+ AST10.tsTypeAnnotation(attributeType)
77071
77126
  ),
77072
77127
  allowReadonly
77073
77128
  );
@@ -77081,14 +77136,14 @@ function inlineType({
77081
77136
  if (includeFragments && fragmentSpreads && fragmentSpreads.length) {
77082
77137
  result.members.push(
77083
77138
  readonlyProperty(
77084
- AST11.tsPropertySignature(
77085
- AST11.stringLiteral(fragmentKey2),
77086
- AST11.tsTypeAnnotation(
77087
- AST11.tsTypeLiteral(
77139
+ AST10.tsPropertySignature(
77140
+ AST10.stringLiteral(fragmentKey2),
77141
+ AST10.tsTypeAnnotation(
77142
+ AST10.tsTypeLiteral(
77088
77143
  (fragmentSpreads || []).map(
77089
- (fragmentSpread) => AST11.tsPropertySignature(
77090
- AST11.identifier(fragmentSpread.name.value),
77091
- AST11.tsTypeAnnotation(AST11.tsTypeLiteral([]))
77144
+ (fragmentSpread) => AST10.tsPropertySignature(
77145
+ AST10.identifier(fragmentSpread.name.value),
77146
+ AST10.tsTypeAnnotation(AST10.tsTypeLiteral([]))
77092
77147
  )
77093
77148
  )
77094
77149
  )
@@ -77133,9 +77188,9 @@ function inlineType({
77133
77188
  }
77134
77189
  objectType.members.push(
77135
77190
  readonlyProperty(
77136
- AST11.tsPropertySignature(
77137
- AST11.identifier("__typename"),
77138
- AST11.tsTypeAnnotation(AST11.tsLiteralType(AST11.stringLiteral(typeName)))
77191
+ AST10.tsPropertySignature(
77192
+ AST10.identifier("__typename"),
77193
+ AST10.tsTypeAnnotation(AST10.tsLiteralType(AST10.stringLiteral(typeName)))
77139
77194
  ),
77140
77195
  allowReadonly
77141
77196
  )
@@ -77175,8 +77230,8 @@ function inlineType({
77175
77230
  if (Object.keys(inlineFragmentSelections).length > 0) {
77176
77231
  let selectionTypes = Object.entries(inlineFragmentSelections).map(
77177
77232
  ([typeName, { type: type2, tsType }]) => {
77178
- return AST11.tsParenthesizedType(
77179
- AST11.tsIntersectionType(
77233
+ return AST10.tsParenthesizedType(
77234
+ AST10.tsIntersectionType(
77180
77235
  [tsType].flatMap((type3) => {
77181
77236
  if (type3.type === "TSUnionType") {
77182
77237
  return type3.types.filter(
@@ -77202,14 +77257,14 @@ function inlineType({
77202
77257
  );
77203
77258
  if (!areAllTypenamesCovered || anySelectionHasRequiredField) {
77204
77259
  selectionTypes.push(
77205
- AST11.tsParenthesizedType(
77206
- AST11.tsTypeLiteral([
77260
+ AST10.tsParenthesizedType(
77261
+ AST10.tsTypeLiteral([
77207
77262
  readonlyProperty(
77208
- AST11.tsPropertySignature(
77209
- AST11.identifier("__typename"),
77210
- AST11.tsTypeAnnotation(
77211
- AST11.tsLiteralType(
77212
- AST11.stringLiteral("non-exhaustive; don't match this")
77263
+ AST10.tsPropertySignature(
77264
+ AST10.identifier("__typename"),
77265
+ AST10.tsTypeAnnotation(
77266
+ AST10.tsLiteralType(
77267
+ AST10.stringLiteral("non-exhaustive; don't match this")
77213
77268
  )
77214
77269
  )
77215
77270
  ),
@@ -77219,9 +77274,9 @@ function inlineType({
77219
77274
  )
77220
77275
  );
77221
77276
  }
77222
- result = AST11.tsIntersectionType([
77277
+ result = AST10.tsIntersectionType([
77223
77278
  result,
77224
- AST11.tsParenthesizedType(AST11.tsUnionType(selectionTypes))
77279
+ AST10.tsParenthesizedType(AST10.tsUnionType(selectionTypes))
77225
77280
  ]);
77226
77281
  }
77227
77282
  } else {
@@ -77239,7 +77294,7 @@ function wrapType2(wrappers, result, root, forceNullable, forceNonNull) {
77239
77294
  } else if (toWrap === "NonNull" /* NonNull */) {
77240
77295
  continue;
77241
77296
  } else if (toWrap === "List" /* List */) {
77242
- result = AST11.tsArrayType(AST11.tsParenthesizedType(result));
77297
+ result = AST10.tsArrayType(AST10.tsParenthesizedType(result));
77243
77298
  }
77244
77299
  }
77245
77300
  return result;
@@ -77284,13 +77339,13 @@ function selectionTypeInfo(schema, filepath, rootType, selection) {
77284
77339
  }
77285
77340
 
77286
77341
  // src/codegen/generators/typescript/loadingState.ts
77287
- var recast12 = __toESM(require_main2(), 1);
77288
- var AST12 = recast12.types.builders;
77342
+ var recast11 = __toESM(require_main2(), 1);
77343
+ var AST11 = recast11.types.builders;
77289
77344
  function withLoadingState(args) {
77290
77345
  if (!("enableLoadingState" in args.document.artifact) || !args.document.artifact.enableLoadingState) {
77291
77346
  return args.base;
77292
77347
  }
77293
- return AST12.tsUnionType([
77348
+ return AST11.tsUnionType([
77294
77349
  args.base,
77295
77350
  loadingState({
77296
77351
  parentType: args.document.artifact.rootType,
@@ -77309,7 +77364,7 @@ function loadingState(args) {
77309
77364
  import: ["LoadingType"],
77310
77365
  sourceModule: "$houdini/runtime/lib/types"
77311
77366
  });
77312
- const result = AST12.tsTypeLiteral(
77367
+ const result = AST11.tsTypeLiteral(
77313
77368
  Object.entries(selection).reduce(
77314
77369
  (rest, [attributeName, value]) => {
77315
77370
  if (!value.loading) {
@@ -77317,7 +77372,7 @@ function loadingState(args) {
77317
77372
  }
77318
77373
  let keyType = null;
77319
77374
  if (value.loading.kind === "value") {
77320
- keyType = AST12.tsTypeReference(AST12.identifier("LoadingType"));
77375
+ keyType = AST11.tsTypeReference(AST11.identifier("LoadingType"));
77321
77376
  }
77322
77377
  if (value.loading.kind === "continue" && value.selection) {
77323
77378
  keyType = loadingState({
@@ -77333,15 +77388,15 @@ function loadingState(args) {
77333
77388
  }
77334
77389
  if (value.loading.list) {
77335
77390
  for (const _ of Array.from({ length: value.loading.list.depth })) {
77336
- keyType = AST12.tsArrayType(keyType);
77391
+ keyType = AST11.tsArrayType(keyType);
77337
77392
  }
77338
77393
  }
77339
77394
  return [
77340
77395
  ...rest,
77341
77396
  readonlyProperty(
77342
- AST12.tsPropertySignature(
77343
- AST12.identifier(attributeName),
77344
- AST12.tsTypeAnnotation(keyType)
77397
+ AST11.tsPropertySignature(
77398
+ AST11.identifier(attributeName),
77399
+ AST11.tsTypeAnnotation(keyType)
77345
77400
  )
77346
77401
  )
77347
77402
  ];
@@ -77352,14 +77407,14 @@ function loadingState(args) {
77352
77407
  if (args.selection.fragments) {
77353
77408
  result.members.push(
77354
77409
  readonlyProperty(
77355
- AST12.tsPropertySignature(
77356
- AST12.stringLiteral(fragmentKey),
77357
- AST12.tsTypeAnnotation(
77358
- AST12.tsTypeLiteral(
77410
+ AST11.tsPropertySignature(
77411
+ AST11.stringLiteral(fragmentKey),
77412
+ AST11.tsTypeAnnotation(
77413
+ AST11.tsTypeLiteral(
77359
77414
  Object.keys(args.selection.fragments).map((name) => {
77360
- return AST12.tsPropertySignature(
77361
- AST12.identifier(name),
77362
- AST12.tsTypeAnnotation(AST12.tsTypeLiteral([]))
77415
+ return AST11.tsPropertySignature(
77416
+ AST11.identifier(name),
77417
+ AST11.tsTypeAnnotation(AST11.tsTypeLiteral([]))
77363
77418
  );
77364
77419
  })
77365
77420
  )
@@ -77372,7 +77427,7 @@ function loadingState(args) {
77372
77427
  }
77373
77428
 
77374
77429
  // src/codegen/generators/typescript/documentTypes.ts
77375
- var AST13 = recast13.types.builders;
77430
+ var AST12 = recast12.types.builders;
77376
77431
  async function generateDocumentTypes(config2, docs) {
77377
77432
  const typePaths = [];
77378
77433
  const fragmentDefinitions = {};
@@ -77397,7 +77452,7 @@ async function generateDocumentTypes(config2, docs) {
77397
77452
  return;
77398
77453
  }
77399
77454
  const typeDefPath = config2.artifactTypePath(originalDocument);
77400
- const program3 = AST13.program([]);
77455
+ const program3 = AST12.program([]);
77401
77456
  const visitedTypes = /* @__PURE__ */ new Set();
77402
77457
  let definition = originalDocument.definitions.find(
77403
77458
  (def) => (def.kind === "OperationDefinition" || def.kind === "FragmentDefinition") && def.name?.value === name
@@ -77433,9 +77488,9 @@ async function generateDocumentTypes(config2, docs) {
77433
77488
  );
77434
77489
  }
77435
77490
  program3.body.push(
77436
- AST13.exportNamedDeclaration(
77437
- AST13.tsTypeAliasDeclaration(
77438
- AST13.identifier(`${name}$artifact`),
77491
+ AST12.exportNamedDeclaration(
77492
+ AST12.tsTypeAliasDeclaration(
77493
+ AST12.identifier(`${name}$artifact`),
77439
77494
  convertToTs(serializeValue(artifact))
77440
77495
  )
77441
77496
  )
@@ -77445,17 +77500,17 @@ async function generateDocumentTypes(config2, docs) {
77445
77500
  typePaths.push(typeDefPath);
77446
77501
  })
77447
77502
  );
77448
- const typeIndex = AST13.program(
77503
+ const typeIndex = AST12.program(
77449
77504
  typePaths.sort((a, b) => a.localeCompare(b)).map((typePath) => {
77450
- return AST13.exportAllDeclaration(
77451
- AST13.literal(
77505
+ return AST12.exportAllDeclaration(
77506
+ AST12.literal(
77452
77507
  "./" + path_exports.relative(path_exports.resolve(config2.typeIndexPath, ".."), typePath).replace(/\.[^/.]+\.[^/.]+$/, "")
77453
77508
  ),
77454
77509
  null
77455
77510
  );
77456
77511
  }).concat([
77457
- AST13.exportAllDeclaration(AST13.literal("./runtime"), null),
77458
- AST13.exportAllDeclaration(AST13.literal("./graphql"), null)
77512
+ AST12.exportAllDeclaration(AST12.literal("./runtime"), null),
77513
+ AST12.exportAllDeclaration(AST12.literal("./graphql"), null)
77459
77514
  ])
77460
77515
  );
77461
77516
  const exportDefaultAs = ({ module: module2, as }) => `
@@ -77510,7 +77565,7 @@ For more information, please visit this link: ${siteURL}/api/config#custom-scala
77510
77565
  }
77511
77566
  function convertToTs(source) {
77512
77567
  if (source.type === "ObjectExpression") {
77513
- return AST13.tsTypeLiteral(
77568
+ return AST12.tsTypeLiteral(
77514
77569
  source.properties.reduce(
77515
77570
  (props, prop) => {
77516
77571
  if (prop.type !== "ObjectProperty" || prop.key.type !== "StringLiteral" && prop.key.type === "Identifier") {
@@ -77518,9 +77573,9 @@ function convertToTs(source) {
77518
77573
  }
77519
77574
  return [
77520
77575
  ...props,
77521
- AST13.tsPropertySignature(
77576
+ AST12.tsPropertySignature(
77522
77577
  prop.key,
77523
- AST13.tsTypeAnnotation(convertToTs(prop.value))
77578
+ AST12.tsTypeAnnotation(convertToTs(prop.value))
77524
77579
  )
77525
77580
  ];
77526
77581
  },
@@ -77529,20 +77584,20 @@ function convertToTs(source) {
77529
77584
  );
77530
77585
  }
77531
77586
  if (source.type === "ArrayExpression") {
77532
- return AST13.tsTupleType(
77587
+ return AST12.tsTupleType(
77533
77588
  source.elements.map((element) => convertToTs(element))
77534
77589
  );
77535
77590
  }
77536
77591
  if (source.type === "Literal" && typeof source.value === "boolean") {
77537
- return AST13.tsLiteralType(AST13.booleanLiteral(source.value));
77592
+ return AST12.tsLiteralType(AST12.booleanLiteral(source.value));
77538
77593
  }
77539
77594
  if (source.type === "Literal" && typeof source.value === "number") {
77540
- return AST13.tsLiteralType(AST13.numericLiteral(source.value));
77595
+ return AST12.tsLiteralType(AST12.numericLiteral(source.value));
77541
77596
  }
77542
77597
  if (source.type === "Literal" && typeof source.value === "string") {
77543
- return AST13.tsLiteralType(AST13.stringLiteral(source.value));
77598
+ return AST12.tsLiteralType(AST12.stringLiteral(source.value));
77544
77599
  }
77545
- return AST13.tsLiteralType(source);
77600
+ return AST12.tsLiteralType(source);
77546
77601
  }
77547
77602
  async function generateOperationTypeDefs(config2, filepath, document, body, definition, selections, visitedTypes, missingScalars, artifact) {
77548
77603
  let parentType = null;
@@ -77581,23 +77636,23 @@ async function generateOperationTypeDefs(config2, filepath, document, body, defi
77581
77636
  });
77582
77637
  }
77583
77638
  body.push(
77584
- AST13.exportNamedDeclaration(
77585
- AST13.tsTypeAliasDeclaration(
77586
- AST13.identifier(definition.name.value),
77587
- AST13.tsTypeLiteral([
77639
+ AST12.exportNamedDeclaration(
77640
+ AST12.tsTypeAliasDeclaration(
77641
+ AST12.identifier(definition.name.value),
77642
+ AST12.tsTypeLiteral([
77588
77643
  readonlyProperty(
77589
- AST13.tsPropertySignature(
77590
- AST13.stringLiteral("input"),
77591
- AST13.tsTypeAnnotation(AST13.tsTypeReference(AST13.identifier(inputTypeName)))
77644
+ AST12.tsPropertySignature(
77645
+ AST12.stringLiteral("input"),
77646
+ AST12.tsTypeAnnotation(AST12.tsTypeReference(AST12.identifier(inputTypeName)))
77592
77647
  )
77593
77648
  ),
77594
77649
  readonlyProperty(
77595
- AST13.tsPropertySignature(
77596
- AST13.stringLiteral("result"),
77597
- AST13.tsTypeAnnotation(
77598
- definition.operation === "mutation" ? AST13.tsTypeReference(AST13.identifier(shapeTypeName)) : AST13.tsUnionType([
77599
- AST13.tsTypeReference(AST13.identifier(shapeTypeName)),
77600
- AST13.tsUndefinedKeyword()
77650
+ AST12.tsPropertySignature(
77651
+ AST12.stringLiteral("result"),
77652
+ AST12.tsTypeAnnotation(
77653
+ definition.operation === "mutation" ? AST12.tsTypeReference(AST12.identifier(shapeTypeName)) : AST12.tsUnionType([
77654
+ AST12.tsTypeReference(AST12.identifier(shapeTypeName)),
77655
+ AST12.tsUndefinedKeyword()
77601
77656
  ])
77602
77657
  )
77603
77658
  )
@@ -77605,8 +77660,8 @@ async function generateOperationTypeDefs(config2, filepath, document, body, defi
77605
77660
  ])
77606
77661
  )
77607
77662
  ),
77608
- AST13.exportNamedDeclaration(
77609
- AST13.tsTypeAliasDeclaration(AST13.identifier(shapeTypeName), resultType)
77663
+ AST12.exportNamedDeclaration(
77664
+ AST12.tsTypeAliasDeclaration(AST12.identifier(shapeTypeName), resultType)
77610
77665
  )
77611
77666
  );
77612
77667
  if (hasInputs && definition.variableDefinitions && definition.variableDefinitions.length > 0) {
@@ -77621,15 +77676,15 @@ async function generateOperationTypeDefs(config2, filepath, document, body, defi
77621
77676
  );
77622
77677
  }
77623
77678
  body.push(
77624
- AST13.exportNamedDeclaration(
77625
- AST13.tsTypeAliasDeclaration(
77626
- AST13.identifier(inputTypeName),
77627
- AST13.tsTypeLiteral(
77679
+ AST12.exportNamedDeclaration(
77680
+ AST12.tsTypeAliasDeclaration(
77681
+ AST12.identifier(inputTypeName),
77682
+ AST12.tsTypeLiteral(
77628
77683
  (definition.variableDefinitions || []).map(
77629
77684
  (definition2) => {
77630
- return AST13.tsPropertySignature(
77631
- AST13.identifier(definition2.variable.name.value),
77632
- AST13.tsTypeAnnotation(
77685
+ return AST12.tsPropertySignature(
77686
+ AST12.identifier(definition2.variable.name.value),
77687
+ AST12.tsTypeAnnotation(
77633
77688
  tsTypeReference(config2, missingScalars, definition2, body)
77634
77689
  ),
77635
77690
  definition2.type.kind !== "NonNullType"
@@ -77642,16 +77697,16 @@ async function generateOperationTypeDefs(config2, filepath, document, body, defi
77642
77697
  );
77643
77698
  } else {
77644
77699
  body.push(
77645
- AST13.exportNamedDeclaration(
77646
- AST13.tsTypeAliasDeclaration(AST13.identifier(inputTypeName), AST13.tsNullKeyword())
77700
+ AST12.exportNamedDeclaration(
77701
+ AST12.tsTypeAliasDeclaration(AST12.identifier(inputTypeName), AST12.tsNullKeyword())
77647
77702
  )
77648
77703
  );
77649
77704
  }
77650
77705
  if (definition.operation === "mutation") {
77651
77706
  body.push(
77652
- AST13.exportNamedDeclaration(
77653
- AST13.tsTypeAliasDeclaration(
77654
- AST13.identifier(optimisticTypeName),
77707
+ AST12.exportNamedDeclaration(
77708
+ AST12.tsTypeAliasDeclaration(
77709
+ AST12.identifier(optimisticTypeName),
77655
77710
  inlineType({
77656
77711
  config: config2,
77657
77712
  filepath,
@@ -77685,12 +77740,12 @@ async function generateFragmentTypeDefs(config2, filepath, body, selections, def
77685
77740
  let directive = definition.directives?.find(
77686
77741
  (directive2) => directive2.name.value === config2.argumentsDirective
77687
77742
  );
77688
- let inputValue = !directive ? AST13.tsTypeLiteral([]) : AST13.tsTypeLiteral(
77743
+ let inputValue = !directive ? AST12.tsTypeLiteral([]) : AST12.tsTypeLiteral(
77689
77744
  (fragmentArgumentsDefinitions(config2, filepath, definition) || []).map(
77690
77745
  (definition2) => {
77691
- return AST13.tsPropertySignature(
77692
- AST13.identifier(definition2.variable.name.value),
77693
- AST13.tsTypeAnnotation(
77746
+ return AST12.tsPropertySignature(
77747
+ AST12.identifier(definition2.variable.name.value),
77748
+ AST12.tsTypeAnnotation(
77694
77749
  tsTypeReference(config2, missingScalars, definition2, body)
77695
77750
  ),
77696
77751
  definition2.type.kind !== "NonNullType"
@@ -77699,30 +77754,30 @@ async function generateFragmentTypeDefs(config2, filepath, body, selections, def
77699
77754
  )
77700
77755
  );
77701
77756
  body.push(
77702
- AST13.exportNamedDeclaration(
77703
- AST13.tsTypeAliasDeclaration(AST13.identifier(inputTypeName), inputValue)
77757
+ AST12.exportNamedDeclaration(
77758
+ AST12.tsTypeAliasDeclaration(AST12.identifier(inputTypeName), inputValue)
77704
77759
  ),
77705
- AST13.exportNamedDeclaration(
77706
- AST13.tsTypeAliasDeclaration(
77707
- AST13.identifier(propTypeName),
77708
- AST13.tsTypeLiteral([
77760
+ AST12.exportNamedDeclaration(
77761
+ AST12.tsTypeAliasDeclaration(
77762
+ AST12.identifier(propTypeName),
77763
+ AST12.tsTypeLiteral([
77709
77764
  readonlyProperty(
77710
- AST13.tsPropertySignature(
77711
- AST13.stringLiteral("shape"),
77712
- AST13.tsTypeAnnotation(
77713
- AST13.tsTypeReference(AST13.identifier(shapeTypeName))
77765
+ AST12.tsPropertySignature(
77766
+ AST12.stringLiteral("shape"),
77767
+ AST12.tsTypeAnnotation(
77768
+ AST12.tsTypeReference(AST12.identifier(shapeTypeName))
77714
77769
  ),
77715
77770
  true
77716
77771
  )
77717
77772
  ),
77718
77773
  readonlyProperty(
77719
- AST13.tsPropertySignature(
77720
- AST13.stringLiteral(fragmentKey2),
77721
- AST13.tsTypeAnnotation(
77722
- AST13.tsTypeLiteral([
77723
- AST13.tsPropertySignature(
77724
- AST13.stringLiteral(propTypeName),
77725
- AST13.tsTypeAnnotation(AST13.tsAnyKeyword())
77774
+ AST12.tsPropertySignature(
77775
+ AST12.stringLiteral(fragmentKey2),
77776
+ AST12.tsTypeAnnotation(
77777
+ AST12.tsTypeLiteral([
77778
+ AST12.tsPropertySignature(
77779
+ AST12.stringLiteral(propTypeName),
77780
+ AST12.tsTypeAnnotation(AST12.tsAnyKeyword())
77726
77781
  )
77727
77782
  ])
77728
77783
  )
@@ -77731,9 +77786,9 @@ async function generateFragmentTypeDefs(config2, filepath, body, selections, def
77731
77786
  ])
77732
77787
  )
77733
77788
  ),
77734
- AST13.exportNamedDeclaration(
77735
- AST13.tsTypeAliasDeclaration(
77736
- AST13.identifier(shapeTypeName),
77789
+ AST12.exportNamedDeclaration(
77790
+ AST12.tsTypeAliasDeclaration(
77791
+ AST12.identifier(shapeTypeName),
77737
77792
  withLoadingState({
77738
77793
  config: config2,
77739
77794
  document,
@@ -77759,8 +77814,8 @@ async function generateFragmentTypeDefs(config2, filepath, body, selections, def
77759
77814
 
77760
77815
  // src/codegen/generators/typescript/imperativeTypeDef.ts
77761
77816
  var graphql19 = __toESM(require_graphql2(), 1);
77762
- var recast14 = __toESM(require_main2(), 1);
77763
- var AST14 = recast14.types.builders;
77817
+ var recast13 = __toESM(require_main2(), 1);
77818
+ var AST13 = recast13.types.builders;
77764
77819
  async function imperativeCacheTypef(config2, docs) {
77765
77820
  const returnType = (doc) => config2.plugins.find((plugin2) => plugin2.graphqlTagReturn)?.graphqlTagReturn?.({
77766
77821
  config: config2,
@@ -77776,87 +77831,87 @@ async function imperativeCacheTypef(config2, docs) {
77776
77831
  }) ?? "any";
77777
77832
  const target = path_exports.join(config2.runtimeDirectory, "generated.d.ts");
77778
77833
  const body = [];
77779
- const declaration = AST14.tsTypeAliasDeclaration(
77780
- AST14.identifier(CacheTypeDefName),
77781
- AST14.tsTypeLiteral([
77782
- AST14.tsPropertySignature(
77783
- AST14.identifier("types"),
77784
- AST14.tsTypeAnnotation(typeDefinitions(config2, body, docs, returnType))
77834
+ const declaration = AST13.tsTypeAliasDeclaration(
77835
+ AST13.identifier(CacheTypeDefName),
77836
+ AST13.tsTypeLiteral([
77837
+ AST13.tsPropertySignature(
77838
+ AST13.identifier("types"),
77839
+ AST13.tsTypeAnnotation(typeDefinitions(config2, body, docs, returnType))
77785
77840
  ),
77786
- AST14.tsPropertySignature(
77787
- AST14.identifier("lists"),
77788
- AST14.tsTypeAnnotation(listDefinitions(config2, body, docs))
77841
+ AST13.tsPropertySignature(
77842
+ AST13.identifier("lists"),
77843
+ AST13.tsTypeAnnotation(listDefinitions(config2, body, docs))
77789
77844
  ),
77790
- AST14.tsPropertySignature(
77791
- AST14.identifier("queries"),
77792
- AST14.tsTypeAnnotation(queryDefinitions(config2, body, docs, returnType))
77845
+ AST13.tsPropertySignature(
77846
+ AST13.identifier("queries"),
77847
+ AST13.tsTypeAnnotation(queryDefinitions(config2, body, docs, returnType))
77793
77848
  )
77794
77849
  ])
77795
77850
  );
77796
77851
  declaration.declare = true;
77797
- const importRecord = AST14.importDeclaration(
77798
- [AST14.importSpecifier(AST14.identifier("Record"))],
77799
- AST14.stringLiteral("./public/record")
77852
+ const importRecord = AST13.importDeclaration(
77853
+ [AST13.importSpecifier(AST13.identifier("Record"))],
77854
+ AST13.stringLiteral("./public/record")
77800
77855
  );
77801
77856
  importRecord.importKind = "type";
77802
77857
  await fs_exports.writeFile(
77803
77858
  target,
77804
- recast14.prettyPrint(
77805
- AST14.program([importRecord, ...body, AST14.exportNamedDeclaration(declaration)])
77859
+ recast13.prettyPrint(
77860
+ AST13.program([importRecord, ...body, AST13.exportNamedDeclaration(declaration)])
77806
77861
  ).code
77807
77862
  );
77808
77863
  }
77809
77864
  function typeDefinitions(config2, body, docs, returnType) {
77810
77865
  const operationTypes = [config2.schema.getMutationType(), config2.schema.getSubscriptionType()].filter(Boolean).map((type) => type?.name);
77811
77866
  const visitedTypes = /* @__PURE__ */ new Set();
77812
- const types18 = Object.values(config2.schema.getTypeMap()).filter(
77867
+ const types17 = Object.values(config2.schema.getTypeMap()).filter(
77813
77868
  (type) => !graphql19.isAbstractType(type) && !graphql19.isScalarType(type) && !graphql19.isEnumType(type) && !graphql19.isInputObjectType(type) && !type.name.startsWith("__") && !operationTypes.includes(type.name)
77814
77869
  );
77815
77870
  const fragmentMap = fragmentListMap(
77816
77871
  config2,
77817
- types18.map((type) => type.name),
77872
+ types17.map((type) => type.name),
77818
77873
  body,
77819
77874
  docs,
77820
77875
  returnType
77821
77876
  );
77822
- return AST14.tsTypeLiteral(
77823
- types18.map((type) => {
77877
+ return AST13.tsTypeLiteral(
77878
+ types17.map((type) => {
77824
77879
  let typeName = type.name;
77825
77880
  if (config2.schema.getQueryType() && config2.schema.getQueryType()?.name === type.name) {
77826
77881
  typeName = "__ROOT__";
77827
77882
  }
77828
- let idFields = AST14.tsNeverKeyword();
77883
+ let idFields = AST13.tsNeverKeyword();
77829
77884
  const keys2 = keyFieldsForType(config2.configFile, type.name);
77830
77885
  if (graphql19.isObjectType(type) && keys2.length > 0 && keys2.every((key) => type.getFields()[key])) {
77831
- idFields = AST14.tsTypeLiteral(
77886
+ idFields = AST13.tsTypeLiteral(
77832
77887
  keys2.map((key) => {
77833
77888
  const fieldType = type.getFields()[key];
77834
77889
  const unwrapped = unwrapType(config2, fieldType.type);
77835
- return AST14.tsPropertySignature(
77836
- AST14.identifier(key),
77837
- AST14.tsTypeAnnotation(
77890
+ return AST13.tsPropertySignature(
77891
+ AST13.identifier(key),
77892
+ AST13.tsTypeAnnotation(
77838
77893
  scalarPropertyValue(config2, /* @__PURE__ */ new Set(), unwrapped.type)
77839
77894
  )
77840
77895
  );
77841
77896
  })
77842
77897
  );
77843
77898
  } else if (typeName === "__ROOT__") {
77844
- idFields = AST14.tsTypeLiteral([]);
77899
+ idFields = AST13.tsTypeLiteral([]);
77845
77900
  }
77846
- let fields = AST14.tsTypeLiteral([]);
77901
+ let fields = AST13.tsTypeLiteral([]);
77847
77902
  if (graphql19.isObjectType(type)) {
77848
- fields = AST14.tsTypeLiteral(
77903
+ fields = AST13.tsTypeLiteral(
77849
77904
  Object.entries(type.getFields()).map(
77850
77905
  ([key, fieldType]) => {
77851
77906
  const unwrapped = unwrapType(config2, fieldType.type);
77852
- let typeOptions = AST14.tsUnionType([]);
77907
+ let typeOptions = AST13.tsUnionType([]);
77853
77908
  if (graphql19.isScalarType(unwrapped.type)) {
77854
77909
  typeOptions.types.push(
77855
77910
  scalarPropertyValue(config2, /* @__PURE__ */ new Set(), unwrapped.type)
77856
77911
  );
77857
77912
  } else if (graphql19.isEnumType(unwrapped.type)) {
77858
77913
  typeOptions.types.push(
77859
- AST14.tsTypeReference(AST14.identifier(unwrapped.type.name))
77914
+ AST13.tsTypeReference(AST13.identifier(unwrapped.type.name))
77860
77915
  );
77861
77916
  } else if (!graphql19.isAbstractType(unwrapped.type)) {
77862
77917
  typeOptions.types.push(record(unwrapped.type.name));
@@ -77867,21 +77922,21 @@ function typeDefinitions(config2, body, docs, returnType) {
77867
77922
  }
77868
77923
  for (const wrapper of unwrapped.wrappers) {
77869
77924
  if (wrapper === "Nullable" /* Nullable */) {
77870
- typeOptions = AST14.tsParenthesizedType(
77871
- AST14.tsUnionType([typeOptions, AST14.tsNullKeyword()])
77925
+ typeOptions = AST13.tsParenthesizedType(
77926
+ AST13.tsUnionType([typeOptions, AST13.tsNullKeyword()])
77872
77927
  );
77873
77928
  } else if (wrapper === "List" /* List */) {
77874
- typeOptions = AST14.tsArrayType(
77875
- AST14.tsParenthesizedType(typeOptions)
77929
+ typeOptions = AST13.tsArrayType(
77930
+ AST13.tsParenthesizedType(typeOptions)
77876
77931
  );
77877
77932
  }
77878
77933
  }
77879
77934
  if (typeOptions.type === "TSParenthesizedType") {
77880
77935
  typeOptions = typeOptions.typeAnnotation;
77881
77936
  }
77882
- let args = AST14.tsNeverKeyword();
77937
+ let args = AST13.tsNeverKeyword();
77883
77938
  if (fieldType.args?.length > 0) {
77884
- args = AST14.tsTypeLiteral(
77939
+ args = AST13.tsTypeLiteral(
77885
77940
  fieldType.args.map((arg) => {
77886
77941
  addReferencedInputTypes(
77887
77942
  config2,
@@ -77891,9 +77946,9 @@ function typeDefinitions(config2, body, docs, returnType) {
77891
77946
  /* @__PURE__ */ new Set(),
77892
77947
  arg.type
77893
77948
  );
77894
- const prop = AST14.tsPropertySignature(
77895
- AST14.identifier(arg.name),
77896
- AST14.tsTypeAnnotation(
77949
+ const prop = AST13.tsPropertySignature(
77950
+ AST13.identifier(arg.name),
77951
+ AST13.tsTypeAnnotation(
77897
77952
  tsTypeReference(config2, /* @__PURE__ */ new Set(), arg, body)
77898
77953
  )
77899
77954
  );
@@ -77903,17 +77958,17 @@ function typeDefinitions(config2, body, docs, returnType) {
77903
77958
  })
77904
77959
  );
77905
77960
  }
77906
- return AST14.tsPropertySignature(
77907
- AST14.identifier(key),
77908
- AST14.tsTypeAnnotation(
77909
- AST14.tsTypeLiteral([
77910
- AST14.tsPropertySignature(
77911
- AST14.identifier("type"),
77912
- AST14.tsTypeAnnotation(typeOptions)
77961
+ return AST13.tsPropertySignature(
77962
+ AST13.identifier(key),
77963
+ AST13.tsTypeAnnotation(
77964
+ AST13.tsTypeLiteral([
77965
+ AST13.tsPropertySignature(
77966
+ AST13.identifier("type"),
77967
+ AST13.tsTypeAnnotation(typeOptions)
77913
77968
  ),
77914
- AST14.tsPropertySignature(
77915
- AST14.identifier("args"),
77916
- AST14.tsTypeAnnotation(args)
77969
+ AST13.tsPropertySignature(
77970
+ AST13.identifier("args"),
77971
+ AST13.tsTypeAnnotation(args)
77917
77972
  )
77918
77973
  ])
77919
77974
  )
@@ -77922,21 +77977,21 @@ function typeDefinitions(config2, body, docs, returnType) {
77922
77977
  )
77923
77978
  );
77924
77979
  }
77925
- return AST14.tsPropertySignature(
77926
- AST14.identifier(typeName),
77927
- AST14.tsTypeAnnotation(
77928
- AST14.tsTypeLiteral([
77929
- AST14.tsPropertySignature(
77930
- AST14.identifier("idFields"),
77931
- AST14.tsTypeAnnotation(idFields)
77980
+ return AST13.tsPropertySignature(
77981
+ AST13.identifier(typeName),
77982
+ AST13.tsTypeAnnotation(
77983
+ AST13.tsTypeLiteral([
77984
+ AST13.tsPropertySignature(
77985
+ AST13.identifier("idFields"),
77986
+ AST13.tsTypeAnnotation(idFields)
77932
77987
  ),
77933
- AST14.tsPropertySignature(
77934
- AST14.identifier("fields"),
77935
- AST14.tsTypeAnnotation(fields)
77988
+ AST13.tsPropertySignature(
77989
+ AST13.identifier("fields"),
77990
+ AST13.tsTypeAnnotation(fields)
77936
77991
  ),
77937
- AST14.tsPropertySignature(
77938
- AST14.identifier("fragments"),
77939
- AST14.tsTypeAnnotation(fragmentMap[typeName] ?? AST14.tsTupleType([]))
77992
+ AST13.tsPropertySignature(
77993
+ AST13.identifier("fragments"),
77994
+ AST13.tsTypeAnnotation(fragmentMap[typeName] ?? AST13.tsTupleType([]))
77940
77995
  )
77941
77996
  ])
77942
77997
  )
@@ -77978,28 +78033,28 @@ function listDefinitions(config2, body, docs) {
77978
78033
  possibleTypes.push(listType.name);
77979
78034
  }
77980
78035
  lists.push(
77981
- AST14.tsPropertySignature(
77982
- AST14.identifier(nameValue),
77983
- AST14.tsTypeAnnotation(
77984
- AST14.tsTypeLiteral([
77985
- AST14.tsPropertySignature(
77986
- AST14.identifier("types"),
77987
- AST14.tsTypeAnnotation(
77988
- AST14.tsUnionType(
78036
+ AST13.tsPropertySignature(
78037
+ AST13.identifier(nameValue),
78038
+ AST13.tsTypeAnnotation(
78039
+ AST13.tsTypeLiteral([
78040
+ AST13.tsPropertySignature(
78041
+ AST13.identifier("types"),
78042
+ AST13.tsTypeAnnotation(
78043
+ AST13.tsUnionType(
77989
78044
  possibleTypes.map(
77990
- (possible) => AST14.tsLiteralType(AST14.stringLiteral(possible))
78045
+ (possible) => AST13.tsLiteralType(AST13.stringLiteral(possible))
77991
78046
  )
77992
78047
  )
77993
78048
  )
77994
78049
  ),
77995
- AST14.tsPropertySignature(
77996
- AST14.identifier("filters"),
77997
- AST14.tsTypeAnnotation(
77998
- targetFieldDefinition.args.length === 0 ? AST14.tsNeverKeyword() : AST14.tsTypeLiteral(
78050
+ AST13.tsPropertySignature(
78051
+ AST13.identifier("filters"),
78052
+ AST13.tsTypeAnnotation(
78053
+ targetFieldDefinition.args.length === 0 ? AST13.tsNeverKeyword() : AST13.tsTypeLiteral(
77999
78054
  targetFieldDefinition.args.map((arg) => {
78000
- const argDef = AST14.tsPropertySignature(
78001
- AST14.identifier(arg.name),
78002
- AST14.tsTypeAnnotation(
78055
+ const argDef = AST13.tsPropertySignature(
78056
+ AST13.identifier(arg.name),
78057
+ AST13.tsTypeAnnotation(
78003
78058
  tsTypeReference(
78004
78059
  config2,
78005
78060
  /* @__PURE__ */ new Set(),
@@ -78021,10 +78076,10 @@ function listDefinitions(config2, body, docs) {
78021
78076
  }
78022
78077
  });
78023
78078
  }
78024
- return AST14.tsTypeLiteral(lists);
78079
+ return AST13.tsTypeLiteral(lists);
78025
78080
  }
78026
78081
  function queryDefinitions(config2, body, docs, returnType) {
78027
- return AST14.tsTupleType(
78082
+ return AST13.tsTupleType(
78028
78083
  docs.reduce((prev, doc) => {
78029
78084
  if (doc.kind !== ArtifactKind.Query || !doc.generateStore) {
78030
78085
  return prev;
@@ -78046,10 +78101,10 @@ function queryDefinitions(config2, body, docs, returnType) {
78046
78101
  import: [`${doc.name}$result`, `${doc.name}$input`]
78047
78102
  });
78048
78103
  return prev.concat(
78049
- AST14.tsTupleType([
78050
- AST14.tsTypeReference(AST14.identifier(runtimeType)),
78051
- AST14.tsTypeReference(AST14.identifier(shapeType)),
78052
- AST14.tsTypeReference(AST14.identifier(inputType))
78104
+ AST13.tsTupleType([
78105
+ AST13.tsTypeReference(AST13.identifier(runtimeType)),
78106
+ AST13.tsTypeReference(AST13.identifier(shapeType)),
78107
+ AST13.tsTypeReference(AST13.identifier(inputType))
78053
78108
  ])
78054
78109
  );
78055
78110
  }, [])
@@ -78078,13 +78133,13 @@ function fragmentListMap(config2, concreteTypes, body, docs, return_type) {
78078
78133
  ),
78079
78134
  import: [`${definition.name.value}$data`]
78080
78135
  });
78081
- let inputType = AST14.tsNeverKeyword();
78136
+ let inputType = AST13.tsNeverKeyword();
78082
78137
  let directive = definition.directives?.find(
78083
78138
  (directive2) => directive2.name.value === config2.argumentsDirective
78084
78139
  );
78085
78140
  if (directive) {
78086
- inputType = AST14.tsTypeReference(
78087
- AST14.identifier(
78141
+ inputType = AST13.tsTypeReference(
78142
+ AST13.identifier(
78088
78143
  ensureImports({
78089
78144
  config: config2,
78090
78145
  body,
@@ -78099,11 +78154,11 @@ function fragmentListMap(config2, concreteTypes, body, docs, return_type) {
78099
78154
  }
78100
78155
  return {
78101
78156
  ...prev,
78102
- [typeName]: AST14.tsTupleType(
78157
+ [typeName]: AST13.tsTupleType(
78103
78158
  previousValue.concat(
78104
- AST14.tsTupleType([
78105
- AST14.tsTypeReference(AST14.identifier(tagResult)),
78106
- AST14.tsTypeReference(AST14.identifier(shapeType)),
78159
+ AST13.tsTupleType([
78160
+ AST13.tsTypeReference(AST13.identifier(tagResult)),
78161
+ AST13.tsTypeReference(AST13.identifier(shapeType)),
78107
78162
  inputType
78108
78163
  ])
78109
78164
  )
@@ -78113,11 +78168,11 @@ function fragmentListMap(config2, concreteTypes, body, docs, return_type) {
78113
78168
  }
78114
78169
  var CacheTypeDefName = "CacheTypeDef";
78115
78170
  function record(name) {
78116
- return AST14.tsTypeReference(
78117
- AST14.identifier("Record"),
78118
- AST14.tsTypeParameterInstantiation([
78119
- AST14.tsTypeReference(AST14.identifier(CacheTypeDefName)),
78120
- AST14.tsLiteralType(AST14.stringLiteral(name))
78171
+ return AST13.tsTypeReference(
78172
+ AST13.identifier("Record"),
78173
+ AST13.tsTypeParameterInstantiation([
78174
+ AST13.tsTypeReference(AST13.identifier(CacheTypeDefName)),
78175
+ AST13.tsLiteralType(AST13.stringLiteral(name))
78121
78176
  ])
78122
78177
  );
78123
78178
  }
@@ -78170,25 +78225,25 @@ async function persistOutputGenerator(config2, docs) {
78170
78225
 
78171
78226
  // src/codegen/generators/definitions/enums.ts
78172
78227
  var graphql21 = __toESM(require_graphql2(), 1);
78173
- var recast15 = __toESM(require_main2(), 1);
78174
- var AST15 = recast15.types.builders;
78228
+ var recast14 = __toESM(require_main2(), 1);
78229
+ var AST14 = recast14.types.builders;
78175
78230
  async function definitionsGenerator(config2) {
78176
78231
  const enums = graphql21.parse(graphql21.printSchema(config2.schema)).definitions.filter(
78177
78232
  (definition) => definition.kind === "EnumTypeDefinition"
78178
78233
  ).filter((def) => !config2.isInternalEnum(def));
78179
78234
  const { code: runtimeDefinitions } = await printJS(
78180
- AST15.program(
78235
+ AST14.program(
78181
78236
  enums.map((defn) => {
78182
78237
  const name = defn.name.value;
78183
78238
  return moduleExport(
78184
78239
  config2,
78185
78240
  name,
78186
- AST15.objectExpression(
78241
+ AST14.objectExpression(
78187
78242
  defn.values?.map((value) => {
78188
78243
  const str = value.name.value;
78189
- return AST15.objectProperty(
78190
- AST15.stringLiteral(str),
78191
- AST15.stringLiteral(str)
78244
+ return AST14.objectProperty(
78245
+ AST14.stringLiteral(str),
78246
+ AST14.stringLiteral(str)
78192
78247
  );
78193
78248
  }) || []
78194
78249
  )
@@ -80174,8 +80229,8 @@ async function updatePackageJSON(targetPath) {
80174
80229
  }
80175
80230
  packageJSON.devDependencies = {
80176
80231
  ...packageJSON.devDependencies,
80177
- houdini: "^1.2.4",
80178
- "houdini-svelte": "^1.2.4"
80232
+ houdini: "^1.2.6-next.0",
80233
+ "houdini-svelte": "^1.2.6-next.0"
80179
80234
  };
80180
80235
  await fs_exports.writeFile(packagePath, JSON.stringify(packageJSON, null, 4));
80181
80236
  }