@salesforce/lds-worker-api 1.321.0 → 1.322.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4271,7 +4271,7 @@
4271
4271
  }
4272
4272
  callbacks.push(callback);
4273
4273
  }
4274
- // version: 1.321.0-1fd3fba1c4
4274
+ // version: 1.322.0-6aa042602a
4275
4275
 
4276
4276
  // TODO [TD-0081508]: once that TD is fulfilled we can probably change this file
4277
4277
  function instrumentAdapter$1(createFunction, _metadata) {
@@ -5219,7 +5219,7 @@
5219
5219
  const { apiFamily, name } = metadata;
5220
5220
  return createGraphQLWireAdapterConstructor$1(adapter, `${apiFamily}.${name}`, luvio, astResolver);
5221
5221
  }
5222
- // version: 1.321.0-1fd3fba1c4
5222
+ // version: 1.322.0-6aa042602a
5223
5223
 
5224
5224
  /**
5225
5225
  * Copyright (c) 2022, Salesforce, Inc.,
@@ -5658,7 +5658,7 @@
5658
5658
  * @returns Luvio or one store wire adapter constructor.
5659
5659
  */
5660
5660
  function getLuvioOrOneStoreAdapter(luvioAdapter, oneStoreAdapter) {
5661
- return oneStoreAdapter !== null && oneStoreAdapter !== void 0 ? oneStoreAdapter : luvioAdapter;
5661
+ return oneStoreAdapter ?? luvioAdapter;
5662
5662
  }
5663
5663
  const getKeywordSearchResultsFactory$2 = new Configurable$2();
5664
5664
  const getListRecordsByNameFactory$2 = new Configurable$2();
@@ -14075,7 +14075,7 @@
14075
14075
  }
14076
14076
 
14077
14077
  const TTL$v = 900000;
14078
- const VERSION$14$2 = "4ba42e1fa0fb00cf78fce86082da41c9";
14078
+ const VERSION$14$2 = "12123f1aca1b5a48303b1d099f9f5629";
14079
14079
  const RepresentationType$M = 'RecordLayoutUserStateRepresentation';
