houdini-svelte 1.2.44 → 1.2.46

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.
@@ -16414,6 +16414,7 @@ import { deprecate as deprecate2 } from "node:util";
16414
16414
  import * as graphql3 from "graphql";
16415
16415
  import * as graphql4 from "graphql";
16416
16416
  import * as graphql5 from "graphql";
16417
+ import * as graphql6 from "graphql";
16417
16418
  var require2 = conflict_free(import.meta.url);
16418
16419
  var __create2 = Object.create;
16419
16420
  var __defProp2 = Object.defineProperty;
@@ -29862,14 +29863,14 @@ var require_lib3 = __commonJS2({
29862
29863
  this.preserveSpace = !!preserveSpace;
29863
29864
  }
29864
29865
  };
29865
- var types42 = {
29866
+ var types52 = {
29866
29867
  brace: new TokContext3("{"),
29867
29868
  j_oTag: new TokContext3("<tag"),
29868
29869
  j_cTag: new TokContext3("</tag"),
29869
29870
  j_expr: new TokContext3("<tag>...</tag>", true)
29870
29871
  };
29871
29872
  {
29872
- types42.template = new TokContext3("`", true);
29873
+ types52.template = new TokContext3("`", true);
29873
29874
  }
29874
29875
  var beforeExpr2 = true;
29875
29876
  var startsExpr2 = true;
@@ -30407,17 +30408,17 @@ var require_lib3 = __commonJS2({
30407
30408
  context.pop();
30408
30409
  };
30409
30410
  tokenTypes[5].updateContext = tokenTypes[7].updateContext = tokenTypes[23].updateContext = (context) => {
30410
- context.push(types42.brace);
30411
+ context.push(types52.brace);
30411
30412
  };
30412
30413
  tokenTypes[22].updateContext = (context) => {
30413
- if (context[context.length - 1] === types42.template) {
30414
+ if (context[context.length - 1] === types52.template) {
30414
30415
  context.pop();
30415
30416
  } else {
30416
- context.push(types42.template);
30417
+ context.push(types52.template);
30417
30418
  }
30418
30419
  };
30419
30420
  tokenTypes[142].updateContext = (context) => {
30420
- context.push(types42.j_expr, types42.j_oTag);
30421
+ context.push(types52.j_expr, types52.j_oTag);
30421
30422
  };
30422
30423
  }
30423
30424
  var nonASCIIidentifierStartChars2 = "\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";
@@ -30977,7 +30978,7 @@ var require_lib3 = __commonJS2({
30977
30978
  this.end = 0;
30978
30979
  this.lastTokEndLoc = null;
30979
30980
  this.lastTokStartLoc = null;
30980
- this.context = [types42.brace];
30981
+ this.context = [types52.brace];
30981
30982
  this.firstInvalidTemplateEscapePos = null;
30982
30983
  this.strictErrors = /* @__PURE__ */ new Map();
30983
30984
  this.tokensLength = 0;
@@ -34804,7 +34805,7 @@ var require_lib3 = __commonJS2({
34804
34805
  context
34805
34806
  } = this.state;
34806
34807
  const currentContext = context[context.length - 1];
34807
- if (currentContext === types42.j_oTag || currentContext === types42.j_expr) {
34808
+ if (currentContext === types52.j_oTag || currentContext === types52.j_expr) {
34808
34809
  context.pop();
34809
34810
  }
34810
34811
  }
@@ -35826,9 +35827,9 @@ var require_lib3 = __commonJS2({
35826
35827
  switch (this.state.type) {
35827
35828
  case 5:
35828
35829
  node2 = this.startNode();
35829
- this.setContext(types42.brace);
35830
+ this.setContext(types52.brace);
35830
35831
  this.next();
35831
- node2 = this.jsxParseExpressionContainer(node2, types42.j_oTag);
35832
+ node2 = this.jsxParseExpressionContainer(node2, types52.j_oTag);
35832
35833
  if (node2.expression.type === "JSXEmptyExpression") {
35833
35834
  this.raise(JsxErrors.AttributeIsEmpty, node2);
35834
35835
  }
@@ -35847,7 +35848,7 @@ var require_lib3 = __commonJS2({
35847
35848
  jsxParseSpreadChild(node2) {
35848
35849
  this.next();
35849
35850
  node2.expression = this.parseExpression();
35850
- this.setContext(types42.j_expr);
35851
+ this.setContext(types52.j_expr);
35851
35852
  this.state.canStartJSXElement = true;
35852
35853
  this.expect(8);
35853
35854
  return this.finishNode(node2, "JSXSpreadChild");
@@ -35867,11 +35868,11 @@ var require_lib3 = __commonJS2({
35867
35868
  jsxParseAttribute() {
35868
35869
  const node2 = this.startNode();
35869
35870
  if (this.match(5)) {
35870
- this.setContext(types42.brace);
35871
+ this.setContext(types52.brace);
35871
35872
  this.next();
35872
35873
  this.expect(21);
35873
35874
  node2.argument = this.parseMaybeAssignAllowIn();
35874
- this.setContext(types42.j_oTag);
35875
+ this.setContext(types52.j_oTag);
35875
35876
  this.state.canStartJSXElement = true;
35876
35877
  this.expect(8);
35877
35878
  return this.finishNode(node2, "JSXSpreadAttribute");
@@ -35930,12 +35931,12 @@ var require_lib3 = __commonJS2({
35930
35931
  break;
35931
35932
  case 5: {
35932
35933
  const node22 = this.startNode();
35933
- this.setContext(types42.brace);
35934
+ this.setContext(types52.brace);
35934
35935
  this.next();
35935
35936
  if (this.match(21)) {
35936
35937
  children.push(this.jsxParseSpreadChild(node22));
35937
35938
  } else {
35938
- children.push(this.jsxParseExpressionContainer(node22, types42.j_expr));
35939
+ children.push(this.jsxParseExpressionContainer(node22, types52.j_expr));
35939
35940
  }
35940
35941
  break;
35941
35942
  }
@@ -36000,11 +36001,11 @@ var require_lib3 = __commonJS2({
36000
36001
  }
36001
36002
  getTokenFromCode(code2) {
36002
36003
  const context = this.curContext();
36003
- if (context === types42.j_expr) {
36004
+ if (context === types52.j_expr) {
36004
36005
  this.jsxReadToken();
36005
36006
  return;
36006
36007
  }
36007
- if (context === types42.j_oTag || context === types42.j_cTag) {
36008
+ if (context === types52.j_oTag || context === types52.j_cTag) {
36008
36009
  if (isIdentifierStart2(code2)) {
36009
36010
  this.jsxReadWord();
36010
36011
  return;
@@ -36014,7 +36015,7 @@ var require_lib3 = __commonJS2({
36014
36015
  this.finishToken(143);
36015
36016
  return;
36016
36017
  }
36017
- if ((code2 === 34 || code2 === 39) && context === types42.j_oTag) {
36018
+ if ((code2 === 34 || code2 === 39) && context === types52.j_oTag) {
36018
36019
  this.jsxReadString(code2);
36019
36020
  return;
36020
36021
  }
@@ -36032,17 +36033,17 @@ var require_lib3 = __commonJS2({
36032
36033
  type
36033
36034
  } = this.state;
36034
36035
  if (type === 56 && prevType === 142) {
36035
- context.splice(-2, 2, types42.j_cTag);
36036
+ context.splice(-2, 2, types52.j_cTag);
36036
36037
  this.state.canStartJSXElement = false;
36037
36038
  } else if (type === 142) {
36038
- context.push(types42.j_oTag);
36039
+ context.push(types52.j_oTag);
36039
36040
  } else if (type === 143) {
36040
36041
  const out = context[context.length - 1];
36041
- if (out === types42.j_oTag && prevType === 56 || out === types42.j_cTag) {
36042
+ if (out === types52.j_oTag && prevType === 56 || out === types52.j_cTag) {
36042
36043
  context.pop();
36043
- this.state.canStartJSXElement = context[context.length - 1] === types42.j_expr;
36044
+ this.state.canStartJSXElement = context[context.length - 1] === types52.j_expr;
36044
36045
  } else {
36045
- this.setContext(types42.j_expr);
36046
+ this.setContext(types52.j_expr);
36046
36047
  this.state.canStartJSXElement = true;
36047
36048
  }
36048
36049
  } else {
@@ -37417,14 +37418,14 @@ var require_lib3 = __commonJS2({
37417
37418
  tsParseUnionOrIntersectionType(kind, parseConstituentType, operator) {
37418
37419
  const node2 = this.startNode();
37419
37420
  const hasLeadingOperator = this.eat(operator);
37420
- const types52 = [];
37421
+ const types62 = [];
37421
37422
  do {
37422
- types52.push(parseConstituentType());
37423
+ types62.push(parseConstituentType());
37423
37424
  } while (this.eat(operator));
37424
- if (types52.length === 1 && !hasLeadingOperator) {
37425
- return types52[0];
37425
+ if (types62.length === 1 && !hasLeadingOperator) {
37426
+ return types62[0];
37426
37427
  }
37427
- node2.types = types52;
37428
+ node2.types = types62;
37428
37429
  return this.finishNode(node2, kind);
37429
37430
  }
37430
37431
  tsParseIntersectionTypeOrHigher() {
@@ -37988,7 +37989,7 @@ var require_lib3 = __commonJS2({
37988
37989
  }));
37989
37990
  if (node2.params.length === 0) {
37990
37991
  this.raise(TSErrors.EmptyTypeArguments, node2);
37991
- } else if (!this.state.inType && this.curContext() === types42.brace) {
37992
+ } else if (!this.state.inType && this.curContext() === types52.brace) {
37992
37993
  this.reScan_lt_gt();
37993
37994
  }
37994
37995
  this.expect(48);
@@ -38614,7 +38615,7 @@ var require_lib3 = __commonJS2({
38614
38615
  context
38615
38616
  } = this.state;
38616
38617
  const currentContext = context[context.length - 1];
38617
- if (currentContext === types42.j_oTag || currentContext === types42.j_expr) {
38618
+ if (currentContext === types52.j_oTag || currentContext === types52.j_expr) {
38618
38619
  context.pop();
38619
38620
  }
38620
38621
  }
@@ -43742,9 +43743,9 @@ var require_shared = __commonJS2({
43742
43743
  var tslib_1 = require_tslib();
43743
43744
  var types_110 = tslib_1.__importDefault(require_types());
43744
43745
  function default_1(fork) {
43745
- var types42 = fork.use(types_110.default);
43746
- var Type = types42.Type;
43747
- var builtin = types42.builtInTypes;
43746
+ var types52 = fork.use(types_110.default);
43747
+ var Type = types52.Type;
43748
+ var builtin = types52.builtInTypes;
43748
43749
  var isNumber2 = builtin.number;
43749
43750
  function geq(than) {
43750
43751
  return Type.from(function(value2) {
@@ -43892,9 +43893,9 @@ var require_types = __commonJS2({
43892
43893
  }(BaseType);
43893
43894
  var OrType = function(_super) {
43894
43895
  tslib_1.__extends(OrType2, _super);
43895
- function OrType2(types42) {
43896
+ function OrType2(types52) {
43896
43897
  var _this = _super.call(this) || this;
43897
- _this.types = types42;
43898
+ _this.types = types52;
43898
43899
  _this.kind = "OrType";
43899
43900
  return _this;
43900
43901
  }
@@ -44035,11 +44036,11 @@ var require_types = __commonJS2({
44035
44036
  function typesPlugin(_fork) {
44036
44037
  var Type = {
44037
44038
  or: function() {
44038
- var types42 = [];
44039
+ var types52 = [];
44039
44040
  for (var _i = 0; _i < arguments.length; _i++) {
44040
- types42[_i] = arguments[_i];
44041
+ types52[_i] = arguments[_i];
44041
44042
  }
44042
- return new OrType(types42.map(function(type) {
44043
+ return new OrType(types52.map(function(type) {
44043
44044
  return Type.from(type);
44044
44045
  }));
44045
44046
  },
@@ -44482,9 +44483,9 @@ var require_path2 = __commonJS2({
44482
44483
  var Op = Object.prototype;
44483
44484
  var hasOwn2 = Op.hasOwnProperty;
44484
44485
  function pathPlugin(fork) {
44485
- var types42 = fork.use(types_110.default);
44486
- var isArray2 = types42.builtInTypes.array;
44487
- var isNumber2 = types42.builtInTypes.number;
44486
+ var types52 = fork.use(types_110.default);
44487
+ var isArray2 = types52.builtInTypes.array;
44488
+ var isNumber2 = types52.builtInTypes.number;
44488
44489
  var Path = function Path2(value2, parentPath, name) {
44489
44490
  if (!(this instanceof Path2)) {
44490
44491
  throw new Error("Path constructor cannot be invoked without 'new'");
@@ -44784,13 +44785,13 @@ var require_scope = __commonJS2({
44784
44785
  var types_110 = tslib_1.__importDefault(require_types());
44785
44786
  var hasOwn2 = Object.prototype.hasOwnProperty;
44786
44787
  function scopePlugin(fork) {
44787
- var types42 = fork.use(types_110.default);
44788
- var Type = types42.Type;
44789
- var namedTypes = types42.namedTypes;
44788
+ var types52 = fork.use(types_110.default);
44789
+ var Type = types52.Type;
44790
+ var namedTypes = types52.namedTypes;
44790
44791
  var Node3 = namedTypes.Node;
44791
44792
  var Expression = namedTypes.Expression;
44792
- var isArray2 = types42.builtInTypes.array;
44793
- var b = types42.builders;
44793
+ var isArray2 = types52.builtInTypes.array;
44794
+ var b = types52.builders;
44794
44795
  var Scope3 = function Scope22(path3, parentScope) {
44795
44796
  if (!(this instanceof Scope22)) {
44796
44797
  throw new Error("Scope constructor cannot be invoked without 'new'");
@@ -44853,7 +44854,7 @@ var require_scope = __commonJS2({
44853
44854
  ++index;
44854
44855
  }
44855
44856
  var name = prefix + index;
44856
- return this.bindings[name] = types42.builders.identifier(name);
44857
+ return this.bindings[name] = types52.builders.identifier(name);
44857
44858
  };
44858
44859
  Sp.injectTemporary = function(identifier, init) {
44859
44860
  identifier || (identifier = this.declareTemporary());
@@ -44929,7 +44930,7 @@ var require_scope = __commonJS2({
44929
44930
  bindings
44930
44931
  );
44931
44932
  } else if (Node3.check(node2) && !Expression.check(node2)) {
44932
- types42.eachField(node2, function(name, child) {
44933
+ types52.eachField(node2, function(name, child) {
44933
44934
  var childPath = path3.get(name);
44934
44935
  if (!pathHasValue(childPath, child)) {
44935
44936
  throw new Error("");
@@ -45007,24 +45008,24 @@ var require_scope = __commonJS2({
45007
45008
  addPattern(patternPath.get("argument"), bindings);
45008
45009
  }
45009
45010
  }
45010
- function addTypePattern(patternPath, types52) {
45011
+ function addTypePattern(patternPath, types62) {
45011
45012
  var pattern = patternPath.value;
45012
45013
  namedTypes.Pattern.assert(pattern);
45013
45014
  if (namedTypes.Identifier.check(pattern)) {
45014
- if (hasOwn2.call(types52, pattern.name)) {
45015
- types52[pattern.name].push(patternPath);
45015
+ if (hasOwn2.call(types62, pattern.name)) {
45016
+ types62[pattern.name].push(patternPath);
45016
45017
  } else {
45017
- types52[pattern.name] = [patternPath];
45018
+ types62[pattern.name] = [patternPath];
45018
45019
  }
45019
45020
  }
45020
45021
  }
45021
- function addTypeParameter(parameterPath, types52) {
45022
+ function addTypeParameter(parameterPath, types62) {
45022
45023
  var parameter = parameterPath.value;
45023
45024
  FlowOrTSTypeParameterType.assert(parameter);
45024
- if (hasOwn2.call(types52, parameter.name)) {
45025
- types52[parameter.name].push(parameterPath);
45025
+ if (hasOwn2.call(types62, parameter.name)) {
45026
+ types62[parameter.name].push(parameterPath);
45026
45027
  } else {
45027
- types52[parameter.name] = [parameterPath];
45028
+ types62[parameter.name] = [parameterPath];
45028
45029
  }
45029
45030
  }
45030
45031
  Sp.lookup = function(name) {
@@ -45063,11 +45064,11 @@ var require_node_path = __commonJS2({
45063
45064
  var scope_1 = tslib_1.__importDefault(require_scope());
45064
45065
  var shared_1 = require_shared();
45065
45066
  function nodePathPlugin(fork) {
45066
- var types42 = fork.use(types_110.default);
45067
- var n = types42.namedTypes;
45068
- var b = types42.builders;
45069
- var isNumber2 = types42.builtInTypes.number;
45070
- var isArray2 = types42.builtInTypes.array;
45067
+ var types52 = fork.use(types_110.default);
45068
+ var n = types52.namedTypes;
45069
+ var b = types52.builders;
45070
+ var isNumber2 = types52.builtInTypes.number;
45071
+ var isArray2 = types52.builtInTypes.array;
45071
45072
  var Path = fork.use(path_1.default);
45072
45073
  var Scope3 = fork.use(scope_1.default);
45073
45074
  var NodePath = function NodePath2(value2, parentPath, name) {
@@ -45158,7 +45159,7 @@ var require_node_path = __commonJS2({
45158
45159
  return scope2 || null;
45159
45160
  };
45160
45161
  NPp.getValueProperty = function(name) {
45161
- return types42.getFieldValue(this.value, name);
45162
+ return types52.getFieldValue(this.value, name);
45162
45163
  };
45163
45164
  NPp.needsParens = function(assumeExpressionContext) {
45164
45165
  var pp2 = this.parentPath;
@@ -45300,7 +45301,7 @@ var require_node_path = __commonJS2({
45300
45301
  return node2.some(containsCallExpression);
45301
45302
  }
45302
45303
  if (n.Node.check(node2)) {
45303
- return types42.someField(node2, function(_name, child) {
45304
+ return types52.someField(node2, function(_name, child) {
45304
45305
  return containsCallExpression(child);
45305
45306
  });
45306
45307
  }
@@ -45419,11 +45420,11 @@ var require_path_visitor = __commonJS2({
45419
45420
  var shared_1 = require_shared();
45420
45421
  var hasOwn2 = Object.prototype.hasOwnProperty;
45421
45422
  function pathVisitorPlugin(fork) {
45422
- var types42 = fork.use(types_110.default);
45423
+ var types52 = fork.use(types_110.default);
45423
45424
  var NodePath = fork.use(node_path_1.default);
45424
- var isArray2 = types42.builtInTypes.array;
45425
- var isObject2 = types42.builtInTypes.object;
45426
- var isFunction2 = types42.builtInTypes.function;
45425
+ var isArray2 = types52.builtInTypes.array;
45426
+ var isObject2 = types52.builtInTypes.object;
45427
+ var isFunction2 = types52.builtInTypes.function;
45427
45428
  var undefined2;
45428
45429
  var PathVisitor = function PathVisitor2() {
45429
45430
  if (!(this instanceof PathVisitor2)) {
@@ -45443,7 +45444,7 @@ var require_path_visitor = __commonJS2({
45443
45444
  typeNames[methodName.slice("visit".length)] = true;
45444
45445
  }
45445
45446
  }
45446
- var supertypeTable = types42.computeSupertypeLookupTable(typeNames);
45447
+ var supertypeTable = types52.computeSupertypeLookupTable(typeNames);
45447
45448
  var methodNameTable = /* @__PURE__ */ Object.create(null);
45448
45449
  var typeNameKeys = Object.keys(supertypeTable);
45449
45450
  var typeNameCount = typeNameKeys.length;
@@ -45562,7 +45563,7 @@ var require_path_visitor = __commonJS2({
45562
45563
  path3.each(visitor.visitWithoutReset, visitor);
45563
45564
  } else if (!isObject2.check(value2)) {
45564
45565
  } else {
45565
- var childNames = types42.getFieldNames(value2);
45566
+ var childNames = types52.getFieldNames(value2);
45566
45567
  if (visitor._shouldVisitComments && value2.comments && childNames.indexOf("comments") < 0) {
45567
45568
  childNames.push("comments");
45568
45569
  }
@@ -45571,7 +45572,7 @@ var require_path_visitor = __commonJS2({
45571
45572
  for (var i22 = 0; i22 < childCount; ++i22) {
45572
45573
  var childName = childNames[i22];
45573
45574
  if (!hasOwn2.call(value2, childName)) {
45574
- value2[childName] = types42.getFieldValue(value2, childName);
45575
+ value2[childName] = types52.getFieldValue(value2, childName);
45575
45576
  }
45576
45577
  childPaths.push(path3.get(childName));
45577
45578
  }
@@ -45712,13 +45713,13 @@ var require_equiv = __commonJS2({
45712
45713
  var shared_1 = require_shared();
45713
45714
  var types_110 = tslib_1.__importDefault(require_types());
45714
45715
  function default_1(fork) {
45715
- var types42 = fork.use(types_110.default);
45716
- var getFieldNames = types42.getFieldNames;
45717
- var getFieldValue = types42.getFieldValue;
45718
- var isArray2 = types42.builtInTypes.array;
45719
- var isObject2 = types42.builtInTypes.object;
45720
- var isDate2 = types42.builtInTypes.Date;
45721
- var isRegExp2 = types42.builtInTypes.RegExp;
45716
+ var types52 = fork.use(types_110.default);
45717
+ var getFieldNames = types52.getFieldNames;
45718
+ var getFieldValue = types52.getFieldValue;
45719
+ var isArray2 = types52.builtInTypes.array;
45720
+ var isObject2 = types52.builtInTypes.object;
45721
+ var isDate2 = types52.builtInTypes.Date;
45722
+ var isRegExp2 = types52.builtInTypes.RegExp;
45722
45723
  var hasOwn2 = Object.prototype.hasOwnProperty;
45723
45724
  function astNodesAreEquivalent(a, b, problemPath) {
45724
45725
  if (isArray2.check(problemPath)) {
@@ -45869,24 +45870,24 @@ var require_fork = __commonJS2({
45869
45870
  var shared_1 = require_shared();
45870
45871
  function default_1(plugins2) {
45871
45872
  var fork = createFork();
45872
- var types42 = fork.use(types_110.default);
45873
+ var types52 = fork.use(types_110.default);
45873
45874
  plugins2.forEach(fork.use);
45874
- types42.finalize();
45875
+ types52.finalize();
45875
45876
  var PathVisitor = fork.use(path_visitor_1.default);
45876
45877
  return {
45877
- Type: types42.Type,
45878
- builtInTypes: types42.builtInTypes,
45879
- namedTypes: types42.namedTypes,
45880
- builders: types42.builders,
45881
- defineMethod: types42.defineMethod,
45882
- getFieldNames: types42.getFieldNames,
45883
- getFieldValue: types42.getFieldValue,
45884
- eachField: types42.eachField,
45885
- someField: types42.someField,
45886
- getSupertypeNames: types42.getSupertypeNames,
45887
- getBuilderName: types42.getBuilderName,
45878
+ Type: types52.Type,
45879
+ builtInTypes: types52.builtInTypes,
45880
+ namedTypes: types52.namedTypes,
45881
+ builders: types52.builders,
45882
+ defineMethod: types52.defineMethod,
45883
+ getFieldNames: types52.getFieldNames,
45884
+ getFieldValue: types52.getFieldValue,
45885
+ eachField: types52.eachField,
45886
+ someField: types52.someField,
45887
+ getSupertypeNames: types52.getSupertypeNames,
45888
+ getBuilderName: types52.getBuilderName,
45888
45889
  astNodesAreEquivalent: fork.use(equiv_1.default),
45889
- finalize: types42.finalize,
45890
+ finalize: types52.finalize,
45890
45891
  Path: fork.use(path_1.default),
45891
45892
  NodePath: fork.use(node_path_1.default),
45892
45893
  PathVisitor,
@@ -46046,8 +46047,8 @@ var require_core2 = __commonJS2({
46046
46047
  var types_110 = tslib_1.__importDefault(require_types());
46047
46048
  var shared_1 = tslib_1.__importStar(require_shared());
46048
46049
  function default_1(fork) {
46049
- var types42 = fork.use(types_110.default);
46050
- var Type = types42.Type;
46050
+ var types52 = fork.use(types_110.default);
46051
+ var Type = types52.Type;
46051
46052
  var def = Type.def;
46052
46053
  var or = Type.or;
46053
46054
  var shared = fork.use(shared_1.default);
@@ -46137,9 +46138,9 @@ var require_es6 = __commonJS2({
46137
46138
  var shared_1 = tslib_1.__importStar(require_shared());
46138
46139
  function default_1(fork) {
46139
46140
  fork.use(core_1.default);
46140
- var types42 = fork.use(types_110.default);
46141
- var def = types42.Type.def;
46142
- var or = types42.Type.or;
46141
+ var types52 = fork.use(types_110.default);
46142
+ var def = types52.Type.def;
46143
+ var or = types52.Type.or;
46143
46144
  var defaults2 = fork.use(shared_1.default).defaults;
46144
46145
  def("Function").field("generator", Boolean, defaults2["false"]).field("expression", Boolean, defaults2["false"]).field("defaults", [or(def("Expression"), null)], defaults2.emptyArray).field("rest", or(def("Identifier"), null), defaults2["null"]);
46145
46146
  def("RestElement").bases("Pattern").build("argument").field("argument", def("Pattern")).field(
@@ -46225,8 +46226,8 @@ var require_es2017 = __commonJS2({
46225
46226
  var shared_1 = tslib_1.__importStar(require_shared());
46226
46227
  function default_1(fork) {
46227
46228
  fork.use(es2016_1.default);
46228
- var types42 = fork.use(types_110.default);
46229
- var def = types42.Type.def;
46229
+ var types52 = fork.use(types_110.default);
46230
+ var def = types52.Type.def;
46230
46231
  var defaults2 = fork.use(shared_1.default).defaults;
46231
46232
  def("Function").field("async", Boolean, defaults2["false"]);
46232
46233
  def("AwaitExpression").bases("Expression").build("argument").field("argument", def("Expression"));
@@ -46247,9 +46248,9 @@ var require_es2018 = __commonJS2({
46247
46248
  var shared_1 = tslib_1.__importStar(require_shared());
46248
46249
  function default_1(fork) {
46249
46250
  fork.use(es2017_1.default);
46250
- var types42 = fork.use(types_110.default);
46251
- var def = types42.Type.def;
46252
- var or = types42.Type.or;
46251
+ var types52 = fork.use(types_110.default);
46252
+ var def = types52.Type.def;
46253
+ var or = types52.Type.or;
46253
46254
  var defaults2 = fork.use(shared_1.default).defaults;
46254
46255
  def("ForOfStatement").field("await", Boolean, defaults2["false"]);
46255
46256
  def("SpreadProperty").bases("Node").build("argument").field("argument", def("Expression"));
@@ -46278,9 +46279,9 @@ var require_es2019 = __commonJS2({
46278
46279
  var shared_1 = tslib_1.__importStar(require_shared());
46279
46280
  function default_1(fork) {
46280
46281
  fork.use(es2018_1.default);
46281
- var types42 = fork.use(types_110.default);
46282
- var def = types42.Type.def;
46283
- var or = types42.Type.or;
46282
+ var types52 = fork.use(types_110.default);
46283
+ var def = types52.Type.def;
46284
+ var or = types52.Type.or;
46284
46285
  var defaults2 = fork.use(shared_1.default).defaults;
46285
46286
  def("CatchClause").field("param", or(def("Pattern"), null), defaults2["null"]);
46286
46287
  }
@@ -46302,9 +46303,9 @@ var require_es20202 = __commonJS2({
46302
46303
  function default_1(fork) {
46303
46304
  fork.use(es2020_1.default);
46304
46305
  fork.use(es2019_1.default);
46305
- var types42 = fork.use(types_110.default);
46306
- var def = types42.Type.def;
46307
- var or = types42.Type.or;
46306
+ var types52 = fork.use(types_110.default);
46307
+ var def = types52.Type.def;
46308
+ var or = types52.Type.or;
46308
46309
  var shared = fork.use(shared_1.default);
46309
46310
  var defaults2 = shared.defaults;
46310
46311
  def("ImportExpression").bases("Expression").build("source").field("source", def("Expression"));
@@ -46350,8 +46351,8 @@ var require_es2022 = __commonJS2({
46350
46351
  var shared_1 = require_shared();
46351
46352
  function default_1(fork) {
46352
46353
  fork.use(es2021_1.default);
46353
- var types42 = fork.use(types_110.default);
46354
- var def = types42.Type.def;
46354
+ var types52 = fork.use(types_110.default);
46355
+ var def = types52.Type.def;
46355
46356
  def("StaticBlock").bases("Declaration").build("body").field("body", [def("Statement")]);
46356
46357
  }
46357
46358
  exports.default = default_1;
@@ -46370,9 +46371,9 @@ var require_es_proposals = __commonJS2({
46370
46371
  var es2022_1 = tslib_1.__importDefault(require_es2022());
46371
46372
  function default_1(fork) {
46372
46373
  fork.use(es2022_1.default);
46373
- var types42 = fork.use(types_110.default);
46374
- var Type = types42.Type;
46375
- var def = types42.Type.def;
46374
+ var types52 = fork.use(types_110.default);
46375
+ var Type = types52.Type;
46376
+ var def = types52.Type.def;
46376
46377
  var or = Type.or;
46377
46378
  var shared = fork.use(shared_1.default);
46378
46379
  var defaults2 = shared.defaults;
@@ -46410,9 +46411,9 @@ var require_jsx = __commonJS2({
46410
46411
  var shared_1 = tslib_1.__importStar(require_shared());
46411
46412
  function default_1(fork) {
46412
46413
  fork.use(es_proposals_1.default);
46413
- var types42 = fork.use(types_110.default);
46414
- var def = types42.Type.def;
46415
- var or = types42.Type.or;
46414
+ var types52 = fork.use(types_110.default);
46415
+ var def = types52.Type.def;
46416
+ var or = types52.Type.or;
46416
46417
  var defaults2 = fork.use(shared_1.default).defaults;
46417
46418
  def("JSXAttribute").bases("Node").build("name", "value").field("name", or(def("JSXIdentifier"), def("JSXNamespacedName"))).field("value", or(
46418
46419
  def("Literal"),
@@ -46468,9 +46469,9 @@ var require_type_annotations = __commonJS2({
46468
46469
  var types_110 = tslib_1.__importDefault(require_types());
46469
46470
  var shared_1 = tslib_1.__importStar(require_shared());
46470
46471
  function default_1(fork) {
46471
- var types42 = fork.use(types_110.default);
46472
- var def = types42.Type.def;
46473
- var or = types42.Type.or;
46472
+ var types52 = fork.use(types_110.default);
46473
+ var def = types52.Type.def;
46474
+ var or = types52.Type.or;
46474
46475
  var defaults2 = fork.use(shared_1.default).defaults;
46475
46476
  var TypeAnnotation = or(def("TypeAnnotation"), def("TSTypeAnnotation"), null);
46476
46477
  var TypeParamDecl = or(def("TypeParameterDeclaration"), def("TSTypeParameterDeclaration"), null);
@@ -46503,9 +46504,9 @@ var require_flow = __commonJS2({
46503
46504
  function default_1(fork) {
46504
46505
  fork.use(es_proposals_1.default);
46505
46506
  fork.use(type_annotations_1.default);
46506
- var types42 = fork.use(types_110.default);
46507
- var def = types42.Type.def;
46508
- var or = types42.Type.or;
46507
+ var types52 = fork.use(types_110.default);
46508
+ var def = types52.Type.def;
46509
+ var or = types52.Type.or;
46509
46510
  var defaults2 = fork.use(shared_1.default).defaults;
46510
46511
  def("Flow").bases("Node");
46511
46512
  def("FlowType").bases("Flow");
@@ -46617,10 +46618,10 @@ var require_esprima = __commonJS2({
46617
46618
  var shared_1 = tslib_1.__importStar(require_shared());
46618
46619
  function default_1(fork) {
46619
46620
  fork.use(es_proposals_1.default);
46620
- var types42 = fork.use(types_110.default);
46621
+ var types52 = fork.use(types_110.default);
46621
46622
  var defaults2 = fork.use(shared_1.default).defaults;
46622
- var def = types42.Type.def;
46623
- var or = types42.Type.or;
46623
+ var def = types52.Type.def;
46624
+ var or = types52.Type.or;
46624
46625
  def("VariableDeclaration").field("declarations", [or(
46625
46626
  def("VariableDeclarator"),
46626
46627
  def("Identifier")
@@ -46663,11 +46664,11 @@ var require_babel_core = __commonJS2({
46663
46664
  function default_1(fork) {
46664
46665
  var _a, _b, _c, _d, _e;
46665
46666
  fork.use(es_proposals_1.default);
46666
- var types42 = fork.use(types_110.default);
46667
+ var types52 = fork.use(types_110.default);
46667
46668
  var defaults2 = fork.use(shared_1.default).defaults;
46668
- var def = types42.Type.def;
46669
- var or = types42.Type.or;
46670
- var isUndefined = types42.builtInTypes.undefined;
46669
+ var def = types52.Type.def;
46670
+ var or = types52.Type.or;
46671
+ var isUndefined = types52.builtInTypes.undefined;
46671
46672
  def("Noop").bases("Statement").build();
46672
46673
  def("DoExpression").bases("Expression").build("body").field("body", [def("Statement")]);
46673
46674
  def("BindExpression").bases("Expression").build("object", "callee").field("object", or(def("Expression"), null)).field("callee", def("Expression"));
@@ -46692,7 +46693,7 @@ var require_babel_core = __commonJS2({
46692
46693
  raw: String
46693
46694
  },
46694
46695
  function getDefault() {
46695
- var value2 = types42.getFieldValue(this, "value");
46696
+ var value2 = types52.getFieldValue(this, "value");
46696
46697
  return {
46697
46698
  rawValue: value2,
46698
46699
  raw: toRaw ? toRaw(value2) : String(value2)
@@ -46793,8 +46794,8 @@ var require_babel = __commonJS2({
46793
46794
  var flow_1 = tslib_1.__importDefault(require_flow());
46794
46795
  var shared_1 = require_shared();
46795
46796
  function default_1(fork) {
46796
- var types42 = fork.use(types_110.default);
46797
- var def = types42.Type.def;
46797
+ var types52 = fork.use(types_110.default);
46798
+ var def = types52.Type.def;
46798
46799
  fork.use(babel_core_1.default);
46799
46800
  fork.use(flow_1.default);
46800
46801
  def("V8IntrinsicIdentifier").bases("Expression").build("name").field("name", String);
@@ -46818,12 +46819,12 @@ var require_typescript = __commonJS2({
46818
46819
  function default_1(fork) {
46819
46820
  fork.use(babel_core_1.default);
46820
46821
  fork.use(type_annotations_1.default);
46821
- var types42 = fork.use(types_110.default);
46822
- var n = types42.namedTypes;
46823
- var def = types42.Type.def;
46824
- var or = types42.Type.or;
46822
+ var types52 = fork.use(types_110.default);
46823
+ var n = types52.namedTypes;
46824
+ var def = types52.Type.def;
46825
+ var or = types52.Type.or;
46825
46826
  var defaults2 = fork.use(shared_1.default).defaults;
46826
- var StringLiteral = types42.Type.from(function(value2, deep) {
46827
+ var StringLiteral = types52.Type.from(function(value2, deep) {
46827
46828
  if (n.StringLiteral && n.StringLiteral.check(value2, deep)) {
46828
46829
  return true;
46829
46830
  }
@@ -48771,8 +48772,8 @@ var require_util2 = __commonJS2({
48771
48772
  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;
48772
48773
  var tslib_1 = require_tslib();
48773
48774
  var assert_1 = tslib_1.__importDefault(__require2("assert"));
48774
- var types42 = tslib_1.__importStar(require_main());
48775
- var n = types42.namedTypes;
48775
+ var types52 = tslib_1.__importStar(require_main());
48776
+ var n = types52.namedTypes;
48776
48777
  var source_map_1 = tslib_1.__importDefault(require_source_map());
48777
48778
  var SourceMapConsumer = source_map_1.default.SourceMapConsumer;
48778
48779
  var SourceMapGenerator = source_map_1.default.SourceMapGenerator;
@@ -56078,10 +56079,10 @@ var require_comments = __commonJS2({
56078
56079
  exports.printComments = exports.attach = void 0;
56079
56080
  var tslib_1 = require_tslib();
56080
56081
  var assert_1 = tslib_1.__importDefault(__require2("assert"));
56081
- var types42 = tslib_1.__importStar(require_main());
56082
- var n = types42.namedTypes;
56083
- var isArray2 = types42.builtInTypes.array;
56084
- var isObject2 = types42.builtInTypes.object;
56082
+ var types52 = tslib_1.__importStar(require_main());
56083
+ var n = types52.namedTypes;
56084
+ var isArray2 = types52.builtInTypes.array;
56085
+ var isObject2 = types52.builtInTypes.object;
56085
56086
  var lines_1 = require_lines();
56086
56087
  var util_110 = require_util2();
56087
56088
  var childNodesCache = /* @__PURE__ */ new WeakMap();
@@ -56112,7 +56113,7 @@ var require_comments = __commonJS2({
56112
56113
  if (isArray2.check(node2)) {
56113
56114
  names = Object.keys(node2);
56114
56115
  } else if (isObject2.check(node2)) {
56115
- names = types42.getFieldNames(node2);
56116
+ names = types52.getFieldNames(node2);
56116
56117
  } else {
56117
56118
  return resultArray;
56118
56119
  }
@@ -56290,7 +56291,7 @@ var require_comments = __commonJS2({
56290
56291
  function printComments(path3, print62) {
56291
56292
  var value2 = path3.getValue();
56292
56293
  var innerLines = print62(path3);
56293
- var comments = n.Node.check(value2) && types42.getFieldValue(value2, "comments");
56294
+ var comments = n.Node.check(value2) && types52.getFieldValue(value2, "comments");
56294
56295
  if (!comments || comments.length === 0) {
56295
56296
  return innerLines;
56296
56297
  }
@@ -56298,8 +56299,8 @@ var require_comments = __commonJS2({
56298
56299
  var trailingParts = [innerLines];
56299
56300
  path3.each(function(commentPath) {
56300
56301
  var comment = commentPath.getValue();
56301
- var leading = types42.getFieldValue(comment, "leading");
56302
- var trailing = types42.getFieldValue(comment, "trailing");
56302
+ var leading = types52.getFieldValue(comment, "leading");
56303
+ var trailing = types52.getFieldValue(comment, "trailing");
56303
56304
  if (leading || trailing && !(n.Statement.check(value2) || comment.type === "Block" || comment.type === "CommentBlock")) {
56304
56305
  leadingParts.push(printLeadingComment(commentPath, print62));
56305
56306
  } else if (trailing) {
@@ -56319,10 +56320,10 @@ var require_parser = __commonJS2({
56319
56320
  exports.parse = void 0;
56320
56321
  var tslib_1 = require_tslib();
56321
56322
  var assert_1 = tslib_1.__importDefault(__require2("assert"));
56322
- var types42 = tslib_1.__importStar(require_main());
56323
- var b = types42.builders;
56324
- var isObject2 = types42.builtInTypes.object;
56325
- var isArray2 = types42.builtInTypes.array;
56323
+ var types52 = tslib_1.__importStar(require_main());
56324
+ var b = types52.builders;
56325
+ var isObject2 = types52.builtInTypes.object;
56326
+ var isArray2 = types52.builtInTypes.array;
56326
56327
  var options_1 = require_options();
56327
56328
  var lines_1 = require_lines();
56328
56329
  var comments_1 = require_comments();
@@ -56506,11 +56507,11 @@ var require_fast_path = __commonJS2({
56506
56507
  Object.defineProperty(exports, "__esModule", { value: true });
56507
56508
  var tslib_1 = require_tslib();
56508
56509
  var assert_1 = tslib_1.__importDefault(__require2("assert"));
56509
- var types42 = tslib_1.__importStar(require_main());
56510
+ var types52 = tslib_1.__importStar(require_main());
56510
56511
  var util2 = tslib_1.__importStar(require_util2());
56511
- var n = types42.namedTypes;
56512
- var isArray2 = types42.builtInTypes.array;
56513
- var isNumber2 = types42.builtInTypes.number;
56512
+ var n = types52.namedTypes;
56513
+ var isArray2 = types52.builtInTypes.array;
56514
+ var isNumber2 = types52.builtInTypes.number;
56514
56515
  var PRECEDENCE = {};
56515
56516
  [
56516
56517
  ["??"],
@@ -56539,7 +56540,7 @@ var require_fast_path = __commonJS2({
56539
56540
  if (obj instanceof FastPath) {
56540
56541
  return obj.copy();
56541
56542
  }
56542
- if (obj instanceof types42.NodePath) {
56543
+ if (obj instanceof types52.NodePath) {
56543
56544
  var copy = Object.create(FastPath.prototype);
56544
56545
  var stack = [obj.value];
56545
56546
  for (var pp2 = void 0; pp2 = obj.parentPath; obj = pp2)
@@ -56850,7 +56851,7 @@ var require_fast_path = __commonJS2({
56850
56851
  return node2.some(containsCallExpression);
56851
56852
  }
56852
56853
  if (n.Node.check(node2)) {
56853
- return types42.someField(node2, function(_name, child) {
56854
+ return types52.someField(node2, function(_name, child) {
56854
56855
  return containsCallExpression(child);
56855
56856
  });
56856
56857
  }
@@ -56938,16 +56939,16 @@ var require_patcher = __commonJS2({
56938
56939
  var tslib_1 = require_tslib();
56939
56940
  var assert_1 = tslib_1.__importDefault(__require2("assert"));
56940
56941
  var linesModule = tslib_1.__importStar(require_lines());
56941
- var types42 = tslib_1.__importStar(require_main());
56942
- var Printable = types42.namedTypes.Printable;
56943
- var Expression = types42.namedTypes.Expression;
56944
- var ReturnStatement = types42.namedTypes.ReturnStatement;
56945
- var SourceLocation3 = types42.namedTypes.SourceLocation;
56942
+ var types52 = tslib_1.__importStar(require_main());
56943
+ var Printable = types52.namedTypes.Printable;
56944
+ var Expression = types52.namedTypes.Expression;
56945
+ var ReturnStatement = types52.namedTypes.ReturnStatement;
56946
+ var SourceLocation3 = types52.namedTypes.SourceLocation;
56946
56947
  var util_110 = require_util2();
56947
56948
  var fast_path_1 = tslib_1.__importDefault(require_fast_path());
56948
- var isObject2 = types42.builtInTypes.object;
56949
- var isArray2 = types42.builtInTypes.array;
56950
- var isString3 = types42.builtInTypes.string;
56949
+ var isObject2 = types52.builtInTypes.object;
56950
+ var isArray2 = types52.builtInTypes.array;
56951
+ var isString3 = types52.builtInTypes.string;
56951
56952
  var riskyAdjoiningCharExp = /[0-9a-z_$]/i;
56952
56953
  var Patcher = function Patcher2(lines) {
56953
56954
  assert_1.default.ok(this instanceof Patcher2);
@@ -57217,8 +57218,8 @@ var require_patcher = __commonJS2({
57217
57218
  if (k.charAt(0) === "_") {
57218
57219
  continue;
57219
57220
  }
57220
- newPath.stack.push(k, types42.getFieldValue(newNode, k));
57221
- oldPath.stack.push(k, types42.getFieldValue(oldNode, k));
57221
+ newPath.stack.push(k, types52.getFieldValue(newNode, k));
57222
+ oldPath.stack.push(k, types52.getFieldValue(oldNode, k));
57222
57223
  var canReprint = findAnyReprints(newPath, oldPath, reprints);
57223
57224
  newPath.stack.length -= 2;
57224
57225
  oldPath.stack.length -= 2;
@@ -57240,16 +57241,16 @@ var require_printer = __commonJS2({
57240
57241
  exports.Printer = void 0;
57241
57242
  var tslib_1 = require_tslib();
57242
57243
  var assert_1 = tslib_1.__importDefault(__require2("assert"));
57243
- var types42 = tslib_1.__importStar(require_main());
57244
+ var types52 = tslib_1.__importStar(require_main());
57244
57245
  var comments_1 = require_comments();
57245
57246
  var fast_path_1 = tslib_1.__importDefault(require_fast_path());
57246
57247
  var lines_1 = require_lines();
57247
57248
  var options_1 = require_options();
57248
57249
  var patcher_1 = require_patcher();
57249
57250
  var util2 = tslib_1.__importStar(require_util2());
57250
- var namedTypes = types42.namedTypes;
57251
- var isString3 = types42.builtInTypes.string;
57252
- var isObject2 = types42.builtInTypes.object;
57251
+ var namedTypes = types52.namedTypes;
57252
+ var isString3 = types52.builtInTypes.string;
57253
+ var isObject2 = types52.builtInTypes.object;
57253
57254
  var PrintResult = function PrintResult2(code, sourceMap) {
57254
57255
  assert_1.default.ok(this instanceof PrintResult2);
57255
57256
  isString3.assert(code);
@@ -57411,7 +57412,7 @@ var require_printer = __commonJS2({
57411
57412
  case "OptionalMemberExpression": {
57412
57413
  parts.push(path3.call(print62, "object"));
57413
57414
  var property = path3.call(print62, "property");
57414
- var optional = types42.getFieldValue(n, "optional");
57415
+ var optional = types52.getFieldValue(n, "optional");
57415
57416
  if (n.computed) {
57416
57417
  parts.push(optional ? "?.[" : "[", property, "]");
57417
57418
  } else {
@@ -57682,7 +57683,7 @@ var require_printer = __commonJS2({
57682
57683
  if (n.typeArguments) {
57683
57684
  parts.push(path3.call(print62, "typeArguments"));
57684
57685
  }
57685
- if (types42.getFieldValue(n, "optional")) {
57686
+ if (types52.getFieldValue(n, "optional")) {
57686
57687
  parts.push("?.");
57687
57688
  }
57688
57689
  parts.push(printArgumentsList(path3, options, print62));
@@ -59361,8 +59362,8 @@ var require_printer = __commonJS2({
59361
59362
  });
59362
59363
  }
59363
59364
  function getPossibleRaw(node2) {
59364
- var value2 = types42.getFieldValue(node2, "value");
59365
- var extra = types42.getFieldValue(node2, "extra");
59365
+ var value2 = types52.getFieldValue(node2, "value");
59366
+ var extra = types52.getFieldValue(node2, "extra");
59366
59367
  if (extra && typeof extra.raw === "string" && value2 == extra.rawValue) {
59367
59368
  return extra.raw;
59368
59369
  }
@@ -59408,8 +59409,8 @@ var require_main2 = __commonJS2({
59408
59409
  exports.run = exports.prettyPrint = exports.print = exports.visit = exports.types = exports.parse = void 0;
59409
59410
  var tslib_1 = require_tslib();
59410
59411
  var fs_1 = tslib_1.__importDefault(__require2("fs"));
59411
- var types42 = tslib_1.__importStar(require_main());
59412
- exports.types = types42;
59412
+ var types52 = tslib_1.__importStar(require_main());
59413
+ exports.types = types52;
59413
59414
  var parser_1 = require_parser();
59414
59415
  Object.defineProperty(exports, "parse", { enumerable: true, get: function() {
59415
59416
  return parser_1.parse;
@@ -63799,30 +63800,30 @@ var require_utils3 = __commonJS2({
63799
63800
  validate22.oneOf = values;
63800
63801
  return validate22;
63801
63802
  }
63802
- function assertNodeType(...types42) {
63803
+ function assertNodeType(...types52) {
63803
63804
  function validate22(node2, key, val) {
63804
- for (const type of types42) {
63805
+ for (const type of types52) {
63805
63806
  if ((0, _is.default)(type, val)) {
63806
63807
  (0, _validate.validateChild)(node2, key, val);
63807
63808
  return;
63808
63809
  }
63809
63810
  }
63810
- throw new TypeError(`Property ${key} of ${node2.type} expected node to be of a type ${JSON.stringify(types42)} but instead got ${JSON.stringify(val == null ? void 0 : val.type)}`);
63811
+ throw new TypeError(`Property ${key} of ${node2.type} expected node to be of a type ${JSON.stringify(types52)} but instead got ${JSON.stringify(val == null ? void 0 : val.type)}`);
63811
63812
  }
63812
- validate22.oneOfNodeTypes = types42;
63813
+ validate22.oneOfNodeTypes = types52;
63813
63814
  return validate22;
63814
63815
  }
63815
- function assertNodeOrValueType(...types42) {
63816
+ function assertNodeOrValueType(...types52) {
63816
63817
  function validate22(node2, key, val) {
63817
- for (const type of types42) {
63818
+ for (const type of types52) {
63818
63819
  if (getType(val) === type || (0, _is.default)(type, val)) {
63819
63820
  (0, _validate.validateChild)(node2, key, val);
63820
63821
  return;
63821
63822
  }
63822
63823
  }
63823
- throw new TypeError(`Property ${key} of ${node2.type} expected node to be of a type ${JSON.stringify(types42)} but instead got ${JSON.stringify(val == null ? void 0 : val.type)}`);
63824
+ throw new TypeError(`Property ${key} of ${node2.type} expected node to be of a type ${JSON.stringify(types52)} but instead got ${JSON.stringify(val == null ? void 0 : val.type)}`);
63824
63825
  }
63825
- validate22.oneOfNodeOrValueTypes = types42;
63826
+ validate22.oneOfNodeOrValueTypes = types52;
63826
63827
  return validate22;
63827
63828
  }
63828
63829
  function assertValueType(type) {
@@ -67400,7 +67401,7 @@ var require_generated2 = __commonJS2({
67400
67401
  exports.tSTypeParameterInstantiation = exports.tsTypeParameterInstantiation = tsTypeParameterInstantiation;
67401
67402
  exports.tSTypePredicate = exports.tsTypePredicate = tsTypePredicate;
67402
67403
  exports.tSTypeQuery = exports.tsTypeQuery = tsTypeQuery;
67403
- exports.tSTypeReference = exports.tsTypeReference = tsTypeReference;
67404
+ exports.tSTypeReference = exports.tsTypeReference = tsTypeReference2;
67404
67405
  exports.tSUndefinedKeyword = exports.tsUndefinedKeyword = tsUndefinedKeyword;
67405
67406
  exports.tSUnionType = exports.tsUnionType = tsUnionType;
67406
67407
  exports.tSUnknownKeyword = exports.tsUnknownKeyword = tsUnknownKeyword;
@@ -68226,10 +68227,10 @@ var require_generated2 = __commonJS2({
68226
68227
  body
68227
68228
  });
68228
68229
  }
68229
- function intersectionTypeAnnotation(types42) {
68230
+ function intersectionTypeAnnotation(types52) {
68230
68231
  return (0, _validateNode.default)({
68231
68232
  type: "IntersectionTypeAnnotation",
68232
- types: types42
68233
+ types: types52
68233
68234
  });
68234
68235
  }
68235
68236
  function mixedTypeAnnotation() {
@@ -68352,10 +68353,10 @@ var require_generated2 = __commonJS2({
68352
68353
  type: "ThisTypeAnnotation"
68353
68354
  };
68354
68355
  }
68355
- function tupleTypeAnnotation(types42) {
68356
+ function tupleTypeAnnotation(types52) {
68356
68357
  return (0, _validateNode.default)({
68357
68358
  type: "TupleTypeAnnotation",
68358
- types: types42
68359
+ types: types52
68359
68360
  });
68360
68361
  }
68361
68362
  function typeofTypeAnnotation(argument) {
@@ -68406,10 +68407,10 @@ var require_generated2 = __commonJS2({
68406
68407
  params
68407
68408
  });
68408
68409
  }
68409
- function unionTypeAnnotation(types42) {
68410
+ function unionTypeAnnotation(types52) {
68410
68411
  return (0, _validateNode.default)({
68411
68412
  type: "UnionTypeAnnotation",
68412
- types: types42
68413
+ types: types52
68413
68414
  });
68414
68415
  }
68415
68416
  function variance(kind) {
@@ -68862,7 +68863,7 @@ var require_generated2 = __commonJS2({
68862
68863
  typeAnnotation: typeAnnotation2
68863
68864
  });
68864
68865
  }
68865
- function tsTypeReference(typeName, typeParameters = null) {
68866
+ function tsTypeReference2(typeName, typeParameters = null) {
68866
68867
  return (0, _validateNode.default)({
68867
68868
  type: "TSTypeReference",
68868
68869
  typeName,
@@ -68922,16 +68923,16 @@ var require_generated2 = __commonJS2({
68922
68923
  optional
68923
68924
  });
68924
68925
  }
68925
- function tsUnionType(types42) {
68926
+ function tsUnionType(types52) {
68926
68927
  return (0, _validateNode.default)({
68927
68928
  type: "TSUnionType",
68928
- types: types42
68929
+ types: types52
68929
68930
  });
68930
68931
  }
68931
- function tsIntersectionType(types42) {
68932
+ function tsIntersectionType(types52) {
68932
68933
  return (0, _validateNode.default)({
68933
68934
  type: "TSIntersectionType",
68934
- types: types42
68935
+ types: types52
68935
68936
  });
68936
68937
  }
68937
68938
  function tsConditionalType(checkType, extendsType, trueType, falseType) {
@@ -70532,12 +70533,12 @@ var require_removeTypeDuplicates = __commonJS2({
70532
70533
  const generics = /* @__PURE__ */ new Map();
70533
70534
  const bases = /* @__PURE__ */ new Map();
70534
70535
  const typeGroups = /* @__PURE__ */ new Set();
70535
- const types42 = [];
70536
+ const types52 = [];
70536
70537
  for (let i22 = 0; i22 < nodes.length; i22++) {
70537
70538
  const node2 = nodes[i22];
70538
70539
  if (!node2)
70539
70540
  continue;
70540
- if (types42.indexOf(node2) >= 0) {
70541
+ if (types52.indexOf(node2) >= 0) {
70541
70542
  continue;
70542
70543
  }
70543
70544
  if ((0, _generated.isAnyTypeAnnotation)(node2)) {
@@ -70571,15 +70572,15 @@ var require_removeTypeDuplicates = __commonJS2({
70571
70572
  }
70572
70573
  continue;
70573
70574
  }
70574
- types42.push(node2);
70575
+ types52.push(node2);
70575
70576
  }
70576
70577
  for (const [, baseType] of bases) {
70577
- types42.push(baseType);
70578
+ types52.push(baseType);
70578
70579
  }
70579
70580
  for (const [, genericName] of generics) {
70580
- types42.push(genericName);
70581
+ types52.push(genericName);
70581
70582
  }
70582
- return types42;
70583
+ return types52;
70583
70584
  }
70584
70585
  }
70585
70586
  });
@@ -70592,8 +70593,8 @@ var require_createFlowUnionType = __commonJS2({
70592
70593
  exports.default = createFlowUnionType;
70593
70594
  var _generated = require_generated2();
70594
70595
  var _removeTypeDuplicates = require_removeTypeDuplicates();
70595
- function createFlowUnionType(types42) {
70596
- const flattened = (0, _removeTypeDuplicates.default)(types42);
70596
+ function createFlowUnionType(types52) {
70597
+ const flattened = (0, _removeTypeDuplicates.default)(types52);
70597
70598
  if (flattened.length === 1) {
70598
70599
  return flattened[0];
70599
70600
  } else {
@@ -70618,12 +70619,12 @@ var require_removeTypeDuplicates2 = __commonJS2({
70618
70619
  const generics = /* @__PURE__ */ new Map();
70619
70620
  const bases = /* @__PURE__ */ new Map();
70620
70621
  const typeGroups = /* @__PURE__ */ new Set();
70621
- const types42 = [];
70622
+ const types52 = [];
70622
70623
  for (let i22 = 0; i22 < nodes.length; i22++) {
70623
70624
  const node2 = nodes[i22];
70624
70625
  if (!node2)
70625
70626
  continue;
70626
- if (types42.indexOf(node2) >= 0) {
70627
+ if (types52.indexOf(node2) >= 0) {
70627
70628
  continue;
70628
70629
  }
70629
70630
  if ((0, _generated.isTSAnyKeyword)(node2)) {
@@ -70657,15 +70658,15 @@ var require_removeTypeDuplicates2 = __commonJS2({
70657
70658
  }
70658
70659
  continue;
70659
70660
  }
70660
- types42.push(node2);
70661
+ types52.push(node2);
70661
70662
  }
70662
70663
  for (const [, baseType] of bases) {
70663
- types42.push(baseType);
70664
+ types52.push(baseType);
70664
70665
  }
70665
70666
  for (const [, genericName] of generics) {
70666
- types42.push(genericName);
70667
+ types52.push(genericName);
70667
70668
  }
70668
- return types42;
70669
+ return types52;
70669
70670
  }
70670
70671
  }
70671
70672
  });
@@ -70680,10 +70681,10 @@ var require_createTSUnionType = __commonJS2({
70680
70681
  var _removeTypeDuplicates = require_removeTypeDuplicates2();
70681
70682
  var _index = require_generated();
70682
70683
  function createTSUnionType(typeAnnotations) {
70683
- const types42 = typeAnnotations.map((type) => {
70684
+ const types52 = typeAnnotations.map((type) => {
70684
70685
  return (0, _index.isTSTypeAnnotation)(type) ? type.typeAnnotation : type;
70685
70686
  });
70686
- const flattened = (0, _removeTypeDuplicates.default)(types42);
70687
+ const flattened = (0, _removeTypeDuplicates.default)(types52);
70687
70688
  if (flattened.length === 1) {
70688
70689
  return flattened[0];
70689
70690
  } else {
@@ -74371,7 +74372,7 @@ var printDocASTReducer = {
74371
74372
  leave: ({ name, interfaces, directives, fields }) => join(["interface", name, wrap("implements ", join(interfaces, " & ")), join(directives, " "), block(fields)], " ")
74372
74373
  },
74373
74374
  UnionTypeDefinition: {
74374
- leave: ({ name, directives, types: types42 }) => join(["union", name, join(directives, " "), wrap("= ", join(types42, " | "))], " ")
74375
+ leave: ({ name, directives, types: types52 }) => join(["union", name, join(directives, " "), wrap("= ", join(types52, " | "))], " ")
74375
74376
  },
74376
74377
  EnumTypeDefinition: {
74377
74378
  leave: ({ name, directives, values }) => join(["enum", name, join(directives, " "), block(values)], " ")
@@ -74398,7 +74399,7 @@ var printDocASTReducer = {
74398
74399
  leave: ({ name, interfaces, directives, fields }) => join(["extend interface", name, wrap("implements ", join(interfaces, " & ")), join(directives, " "), block(fields)], " ")
74399
74400
  },
74400
74401
  UnionTypeExtension: {
74401
- leave: ({ name, directives, types: types42 }) => join(["extend union", name, join(directives, " "), wrap("= ", join(types42, " | "))], " ")
74402
+ leave: ({ name, directives, types: types52 }) => join(["extend union", name, join(directives, " "), wrap("= ", join(types52, " | "))], " ")
74402
74403
  },
74403
74404
  EnumTypeExtension: {
74404
74405
  leave: ({ name, directives, values }) => join(["extend enum", name, join(directives, " "), block(values)], " ")
@@ -74565,45 +74566,6 @@ function deepMerge(...objects) {
74565
74566
  }
74566
74567
  return mergedObj;
74567
74568
  }
74568
- async function marshalSelection({
74569
- selection,
74570
- data: data2
74571
- }) {
74572
- const config2 = getCurrentConfig();
74573
- if (data2 === null || typeof data2 === "undefined") {
74574
- return data2;
74575
- }
74576
- if (Array.isArray(data2)) {
74577
- return await Promise.all(data2.map((val) => marshalSelection({ selection, data: val })));
74578
- }
74579
- const targetSelection = getFieldsForType(selection, data2["__typename"], false);
74580
- return Object.fromEntries(
74581
- await Promise.all(
74582
- Object.entries(data2).map(async ([fieldName, value2]) => {
74583
- const { type, selection: selection2 } = targetSelection[fieldName];
74584
- if (!type) {
74585
- return [fieldName, value2];
74586
- }
74587
- if (selection2) {
74588
- return [fieldName, await marshalSelection({ selection: selection2, data: value2 })];
74589
- }
74590
- if (config2.scalars?.[type]) {
74591
- const marshalFn = config2.scalars[type].marshal;
74592
- if (!marshalFn) {
74593
- throw new Error(
74594
- `scalar type ${type} is missing a \`marshal\` function. see https://github.com/AlecAivazis/houdini#%EF%B8%8Fcustom-scalars`
74595
- );
74596
- }
74597
- if (Array.isArray(value2)) {
74598
- return [fieldName, value2.map(marshalFn)];
74599
- }
74600
- return [fieldName, marshalFn(value2)];
74601
- }
74602
- return [fieldName, value2];
74603
- })
74604
- )
74605
- );
74606
- }
74607
74569
  var ArtifactKind = {
74608
74570
  Query: "HoudiniQuery",
74609
74571
  Subscription: "HoudiniSubscription",
@@ -74614,11 +74576,6 @@ var CompiledFragmentKind = ArtifactKind.Fragment;
74614
74576
  var CompiledMutationKind = ArtifactKind.Mutation;
74615
74577
  var CompiledQueryKind = ArtifactKind.Query;
74616
74578
  var CompiledSubscriptionKind = ArtifactKind.Subscription;
74617
- var DataSource = {
74618
- Cache: "cache",
74619
- Network: "network",
74620
- Ssr: "ssr"
74621
- };
74622
74579
  var fragmentKey = " $fragments";
74623
74580
  var PendingValue = Symbol("houdini_loading");
74624
74581
  var computeKey = ({ field, args }) => {
@@ -77809,194 +77766,6 @@ function defaultComponentField({
77809
77766
  }
77810
77767
  var cache_default = new Cache();
77811
77768
  var serverSide = typeof globalThis.window === "undefined";
77812
- var documentPlugin = (kind, source) => {
77813
- return () => {
77814
- const sourceHandlers = source();
77815
- const enterWrapper = (handler) => {
77816
- return !handler ? void 0 : (ctx, handlers2) => {
77817
- if (ctx.artifact.kind !== kind) {
77818
- return handlers2.next(ctx);
77819
- }
77820
- return handler(ctx, handlers2);
77821
- };
77822
- };
77823
- const exitWrapper = (handler) => {
77824
- return !handler ? void 0 : (ctx, handlers2) => {
77825
- if (ctx.artifact.kind !== kind) {
77826
- return handlers2.resolve(ctx);
77827
- }
77828
- return handler(ctx, handlers2);
77829
- };
77830
- };
77831
- return {
77832
- start: enterWrapper(sourceHandlers.start),
77833
- network: enterWrapper(sourceHandlers.network),
77834
- afterNetwork: exitWrapper(sourceHandlers.afterNetwork),
77835
- end: exitWrapper(sourceHandlers.end),
77836
- catch: sourceHandlers.catch ? (ctx, handlers2) => sourceHandlers.catch(ctx, handlers2) : void 0,
77837
- cleanup: (...args) => sourceHandlers.cleanup?.(...args)
77838
- };
77839
- };
77840
- };
77841
- var query = documentPlugin(ArtifactKind.Query, function() {
77842
- let subscriptionSpec = null;
77843
- let lastVariables = null;
77844
- return {
77845
- start(ctx, { next }) {
77846
- const runtimeScalarPayload = {
77847
- session: ctx.session
77848
- };
77849
- ctx.variables = {
77850
- ...lastVariables,
77851
- ...Object.fromEntries(
77852
- Object.entries(ctx.artifact.input?.runtimeScalars ?? {}).map(
77853
- ([field, type]) => {
77854
- const runtimeScalar = ctx.config.features?.runtimeScalars?.[type];
77855
- if (!runtimeScalar) {
77856
- return [field, type];
77857
- }
77858
- return [field, runtimeScalar.resolve(runtimeScalarPayload)];
77859
- }
77860
- )
77861
- ),
77862
- ...ctx.variables
77863
- };
77864
- next(ctx);
77865
- },
77866
- end(ctx, { resolve: resolve22, marshalVariables: marshalVariables2, variablesChanged: variablesChanged2 }) {
77867
- if (variablesChanged2(ctx) && !ctx.cacheParams?.disableSubscriptions) {
77868
- if (subscriptionSpec) {
77869
- cache_default.unsubscribe(subscriptionSpec, subscriptionSpec.variables?.() || {});
77870
- }
77871
- lastVariables = { ...marshalVariables2(ctx) };
77872
- const variables = lastVariables;
77873
- subscriptionSpec = {
77874
- rootType: ctx.artifact.rootType,
77875
- selection: ctx.artifact.selection,
77876
- variables: () => variables,
77877
- set: (newValue) => {
77878
- resolve22(ctx, {
77879
- data: newValue,
77880
- errors: null,
77881
- fetching: false,
77882
- partial: false,
77883
- stale: false,
77884
- source: DataSource.Cache,
77885
- variables: ctx.variables ?? {}
77886
- });
77887
- }
77888
- };
77889
- cache_default.subscribe(subscriptionSpec, lastVariables);
77890
- }
77891
- resolve22(ctx);
77892
- },
77893
- cleanup() {
77894
- if (subscriptionSpec) {
77895
- cache_default.unsubscribe(subscriptionSpec, subscriptionSpec.variables?.());
77896
- lastVariables = null;
77897
- }
77898
- }
77899
- };
77900
- });
77901
- var fragment = documentPlugin(ArtifactKind.Fragment, function() {
77902
- let subscriptionSpec = null;
77903
- let lastReference = null;
77904
- return {
77905
- start(ctx, { next, resolve: resolve22, variablesChanged: variablesChanged2, marshalVariables: marshalVariables2 }) {
77906
- if (!ctx.stuff.parentID) {
77907
- return next(ctx);
77908
- }
77909
- const currentReference = {
77910
- parent: ctx.stuff.parentID,
77911
- variables: marshalVariables2(ctx)
77912
- };
77913
- if (!ctx.cacheParams?.disableSubscriptions && (!deepEquals(lastReference, currentReference) || variablesChanged2(ctx))) {
77914
- if (subscriptionSpec) {
77915
- cache_default.unsubscribe(subscriptionSpec, subscriptionSpec.variables?.() || {});
77916
- }
77917
- const variables = marshalVariables2(ctx);
77918
- subscriptionSpec = {
77919
- rootType: ctx.artifact.rootType,
77920
- selection: ctx.artifact.selection,
77921
- variables: () => variables,
77922
- parentID: ctx.stuff.parentID,
77923
- set: (newValue) => {
77924
- resolve22(ctx, {
77925
- data: newValue,
77926
- errors: null,
77927
- fetching: false,
77928
- partial: false,
77929
- stale: false,
77930
- source: DataSource.Cache,
77931
- variables
77932
- });
77933
- }
77934
- };
77935
- cache_default.subscribe(subscriptionSpec, variables);
77936
- lastReference = currentReference;
77937
- }
77938
- next(ctx);
77939
- },
77940
- cleanup() {
77941
- if (subscriptionSpec) {
77942
- cache_default.unsubscribe(subscriptionSpec, subscriptionSpec.variables?.());
77943
- }
77944
- }
77945
- };
77946
- });
77947
- var mutation = documentPlugin(ArtifactKind.Mutation, () => {
77948
- return {
77949
- async start(ctx, { next, marshalVariables: marshalVariables2 }) {
77950
- const layerOptimistic = cache_default._internal_unstable.storage.createLayer(true);
77951
- const optimisticResponse = ctx.stuff.optimisticResponse;
77952
- let toNotify = [];
77953
- if (optimisticResponse) {
77954
- toNotify = cache_default.write({
77955
- selection: ctx.artifact.selection,
77956
- data: await marshalSelection({
77957
- selection: ctx.artifact.selection,
77958
- data: optimisticResponse
77959
- }),
77960
- variables: marshalVariables2(ctx),
77961
- layer: layerOptimistic.id
77962
- });
77963
- }
77964
- ctx.cacheParams = {
77965
- ...ctx.cacheParams,
77966
- layer: layerOptimistic,
77967
- notifySubscribers: toNotify,
77968
- forceNotify: true
77969
- };
77970
- next(ctx);
77971
- },
77972
- afterNetwork(ctx, { resolve: resolve22 }) {
77973
- if (ctx.cacheParams?.layer) {
77974
- cache_default.clearLayer(ctx.cacheParams.layer.id);
77975
- }
77976
- resolve22(ctx);
77977
- },
77978
- end(ctx, { resolve: resolve22, value: value2 }) {
77979
- const hasErrors = value2.errors && value2.errors.length > 0;
77980
- if (hasErrors) {
77981
- if (ctx.cacheParams?.layer) {
77982
- cache_default.clearLayer(ctx.cacheParams.layer.id);
77983
- }
77984
- }
77985
- if (ctx.cacheParams?.layer) {
77986
- cache_default._internal_unstable.storage.resolveLayer(ctx.cacheParams.layer.id);
77987
- }
77988
- resolve22(ctx);
77989
- },
77990
- catch(ctx, { error: error2 }) {
77991
- if (ctx.cacheParams?.layer) {
77992
- const { layer } = ctx.cacheParams;
77993
- cache_default.clearLayer(layer.id);
77994
- cache_default._internal_unstable.storage.resolveLayer(layer.id);
77995
- }
77996
- throw error2;
77997
- }
77998
- };
77999
- });
78000
77769
  var currentDir = dirname(fileURLToPath(import.meta.url));
78001
77770
  var DEFAULT_CONFIG_PATH = join2(process.cwd(), "houdini.config.js");
78002
77771
  var emptySchema = graphql2.buildSchema("type Query { hello: String }");
@@ -78035,7 +77804,7 @@ function operation_requires_variables(operation) {
78035
77804
  )
78036
77805
  );
78037
77806
  }
78038
- function unwrapType(config2, type, wrappers = []) {
77807
+ function unwrapType(config2, type, wrappers = [], convertRuntimeScalars) {
78039
77808
  if (type.kind === "NonNullType") {
78040
77809
  return unwrapType(config2, type.type, [TypeWrapper.NonNull, ...wrappers]);
78041
77810
  }
@@ -78051,6 +77820,11 @@ function unwrapType(config2, type, wrappers = []) {
78051
77820
  if (type instanceof graphql3.GraphQLList) {
78052
77821
  return unwrapType(config2, type.ofType, [TypeWrapper.List, ...wrappers]);
78053
77822
  }
77823
+ if (convertRuntimeScalars && config2.configFile.features?.runtimeScalars?.[type.name.value]) {
77824
+ type = config2.schema.getType(
77825
+ config2.configFile.features?.runtimeScalars?.[type.name.value].type
77826
+ );
77827
+ }
78054
77828
  const namedType = config2.schema.getType(type.name.value || type.name);
78055
77829
  if (!namedType) {
78056
77830
  throw new Error("Unknown type: " + type.name.value || type.name);
@@ -78086,7 +77860,12 @@ function deepMerge2(filepath, ...targets) {
78086
77860
  }
78087
77861
  function parseJS(str, config2) {
78088
77862
  const defaultConfig = {
78089
- plugins: ["typescript", "importAssertions", "decorators-legacy"],
77863
+ plugins: [
77864
+ "typescript",
77865
+ "importAssertions",
77866
+ "decorators-legacy",
77867
+ "explicitResourceManagement"
77868
+ ],
78090
77869
  sourceType: "module"
78091
77870
  };
78092
77871
  return (0, import_parser.parse)(str || "", config2 ? deepMerge2("", defaultConfig, config2) : defaultConfig).program;
@@ -78177,6 +77956,8 @@ async function detectFromPackageJSON(cwd) {
78177
77956
  module: packageJSON["type"] === "module" ? "esm" : "commonjs"
78178
77957
  };
78179
77958
  }
77959
+ var recast2 = __toESM2(require_main2(), 1);
77960
+ var AST2 = recast2.types.builders;
78180
77961
  var WalkerBase = class {
78181
77962
  constructor() {
78182
77963
  this.should_skip = false;
@@ -78337,7 +78118,7 @@ async function find_graphql(config2, parsedScript, walker) {
78337
78118
  } else if (!documentString) {
78338
78119
  return;
78339
78120
  }
78340
- const parsedTag = graphql4.parse(documentString);
78121
+ const parsedTag = graphql5.parse(documentString);
78341
78122
  if (walker.where && !walker.where(parsedTag, { node: node2, parent: parent2 })) {
78342
78123
  return;
78343
78124
  }
@@ -78469,7 +78250,7 @@ function extractAnonymousQuery(config2, raw, expr, propName) {
78469
78250
  };
78470
78251
  return defs.concat([
78471
78252
  {
78472
- raw: graphql4.print(parsed),
78253
+ raw: graphql5.print(parsed),
78473
78254
  parsed
78474
78255
  }
78475
78256
  ]);
@@ -78612,14 +78393,14 @@ import * as url from "node:url";
78612
78393
  import { loadEnv } from "vite";
78613
78394
 
78614
78395
  // src/plugin/artifactData.ts
78615
- import * as graphql6 from "graphql";
78396
+ import * as graphql7 from "graphql";
78616
78397
  function artifactData({
78617
78398
  config: config2,
78618
78399
  document: document2
78619
78400
  }) {
78620
78401
  let isManualLoad = document2.filename.endsWith(".svelte");
78621
78402
  let set_blocking = void 0;
78622
- graphql6.visit(document2.document, {
78403
+ graphql7.visit(document2.document, {
78623
78404
  Directive(node2, _, __, ___) {
78624
78405
  if (node2.name.value === config2.loadDirective) {
78625
78406
  isManualLoad = false;
@@ -78654,12 +78435,12 @@ import * as graphql35 from "graphql";
78654
78435
  // ../houdini/build/vite-esm/index.js
78655
78436
  import { createRequire as conflict_free2 } from "module";
78656
78437
  import { statSync as statSync2, createReadStream as createReadStream2, promises as fs22 } from "node:fs";
78657
- import * as graphql33 from "graphql";
78438
+ import * as graphql32 from "graphql";
78658
78439
  import { getNamedType as getNamedType32, isScalarType as isScalarType52 } from "graphql";
78659
78440
  import { parse as parse6 } from "graphql";
78660
78441
  import { GraphQLError as GraphQLError2 } from "graphql";
78661
- import { print as print5, Kind as Kind32, isSpecifiedScalarType as isSpecifiedScalarType5, isIntrospectionType as isIntrospectionType2, isSpecifiedDirective as isSpecifiedDirective3, astFromValue as astFromValue2, GraphQLDeprecatedDirective as GraphQLDeprecatedDirective2, isObjectType as isObjectType10, isInterfaceType as isInterfaceType7, isUnionType as isUnionType7, isInputObjectType as isInputObjectType7, isEnumType as isEnumType6, isScalarType as isScalarType7 } from "graphql";
78662
- import { isNonNullType as isNonNullType6, Kind as Kind20, isListType as isListType7 } from "graphql";
78442
+ import { print as print5, Kind as Kind32, isSpecifiedScalarType as isSpecifiedScalarType5, isIntrospectionType as isIntrospectionType2, isSpecifiedDirective as isSpecifiedDirective3, astFromValue as astFromValue2, GraphQLDeprecatedDirective as GraphQLDeprecatedDirective2, isObjectType as isObjectType10, isInterfaceType as isInterfaceType7, isUnionType as isUnionType7, isInputObjectType as isInputObjectType7, isEnumType as isEnumType7, isScalarType as isScalarType8 } from "graphql";
78443
+ import { isNonNullType as isNonNullType7, Kind as Kind20, isListType as isListType7 } from "graphql";
78663
78444
  import { Kind as Kind22 } from "graphql";
78664
78445
  import { visit as visit5, TokenKind as TokenKind2 } from "graphql";
78665
78446
  import { GraphQLObjectType as GraphQLObjectType32, GraphQLSchema as GraphQLSchema2, isInterfaceType as isInterfaceType32, isEnumType as isEnumType32, isObjectType as isObjectType42, isScalarType as isScalarType32, isUnionType as isUnionType32, isInputObjectType as isInputObjectType42, GraphQLInputObjectType as GraphQLInputObjectType32, GraphQLInterfaceType as GraphQLInterfaceType32, isLeafType as isLeafType22, isListType as isListType42, isNonNullType as isNonNullType32, isNamedType as isNamedType22, GraphQLList as GraphQLList32, GraphQLNonNull as GraphQLNonNull32, GraphQLEnumType as GraphQLEnumType22, Kind as Kind52 } from "graphql";
@@ -78691,7 +78472,7 @@ import fs3 from "node:fs/promises";
78691
78472
  import { promisify as promisify3 } from "node:util";
78692
78473
  import os2 from "node:os";
78693
78474
  import path2 from "node:path";
78694
- import * as graphql7 from "graphql";
78475
+ import * as graphql8 from "graphql";
78695
78476
  import Stream2, { PassThrough as PassThrough2 } from "node:stream";
78696
78477
  import { types as types3, deprecate as deprecate3, promisify as promisify22 } from "node:util";
78697
78478
  import { Buffer as Buffer22 } from "node:buffer";
@@ -78699,32 +78480,31 @@ import { types as types22 } from "node:util";
78699
78480
  import http2 from "node:http";
78700
78481
  import { format as formatUrl2 } from "node:url";
78701
78482
  import { deprecate as deprecate22 } from "node:util";
78702
- import * as graphql32 from "graphql";
78483
+ import * as graphql33 from "graphql";
78703
78484
  import * as graphql42 from "graphql";
78704
78485
  import * as graphql52 from "graphql";
78705
- import * as graphql16 from "graphql";
78706
- import * as graphql72 from "graphql";
78707
78486
  import * as graphql62 from "graphql";
78487
+ import * as graphql17 from "graphql";
78488
+ import * as graphql82 from "graphql";
78489
+ import * as graphql72 from "graphql";
78708
78490
  import { Kind as GraphqlKinds } from "graphql";
78709
- import * as graphql8 from "graphql";
78710
- import * as graphql10 from "graphql";
78711
78491
  import * as graphql9 from "graphql";
78712
- import * as graphql15 from "graphql";
78713
- import * as graphql13 from "graphql";
78714
78492
  import * as graphql11 from "graphql";
78715
- import * as graphql12 from "graphql";
78493
+ import * as graphql10 from "graphql";
78494
+ import * as graphql16 from "graphql";
78716
78495
  import * as graphql14 from "graphql";
78717
- import * as graphql19 from "graphql";
78496
+ import * as graphql12 from "graphql";
78497
+ import * as graphql13 from "graphql";
78498
+ import * as graphql15 from "graphql";
78718
78499
  import * as graphql18 from "graphql";
78719
- import * as graphql17 from "graphql";
78500
+ import * as graphql19 from "graphql";
78720
78501
  import * as graphql20 from "graphql";
78721
78502
  import * as graphql21 from "graphql";
78722
- import * as graphql222 from "graphql";
78723
- import * as graphql24 from "graphql";
78724
78503
  import * as graphql23 from "graphql";
78504
+ import * as graphql222 from "graphql";
78725
78505
  import { parse as parse92 } from "graphql";
78726
78506
  import { GraphQLError as GraphQLError32 } from "graphql";
78727
- import { GraphQLDeprecatedDirective as GraphQLDeprecatedDirective22, isEnumType as isEnumType12, isInputObjectType as isInputObjectType9, isInterfaceType as isInterfaceType92, isIntrospectionType as isIntrospectionType22, isObjectType as isObjectType132, isScalarType as isScalarType122, isSpecifiedDirective as isSpecifiedDirective32, isSpecifiedScalarType as isSpecifiedScalarType52, isUnionType as isUnionType112, Kind as Kind292, print as print102 } from "graphql";
78507
+ import { GraphQLDeprecatedDirective as GraphQLDeprecatedDirective22, isEnumType as isEnumType122, isInputObjectType as isInputObjectType9, isInterfaceType as isInterfaceType92, isIntrospectionType as isIntrospectionType22, isObjectType as isObjectType132, isScalarType as isScalarType122, isSpecifiedDirective as isSpecifiedDirective32, isSpecifiedScalarType as isSpecifiedScalarType52, isUnionType as isUnionType112, Kind as Kind292, print as print102 } from "graphql";
78728
78508
  import { isListType as isListType72, isNonNullType as isNonNullType92, Kind as Kind262 } from "graphql";
78729
78509
  import { isEnumType as isEnumType112, isInputObjectType as isInputObjectType82, isLeafType as isLeafType42, isListType as isListType82, isNonNullType as isNonNullType102, Kind as Kind282 } from "graphql";
78730
78510
  import { Kind as Kind272 } from "graphql";
@@ -78741,6 +78521,7 @@ import { Kind as Kind36 } from "graphql";
78741
78521
  import { Kind as Kind37 } from "graphql";
78742
78522
  import { Kind as Kind38 } from "graphql";
78743
78523
  import { parse as parse102, Kind as Kind40, isSchema as isSchema32, isDefinitionNode as isDefinitionNode22 } from "graphql";
78524
+ import * as graphql24 from "graphql";
78744
78525
  import * as graphql25 from "graphql";
78745
78526
  import * as graphql26 from "graphql";
78746
78527
  import * as graphql27 from "graphql";
@@ -78748,7 +78529,6 @@ import * as graphql28 from "graphql";
78748
78529
  import * as graphql29 from "graphql";
78749
78530
  import * as graphql30 from "graphql";
78750
78531
  import * as graphql31 from "graphql";
78751
- import * as graphql322 from "graphql";
78752
78532
  var require3 = conflict_free2(import.meta.url);
78753
78533
  var __create3 = Object.create;
78754
78534
  var __defProp3 = Object.defineProperty;
@@ -139834,45 +139614,6 @@ function deepMerge3(...objects) {
139834
139614
  }
139835
139615
  return mergedObj;
139836
139616
  }
139837
- async function marshalSelection2({
139838
- selection,
139839
- data: data2
139840
- }) {
139841
- const config2 = getCurrentConfig2();
139842
- if (data2 === null || typeof data2 === "undefined") {
139843
- return data2;
139844
- }
139845
- if (Array.isArray(data2)) {
139846
- return await Promise.all(data2.map((val) => marshalSelection2({ selection, data: val })));
139847
- }
139848
- const targetSelection = getFieldsForType2(selection, data2["__typename"], false);
139849
- return Object.fromEntries(
139850
- await Promise.all(
139851
- Object.entries(data2).map(async ([fieldName, value2]) => {
139852
- const { type, selection: selection2 } = targetSelection[fieldName];
139853
- if (!type) {
139854
- return [fieldName, value2];
139855
- }
139856
- if (selection2) {
139857
- return [fieldName, await marshalSelection2({ selection: selection2, data: value2 })];
139858
- }
139859
- if (config2.scalars?.[type]) {
139860
- const marshalFn = config2.scalars[type].marshal;
139861
- if (!marshalFn) {
139862
- throw new Error(
139863
- `scalar type ${type} is missing a \`marshal\` function. see https://github.com/AlecAivazis/houdini#%EF%B8%8Fcustom-scalars`
139864
- );
139865
- }
139866
- if (Array.isArray(value2)) {
139867
- return [fieldName, value2.map(marshalFn)];
139868
- }
139869
- return [fieldName, marshalFn(value2)];
139870
- }
139871
- return [fieldName, value2];
139872
- })
139873
- )
139874
- );
139875
- }
139876
139617
  var ArtifactKind2 = {
139877
139618
  Query: "HoudiniQuery",
139878
139619
  Subscription: "HoudiniSubscription",
@@ -139883,11 +139624,6 @@ var CompiledFragmentKind2 = ArtifactKind2.Fragment;
139883
139624
  var CompiledMutationKind2 = ArtifactKind2.Mutation;
139884
139625
  var CompiledQueryKind2 = ArtifactKind2.Query;
139885
139626
  var CompiledSubscriptionKind2 = ArtifactKind2.Subscription;
139886
- var DataSource2 = {
139887
- Cache: "cache",
139888
- Network: "network",
139889
- Ssr: "ssr"
139890
- };
139891
139627
  var fragmentKey2 = " $fragments";
139892
139628
  var PendingValue2 = Symbol("houdini_loading");
139893
139629
  var computeKey2 = ({ field, args }) => {
@@ -142963,194 +142699,6 @@ function defaultComponentField2({
142963
142699
  }
142964
142700
  var cache_default2 = new Cache2();
142965
142701
  var serverSide2 = typeof globalThis.window === "undefined";
142966
- var documentPlugin2 = (kind, source) => {
142967
- return () => {
142968
- const sourceHandlers = source();
142969
- const enterWrapper = (handler) => {
142970
- return !handler ? void 0 : (ctx, handlers2) => {
142971
- if (ctx.artifact.kind !== kind) {
142972
- return handlers2.next(ctx);
142973
- }
142974
- return handler(ctx, handlers2);
142975
- };
142976
- };
142977
- const exitWrapper = (handler) => {
142978
- return !handler ? void 0 : (ctx, handlers2) => {
142979
- if (ctx.artifact.kind !== kind) {
142980
- return handlers2.resolve(ctx);
142981
- }
142982
- return handler(ctx, handlers2);
142983
- };
142984
- };
142985
- return {
142986
- start: enterWrapper(sourceHandlers.start),
142987
- network: enterWrapper(sourceHandlers.network),
142988
- afterNetwork: exitWrapper(sourceHandlers.afterNetwork),
142989
- end: exitWrapper(sourceHandlers.end),
142990
- catch: sourceHandlers.catch ? (ctx, handlers2) => sourceHandlers.catch(ctx, handlers2) : void 0,
142991
- cleanup: (...args) => sourceHandlers.cleanup?.(...args)
142992
- };
142993
- };
142994
- };
142995
- var query2 = documentPlugin2(ArtifactKind2.Query, function() {
142996
- let subscriptionSpec = null;
142997
- let lastVariables = null;
142998
- return {
142999
- start(ctx, { next }) {
143000
- const runtimeScalarPayload = {
143001
- session: ctx.session
143002
- };
143003
- ctx.variables = {
143004
- ...lastVariables,
143005
- ...Object.fromEntries(
143006
- Object.entries(ctx.artifact.input?.runtimeScalars ?? {}).map(
143007
- ([field, type]) => {
143008
- const runtimeScalar = ctx.config.features?.runtimeScalars?.[type];
143009
- if (!runtimeScalar) {
143010
- return [field, type];
143011
- }
143012
- return [field, runtimeScalar.resolve(runtimeScalarPayload)];
143013
- }
143014
- )
143015
- ),
143016
- ...ctx.variables
143017
- };
143018
- next(ctx);
143019
- },
143020
- end(ctx, { resolve: resolve22, marshalVariables, variablesChanged }) {
143021
- if (variablesChanged(ctx) && !ctx.cacheParams?.disableSubscriptions) {
143022
- if (subscriptionSpec) {
143023
- cache_default2.unsubscribe(subscriptionSpec, subscriptionSpec.variables?.() || {});
143024
- }
143025
- lastVariables = { ...marshalVariables(ctx) };
143026
- const variables = lastVariables;
143027
- subscriptionSpec = {
143028
- rootType: ctx.artifact.rootType,
143029
- selection: ctx.artifact.selection,
143030
- variables: () => variables,
143031
- set: (newValue) => {
143032
- resolve22(ctx, {
143033
- data: newValue,
143034
- errors: null,
143035
- fetching: false,
143036
- partial: false,
143037
- stale: false,
143038
- source: DataSource2.Cache,
143039
- variables: ctx.variables ?? {}
143040
- });
143041
- }
143042
- };
143043
- cache_default2.subscribe(subscriptionSpec, lastVariables);
143044
- }
143045
- resolve22(ctx);
143046
- },
143047
- cleanup() {
143048
- if (subscriptionSpec) {
143049
- cache_default2.unsubscribe(subscriptionSpec, subscriptionSpec.variables?.());
143050
- lastVariables = null;
143051
- }
143052
- }
143053
- };
143054
- });
143055
- var fragment2 = documentPlugin2(ArtifactKind2.Fragment, function() {
143056
- let subscriptionSpec = null;
143057
- let lastReference = null;
143058
- return {
143059
- start(ctx, { next, resolve: resolve22, variablesChanged, marshalVariables }) {
143060
- if (!ctx.stuff.parentID) {
143061
- return next(ctx);
143062
- }
143063
- const currentReference = {
143064
- parent: ctx.stuff.parentID,
143065
- variables: marshalVariables(ctx)
143066
- };
143067
- if (!ctx.cacheParams?.disableSubscriptions && (!deepEquals2(lastReference, currentReference) || variablesChanged(ctx))) {
143068
- if (subscriptionSpec) {
143069
- cache_default2.unsubscribe(subscriptionSpec, subscriptionSpec.variables?.() || {});
143070
- }
143071
- const variables = marshalVariables(ctx);
143072
- subscriptionSpec = {
143073
- rootType: ctx.artifact.rootType,
143074
- selection: ctx.artifact.selection,
143075
- variables: () => variables,
143076
- parentID: ctx.stuff.parentID,
143077
- set: (newValue) => {
143078
- resolve22(ctx, {
143079
- data: newValue,
143080
- errors: null,
143081
- fetching: false,
143082
- partial: false,
143083
- stale: false,
143084
- source: DataSource2.Cache,
143085
- variables
143086
- });
143087
- }
143088
- };
143089
- cache_default2.subscribe(subscriptionSpec, variables);
143090
- lastReference = currentReference;
143091
- }
143092
- next(ctx);
143093
- },
143094
- cleanup() {
143095
- if (subscriptionSpec) {
143096
- cache_default2.unsubscribe(subscriptionSpec, subscriptionSpec.variables?.());
143097
- }
143098
- }
143099
- };
143100
- });
143101
- var mutation2 = documentPlugin2(ArtifactKind2.Mutation, () => {
143102
- return {
143103
- async start(ctx, { next, marshalVariables }) {
143104
- const layerOptimistic = cache_default2._internal_unstable.storage.createLayer(true);
143105
- const optimisticResponse = ctx.stuff.optimisticResponse;
143106
- let toNotify = [];
143107
- if (optimisticResponse) {
143108
- toNotify = cache_default2.write({
143109
- selection: ctx.artifact.selection,
143110
- data: await marshalSelection2({
143111
- selection: ctx.artifact.selection,
143112
- data: optimisticResponse
143113
- }),
143114
- variables: marshalVariables(ctx),
143115
- layer: layerOptimistic.id
143116
- });
143117
- }
143118
- ctx.cacheParams = {
143119
- ...ctx.cacheParams,
143120
- layer: layerOptimistic,
143121
- notifySubscribers: toNotify,
143122
- forceNotify: true
143123
- };
143124
- next(ctx);
143125
- },
143126
- afterNetwork(ctx, { resolve: resolve22 }) {
143127
- if (ctx.cacheParams?.layer) {
143128
- cache_default2.clearLayer(ctx.cacheParams.layer.id);
143129
- }
143130
- resolve22(ctx);
143131
- },
143132
- end(ctx, { resolve: resolve22, value: value2 }) {
143133
- const hasErrors = value2.errors && value2.errors.length > 0;
143134
- if (hasErrors) {
143135
- if (ctx.cacheParams?.layer) {
143136
- cache_default2.clearLayer(ctx.cacheParams.layer.id);
143137
- }
143138
- }
143139
- if (ctx.cacheParams?.layer) {
143140
- cache_default2._internal_unstable.storage.resolveLayer(ctx.cacheParams.layer.id);
143141
- }
143142
- resolve22(ctx);
143143
- },
143144
- catch(ctx, { error: error2 }) {
143145
- if (ctx.cacheParams?.layer) {
143146
- const { layer } = ctx.cacheParams;
143147
- cache_default2.clearLayer(layer.id);
143148
- cache_default2._internal_unstable.storage.resolveLayer(layer.id);
143149
- }
143150
- throw error2;
143151
- }
143152
- };
143153
- });
143154
142702
  var currentDir2 = dirname2(fileURLToPath2(import.meta.url));
143155
142703
  var DEFAULT_CONFIG_PATH2 = join22(process.cwd(), "houdini.config.js");
143156
142704
  var emptySchema2 = graphql22.buildSchema("type Query { hello: String }");
@@ -143158,8 +142706,10 @@ var defaultDirectives2 = emptySchema2.getDirectives().map((dir) => dir.name);
143158
142706
  var import_parser2 = __toESM3(require_lib32(), 1);
143159
142707
  var import_recast2 = __toESM3(require_main22(), 1);
143160
142708
  var import_deepmerge2 = __toESM3(require_cjs2(), 1);
143161
- var recast2 = __toESM3(require_main22(), 1);
143162
- var AST2 = recast2.types.builders;
142709
+ var recast3 = __toESM3(require_main22(), 1);
142710
+ var AST3 = recast3.types.builders;
142711
+ var recast22 = __toESM3(require_main22(), 1);
142712
+ var AST22 = recast22.types.builders;
143163
142713
  var conventions_exports2 = {};
143164
142714
  __export3(conventions_exports2, {
143165
142715
  adapter_config_path: () => adapter_config_path2,
@@ -143285,43 +142835,43 @@ function serialized_manifest_path2(config2, base = base_dir2(config2)) {
143285
142835
  return path_exports2.join(base, "manifest.json");
143286
142836
  }
143287
142837
  var t22 = __toESM3(require_lib62(), 1);
143288
- var recast4 = __toESM3(require_main22(), 1);
143289
- var recast22 = __toESM3(require_main22(), 1);
143290
- var AST22 = recast22.types.builders;
142838
+ var recast5 = __toESM3(require_main22(), 1);
142839
+ var recast32 = __toESM3(require_main22(), 1);
142840
+ var AST32 = recast32.types.builders;
143291
142841
  var { toString } = {};
143292
142842
  var { keys } = Object;
143293
- var recast3 = __toESM3(require_main22(), 1);
143294
- var AST3 = recast3.types.builders;
142843
+ var recast4 = __toESM3(require_main22(), 1);
142844
+ var AST4 = recast4.types.builders;
143295
142845
  var pageInfoSelection = [
143296
142846
  {
143297
- kind: graphql12.Kind.FIELD,
142847
+ kind: graphql13.Kind.FIELD,
143298
142848
  name: {
143299
- kind: graphql12.Kind.NAME,
142849
+ kind: graphql13.Kind.NAME,
143300
142850
  value: "edges"
143301
142851
  },
143302
142852
  selectionSet: {
143303
- kind: graphql12.Kind.SELECTION_SET,
142853
+ kind: graphql13.Kind.SELECTION_SET,
143304
142854
  selections: [
143305
142855
  {
143306
- kind: graphql12.Kind.FIELD,
142856
+ kind: graphql13.Kind.FIELD,
143307
142857
  name: {
143308
- kind: graphql12.Kind.NAME,
142858
+ kind: graphql13.Kind.NAME,
143309
142859
  value: "cursor"
143310
142860
  }
143311
142861
  },
143312
142862
  {
143313
- kind: graphql12.Kind.FIELD,
142863
+ kind: graphql13.Kind.FIELD,
143314
142864
  name: {
143315
- kind: graphql12.Kind.NAME,
142865
+ kind: graphql13.Kind.NAME,
143316
142866
  value: "node"
143317
142867
  },
143318
142868
  selectionSet: {
143319
- kind: graphql12.Kind.SELECTION_SET,
142869
+ kind: graphql13.Kind.SELECTION_SET,
143320
142870
  selections: [
143321
142871
  {
143322
- kind: graphql12.Kind.FIELD,
142872
+ kind: graphql13.Kind.FIELD,
143323
142873
  name: {
143324
- kind: graphql12.Kind.NAME,
142874
+ kind: graphql13.Kind.NAME,
143325
142875
  value: "__typename"
143326
142876
  }
143327
142877
  }
@@ -143332,39 +142882,39 @@ var pageInfoSelection = [
143332
142882
  }
143333
142883
  },
143334
142884
  {
143335
- kind: graphql12.Kind.FIELD,
142885
+ kind: graphql13.Kind.FIELD,
143336
142886
  name: {
143337
- kind: graphql12.Kind.NAME,
142887
+ kind: graphql13.Kind.NAME,
143338
142888
  value: "pageInfo"
143339
142889
  },
143340
142890
  selectionSet: {
143341
- kind: graphql12.Kind.SELECTION_SET,
142891
+ kind: graphql13.Kind.SELECTION_SET,
143342
142892
  selections: [
143343
142893
  {
143344
- kind: graphql12.Kind.FIELD,
142894
+ kind: graphql13.Kind.FIELD,
143345
142895
  name: {
143346
- kind: graphql12.Kind.NAME,
142896
+ kind: graphql13.Kind.NAME,
143347
142897
  value: "hasPreviousPage"
143348
142898
  }
143349
142899
  },
143350
142900
  {
143351
- kind: graphql12.Kind.FIELD,
142901
+ kind: graphql13.Kind.FIELD,
143352
142902
  name: {
143353
- kind: graphql12.Kind.NAME,
142903
+ kind: graphql13.Kind.NAME,
143354
142904
  value: "hasNextPage"
143355
142905
  }
143356
142906
  },
143357
142907
  {
143358
- kind: graphql12.Kind.FIELD,
142908
+ kind: graphql13.Kind.FIELD,
143359
142909
  name: {
143360
- kind: graphql12.Kind.NAME,
142910
+ kind: graphql13.Kind.NAME,
143361
142911
  value: "startCursor"
143362
142912
  }
143363
142913
  },
143364
142914
  {
143365
- kind: graphql12.Kind.FIELD,
142915
+ kind: graphql13.Kind.FIELD,
143366
142916
  name: {
143367
- kind: graphql12.Kind.NAME,
142917
+ kind: graphql13.Kind.NAME,
143368
142918
  value: "endCursor"
143369
142919
  }
143370
142920
  }
@@ -143372,17 +142922,15 @@ var pageInfoSelection = [
143372
142922
  }
143373
142923
  }
143374
142924
  ];
143375
- var AST4 = recast4.types.builders;
143376
- var recast5 = __toESM3(require_main22(), 1);
143377
142925
  var AST5 = recast5.types.builders;
143378
- var recast11 = __toESM3(require_main22(), 1);
143379
- var recast8 = __toESM3(require_main22(), 1);
143380
- var recast7 = __toESM3(require_main22(), 1);
143381
142926
  var recast6 = __toESM3(require_main22(), 1);
143382
142927
  var AST6 = recast6.types.builders;
142928
+ var recast11 = __toESM3(require_main22(), 1);
142929
+ var recast7 = __toESM3(require_main22(), 1);
143383
142930
  var AST7 = recast7.types.builders;
143384
- var AST8 = recast8.types.builders;
143385
142931
  var recast9 = __toESM3(require_main22(), 1);
142932
+ var recast8 = __toESM3(require_main22(), 1);
142933
+ var AST8 = recast8.types.builders;
143386
142934
  var AST9 = recast9.types.builders;
143387
142935
  var recast10 = __toESM3(require_main22(), 1);
143388
142936
  var AST10 = recast10.types.builders;
@@ -156285,8 +155833,8 @@ function read_tag_name(parser) {
156285
155833
  let i3 = parser.stack.length;
156286
155834
  let legal = false;
156287
155835
  while (i3--) {
156288
- const fragment4 = parser.stack[i3];
156289
- if (fragment4.type === "IfBlock" || fragment4.type === "EachBlock" || fragment4.type === "InlineComponent") {
155836
+ const fragment2 = parser.stack[i3];
155837
+ if (fragment2.type === "IfBlock" || fragment2.type === "EachBlock" || fragment2.type === "InlineComponent") {
156290
155838
  legal = true;
156291
155839
  break;
156292
155840
  }
@@ -156993,7 +156541,7 @@ function text(parser) {
156993
156541
  };
156994
156542
  parser.current().children.push(node2);
156995
156543
  }
156996
- function fragment3(parser) {
156544
+ function fragment(parser) {
156997
156545
  if (parser.match("<")) {
156998
156546
  return tag;
156999
156547
  }
@@ -157155,9 +156703,9 @@ var Parser$1 = class {
157155
156703
  children: []
157156
156704
  };
157157
156705
  this.stack.push(this.html);
157158
- let state = fragment3;
156706
+ let state = fragment;
157159
156707
  while (this.index < this.template.length) {
157160
- state = state(this) || fragment3;
156708
+ state = state(this) || fragment;
157161
156709
  }
157162
156710
  if (this.stack.length > 1) {
157163
156711
  const current2 = this.current();
@@ -157168,7 +156716,7 @@ var Parser$1 = class {
157168
156716
  message: `${type} was left open`
157169
156717
  }, current2.start);
157170
156718
  }
157171
- if (state !== fragment3) {
156719
+ if (state !== fragment) {
157172
156720
  this.error({
157173
156721
  code: "unexpected-eof",
157174
156722
  message: "Unexpected end of input"
@@ -171541,7 +171089,7 @@ async function extract_load_function(config2, filepath, mockArtifacts) {
171541
171089
  return {
171542
171090
  exports,
171543
171091
  houdini_load: load.map(
171544
- (query3) => graphql34.parse(query3).definitions[0]
171092
+ (query) => graphql34.parse(query).definitions[0]
171545
171093
  )
171546
171094
  };
171547
171095
  }
@@ -171557,14 +171105,14 @@ async function processScript(config2, filepath, program, mockArtifacts) {
171557
171105
  }
171558
171106
  for (const specifier of statement.specifiers ?? []) {
171559
171107
  let name = specifier.local?.name || "";
171560
- let query3 = "";
171108
+ let query = "";
171561
171109
  if (name.endsWith(store_suffix(config2))) {
171562
- query3 = name.substring(0, name.length - store_suffix(config2).length);
171110
+ query = name.substring(0, name.length - store_suffix(config2).length);
171563
171111
  } else if (source.startsWith("$houdini/" + stores_directory_name()) && specifier.type === "ImportDefaultSpecifier") {
171564
- query3 = source.substring(`$houdini/${stores_directory_name()}`.length - 1);
171112
+ query = source.substring(`$houdini/${stores_directory_name()}`.length - 1);
171565
171113
  }
171566
- if (query3) {
171567
- const artifact = mockArtifacts?.[query3] || (await import(path_exports.importPath(path_exports.join(config2.artifactDirectory, query3 + ".js")))).default;
171114
+ if (query) {
171115
+ const artifact = mockArtifacts?.[query] || (await import(path_exports.importPath(path_exports.join(config2.artifactDirectory, query + ".js")))).default;
171568
171116
  globalImports[name] = artifact.raw;
171569
171117
  }
171570
171118
  }
@@ -171854,9 +171402,9 @@ async function walk_routes(config2, framework2, visitor, dirpath = config2.route
171854
171402
  continue;
171855
171403
  }
171856
171404
  try {
171857
- const query3 = config2.extractQueryDefinition(graphql35.parse(contents));
171858
- await visitor.routeLayoutQuery?.(query3, childPath);
171859
- layoutQueries.push(query3);
171405
+ const query = config2.extractQueryDefinition(graphql35.parse(contents));
171406
+ await visitor.routeLayoutQuery?.(query, childPath);
171407
+ layoutQueries.push(query);
171860
171408
  } catch (e3) {
171861
171409
  throw routeQueryError(childPath);
171862
171410
  }
@@ -171867,9 +171415,9 @@ async function walk_routes(config2, framework2, visitor, dirpath = config2.route
171867
171415
  continue;
171868
171416
  }
171869
171417
  try {
171870
- const query3 = config2.extractQueryDefinition(graphql35.parse(contents));
171871
- await visitor.routePageQuery?.(query3, childPath);
171872
- pageQueries.push(query3);
171418
+ const query = config2.extractQueryDefinition(graphql35.parse(contents));
171419
+ await visitor.routePageQuery?.(query, childPath);
171420
+ pageQueries.push(query);
171873
171421
  } catch (e3) {
171874
171422
  throw routeQueryError(childPath);
171875
171423
  }
@@ -172033,13 +171581,13 @@ import ${no_ext} from './${file}'
172033
171581
  ` + typeFile + `
172034
171582
  type ${prop_type} = ComponentProps<${no_ext}>
172035
171583
  `;
172036
- for (const query3 of queries[filepath]) {
171584
+ for (const query of queries[filepath]) {
172037
171585
  typeFile = `
172038
- import type { ${query3.name}$input } from '${path_exports.relative(filepath, path_exports.join(config2.artifactDirectory, query3.name)).replace("/$houdini", "")}'
171586
+ import type { ${query.name}$input } from '${path_exports.relative(filepath, path_exports.join(config2.artifactDirectory, query.name)).replace("/$houdini", "")}'
172039
171587
  ` + typeFile + `
172040
171588
  export type ${config2.variableFunctionName(
172041
- query3.name
172042
- )} = <_Props extends ${prop_type}>(args: { props: _Props }) => ${query3.name}$input
171589
+ query.name
171590
+ )} = <_Props extends ${prop_type}>(args: { props: _Props }) => ${query.name}$input
172043
171591
  `;
172044
171592
  }
172045
171593
  }
@@ -172303,10 +171851,10 @@ async function svelteKitGenerator(framework2, { config: config2 }) {
172303
171851
  const houdiniRelative = path_exports.relative(target, config2.typeRootDir);
172304
171852
  const queryNames = [];
172305
171853
  const uniquePageQueries = [];
172306
- for (const query3 of pageQueries) {
172307
- if (!queryNames.includes(query3.name.value)) {
172308
- queryNames.push(query3.name.value);
172309
- uniquePageQueries.push(query3);
171854
+ for (const query of pageQueries) {
171855
+ if (!queryNames.includes(query.name.value)) {
171856
+ queryNames.push(query.name.value);
171857
+ uniquePageQueries.push(query);
172310
171858
  }
172311
171859
  }
172312
171860
  const layoutNames = [];
@@ -172414,8 +171962,8 @@ import type { ${functionImportsToBring.join(
172414
171962
  utilityTypes = utilityTypes.concat(layoutParams).concat(pageParams).replaceAll(/\$types\.js/gm, "$houdini");
172415
171963
  typeExports = typeExports.concat(append_loadInput([...layoutQueries, ...pageQueries])).concat(layout_append_beforeLoad).concat(page_append_beforeLoad).concat(layout_append_afterLoad).concat(page_append_afterLoad).concat(layout_append_onError).concat(page_append_onError).concat(layout_append_VariablesFunction).concat(page_append_VariablesFunction).concat(component_append_VariablesFunction).replace(
172416
171964
  /(?<=LayoutData = )([\s\S]*?)(?=;)/,
172417
- `Expand<$1 & { ${layoutQueries.map((query3) => {
172418
- const name = query3.name.value;
171965
+ `Expand<$1 & { ${layoutQueries.map((query) => {
171966
+ const name = query.name.value;
172419
171967
  return [name, name + store_suffix(config2)].join(": ");
172420
171968
  }).join("; ")} }${internal_append_TypeDataExtra(
172421
171969
  beforeLayoutLoad,
@@ -172424,8 +171972,8 @@ import type { ${functionImportsToBring.join(
172424
171972
  )}>`
172425
171973
  ).replace(
172426
171974
  /(?<=PageData = )([\s\S]*?)(?=;)/,
172427
- `Expand<$1 & { ${pageQueries.map((query3) => {
172428
- const name = query3.name.value;
171975
+ `Expand<$1 & { ${pageQueries.map((query) => {
171976
+ const name = query.name.value;
172429
171977
  return [name, name + store_suffix(config2)].join(": ");
172430
171978
  }).join("; ")} }${internal_append_TypeDataExtra(
172431
171979
  beforePageLoad,
@@ -172450,8 +171998,8 @@ import type { ${functionImportsToBring.join(
172450
171998
  });
172451
171999
  }
172452
172000
  function getTypeImports(houdiniRelative, config2, queries) {
172453
- return queries.map((query3) => {
172454
- const name = query3.name.value;
172001
+ return queries.map((query) => {
172002
+ const name = query.name.value;
172455
172003
  return `
172456
172004
  import { ${name}$result, ${name}$input } from '${houdiniRelative}/${config2.artifactDirectoryName}/${name}';
172457
172005
  import { ${name}Store } from '${houdiniRelative}/plugins/houdini-svelte/${stores_directory_name()}/${name}';`;
@@ -172462,25 +172010,25 @@ function getComponentTypeImports(dirpath, config2, queries) {
172462
172010
  return "";
172463
172011
  }
172464
172012
  let typeFile = "\nimport type { ComponentProps } from 'svelte'\n";
172465
- return typeFile + queries.map((query3) => {
172466
- const no_ext = path_exports.parse(query3.componentPath).name;
172467
- const file = path_exports.parse(query3.componentPath);
172013
+ return typeFile + queries.map((query) => {
172014
+ const no_ext = path_exports.parse(query.componentPath).name;
172015
+ const file = path_exports.parse(query.componentPath);
172468
172016
  return `
172469
172017
  import ${no_ext} from './${file.base}'
172470
- import type { ${query3.query.name.value}$input } from '${path_exports.relative(dirpath, path_exports.join(config2.artifactDirectory, query3.query.name.value)).replace("/$houdini", "")}'
172018
+ import type { ${query.query.name.value}$input } from '${path_exports.relative(dirpath, path_exports.join(config2.artifactDirectory, query.query.name.value)).replace("/$houdini", "")}'
172471
172019
  `;
172472
172020
  }).join("\n");
172473
172021
  }
172474
172022
  function append_VariablesFunction(type, filepath, config2, queries) {
172475
172023
  const { params } = route_params(filepath);
172476
172024
  const garunteed_args = params.filter((param) => !param.optional).map((param) => param.name);
172477
- return queries.map((query3) => {
172478
- const name = query3.name.value;
172479
- if (!query3.variableDefinitions?.length) {
172025
+ return queries.map((query) => {
172026
+ const name = query.name.value;
172027
+ if (!query.variableDefinitions?.length) {
172480
172028
  return "";
172481
172029
  }
172482
172030
  const make_optional = [];
172483
- for (const def of query3.variableDefinitions) {
172031
+ for (const def of query.variableDefinitions) {
172484
172032
  if (garunteed_args.includes(def.variable.name.value)) {
172485
172033
  make_optional.push(`'${def.variable.name.value}'`);
172486
172034
  }
@@ -172496,21 +172044,21 @@ export type ${config2.variableFunctionName(
172496
172044
  }).join("\n");
172497
172045
  }
172498
172046
  function append_ComponentVariablesFunction(filepath, config2, queries) {
172499
- return queries.map((query3) => {
172500
- const no_ext = path_exports.parse(query3.componentPath).name;
172047
+ return queries.map((query) => {
172048
+ const no_ext = path_exports.parse(query.componentPath).name;
172501
172049
  const prop_type = no_ext + "Props";
172502
172050
  return `
172503
172051
  type ${prop_type} = ComponentProps<${no_ext}>
172504
172052
  export type ${config2.variableFunctionName(
172505
- query3.query.name.value
172506
- )} = <_Props extends ${prop_type}>(args: { props: _Props }) => ${query3.query.name.value}$input
172053
+ query.query.name.value
172054
+ )} = <_Props extends ${prop_type}>(args: { props: _Props }) => ${query.query.name.value}$input
172507
172055
  `;
172508
172056
  }).join("\n");
172509
172057
  }
172510
172058
  function append_loadInput(queries) {
172511
172059
  return `${queries.filter((q) => q.variableDefinitions?.length).length ? `
172512
- type LoadInput = { ${queries.filter((query3) => query3.variableDefinitions?.length).map((query3) => {
172513
- const name = query3.name.value;
172060
+ type LoadInput = { ${queries.filter((query) => query.variableDefinitions?.length).map((query) => {
172061
+ const name = query.name.value;
172514
172062
  return [name, name + "$input"].join(": ");
172515
172063
  }).join("; ")} };` : ""}`;
172516
172064
  }
@@ -172529,8 +172077,8 @@ export type AfterLoadEvent = {
172529
172077
  ` : "";
172530
172078
  }
172531
172079
  function internal_append_afterLoad(queries) {
172532
- return `${queries.map((query3) => {
172533
- const name = query3.name.value;
172080
+ return `${queries.map((query) => {
172081
+ const name = query.name.value;
172534
172082
  return [name, name + "$result"].join(": ");
172535
172083
  }).join(";\n ")}`;
172536
172084
  }
@@ -173071,26 +172619,26 @@ async function QueryProcessor(config2, page2) {
173071
172619
  import: ["isBrowser"],
173072
172620
  sourceModule: "$houdini/plugins/houdini-svelte/runtime/adapter"
173073
172621
  });
173074
- for (const query3 of queries) {
172622
+ for (const query of queries) {
173075
172623
  const factory = ensure_imports({
173076
172624
  script: page2.script,
173077
172625
  config: page2.config,
173078
- import: [`${query3.name.value}Store`],
173079
- sourceModule: store_import_path({ config: config2, name: query3.name.value })
172626
+ import: [`${query.name.value}Store`],
172627
+ sourceModule: store_import_path({ config: config2, name: query.name.value })
173080
172628
  }).ids[0];
173081
172629
  page2.script.body.splice(
173082
172630
  find_insert_index(page2.script),
173083
172631
  0,
173084
172632
  AST16.variableDeclaration("const", [
173085
- AST16.variableDeclarator(store_id(query3.name.value), AST16.newExpression(factory, []))
172633
+ AST16.variableDeclarator(store_id(query.name.value), AST16.newExpression(factory, []))
173086
172634
  ])
173087
172635
  );
173088
172636
  }
173089
172637
  page2.script.body.push(
173090
- ...queries.flatMap((query3) => {
173091
- const variable_fn = query_variable_fn(query3.name.value);
172638
+ ...queries.flatMap((query) => {
172639
+ const variable_fn = query_variable_fn(query.name.value);
173092
172640
  const has_variables = find_exported_fn(page2.script.body, variable_fn);
173093
- if (query3.variableDefinitions && query3.variableDefinitions?.length > 0 && has_variables === null) {
172641
+ if (query.variableDefinitions && query.variableDefinitions?.length > 0 && has_variables === null) {
173094
172642
  formatErrors({
173095
172643
  filepath: page2.filepath,
173096
172644
  message: `Could not find required variable function: ${yellow4(
@@ -173107,7 +172655,7 @@ async function QueryProcessor(config2, page2) {
173107
172655
  AST16.identifier("isBrowser"),
173108
172656
  AST16.callExpression(
173109
172657
  AST16.memberExpression(
173110
- store_id(query3.name.value),
172658
+ store_id(query.name.value),
173111
172659
  AST16.identifier("fetch")
173112
172660
  ),
173113
172661
  [
@@ -173126,7 +172674,7 @@ async function QueryProcessor(config2, page2) {
173126
172674
  AST16.objectProperty(
173127
172675
  AST16.identifier("artifact"),
173128
172676
  AST16.memberExpression(
173129
- store_id(query3.name.value),
172677
+ store_id(query.name.value),
173130
172678
  AST16.identifier("artifact")
173131
172679
  )
173132
172680
  ),
@@ -173347,14 +172895,14 @@ function add_load({
173347
172895
  return;
173348
172896
  }
173349
172897
  let invalid = false;
173350
- for (const query3 of queries) {
173351
- if (!query3.variableDefinitions || query3.variableDefinitions.length === 0) {
172898
+ for (const query of queries) {
172899
+ if (!query.variableDefinitions || query.variableDefinitions.length === 0) {
173352
172900
  continue;
173353
172901
  }
173354
- const variable_fn = query_variable_fn(query3.name.value);
172902
+ const variable_fn = query_variable_fn(query.name.value);
173355
172903
  try {
173356
172904
  page2.script.body.push(
173357
- variable_function_for_query(page2, query3, page_info.exports.includes(variable_fn))
172905
+ variable_function_for_query(page2, query, page_info.exports.includes(variable_fn))
173358
172906
  );
173359
172907
  } catch (e3) {
173360
172908
  formatErrors(e3);
@@ -173417,16 +172965,16 @@ function add_load({
173417
172965
  preload_fn.async = true;
173418
172966
  page2.script.body.push(AST18.exportNamedDeclaration(preload_fn));
173419
172967
  let insert_index = 4;
173420
- for (const query3 of queries) {
172968
+ for (const query of queries) {
173421
172969
  const { ids } = ensure_imports({
173422
172970
  script: page2.script,
173423
172971
  config: page2.config,
173424
- import: [`load_${query3.name.value}`],
173425
- sourceModule: store_import_path({ config: page2.config, name: query3.name.value })
172972
+ import: [`load_${query.name.value}`],
172973
+ sourceModule: store_import_path({ config: page2.config, name: query.name.value })
173426
172974
  });
173427
172975
  const load_fn = ids[0];
173428
- const variables = (query3.variableDefinitions?.length ?? 0) > 0 ? AST18.awaitExpression(
173429
- AST18.callExpression(AST18.identifier(__variable_fn_name(query3.name.value)), [
172976
+ const variables = (query.variableDefinitions?.length ?? 0) > 0 ? AST18.awaitExpression(
172977
+ AST18.callExpression(AST18.identifier(__variable_fn_name(query.name.value)), [
173430
172978
  AST18.identifier("houdiniConfig"),
173431
172979
  AST18.identifier("context")
173432
172980
  ])
@@ -173437,7 +172985,7 @@ function add_load({
173437
172985
  AST18.expressionStatement(
173438
172986
  AST18.assignmentExpression(
173439
172987
  "=",
173440
- AST18.memberExpression(input_obj, AST18.literal(query3.name.value)),
172988
+ AST18.memberExpression(input_obj, AST18.literal(query.name.value)),
173441
172989
  variables
173442
172990
  )
173443
172991
  )
@@ -173451,7 +172999,7 @@ function add_load({
173451
172999
  AST18.objectExpression([
173452
173000
  AST18.objectProperty(
173453
173001
  AST18.literal("variables"),
173454
- AST18.memberExpression(input_obj, AST18.literal(query3.name.value))
173002
+ AST18.memberExpression(input_obj, AST18.literal(query.name.value))
173455
173003
  ),
173456
173004
  AST18.objectProperty(AST18.literal("event"), AST18.identifier("context")),
173457
173005
  AST18.objectProperty(
@@ -173607,7 +173155,7 @@ function unexported_data_error(filepath) {
173607
173155
  description: `This is not allowed in a route since it would conflict with Houdini's generated code`
173608
173156
  };
173609
173157
  }
173610
- function variable_function_for_query(page2, query3, has_local) {
173158
+ function variable_function_for_query(page2, query, has_local) {
173611
173159
  const params = route_params(page2.filepath).params.reduce(
173612
173160
  (acc, param) => ({
173613
173161
  ...acc,
@@ -173623,7 +173171,7 @@ function variable_function_for_query(page2, query3, has_local) {
173623
173171
  });
173624
173172
  const missing_args = [];
173625
173173
  const has_args = {};
173626
- for (const definition of query3.variableDefinitions ?? []) {
173174
+ for (const definition of query.variableDefinitions ?? []) {
173627
173175
  const unwrapped = unwrapType(page2.config, definition.type);
173628
173176
  const runtime_scalar = page2.config.configFile.features?.runtimeScalars?.[unwrapped.type.name];
173629
173177
  if (unwrapped.wrappers[unwrapped.wrappers.length - 1] === TypeWrapper.NonNull && !definition.defaultValue && !runtime_scalar && (!params[definition.variable.name.value] || params[definition.variable.name.value].optional)) {
@@ -173637,7 +173185,7 @@ function variable_function_for_query(page2, query3, has_local) {
173637
173185
  throw {
173638
173186
  filepath: page2.filepath,
173639
173187
  message: `Could not find required variable function: ${yellow4(
173640
- query_variable_fn(query3.name.value)
173188
+ query_variable_fn(query.name.value)
173641
173189
  )}. maybe its not exported?`
173642
173190
  };
173643
173191
  }
@@ -173683,7 +173231,7 @@ function variable_function_for_query(page2, query3, has_local) {
173683
173231
  AST18.identifier("input"),
173684
173232
  AST18.awaitExpression(
173685
173233
  AST18.callExpression(
173686
- AST18.identifier(query_variable_fn(query3.name.value)),
173234
+ AST18.identifier(query_variable_fn(query.name.value)),
173687
173235
  [AST18.identifier("event")]
173688
173236
  )
173689
173237
  )
@@ -173694,7 +173242,7 @@ function variable_function_for_query(page2, query3, has_local) {
173694
173242
  config: page2.config,
173695
173243
  script: page2.script,
173696
173244
  page: page2,
173697
- artifact: { name: query3.name.value }
173245
+ artifact: { name: query.name.value }
173698
173246
  }).id
173699
173247
  )
173700
173248
  ])
@@ -173706,7 +173254,7 @@ function variable_function_for_query(page2, query3, has_local) {
173706
173254
  }
173707
173255
  fn_body.push(AST18.returnStatement(AST18.identifier("result")));
173708
173256
  const declaration = AST18.functionDeclaration(
173709
- AST18.identifier(__variable_fn_name(query3.name.value)),
173257
+ AST18.identifier(__variable_fn_name(query.name.value)),
173710
173258
  [AST18.identifier("config"), AST18.identifier("event")],
173711
173259
  AST18.blockStatement(fn_body)
173712
173260
  );