@salesforce/lds-ads-bridge 1.306.0 → 1.307.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 +9 -12
- package/dist/adsBridge.js +8 -11
- package/dist/types/ads-bridge.d.ts +0 -1
- package/package.json +3 -3
- package/src/ads-bridge.ts +12 -13
package/dist/ads-bridge-perf.js
CHANGED
|
@@ -481,7 +481,7 @@ const callbacks$1 = [];
|
|
|
481
481
|
function register(r) {
|
|
482
482
|
callbacks$1.forEach((callback) => callback(r));
|
|
483
483
|
}
|
|
484
|
-
// version: 1.
|
|
484
|
+
// version: 1.307.0-1e74878a83
|
|
485
485
|
|
|
486
486
|
/**
|
|
487
487
|
* Returns true if the value acts like a Promise, i.e. has a "then" function,
|
|
@@ -9245,27 +9245,24 @@ const { keys } = Object;
|
|
|
9245
9245
|
const { hasOwnProperty } = Object.prototype;
|
|
9246
9246
|
const { parse, stringify } = JSON;
|
|
9247
9247
|
|
|
9248
|
-
// The below imports were changed in W-15596354 to be imported from '@salesforce/lds-uipai-record-utils-mobile' which caused graphQL to be bundled
|
|
9249
|
-
// resulting in the module size greatly increasing: https://gus.lightning.force.com/lightning/r/ADM_Work__c/a07EE00001wIJcBYAW/view. Therefore,
|
|
9250
|
-
// the fix is to just include these values directly instead of importing.
|
|
9251
|
-
const API_NAMESPACE = 'UiApi';
|
|
9252
|
-
const RECORD_REPRESENTATION_NAME = 'RecordRepresentation';
|
|
9253
|
-
const RECORD_ID_PREFIX = `${API_NAMESPACE}::${RECORD_REPRESENTATION_NAME}:`;
|
|
9254
|
-
const RECORD_FIELDS_KEY_JUNCTION = '__fields__';
|
|
9255
|
-
function isStoreKeyRecordId(key) {
|
|
9256
|
-
return key.indexOf(RECORD_ID_PREFIX) > -1 && key.indexOf(RECORD_FIELDS_KEY_JUNCTION) === -1;
|
|
9257
|
-
}
|
|
9258
9248
|
// No need to pass the actual record key `luvio.ingestStore`. The `RecordRepresentation.ts#ingest`
|
|
9259
9249
|
// function extracts the appropriate record id from the ingested record.
|
|
9260
9250
|
const INGEST_KEY = '';
|
|
9261
9251
|
const MAIN_RECORD_TYPE_ID = '012000000000000AAA';
|
|
9262
9252
|
const DMO_API_NAME_SUFFIX = '__dlm';
|
|
9253
|
+
const API_NAMESPACE = 'UiApi';
|
|
9254
|
+
const RECORD_REPRESENTATION_NAME = 'RecordRepresentation';
|
|
9255
|
+
const RECORD_ID_PREFIX = `${API_NAMESPACE}::${RECORD_REPRESENTATION_NAME}:`;
|
|
9256
|
+
const RECORD_FIELDS_KEY_JUNCTION = '__fields__';
|
|
9263
9257
|
function isGraphNode(node) {
|
|
9264
9258
|
return node !== null && node.type === 'Node';
|
|
9265
9259
|
}
|
|
9266
9260
|
function isSpanningRecord(fieldValue) {
|
|
9267
9261
|
return fieldValue !== null && typeof fieldValue === 'object';
|
|
9268
9262
|
}
|
|
9263
|
+
function isStoreKeyRecordId(key) {
|
|
9264
|
+
return key.indexOf(RECORD_ID_PREFIX) > -1 && key.indexOf(RECORD_FIELDS_KEY_JUNCTION) === -1;
|
|
9265
|
+
}
|
|
9269
9266
|
/**
|
|
9270
9267
|
* Returns a shallow copy of a record with its field values if it is a scalar and a reference and a
|
|
9271
9268
|
* a RecordRepresentation with no field if the value if a spanning record.
|
|
@@ -9544,4 +9541,4 @@ class AdsBridge {
|
|
|
9544
9541
|
}
|
|
9545
9542
|
}
|
|
9546
9543
|
|
|
9547
|
-
export { AdsBridge as default, isDMOEntity
|
|
9544
|
+
export { AdsBridge as default, isDMOEntity };
|
package/dist/adsBridge.js
CHANGED
|
@@ -40,27 +40,24 @@ function instrument(newInstrumentation) {
|
|
|
40
40
|
instrumentation = Object.assign(instrumentation, newInstrumentation);
|
|
41
41
|
}
|
|
42
42
|
|
|
43
|
-
// The below imports were changed in W-15596354 to be imported from '@salesforce/lds-uipai-record-utils-mobile' which caused graphQL to be bundled
|
|
44
|
-
// resulting in the module size greatly increasing: https://gus.lightning.force.com/lightning/r/ADM_Work__c/a07EE00001wIJcBYAW/view. Therefore,
|
|
45
|
-
// the fix is to just include these values directly instead of importing.
|
|
46
|
-
const API_NAMESPACE = 'UiApi';
|
|
47
|
-
const RECORD_REPRESENTATION_NAME = 'RecordRepresentation';
|
|
48
|
-
const RECORD_ID_PREFIX = `${API_NAMESPACE}::${RECORD_REPRESENTATION_NAME}:`;
|
|
49
|
-
const RECORD_FIELDS_KEY_JUNCTION = '__fields__';
|
|
50
|
-
function isStoreKeyRecordId(key) {
|
|
51
|
-
return key.indexOf(RECORD_ID_PREFIX) > -1 && key.indexOf(RECORD_FIELDS_KEY_JUNCTION) === -1;
|
|
52
|
-
}
|
|
53
43
|
// No need to pass the actual record key `luvio.ingestStore`. The `RecordRepresentation.ts#ingest`
|
|
54
44
|
// function extracts the appropriate record id from the ingested record.
|
|
55
45
|
const INGEST_KEY = '';
|
|
56
46
|
const MAIN_RECORD_TYPE_ID = '012000000000000AAA';
|
|
57
47
|
const DMO_API_NAME_SUFFIX = '__dlm';
|
|
48
|
+
const API_NAMESPACE = 'UiApi';
|
|
49
|
+
const RECORD_REPRESENTATION_NAME = 'RecordRepresentation';
|
|
50
|
+
const RECORD_ID_PREFIX = `${API_NAMESPACE}::${RECORD_REPRESENTATION_NAME}:`;
|
|
51
|
+
const RECORD_FIELDS_KEY_JUNCTION = '__fields__';
|
|
58
52
|
function isGraphNode(node) {
|
|
59
53
|
return node !== null && node.type === 'Node';
|
|
60
54
|
}
|
|
61
55
|
function isSpanningRecord(fieldValue) {
|
|
62
56
|
return fieldValue !== null && typeof fieldValue === 'object';
|
|
63
57
|
}
|
|
58
|
+
function isStoreKeyRecordId(key) {
|
|
59
|
+
return key.indexOf(RECORD_ID_PREFIX) > -1 && key.indexOf(RECORD_FIELDS_KEY_JUNCTION) === -1;
|
|
60
|
+
}
|
|
64
61
|
/**
|
|
65
62
|
* Returns a shallow copy of a record with its field values if it is a scalar and a reference and a
|
|
66
63
|
* a RecordRepresentation with no field if the value if a spanning record.
|
|
@@ -370,4 +367,4 @@ function withAdsBridge(callback) {
|
|
|
370
367
|
}
|
|
371
368
|
|
|
372
369
|
export { instrument, withAdsBridge };
|
|
373
|
-
// version: 1.
|
|
370
|
+
// version: 1.307.0-1e74878a83
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import type { Luvio } from '@luvio/engine';
|
|
2
2
|
import type { RecordRepresentation } from '@salesforce/lds-adapters-uiapi';
|
|
3
|
-
export declare function isStoreKeyRecordId(key: string): boolean;
|
|
4
3
|
interface AdsRecord {
|
|
5
4
|
/**
|
|
6
5
|
* True if the passed record is a primary record, otherwise false.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@salesforce/lds-ads-bridge",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.307.0",
|
|
4
4
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
5
5
|
"description": "Bridge to sync data between LDS and ADS",
|
|
6
6
|
"main": "dist/adsBridge.js",
|
|
@@ -30,8 +30,8 @@
|
|
|
30
30
|
"release:corejar": "yarn build && ../core-build/scripts/core.js --name=lds-ads-bridge"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
|
33
|
-
"@salesforce/lds-adapters-uiapi": "^1.
|
|
34
|
-
"@salesforce/lds-uiapi-record-utils-mobile": "^1.
|
|
33
|
+
"@salesforce/lds-adapters-uiapi": "^1.307.0",
|
|
34
|
+
"@salesforce/lds-uiapi-record-utils-mobile": "^1.307.0"
|
|
35
35
|
},
|
|
36
36
|
"volta": {
|
|
37
37
|
"extends": "../../package.json"
|
package/src/ads-bridge.ts
CHANGED
|
@@ -27,19 +27,6 @@ import {
|
|
|
27
27
|
} from './utils/metric-keys';
|
|
28
28
|
import { instrumentation } from './instrumentation';
|
|
29
29
|
|
|
30
|
-
// The below imports were changed in W-15596354 to be imported from '@salesforce/lds-uipai-record-utils-mobile' which caused graphQL to be bundled
|
|
31
|
-
// resulting in the module size greatly increasing: https://gus.lightning.force.com/lightning/r/ADM_Work__c/a07EE00001wIJcBYAW/view. Therefore,
|
|
32
|
-
// the fix is to just include these values directly instead of importing.
|
|
33
|
-
|
|
34
|
-
const API_NAMESPACE = 'UiApi';
|
|
35
|
-
const RECORD_REPRESENTATION_NAME = 'RecordRepresentation';
|
|
36
|
-
const RECORD_ID_PREFIX = `${API_NAMESPACE}::${RECORD_REPRESENTATION_NAME}:`;
|
|
37
|
-
const RECORD_FIELDS_KEY_JUNCTION = '__fields__';
|
|
38
|
-
|
|
39
|
-
export function isStoreKeyRecordId(key: string) {
|
|
40
|
-
return key.indexOf(RECORD_ID_PREFIX) > -1 && key.indexOf(RECORD_FIELDS_KEY_JUNCTION) === -1;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
30
|
// No need to pass the actual record key `luvio.ingestStore`. The `RecordRepresentation.ts#ingest`
|
|
44
31
|
// function extracts the appropriate record id from the ingested record.
|
|
45
32
|
const INGEST_KEY = '';
|
|
@@ -48,6 +35,14 @@ const MAIN_RECORD_TYPE_ID = '012000000000000AAA';
|
|
|
48
35
|
|
|
49
36
|
const DMO_API_NAME_SUFFIX = '__dlm';
|
|
50
37
|
|
|
38
|
+
const API_NAMESPACE = 'UiApi';
|
|
39
|
+
|
|
40
|
+
const RECORD_REPRESENTATION_NAME = 'RecordRepresentation';
|
|
41
|
+
|
|
42
|
+
const RECORD_ID_PREFIX = `${API_NAMESPACE}::${RECORD_REPRESENTATION_NAME}:`;
|
|
43
|
+
|
|
44
|
+
const RECORD_FIELDS_KEY_JUNCTION = '__fields__';
|
|
45
|
+
|
|
51
46
|
type Unsubscribe = () => void;
|
|
52
47
|
|
|
53
48
|
interface AdsRecord {
|
|
@@ -104,6 +99,10 @@ function isSpanningRecord(
|
|
|
104
99
|
return fieldValue !== null && typeof fieldValue === 'object';
|
|
105
100
|
}
|
|
106
101
|
|
|
102
|
+
function isStoreKeyRecordId(key: string) {
|
|
103
|
+
return key.indexOf(RECORD_ID_PREFIX) > -1 && key.indexOf(RECORD_FIELDS_KEY_JUNCTION) === -1;
|
|
104
|
+
}
|
|
105
|
+
|
|
107
106
|
/**
|
|
108
107
|
* Returns a shallow copy of a record with its field values if it is a scalar and a reference and a
|
|
109
108
|
* a RecordRepresentation with no field if the value if a spanning record.
|