@salesforce/lds-worker-api 1.354.0-dev21 → 1.354.0-dev22
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.
|
@@ -1128,4 +1128,4 @@ if (process.env.NODE_ENV !== 'production') {
|
|
|
1128
1128
|
}
|
|
1129
1129
|
|
|
1130
1130
|
export { createPrimingSession, draftManager, draftQueue, evictCacheRecordsByIds, evictExpiredCacheEntries, executeAdapter, executeMutatingAdapter, getImperativeAdapterNames, invokeAdapter, invokeAdapterWithDraftToMerge, invokeAdapterWithDraftToReplace, invokeAdapterWithMetadata, nimbusDraftQueue, setMetadataTTL, setUiApiRecordTTL, stopEviction, subscribeToAdapter };
|
|
1131
|
-
// version: 1.354.0-
|
|
1131
|
+
// version: 1.354.0-dev22-5cd80216e4
|
|
@@ -4274,7 +4274,7 @@ function withDefaultLuvio(callback) {
|
|
|
4274
4274
|
}
|
|
4275
4275
|
callbacks.push(callback);
|
|
4276
4276
|
}
|
|
4277
|
-
// version: 1.354.0-
|
|
4277
|
+
// version: 1.354.0-dev22-5cd80216e4
|
|
4278
4278
|
|
|
4279
4279
|
// TODO [TD-0081508]: once that TD is fulfilled we can probably change this file
|
|
4280
4280
|
function instrumentAdapter$1(createFunction, _metadata) {
|
|
@@ -5286,7 +5286,7 @@ function createGraphQLWireAdapterConstructor(luvio, adapter, metadata, astResolv
|
|
|
5286
5286
|
const { apiFamily, name } = metadata;
|
|
5287
5287
|
return createGraphQLWireAdapterConstructor$1(adapter, `${apiFamily}.${name}`, luvio, astResolver);
|
|
5288
5288
|
}
|
|
5289
|
-
// version: 1.354.0-
|
|
5289
|
+
// version: 1.354.0-dev22-5cd80216e4
|
|
5290
5290
|
|
|
5291
5291
|
/**
|
|
5292
5292
|
* Copyright (c) 2022, Salesforce, Inc.,
|
|
@@ -34085,7 +34085,7 @@ withDefaultLuvio((luvio) => {
|
|
|
34085
34085
|
throttle(60, 60000, setupNotifyAllListRecordUpdateAvailable(luvio));
|
|
34086
34086
|
throttle(60, 60000, setupNotifyAllListInfoSummaryUpdateAvailable(luvio));
|
|
34087
34087
|
});
|
|
34088
|
-
// version: 1.354.0-
|
|
34088
|
+
// version: 1.354.0-dev22-337fdb817f
|
|
34089
34089
|
|
|
34090
34090
|
function requestIdleDetectedCallback(_callback) { }
|
|
34091
34091
|
function declareNotifierTaskSingle(_name) {
|
|
@@ -80552,8 +80552,44 @@ function reportChunkCandidateUrlLength(urlLength) {
|
|
|
80552
80552
|
ldsMobileInstrumentation$2.bucketValue('chunk-candidate-url-length-histogram', urlLength, buckets);
|
|
80553
80553
|
}
|
|
80554
80554
|
|
|
80555
|
+
class AbstractQuickActionHandler extends AbstractResourceRequestActionHandler {
|
|
80556
|
+
constructor(draftQueue, networkAdapter, getLuvio, recordService) {
|
|
80557
|
+
super(draftQueue, networkAdapter, getLuvio, recordService);
|
|
80558
|
+
}
|
|
80559
|
+
async buildPendingAction(request, queue) {
|
|
80560
|
+
this.resolveResourceRequestBody(request.body);
|
|
80561
|
+
return await super.buildPendingAction(request, queue);
|
|
80562
|
+
}
|
|
80563
|
+
resolveResourceRequestBody(body) {
|
|
80564
|
+
let contextId = body.contextId;
|
|
80565
|
+
if (contextId && this.isDraftId(contextId)) {
|
|
80566
|
+
const draftKey = getRecordKeyForId(this.getLuvio(), contextId);
|
|
80567
|
+
const canonicalKey = this.getLuvio().storeGetCanonicalKey(draftKey);
|
|
80568
|
+
if (draftKey !== canonicalKey) {
|
|
80569
|
+
const canonicalId = extractRecordIdFromStoreKey$1(canonicalKey);
|
|
80570
|
+
if (canonicalId !== undefined) {
|
|
80571
|
+
body.contextId = canonicalId;
|
|
80572
|
+
}
|
|
80573
|
+
}
|
|
80574
|
+
}
|
|
80575
|
+
for (const field of keys$2$1(body.fields)) {
|
|
80576
|
+
const fieldValue = body.fields[field];
|
|
80577
|
+
if (typeof fieldValue === 'string' && this.isDraftId(fieldValue)) {
|
|
80578
|
+
const draftKey = getRecordKeyForId(this.getLuvio(), fieldValue);
|
|
80579
|
+
const canonicalKey = this.getLuvio().storeGetCanonicalKey(draftKey);
|
|
80580
|
+
if (draftKey !== canonicalKey) {
|
|
80581
|
+
const canonicalId = extractRecordIdFromStoreKey$1(canonicalKey);
|
|
80582
|
+
if (canonicalId !== undefined) {
|
|
80583
|
+
body.fields[field] = canonicalId;
|
|
80584
|
+
}
|
|
80585
|
+
}
|
|
80586
|
+
}
|
|
80587
|
+
}
|
|
80588
|
+
}
|
|
80589
|
+
}
|
|
80590
|
+
|
|
80555
80591
|
const QUICK_ACTION_HANDLER = 'QUICK_ACTION_HANDLER';
|
|
80556
|
-
class QuickActionExecutionRepresentationHandler extends
|
|
80592
|
+
class QuickActionExecutionRepresentationHandler extends AbstractQuickActionHandler {
|
|
80557
80593
|
constructor(getLuvio, draftRecordService, draftQueue, networkAdapter, isDraftId, sideEffectService, objectInfoService, getRecord) {
|
|
80558
80594
|
super(draftQueue, networkAdapter, getLuvio, draftRecordService);
|
|
80559
80595
|
this.draftRecordService = draftRecordService;
|
|
@@ -80639,7 +80675,7 @@ class QuickActionExecutionRepresentationHandler extends AbstractResourceRequestA
|
|
|
80639
80675
|
}
|
|
80640
80676
|
|
|
80641
80677
|
const UPDATE_RECORD_QUICK_ACTION_HANDLER = 'UPDATE_RECORD_QUICK_ACTION_HANDLER';
|
|
80642
|
-
class UpdateRecordQuickActionExecutionRepresentationHandler extends
|
|
80678
|
+
class UpdateRecordQuickActionExecutionRepresentationHandler extends AbstractQuickActionHandler {
|
|
80643
80679
|
constructor(getLuvio, draftRecordService, draftQueue, networkAdapter, isDraftId, sideEffectService) {
|
|
80644
80680
|
super(draftQueue, networkAdapter, getLuvio, draftRecordService);
|
|
80645
80681
|
this.draftRecordService = draftRecordService;
|
|
@@ -93389,7 +93425,7 @@ register$1({
|
|
|
93389
93425
|
id: '@salesforce/lds-network-adapter',
|
|
93390
93426
|
instrument: instrument$2,
|
|
93391
93427
|
});
|
|
93392
|
-
// version: 1.354.0-
|
|
93428
|
+
// version: 1.354.0-dev22-5cd80216e4
|
|
93393
93429
|
|
|
93394
93430
|
const { create: create$2, keys: keys$2 } = Object;
|
|
93395
93431
|
const { stringify, parse } = JSON;
|
|
@@ -118026,7 +118062,7 @@ register$1({
|
|
|
118026
118062
|
configuration: { ...configurationForGraphQLAdapters$1 },
|
|
118027
118063
|
instrument: instrument$1,
|
|
118028
118064
|
});
|
|
118029
|
-
// version: 1.354.0-
|
|
118065
|
+
// version: 1.354.0-dev22-337fdb817f
|
|
118030
118066
|
|
|
118031
118067
|
// On core the unstable adapters are re-exported with different names,
|
|
118032
118068
|
// we want to match them here.
|
|
@@ -118178,7 +118214,7 @@ withDefaultLuvio((luvio) => {
|
|
|
118178
118214
|
unstable_graphQL_imperative = createImperativeAdapter(luvio, createInstrumentedAdapter(ldsAdapter, adapterMetadata), adapterMetadata);
|
|
118179
118215
|
graphQLImperative = ldsAdapter;
|
|
118180
118216
|
});
|
|
118181
|
-
// version: 1.354.0-
|
|
118217
|
+
// version: 1.354.0-dev22-337fdb817f
|
|
118182
118218
|
|
|
118183
118219
|
var gqlApi = /*#__PURE__*/Object.freeze({
|
|
118184
118220
|
__proto__: null,
|
|
@@ -118970,7 +119006,7 @@ const callbacks$1 = [];
|
|
|
118970
119006
|
function register(r) {
|
|
118971
119007
|
callbacks$1.forEach((callback) => callback(r));
|
|
118972
119008
|
}
|
|
118973
|
-
// version: 1.354.0-
|
|
119009
|
+
// version: 1.354.0-dev22-5cd80216e4
|
|
118974
119010
|
|
|
118975
119011
|
/**
|
|
118976
119012
|
* Copyright (c) 2022, Salesforce, Inc.,
|
|
@@ -120050,4 +120086,4 @@ const { luvio } = getRuntime();
|
|
|
120050
120086
|
setDefaultLuvio({ luvio });
|
|
120051
120087
|
|
|
120052
120088
|
export { createPrimingSession, draftManager, draftQueue, evictCacheRecordsByIds, evictExpiredCacheEntries, executeAdapter, executeMutatingAdapter, getImperativeAdapterNames, invokeAdapter, invokeAdapterWithDraftToMerge, invokeAdapterWithDraftToReplace, invokeAdapterWithMetadata, nimbusDraftQueue, registerReportObserver, setMetadataTTL, setUiApiRecordTTL, stopEviction, subscribeToAdapter };
|
|
120053
|
-
// version: 1.354.0-
|
|
120089
|
+
// version: 1.354.0-dev22-5cd80216e4
|
|
@@ -4280,7 +4280,7 @@
|
|
|
4280
4280
|
}
|
|
4281
4281
|
callbacks.push(callback);
|
|
4282
4282
|
}
|
|
4283
|
-
// version: 1.354.0-
|
|
4283
|
+
// version: 1.354.0-dev22-5cd80216e4
|
|
4284
4284
|
|
|
4285
4285
|
// TODO [TD-0081508]: once that TD is fulfilled we can probably change this file
|
|
4286
4286
|
function instrumentAdapter$1(createFunction, _metadata) {
|
|
@@ -5292,7 +5292,7 @@
|
|
|
5292
5292
|
const { apiFamily, name } = metadata;
|
|
5293
5293
|
return createGraphQLWireAdapterConstructor$1(adapter, `${apiFamily}.${name}`, luvio, astResolver);
|
|
5294
5294
|
}
|
|
5295
|
-
// version: 1.354.0-
|
|
5295
|
+
// version: 1.354.0-dev22-5cd80216e4
|
|
5296
5296
|
|
|
5297
5297
|
/**
|
|
5298
5298
|
* Copyright (c) 2022, Salesforce, Inc.,
|
|
@@ -34091,7 +34091,7 @@
|
|
|
34091
34091
|
throttle(60, 60000, setupNotifyAllListRecordUpdateAvailable(luvio));
|
|
34092
34092
|
throttle(60, 60000, setupNotifyAllListInfoSummaryUpdateAvailable(luvio));
|
|
34093
34093
|
});
|
|
34094
|
-
// version: 1.354.0-
|
|
34094
|
+
// version: 1.354.0-dev22-337fdb817f
|
|
34095
34095
|
|
|
34096
34096
|
function requestIdleDetectedCallback(_callback) { }
|
|
34097
34097
|
function declareNotifierTaskSingle(_name) {
|
|
@@ -80558,8 +80558,44 @@
|
|
|
80558
80558
|
ldsMobileInstrumentation$2.bucketValue('chunk-candidate-url-length-histogram', urlLength, buckets);
|
|
80559
80559
|
}
|
|
80560
80560
|
|
|
80561
|
+
class AbstractQuickActionHandler extends AbstractResourceRequestActionHandler {
|
|
80562
|
+
constructor(draftQueue, networkAdapter, getLuvio, recordService) {
|
|
80563
|
+
super(draftQueue, networkAdapter, getLuvio, recordService);
|
|
80564
|
+
}
|
|
80565
|
+
async buildPendingAction(request, queue) {
|
|
80566
|
+
this.resolveResourceRequestBody(request.body);
|
|
80567
|
+
return await super.buildPendingAction(request, queue);
|
|
80568
|
+
}
|
|
80569
|
+
resolveResourceRequestBody(body) {
|
|
80570
|
+
let contextId = body.contextId;
|
|
80571
|
+
if (contextId && this.isDraftId(contextId)) {
|
|
80572
|
+
const draftKey = getRecordKeyForId(this.getLuvio(), contextId);
|
|
80573
|
+
const canonicalKey = this.getLuvio().storeGetCanonicalKey(draftKey);
|
|
80574
|
+
if (draftKey !== canonicalKey) {
|
|
80575
|
+
const canonicalId = extractRecordIdFromStoreKey$1(canonicalKey);
|
|
80576
|
+
if (canonicalId !== undefined) {
|
|
80577
|
+
body.contextId = canonicalId;
|
|
80578
|
+
}
|
|
80579
|
+
}
|
|
80580
|
+
}
|
|
80581
|
+
for (const field of keys$2$1(body.fields)) {
|
|
80582
|
+
const fieldValue = body.fields[field];
|
|
80583
|
+
if (typeof fieldValue === 'string' && this.isDraftId(fieldValue)) {
|
|
80584
|
+
const draftKey = getRecordKeyForId(this.getLuvio(), fieldValue);
|
|
80585
|
+
const canonicalKey = this.getLuvio().storeGetCanonicalKey(draftKey);
|
|
80586
|
+
if (draftKey !== canonicalKey) {
|
|
80587
|
+
const canonicalId = extractRecordIdFromStoreKey$1(canonicalKey);
|
|
80588
|
+
if (canonicalId !== undefined) {
|
|
80589
|
+
body.fields[field] = canonicalId;
|
|
80590
|
+
}
|
|
80591
|
+
}
|
|
80592
|
+
}
|
|
80593
|
+
}
|
|
80594
|
+
}
|
|
80595
|
+
}
|
|
80596
|
+
|
|
80561
80597
|
const QUICK_ACTION_HANDLER = 'QUICK_ACTION_HANDLER';
|
|
80562
|
-
class QuickActionExecutionRepresentationHandler extends
|
|
80598
|
+
class QuickActionExecutionRepresentationHandler extends AbstractQuickActionHandler {
|
|
80563
80599
|
constructor(getLuvio, draftRecordService, draftQueue, networkAdapter, isDraftId, sideEffectService, objectInfoService, getRecord) {
|
|
80564
80600
|
super(draftQueue, networkAdapter, getLuvio, draftRecordService);
|
|
80565
80601
|
this.draftRecordService = draftRecordService;
|
|
@@ -80645,7 +80681,7 @@
|
|
|
80645
80681
|
}
|
|
80646
80682
|
|
|
80647
80683
|
const UPDATE_RECORD_QUICK_ACTION_HANDLER = 'UPDATE_RECORD_QUICK_ACTION_HANDLER';
|
|
80648
|
-
class UpdateRecordQuickActionExecutionRepresentationHandler extends
|
|
80684
|
+
class UpdateRecordQuickActionExecutionRepresentationHandler extends AbstractQuickActionHandler {
|
|
80649
80685
|
constructor(getLuvio, draftRecordService, draftQueue, networkAdapter, isDraftId, sideEffectService) {
|
|
80650
80686
|
super(draftQueue, networkAdapter, getLuvio, draftRecordService);
|
|
80651
80687
|
this.draftRecordService = draftRecordService;
|
|
@@ -93395,7 +93431,7 @@
|
|
|
93395
93431
|
id: '@salesforce/lds-network-adapter',
|
|
93396
93432
|
instrument: instrument$2,
|
|
93397
93433
|
});
|
|
93398
|
-
// version: 1.354.0-
|
|
93434
|
+
// version: 1.354.0-dev22-5cd80216e4
|
|
93399
93435
|
|
|
93400
93436
|
const { create: create$2, keys: keys$2 } = Object;
|
|
93401
93437
|
const { stringify, parse } = JSON;
|
|
@@ -118032,7 +118068,7 @@
|
|
|
118032
118068
|
configuration: { ...configurationForGraphQLAdapters$1 },
|
|
118033
118069
|
instrument: instrument$1,
|
|
118034
118070
|
});
|
|
118035
|
-
// version: 1.354.0-
|
|
118071
|
+
// version: 1.354.0-dev22-337fdb817f
|
|
118036
118072
|
|
|
118037
118073
|
// On core the unstable adapters are re-exported with different names,
|
|
118038
118074
|
// we want to match them here.
|
|
@@ -118184,7 +118220,7 @@
|
|
|
118184
118220
|
unstable_graphQL_imperative = createImperativeAdapter(luvio, createInstrumentedAdapter(ldsAdapter, adapterMetadata), adapterMetadata);
|
|
118185
118221
|
graphQLImperative = ldsAdapter;
|
|
118186
118222
|
});
|
|
118187
|
-
// version: 1.354.0-
|
|
118223
|
+
// version: 1.354.0-dev22-337fdb817f
|
|
118188
118224
|
|
|
118189
118225
|
var gqlApi = /*#__PURE__*/Object.freeze({
|
|
118190
118226
|
__proto__: null,
|
|
@@ -118976,7 +119012,7 @@
|
|
|
118976
119012
|
function register(r) {
|
|
118977
119013
|
callbacks$1.forEach((callback) => callback(r));
|
|
118978
119014
|
}
|
|
118979
|
-
// version: 1.354.0-
|
|
119015
|
+
// version: 1.354.0-dev22-5cd80216e4
|
|
118980
119016
|
|
|
118981
119017
|
/**
|
|
118982
119018
|
* Copyright (c) 2022, Salesforce, Inc.,
|
|
@@ -120075,4 +120111,4 @@
|
|
|
120075
120111
|
exports.subscribeToAdapter = subscribeToAdapter;
|
|
120076
120112
|
|
|
120077
120113
|
}));
|
|
120078
|
-
// version: 1.354.0-
|
|
120114
|
+
// version: 1.354.0-dev22-5cd80216e4
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@salesforce/lds-worker-api",
|
|
3
|
-
"version": "1.354.0-
|
|
3
|
+
"version": "1.354.0-dev22",
|
|
4
4
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
5
5
|
"description": "",
|
|
6
6
|
"main": "dist/standalone/es/lds-worker-api.js",
|
|
@@ -35,14 +35,14 @@
|
|
|
35
35
|
},
|
|
36
36
|
"devDependencies": {
|
|
37
37
|
"@oat-sa/rollup-plugin-wildcard-external": "^1.0.0",
|
|
38
|
-
"@salesforce/lds-adapters-graphql": "^1.354.0-
|
|
39
|
-
"@salesforce/lds-adapters-uiapi": "^1.354.0-
|
|
40
|
-
"@salesforce/lds-default-luvio": "^1.354.0-
|
|
41
|
-
"@salesforce/lds-drafts": "^1.354.0-
|
|
42
|
-
"@salesforce/lds-graphql-parser": "^1.354.0-
|
|
43
|
-
"@salesforce/lds-luvio-engine": "^1.354.0-
|
|
44
|
-
"@salesforce/lds-runtime-mobile": "^1.354.0-
|
|
45
|
-
"@salesforce/nimbus-plugin-lds": "^1.354.0-
|
|
38
|
+
"@salesforce/lds-adapters-graphql": "^1.354.0-dev22",
|
|
39
|
+
"@salesforce/lds-adapters-uiapi": "^1.354.0-dev22",
|
|
40
|
+
"@salesforce/lds-default-luvio": "^1.354.0-dev22",
|
|
41
|
+
"@salesforce/lds-drafts": "^1.354.0-dev22",
|
|
42
|
+
"@salesforce/lds-graphql-parser": "^1.354.0-dev22",
|
|
43
|
+
"@salesforce/lds-luvio-engine": "^1.354.0-dev22",
|
|
44
|
+
"@salesforce/lds-runtime-mobile": "^1.354.0-dev22",
|
|
45
|
+
"@salesforce/nimbus-plugin-lds": "^1.354.0-dev22",
|
|
46
46
|
"ajv": "^8.11.0",
|
|
47
47
|
"glob": "^7.1.5",
|
|
48
48
|
"nimbus-types": "^2.0.0-alpha1",
|