14080
14080
  function keyBuilder$1U(luvio, config) {
14081
14081
  return keyPrefix$3 + '::' + RepresentationType$M + ':' + config.recordTypeId + ':' + config.apiName + ':' + config.layoutType + ':' + config.mode;
@@ -20276,11 +20276,11 @@
20276
20276
  if (config === null) {
20277
20277
  return null;
20278
20278
  }
20279
- // recordTypeId coercion is nuts: if `null` (but not undefined) then use MASTER record type id
20280
20279
  let recordTypeId = config.recordTypeId;
20281
20280
  if (recordTypeId === undefined) {
20282
20281
  // must check untrusted bc config has been coerced
20283
- if (untrustedConfig.recordTypeId !== null) {
20282
+ if (untrustedConfig.recordTypeId !== null &&
20283
+ untrustedConfig.recordTypeId !== undefined) {
20284
20284
  return null;
20285
20285
  }
20286
20286
  recordTypeId = MAIN_RECORD_TYPE_ID$1;
@@ -30582,8 +30582,7 @@
30582
30582
  }
30583
30583
 
30584
30584
  function keyBuilder$8$2(luvio, params) {
30585
- var _a, _b, _c, _d, _e;
30586
- return keyPrefix$3 + '::LookupValuesRepresentation:(' + 'dependentFieldBindings:' + params.queryParams.dependentFieldBindings + ',' + 'page:' + params.queryParams.page + ',' + 'pageSize:' + params.queryParams.pageSize + ',' + 'q:' + params.queryParams.q + ',' + 'searchType:' + params.queryParams.searchType + ',' + 'sourceRecordId:' + params.queryParams.sourceRecordId + ',' + 'targetApiName:' + params.queryParams.targetApiName + ',' + 'fieldApiName:' + params.urlParams.fieldApiName + ',' + 'objectApiName:' + params.urlParams.objectApiName + ',' + (((_a = params.body.sourceRecord) === null || _a === void 0 ? void 0 : _a.allowSaveOnDuplicate) === undefined ? 'sourceRecord.allowSaveOnDuplicate' : 'sourceRecord.allowSaveOnDuplicate:' + ((_b = params.body.sourceRecord) === null || _b === void 0 ? void 0 : _b.allowSaveOnDuplicate)) + '::' + (((_c = params.body.sourceRecord) === null || _c === void 0 ? void 0 : _c.apiName) === undefined ? 'sourceRecord.apiName' : 'sourceRecord.apiName:' + ((_d = params.body.sourceRecord) === null || _d === void 0 ? void 0 : _d.apiName)) + '::' + stableJSONStringify$2((_e = params.body.sourceRecord) === null || _e === void 0 ? void 0 : _e.fields) + '::' + (params.body.orderBy === undefined ? undefined : ('[' + params.body.orderBy.map(element => 'orderBy.fieldApiName:' + element.fieldApiName + '::' + 'orderBy.isAscending:' + element.isAscending).join(',') + ']')) + ')';
30585
+ return keyPrefix$3 + '::LookupValuesRepresentation:(' + 'dependentFieldBindings:' + params.queryParams.dependentFieldBindings + ',' + 'page:' + params.queryParams.page + ',' + 'pageSize:' + params.queryParams.pageSize + ',' + 'q:' + params.queryParams.q + ',' + 'searchType:' + params.queryParams.searchType + ',' + 'sourceRecordId:' + params.queryParams.sourceRecordId + ',' + 'targetApiName:' + params.queryParams.targetApiName + ',' + 'fieldApiName:' + params.urlParams.fieldApiName + ',' + 'objectApiName:' + params.urlParams.objectApiName + ',' + (params.body.sourceRecord?.allowSaveOnDuplicate === undefined ? 'sourceRecord.allowSaveOnDuplicate' : 'sourceRecord.allowSaveOnDuplicate:' + params.body.sourceRecord?.allowSaveOnDuplicate) + '::' + (params.body.sourceRecord?.apiName === undefined ? 'sourceRecord.apiName' : 'sourceRecord.apiName:' + params.body.sourceRecord?.apiName) + '::' + stableJSONStringify$2(params.body.sourceRecord?.fields) + '::' + (params.body.orderBy === undefined ? undefined : ('[' + params.body.orderBy.map(element => 'orderBy.fieldApiName:' + element.fieldApiName + '::' + 'orderBy.isAscending:' + element.isAscending).join(',') + ']')) + ')';
30587
30586
  }
30588
30587
  function getResponseCacheKeys$7$1(storeKeyMap, luvio, resourceParams, response) {
30589
30588
  getTypeCacheKeys$7$2(storeKeyMap, luvio, response, () => keyBuilder$8$2(luvio, resourceParams));
@@ -33432,7 +33431,6 @@
33432
33431
  const getSearchFilterOptionsMetadata = { apiFamily: keyPrefix$3, name: adapterName$b$1, ttl: 30000 };
33433
33432
  const getSearchResultsMetadata = { apiFamily: keyPrefix$3, name: adapterName$9$1, ttl: 200 };
33434
33433
  function bindExportsTo$1(luvio) {
33435
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
33436
33434
  // LDS adapters
33437
33435
  const getActionOverrides_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getActionOverrides', getActionOverridesAdapterFactory), getActionOverridesMetadata);
33438
33436
  const getAllApps_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getAllApps', getAllAppsAdapterFactory), getAllAppsMetadata);
@@ -33441,7 +33439,7 @@
33441
33439
  const getDuplicates_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getDuplicates', getDuplicatesAdapterFactory), getDuplicatesMetadata);
33442
33440
  const getFlexipageFormulaOverrides_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getFlexipageFormulaOverrides', getFlexipageFormulaOverridesAdapterFactory), getFlexipageFormulaOverridesMetadata);
33443
33441
  const getGlobalActions_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getGlobalActions', getGlobalActionsAdapterFactory), getGlobalActionsMetadata);
33444
- const getKeywordSearchResults_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getKeywordSearchResults', (_a = configurationForEnvironmentFactoryOverrides$2.getKeywordSearchResultsAdapterFactory()) !== null && _a !== void 0 ? _a : getKeywordSearchResultsAdapterFactory$1), getKeywordSearchResultsMetadata);
33442
+ const getKeywordSearchResults_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getKeywordSearchResults', configurationForEnvironmentFactoryOverrides$2.getKeywordSearchResultsAdapterFactory() ?? getKeywordSearchResultsAdapterFactory$1), getKeywordSearchResultsMetadata);
33445
33443
  const getLayout_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getLayout', getLayoutAdapterFactory), getLayoutMetadata);
33446
33444
  const getLayoutUserState_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getLayoutUserState', getLayoutUserStateAdapterFactory), getLayoutUserStateMetadata);
33447
33445
  const getListInfoByName_ldsAdapter = createInstrumentedAdapter(createLDSAdapterWithPrediction(createLDSAdapter(luvio, 'getListInfoByName', getListInfoByNameAdapterFactory), luvio, 'getListInfoByName'), getListInfoByNameMetadata);
@@ -33449,11 +33447,11 @@
33449
33447
  const getListInfosByObjectName_ldsAdapter = createInstrumentedAdapter(createLDSAdapterWithPrediction(createLDSAdapter(luvio, 'getListInfosByObjectName', getListInfosByObjectNameAdapterFactory), luvio, 'getListInfosByObjectName'), getListInfosByObjectNameMetadata);
33450
33448
  const getListObjectInfo_ldsAdapter = createInstrumentedAdapter(createLDSAdapterWithPrediction(createLDSAdapter(luvio, 'getListObjectInfo', getListObjectInfoAdapterFactory), luvio, 'getListObjectInfo'), getListObjectInfoMetadata);
33451
33449
  const getListPreferences_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getListPreferences', getListPreferencesAdapterFactory), getListPreferencesMetadata);
33452
- const getListRecordsByName_ldsAdapter = createInstrumentedAdapter(createLDSAdapterWithPrediction(createLDSAdapter(luvio, 'getListRecordsByName', (_b = configurationForEnvironmentFactoryOverrides$2.getListRecordsByNameAdapterFactory()) !== null && _b !== void 0 ? _b : factory$a), luvio, 'getListRecordsByName'), getListRecordsByNameMetadata);
33453
- const getListUi_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getListUi', (_c = configurationForEnvironmentFactoryOverrides$2.getListUiAdapterFactory()) !== null && _c !== void 0 ? _c : factory$h), getListUiMetadata);
33450
+ const getListRecordsByName_ldsAdapter = createInstrumentedAdapter(createLDSAdapterWithPrediction(createLDSAdapter(luvio, 'getListRecordsByName', configurationForEnvironmentFactoryOverrides$2.getListRecordsByNameAdapterFactory() ?? factory$a), luvio, 'getListRecordsByName'), getListRecordsByNameMetadata);
33451
+ const getListUi_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getListUi', configurationForEnvironmentFactoryOverrides$2.getListUiAdapterFactory() ?? factory$h), getListUiMetadata);
33454
33452
  const getLookupActions_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getLookupActions', getLookupActionsAdapterFactory), getLookupActionsMetadata);
33455
33453
  const getLookupMetadata_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getLookupMetadata', getLookupMetadataAdapterFactory), getLookupMetadataMetadata);
33456
- const getLookupRecords_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getLookupRecords', (_d = configurationForEnvironmentFactoryOverrides$2.getLookupRecordsAdapterFactory()) !== null && _d !== void 0 ? _d : factory$9$1), getLookupRecordsMetadata);
33454
+ const getLookupRecords_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getLookupRecords', configurationForEnvironmentFactoryOverrides$2.getLookupRecordsAdapterFactory() ?? factory$9$1), getLookupRecordsMetadata);
33457
33455
  const getNavItems_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getNavItems', getNavItemsAdapterFactory), getNavItemsMetadata);
33458
33456
  const getObjectCreateActions_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getObjectCreateActions', getObjectCreateActionsAdapterFactory), getObjectCreateActionsMetadata);
33459
33457
  const getObjectInfo_ldsAdapter = createInstrumentedAdapter(createLDSAdapterWithPrediction(createLDSAdapter(luvio, 'getObjectInfo', getObjectInfoAdapterFactory), luvio, 'getObjectInfo'), getObjectInfoMetadata);
@@ -33461,18 +33459,18 @@
33461
33459
  const getPathLayout_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getPathLayout', getPathLayoutAdapterFactory), getPathLayoutMetadata);
33462
33460
  const getPicklistValues_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getPicklistValues', getPicklistValuesAdapterFactory), getPicklistValuesMetadata);
33463
33461
  const getPicklistValuesByRecordType_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getPicklistValuesByRecordType', getPicklistValuesByRecordTypeAdapterFactory), getPicklistValuesByRecordTypeMetadata);
33464
- const getQuickActionDefaults_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getQuickActionDefaults', (_e = configurationForEnvironmentFactoryOverrides$2.getQuickActionDefaultsAdapterFactory()) !== null && _e !== void 0 ? _e : getQuickActionDefaultsAdapterFactory$1), getQuickActionDefaultsMetadata);
33462
+ const getQuickActionDefaults_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getQuickActionDefaults', configurationForEnvironmentFactoryOverrides$2.getQuickActionDefaultsAdapterFactory() ?? getQuickActionDefaultsAdapterFactory$1), getQuickActionDefaultsMetadata);
33465
33463
  const getQuickActionInfo_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getQuickActionInfo', getQuickActionInfoAdapterFactory), getQuickActionInfoMetadata);
33466
33464
  const getQuickActionLayout_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getQuickActionLayout', getQuickActionLayoutAdapterFactory), getQuickActionLayoutMetadata);
33467
- const getRecord_ldsAdapter = createInstrumentedAdapter(createLDSAdapterWithPrediction(createLDSAdapter(luvio, 'getRecord', (_f = configurationForEnvironmentFactoryOverrides$2.getRecordAdapterFactory()) !== null && _f !== void 0 ? _f : factory$f), luvio, 'getRecord'), getRecordMetadata);
33465
+ const getRecord_ldsAdapter = createInstrumentedAdapter(createLDSAdapterWithPrediction(createLDSAdapter(luvio, 'getRecord', configurationForEnvironmentFactoryOverrides$2.getRecordAdapterFactory() ?? factory$f), luvio, 'getRecord'), getRecordMetadata);
33468
33466
  const getRecordActions_ldsAdapter = createInstrumentedAdapter(createLDSAdapterWithPrediction(createLDSAdapter(luvio, 'getRecordActions', getRecordActionsAdapterFactory), luvio, 'getRecordActions'), getRecordActionsMetadata);
33469
33467
  const getRecordAvatars_ldsAdapter = createInstrumentedAdapter(createLDSAdapterWithPrediction(createLDSAdapter(luvio, 'getRecordAvatars', getRecordAvatarsAdapterFactory), luvio, 'getRecordAvatars'), getRecordAvatarsMetadata);
33470
- const getRecordCreateDefaults_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getRecordCreateDefaults', (_g = configurationForEnvironmentFactoryOverrides$2.getRecordCreateDefaultsAdapterFactory()) !== null && _g !== void 0 ? _g : factory$7$1), getRecordCreateDefaultsMetadata);
33468
+ const getRecordCreateDefaults_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getRecordCreateDefaults', configurationForEnvironmentFactoryOverrides$2.getRecordCreateDefaultsAdapterFactory() ?? factory$7$1), getRecordCreateDefaultsMetadata);
33471
33469
  const getRecordEditActions_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getRecordEditActions', getRecordEditActionsAdapterFactory), getRecordEditActionsMetadata);
33472
- const getRecordTemplateClone_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getRecordTemplateClone', (_h = configurationForEnvironmentFactoryOverrides$2.getRecordTemplateCloneAdapterFactory()) !== null && _h !== void 0 ? _h : factory$6$1), getRecordTemplateCloneMetadata);
33473
- const getRecordTemplateCreate_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getRecordTemplateCreate', (_j = configurationForEnvironmentFactoryOverrides$2.getRecordTemplateCreateAdapterFactory()) !== null && _j !== void 0 ? _j : factory$5$1), getRecordTemplateCreateMetadata);
33474
- const getRecordUi_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getRecordUi', (_k = configurationForEnvironmentFactoryOverrides$2.getRecordUiAdapterFactory()) !== null && _k !== void 0 ? _k : factory$g), getRecordUiMetadata);
33475
- const getRecords_ldsAdapter = createInstrumentedAdapter(createLDSAdapterWithPrediction(createLDSAdapter(luvio, 'getRecords', (_l = configurationForEnvironmentFactoryOverrides$2.getRecordsAdapterFactory()) !== null && _l !== void 0 ? _l : getRecordsAdapterFactory$1), luvio, 'getRecords'), getRecordsMetadata);
33470
+ const getRecordTemplateClone_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getRecordTemplateClone', configurationForEnvironmentFactoryOverrides$2.getRecordTemplateCloneAdapterFactory() ?? factory$6$1), getRecordTemplateCloneMetadata);
33471
+ const getRecordTemplateCreate_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getRecordTemplateCreate', configurationForEnvironmentFactoryOverrides$2.getRecordTemplateCreateAdapterFactory() ?? factory$5$1), getRecordTemplateCreateMetadata);
33472
+ const getRecordUi_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getRecordUi', configurationForEnvironmentFactoryOverrides$2.getRecordUiAdapterFactory() ?? factory$g), getRecordUiMetadata);
33473
+ const getRecords_ldsAdapter = createInstrumentedAdapter(createLDSAdapterWithPrediction(createLDSAdapter(luvio, 'getRecords', configurationForEnvironmentFactoryOverrides$2.getRecordsAdapterFactory() ?? getRecordsAdapterFactory$1), luvio, 'getRecords'), getRecordsMetadata);
33476
33474
  const getRelatedListActions_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getRelatedListActions', getRelatedListActionsAdapterFactory), getRelatedListActionsMetadata);
33477
33475
  const getRelatedListCount_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getRelatedListCount', getRelatedListCountAdapterFactory), getRelatedListCountMetadata);
33478
33476
  const getRelatedListInfo_ldsAdapter = createInstrumentedAdapter(createRelatedListAdapterWithPrediction(createLDSAdapter(luvio, 'getRelatedListInfo', getRelatedListInfoAdapterFactory), luvio, 'getRelatedListInfo'), getRelatedListInfoMetadata);
@@ -33480,14 +33478,14 @@
33480
33478
  const getRelatedListPreferences_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getRelatedListPreferences', getRelatedListPreferencesAdapterFactory), getRelatedListPreferencesMetadata);
33481
33479
  const getRelatedListPreferencesBatch_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getRelatedListPreferencesBatch', getRelatedListPreferencesBatchAdapterFactory), getRelatedListPreferencesBatchMetadata);
33482
33480
  const getRelatedListRecordActions_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getRelatedListRecordActions', getRelatedListRecordActionsAdapterFactory), getRelatedListRecordActionsMetadata);
33483
- const getRelatedListRecords_ldsAdapter = createInstrumentedAdapter(createRelatedListAdapterWithPrediction(createLDSAdapter(luvio, 'getRelatedListRecords', (_m = configurationForEnvironmentFactoryOverrides$2.getRelatedListRecordsAdapterFactory()) !== null && _m !== void 0 ? _m : getRelatedListRecordsAdapterFactory$1), luvio, 'getRelatedListRecords'), getRelatedListRecordsMetadata);
33484
- const getRelatedListRecordsBatch_ldsAdapter = createInstrumentedAdapter(createRelatedListAdapterWithPrediction(createLDSAdapter(luvio, 'getRelatedListRecordsBatch', (_o = configurationForEnvironmentFactoryOverrides$2.getRelatedListRecordsBatchAdapterFactory()) !== null && _o !== void 0 ? _o : getRelatedListRecordsBatchAdapterFactory$1), luvio, 'getRelatedListRecordsBatch'), getRelatedListRecordsBatchMetadata);
33481
+ const getRelatedListRecords_ldsAdapter = createInstrumentedAdapter(createRelatedListAdapterWithPrediction(createLDSAdapter(luvio, 'getRelatedListRecords', configurationForEnvironmentFactoryOverrides$2.getRelatedListRecordsAdapterFactory() ?? getRelatedListRecordsAdapterFactory$1), luvio, 'getRelatedListRecords'), getRelatedListRecordsMetadata);
33482
+ const getRelatedListRecordsBatch_ldsAdapter = createInstrumentedAdapter(createRelatedListAdapterWithPrediction(createLDSAdapter(luvio, 'getRelatedListRecordsBatch', configurationForEnvironmentFactoryOverrides$2.getRelatedListRecordsBatchAdapterFactory() ?? getRelatedListRecordsBatchAdapterFactory$1), luvio, 'getRelatedListRecordsBatch'), getRelatedListRecordsBatchMetadata);
33485
33483
  const getRelatedListsActions_ldsAdapter = createInstrumentedAdapter(createRelatedListAdapterWithPrediction(createLDSAdapter(luvio, 'getRelatedListsActions', getRelatedListsActionsAdapterFactory), luvio, 'getRelatedListsActions'), getRelatedListsActionsMetadata);
33486
33484
  const getRelatedListsCount_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getRelatedListsCount', getRelatedListsCountAdapterFactory), getRelatedListsCountMetadata);
33487
33485
  const getRelatedListsInfo_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getRelatedListsInfo', getRelatedListsInfoAdapterFactory), getRelatedListsInfoMetadata);
33488
33486
  const getSearchFilterMetadata_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getSearchFilterMetadata', getSearchFilterMetadataAdapterFactory), getSearchFilterMetadataMetadata);
33489
33487
  const getSearchFilterOptions_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getSearchFilterOptions', getSearchFilterOptionsAdapterFactory), getSearchFilterOptionsMetadata);
33490
- const getSearchResults_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getSearchResults', (_p = configurationForEnvironmentFactoryOverrides$2.getSearchResultsAdapterFactory()) !== null && _p !== void 0 ? _p : getSearchResultsAdapterFactory$1), getSearchResultsMetadata);
33488
+ const getSearchResults_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getSearchResults', configurationForEnvironmentFactoryOverrides$2.getSearchResultsAdapterFactory() ?? getSearchResultsAdapterFactory$1), getSearchResultsMetadata);
33491
33489
  function unwrapSnapshotData(factory) {
33492
33490
  const adapter = factory(luvio);
33493
33491
  return (...config) => adapter(...config).then(snapshot => snapshot.data);
@@ -33790,7 +33788,7 @@
33790
33788
  throttle(60, 60000, setupNotifyAllListRecordUpdateAvailable(luvio));
33791
33789
  throttle(60, 60000, setupNotifyAllListInfoSummaryUpdateAvailable(luvio));
33792
33790
  });
33793
- // version: 1.321.0-40847d67a8
33791
+ // version: 1.322.0-87f682c9f3
33794
33792
 
33795
33793
  var ldsIdempotencyWriteDisabled = {
33796
33794
  isOpen: function (e) {
@@ -47070,7 +47068,7 @@
47070
47068
  try {
47071
47069
  cancelFn();
47072
47070
  }
47073
- catch (_a) {
47071
+ catch {
47074
47072
  success = false;
47075
47073
  }
47076
47074
  }
@@ -47082,7 +47080,7 @@
47082
47080
  try {
47083
47081
  cancelFn();
47084
47082
  }
47085
- catch (_b) {
47083
+ catch {
47086
47084
  success = false;
47087
47085
  }
47088
47086
  }
@@ -47902,7 +47900,7 @@
47902
47900
  try {
47903
47901
  await this.startQueueSafe();
47904
47902
  }
47905
- catch (_a) {
47903
+ catch {
47906
47904
  // An error starting the queue should not bubble up from this method
47907
47905
  }
47908
47906
  }
@@ -51448,7 +51446,7 @@
51448
51446
  return endOfList > 0 ? endOfList - 1 : 0; // Cursor based pagination in gql is off by one :)
51449
51447
  }
51450
51448
  // end is included in the above case.
51451
- return Object.values(metadata).reduce((acc, value) => Math.max(value !== null && value !== void 0 ? value : -1, acc), -1);
51449
+ return Object.values(metadata).reduce((acc, value) => Math.max(value ?? -1, acc), -1);
51452
51450
  }
51453
51451
  function getPageTokenAndOffset$1(paginationMetadata, token) {
51454
51452
  if (token === undefined) {
@@ -57700,7 +57698,8 @@
57700
57698
  '")');
57701
57699
  }
57702
57700
  })();
57703
- if (obj_values_item_union0_error !== null) {
57701
+ // eslint-disable-next-line eqeqeq
57702
+ if (obj_values_item_union0_error != null) {
57704
57703
  obj_values_item_union0 = obj_values_item_union0_error.message;
57705
57704
  }
57706
57705
  let obj_values_item_union1 = null;
@@ -57713,7 +57712,8 @@
57713
57712
  '")');
57714
57713
  }
