@salesforce/lds-runtime-bridge 1.290.0 → 1.291.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/ldsRuntimeBridge.js +34 -2
- package/package.json +8 -8
package/dist/ldsRuntimeBridge.js
CHANGED
|
@@ -3067,6 +3067,32 @@ async function readIngestionTimestampForKey(key, query) {
|
|
|
3067
3067
|
return ingestionTimestamp;
|
|
3068
3068
|
}
|
|
3069
3069
|
|
|
3070
|
+
// Code lifted from https://github.com/MaxArt2501/base64-js/blob/master/base64.js
|
|
3071
|
+
// base64 character set, plus padding character (=)
|
|
3072
|
+
const b64 = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=';
|
|
3073
|
+
function btoaPolyfill(input) {
|
|
3074
|
+
let bitmap, a, b, c;
|
|
3075
|
+
let result = '', i = 0;
|
|
3076
|
+
const rest = input.length % 3; // To determine the final padding
|
|
3077
|
+
for (; i < input.length;) {
|
|
3078
|
+
if ((a = input.charCodeAt(i++)) > 255 ||
|
|
3079
|
+
(b = input.charCodeAt(i++)) > 255 ||
|
|
3080
|
+
(c = input.charCodeAt(i++)) > 255) {
|
|
3081
|
+
throw new TypeError('Failed base64ToAscii encoding: The string to be encoded contains characters outside of the Latin1 range. ' +
|
|
3082
|
+
input);
|
|
3083
|
+
}
|
|
3084
|
+
bitmap = (a << 16) | (b << 8) | c;
|
|
3085
|
+
result +=
|
|
3086
|
+
b64.charAt((bitmap >> 18) & 63) +
|
|
3087
|
+
b64.charAt((bitmap >> 12) & 63) +
|
|
3088
|
+
b64.charAt((bitmap >> 6) & 63) +
|
|
3089
|
+
b64.charAt(bitmap & 63);
|
|
3090
|
+
}
|
|
3091
|
+
// If there's need of padding, replace the last 'A's with equal signs
|
|
3092
|
+
return rest ? result.slice(0, rest - 3) + '==='.substring(rest) : result;
|
|
3093
|
+
}
|
|
3094
|
+
const base64encode = typeof btoa === 'function' ? btoa : btoaPolyfill;
|
|
3095
|
+
|
|
3070
3096
|
function findSpanningField(name) {
|
|
3071
3097
|
return (field) => {
|
|
3072
3098
|
return (field.apiName === name ||
|
|
@@ -3348,6 +3374,11 @@ function addResolversToSchema(schema, polyFields) {
|
|
|
3348
3374
|
return { recordRepresentation, ingestionTimestamp };
|
|
3349
3375
|
};
|
|
3350
3376
|
}
|
|
3377
|
+
else if (field.name === 'cursor') {
|
|
3378
|
+
field.resolve = function ({ index }) {
|
|
3379
|
+
return base64encode(`v1:${index}`);
|
|
3380
|
+
};
|
|
3381
|
+
}
|
|
3351
3382
|
}
|
|
3352
3383
|
}
|
|
3353
3384
|
if (isRecordType(type)) {
|
|
@@ -3564,10 +3595,11 @@ async function connectionEdgeResolver(obj, _args, context) {
|
|
|
3564
3595
|
//map each sql result with the ingestion timestamp to pass it down a level
|
|
3565
3596
|
return results.rows
|
|
3566
3597
|
.map((row) => row[0])
|
|
3567
|
-
.map((record) => {
|
|
3598
|
+
.map((record, index) => {
|
|
3568
3599
|
return {
|
|
3569
3600
|
record,
|
|
3570
3601
|
ingestionTimestamp,
|
|
3602
|
+
index,
|
|
3571
3603
|
};
|
|
3572
3604
|
});
|
|
3573
3605
|
}
|
|
@@ -4101,4 +4133,4 @@ function ldsRuntimeBridge() {
|
|
|
4101
4133
|
}
|
|
4102
4134
|
|
|
4103
4135
|
export { ldsRuntimeBridge as default };
|
|
4104
|
-
// version: 1.
|
|
4136
|
+
// version: 1.291.0-8df6969f6
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@salesforce/lds-runtime-bridge",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.291.0",
|
|
4
4
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
5
5
|
"description": "LDS runtime for bridge.app.",
|
|
6
6
|
"main": "dist/ldsRuntimeBridge.js",
|
|
@@ -34,17 +34,17 @@
|
|
|
34
34
|
"release:corejar": "yarn build && ../core-build/scripts/core.js --name=lds-runtime-bridge"
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"@salesforce/lds-adapters-uiapi": "^1.
|
|
38
|
-
"@salesforce/lds-instrumentation": "^1.
|
|
37
|
+
"@salesforce/lds-adapters-uiapi": "^1.291.0",
|
|
38
|
+
"@salesforce/lds-instrumentation": "^1.291.0",
|
|
39
39
|
"@salesforce/user": "0.0.21",
|
|
40
40
|
"o11y": "250.7.0"
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
|
-
"@salesforce/lds-drafts-adapters-uiapi": "^1.
|
|
44
|
-
"@salesforce/lds-network-aura": "^1.
|
|
45
|
-
"@salesforce/lds-runtime-aura": "^1.
|
|
46
|
-
"@salesforce/lds-store-nimbus": "^1.
|
|
47
|
-
"@salesforce/nimbus-plugin-lds": "^1.
|
|
43
|
+
"@salesforce/lds-drafts-adapters-uiapi": "^1.291.0",
|
|
44
|
+
"@salesforce/lds-network-aura": "^1.291.0",
|
|
45
|
+
"@salesforce/lds-runtime-aura": "^1.291.0",
|
|
46
|
+
"@salesforce/lds-store-nimbus": "^1.291.0",
|
|
47
|
+
"@salesforce/nimbus-plugin-lds": "^1.291.0",
|
|
48
48
|
"babel-plugin-dynamic-import-node": "^2.3.3"
|
|
49
49
|
},
|
|
50
50
|
"luvioBundlesize": [
|