@salesforce/lds-runtime-mobile 1.241.0 → 1.242.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/main.js CHANGED
@@ -16,7 +16,7 @@ import { setupInstrumentation, instrumentAdapter as instrumentAdapter$1, instrum
16
16
  import { HttpStatusCode, StoreKeySet, serializeStructuredKey, StringKeyInMemoryStore, Reader, deepFreeze, emitAdapterEvent, createCustomAdapterEventEmitter, StoreKeyMap, isFileReference, Environment, Luvio, InMemoryStore } from '@luvio/engine';
17
17
  import excludeStaleRecordsGate from '@salesforce/gate/lds.graphqlEvalExcludeStaleRecords';
18
18
  import { parseAndVisit, Kind, visit, execute, buildSchema, isObjectType, defaultFieldResolver } from '@luvio/graphql-parser';
19
- import { getRecordId18, keyBuilderQuickActionExecutionRepresentation, ingestQuickActionExecutionRepresentation, keyBuilderContentDocumentCompositeRepresentation, getResponseCacheKeysContentDocumentCompositeRepresentation, keyBuilderFromTypeContentDocumentCompositeRepresentation, ingestContentDocumentCompositeRepresentation, keyBuilderRecord, getTypeCacheKeysRecord, keyBuilderFromTypeRecordRepresentation, ingestRecord, RecordRepresentationRepresentationType, ObjectInfoRepresentationType, getRecordAdapterFactory, getObjectInfoAdapterFactory, getObjectInfosAdapterFactory, UiApiNamespace, RecordRepresentationType, RecordRepresentationTTL, RecordRepresentationVersion, getRecordsAdapterFactory } from '@salesforce/lds-adapters-uiapi';
19
+ import { RECORD_ID_PREFIX, RECORD_FIELDS_KEY_JUNCTION, isStoreKeyRecordViewEntity, getRecordId18, RECORD_REPRESENTATION_NAME, extractRecordIdFromStoreKey, keyBuilderQuickActionExecutionRepresentation, ingestQuickActionExecutionRepresentation, keyBuilderContentDocumentCompositeRepresentation, getResponseCacheKeysContentDocumentCompositeRepresentation, keyBuilderFromTypeContentDocumentCompositeRepresentation, ingestContentDocumentCompositeRepresentation, keyBuilderRecord, RECORD_VIEW_ENTITY_ID_PREFIX, getTypeCacheKeysRecord, keyBuilderFromTypeRecordRepresentation, ingestRecord, RecordRepresentationRepresentationType, ObjectInfoRepresentationType, getRecordAdapterFactory, getObjectInfoAdapterFactory, getObjectInfosAdapterFactory, UiApiNamespace, RecordRepresentationType, RecordRepresentationTTL, RecordRepresentationVersion, getRecordsAdapterFactory } from '@salesforce/lds-adapters-uiapi';
20
20
  import caseSensitiveUserId from '@salesforce/user/Id';
21
21
  import { idleDetector, getInstrumentation } from 'o11y/client';
22
22
  import ldsUseShortUrlGate from '@salesforce/gate/lds.useShortUrl';
@@ -1578,30 +1578,13 @@ function makeDurable(environment, { durableStore, instrumentation, useRevivingSt
1578
1578
  * For full license text, see the LICENSE.txt file
1579
1579
  */
1580
1580
 
1581
- const API_NAMESPACE = 'UiApi';
1582
- const RECORD_REPRESENTATION_NAME = 'RecordRepresentation';
1583
- const RECORD_VIEW_ENTITY_REPRESENTATION_NAME = 'RecordViewEntityRepresentation';
1584
- const RECORD_ID_PREFIX = `${API_NAMESPACE}::${RECORD_REPRESENTATION_NAME}:`;
1585
- const RECORD_VIEW_ENTITY_ID_PREFIX = `${API_NAMESPACE}::${RECORD_VIEW_ENTITY_REPRESENTATION_NAME}:Name:`;
1586
- const RECORD_FIELDS_KEY_JUNCTION = '__fields__';
1581
+
1587
1582
  function isStoreKeyRecordId(key) {
1588
1583
  return key.indexOf(RECORD_ID_PREFIX) > -1 && key.indexOf(RECORD_FIELDS_KEY_JUNCTION) === -1;
1589
1584
  }
1590
- function isStoreKeyRecordViewEntity(key) {
1591
- return (key.indexOf(RECORD_VIEW_ENTITY_ID_PREFIX) > -1 &&
1592
- key.indexOf(RECORD_FIELDS_KEY_JUNCTION) === -1);
1593
- }
1594
1585
  function isStoreKeyRecordField(key) {
1595
1586
  return key.indexOf(RECORD_ID_PREFIX) > -1 && key.indexOf(RECORD_FIELDS_KEY_JUNCTION) > -1;
1596
1587
  }
1597
- function extractRecordIdFromStoreKey(key) {
1598
- if (key === undefined ||
1599
- (key.indexOf(RECORD_ID_PREFIX) === -1 && key.indexOf(RECORD_VIEW_ENTITY_ID_PREFIX) === -1)) {
1600
- return undefined;
1601
- }
1602
- const parts = key.split(':');
1603
- return parts[parts.length - 1].split('_')[0];
1604
- }
1605
1588
  function buildRecordFieldStoreKey(recordKey, fieldName) {
1606
1589
  return `${recordKey}${RECORD_FIELDS_KEY_JUNCTION}${fieldName}`;
1607
1590
  }
@@ -17063,4 +17046,4 @@ register({
17063
17046
  });
17064
17047
 
17065
17048
  export { getRuntime, registerReportObserver, reportGraphqlQueryParseError };
17066
- // version: 1.241.0-b14b649d4
17049
+ // version: 1.242.0-57237c3b6
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@salesforce/lds-runtime-mobile",
3
- "version": "1.241.0",
3
+ "version": "1.242.0",
4
4
  "license": "SEE LICENSE IN LICENSE.txt",
5
5
  "description": "LDS runtime for mobile/hybrid environments.",
6
6
  "main": "dist/main.js",
@@ -87,9 +87,9 @@
87
87
  "targets": {
88
88
  "build": {
89
89
  "outputs": [
90
- "packages/lds-runtime-mobile/dist",
91
- "packages/lds-runtime-mobile/sfdc",
92
- "packages/lds-runtime-mobile/src/__tests__/fixtures"
90
+ "{projectRoot}/dist",
91
+ "{projectRoot}/sfdc",
92
+ "{projectRoot}/src/__tests__/fixtures"
93
93
  ]
94
94
  }
95
95
  }
package/sfdc/main.js CHANGED
@@ -16,7 +16,7 @@ import { setupInstrumentation, instrumentAdapter as instrumentAdapter$1, instrum
16
16
  import { HttpStatusCode, StoreKeySet, serializeStructuredKey, StringKeyInMemoryStore, Reader, deepFreeze, emitAdapterEvent, createCustomAdapterEventEmitter, StoreKeyMap, isFileReference, Environment, Luvio, InMemoryStore } from 'force/luvioEngine';
17
17
  import excludeStaleRecordsGate from '@salesforce/gate/lds.graphqlEvalExcludeStaleRecords';
18
18
  import { parseAndVisit, Kind, visit, execute, buildSchema, isObjectType, defaultFieldResolver } from 'force/ldsGraphqlParser';
19
- import { getRecordId18, keyBuilderQuickActionExecutionRepresentation, ingestQuickActionExecutionRepresentation, keyBuilderContentDocumentCompositeRepresentation, getResponseCacheKeysContentDocumentCompositeRepresentation, keyBuilderFromTypeContentDocumentCompositeRepresentation, ingestContentDocumentCompositeRepresentation, keyBuilderRecord, getTypeCacheKeysRecord, keyBuilderFromTypeRecordRepresentation, ingestRecord, RecordRepresentationRepresentationType, ObjectInfoRepresentationType, getRecordAdapterFactory, getObjectInfoAdapterFactory, getObjectInfosAdapterFactory, UiApiNamespace, RecordRepresentationType, RecordRepresentationTTL, RecordRepresentationVersion, getRecordsAdapterFactory } from 'force/ldsAdaptersUiapi';
19
+ import { RECORD_ID_PREFIX, RECORD_FIELDS_KEY_JUNCTION, isStoreKeyRecordViewEntity, getRecordId18, RECORD_REPRESENTATION_NAME, extractRecordIdFromStoreKey, keyBuilderQuickActionExecutionRepresentation, ingestQuickActionExecutionRepresentation, keyBuilderContentDocumentCompositeRepresentation, getResponseCacheKeysContentDocumentCompositeRepresentation, keyBuilderFromTypeContentDocumentCompositeRepresentation, ingestContentDocumentCompositeRepresentation, keyBuilderRecord, RECORD_VIEW_ENTITY_ID_PREFIX, getTypeCacheKeysRecord, keyBuilderFromTypeRecordRepresentation, ingestRecord, RecordRepresentationRepresentationType, ObjectInfoRepresentationType, getRecordAdapterFactory, getObjectInfoAdapterFactory, getObjectInfosAdapterFactory, UiApiNamespace, RecordRepresentationType, RecordRepresentationTTL, RecordRepresentationVersion, getRecordsAdapterFactory } from 'force/ldsAdaptersUiapi';
20
20
  import caseSensitiveUserId from '@salesforce/user/Id';
21
21
  import { idleDetector, getInstrumentation } from 'o11y/client';
22
22
  import ldsUseShortUrlGate from '@salesforce/gate/lds.useShortUrl';
@@ -1578,30 +1578,13 @@ function makeDurable(environment, { durableStore, instrumentation, useRevivingSt
1578
1578
  * For full license text, see the LICENSE.txt file
1579
1579
  */
1580
1580
 
1581
- const API_NAMESPACE = 'UiApi';
1582
- const RECORD_REPRESENTATION_NAME = 'RecordRepresentation';
1583
- const RECORD_VIEW_ENTITY_REPRESENTATION_NAME = 'RecordViewEntityRepresentation';
1584
- const RECORD_ID_PREFIX = `${API_NAMESPACE}::${RECORD_REPRESENTATION_NAME}:`;
1585
- const RECORD_VIEW_ENTITY_ID_PREFIX = `${API_NAMESPACE}::${RECORD_VIEW_ENTITY_REPRESENTATION_NAME}:Name:`;
1586
- const RECORD_FIELDS_KEY_JUNCTION = '__fields__';
1581
+
1587
1582
  function isStoreKeyRecordId(key) {
1588
1583
  return key.indexOf(RECORD_ID_PREFIX) > -1 && key.indexOf(RECORD_FIELDS_KEY_JUNCTION) === -1;
1589
1584
  }
1590
- function isStoreKeyRecordViewEntity(key) {
1591
- return (key.indexOf(RECORD_VIEW_ENTITY_ID_PREFIX) > -1 &&
1592
- key.indexOf(RECORD_FIELDS_KEY_JUNCTION) === -1);
1593
- }
1594
1585
  function isStoreKeyRecordField(key) {
1595
1586
  return key.indexOf(RECORD_ID_PREFIX) > -1 && key.indexOf(RECORD_FIELDS_KEY_JUNCTION) > -1;
1596
1587
  }
1597
- function extractRecordIdFromStoreKey(key) {
1598
- if (key === undefined ||
1599
- (key.indexOf(RECORD_ID_PREFIX) === -1 && key.indexOf(RECORD_VIEW_ENTITY_ID_PREFIX) === -1)) {
1600
- return undefined;
1601
- }
1602
- const parts = key.split(':');
1603
- return parts[parts.length - 1].split('_')[0];
1604
- }
1605
1588
  function buildRecordFieldStoreKey(recordKey, fieldName) {
1606
1589
  return `${recordKey}${RECORD_FIELDS_KEY_JUNCTION}${fieldName}`;
1607
1590
  }
@@ -17063,4 +17046,4 @@ register({
17063
17046
  });
17064
17047
 
17065
17048
  export { getRuntime, registerReportObserver, reportGraphqlQueryParseError };
17066
- // version: 1.241.0-b14b649d4
17049
+ // version: 1.242.0-57237c3b6