@salesforce/lds-worker-api 1.266.0-dev14 → 1.266.0-dev16
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.
|
@@ -1034,4 +1034,4 @@ if (process.env.NODE_ENV !== 'production') {
|
|
|
1034
1034
|
}
|
|
1035
1035
|
|
|
1036
1036
|
export { createPrimingSession, draftManager, draftQueue, evictCacheRecordsByIds, evictExpiredCacheEntries, executeAdapter, executeMutatingAdapter, getImperativeAdapterNames, invokeAdapter, invokeAdapterWithDraftToReplace, invokeAdapterWithMetadata, nimbusDraftQueue, setMetadataTTL, setUiApiRecordTTL, stopEviction, subscribeToAdapter };
|
|
1037
|
-
// version: 1.266.0-
|
|
1037
|
+
// version: 1.266.0-dev16-a54e7da01
|
|
@@ -4144,7 +4144,7 @@ function withDefaultLuvio(callback) {
|
|
|
4144
4144
|
}
|
|
4145
4145
|
callbacks.push(callback);
|
|
4146
4146
|
}
|
|
4147
|
-
// version: 1.266.0-
|
|
4147
|
+
// version: 1.266.0-dev16-a54e7da01
|
|
4148
4148
|
|
|
4149
4149
|
// TODO [TD-0081508]: once that TD is fulfilled we can probably change this file
|
|
4150
4150
|
function instrumentAdapter$1(createFunction, _metadata) {
|
|
@@ -15652,7 +15652,7 @@ function gql(literals, ...subs) {
|
|
|
15652
15652
|
}
|
|
15653
15653
|
return superResult;
|
|
15654
15654
|
}
|
|
15655
|
-
// version: 1.266.0-
|
|
15655
|
+
// version: 1.266.0-dev16-a54e7da01
|
|
15656
15656
|
|
|
15657
15657
|
function unwrap(data) {
|
|
15658
15658
|
// The lwc-luvio bindings import a function from lwc called "unwrap".
|
|
@@ -16577,7 +16577,7 @@ function createGraphQLWireAdapterConstructor(luvio, adapter, metadata, astResolv
|
|
|
16577
16577
|
const { apiFamily, name } = metadata;
|
|
16578
16578
|
return createGraphQLWireAdapterConstructor$1(adapter, `${apiFamily}.${name}`, luvio, astResolver);
|
|
16579
16579
|
}
|
|
16580
|
-
// version: 1.266.0-
|
|
16580
|
+
// version: 1.266.0-dev16-a54e7da01
|
|
16581
16581
|
|
|
16582
16582
|
/**
|
|
16583
16583
|
* Copyright (c) 2022, Salesforce, Inc.,
|
|
@@ -43154,7 +43154,7 @@ withDefaultLuvio((luvio) => {
|
|
|
43154
43154
|
throttle(60, 60000, createLDSAdapter(luvio, 'notifyListInfoUpdateAvailable', notifyUpdateAvailableFactory$1));
|
|
43155
43155
|
throttle(60, 60000, createLDSAdapter(luvio, 'notifyQuickActionDefaultsUpdateAvailable', notifyUpdateAvailableFactory));
|
|
43156
43156
|
});
|
|
43157
|
-
// version: 1.266.0-
|
|
43157
|
+
// version: 1.266.0-dev16-6c1030f29
|
|
43158
43158
|
|
|
43159
43159
|
var ldsIdempotencyWriteDisabled = {
|
|
43160
43160
|
isOpen: function (e) {
|
|
@@ -59909,6 +59909,7 @@ function findReferenceFieldForSpanningField(fieldName, objectInfo) {
|
|
|
59909
59909
|
function buildFieldUnionArray(existingRecord, incomingRecord, objectInfo) {
|
|
59910
59910
|
const allFields = Array.from(new Set([...Object.keys(existingRecord.fields), ...Object.keys(incomingRecord.fields)]));
|
|
59911
59911
|
const fieldUnion = [];
|
|
59912
|
+
let includesSpanningFields = false;
|
|
59912
59913
|
allFields.forEach((fieldName) => {
|
|
59913
59914
|
const objectInfoField = objectInfo.fields[fieldName];
|
|
59914
59915
|
if (objectInfoField === undefined) {
|
|
@@ -59916,13 +59917,14 @@ function buildFieldUnionArray(existingRecord, incomingRecord, objectInfo) {
|
|
|
59916
59917
|
const referenceField = findReferenceFieldForSpanningField(fieldName, objectInfo);
|
|
59917
59918
|
if (referenceField !== undefined) {
|
|
59918
59919
|
fieldUnion.push(`${fieldName}.Id`);
|
|
59920
|
+
includesSpanningFields = true;
|
|
59919
59921
|
}
|
|
59920
59922
|
}
|
|
59921
59923
|
else {
|
|
59922
59924
|
fieldUnion.push(fieldName);
|
|
59923
59925
|
}
|
|
59924
59926
|
});
|
|
59925
|
-
return fieldUnion;
|
|
59927
|
+
return { fields: fieldUnion, includesSpanningFields };
|
|
59926
59928
|
}
|
|
59927
59929
|
/**
|
|
59928
59930
|
* Merges (if possible) an incoming record from a priming session with an existing record in the durable store.
|
|
@@ -59954,7 +59956,7 @@ function mergeRecord(existingRecord, incomingRecord, objectInfo) {
|
|
|
59954
59956
|
ok: false,
|
|
59955
59957
|
code: 'conflict-drafts',
|
|
59956
59958
|
hasDraft: true,
|
|
59957
|
-
fieldUnion: buildFieldUnionArray(existingRecord, incomingRecord, objectInfo),
|
|
59959
|
+
fieldUnion: buildFieldUnionArray(existingRecord, incomingRecord, objectInfo).fields,
|
|
59958
59960
|
};
|
|
59959
59961
|
}
|
|
59960
59962
|
// Check if incoming record's Etag is equal to the existing one
|
|
@@ -60016,10 +60018,19 @@ function mergeRecord(existingRecord, incomingRecord, objectInfo) {
|
|
|
60016
60018
|
};
|
|
60017
60019
|
}
|
|
60018
60020
|
// If Etags do not match and the incoming record does not contain all fields, re-request the record
|
|
60021
|
+
const { fields, includesSpanningFields } = buildFieldUnionArray(existingRecord, incomingRecord, objectInfo);
|
|
60022
|
+
if (includesSpanningFields) {
|
|
60023
|
+
return {
|
|
60024
|
+
ok: false,
|
|
60025
|
+
code: 'conflict-spanning-record',
|
|
60026
|
+
fieldUnion: fields,
|
|
60027
|
+
hasDraft: false,
|
|
60028
|
+
};
|
|
60029
|
+
}
|
|
60019
60030
|
return {
|
|
60020
60031
|
ok: false,
|
|
60021
60032
|
code: 'conflict-missing-fields',
|
|
60022
|
-
fieldUnion:
|
|
60033
|
+
fieldUnion: fields,
|
|
60023
60034
|
hasDraft: false,
|
|
60024
60035
|
};
|
|
60025
60036
|
}
|
|
@@ -61067,7 +61078,7 @@ register$1({
|
|
|
61067
61078
|
id: '@salesforce/lds-network-adapter',
|
|
61068
61079
|
instrument: instrument$2,
|
|
61069
61080
|
});
|
|
61070
|
-
// version: 1.266.0-
|
|
61081
|
+
// version: 1.266.0-dev16-a54e7da01
|
|
61071
61082
|
|
|
61072
61083
|
const { create: create$3, keys: keys$3 } = Object;
|
|
61073
61084
|
const { stringify: stringify$1, parse: parse$1 } = JSON;
|
|
@@ -79462,7 +79473,7 @@ register$1({
|
|
|
79462
79473
|
configuration: { ...configurationForGraphQLAdapters$1 },
|
|
79463
79474
|
instrument: instrument$1,
|
|
79464
79475
|
});
|
|
79465
|
-
// version: 1.266.0-
|
|
79476
|
+
// version: 1.266.0-dev16-6c1030f29
|
|
79466
79477
|
|
|
79467
79478
|
// On core the unstable adapters are re-exported with different names,
|
|
79468
79479
|
// we want to match them here.
|
|
@@ -81716,7 +81727,7 @@ withDefaultLuvio((luvio) => {
|
|
|
81716
81727
|
unstable_graphQL_imperative = createImperativeAdapter(luvio, createInstrumentedAdapter(ldsAdapter, adapterMetadata), adapterMetadata);
|
|
81717
81728
|
graphQLImperative = ldsAdapter;
|
|
81718
81729
|
});
|
|
81719
|
-
// version: 1.266.0-
|
|
81730
|
+
// version: 1.266.0-dev16-6c1030f29
|
|
81720
81731
|
|
|
81721
81732
|
var gqlApi = /*#__PURE__*/Object.freeze({
|
|
81722
81733
|
__proto__: null,
|
|
@@ -82414,7 +82425,7 @@ const callbacks$1 = [];
|
|
|
82414
82425
|
function register(r) {
|
|
82415
82426
|
callbacks$1.forEach((callback) => callback(r));
|
|
82416
82427
|
}
|
|
82417
|
-
// version: 1.266.0-
|
|
82428
|
+
// version: 1.266.0-dev16-a54e7da01
|
|
82418
82429
|
|
|
82419
82430
|
/**
|
|
82420
82431
|
* Returns true if the value acts like a Promise, i.e. has a "then" function,
|
|
@@ -87319,4 +87330,4 @@ const { luvio } = getRuntime();
|
|
|
87319
87330
|
setDefaultLuvio({ luvio });
|
|
87320
87331
|
|
|
87321
87332
|
export { createPrimingSession, draftManager, draftQueue, evictCacheRecordsByIds, evictExpiredCacheEntries, executeAdapter, executeMutatingAdapter, getImperativeAdapterNames, invokeAdapter, invokeAdapterWithDraftToReplace, invokeAdapterWithMetadata, nimbusDraftQueue, registerReportObserver, setMetadataTTL, setUiApiRecordTTL, stopEviction, subscribeToAdapter };
|
|
87322
|
-
// version: 1.266.0-
|
|
87333
|
+
// version: 1.266.0-dev16-a54e7da01
|
|
@@ -4150,7 +4150,7 @@
|
|
|
4150
4150
|
}
|
|
4151
4151
|
callbacks.push(callback);
|
|
4152
4152
|
}
|
|
4153
|
-
// version: 1.266.0-
|
|
4153
|
+
// version: 1.266.0-dev16-a54e7da01
|
|
4154
4154
|
|
|
4155
4155
|
// TODO [TD-0081508]: once that TD is fulfilled we can probably change this file
|
|
4156
4156
|
function instrumentAdapter$1(createFunction, _metadata) {
|
|
@@ -15658,7 +15658,7 @@
|
|
|
15658
15658
|
}
|
|
15659
15659
|
return superResult;
|
|
15660
15660
|
}
|
|
15661
|
-
// version: 1.266.0-
|
|
15661
|
+
// version: 1.266.0-dev16-a54e7da01
|
|
15662
15662
|
|
|
15663
15663
|
function unwrap(data) {
|
|
15664
15664
|
// The lwc-luvio bindings import a function from lwc called "unwrap".
|
|
@@ -16583,7 +16583,7 @@
|
|
|
16583
16583
|
const { apiFamily, name } = metadata;
|
|
16584
16584
|
return createGraphQLWireAdapterConstructor$1(adapter, `${apiFamily}.${name}`, luvio, astResolver);
|
|
16585
16585
|
}
|
|
16586
|
-
// version: 1.266.0-
|
|
16586
|
+
// version: 1.266.0-dev16-a54e7da01
|
|
16587
16587
|
|
|
16588
16588
|
/**
|
|
16589
16589
|
* Copyright (c) 2022, Salesforce, Inc.,
|
|
@@ -43160,7 +43160,7 @@
|
|
|
43160
43160
|
throttle(60, 60000, createLDSAdapter(luvio, 'notifyListInfoUpdateAvailable', notifyUpdateAvailableFactory$1));
|
|
43161
43161
|
throttle(60, 60000, createLDSAdapter(luvio, 'notifyQuickActionDefaultsUpdateAvailable', notifyUpdateAvailableFactory));
|
|
43162
43162
|
});
|
|
43163
|
-
// version: 1.266.0-
|
|
43163
|
+
// version: 1.266.0-dev16-6c1030f29
|
|
43164
43164
|
|
|
43165
43165
|
var ldsIdempotencyWriteDisabled = {
|
|
43166
43166
|
isOpen: function (e) {
|
|
@@ -59915,6 +59915,7 @@
|
|
|
59915
59915
|
function buildFieldUnionArray(existingRecord, incomingRecord, objectInfo) {
|
|
59916
59916
|
const allFields = Array.from(new Set([...Object.keys(existingRecord.fields), ...Object.keys(incomingRecord.fields)]));
|
|
59917
59917
|
const fieldUnion = [];
|
|
59918
|
+
let includesSpanningFields = false;
|
|
59918
59919
|
allFields.forEach((fieldName) => {
|
|
59919
59920
|
const objectInfoField = objectInfo.fields[fieldName];
|
|
59920
59921
|
if (objectInfoField === undefined) {
|
|
@@ -59922,13 +59923,14 @@
|
|
|
59922
59923
|
const referenceField = findReferenceFieldForSpanningField(fieldName, objectInfo);
|
|
59923
59924
|
if (referenceField !== undefined) {
|
|
59924
59925
|
fieldUnion.push(`${fieldName}.Id`);
|
|
59926
|
+
includesSpanningFields = true;
|
|
59925
59927
|
}
|
|
59926
59928
|
}
|
|
59927
59929
|
else {
|
|
59928
59930
|
fieldUnion.push(fieldName);
|
|
59929
59931
|
}
|
|
59930
59932
|
});
|
|
59931
|
-
return fieldUnion;
|
|
59933
|
+
return { fields: fieldUnion, includesSpanningFields };
|
|
59932
59934
|
}
|
|
59933
59935
|
/**
|
|
59934
59936
|
* Merges (if possible) an incoming record from a priming session with an existing record in the durable store.
|
|
@@ -59960,7 +59962,7 @@
|
|
|
59960
59962
|
ok: false,
|
|
59961
59963
|
code: 'conflict-drafts',
|
|
59962
59964
|
hasDraft: true,
|
|
59963
|
-
fieldUnion: buildFieldUnionArray(existingRecord, incomingRecord, objectInfo),
|
|
59965
|
+
fieldUnion: buildFieldUnionArray(existingRecord, incomingRecord, objectInfo).fields,
|
|
59964
59966
|
};
|
|
59965
59967
|
}
|
|
59966
59968
|
// Check if incoming record's Etag is equal to the existing one
|
|
@@ -60022,10 +60024,19 @@
|
|
|
60022
60024
|
};
|
|
60023
60025
|
}
|
|
60024
60026
|
// If Etags do not match and the incoming record does not contain all fields, re-request the record
|
|
60027
|
+
const { fields, includesSpanningFields } = buildFieldUnionArray(existingRecord, incomingRecord, objectInfo);
|
|
60028
|
+
if (includesSpanningFields) {
|
|
60029
|
+
return {
|
|
60030
|
+
ok: false,
|
|
60031
|
+
code: 'conflict-spanning-record',
|
|
60032
|
+
fieldUnion: fields,
|
|
60033
|
+
hasDraft: false,
|
|
60034
|
+
};
|
|
60035
|
+
}
|
|
60025
60036
|
return {
|
|
60026
60037
|
ok: false,
|
|
60027
60038
|
code: 'conflict-missing-fields',
|
|
60028
|
-
fieldUnion:
|
|
60039
|
+
fieldUnion: fields,
|
|
60029
60040
|
hasDraft: false,
|
|
60030
60041
|
};
|
|
60031
60042
|
}
|
|
@@ -61073,7 +61084,7 @@
|
|
|
61073
61084
|
id: '@salesforce/lds-network-adapter',
|
|
61074
61085
|
instrument: instrument$2,
|
|
61075
61086
|
});
|
|
61076
|
-
// version: 1.266.0-
|
|
61087
|
+
// version: 1.266.0-dev16-a54e7da01
|
|
61077
61088
|
|
|
61078
61089
|
const { create: create$3, keys: keys$3 } = Object;
|
|
61079
61090
|
const { stringify: stringify$1, parse: parse$1 } = JSON;
|
|
@@ -79468,7 +79479,7 @@
|
|
|
79468
79479
|
configuration: { ...configurationForGraphQLAdapters$1 },
|
|
79469
79480
|
instrument: instrument$1,
|
|
79470
79481
|
});
|
|
79471
|
-
// version: 1.266.0-
|
|
79482
|
+
// version: 1.266.0-dev16-6c1030f29
|
|
79472
79483
|
|
|
79473
79484
|
// On core the unstable adapters are re-exported with different names,
|
|
79474
79485
|
// we want to match them here.
|
|
@@ -81722,7 +81733,7 @@
|
|
|
81722
81733
|
unstable_graphQL_imperative = createImperativeAdapter(luvio, createInstrumentedAdapter(ldsAdapter, adapterMetadata), adapterMetadata);
|
|
81723
81734
|
graphQLImperative = ldsAdapter;
|
|
81724
81735
|
});
|
|
81725
|
-
// version: 1.266.0-
|
|
81736
|
+
// version: 1.266.0-dev16-6c1030f29
|
|
81726
81737
|
|
|
81727
81738
|
var gqlApi = /*#__PURE__*/Object.freeze({
|
|
81728
81739
|
__proto__: null,
|
|
@@ -82420,7 +82431,7 @@
|
|
|
82420
82431
|
function register(r) {
|
|
82421
82432
|
callbacks$1.forEach((callback) => callback(r));
|
|
82422
82433
|
}
|
|
82423
|
-
// version: 1.266.0-
|
|
82434
|
+
// version: 1.266.0-dev16-a54e7da01
|
|
82424
82435
|
|
|
82425
82436
|
/**
|
|
82426
82437
|
* Returns true if the value acts like a Promise, i.e. has a "then" function,
|
|
@@ -87343,4 +87354,4 @@
|
|
|
87343
87354
|
exports.subscribeToAdapter = subscribeToAdapter;
|
|
87344
87355
|
|
|
87345
87356
|
}));
|
|
87346
|
-
// version: 1.266.0-
|
|
87357
|
+
// version: 1.266.0-dev16-a54e7da01
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@salesforce/lds-worker-api",
|
|
3
|
-
"version": "1.266.0-
|
|
3
|
+
"version": "1.266.0-dev16",
|
|
4
4
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
5
5
|
"description": "",
|
|
6
6
|
"main": "dist/standalone/es/lds-worker-api.js",
|
|
@@ -35,15 +35,15 @@
|
|
|
35
35
|
},
|
|
36
36
|
"devDependencies": {
|
|
37
37
|
"@oat-sa/rollup-plugin-wildcard-external": "^1.0.0",
|
|
38
|
-
"@salesforce/lds-adapters-graphql": "^1.266.0-
|
|
39
|
-
"@salesforce/lds-adapters-uiapi": "^1.266.0-
|
|
40
|
-
"@salesforce/lds-default-luvio": "^1.266.0-
|
|
41
|
-
"@salesforce/lds-drafts": "^1.266.0-
|
|
42
|
-
"@salesforce/lds-graphql-parser": "^1.266.0-
|
|
43
|
-
"@salesforce/lds-luvio-engine": "^1.266.0-
|
|
44
|
-
"@salesforce/lds-priming": "^1.266.0-
|
|
45
|
-
"@salesforce/lds-runtime-mobile": "^1.266.0-
|
|
46
|
-
"@salesforce/nimbus-plugin-lds": "^1.266.0-
|
|
38
|
+
"@salesforce/lds-adapters-graphql": "^1.266.0-dev16",
|
|
39
|
+
"@salesforce/lds-adapters-uiapi": "^1.266.0-dev16",
|
|
40
|
+
"@salesforce/lds-default-luvio": "^1.266.0-dev16",
|
|
41
|
+
"@salesforce/lds-drafts": "^1.266.0-dev16",
|
|
42
|
+
"@salesforce/lds-graphql-parser": "^1.266.0-dev16",
|
|
43
|
+
"@salesforce/lds-luvio-engine": "^1.266.0-dev16",
|
|
44
|
+
"@salesforce/lds-priming": "^1.266.0-dev16",
|
|
45
|
+
"@salesforce/lds-runtime-mobile": "^1.266.0-dev16",
|
|
46
|
+
"@salesforce/nimbus-plugin-lds": "^1.266.0-dev16",
|
|
47
47
|
"ajv": "^8.11.0",
|
|
48
48
|
"glob": "^7.1.5",
|
|
49
49
|
"nimbus-types": "^2.0.0-alpha1",
|