57715
57714
  })();
57716
- if (obj_values_item_union1_error !== null) {
57715
+ // eslint-disable-next-line eqeqeq
57716
+ if (obj_values_item_union1_error != null) {
57717
57717
  obj_values_item_union1 = obj_values_item_union1_error.message;
57718
57718
  }
57719
57719
  let obj_values_item_union2 = null;
@@ -57726,7 +57726,8 @@
57726
57726
  '")');
57727
57727
  }
57728
57728
  })();
57729
- if (obj_values_item_union2_error !== null) {
57729
+ // eslint-disable-next-line eqeqeq
57730
+ if (obj_values_item_union2_error != null) {
57730
57731
  obj_values_item_union2 = obj_values_item_union2_error.message;
57731
57732
  }
57732
57733
  if (obj_values_item_union0 && obj_values_item_union1 && obj_values_item_union2) {
@@ -58495,7 +58496,8 @@
58495
58496
  '")');
58496
58497
  }
58497
58498
  })();
58498
- if (obj_fields_prop_union0_error !== null) {
58499
+ // eslint-disable-next-line eqeqeq
58500
+ if (obj_fields_prop_union0_error != null) {
58499
58501
  obj_fields_prop_union0 = obj_fields_prop_union0_error.message;
58500
58502
  }
58501
58503
  let obj_fields_prop_union1 = null;
@@ -58508,7 +58510,8 @@
58508
58510
  '")');
