@salesforce/lds-ads-bridge 1.244.0 → 1.246.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.
- package/dist/ads-bridge-perf.js +147 -147
- package/dist/adsBridge.js +1 -1
- package/package.json +1 -1
package/dist/ads-bridge-perf.js
CHANGED
|
@@ -427,7 +427,7 @@ function createResourceParamsImpl(config, configMetadata) {
|
|
|
427
427
|
}
|
|
428
428
|
return resourceParams;
|
|
429
429
|
}
|
|
430
|
-
// engine version: 0.150.
|
|
430
|
+
// engine version: 0.150.6-26328503
|
|
431
431
|
|
|
432
432
|
/**
|
|
433
433
|
* Copyright (c) 2022, Salesforce, Inc.,
|
|
@@ -475,7 +475,7 @@ const callbacks$1 = [];
|
|
|
475
475
|
function register(r) {
|
|
476
476
|
callbacks$1.forEach((callback) => callback(r));
|
|
477
477
|
}
|
|
478
|
-
// version: 1.
|
|
478
|
+
// version: 1.246.0-8357100fc
|
|
479
479
|
|
|
480
480
|
/**
|
|
481
481
|
* Returns true if the value acts like a Promise, i.e. has a "then" function,
|
|
@@ -4676,7 +4676,7 @@ function buildAdapterValidationConfig(displayName, paramsMeta) {
|
|
|
4676
4676
|
}
|
|
4677
4677
|
const keyPrefix = 'UiApi';
|
|
4678
4678
|
|
|
4679
|
-
const { assign, create, freeze, keys: keys$1 } = Object;
|
|
4679
|
+
const { assign, create, freeze, isFrozen, keys: keys$1 } = Object;
|
|
4680
4680
|
const { hasOwnProperty: hasOwnProperty$1 } = Object.prototype;
|
|
4681
4681
|
const { split, endsWith } = String.prototype;
|
|
4682
4682
|
const { isArray } = Array;
|
|
@@ -4916,8 +4916,8 @@ function toSortedStringArray(value) {
|
|
|
4916
4916
|
return undefined;
|
|
4917
4917
|
}
|
|
4918
4918
|
|
|
4919
|
-
const VERSION$
|
|
4920
|
-
function validate$
|
|
4919
|
+
const VERSION$2p = "d1e589a127fb1060c89070cdb6f500b2";
|
|
4920
|
+
function validate$1L(obj, path = 'RecordTypeInfoRepresentation') {
|
|
4921
4921
|
const v_error = (() => {
|
|
4922
4922
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
4923
4923
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -4950,10 +4950,10 @@ function validate$1H(obj, path = 'RecordTypeInfoRepresentation') {
|
|
|
4950
4950
|
})();
|
|
4951
4951
|
return v_error === undefined ? null : v_error;
|
|
4952
4952
|
}
|
|
4953
|
-
const select$
|
|
4953
|
+
const select$2$ = function RecordTypeInfoRepresentationSelect() {
|
|
4954
4954
|
return {
|
|
4955
4955
|
kind: 'Fragment',
|
|
4956
|
-
version: VERSION$
|
|
4956
|
+
version: VERSION$2p,
|
|
4957
4957
|
private: [],
|
|
4958
4958
|
selections: [
|
|
4959
4959
|
{
|
|
@@ -4979,7 +4979,7 @@ const select$2W = function RecordTypeInfoRepresentationSelect() {
|
|
|
4979
4979
|
]
|
|
4980
4980
|
};
|
|
4981
4981
|
};
|
|
4982
|
-
function equals$
|
|
4982
|
+
function equals$16(existing, incoming) {
|
|
4983
4983
|
const existing_available = existing.available;
|
|
4984
4984
|
const incoming_available = incoming.available;
|
|
4985
4985
|
if (!(existing_available === incoming_available)) {
|
|
@@ -5008,8 +5008,8 @@ function equals$13(existing, incoming) {
|
|
|
5008
5008
|
return true;
|
|
5009
5009
|
}
|
|
5010
5010
|
|
|
5011
|
-
const VERSION$
|
|
5012
|
-
function validate$
|
|
5011
|
+
const VERSION$2o = "195d918987a35f45e1aa4dce9a11d8c5";
|
|
5012
|
+
function validate$1K(obj, path = 'FieldValueRepresentation') {
|
|
5013
5013
|
const v_error = (() => {
|
|
5014
5014
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
5015
5015
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -5099,11 +5099,11 @@ function validate$1G(obj, path = 'FieldValueRepresentation') {
|
|
|
5099
5099
|
})();
|
|
5100
5100
|
return v_error === undefined ? null : v_error;
|
|
5101
5101
|
}
|
|
5102
|
-
const RepresentationType$
|
|
5103
|
-
const select$
|
|
5102
|
+
const RepresentationType$Y = 'FieldValueRepresentation';
|
|
5103
|
+
const select$2_ = function FieldValueRepresentationSelect() {
|
|
5104
5104
|
return {
|
|
5105
5105
|
kind: 'Fragment',
|
|
5106
|
-
version: VERSION$
|
|
5106
|
+
version: VERSION$2o,
|
|
5107
5107
|
private: [],
|
|
5108
5108
|
selections: [
|
|
5109
5109
|
{
|
|
@@ -5114,12 +5114,12 @@ const select$2V = function FieldValueRepresentationSelect() {
|
|
|
5114
5114
|
name: 'value',
|
|
5115
5115
|
kind: 'Link',
|
|
5116
5116
|
nullable: true,
|
|
5117
|
-
fragment: select$
|
|
5117
|
+
fragment: select$2Y()
|
|
5118
5118
|
}
|
|
5119
5119
|
]
|
|
5120
5120
|
};
|
|
5121
5121
|
};
|
|
5122
|
-
function equals$
|
|
5122
|
+
function equals$15(existing, incoming) {
|
|
5123
5123
|
const existing_displayValue = existing.displayValue;
|
|
5124
5124
|
const incoming_displayValue = incoming.displayValue;
|
|
5125
5125
|
if (!(existing_displayValue === incoming_displayValue)) {
|
|
@@ -5137,26 +5137,26 @@ function equals$12(existing, incoming) {
|
|
|
5137
5137
|
}
|
|
5138
5138
|
return true;
|
|
5139
5139
|
}
|
|
5140
|
-
function getTypeCacheKeys$
|
|
5140
|
+
function getTypeCacheKeys$1Z(rootKeySet, luvio, input, fullPathFactory) {
|
|
5141
5141
|
// root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
|
|
5142
5142
|
const rootKey = fullPathFactory();
|
|
5143
5143
|
rootKeySet.set(rootKey, {
|
|
5144
5144
|
namespace: keyPrefix,
|
|
5145
|
-
representationName: RepresentationType$
|
|
5145
|
+
representationName: RepresentationType$Y,
|
|
5146
5146
|
mergeable: false
|
|
5147
5147
|
});
|
|
5148
5148
|
if (input.value !== null && typeof input.value === 'object') {
|
|
5149
|
-
getTypeCacheKeys$
|
|
5149
|
+
getTypeCacheKeys$1Y(rootKeySet, luvio, input.value);
|
|
5150
5150
|
}
|
|
5151
5151
|
}
|
|
5152
5152
|
|
|
5153
5153
|
// we override the generated so we can set "mergeable: true" on the root key
|
|
5154
|
-
const getTypeCacheKeys$
|
|
5154
|
+
const getTypeCacheKeys$1Y = (rootKeySet, luvio, input, _fullPathFactory) => {
|
|
5155
5155
|
// root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
|
|
5156
|
-
const rootKey = keyBuilderFromType$
|
|
5156
|
+
const rootKey = keyBuilderFromType$A(luvio, input);
|
|
5157
5157
|
rootKeySet.set(rootKey, {
|
|
5158
5158
|
namespace: keyPrefix,
|
|
5159
|
-
representationName: RepresentationType$
|
|
5159
|
+
representationName: RepresentationType$W,
|
|
5160
5160
|
mergeable: true,
|
|
5161
5161
|
});
|
|
5162
5162
|
const input_childRelationships = input.childRelationships;
|
|
@@ -5164,21 +5164,21 @@ const getTypeCacheKeys$1V = (rootKeySet, luvio, input, _fullPathFactory) => {
|
|
|
5164
5164
|
const input_childRelationships_length = input_childRelationships_keys.length;
|
|
5165
5165
|
for (let i = 0; i < input_childRelationships_length; i++) {
|
|
5166
5166
|
const key = input_childRelationships_keys[i];
|
|
5167
|
-
getTypeCacheKeys$
|
|
5167
|
+
getTypeCacheKeys$1X(rootKeySet, luvio, input_childRelationships[key], () => rootKey + '__childRelationships' + '__' + key);
|
|
5168
5168
|
}
|
|
5169
5169
|
const input_fields = input.fields;
|
|
5170
5170
|
const input_fields_keys = keys$1(input_fields);
|
|
5171
5171
|
const input_fields_length = input_fields_keys.length;
|
|
5172
5172
|
for (let i = 0; i < input_fields_length; i++) {
|
|
5173
5173
|
const key = input_fields_keys[i];
|
|
5174
|
-
getTypeCacheKeys$
|
|
5174
|
+
getTypeCacheKeys$1Z(rootKeySet, luvio, input_fields[key], () => rootKey + '__fields__' + key);
|
|
5175
5175
|
}
|
|
5176
5176
|
return rootKeySet;
|
|
5177
5177
|
};
|
|
5178
5178
|
|
|
5179
|
-
const TTL$
|
|
5180
|
-
const VERSION$
|
|
5181
|
-
function validate$
|
|
5179
|
+
const TTL$D = 120000;
|
|
5180
|
+
const VERSION$2n = "79cb5ac9f44542f683d00245fdfe500d";
|
|
5181
|
+
function validate$1J(obj, path = 'RecordCollectionRepresentation') {
|
|
5182
5182
|
const v_error = (() => {
|
|
5183
5183
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
5184
5184
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -5338,14 +5338,14 @@ function validate$1F(obj, path = 'RecordCollectionRepresentation') {
|
|
|
5338
5338
|
})();
|
|
5339
5339
|
return v_error === undefined ? null : v_error;
|
|
5340
5340
|
}
|
|
5341
|
-
const RepresentationType$
|
|
5342
|
-
function normalize$
|
|
5341
|
+
const RepresentationType$X = 'RecordCollectionRepresentation';
|
|
5342
|
+
function normalize$Q(input, existing, path, luvio, store, timestamp) {
|
|
5343
5343
|
const input_records = input.records;
|
|
5344
5344
|
const input_records_id = path.fullPath + '__records';
|
|
5345
5345
|
for (let i = 0; i < input_records.length; i++) {
|
|
5346
5346
|
const input_records_item = input_records[i];
|
|
5347
5347
|
let input_records_item_id = input_records_id + '__' + i;
|
|
5348
|
-
input_records[i] = ingest$
|
|
5348
|
+
input_records[i] = ingest$1U(input_records_item, {
|
|
5349
5349
|
fullPath: input_records_item_id,
|
|
5350
5350
|
propertyName: i,
|
|
5351
5351
|
parent: {
|
|
@@ -5358,10 +5358,10 @@ function normalize$N(input, existing, path, luvio, store, timestamp) {
|
|
|
5358
5358
|
}
|
|
5359
5359
|
return input;
|
|
5360
5360
|
}
|
|
5361
|
-
const select$
|
|
5361
|
+
const select$2Z = function RecordCollectionRepresentationSelect() {
|
|
5362
5362
|
return {
|
|
5363
5363
|
kind: 'Fragment',
|
|
5364
|
-
version: VERSION$
|
|
5364
|
+
version: VERSION$2n,
|
|
5365
5365
|
private: [],
|
|
5366
5366
|
selections: [
|
|
5367
5367
|
{
|
|
@@ -5396,12 +5396,12 @@ const select$2U = function RecordCollectionRepresentationSelect() {
|
|
|
5396
5396
|
name: 'records',
|
|
5397
5397
|
kind: 'Link',
|
|
5398
5398
|
plural: true,
|
|
5399
|
-
fragment: select$
|
|
5399
|
+
fragment: select$2Y()
|
|
5400
5400
|
}
|
|
5401
5401
|
]
|
|
5402
5402
|
};
|
|
5403
5403
|
};
|
|
5404
|
-
function equals$
|
|
5404
|
+
function equals$14(existing, incoming) {
|
|
5405
5405
|
const existing_count = existing.count;
|
|
5406
5406
|
const incoming_count = incoming.count;
|
|
5407
5407
|
if (!(existing_count === incoming_count)) {
|
|
@@ -5449,45 +5449,45 @@ function equals$11(existing, incoming) {
|
|
|
5449
5449
|
}
|
|
5450
5450
|
return true;
|
|
5451
5451
|
}
|
|
5452
|
-
const ingest$
|
|
5452
|
+
const ingest$1V = function RecordCollectionRepresentationIngest(input, path, luvio, store, timestamp) {
|
|
5453
5453
|
if (process.env.NODE_ENV !== 'production') {
|
|
5454
|
-
const validateError = validate$
|
|
5454
|
+
const validateError = validate$1J(input);
|
|
5455
5455
|
if (validateError !== null) {
|
|
5456
5456
|
throw validateError;
|
|
5457
5457
|
}
|
|
5458
5458
|
}
|
|
5459
5459
|
const key = path.fullPath;
|
|
5460
|
-
const ttlToUse = TTL$
|
|
5461
|
-
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$
|
|
5460
|
+
const ttlToUse = TTL$D;
|
|
5461
|
+
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$Q, "UiApi", VERSION$2n, RepresentationType$X, equals$14);
|
|
5462
5462
|
return createLink$1(key);
|
|
5463
5463
|
};
|
|
5464
|
-
function getTypeCacheKeys$
|
|
5464
|
+
function getTypeCacheKeys$1X(rootKeySet, luvio, input, fullPathFactory) {
|
|
5465
5465
|
// root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
|
|
5466
5466
|
const rootKey = fullPathFactory();
|
|
5467
5467
|
rootKeySet.set(rootKey, {
|
|
5468
5468
|
namespace: keyPrefix,
|
|
5469
|
-
representationName: RepresentationType$
|
|
5469
|
+
representationName: RepresentationType$X,
|
|
5470
5470
|
mergeable: false
|
|
5471
5471
|
});
|
|
5472
5472
|
const input_records_length = input.records.length;
|
|
5473
5473
|
for (let i = 0; i < input_records_length; i++) {
|
|
5474
|
-
getTypeCacheKeys$
|
|
5474
|
+
getTypeCacheKeys$1Y(rootKeySet, luvio, input.records[i]);
|
|
5475
5475
|
}
|
|
5476
5476
|
}
|
|
5477
5477
|
|
|
5478
5478
|
const VIEW_ENTITY_API_NAME = 'Name';
|
|
5479
5479
|
const VIEW_ENTITY_KEY_PREFIX = `${keyPrefix}::RecordViewEntityRepresentation:${VIEW_ENTITY_API_NAME}:`;
|
|
5480
|
-
const keyBuilderFromType$
|
|
5480
|
+
const keyBuilderFromType$B = function RecordRepresentationKeyBuilderFromType(luvio, object) {
|
|
5481
5481
|
const { apiName, id } = object;
|
|
5482
5482
|
if (apiName === VIEW_ENTITY_API_NAME) {
|
|
5483
5483
|
return VIEW_ENTITY_KEY_PREFIX + id;
|
|
5484
5484
|
}
|
|
5485
|
-
return keyBuilderFromType$
|
|
5485
|
+
return keyBuilderFromType$A(luvio, object);
|
|
5486
5486
|
};
|
|
5487
5487
|
|
|
5488
|
-
const TTL$
|
|
5489
|
-
const VERSION$
|
|
5490
|
-
function validate$
|
|
5488
|
+
const TTL$C = 30000;
|
|
5489
|
+
const VERSION$2m = "98c5b18512e48ca8d28727549507e4ba";
|
|
5490
|
+
function validate$1I(obj, path = 'RecordRepresentation') {
|
|
5491
5491
|
const v_error = (() => {
|
|
5492
5492
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
5493
5493
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -5617,7 +5617,7 @@ function validate$1E(obj, path = 'RecordRepresentation') {
|
|
|
5617
5617
|
const path_recordTypeInfo = path + '.recordTypeInfo';
|
|
5618
5618
|
let obj_recordTypeInfo_union0 = null;
|
|
5619
5619
|
const obj_recordTypeInfo_union0_error = (() => {
|
|
5620
|
-
const referencepath_recordTypeInfoValidationError = validate$
|
|
5620
|
+
const referencepath_recordTypeInfoValidationError = validate$1L(obj_recordTypeInfo, path_recordTypeInfo);
|
|
5621
5621
|
if (referencepath_recordTypeInfoValidationError !== null) {
|
|
5622
5622
|
let message = 'Object doesn\'t match RecordTypeInfoRepresentation (at "' + path_recordTypeInfo + '")\n';
|
|
5623
5623
|
message += referencepath_recordTypeInfoValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -5676,15 +5676,15 @@ function validate$1E(obj, path = 'RecordRepresentation') {
|
|
|
5676
5676
|
})();
|
|
5677
5677
|
return v_error === undefined ? null : v_error;
|
|
5678
5678
|
}
|
|
5679
|
-
const RepresentationType$
|
|
5680
|
-
function keyBuilder$
|
|
5681
|
-
return keyPrefix + '::' + RepresentationType$
|
|
5679
|
+
const RepresentationType$W = 'RecordRepresentation';
|
|
5680
|
+
function keyBuilder$3b(luvio, config) {
|
|
5681
|
+
return keyPrefix + '::' + RepresentationType$W + ':' + config.recordId;
|
|
5682
5682
|
}
|
|
5683
|
-
function keyBuilderFromType$
|
|
5683
|
+
function keyBuilderFromType$A(luvio, object) {
|
|
5684
5684
|
const keyParams = {
|
|
5685
5685
|
recordId: object.id
|
|
5686
5686
|
};
|
|
5687
|
-
return keyBuilder$
|
|
5687
|
+
return keyBuilder$3b(luvio, keyParams);
|
|
5688
5688
|
}
|
|
5689
5689
|
function dynamicNormalize$5(ingestParams) {
|
|
5690
5690
|
return function normalize_dynamic(input, existing, path, luvio, store, timestamp) {
|
|
@@ -5729,11 +5729,11 @@ function dynamicNormalize$5(ingestParams) {
|
|
|
5729
5729
|
return input;
|
|
5730
5730
|
};
|
|
5731
5731
|
}
|
|
5732
|
-
const select$
|
|
5733
|
-
const { selections: RecordTypeInfoRepresentation__selections, opaque: RecordTypeInfoRepresentation__opaque, } = select$
|
|
5732
|
+
const select$2Y = function RecordRepresentationSelect() {
|
|
5733
|
+
const { selections: RecordTypeInfoRepresentation__selections, opaque: RecordTypeInfoRepresentation__opaque, } = select$2$();
|
|
5734
5734
|
return {
|
|
5735
5735
|
kind: 'Fragment',
|
|
5736
|
-
version: VERSION$
|
|
5736
|
+
version: VERSION$2m,
|
|
5737
5737
|
private: [
|
|
5738
5738
|
'eTag',
|
|
5739
5739
|
'weakEtag'
|
|
@@ -5747,13 +5747,13 @@ const select$2T = function RecordRepresentationSelect() {
|
|
|
5747
5747
|
name: 'childRelationships',
|
|
5748
5748
|
kind: 'Link',
|
|
5749
5749
|
map: true,
|
|
5750
|
-
fragment: select$
|
|
5750
|
+
fragment: select$2Z()
|
|
5751
5751
|
},
|
|
5752
5752
|
{
|
|
5753
5753
|
name: 'fields',
|
|
5754
5754
|
kind: 'Link',
|
|
5755
5755
|
map: true,
|
|
5756
|
-
fragment: select$
|
|
5756
|
+
fragment: select$2_()
|
|
5757
5757
|
},
|
|
5758
5758
|
{
|
|
5759
5759
|
name: 'id',
|
|
@@ -5789,18 +5789,18 @@ const dynamicSelect$8 = function dynamicRecordRepresentationSelect(params) {
|
|
|
5789
5789
|
name: 'childRelationships',
|
|
5790
5790
|
kind: 'Link',
|
|
5791
5791
|
map: true,
|
|
5792
|
-
fragment: select$
|
|
5792
|
+
fragment: select$2Z()
|
|
5793
5793
|
} : params.childRelationships;
|
|
5794
5794
|
const fieldsPathSelection = params.fields === undefined ? {
|
|
5795
5795
|
name: 'fields',
|
|
5796
5796
|
kind: 'Link',
|
|
5797
5797
|
map: true,
|
|
5798
|
-
fragment: select$
|
|
5798
|
+
fragment: select$2_()
|
|
5799
5799
|
} : params.fields;
|
|
5800
|
-
const { selections: RecordTypeInfoRepresentation__selections, opaque: RecordTypeInfoRepresentation__opaque, } = select$
|
|
5800
|
+
const { selections: RecordTypeInfoRepresentation__selections, opaque: RecordTypeInfoRepresentation__opaque, } = select$2$();
|
|
5801
5801
|
return {
|
|
5802
5802
|
kind: 'Fragment',
|
|
5803
|
-
version: VERSION$
|
|
5803
|
+
version: VERSION$2m,
|
|
5804
5804
|
private: [
|
|
5805
5805
|
'eTag',
|
|
5806
5806
|
'weakEtag'
|
|
@@ -5841,7 +5841,7 @@ const dynamicSelect$8 = function dynamicRecordRepresentationSelect(params) {
|
|
|
5841
5841
|
]
|
|
5842
5842
|
};
|
|
5843
5843
|
};
|
|
5844
|
-
function equals$
|
|
5844
|
+
function equals$13(existing, incoming) {
|
|
5845
5845
|
const existing_weakEtag = existing.weakEtag;
|
|
5846
5846
|
const incoming_weakEtag = incoming.weakEtag;
|
|
5847
5847
|
if (!(existing_weakEtag === incoming_weakEtag)) {
|
|
@@ -5902,7 +5902,7 @@ function equals$10(existing, incoming) {
|
|
|
5902
5902
|
if (!(existing_recordTypeInfo === incoming_recordTypeInfo
|
|
5903
5903
|
|| (existing_recordTypeInfo != null &&
|
|
5904
5904
|
incoming_recordTypeInfo != null &&
|
|
5905
|
-
equals$
|
|
5905
|
+
equals$16(existing_recordTypeInfo, incoming_recordTypeInfo)))) {
|
|
5906
5906
|
return false;
|
|
5907
5907
|
}
|
|
5908
5908
|
const existing_systemModstamp = existing.systemModstamp;
|
|
@@ -7279,7 +7279,7 @@ function createPathSelection(propertyName, fieldDefinition) {
|
|
|
7279
7279
|
kind: 'Fragment',
|
|
7280
7280
|
private: ['eTag', 'weakEtag'],
|
|
7281
7281
|
selections: createRecordSelection(childFieldDefinition),
|
|
7282
|
-
version: VERSION$
|
|
7282
|
+
version: VERSION$2m,
|
|
7283
7283
|
},
|
|
7284
7284
|
};
|
|
7285
7285
|
}
|
|
@@ -7289,7 +7289,7 @@ function createPathSelection(propertyName, fieldDefinition) {
|
|
|
7289
7289
|
required: childFieldDefinition.optional === true ? false : undefined,
|
|
7290
7290
|
fragment: {
|
|
7291
7291
|
kind: 'Fragment',
|
|
7292
|
-
version: VERSION$
|
|
7292
|
+
version: VERSION$2o,
|
|
7293
7293
|
private: [],
|
|
7294
7294
|
selections: [DISPLAY_VALUE_SELECTION, fieldValueSelection],
|
|
7295
7295
|
},
|
|
@@ -7371,7 +7371,7 @@ const RECORD_REPRESENTATION_ERROR_VERSION = 'RECORD_REPRESENTATION_ERROR_VERSION
|
|
|
7371
7371
|
const RECORD_REPRESENTATION_ERROR_STORE_METADATA_PARAMS = {
|
|
7372
7372
|
representationName: '',
|
|
7373
7373
|
namespace: keyPrefix,
|
|
7374
|
-
ttl: TTL$
|
|
7374
|
+
ttl: TTL$C,
|
|
7375
7375
|
version: RECORD_REPRESENTATION_ERROR_VERSION,
|
|
7376
7376
|
};
|
|
7377
7377
|
function isGraphNode$1(node) {
|
|
@@ -7746,7 +7746,7 @@ function mergeAndRefreshLowerVersionRecord(luvio, incoming, existing, incomingTr
|
|
|
7746
7746
|
};
|
|
7747
7747
|
}
|
|
7748
7748
|
else {
|
|
7749
|
-
buildNetworkSnapshot$
|
|
7749
|
+
buildNetworkSnapshot$14(luvio, {
|
|
7750
7750
|
recordId: incoming.id,
|
|
7751
7751
|
optionalFields: convertTrieToFields(incomingTrackedFieldsTrieRoot),
|
|
7752
7752
|
});
|
|
@@ -7766,7 +7766,7 @@ function mergeRecordConflict(luvio, incoming, existing, recordConflictMap) {
|
|
|
7766
7766
|
name: existing.apiName,
|
|
7767
7767
|
children: {},
|
|
7768
7768
|
};
|
|
7769
|
-
const recordKey = keyBuilder$
|
|
7769
|
+
const recordKey = keyBuilder$3b(luvio, {
|
|
7770
7770
|
recordId: incoming.id,
|
|
7771
7771
|
});
|
|
7772
7772
|
const trackedFieldsConfig = {
|
|
@@ -7911,7 +7911,7 @@ function fixDisplayValue(existing, incoming, path) {
|
|
|
7911
7911
|
}
|
|
7912
7912
|
}
|
|
7913
7913
|
|
|
7914
|
-
function normalize$
|
|
7914
|
+
function normalize$P(input, existing, path, luvio, store, timestamp, fieldsTrie, optionalFieldsTrie, recordConflictMap) {
|
|
7915
7915
|
const input_value = input.value;
|
|
7916
7916
|
const input_value_id = path.fullPath + '__value';
|
|
7917
7917
|
if (input_value !== null && typeof input_value === 'object') {
|
|
@@ -7932,14 +7932,14 @@ function normalize$M(input, existing, path, luvio, store, timestamp, fieldsTrie,
|
|
|
7932
7932
|
function makeIngest(fieldsTrie, optionalFieldsTrie, recordConflictMap) {
|
|
7933
7933
|
return (input, path, luvio, store, timestamp) => {
|
|
7934
7934
|
if (process.env.NODE_ENV !== 'production') {
|
|
7935
|
-
const validateError = validate$
|
|
7935
|
+
const validateError = validate$1K(input);
|
|
7936
7936
|
if (validateError !== null) {
|
|
7937
7937
|
throw validateError;
|
|
7938
7938
|
}
|
|
7939
7939
|
}
|
|
7940
7940
|
const key = path.fullPath;
|
|
7941
7941
|
let existingRecord = store.readEntry(key);
|
|
7942
|
-
let incomingRecord = normalize$
|
|
7942
|
+
let incomingRecord = normalize$P(input, store.readEntry(key), {
|
|
7943
7943
|
fullPath: key,
|
|
7944
7944
|
parent: path.parent,
|
|
7945
7945
|
propertyName: path.propertyName,
|
|
@@ -7947,7 +7947,7 @@ function makeIngest(fieldsTrie, optionalFieldsTrie, recordConflictMap) {
|
|
|
7947
7947
|
// read again after children ingested in case of a circular ref
|
|
7948
7948
|
existingRecord = store.readEntry(key);
|
|
7949
7949
|
incomingRecord = merge$2(existingRecord, incomingRecord, luvio, path);
|
|
7950
|
-
if (existingRecord === undefined || equals$
|
|
7950
|
+
if (existingRecord === undefined || equals$15(existingRecord, incomingRecord) === false) {
|
|
7951
7951
|
luvio.storePublish(key, incomingRecord);
|
|
7952
7952
|
}
|
|
7953
7953
|
return createLink$1(key);
|
|
@@ -8017,7 +8017,7 @@ function createFieldsIngestion(fieldsTrie, optionalFieldsTrie, recordConflictMap
|
|
|
8017
8017
|
}
|
|
8018
8018
|
function createChildRecordNormalize(fieldsTrie, optionalFieldsTrie, recordConflictMap) {
|
|
8019
8019
|
return dynamicNormalize$5({
|
|
8020
|
-
childRelationships: ingest$
|
|
8020
|
+
childRelationships: ingest$1V,
|
|
8021
8021
|
fields: createFieldsIngestion(fieldsTrie, optionalFieldsTrie, recordConflictMap),
|
|
8022
8022
|
});
|
|
8023
8023
|
}
|
|
@@ -8025,13 +8025,13 @@ const createRecordIngest = (fieldsTrie, optionalFieldsTrie, recordConflictMap) =
|
|
|
8025
8025
|
const childNormalize = createChildRecordNormalize(fieldsTrie, optionalFieldsTrie, recordConflictMap);
|
|
8026
8026
|
return (input, path, luvio, store, timestamp) => {
|
|
8027
8027
|
if (process.env.NODE_ENV !== 'production') {
|
|
8028
|
-
const validateError = validate$
|
|
8028
|
+
const validateError = validate$1I(input);
|
|
8029
8029
|
if (validateError !== null) {
|
|
8030
8030
|
throw validateError;
|
|
8031
8031
|
}
|
|
8032
8032
|
}
|
|
8033
8033
|
input.eTag = ''; //[W-13724550] Record Reps ALWAYS have '' etag, to be consistent with GraphQL, as it is not queryable via GraphQL.
|
|
8034
|
-
const key = keyBuilderFromType$
|
|
8034
|
+
const key = keyBuilderFromType$B(luvio, input);
|
|
8035
8035
|
let existingRecord = store.readEntry(key);
|
|
8036
8036
|
const recordPath = {
|
|
8037
8037
|
fullPath: key,
|
|
@@ -8043,17 +8043,17 @@ const createRecordIngest = (fieldsTrie, optionalFieldsTrie, recordConflictMap) =
|
|
|
8043
8043
|
existingRecord = store.readEntry(key);
|
|
8044
8044
|
incomingRecord = merge$3(existingRecord, incomingRecord, luvio, path, recordConflictMap);
|
|
8045
8045
|
if (existingRecord === undefined ||
|
|
8046
|
-
equals$
|
|
8046
|
+
equals$13(existingRecord, incomingRecord) === false ||
|
|
8047
8047
|
// always publish if existing record has drafts
|
|
8048
8048
|
existingRecord.drafts !==
|
|
8049
8049
|
undefined) {
|
|
8050
8050
|
luvio.storePublish(key, incomingRecord);
|
|
8051
8051
|
}
|
|
8052
8052
|
luvio.publishStoreMetadata(key, {
|
|
8053
|
-
ttl: TTL$
|
|
8054
|
-
representationName: RepresentationType$
|
|
8053
|
+
ttl: TTL$C,
|
|
8054
|
+
representationName: RepresentationType$W,
|
|
8055
8055
|
namespace: keyPrefix,
|
|
8056
|
-
version: VERSION$
|
|
8056
|
+
version: VERSION$2m,
|
|
8057
8057
|
});
|
|
8058
8058
|
return createLink$1(key);
|
|
8059
8059
|
};
|
|
@@ -8142,22 +8142,22 @@ function isRestrictedPathCondition(existingPath, path) {
|
|
|
8142
8142
|
(existingPath.includes('/records') && path.includes('/record-ui')));
|
|
8143
8143
|
}
|
|
8144
8144
|
|
|
8145
|
-
const createResourceRequest$
|
|
8145
|
+
const createResourceRequest$19 = function getUiApiRecordsByRecordIdCreateResourceRequest(config) {
|
|
8146
8146
|
return {
|
|
8147
|
-
...createResourceRequest$
|
|
8147
|
+
...createResourceRequest$18(config),
|
|
8148
8148
|
fulfill: fulfill,
|
|
8149
8149
|
};
|
|
8150
8150
|
};
|
|
8151
8151
|
|
|
8152
|
-
function keyBuilder$
|
|
8153
|
-
return keyBuilder$
|
|
8152
|
+
function keyBuilder$3a(luvio, params) {
|
|
8153
|
+
return keyBuilder$3b(luvio, {
|
|
8154
8154
|
recordId: params.urlParams.recordId
|
|
8155
8155
|
});
|
|
8156
8156
|
}
|
|
8157
|
-
function getResponseCacheKeys$
|
|
8158
|
-
getTypeCacheKeys$
|
|
8157
|
+
function getResponseCacheKeys$10(storeKeyMap, luvio, resourceParams, response) {
|
|
8158
|
+
getTypeCacheKeys$1Y(storeKeyMap, luvio, response);
|
|
8159
8159
|
}
|
|
8160
|
-
function createResourceRequest$
|
|
8160
|
+
function createResourceRequest$18(config) {
|
|
8161
8161
|
const headers = {};
|
|
8162
8162
|
return {
|
|
8163
8163
|
baseUri: '/services/data/v60.0',
|
|
@@ -8181,17 +8181,17 @@ const getRecord_ConfigPropertyMetadata = [
|
|
|
8181
8181
|
generateParamConfigMetadata('pageSize', false, 1 /* QueryParameter */, 3 /* Integer */),
|
|
8182
8182
|
generateParamConfigMetadata('updateMru', false, 1 /* QueryParameter */, 1 /* Boolean */),
|
|
8183
8183
|
];
|
|
8184
|
-
const createResourceParams$
|
|
8184
|
+
const createResourceParams$10 = /*#__PURE__*/ createResourceParams(getRecord_ConfigPropertyMetadata);
|
|
8185
8185
|
|
|
8186
8186
|
// used by getUiApiRecordsBatchByRecordIds#selectChildResourceParams
|
|
8187
8187
|
function buildRecordSelector(luvio, recordId, fields, optionalFields) {
|
|
8188
8188
|
return {
|
|
8189
|
-
recordId: keyBuilder$
|
|
8189
|
+
recordId: keyBuilder$3b(luvio, { recordId }),
|
|
8190
8190
|
node: {
|
|
8191
8191
|
kind: 'Fragment',
|
|
8192
8192
|
private: ['eTag', 'weakEtag'],
|
|
8193
8193
|
selections: buildSelectionFromFields(fields, optionalFields),
|
|
8194
|
-
version: VERSION$
|
|
8194
|
+
version: VERSION$2m,
|
|
8195
8195
|
},
|
|
8196
8196
|
variables: {},
|
|
8197
8197
|
};
|
|
@@ -8199,27 +8199,27 @@ function buildRecordSelector(luvio, recordId, fields, optionalFields) {
|
|
|
8199
8199
|
function buildSnapshotRefresh$5(luvio, config) {
|
|
8200
8200
|
return {
|
|
8201
8201
|
config,
|
|
8202
|
-
resolve: () => buildNetworkSnapshot$
|
|
8202
|
+
resolve: () => buildNetworkSnapshot$14(luvio, config),
|
|
8203
8203
|
};
|
|
8204
8204
|
}
|
|
8205
8205
|
function prepareRequest$6(luvio, config) {
|
|
8206
8206
|
const { recordId, fields } = config;
|
|
8207
8207
|
// Should this go into the coersion logic?
|
|
8208
|
-
const key = keyBuilder$
|
|
8208
|
+
const key = keyBuilder$3a(luvio, createResourceParams$10(config));
|
|
8209
8209
|
const allTrackedFields = getTrackedFields(key, luvio.getNode(key), {
|
|
8210
8210
|
maxDepth: configurationForRestAdapters.getTrackedFieldDepthOnCacheMiss(),
|
|
8211
8211
|
onlyFetchLeafNodeIdAndName: configurationForRestAdapters.getTrackedFieldLeafNodeIdAndNameOnly(),
|
|
8212
8212
|
}, config.optionalFields);
|
|
8213
8213
|
const optionalFields = fields === undefined ? allTrackedFields : difference(allTrackedFields, fields);
|
|
8214
|
-
const resourceParams = createResourceParams$
|
|
8214
|
+
const resourceParams = createResourceParams$10({
|
|
8215
8215
|
recordId,
|
|
8216
8216
|
fields,
|
|
8217
8217
|
optionalFields: optionalFields.length > 0 ? optionalFields : undefined,
|
|
8218
8218
|
});
|
|
8219
|
-
const request = createResourceRequest$
|
|
8219
|
+
const request = createResourceRequest$19(resourceParams);
|
|
8220
8220
|
return { request, key, allTrackedFields, resourceParams };
|
|
8221
8221
|
}
|
|
8222
|
-
function ingestSuccess$
|
|
8222
|
+
function ingestSuccess$S(luvio, config, key, allTrackedFields, response, serverRequestCount) {
|
|
8223
8223
|
const { body } = response;
|
|
8224
8224
|
const fields = config.fields === undefined ? [] : config.fields;
|
|
8225
8225
|
const optionalFields = config.optionalFields === undefined ? [] : config.optionalFields;
|
|
@@ -8233,19 +8233,19 @@ function ingestSuccess$Q(luvio, config, key, allTrackedFields, response, serverR
|
|
|
8233
8233
|
return luvio.storeLookup(buildRecordSelector(luvio, config.recordId, fields, optionalFields), buildSnapshotRefresh$5(luvio, config));
|
|
8234
8234
|
}
|
|
8235
8235
|
function onResourceSuccess(luvio, config, key, allTrackedFields, response, serverRequestCount) {
|
|
8236
|
-
const snapshot = ingestSuccess$
|
|
8236
|
+
const snapshot = ingestSuccess$S(luvio, config, key, allTrackedFields, response, serverRequestCount);
|
|
8237
8237
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
8238
8238
|
}
|
|
8239
|
-
function ingestError$
|
|
8239
|
+
function ingestError$O(luvio, config, key, err) {
|
|
8240
8240
|
const errorSnapshot = luvio.errorSnapshot(err, buildSnapshotRefresh$5(luvio, config));
|
|
8241
8241
|
luvio.storeIngestError(key, errorSnapshot, RECORD_REPRESENTATION_ERROR_STORE_METADATA_PARAMS);
|
|
8242
8242
|
return errorSnapshot;
|
|
8243
8243
|
}
|
|
8244
8244
|
function onResourceError(luvio, config, key, err) {
|
|
8245
|
-
const errorSnapshot = ingestError$
|
|
8245
|
+
const errorSnapshot = ingestError$O(luvio, config, key, err);
|
|
8246
8246
|
return luvio.storeBroadcast().then(() => errorSnapshot);
|
|
8247
8247
|
}
|
|
8248
|
-
function buildNetworkSnapshot$
|
|
8248
|
+
function buildNetworkSnapshot$14(luvio, config, serverRequestCount = 0, options) {
|
|
8249
8249
|
const { request, key, allTrackedFields, resourceParams } = prepareRequest$6(luvio, config);
|
|
8250
8250
|
return luvio.dispatchResourceRequest(request, options).then((response) => {
|
|
8251
8251
|
return luvio.handleSuccessResponse(() => {
|
|
@@ -8262,7 +8262,7 @@ function buildNetworkSnapshot$12(luvio, config, serverRequestCount = 0, options)
|
|
|
8262
8262
|
return onResourceSuccess(luvio, config, key, allTrackedFields, response, serverRequestCount + 1);
|
|
8263
8263
|
}, () => {
|
|
8264
8264
|
const cache = new StoreKeyMap();
|
|
8265
|
-
getResponseCacheKeys$
|
|
8265
|
+
getResponseCacheKeys$10(cache, luvio, resourceParams, response.body);
|
|
8266
8266
|
return cache;
|
|
8267
8267
|
});
|
|
8268
8268
|
}, (err) => {
|
|
@@ -8276,7 +8276,7 @@ function isSingleBatchRecordResponse(response) {
|
|
|
8276
8276
|
response.results.length === 1);
|
|
8277
8277
|
}
|
|
8278
8278
|
|
|
8279
|
-
const VERSION$
|
|
8279
|
+
const VERSION$2l = "98cce53b8d13b1883d001bbdaab24383";
|
|
8280
8280
|
|
|
8281
8281
|
const nonCachedErrors$8 = ObjectCreate$1(null);
|
|
8282
8282
|
function ingestSuccessChildResourceParams$8(luvio, childResourceParamsArray, childEnvelopes, serverRequestCount = 0) {
|
|
@@ -8286,7 +8286,7 @@ function ingestSuccessChildResourceParams$8(luvio, childResourceParamsArray, chi
|
|
|
8286
8286
|
const now = Date.now();
|
|
8287
8287
|
for (let index = 0, len = childResourceParamsArray.length; index < len; index += 1) {
|
|
8288
8288
|
const childResourceParams = childResourceParamsArray[index];
|
|
8289
|
-
const childKey = keyBuilder$
|
|
8289
|
+
const childKey = keyBuilder$3a(luvio, childResourceParams);
|
|
8290
8290
|
const result = childEnvelopes[index];
|
|
8291
8291
|
const { statusCode: childStatusCode, result: childBody } = result;
|
|
8292
8292
|
if (childStatusCode === 200) {
|
|
@@ -8301,7 +8301,7 @@ function ingestSuccessChildResourceParams$8(luvio, childResourceParamsArray, chi
|
|
|
8301
8301
|
maxDepth: configurationForRestAdapters.getTrackedFieldDepthOnCacheMiss(),
|
|
8302
8302
|
onlyFetchLeafNodeIdAndName: configurationForRestAdapters.getTrackedFieldLeafNodeIdAndNameOnly(),
|
|
8303
8303
|
}, childResourceParams.queryParams.optionalFields);
|
|
8304
|
-
const childSnapshot = ingestSuccess$
|
|
8304
|
+
const childSnapshot = ingestSuccess$S(luvio, {
|
|
8305
8305
|
recordId: childResourceParams.urlParams.recordId,
|
|
8306
8306
|
fields: childResourceParams.queryParams.fields,
|
|
8307
8307
|
optionalFields: childResourceParams.queryParams.optionalFields,
|
|
@@ -8327,7 +8327,7 @@ function ingestSuccessChildResourceParams$8(luvio, childResourceParamsArray, chi
|
|
|
8327
8327
|
headers: {},
|
|
8328
8328
|
errorType: 'fetchResponse',
|
|
8329
8329
|
};
|
|
8330
|
-
ingestError$
|
|
8330
|
+
ingestError$O(luvio, {
|
|
8331
8331
|
recordId: childResourceParams.urlParams.recordId,
|
|
8332
8332
|
fields: childResourceParams.queryParams.fields,
|
|
8333
8333
|
optionalFields: childResourceParams.queryParams.optionalFields,
|
|
@@ -8342,7 +8342,7 @@ function ingestSuccessChildResourceParams$8(luvio, childResourceParamsArray, chi
|
|
|
8342
8342
|
// track non-cached responses so rebuilds work properly
|
|
8343
8343
|
if (childStatusCode !== 404 && childStatusCode !== 200) {
|
|
8344
8344
|
nonCachedErrors$8[childKey] = {
|
|
8345
|
-
expiration: now + TTL$
|
|
8345
|
+
expiration: now + TTL$C,
|
|
8346
8346
|
response: childBody,
|
|
8347
8347
|
status: childStatusCode,
|
|
8348
8348
|
};
|
|
@@ -8373,11 +8373,11 @@ function selectChildResourceParams$8(luvio, childResources, resourceParams) {
|
|
|
8373
8373
|
read: (reader) => {
|
|
8374
8374
|
// Top-level 404 lookup
|
|
8375
8375
|
const compositeSnapshot = luvio.storeLookup({
|
|
8376
|
-
recordId: keyBuilder$
|
|
8376
|
+
recordId: keyBuilder$39(luvio, resourceParams),
|
|
8377
8377
|
node: {
|
|
8378
8378
|
kind: 'Fragment',
|
|
8379
8379
|
private: [],
|
|
8380
|
-
version: VERSION$
|
|
8380
|
+
version: VERSION$2l,
|
|
8381
8381
|
},
|
|
8382
8382
|
variables: {},
|
|
8383
8383
|
});
|
|
@@ -8397,7 +8397,7 @@ function selectChildResourceParams$8(luvio, childResources, resourceParams) {
|
|
|
8397
8397
|
reader.enterPath(i);
|
|
8398
8398
|
reader.enterPath(envelopeBodyPath);
|
|
8399
8399
|
const childResource = childResources[i];
|
|
8400
|
-
const childKey = keyBuilder$
|
|
8400
|
+
const childKey = keyBuilder$3a(luvio, childResource);
|
|
8401
8401
|
const isMissingDataBeforeChildRead = reader.getIsDataMissing();
|
|
8402
8402
|
const childSnapshot = reader.read(buildRecordSelector(luvio, childResource.urlParams.recordId, childResource.queryParams.fields || [], childResource.queryParams.optionalFields || []));
|
|
8403
8403
|
reader.exitPath();
|
|
@@ -8497,10 +8497,10 @@ function createChildResourceParams$c(resourceParams) {
|
|
|
8497
8497
|
}
|
|
8498
8498
|
return childConfigs;
|
|
8499
8499
|
}
|
|
8500
|
-
function keyBuilder$
|
|
8500
|
+
function keyBuilder$39(luvio, params) {
|
|
8501
8501
|
return keyPrefix + '::BatchRepresentation:(' + 'childRelationships:' + params.queryParams.childRelationships + ',' + 'fields:' + params.queryParams.fields + ',' + 'layoutTypes:' + params.queryParams.layoutTypes + ',' + 'modes:' + params.queryParams.modes + ',' + 'optionalFields:' + params.queryParams.optionalFields + ',' + 'pageSize:' + params.queryParams.pageSize + ',' + 'updateMru:' + params.queryParams.updateMru + ',' + 'recordIds:' + params.urlParams.recordIds + ')';
|
|
8502
8502
|
}
|
|
8503
|
-
function getResponseCacheKeys
|
|
8503
|
+
function getResponseCacheKeys$$(keys, luvio, resourceParams, response) {
|
|
8504
8504
|
const childEnvelopes = response.results;
|
|
8505
8505
|
const childResourceParamsArray = createChildResourceParams$c(resourceParams);
|
|
8506
8506
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -8514,25 +8514,25 @@ function getResponseCacheKeys$Z(keys, luvio, resourceParams, response) {
|
|
|
8514
8514
|
const childResult = childEnvelopes[index];
|
|
8515
8515
|
const { statusCode: childStatusCode, result: childBody } = childResult;
|
|
8516
8516
|
if (childStatusCode === 200) {
|
|
8517
|
-
getResponseCacheKeys$
|
|
8517
|
+
getResponseCacheKeys$10(keys, luvio, childResourceParams, childBody);
|
|
8518
8518
|
}
|
|
8519
8519
|
else if (childStatusCode === 404) {
|
|
8520
|
-
const childKey = keyBuilder$
|
|
8520
|
+
const childKey = keyBuilder$3a(luvio, childResourceParams);
|
|
8521
8521
|
keys.set(childKey, {
|
|
8522
8522
|
namespace: keyPrefix,
|
|
8523
|
-
representationName: RepresentationType$
|
|
8523
|
+
representationName: RepresentationType$W,
|
|
8524
8524
|
mergeable: false
|
|
8525
8525
|
});
|
|
8526
8526
|
}
|
|
8527
8527
|
}
|
|
8528
8528
|
}
|
|
8529
|
-
function ingestError$
|
|
8530
|
-
const key = keyBuilder$
|
|
8529
|
+
function ingestError$N(luvio, params, error, snapshotRefresh) {
|
|
8530
|
+
const key = keyBuilder$39(luvio, params);
|
|
8531
8531
|
const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
|
|
8532
8532
|
luvio.storeIngestError(key, errorSnapshot);
|
|
8533
8533
|
return errorSnapshot;
|
|
8534
8534
|
}
|
|
8535
|
-
function createResourceRequest$
|
|
8535
|
+
function createResourceRequest$17(config) {
|
|
8536
8536
|
const headers = {};
|
|
8537
8537
|
return {
|
|
8538
8538
|
baseUri: '/services/data/v60.0',
|
|
@@ -8546,7 +8546,7 @@ function createResourceRequest$15(config) {
|
|
|
8546
8546
|
};
|
|
8547
8547
|
}
|
|
8548
8548
|
|
|
8549
|
-
function createResourceParams
|
|
8549
|
+
function createResourceParams$$(config) {
|
|
8550
8550
|
const { records: configRecords } = config;
|
|
8551
8551
|
const recordIds = [];
|
|
8552
8552
|
const resourceConfigFields = [];
|
|
@@ -8598,13 +8598,13 @@ function createChildResourceParams$b(config) {
|
|
|
8598
8598
|
return childResources;
|
|
8599
8599
|
}
|
|
8600
8600
|
|
|
8601
|
-
function adapterFragment$
|
|
8601
|
+
function adapterFragment$L(luvio, config) {
|
|
8602
8602
|
const childResources = createChildResourceParams$b(config);
|
|
8603
|
-
const resourceParams = createResourceParams
|
|
8603
|
+
const resourceParams = createResourceParams$$(config);
|
|
8604
8604
|
return selectChildResourceParams$8(luvio, childResources, resourceParams);
|
|
8605
8605
|
}
|
|
8606
8606
|
|
|
8607
|
-
function onFetchResponseSuccess$
|
|
8607
|
+
function onFetchResponseSuccess$P(luvio, config, resourceParams, response, serverRequestCount = 0) {
|
|
8608
8608
|
const childEnvelopes = response.body.results;
|
|
8609
8609
|
const childResourceParamsArray = createChildResourceParams$b(config);
|
|
8610
8610
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -8616,7 +8616,7 @@ function onFetchResponseSuccess$N(luvio, config, resourceParams, response, serve
|
|
|
8616
8616
|
}
|
|
8617
8617
|
}
|
|
8618
8618
|
const snapshotStateFulfilled = 'Fulfilled';
|
|
8619
|
-
const key = keyBuilder$
|
|
8619
|
+
const key = keyBuilder$39(luvio, resourceParams);
|
|
8620
8620
|
const { childSnapshotData, seenRecords } = ingestSuccessChildResourceParams$8(luvio, childResourceParamsArray, childEnvelopes, serverRequestCount);
|
|
8621
8621
|
const snapshot = {
|
|
8622
8622
|
recordId: key,
|
|
@@ -8625,36 +8625,36 @@ function onFetchResponseSuccess$N(luvio, config, resourceParams, response, serve
|
|
|
8625
8625
|
seenRecords: seenRecords,
|
|
8626
8626
|
select: {
|
|
8627
8627
|
recordId: key,
|
|
8628
|
-
node: adapterFragment$
|
|
8628
|
+
node: adapterFragment$L(luvio, config),
|
|
8629
8629
|
variables: {},
|
|
8630
8630
|
},
|
|
8631
8631
|
refresh: {
|
|
8632
8632
|
config,
|
|
8633
|
-
resolve: () => buildNetworkSnapshot$
|
|
8633
|
+
resolve: () => buildNetworkSnapshot$13(luvio, config, serverRequestCount, snapshotRefreshOptions),
|
|
8634
8634
|
},
|
|
8635
8635
|
variables: {},
|
|
8636
8636
|
};
|
|
8637
8637
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
8638
8638
|
}
|
|
8639
8639
|
|
|
8640
|
-
function onFetchResponseError$
|
|
8641
|
-
const snapshot = ingestError$
|
|
8640
|
+
function onFetchResponseError$Q(luvio, config, resourceParams, response) {
|
|
8641
|
+
const snapshot = ingestError$N(luvio, resourceParams, response, {
|
|
8642
8642
|
config,
|
|
8643
|
-
resolve: () => buildNetworkSnapshot$
|
|
8643
|
+
resolve: () => buildNetworkSnapshot$13(luvio, config, 0, snapshotRefreshOptions),
|
|
8644
8644
|
});
|
|
8645
8645
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
8646
8646
|
}
|
|
8647
|
-
function buildNetworkSnapshot$
|
|
8648
|
-
const resourceParams = createResourceParams
|
|
8649
|
-
const request = createResourceRequest$
|
|
8647
|
+
function buildNetworkSnapshot$13(luvio, config, serverRequestCount = 0, options) {
|
|
8648
|
+
const resourceParams = createResourceParams$$(config);
|
|
8649
|
+
const request = createResourceRequest$17(resourceParams);
|
|
8650
8650
|
return luvio.dispatchResourceRequest(request, options).then((response) => {
|
|
8651
|
-
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$
|
|
8651
|
+
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$P(luvio, config, resourceParams, response, serverRequestCount + 1), () => {
|
|
8652
8652
|
const cache = new StoreKeyMap();
|
|
8653
|
-
getResponseCacheKeys
|
|
8653
|
+
getResponseCacheKeys$$(cache, luvio, resourceParams, response.body);
|
|
8654
8654
|
return cache;
|
|
8655
8655
|
});
|
|
8656
8656
|
}, (response) => {
|
|
8657
|
-
return luvio.handleErrorResponse(() => onFetchResponseError$
|
|
8657
|
+
return luvio.handleErrorResponse(() => onFetchResponseError$Q(luvio, config, resourceParams, response));
|
|
8658
8658
|
});
|
|
8659
8659
|
}
|
|
8660
8660
|
|
|
@@ -8671,7 +8671,7 @@ function resolveConflict(luvio, map) {
|
|
|
8671
8671
|
recordId,
|
|
8672
8672
|
optionalFields: convertTrieToFields(map.conflicts[recordId].trackedFields),
|
|
8673
8673
|
};
|
|
8674
|
-
buildNetworkSnapshot$
|
|
8674
|
+
buildNetworkSnapshot$14(luvio, config, map.serverRequestCount);
|
|
8675
8675
|
}
|
|
8676
8676
|
else {
|
|
8677
8677
|
const records = reduce.call(ids, (acc, id) => {
|
|
@@ -8683,10 +8683,10 @@ function resolveConflict(luvio, map) {
|
|
|
8683
8683
|
return acc;
|
|
8684
8684
|
}, []);
|
|
8685
8685
|
const config = { records };
|
|
8686
|
-
buildNetworkSnapshot$
|
|
8686
|
+
buildNetworkSnapshot$13(luvio, config, map.serverRequestCount);
|
|
8687
8687
|
}
|
|
8688
8688
|
}
|
|
8689
|
-
const ingest$
|
|
8689
|
+
const ingest$1U = (input, path, luvio, store, timestamp) => {
|
|
8690
8690
|
const conflictMap = {
|
|
8691
8691
|
conflicts: {},
|
|
8692
8692
|
serverRequestCount: 0,
|
|
@@ -8697,7 +8697,7 @@ const ingest$1R = (input, path, luvio, store, timestamp) => {
|
|
|
8697
8697
|
return result;
|
|
8698
8698
|
};
|
|
8699
8699
|
|
|
8700
|
-
const adapterName$
|
|
8700
|
+
const adapterName$W = 'getListUiByApiName';
|
|
8701
8701
|
const getListUiByApiName_ConfigPropertyMetadata = [
|
|
8702
8702
|
generateParamConfigMetadata('listViewApiName', true, 0 /* UrlParameter */, 0 /* String */),
|
|
8703
8703
|
generateParamConfigMetadata('objectApiName', true, 0 /* UrlParameter */, 0 /* String */, false, getObjectApiName$1),
|
|
@@ -8707,9 +8707,9 @@ const getListUiByApiName_ConfigPropertyMetadata = [
|
|
|
8707
8707
|
generateParamConfigMetadata('pageToken', false, 1 /* QueryParameter */, 0 /* String */),
|
|
8708
8708
|
generateParamConfigMetadata('sortBy', false, 1 /* QueryParameter */, 0 /* String */, true, getFieldApiNamesArray),
|
|
8709
8709
|
];
|
|
8710
|
-
const getListUiByApiName_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
8710
|
+
const getListUiByApiName_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$W, getListUiByApiName_ConfigPropertyMetadata);
|
|
8711
8711
|
|
|
8712
|
-
const adapterName$
|
|
8712
|
+
const adapterName$V = 'getListUiByListViewId';
|
|
8713
8713
|
const getListUiByListViewId_ConfigPropertyMetadata = [
|
|
8714
8714
|
generateParamConfigMetadata('listViewId', true, 0 /* UrlParameter */, 0 /* String */),
|
|
8715
8715
|
generateParamConfigMetadata('fields', false, 1 /* QueryParameter */, 0 /* String */, true, getFieldApiNamesArray),
|
|
@@ -8718,9 +8718,9 @@ const getListUiByListViewId_ConfigPropertyMetadata = [
|
|
|
8718
8718
|
generateParamConfigMetadata('pageToken', false, 1 /* QueryParameter */, 0 /* String */),
|
|
8719
8719
|
generateParamConfigMetadata('sortBy', false, 1 /* QueryParameter */, 0 /* String */, true, getFieldApiNamesArray),
|
|
8720
8720
|
];
|
|
8721
|
-
const getListUiByListViewId_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
8721
|
+
const getListUiByListViewId_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$V, getListUiByListViewId_ConfigPropertyMetadata);
|
|
8722
8722
|
|
|
8723
|
-
const adapterName$
|
|
8723
|
+
const adapterName$T = 'getMruListUi';
|
|
8724
8724
|
const getMruListUi_ConfigPropertyMetadata = [
|
|
8725
8725
|
generateParamConfigMetadata('objectApiName', true, 0 /* UrlParameter */, 0 /* String */, false, getObjectApiName$1),
|
|
8726
8726
|
generateParamConfigMetadata('fields', false, 1 /* QueryParameter */, 0 /* String */, true, getFieldApiNamesArray),
|
|
@@ -8729,7 +8729,7 @@ const getMruListUi_ConfigPropertyMetadata = [
|
|
|
8729
8729
|
generateParamConfigMetadata('pageToken', false, 1 /* QueryParameter */, 0 /* String */),
|
|
8730
8730
|
generateParamConfigMetadata('sortBy', false, 1 /* QueryParameter */, 0 /* String */, true, getFieldApiNamesArray),
|
|
8731
8731
|
];
|
|
8732
|
-
const getMruListUi_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
8732
|
+
const getMruListUi_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$T, getMruListUi_ConfigPropertyMetadata);
|
|
8733
8733
|
// make local copies of the adapter configs so we can ignore other getListUi config parameters to match
|
|
8734
8734
|
// lds222 behavior
|
|
8735
8735
|
({
|
|
@@ -8763,9 +8763,9 @@ const getMruListUi_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationCon
|
|
|
8763
8763
|
],
|
|
8764
8764
|
},
|
|
8765
8765
|
});
|
|
8766
|
-
const RepresentationType$
|
|
8767
|
-
function keyBuilder$
|
|
8768
|
-
return keyPrefix + '::' + RepresentationType$
|
|
8766
|
+
const RepresentationType$R = 'ObjectInfoRepresentation';
|
|
8767
|
+
function keyBuilder$2Y(luvio, config) {
|
|
8768
|
+
return keyPrefix + '::' + RepresentationType$R + ':' + config.apiName;
|
|
8769
8769
|
}
|
|
8770
8770
|
|
|
8771
8771
|
var DiscriminatorValues$4;
|
|
@@ -9120,7 +9120,7 @@ function getShallowRecord(luvio, storeRecordId) {
|
|
|
9120
9120
|
*/
|
|
9121
9121
|
function getObjectMetadata(luvio, record) {
|
|
9122
9122
|
const { data: objectInfo } = luvio.storeLookup({
|
|
9123
|
-
recordId: keyBuilder$
|
|
9123
|
+
recordId: keyBuilder$2Y(luvio, { apiName: record.apiName }),
|
|
9124
9124
|
node: {
|
|
9125
9125
|
kind: 'Fragment',
|
|
9126
9126
|
private: ['eTag'],
|
|
@@ -9161,7 +9161,7 @@ function getObjectMetadata(luvio, record) {
|
|
|
9161
9161
|
function fixRecordTypes(luvio, record) {
|
|
9162
9162
|
// non-master record types should always be correct
|
|
9163
9163
|
if (record.recordTypeId === MASTER_RECORD_TYPE_ID) {
|
|
9164
|
-
const key = keyBuilder$
|
|
9164
|
+
const key = keyBuilder$3b(luvio, { recordId: record.id });
|
|
9165
9165
|
const recordNode = luvio.getNode(key);
|
|
9166
9166
|
if (isGraphNode(recordNode) &&
|
|
9167
9167
|
recordNode.scalar('recordTypeId') !== MASTER_RECORD_TYPE_ID) {
|
|
@@ -9235,7 +9235,7 @@ class AdsBridge {
|
|
|
9235
9235
|
// Don't let incorrect ADS/RecordGVP recordTypeIds replace a valid record type in our store
|
|
9236
9236
|
// with the master record type. See W-7302870 for details.
|
|
9237
9237
|
fixRecordTypes(luvio, recordCopy);
|
|
9238
|
-
luvio.storeIngest(INGEST_KEY, ingest$
|
|
9238
|
+
luvio.storeIngest(INGEST_KEY, ingest$1U, recordCopy);
|
|
9239
9239
|
}
|
|
9240
9240
|
}
|
|
9241
9241
|
if (didIngestRecord === true) {
|
|
@@ -9248,7 +9248,7 @@ class AdsBridge {
|
|
|
9248
9248
|
*/
|
|
9249
9249
|
evict(recordId) {
|
|
9250
9250
|
const { luvio } = this;
|
|
9251
|
-
const key = keyBuilder$
|
|
9251
|
+
const key = keyBuilder$3b(luvio, { recordId });
|
|
9252
9252
|
return this.lockLdsRecordEmit(() => {
|
|
9253
9253
|
luvio.storeEvict(key);
|
|
9254
9254
|
luvio.storeBroadcast();
|
|
@@ -9263,7 +9263,7 @@ class AdsBridge {
|
|
|
9263
9263
|
*/
|
|
9264
9264
|
getTrackedFieldsForRecord(recordId) {
|
|
9265
9265
|
const { luvio } = this;
|
|
9266
|
-
const storeRecordId = keyBuilder$
|
|
9266
|
+
const storeRecordId = keyBuilder$3b(luvio, { recordId });
|
|
9267
9267
|
const recordNode = luvio.getNode(storeRecordId);
|
|
9268
9268
|
if (!isGraphNode(recordNode)) {
|
|
9269
9269
|
return Promise.resolve([]);
|
package/dist/adsBridge.js
CHANGED