@salesforce/lds-worker-api 1.380.0-dev1 → 1.380.0-dev2

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.
@@ -4274,7 +4274,7 @@ function withDefaultLuvio(callback) {
4274
4274
  }
4275
4275
  callbacks.push(callback);
4276
4276
  }
4277
- // version: 1.380.0-dev1-4b44b915b4
4277
+ // version: 1.380.0-dev2-40594334e8
4278
4278
 
4279
4279
  // TODO [TD-0081508]: once that TD is fulfilled we can probably change this file
4280
4280
  function instrumentAdapter$1(createFunction, _metadata) {
@@ -5318,7 +5318,7 @@ function createGraphQLWireAdapterConstructor(luvio, adapter, metadata, astResolv
5318
5318
  const { apiFamily, name } = metadata;
5319
5319
  return createGraphQLWireAdapterConstructor$1(adapter, `${apiFamily}.${name}`, luvio, astResolver);
5320
5320
  }
5321
- // version: 1.380.0-dev1-4b44b915b4
5321
+ // version: 1.380.0-dev2-40594334e8
5322
5322
 
5323
5323
  /**
5324
5324
  * Copyright (c) 2022, Salesforce, Inc.,
@@ -34154,7 +34154,7 @@ withDefaultLuvio((luvio) => {
34154
34154
  throttle(60, 60000, setupNotifyAllListRecordUpdateAvailable(luvio));
34155
34155
  throttle(60, 60000, setupNotifyAllListInfoSummaryUpdateAvailable(luvio));
34156
34156
  });
34157
- // version: 1.380.0-dev1-b7c5fad9db
34157
+ // version: 1.380.0-dev2-fd70e1c449
34158
34158
 
34159
34159
  function requestIdleDetectedCallback(_callback) { }
34160
34160
  function declareNotifierTaskSingle(_name) {
@@ -95881,7 +95881,7 @@ function buildServiceDescriptor$5(luvio) {
95881
95881
  },
95882
95882
  };
95883
95883
  }
95884
- // version: 1.380.0-dev1-b7c5fad9db
95884
+ // version: 1.380.0-dev2-fd70e1c449
95885
95885
 
95886
95886
  /**
95887
95887
  * Copyright (c) 2022, Salesforce, Inc.,
@@ -95907,7 +95907,7 @@ function buildServiceDescriptor$4(notifyRecordUpdateAvailable, getNormalizedLuvi
95907
95907
  },
95908
95908
  };
95909
95909
  }
95910
- // version: 1.380.0-dev1-b7c5fad9db
95910
+ // version: 1.380.0-dev2-fd70e1c449
95911
95911
 
95912
95912
  /*!
95913
95913
  * Copyright (c) 2022, Salesforce, Inc.,
@@ -96790,7 +96790,7 @@ function buildGraphQLInputExtension$1(input) {
96790
96790
  };
96791
96791
  return prev;
96792
96792
  }, {})) || {};
96793
- const fragments = input.query.definitions.filter((def) => def.kind === "FragmentDefinition").reduce((prev, fragment) => {
96793
+ const fragments = input.query.definitions.filter(isFragmentDefinition$1).reduce((prev, fragment) => {
96794
96794
  prev[fragment.name.value] = fragment;
96795
96795
  return prev;
96796
96796
  }, {});
@@ -96800,6 +96800,47 @@ function buildGraphQLInputExtension$1(input) {
96800
96800
  parentFieldSelection: void 0
96801
96801
  });
96802
96802
  }
96803
+ const TYPENAME_FIELD = {
96804
+ kind: Kind$2.FIELD,
96805
+ name: {
96806
+ kind: Kind$2.NAME,
96807
+ value: "__typename"
96808
+ }
96809
+ };
96810
+ function addTypenameToDocument(doc) {
96811
+ return visit(doc, {
96812
+ SelectionSet: {
96813
+ enter(node, _key, parent) {
96814
+ if (isOperationDefinition(parent)) {
96815
+ return;
96816
+ }
96817
+ const { selections } = node;
96818
+ if (!selections || selections.length === 0) {
96819
+ return;
96820
+ }
96821
+ const skip = selections.some((selection) => {
96822
+ return isField$1(selection) && (selection.name.value === "__typename" || selection.name.value.lastIndexOf("__", 0) === 0);
96823
+ });
96824
+ if (skip) {
96825
+ return;
96826
+ }
96827
+ return {
96828
+ ...node,
96829
+ selections: [...selections, TYPENAME_FIELD]
96830
+ };
96831
+ }
96832
+ }
96833
+ });
96834
+ }
96835
+ function isOperationDefinition(parent) {
96836
+ return !!parent && !Array.isArray(parent) && parent.kind === Kind$2.OPERATION_DEFINITION;
96837
+ }
96838
+ function isField$1(node) {
96839
+ return node.kind === Kind$2.FIELD;
96840
+ }
96841
+ function isFragmentDefinition$1(node) {
96842
+ return node.kind === Kind$2.FRAGMENT_DEFINITION;
96843
+ }
96803
96844
 
96804
96845
  /*!
96805
96846
  * Copyright (c) 2022, Salesforce, Inc.,
@@ -96923,7 +96964,7 @@ class AuraGraphQLNormalizedCacheControlCommand extends AuraNormalizedCacheContro
96923
96964
  if (augmentedQueryResult.isErr()) {
96924
96965
  throw augmentedQueryResult.error;
96925
96966
  }
96926
- return augmentedQueryResult.value;
96967
+ return addTypenameToDocument(augmentedQueryResult.value);
96927
96968
  }
96928
96969
  buildWriteInput(data) {
96929
96970
  const extensionResult = buildGraphQLInputExtension$1({
@@ -97017,7 +97058,7 @@ class HttpGraphQLNormalizedCacheControlCommand extends HttpNormalizedCacheContro
97017
97058
  if (augmentedQueryResult.isErr()) {
97018
97059
  throw augmentedQueryResult.error;
97019
97060
  }
97020
- return augmentedQueryResult.value;
97061
+ return addTypenameToDocument(augmentedQueryResult.value);
97021
97062
  }
97022
97063
  buildWriteInput(data) {
97023
97064
  const extensionResult = buildGraphQLInputExtension$1({
@@ -98023,7 +98064,7 @@ register$1({
98023
98064
  id: '@salesforce/lds-network-adapter',
98024
98065
  instrument: instrument$2,
98025
98066
  });
98026
- // version: 1.380.0-dev1-4b44b915b4
98067
+ // version: 1.380.0-dev2-40594334e8
98027
98068
 
98028
98069
  const { create: create$3, keys: keys$3 } = Object;
98029
98070
  const { stringify: stringify$1, parse } = JSON;
@@ -98981,7 +99022,7 @@ function buildGraphQLInputExtension(input) {
98981
99022
  };
98982
99023
  return prev;
98983
99024
  }, {})) || {};
98984
- const fragments = input.query.definitions.filter((def) => def.kind === "FragmentDefinition").reduce((prev, fragment) => {
99025
+ const fragments = input.query.definitions.filter(isFragmentDefinition).reduce((prev, fragment) => {
98985
99026
  prev[fragment.name.value] = fragment;
98986
99027
  return prev;
98987
99028
  }, {});
@@ -99022,14 +99063,14 @@ function collectFieldNames(selections, fragments) {
99022
99063
  var _a;
99023
99064
  const fieldNames = /* @__PURE__ */ new Set();
99024
99065
  for (const selection of selections) {
99025
- if (selection.kind === Kind.FIELD) {
99066
+ if (isField(selection)) {
99026
99067
  fieldNames.add(((_a = selection.alias) == null ? void 0 : _a.value) || selection.name.value);
99027
- } else if (selection.kind === Kind.INLINE_FRAGMENT) {
99068
+ } else if (isInlineFragment(selection)) {
99028
99069
  collectFieldNames(
99029
99070
  selection.selectionSet.selections,
99030
99071
  fragments
99031
99072
  ).forEach((name) => fieldNames.add(name));
99032
- } else if (selection.kind === Kind.FRAGMENT_SPREAD) {
99073
+ } else if (isFragmentSpread(selection)) {
99033
99074
  const fragment = fragments[selection.name.value];
99034
99075
  if (fragment) {
99035
99076
  collectFieldNames(
@@ -99059,6 +99100,25 @@ function buildFieldKey(canonicalFieldName, fieldArguments, variables) {
99059
99100
  }
99060
99101
  return ok$4(`${canonicalFieldName}::${stableJSONStringify$3({ args: formattedArguments })}`);
99061
99102
  }
99103
+ ({
99104
+ kind: Kind.FIELD,
99105
+ name: {
99106
+ kind: Kind.NAME,
99107
+ value: "__typename"
99108
+ }
99109
+ });
99110
+ function isField(node) {
99111
+ return node.kind === Kind.FIELD;
99112
+ }
99113
+ function isFragmentSpread(node) {
99114
+ return node.kind === Kind.FRAGMENT_SPREAD;
99115
+ }
99116
+ function isInlineFragment(node) {
99117
+ return node.kind === Kind.INLINE_FRAGMENT;
99118
+ }
99119
+ function isFragmentDefinition(node) {
99120
+ return node.kind === Kind.FRAGMENT_DEFINITION;
99121
+ }
99062
99122
  function extractIfArgument(directive, variables, directiveName) {
99063
99123
  var _a;
99064
99124
  const ifArg = (_a = directive.arguments) == null ? void 0 : _a.find((arg) => arg.name.value === "if");
@@ -99342,11 +99402,11 @@ class BaseGraphQLTypeRepository {
99342
99402
  const augmentedSelections = [];
99343
99403
  let augmentedFragments = { ...input.fragments };
99344
99404
  for (const selection of input.selections) {
99345
- if (selection.kind === Kind.FIELD) {
99405
+ if (isField(selection)) {
99346
99406
  const result = this.augmentFieldSelection(selection, augmentedFragments);
99347
99407
  augmentedSelections.push(...result.selections);
99348
99408
  augmentedFragments = result.fragments;
99349
- } else if (selection.kind === Kind.INLINE_FRAGMENT) {
99409
+ } else if (isInlineFragment(selection)) {
99350
99410
  const augmentedFragmentSelections = this.augmentInlineFragmentSelection(
99351
99411
  selection,
99352
99412
  augmentedFragments
@@ -99461,14 +99521,14 @@ class BaseGraphQLTypeRepository {
99461
99521
  const normalized = {};
99462
99522
  const errors = [];
99463
99523
  for (const selection of input.selections) {
99464
- if (selection.kind === Kind.FIELD) {
99524
+ if (isField(selection)) {
99465
99525
  deepMerge$2(
99466
99526
  normalized,
99467
99527
  this.normalizeFieldSelection(cache, input, selection, errors)
99468
99528
  );
99469
99529
  } else {
99470
99530
  let fragment;
99471
- if (selection.kind === Kind.INLINE_FRAGMENT) {
99531
+ if (isInlineFragment(selection)) {
99472
99532
  fragment = selection;
99473
99533
  } else {
99474
99534
  const fragmentDefinition = input.request.definitions.fragments[selection.name.value];
@@ -99573,14 +99633,14 @@ class BaseGraphQLTypeRepository {
99573
99633
  const errors = [];
99574
99634
  const denormalized = {};
99575
99635
  for (const selection of input.selections) {
99576
- if (selection.kind === Kind.FIELD) {
99636
+ if (isField(selection)) {
99577
99637
  deepMerge$2(
99578
99638
  denormalized,
99579
99639
  this.denormalizeFieldSelection(cache, input, selection, errors)
99580
99640
  );
99581
99641
  } else {
99582
99642
  let fragment;
99583
- if (selection.kind === Kind.INLINE_FRAGMENT) {
99643
+ if (isInlineFragment(selection)) {
99584
99644
  fragment = selection;
99585
99645
  } else {
99586
99646
  const fragmentDefinition = input.request.definitions.fragments[selection.name.value];
@@ -99838,6 +99898,19 @@ class IdentifiableGraphQLTypeRepository extends IdentifiableTypeRepository {
99838
99898
  buildFieldKey(selection, variables) {
99839
99899
  return this.graphqlRepository.buildFieldKey(selection, variables);
99840
99900
  }
99901
+ buildKeyParams(input) {
99902
+ var _a;
99903
+ const idField = input.selections.find(
99904
+ (selection) => selection.kind === Kind.FIELD && selection.name.value === this.idField
99905
+ );
99906
+ if (!idField) {
99907
+ throw new Error(`Id field ${this.idField} not found in selections`);
99908
+ }
99909
+ const idFieldDataProperty = ((_a = idField.alias) == null ? void 0 : _a.value) || idField.name.value;
99910
+ return {
99911
+ [this.idField]: input.data[idFieldDataProperty]
99912
+ };
99913
+ }
99841
99914
  }
99842
99915
  class GraphQLDocumentRootTypeRepository extends IdentifiableGraphQLTypeRepository {
99843
99916
  constructor() {
@@ -100383,6 +100456,25 @@ function isIncompleteConfigError(err) {
100383
100456
  (validationError) => validationError instanceof MissingRequiredPropertyError
100384
100457
  ) !== void 0;
100385
100458
  }
100459
+ function resolveAst(ast) {
100460
+ if (ast === null) {
100461
+ return;
100462
+ }
100463
+ const result = astResolver(ast);
100464
+ if (result === void 0) {
100465
+ throw new Error("Could not resolve AST. Did you parse the query with gql?");
100466
+ }
100467
+ return result;
100468
+ }
100469
+ function wrapConfigAndVerify(config) {
100470
+ if (config == null ? void 0 : config.query) {
100471
+ config = { ...config, query: resolveAst(config.query) };
100472
+ if (config.query === void 0) {
100473
+ throw new Error("Internal error in GraphQL adapter occurred: Unable to resolve query");
100474
+ }
100475
+ }
100476
+ return config;
100477
+ }
100386
100478
  class GraphQLCommandWireAdapterConstructor extends CommandWireAdapterConstructor {
100387
100479
  emit(result) {
100388
100480
  try {
@@ -100453,13 +100545,14 @@ class GraphQLCommandWireAdapterConstructor extends CommandWireAdapterConstructor
100453
100545
  this.unsubscribe();
100454
100546
  this.config = {
100455
100547
  ...sanitize(config),
100456
- query: config.query
100548
+ query: resolveAst(config.query)
100457
100549
  };
100458
100550
  this.invokeAdapter();
100459
100551
  }
100460
100552
  }
100461
100553
  function buildAsyncGraphQLImperativeLegacyInvoker(getCommand) {
100462
100554
  const invoke = async (config, requestContext, callback) => {
100555
+ config = wrapConfigAndVerify(config);
100463
100556
  const command = getCommand({ config, assertIsValid });
100464
100557
  try {
100465
100558
  const overrides = requestContextIsCachePolicy(requestContext) ? { cacheControlConfig: { type: "no-cache" } } : {};
@@ -100492,6 +100585,7 @@ function buildAsyncGraphQLImperativeLegacyInvoker(getCommand) {
100492
100585
  }
100493
100586
  };
100494
100587
  const subscribe = (config, requestContext, callback) => {
100588
+ config = wrapConfigAndVerify(config);
100495
100589
  const command = getCommand({ config, assertIsValid });
100496
100590
  let unsubscribe = () => {
100497
100591
  };
@@ -100552,14 +100646,7 @@ function buildAsyncGraphQLImperativeLegacyInvoker(getCommand) {
100552
100646
  function requestContextIsCachePolicy(requestContext) {
100553
100647
  return typeof requestContext === "object" && requestContext !== null && "cachePolicy" in requestContext && typeof requestContext.cachePolicy === "object" && requestContext.cachePolicy !== null && "type" in requestContext.cachePolicy && requestContext.cachePolicy.type === "no-cache";
100554
100648
  }
100555
- function resolveAst(ast) {
100556
- const result = astResolver(ast);
100557
- if (result === void 0) {
100558
- throw new Error("Could not resolve AST. Did you parse the query with gql?");
100559
- }
100560
- return result;
100561
- }
100562
- // version: 1.380.0-dev1-b7c5fad9db
100649
+ // version: 1.380.0-dev2-fd70e1c449
100563
100650
 
100564
100651
  class Analytics__AnalyticsBrowseRepository extends UnidentifiableGraphQLTypeRepository {
100565
100652
  constructor(services, typeRegistry) {
@@ -100624,6 +100711,7 @@ class Analytics__AnalyticsRepresentationRepository extends IdentifiableGraphQLTy
100624
100711
  this.namespace = "oas";
100625
100712
  this.typeName = "Analytics__AnalyticsRepresentation";
100626
100713
  this.implementedInterfaces = ["Analytics__AnalyticsRepresentationInterface"];
100714
+ this.idField = "Id";
100627
100715
  }
100628
100716
  get fields() {
100629
100717
  return {
@@ -100642,9 +100730,6 @@ class Analytics__AnalyticsRepresentationRepository extends IdentifiableGraphQLTy
100642
100730
  Dataspaces: new BaseArrayFieldDef(new BaseObjectFieldDef(this.typeRegistry.Analytics__DataspaceRepresentation, true), true),
100643
100731
  };
100644
100732
  }
100645
- buildKeyParams(input) {
100646
- return { Id: input.data.Id };
100647
- }
100648
100733
  get cacheControl() {
100649
100734
  return { type: "max-age", maxAge: 60 };
100650
100735
  }
@@ -100715,6 +100800,7 @@ class Analytics__AnalyticsWorkspaceRepository extends IdentifiableGraphQLTypeRep
100715
100800
  this.namespace = "oas";
100716
100801
  this.typeName = "Analytics__AnalyticsWorkspace";
100717
100802
  this.implementedInterfaces = [];
100803
+ this.idField = "Id";
100718
100804
  }
100719
100805
  get fields() {
100720
100806
  return {
@@ -100729,9 +100815,6 @@ class Analytics__AnalyticsWorkspaceRepository extends IdentifiableGraphQLTypeRep
100729
100815
  ApiName: new BaseScalarFieldDef(false),
100730
100816
  };
100731
100817
  }
100732
- buildKeyParams(input) {
100733
- return { Id: input.data.Id };
100734
- }
100735
100818
  get cacheControl() {
100736
100819
  return { type: "max-age", maxAge: 60 };
100737
100820
  }
@@ -100745,6 +100828,7 @@ class Analytics__DataspaceRepresentationRepository extends IdentifiableGraphQLTy
100745
100828
  this.namespace = "oas";
100746
100829
  this.typeName = "Analytics__DataspaceRepresentation";
100747
100830
  this.implementedInterfaces = [];
100831
+ this.idField = "Id";
100748
100832
  }
100749
100833
  get fields() {
100750
100834
  return {
@@ -100755,9 +100839,6 @@ class Analytics__DataspaceRepresentationRepository extends IdentifiableGraphQLTy
100755
100839
  DeveloperName: new BaseScalarFieldDef(true),
100756
100840
  };
100757
100841
  }
100758
- buildKeyParams(input) {
100759
- return { Id: input.data.Id };
100760
- }
100761
100842
  get cacheControl() {
100762
100843
  return { type: "max-age", maxAge: 60 };
100763
100844
  }
@@ -101935,6 +102016,7 @@ let RecordRepresentationRepository$1 = class RecordRepresentationRepository exte
101935
102016
  this.namespace = "oas";
101936
102017
  this.typeName = "RecordRepresentation";
101937
102018
  this.implementedInterfaces = ["Record"];
102019
+ this.idField = "Id";
101938
102020
  }
101939
102021
  get fields() {
101940
102022
  return {
@@ -101978,9 +102060,6 @@ let RecordRepresentationRepository$1 = class RecordRepresentationRepository exte
101978
102060
  AnyType: new BaseObjectFieldDef(this.typeRegistry.AnyType, true),
101979
102061
  };
101980
102062
  }
101981
- buildKeyParams(input) {
101982
- return { Id: input.data.Id };
101983
- }
101984
102063
  get cacheControl() {
101985
102064
  return { type: "max-age", maxAge: 60 };
101986
102065
  }
@@ -102110,6 +102189,7 @@ class Setup__EntityRepresentationRepository extends IdentifiableGraphQLTypeRepos
102110
102189
  this.namespace = "oas";
102111
102190
  this.typeName = "Setup__EntityRepresentation";
102112
102191
  this.implementedInterfaces = [];
102192
+ this.idField = "Id";
102113
102193
  }
102114
102194
  get fields() {
102115
102195
  return {
@@ -102148,9 +102228,6 @@ class Setup__EntityRepresentationRepository extends IdentifiableGraphQLTypeRepos
102148
102228
  AnyType: new BaseObjectFieldDef(this.typeRegistry.AnyType, true),
102149
102229
  };
102150
102230
  }
102151
- buildKeyParams(input) {
102152
- return { Id: input.data.Id };
102153
- }
102154
102231
  get cacheControl() {
102155
102232
  return { type: "max-age", maxAge: 60 };
102156
102233
  }
@@ -102325,6 +102402,7 @@ class Setup__ListViewRowRepository extends IdentifiableGraphQLTypeRepository {
102325
102402
  this.namespace = "oas";
102326
102403
  this.typeName = "Setup__ListViewRow";
102327
102404
  this.implementedInterfaces = [];
102405
+ this.idField = "id";
102328
102406
  }
102329
102407
  get fields() {
102330
102408
  return {
@@ -102333,9 +102411,6 @@ class Setup__ListViewRowRepository extends IdentifiableGraphQLTypeRepository {
102333
102411
  columns: new BaseArrayFieldDef(new BaseObjectFieldDef(this.typeRegistry.Setup__ListScalarField, true), false),
102334
102412
  };
102335
102413
  }
102336
- buildKeyParams(input) {
102337
- return { id: input.data.id };
102338
- }
102339
102414
  get cacheControl() {
102340
102415
  return { type: "max-age", maxAge: 60 };
102341
102416
  }
@@ -103371,6 +103446,61 @@ function getFieldCategoryFromData(data) {
103371
103446
  return data.__genericTypename || data.__typename;
103372
103447
  }
103373
103448
 
103449
+ /**
103450
+ * Finds the typename field name from GraphQL selections, looking for __typename or aliased fields.
103451
+ *
103452
+ * @param input - The normalize/denormalize data input containing selections
103453
+ * @returns The field name to use for typename lookup, or '__typename' as fallback
103454
+ */
103455
+ function findTypenameFieldFromSelections(input) {
103456
+ // For normalize inputs, check if selections exist and find __typename field
103457
+ if (input && 'selections' in input && Array.isArray(input.selections)) {
103458
+ const typenameSelection = input.selections.find((selection) => selection.kind === 'Field' && selection.name?.value === '__typename');
103459
+ if (typenameSelection) {
103460
+ // If there's an alias, use the alias name, otherwise use the field name
103461
+ return typenameSelection.alias?.value || typenameSelection.name.value;
103462
+ }
103463
+ }
103464
+ // Fallback to standard __typename field name
103465
+ return '__typename';
103466
+ }
103467
+ /**
103468
+ * Checks if the input data satisfies a fragment type condition by comparing the typename
103469
+ * from the input data with the fragment's conditional type name.
103470
+ *
103471
+ * @param input - The normalize/denormalize data input containing the typename
103472
+ * @param fragment - The fragment containing the type condition
103473
+ * @returns Result<boolean, Error> - true if the type condition is satisfied
103474
+ */
103475
+ function dataSatisfiesFragmentTypeCondition(input, fragment) {
103476
+ const conditionalTypeName = fragment?.typeCondition?.name.value;
103477
+ const typename = input?.data?.[findTypenameFieldFromSelections(input)] ||
103478
+ input?.normalizedData?.__typename?.data;
103479
+ if (conditionalTypeName && typename === conditionalTypeName) {
103480
+ return ok(true);
103481
+ }
103482
+ return ok(false);
103483
+ }
103484
+ /**
103485
+ * Generic implementation of satisfiesFragmentTypeCondition for repositories.
103486
+ * Combines the base class type condition check with custom typename validation.
103487
+ *
103488
+ * @param superSatisfiesFragmentTypeCondition - The super class method to call first
103489
+ * @param input - The normalize/denormalize data input
103490
+ * @param fragment - The fragment containing the type condition
103491
+ * @param typeName - The repository type name for error messages
103492
+ * @returns Result<boolean, Error> - true if the fragment type condition is satisfied
103493
+ */
103494
+ function genericSatisfiesFragmentTypeCondition(superSatisfiesFragmentTypeCondition, input, fragment, typeName) {
103495
+ // First try the base class implementation
103496
+ const result = superSatisfiesFragmentTypeCondition(input, fragment);
103497
+ if (result.isErr() || result.value) {
103498
+ return result;
103499
+ }
103500
+ // Then try our custom typename checking
103501
+ return dataSatisfiesFragmentTypeCondition(input, fragment);
103502
+ }
103503
+
103374
103504
  class RecordRepresentationBaseRepository extends BaseGraphQLTypeRepository {
103375
103505
  constructor(namespace, typeName, implementedInterfaces, fields, idField, services) {
103376
103506
  super();
@@ -103397,15 +103527,8 @@ class RecordRepresentationBaseRepository extends BaseGraphQLTypeRepository {
103397
103527
  getFieldDef(_input, selection) {
103398
103528
  return buildGenericTypeFieldDef(selection, this.fields, this.staticFieldNames, this.typeName);
103399
103529
  }
103400
- satisfiesFragmentTypeCondition(_input, fragment) {
103401
- const result = super.satisfiesFragmentTypeCondition(_input, fragment);
103402
- if (result.isErr()) {
103403
- return result;
103404
- }
103405
- if (result.value) {
103406
- return result;
103407
- }
103408
- return err(new Error(`${this.typeName}: unsupported fragment type condition: ${fragment.typeCondition?.name.value}`));
103530
+ satisfiesFragmentTypeCondition(input, fragment) {
103531
+ return genericSatisfiesFragmentTypeCondition(super.satisfiesFragmentTypeCondition.bind(this), input, fragment, this.typeName);
103409
103532
  }
103410
103533
  }
103411
103534
 
@@ -103414,7 +103537,7 @@ class RecordRepresentationRepository extends RecordRepresentationRepository$1 {
103414
103537
  super(services, typeRegistry);
103415
103538
  this.services = services;
103416
103539
  this.typeRegistry = typeRegistry;
103417
- this.namespace = 'oas';
103540
+ this.namespace = 'uiapi';
103418
103541
  this.typeName = 'RecordRepresentation';
103419
103542
  this.implementedInterfaces = ['Record'];
103420
103543
  this._graphqlRepositoryOverride = undefined;
@@ -103566,14 +103689,7 @@ class CompoundFieldRepository extends CompoundFieldRepository$1 {
103566
103689
  return super.getFieldDef(undefined, selection) !== undefined;
103567
103690
  }
103568
103691
  satisfiesFragmentTypeCondition(_input, fragment) {
103569
- const result = super.satisfiesFragmentTypeCondition(_input, fragment);
103570
- if (result.isErr()) {
103571
- return result;
103572
- }
103573
- if (result.value) {
103574
- return result;
103575
- }
103576
- return err(new Error(`${this.typeName}: unsupported fragment type condition: ${fragment.typeCondition?.name.value}`));
103692
+ return genericSatisfiesFragmentTypeCondition(super.satisfiesFragmentTypeCondition.bind(this), _input, fragment, this.typeName);
103577
103693
  }
103578
103694
  }
103579
103695
 
@@ -103597,14 +103713,7 @@ class RecordAggregateRepository extends RecordAggregateRepository$1 {
103597
103713
  return buildGenericTypeFieldDef(selection, this.fields, this.staticFieldNames, this.typeName);
103598
103714
  }
103599
103715
  satisfiesFragmentTypeCondition(_input, fragment) {
103600
- const result = super.satisfiesFragmentTypeCondition(_input, fragment);
103601
- if (result.isErr()) {
103602
- return result;
103603
- }
103604
- if (result.value) {
103605
- return result;
103606
- }
103607
- return err(new Error(`${this.typeName}: unsupported fragment type condition: ${fragment.typeCondition?.name.value}`));
103716
+ return genericSatisfiesFragmentTypeCondition(super.satisfiesFragmentTypeCondition.bind(this), _input, fragment, this.typeName);
103608
103717
  }
103609
103718
  }
103610
103719
 
@@ -103640,7 +103749,7 @@ class SetupEntityRepresentationRepository extends UnidentifiableGraphQLTypeRepos
103640
103749
  super(services);
103641
103750
  this.services = services;
103642
103751
  this.typeRegistry = typeRegistry;
103643
- this.namespace = 'oas';
103752
+ this.namespace = 'uiapi';
103644
103753
  this.typeName = 'Setup__EntityRepresentation';
103645
103754
  this.implementedInterfaces = [];
103646
103755
  }
@@ -103690,14 +103799,7 @@ class SetupEntityRepresentationRepository extends UnidentifiableGraphQLTypeRepos
103690
103799
  return blobTypeDef;
103691
103800
  }
103692
103801
  satisfiesFragmentTypeCondition(input, fragment) {
103693
- const result = super.satisfiesFragmentTypeCondition(input, fragment);
103694
- if (result.isErr()) {
103695
- return result;
103696
- }
103697
- if (result.value) {
103698
- return result;
103699
- }
103700
- return err(new Error(`${this.typeName}: unsupported fragment type condition: ${fragment.typeCondition?.name.value}`));
103802
+ return genericSatisfiesFragmentTypeCondition(super.satisfiesFragmentTypeCondition.bind(this), input, fragment, this.typeName);
103701
103803
  }
103702
103804
  }
103703
103805
 
@@ -103737,14 +103839,7 @@ class SetupRecordAggregateRepository extends Setup__SetupRecordAggregateReposito
103737
103839
  return blobTypeDef;
103738
103840
  }
103739
103841
  satisfiesFragmentTypeCondition(_input, fragment) {
103740
- const result = super.satisfiesFragmentTypeCondition(_input, fragment);
103741
- if (result.isErr()) {
103742
- return result;
103743
- }
103744
- if (result.value) {
103745
- return result;
103746
- }
103747
- return err(new Error(`${this.typeName}: unsupported fragment type condition: ${fragment.typeCondition?.name.value}`));
103842
+ return genericSatisfiesFragmentTypeCondition(super.satisfiesFragmentTypeCondition.bind(this), _input, fragment, this.typeName);
103748
103843
  }
103749
103844
  }
103750
103845
 
@@ -103763,7 +103858,7 @@ class SetupRepository extends IdentifiableGraphQLTypeRepository {
103763
103858
  constructor(services, typeRegistry) {
103764
103859
  super(services);
103765
103860
  this.typeRegistry = typeRegistry;
103766
- this.namespace = 'oas';
103861
+ this.namespace = 'uiapi';
103767
103862
  this.typeName = 'Setup__Setup';
103768
103863
  this.implementedInterfaces = [];
103769
103864
  this.cacheControl = {
@@ -103784,14 +103879,7 @@ class SetupRepository extends IdentifiableGraphQLTypeRepository {
103784
103879
 
103785
103880
  class SetupEdgeRepository extends Setup__SetupEdgeRepository {
103786
103881
  satisfiesFragmentTypeCondition(_input, fragment) {
103787
- const result = super.satisfiesFragmentTypeCondition(_input, fragment);
103788
- if (result.isErr()) {
103789
- return result;
103790
- }
103791
- if (result.value) {
103792
- return result;
103793
- }
103794
- return err(new Error(`${this.typeName}: unsupported fragment type condition: ${fragment.typeCondition?.name.value}`));
103882
+ return genericSatisfiesFragmentTypeCondition(super.satisfiesFragmentTypeCondition.bind(this), _input, fragment, this.typeName);
103795
103883
  }
103796
103884
  }
103797
103885
 
@@ -103805,118 +103893,55 @@ class PolymorphicAggregateParentRelationshipRepository extends PolymorphicAggreg
103805
103893
 
103806
103894
  class RecordAggregateConnectionRepository extends RecordAggregateConnectionRepository$1 {
103807
103895
  satisfiesFragmentTypeCondition(_input, fragment) {
103808
- const result = super.satisfiesFragmentTypeCondition(_input, fragment);
103809
- if (result.isErr()) {
103810
- return result;
103811
- }
103812
- if (result.value) {
103813
- return result;
103814
- }
103815
- return err(new Error(`${this.typeName}: unsupported fragment type condition: ${fragment.typeCondition?.name.value}`));
103896
+ return genericSatisfiesFragmentTypeCondition(super.satisfiesFragmentTypeCondition.bind(this), _input, fragment, this.typeName);
103816
103897
  }
103817
103898
  }
103818
103899
 
103819
103900
  class RecordAggregateEdgeRepository extends RecordAggregateEdgeRepository$1 {
103820
103901
  satisfiesFragmentTypeCondition(_input, fragment) {
103821
- const result = super.satisfiesFragmentTypeCondition(_input, fragment);
103822
- if (result.isErr()) {
103823
- return result;
103824
- }
103825
- if (result.value) {
103826
- return result;
103827
- }
103828
- return err(new Error(`${this.typeName}: unsupported fragment type condition: ${fragment.typeCondition?.name.value}`));
103902
+ return genericSatisfiesFragmentTypeCondition(super.satisfiesFragmentTypeCondition.bind(this), _input, fragment, this.typeName);
103829
103903
  }
103830
103904
  }
103831
103905
 
103832
103906
  class RecordConnectionRepository extends RecordConnectionRepository$1 {
103833
103907
  satisfiesFragmentTypeCondition(_input, fragment) {
103834
- const result = super.satisfiesFragmentTypeCondition(_input, fragment);
103835
- if (result.isErr()) {
103836
- return result;
103837
- }
103838
- if (result.value) {
103839
- return result;
103840
- }
103841
- return err(new Error(`${this.typeName}: unsupported fragment type condition: ${fragment.typeCondition?.name.value}`));
103908
+ return genericSatisfiesFragmentTypeCondition(super.satisfiesFragmentTypeCondition.bind(this), _input, fragment, this.typeName);
103842
103909
  }
103843
103910
  }
103844
103911
 
103845
103912
  class RecordEdgeRepository extends RecordEdgeRepository$1 {
103846
103913
  satisfiesFragmentTypeCondition(_input, fragment) {
103847
- const result = super.satisfiesFragmentTypeCondition(_input, fragment);
103848
- if (result.isErr()) {
103849
- return result;
103850
- }
103851
- if (result.value) {
103852
- return result;
103853
- }
103854
- return err(new Error(`${this.typeName}: unsupported fragment type condition: ${fragment.typeCondition?.name.value}`));
103914
+ return genericSatisfiesFragmentTypeCondition(super.satisfiesFragmentTypeCondition.bind(this), _input, fragment, this.typeName);
103855
103915
  }
103856
103916
  }
103857
103917
 
103858
103918
  class RecordResultRepository extends RecordResultRepository$1 {
103859
103919
  satisfiesFragmentTypeCondition(_input, fragment) {
103860
- const result = super.satisfiesFragmentTypeCondition(_input, fragment);
103861
- if (result.isErr()) {
103862
- return result;
103863
- }
103864
- if (result.value) {
103865
- return result;
103866
- }
103867
- return err(new Error(`${this.typeName}: unsupported fragment type condition: ${fragment.typeCondition?.name.value}`));
103920
+ return genericSatisfiesFragmentTypeCondition(super.satisfiesFragmentTypeCondition.bind(this), _input, fragment, this.typeName);
103868
103921
  }
103869
103922
  }
103870
103923
 
103871
103924
  class SetupRecordResultRepository extends Setup__SetupRecordResultRepository {
103872
103925
  satisfiesFragmentTypeCondition(_input, fragment) {
103873
- const result = super.satisfiesFragmentTypeCondition(_input, fragment);
103874
- if (result.isErr()) {
103875
- return result;
103876
- }
103877
- if (result.value) {
103878
- return result;
103879
- }
103880
- return err(new Error(`${this.typeName}: unsupported fragment type condition: ${fragment.typeCondition?.name.value}`));
103926
+ return genericSatisfiesFragmentTypeCondition(super.satisfiesFragmentTypeCondition.bind(this), _input, fragment, this.typeName);
103881
103927
  }
103882
103928
  }
103883
103929
 
103884
103930
  class SetupAggregateConnectionRepository extends Setup__SetupAggregateConnectionRepository {
103885
103931
  satisfiesFragmentTypeCondition(_input, fragment) {
103886
- const result = super.satisfiesFragmentTypeCondition(_input, fragment);
103887
- if (result.isErr()) {
103888
- return result;
103889
- }
103890
- if (result.value) {
103891
- return result;
103892
- }
103893
- return err(new Error(`${this.typeName}: unsupported fragment type condition: ${fragment.typeCondition?.name.value}`));
103932
+ return genericSatisfiesFragmentTypeCondition(super.satisfiesFragmentTypeCondition.bind(this), _input, fragment, this.typeName);
103894
103933
  }
103895
103934
  }
103896
103935
 
103897
103936
  class SetupAggregateEdgeRepository extends Setup__SetupAggregateEdgeRepository {
103898
103937
  satisfiesFragmentTypeCondition(_input, fragment) {
103899
- const result = super.satisfiesFragmentTypeCondition(_input, fragment);
103900
- if (result.isErr()) {
103901
- return result;
103902
- }
103903
- if (result.value) {
103904
- return result;
103905
- }
103906
- return err(new Error(`${this.typeName}: unsupported fragment type condition: ${fragment.typeCondition?.name.value}`));
103938
+ return genericSatisfiesFragmentTypeCondition(super.satisfiesFragmentTypeCondition.bind(this), _input, fragment, this.typeName);
103907
103939
  }
103908
103940
  }
103909
103941
 
103910
103942
  class SetupConnectionRepository extends Setup__SetupConnectionRepository {
103911
103943
  satisfiesFragmentTypeCondition(_input, fragment) {
103912
- const result = super.satisfiesFragmentTypeCondition(_input, fragment);
103913
- if (result.isErr()) {
103914
- return result;
103915
- }
103916
- if (result.value) {
103917
- return result;
103918
- }
103919
- return err(new Error(`${this.typeName}: unsupported fragment type condition: ${fragment.typeCondition?.name.value}`));
103944
+ return genericSatisfiesFragmentTypeCondition(super.satisfiesFragmentTypeCondition.bind(this), _input, fragment, this.typeName);
103920
103945
  }
103921
103946
  }
103922
103947
 
@@ -104394,14 +104419,14 @@ getServices(serviceRequirements).then((services) => {
104394
104419
  this.exposeRefresh = true;
104395
104420
  }
104396
104421
  getCommand() {
104397
- return new graphql_ctor({ ...this.config, query: resolveAst(this.config.query) }, documentRootType, services);
104422
+ return new graphql_ctor(this.config, documentRootType, services);
104398
104423
  }
104399
104424
  };
104400
104425
  const graphql_imperative_ctor = services.instrumentCommand(buildCommandClass(services.auraGraphQLNormalizedCacheControlCommand), 'graphql_imperative');
104401
104426
  graphql_imperative$1 = buildAsyncGraphQLImperativeLegacyInvoker(({ config, assertIsValid }) => {
104402
104427
  const _ = assertIsValid;
104403
104428
  _(config, CONFIG_SCHEMA);
104404
- return new graphql_imperative_ctor({ ...config, query: resolveAst(config.query) }, documentRootType, services);
104429
+ return new graphql_imperative_ctor(config, documentRootType, services);
104405
104430
  });
104406
104431
  useOneStoreGraphQL = services.featureFlags?.get('useOneStoreGraphQL') ?? false;
104407
104432
  if (provisionedCallback) {
@@ -104416,7 +104441,7 @@ function registerCallback(cb) {
104416
104441
  cb(graphql$1, graphql_imperative$1, useOneStoreGraphQL);
104417
104442
  }
104418
104443
  }
104419
- // version: 1.380.0-dev1-b7c5fad9db
104444
+ // version: 1.380.0-dev2-fd70e1c449
104420
104445
 
104421
104446
  function createFragmentMap(documentNode) {
104422
104447
  const fragments = {};
@@ -130911,7 +130936,7 @@ function refreshGraphQL(data) {
130911
130936
  }
130912
130937
  return refresh$3(data, 'refreshUiApi');
130913
130938
  }
130914
- // version: 1.380.0-dev1-b7c5fad9db
130939
+ // version: 1.380.0-dev2-fd70e1c449
130915
130940
 
130916
130941
  // On core the unstable adapters are re-exported with different names,
130917
130942
  // we want to match them here.
@@ -131063,7 +131088,7 @@ withDefaultLuvio((luvio) => {
131063
131088
  unstable_graphQL_imperative = createImperativeAdapter(luvio, createInstrumentedAdapter(ldsAdapter, adapterMetadata), adapterMetadata);
131064
131089
  graphQLImperative = ldsAdapter;
131065
131090
  });
131066
- // version: 1.380.0-dev1-b7c5fad9db
131091
+ // version: 1.380.0-dev2-fd70e1c449
131067
131092
 
131068
131093
  var gqlApi = /*#__PURE__*/Object.freeze({
131069
131094
  __proto__: null,
@@ -131862,7 +131887,7 @@ const callbacks$1 = [];
131862
131887
  function register(r) {
131863
131888
  callbacks$1.forEach((callback) => callback(r));
131864
131889
  }
131865
- // version: 1.380.0-dev1-4b44b915b4
131890
+ // version: 1.380.0-dev2-40594334e8
131866
131891
 
131867
131892
  /**
131868
131893
  * Copyright (c) 2022, Salesforce, Inc.,
@@ -133178,4 +133203,4 @@ const { luvio } = getRuntime();
133178
133203
  setDefaultLuvio({ luvio });
133179
133204
 
133180
133205
  export { createPrimingSession, draftManager, draftQueue, evictCacheRecordsByIds, evictExpiredCacheEntries, executeAdapter, executeMutatingAdapter, getImperativeAdapterNames, importLuvioAdapterModule, importOneStoreAdapterModule, invokeAdapter, invokeAdapterWithDraftToMerge, invokeAdapterWithDraftToReplace, invokeAdapterWithMetadata, nimbusDraftQueue, registerReportObserver, setMetadataTTL, setUiApiRecordTTL, stopEviction, subscribeToAdapter };
133181
- // version: 1.380.0-dev1-4b44b915b4
133206
+ // version: 1.380.0-dev2-40594334e8