58509
58511
  }
58510
58512
  })();
58511
- if (obj_fields_prop_union1_error !== null) {
58513
+ // eslint-disable-next-line eqeqeq
58514
+ if (obj_fields_prop_union1_error != null) {
58512
58515
  obj_fields_prop_union1 = obj_fields_prop_union1_error.message;
58513
58516
  }
58514
58517
  let obj_fields_prop_union2 = null;
@@ -58521,7 +58524,8 @@
58521
58524
  '")');
58522
58525
  }
58523
58526
  })();
58524
- if (obj_fields_prop_union2_error !== null) {
58527
+ // eslint-disable-next-line eqeqeq
58528
+ if (obj_fields_prop_union2_error != null) {
58525
58529
  obj_fields_prop_union2 = obj_fields_prop_union2_error.message;
58526
58530
  }
58527
58531
  let obj_fields_prop_union3 = null;
@@ -58534,7 +58538,8 @@
58534
58538
  '")');
58535
58539
  }
58536
58540
  })();
58537
- if (obj_fields_prop_union3_error !== null) {
58541
+ // eslint-disable-next-line eqeqeq
58542
+ if (obj_fields_prop_union3_error != null) {
58538
58543
  obj_fields_prop_union3 = obj_fields_prop_union3_error.message;
58539
58544
  }
58540
58545
  if (obj_fields_prop_union0 &&
@@ -67150,14 +67155,13 @@
67150
67155
  };
67151
67156
  }
67152
67157
  function ingestPaginationMetadata$2$1(astNode, state, key, sink, existingData) {
67153
- var _a;
67154
67158
  const { data, luvio, store } = state;
67155
67159
  const { pageInfo: { hasNextPage, startCursor }, edges } = data;
67156
67160
  if (!hasGraphQLPaginationFields$1(data))
67157
67161
  return;
67158
67162
  const paginationKey = key + '__pagination';
67159
67163
  let existingPaginationMetadata = store.readEntry(paginationKey);
67160
- const afterArg = (_a = astNode.arguments) === null || _a === void 0 ? void 0 : _a.find(argument => { return argument.name.value === 'after'; });
67164
+ const afterArg = astNode.arguments?.find(argument => { return argument.name.value === 'after'; });
67161
67165
  const afterArgVal = evaluateArgumentValue$1(afterArg, 'StringValue', state.variables);
67162
67166
  const isPagedResponse = afterArgVal !== undefined &&
67163
67167
  existingPaginationMetadata !== undefined &&
@@ -72327,14 +72331,13 @@
72327
72331
  };
72328
72332
  }
72329
72333
  function ingestPaginationMetadata$1$1(astNode, state, key, sink, existingData) {
72330
- var _a;
72331
72334
  const { data, luvio, store } = state;
72332
72335
  const { pageInfo: { hasNextPage, startCursor }, edges } = data;
72333
72336
  if (!hasGraphQLPaginationFields$1(data))
72334
72337
  return;
72335
72338
  const paginationKey = key + '__pagination';
72336
72339
  let existingPaginationMetadata = store.readEntry(paginationKey);
72337
- const afterArg = (_a = astNode.arguments) === null || _a === void 0 ? void 0 : _a.find(argument => { return argument.name.value === 'after'; });
72340
+ const afterArg = astNode.arguments?.find(argument => { return argument.name.value === 'after'; });
72338
72341
  const afterArgVal = evaluateArgumentValue$1(afterArg, 'StringValue', state.variables);
72339
72342
  const isPagedResponse = afterArgVal !== undefined &&
72340
72343
  existingPaginationMetadata !== undefined &&
@@ -76266,14 +76269,13 @@
76266
76269
  };
76267
76270
  }
76268
76271
  function ingestPaginationMetadata$4(astNode, state, key, sink, existingData) {
76269
- var _a;
76270
76272
  const { data, luvio, store } = state;
76271
76273
  const { pageInfo: { hasNextPage, startCursor }, edges } = data;
76272
76274
  if (!hasGraphQLPaginationFields$1(data))
76273
76275
  return;
76274
76276
  const paginationKey = key + '__pagination';
76275
76277
  let existingPaginationMetadata = store.readEntry(paginationKey);
76276
- const afterArg = (_a = astNode.arguments) === null || _a === void 0 ? void 0 : _a.find(argument => { return argument.name.value === 'after'; });
76278
+ const afterArg = astNode.arguments?.find(argument => { return argument.name.value === 'after'; });
76277
76279
  const afterArgVal = evaluateArgumentValue$1(afterArg, 'StringValue', state.variables);
76278
76280
  const isPagedResponse = afterArgVal !== undefined &&
76279
76281
  existingPaginationMetadata !== undefined &&
@@ -77657,8 +77659,7 @@
77657
77659
  }
77658
77660
 
77659
77661
  function applyToSelection$3$1(selection, directive, variables) {
77660
- var _a;
77661
- const ifArg = (_a = directive.arguments) === null || _a === void 0 ? void 0 : _a.find(argument => argument.name.value === "if");
77662
+ const ifArg = directive.arguments?.find(argument => argument.name.value === "if");
77662
77663
  if (ifArg && ifArg.value) {
77663
77664
  if (ifArg.value.kind === "BooleanValue") {
77664
77665
  return ifArg.value.value ? selection : undefined;
@@ -77671,8 +77672,7 @@
77671
77672
  }
77672
77673
 
77673
77674
  function applyToSelection$2$1(selection, directive, variables) {
77674
- var _a;
77675
- const ifArg = (_a = directive.arguments) === null || _a === void 0 ? void 0 : _a.find(argument => argument.name.value === "if");
77675
+ const ifArg = directive.arguments?.find(argument => argument.name.value === "if");
77676
77676
  if (ifArg && ifArg.value) {
77677
77677
  if (ifArg.value.kind === "BooleanValue") {
77678
77678
  return ifArg.value.value ? undefined : selection;
@@ -77846,7 +77846,7 @@
77846
77846
  selections: queryTransformHelper.getMinimumSelections()
77847
77847
  };
77848
77848
  const mergedSelections = mergeSelectionSets$1(selectionSetNode, minimumSelectionSet);
77849
- mergedSelections === null || mergedSelections === void 0 ? void 0 : mergedSelections.selections.forEach(selection => {
77849
+ mergedSelections?.selections.forEach(selection => {
77850
77850
  if (selection.kind === 'Field') {
77851
77851
  const fieldType = queryTransformHelper.getFieldType(selection);
77852
77852
  const fieldTransformHelper = fieldType === undefined ? undefined : getQueryTransformerForType$1(fieldType.typename);
@@ -78422,13 +78422,12 @@
78422
78422
  }
78423
78423
  // Shared export for getting the offset of the current page in the edges array
78424
78424
  function getArrayOffsetForPage$1(state, node, key) {
78425
- var _a;
78426
78425
  const { variables, data, store } = state;
78427
78426
  // if we have pagination metadata, see if we can locate either the start or
78428
78427
  // after cursor in it to determine the correct index to use for the fullPath
78429
78428
  const paginationKey = key + '__pagination';
78430
78429
  let existingPaginationMetadata = store.readEntry(paginationKey);
78431
- const afterArg = (_a = node.arguments) === null || _a === void 0 ? void 0 : _a.find(argument => { return argument.name.value === 'after'; });
78430
+ const afterArg = node.arguments?.find(argument => { return argument.name.value === 'after'; });
78432
78431
  const afterArgVal = evaluateArgumentValue$1(afterArg, 'StringValue', variables);
78433
78432
  if (existingPaginationMetadata !== undefined) {
78434
78433
  // if the starting cursor for current page exists in the existing metadata use that as offset
@@ -78558,8 +78557,7 @@
78558
78557
  });
78559
78558
  }
78560
78559
  function selectCalculateSink$1(sink, field, buildSelectionForNodeFn, source, reader, variables, fragments, parentRecordId) {
78561
- var _a;
78562
- (_a = field.selectionSet) === null || _a === void 0 ? void 0 : _a.selections.forEach((sel) => {
78560
+ field.selectionSet?.selections.forEach((sel) => {
78563
78561
  const builtSelection = buildSelectionForNodeFn(source, reader, field, sel, variables, fragments, parentRecordId);
78564
78562
  if (builtSelection !== undefined) {
78565
78563
  deepMerge$1(sink, builtSelection);
@@ -78568,7 +78566,6 @@
78568
78566
  return sink;
78569
78567
  }
78570
78568
  function selectTypeLinkWithPagination$1(resolvedLink, sel, fieldData, reader, key, sink, variables, fragments, selectFn) {
78571
- var _a, _b, _c, _d, _e;
78572
78569
  const source = resolvedLink.data.data;
78573
78570
  const parentRecordId = resolvedLink.recordId;
78574
78571
  const totalEdges = source.edges !== undefined ? source.edges.length : 0;
@@ -78578,10 +78575,10 @@
78578
78575
  reader.markMissing();
78579
78576
  return;
78580
78577
  }
78581
- const firstArg = (_a = sel.arguments) === null || _a === void 0 ? void 0 : _a.find(argument => { return argument.name.value === 'first'; });
78578
+ const firstArg = sel.arguments?.find(argument => { return argument.name.value === 'first'; });
78582
78579
  const firstArgVal = evaluateArgumentValue$1(firstArg, 'IntValue', variables);
78583
78580
  const pageSize = firstArgVal !== undefined ? firstArgVal : totalEdges;
78584
- const afterArg = (_b = sel.arguments) === null || _b === void 0 ? void 0 : _b.find(argument => { return argument.name.value === 'after'; });
78581
+ const afterArg = sel.arguments?.find(argument => { return argument.name.value === 'after'; });
78585
78582
  const afterArgVal = evaluateArgumentValue$1(afterArg, 'StringValue', variables);
78586
78583
  const paginationParams = {
78587
78584
  pageSize: parseInt(pageSize, 10),
@@ -78631,7 +78628,7 @@
78631
78628
  reader.markMissingLink(fieldData.__ref);
78632
78629
  reader.markMissing();
78633
78630
  // optimize pagination when "first" and "after" args are part of the variable
78634
- if (((_c = firstArg === null || firstArg === void 0 ? void 0 : firstArg.value) === null || _c === void 0 ? void 0 : _c.kind) === 'Variable' && ((_d = afterArg === null || afterArg === void 0 ? void 0 : afterArg.value) === null || _d === void 0 ? void 0 : _d.kind) === 'Variable') {
78631
+ if (firstArg?.value?.kind === 'Variable' && afterArg?.value?.kind === 'Variable') {
78635
78632
  optimizePagination$1(metadata, firstArg.value.name.value, afterArg.value.name.value, variables);
78636
78633
  }
78637
78634
  return;
@@ -78647,9 +78644,9 @@
78647
78644
  };
78648
78645
  reader.markSeenId(parentRecordId);
78649
78646
  const result = selectFn(sel, variables, fragments)(paginatedData, reader, parentRecordId);
78650
- const pageInfo = createPageInfo$1(result === null || result === void 0 ? void 0 : result.edges, startOffset, endOffset, maxOffset, metadata);
78647
+ const pageInfo = createPageInfo$1(result?.edges, startOffset, endOffset, maxOffset, metadata);
78651
78648
  if (pageInfo !== undefined) {
78652
- const selectedPageInfo = selectPageInfo$1((_e = sel.selectionSet) === null || _e === void 0 ? void 0 : _e.selections, fragments, pageInfo);
78649
+ const selectedPageInfo = selectPageInfo$1(sel.selectionSet?.selections, fragments, pageInfo);
78653
78650
  if (selectedPageInfo !== undefined) {
78654
78651
  reader.assignNonScalar(result, 'pageInfo', selectedPageInfo);
78655
78652
  }
@@ -78657,11 +78654,10 @@
78657
78654
  reader.assignNonScalar(sink, key, result);
78658
78655
  }
78659
78656
  function selectPageInfo$1(selections, fragments, pageInfo) {
78660
- var _a;
78661
78657
  const pageInfoSelection = getSelectionNode$1(selections, fragments, 'pageInfo');
78662
78658
  if (pageInfo === undefined || pageInfoSelection === undefined || pageInfoSelection.kind !== 'Field')
78663
78659
  return undefined;
78664
- const pageInfoSelections = (_a = pageInfoSelection.selectionSet) === null || _a === void 0 ? void 0 : _a.selections;
78660
+ const pageInfoSelections = pageInfoSelection.selectionSet?.selections;
78665
78661
  const selectedPageInfo = Object.assign({}, pageInfo);
78666
78662
  Object.keys(pageInfo).forEach((fieldName) => {
78667
78663
  if (getSelectionNode$1(pageInfoSelections, fragments, fieldName) === undefined) {
@@ -78680,7 +78676,7 @@
78680
78676
  }
78681
78677
  else if (selection.kind === 'FragmentSpread') {
78682
78678
  const fragment = fragments[selection.name.value];
78683
- return getSelectionNode$1(fragment === null || fragment === void 0 ? void 0 : fragment.selectionSet.selections, fragments, fieldName);
78679
+ return getSelectionNode$1(fragment?.selectionSet.selections, fragments, fieldName);
78684
78680
  }
78685
78681
  else if (selection.kind === 'InlineFragment') {
78686
78682
  return getSelectionNode$1(selection.selectionSet.selections, fragments, fieldName);
@@ -86722,8 +86718,7 @@
86722
86718
  * @returns
86723
86719
  */
86724
86720
  function batchingGetRecordsAdapterFactory(luvio) {
86725
- var _a;
86726
- const getRecordsAdapter = ((_a = configurationForRestAdapters$2.getRecordsAdapterFactory()) !== null && _a !== void 0 ? _a : getRecordsAdapterFactory$1)(luvio);
86721
+ const getRecordsAdapter = (configurationForRestAdapters$2.getRecordsAdapterFactory() ?? getRecordsAdapterFactory$1)(luvio);
86727
86722
  const batchGetRecords = (config, requestContext) => {
86728
86723
  const seenRecords = new StoreKeySet();
86729
86724
  const chunks = chunkConfig(config);
@@ -86770,8 +86765,7 @@
86770
86765
 
86771
86766
  function getCanonicalIdFunction(luvio) {
86772
86767
  return (id) => {
86773
- var _a;
86774
- return ((_a = extractRecordIdFromStoreKey$1(luvio.storeGetCanonicalKey(RECORD_ID_PREFIX$1 + id))) !== null && _a !== void 0 ? _a : id);
86768
+ return (extractRecordIdFromStoreKey$1(luvio.storeGetCanonicalKey(RECORD_ID_PREFIX$1 + id)) ?? id);
86775
86769
  };
86776
86770
  }
86777
86771
 
@@ -87070,7 +87064,7 @@
87070
87064
  data: queryInstrumentation,
87071
87065
  });
87072
87066
  }
87073
- catch (_a) {
87067
+ catch {
87074
87068
  // ignore errors instrumenting limits
87075
87069
  }
87076
87070
  try {
@@ -87091,18 +87085,15 @@
87091
87085
  }
87092
87086
  catch (throwable) {
87093
87087
  const error = throwable;
87088
+ const message = error instanceof Error ? error.message : String(error);
87094
87089
  return {
87095
87090
  data: undefined,
87096
87091
  state: 'Error',
87097
87092
  error: {
87098
- status: 500,
87099
- statusText: 'SYNTHETIC_FIELD_INJECTION_ERROR',
87100
- body: {
87101
- message: error.message,
87093
+ errorType: 'adapterError',
87094
+ error: {
87095
+ message,
87102
87096
  },
87103
- errorType: 'fetchResponse',
87104
- headers: {},
87105
- ok: false,
87106
87097
  },
87107
87098
  };
87108
87099
  }
@@ -87143,19 +87134,16 @@
87143
87134
  }
87144
87135
  catch (throwable) {
87145
87136
  const error = throwable;
87137
+ const message = error instanceof Error ? error.message : String(error);
87146
87138
  return {
87147
87139
  ...nonEvaluatedSnapshot,
87148
87140
  data: undefined,
87149
87141
  state: 'Error',
87150
87142
  error: {
87151
- status: 500,
87152
- statusText: 'LOCAL_EVALUATION_ERROR',
87153
- body: {
87154
- message: error.message,
87143
+ errorType: 'adapterError',
87144
+ error: {
87145
+ message,
87155
87146
  },
87156
- errorType: 'fetchResponse',
87157
- headers: {},
87158
- ok: false,
87159
87147
  },
87160
87148
  };
87161
87149
  }
@@ -89293,8 +89281,7 @@
89293
89281
  };
89294
89282
  }
89295
89283
  getTable(segment) {
89296
- var _a;
89297
- return (_a = this.dataTableMap[segment]) !== null && _a !== void 0 ? _a : this.internalDataTable;
89284
+ return this.dataTableMap[segment] ?? this.internalDataTable;
89298
89285
  }
89299
89286
  idsToDeleteOperation(entryIds, segment) {
89300
89287
  const table = this.getTable(segment);
@@ -89933,10 +89920,9 @@
89933
89920
  const DEFAULT_CONCURRENCY = 6;
89934
89921
  class PrimingSession extends EventEmitter {
89935
89922
  constructor(config) {
89936
- var _a, _b;
89937
89923
  super();
89938
- this.batchSize = (_a = config.batchSize) !== null && _a !== void 0 ? _a : DEFAULT_BATCH_SIZE;
89939
- this.concurrency = (_b = config.concurrency) !== null && _b !== void 0 ? _b : DEFAULT_CONCURRENCY;
89924
+ this.batchSize = config.batchSize ?? DEFAULT_BATCH_SIZE;
89925
+ this.concurrency = config.concurrency ?? DEFAULT_CONCURRENCY;
89940
89926
  this.recordLoader = config.recordLoader;
89941
89927
  this.recordIngestor = config.recordIngestor;
89942
89928
  this.objectInfoLoader = config.objectInfoLoader;
@@ -90170,7 +90156,7 @@
90170
90156
  const ttlOverride = await luvio.storeGetTTLOverride(keyPrefix$3, RepresentationType$V);
90171
90157
  const metadata = {
90172
90158
  ingestionTimestamp,
90173
- expirationTimestamp: (ttlOverride !== null && ttlOverride !== void 0 ? ttlOverride : TTL$z) + ingestionTimestamp,
90159
+ expirationTimestamp: (ttlOverride ?? TTL$z) + ingestionTimestamp,
90174
90160
  namespace: keyPrefix$3,
90175
90161
  representationName: RepresentationType$V,
90176
90162
  metadataVersion: DURABLE_METADATA_VERSION,
@@ -91242,12 +91228,11 @@
91242
91228
  const request = createResourceRequest$1$1(resourceParams);
91243
91229
  return luvio.dispatchResourceRequest(request, options)
91244
91230
  .then((response) => {
91245
- var _a, _b;
91246
- const graphqlErrors = (_a = response === null || response === void 0 ? void 0 : response.body) === null || _a === void 0 ? void 0 : _a.errors;
91231
+ const graphqlErrors = response?.body?.errors;
91247
91232
  if ((graphqlErrors || []).length === 0) {
91248
91233
  return response;
91249
91234
  }
91250
- return Promise.reject({ errorType: 'adapterError', error: (_b = response === null || response === void 0 ? void 0 : response.body) === null || _b === void 0 ? void 0 : _b.errors });
91235
+ return Promise.reject({ errorType: 'adapterError', error: response?.body?.errors });
91251
91236
  })
91252
91237
  .then((response) => {
91253
91238
  return luvio.handleSuccessResponse(() => onFetchResponseSuccess$1$1(luvio, config, resourceParams, response), () => {
@@ -92517,7 +92502,7 @@
92517
92502
  id: '@salesforce/lds-network-adapter',
92518
92503
  instrument: instrument$2,
92519
92504
  });
92520
- // version: 1.321.0-1fd3fba1c4
92505
+ // version: 1.322.0-6aa042602a
92521
92506
 
92522
92507
  const { create: create$2, keys: keys$2 } = Object;
92523
92508
  const { stringify, parse } = JSON;
@@ -93103,7 +93088,7 @@
93103
93088
  if (edges === undefined) {
93104
93089
  return undefined;
93105
93090
  }
93106
- const listIsIncomplete = ((metadata === null || metadata === void 0 ? void 0 : metadata.__END__) === undefined);
93091
+ const listIsIncomplete = (metadata?.__END__ === undefined);
93107
93092
  const hasNextPage = listIsIncomplete || (endOffset !== undefined && maxOffset !== undefined && (endOffset - 1 < maxOffset));
93108
93093
  const hasPreviousPage = startOffset !== undefined && startOffset > 0;
93109
93094
  let startCursor = null;
@@ -93139,7 +93124,7 @@
93139
93124
  }
93140
93125
  // end is included in the above case.
93141
93126
  return Object.values(metadata)
93142
- .reduce((acc, value) => Math.max(value !== null && value !== void 0 ? value : -1, acc), -1);
93127
+ .reduce((acc, value) => Math.max(value ?? -1, acc), -1);
93143
93128
  }
93144
93129
  function getPageTokenAndOffset(paginationMetadata, token) {
93145
93130
  if (token === undefined) {
@@ -99549,14 +99534,13 @@
99549
99534
  };
99550
99535
  }
99551
99536
  function ingestPaginationMetadata$3(astNode, state, key, sink, existingData) {
99552
- var _a;
99553
99537
  const { data, luvio, store } = state;
99554
99538
  const { pageInfo: { hasNextPage, startCursor }, edges } = data;
99555
99539
  if (!hasGraphQLPaginationFields(data))
99556
99540
  return;
99557
99541
  const paginationKey = key + '__pagination';
99558
99542
  let existingPaginationMetadata = store.readEntry(paginationKey);
99559
- const afterArg = (_a = astNode.arguments) === null || _a === void 0 ? void 0 : _a.find(argument => { return argument.name.value === 'after'; });
99543
+ const afterArg = astNode.arguments?.find(argument => { return argument.name.value === 'after'; });
99560
99544
  const afterArgVal = evaluateArgumentValue(afterArg, 'StringValue', state.variables);
99561
99545
  const isPagedResponse = afterArgVal !== undefined &&
99562
99546
  existingPaginationMetadata !== undefined &&
@@ -104806,14 +104790,13 @@
104806
104790
  };
104807
104791
  }
104808
104792
  function ingestPaginationMetadata$2(astNode, state, key, sink, existingData) {
104809
- var _a;
104810
104793
  const { data, luvio, store } = state;
104811
104794
  const { pageInfo: { hasNextPage, startCursor }, edges } = data;
104812
104795
  if (!hasGraphQLPaginationFields(data))
104813
104796
  return;
104814
104797
  const paginationKey = key + '__pagination';
104815
104798
  let existingPaginationMetadata = store.readEntry(paginationKey);
104816
- const afterArg = (_a = astNode.arguments) === null || _a === void 0 ? void 0 : _a.find(argument => { return argument.name.value === 'after'; });
104799
+ const afterArg = astNode.arguments?.find(argument => { return argument.name.value === 'after'; });
104817
104800
  const afterArgVal = evaluateArgumentValue(afterArg, 'StringValue', state.variables);
104818
104801
  const isPagedResponse = afterArgVal !== undefined &&
104819
104802
  existingPaginationMetadata !== undefined &&
@@ -109715,14 +109698,13 @@
109715
109698
  };
109716
109699
  }
109717
109700
  function ingestPaginationMetadata$1(astNode, state, key, sink, existingData) {
109718
- var _a;
109719
109701
  const { data, luvio, store } = state;
109720
109702
  const { pageInfo: { hasNextPage, startCursor }, edges } = data;
109721
109703
  if (!hasGraphQLPaginationFields(data))
109722
109704
  return;
109723
109705
  const paginationKey = key + '__pagination';
109724
109706
  let existingPaginationMetadata = store.readEntry(paginationKey);
109725
- const afterArg = (_a = astNode.arguments) === null || _a === void 0 ? void 0 : _a.find(argument => { return argument.name.value === 'after'; });
109707
+ const afterArg = astNode.arguments?.find(argument => { return argument.name.value === 'after'; });
109726
109708
  const afterArgVal = evaluateArgumentValue(afterArg, 'StringValue', state.variables);
109727
109709
  const isPagedResponse = afterArgVal !== undefined &&
109728
109710
  existingPaginationMetadata !== undefined &&
@@ -111065,14 +111047,13 @@
111065
111047
  };
111066
111048
  }
111067
111049
  function ingestPaginationMetadata(astNode, state, key, sink, existingData) {
111068
- var _a;
111069
111050
  const { data, luvio, store } = state;
111070
111051
  const { pageInfo: { hasNextPage, startCursor }, edges } = data;
111071
111052
  if (!hasGraphQLPaginationFields(data))
111072
111053
  return;
111073
111054
  const paginationKey = key + '__pagination';
111074
111055
  let existingPaginationMetadata = store.readEntry(paginationKey);
111075
- const afterArg = (_a = astNode.arguments) === null || _a === void 0 ? void 0 : _a.find(argument => { return argument.name.value === 'after'; });
111056
+ const afterArg = astNode.arguments?.find(argument => { return argument.name.value === 'after'; });
111076
111057
  const afterArgVal = evaluateArgumentValue(afterArg, 'StringValue', state.variables);
111077
111058
  const isPagedResponse = afterArgVal !== undefined &&
111078
111059
  existingPaginationMetadata !== undefined &&
@@ -111313,6 +111294,23 @@
111313
111294
  return sharedGetFragmentType(fragment, fragmentMap);
111314
111295
  }
111315
111296
 
111297
+ function getFieldType$b(field) {
111298
+ switch (field.name.value) {
111299
+ case '__typename': {
111300
+ return {
111301
+ isArray: false,
111302
+ typename: 'String',
111303
+ };
111304
+ }
111305
+ default: {
111306
+ return {
111307
+ isArray: false,
111308
+ typename: 'Setup__SetupAggregateConnection',
111309
+ };
111310
+ }
111311
+ }
111312
+ }
111313
+
111316
111314
  const name$2 = 'Setup__SetupQueryAggregate';
111317
111315
  const VERSION$a = '0592284764c8e58016880e291b9ffb64';
111318
111316
  function keyBuilder$6(luvio, path, data) {
@@ -111430,24 +111428,6 @@
111430
111428
  }
111431
111429
  // Deal with mapped types' cache keys
111432
111430
  }
111433
- function getFieldType$b(field) {
111434
- switch (field.name.value) {
111435
- case '__typename': {
111436
- return {
111437
- isArray: false,
111438
- typename: 'String'
111439
- };
111440
- }
111441
- case 'recordQueryAggregate': {
111442
- return {
111443
- isArray: false,
111444
- typename: 'Setup__SetupAggregateConnection'
111445
- };
111446
- }
111447
- default:
111448
- return undefined;
111449
- }
111450
- }
111451
111431
  function ingestFieldByType$2(typename, parentKey, requestedField, sink, fieldKey, fieldData, state) {
111452
111432
  // TODO: add validation logic to only allow nullable fields to be null in the future
111453
111433
  if (fieldData === null) {
@@ -112485,8 +112465,7 @@
112485
112465
  }
112486
112466
 
112487
112467
  function applyToSelection$3(selection, directive, variables) {
112488
- var _a;
112489
- const ifArg = (_a = directive.arguments) === null || _a === void 0 ? void 0 : _a.find(argument => argument.name.value === "if");
112468
+ const ifArg = directive.arguments?.find(argument => argument.name.value === "if");
112490
112469
  if (ifArg && ifArg.value) {
112491
112470
  if (ifArg.value.kind === "BooleanValue") {
112492
112471
  return ifArg.value.value ? selection : undefined;
@@ -112499,8 +112478,7 @@
112499
112478
  }
112500
112479
 
112501
112480
  function applyToSelection$2(selection, directive, variables) {
112502
- var _a;
112503
- const ifArg = (_a = directive.arguments) === null || _a === void 0 ? void 0 : _a.find(argument => argument.name.value === "if");
112481
+ const ifArg = directive.arguments?.find(argument => argument.name.value === "if");
112504
112482
  if (ifArg && ifArg.value) {
112505
112483
  if (ifArg.value.kind === "BooleanValue") {
112506
112484
  return ifArg.value.value ? undefined : selection;
@@ -112674,7 +112652,7 @@
112674
112652
  selections: queryTransformHelper.getMinimumSelections()
112675
112653
  };
112676
112654
  const mergedSelections = mergeSelectionSets(selectionSetNode, minimumSelectionSet);
112677
- mergedSelections === null || mergedSelections === void 0 ? void 0 : mergedSelections.selections.forEach(selection => {
112655
+ mergedSelections?.selections.forEach(selection => {
112678
112656
  if (selection.kind === 'Field') {
112679
112657
  const fieldType = queryTransformHelper.getFieldType(selection);
112680
112658
  const fieldTransformHelper = fieldType === undefined ? undefined : getQueryTransformerForType(fieldType.typename);
@@ -113311,13 +113289,12 @@
113311
113289
  }
113312
113290
  // Shared export for getting the offset of the current page in the edges array
113313
113291
  function getArrayOffsetForPage(state, node, key) {
113314
- var _a;
113315
113292
  const { variables, data, store } = state;
113316
113293
  // if we have pagination metadata, see if we can locate either the start or
113317
113294
  // after cursor in it to determine the correct index to use for the fullPath
113318
113295
  const paginationKey = key + '__pagination';
113319
113296
  let existingPaginationMetadata = store.readEntry(paginationKey);
113320
- const afterArg = (_a = node.arguments) === null || _a === void 0 ? void 0 : _a.find(argument => { return argument.name.value === 'after'; });
113297
+ const afterArg = node.arguments?.find(argument => { return argument.name.value === 'after'; });
113321
113298
  const afterArgVal = evaluateArgumentValue(afterArg, 'StringValue', variables);
113322
113299
  if (existingPaginationMetadata !== undefined) {
113323
113300
  // if the starting cursor for current page exists in the existing metadata use that as offset
@@ -113447,8 +113424,7 @@
113447
113424
  });
113448
113425
  }
113449
113426
  function selectCalculateSink(sink, field, buildSelectionForNodeFn, source, reader, variables, fragments, parentRecordId) {
113450
- var _a;
113451
- (_a = field.selectionSet) === null || _a === void 0 ? void 0 : _a.selections.forEach((sel) => {
113427
+ field.selectionSet?.selections.forEach((sel) => {
113452
113428
  const builtSelection = buildSelectionForNodeFn(source, reader, field, sel, variables, fragments, parentRecordId);
113453
113429
  if (builtSelection !== undefined) {
113454
113430
  deepMerge(sink, builtSelection);
@@ -113457,7 +113433,6 @@
113457
113433
  return sink;
113458
113434
  }
113459
113435
  function selectTypeLinkWithPagination(resolvedLink, sel, fieldData, reader, key, sink, variables, fragments, selectFn) {
113460
- var _a, _b, _c, _d, _e;
113461
113436
  const source = resolvedLink.data.data;
113462
113437
  const parentRecordId = resolvedLink.recordId;
113463
113438
  const totalEdges = source.edges !== undefined ? source.edges.length : 0;
@@ -113467,10 +113442,10 @@
113467
113442
  reader.markMissing();
113468
113443
  return;
113469
113444
  }
113470
- const firstArg = (_a = sel.arguments) === null || _a === void 0 ? void 0 : _a.find(argument => { return argument.name.value === 'first'; });
113445
+ const firstArg = sel.arguments?.find(argument => { return argument.name.value === 'first'; });
113471
113446
  const firstArgVal = evaluateArgumentValue(firstArg, 'IntValue', variables);
113472
113447
  const pageSize = firstArgVal !== undefined ? firstArgVal : totalEdges;
113473
- const afterArg = (_b = sel.arguments) === null || _b === void 0 ? void 0 : _b.find(argument => { return argument.name.value === 'after'; });
113448
+ const afterArg = sel.arguments?.find(argument => { return argument.name.value === 'after'; });
113474
113449
  const afterArgVal = evaluateArgumentValue(afterArg, 'StringValue', variables);
113475
113450
  const paginationParams = {
113476
113451
  pageSize: parseInt(pageSize, 10),
@@ -113521,7 +113496,7 @@
113521
113496
  reader.markMissingLink(fieldData.__ref);
113522
113497
  reader.markMissing();
113523
113498
  // optimize pagination when "first" and "after" args are part of the variable
113524
- if (((_c = firstArg === null || firstArg === void 0 ? void 0 : firstArg.value) === null || _c === void 0 ? void 0 : _c.kind) === 'Variable' && ((_d = afterArg === null || afterArg === void 0 ? void 0 : afterArg.value) === null || _d === void 0 ? void 0 : _d.kind) === 'Variable') {
113499
+ if (firstArg?.value?.kind === 'Variable' && afterArg?.value?.kind === 'Variable') {
113525
113500
  optimizePagination(metadata, firstArg.value.name.value, afterArg.value.name.value, variables);
113526
113501
  }
113527
113502
  return;
@@ -113537,9 +113512,9 @@
113537
113512
  };
113538
113513
  reader.markSeenId(parentRecordId);
113539
113514
  const result = selectFn(sel, variables, fragments)(paginatedData, reader, parentRecordId);
113540
- const pageInfo = createPageInfo(result === null || result === void 0 ? void 0 : result.edges, startOffset, endOffset, maxOffset, metadata);
113515
+ const pageInfo = createPageInfo(result?.edges, startOffset, endOffset, maxOffset, metadata);
113541
113516
  if (pageInfo !== undefined) {
113542
- const selectedPageInfo = selectPageInfo((_e = sel.selectionSet) === null || _e === void 0 ? void 0 : _e.selections, fragments, pageInfo);
113517
+ const selectedPageInfo = selectPageInfo(sel.selectionSet?.selections, fragments, pageInfo);
113543
113518
  if (selectedPageInfo !== undefined) {
113544
113519
  reader.assignNonScalar(result, 'pageInfo', selectedPageInfo);
113545
113520
  }
@@ -113547,11 +113522,10 @@
113547
113522
  reader.assignNonScalar(sink, key, result);
113548
113523
  }
113549
113524
  function selectPageInfo(selections, fragments, pageInfo) {
113550
- var _a;
113551
113525
  const pageInfoSelection = getSelectionNode(selections, fragments, 'pageInfo');
113552
113526
  if (pageInfo === undefined || pageInfoSelection === undefined || pageInfoSelection.kind !== 'Field')
113553
113527
  return undefined;
113554
- const pageInfoSelections = (_a = pageInfoSelection.selectionSet) === null || _a === void 0 ? void 0 : _a.selections;
113528
+ const pageInfoSelections = pageInfoSelection.selectionSet?.selections;
113555
113529
  const selectedPageInfo = Object.assign({}, pageInfo);
113556
113530
  Object.keys(pageInfo).forEach((fieldName) => {
113557
113531
  if (getSelectionNode(pageInfoSelections, fragments, fieldName) === undefined) {
@@ -113570,7 +113544,7 @@
113570
113544
  }
113571
113545
  else if (selection.kind === 'FragmentSpread') {
113572
113546
  const fragment = fragments[selection.name.value];
113573
- return getSelectionNode(fragment === null || fragment === void 0 ? void 0 : fragment.selectionSet.selections, fragments, fieldName);
113547
+ return getSelectionNode(fragment?.selectionSet.selections, fragments, fieldName);
113574
113548
  }
113575
113549
  else if (selection.kind === 'InlineFragment') {
113576
113550
  return getSelectionNode(selection.selectionSet.selections, fragments, fieldName);
@@ -113859,12 +113833,11 @@
113859
113833
  const request = createResourceRequest$1(resourceParams);
113860
113834
  return luvio.dispatchResourceRequest(request, options)
113861
113835
  .then((response) => {
113862
- var _a, _b;
113863
- const graphqlErrors = (_a = response === null || response === void 0 ? void 0 : response.body) === null || _a === void 0 ? void 0 : _a.errors;
113836
+ const graphqlErrors = response?.body?.errors;
113864
113837
  if ((graphqlErrors || []).length === 0) {
113865
113838
  return response;
113866
113839
  }
113867
- return Promise.reject({ errorType: 'adapterError', error: (_b = response === null || response === void 0 ? void 0 : response.body) === null || _b === void 0 ? void 0 : _b.errors });
113840
+ return Promise.reject({ errorType: 'adapterError', error: response?.body?.errors });
113868
113841
  })
113869
113842
  .then((response) => {
113870
113843
  return luvio.handleSuccessResponse(() => onFetchResponseSuccess$1(luvio, config, resourceParams, response), () => {
@@ -115096,7 +115069,7 @@
115096
115069
  configuration: { ...configurationForGraphQLAdapters$1 },
115097
115070
  instrument: instrument$1,
115098
115071
  });
115099
- // version: 1.321.0-40847d67a8
115072
+ // version: 1.322.0-87f682c9f3
115100
115073
 
115101
115074
  // On core the unstable adapters are re-exported with different names,
115102
115075
  // we want to match them here.
@@ -115248,7 +115221,7 @@
115248
115221
  unstable_graphQL_imperative = createImperativeAdapter(luvio, createInstrumentedAdapter(ldsAdapter, adapterMetadata), adapterMetadata);
115249
115222
  graphQLImperative = ldsAdapter;
115250
115223
  });
115251
- // version: 1.321.0-40847d67a8
115224
+ // version: 1.322.0-87f682c9f3
115252
115225
 
115253
115226
  var gqlApi = /*#__PURE__*/Object.freeze({
115254
115227
  __proto__: null,
@@ -116004,7 +115977,7 @@
116004
115977
  function register(r) {
116005
115978
  callbacks$1.forEach((callback) => callback(r));
116006
115979
  }
116007
- // version: 1.321.0-1fd3fba1c4
115980
+ // version: 1.322.0-6aa042602a
116008
115981
 
116009
115982
  /**
116010
115983
  * Copyright (c) 2022, Salesforce, Inc.,
@@ -117086,4 +117059,4 @@
117086
117059
  exports.subscribeToAdapter = subscribeToAdapter;
117087
117060
 
117088
117061
  }));
117089
- // version: 1.321.0-1fd3fba1c4
117062
+ // version: 1.322.0-6aa042602a