@salesforce/lds-adapters-uiapi 1.314.0 → 1.316.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/es/es2018/types/src/generated/adapters/getLookupRecords.d.ts +3 -1
- package/dist/es/es2018/types/src/generated/resources/postUiApiLookupsByFieldApiNameAndObjectApiName.d.ts +3 -1
- package/dist/es/es2018/types/src/generated/types/LookupPOSTRequestBodyRepresentation.d.ts +7 -4
- package/dist/es/es2018/types/src/main.d.ts +2 -0
- package/dist/es/es2018/types/src/primitives/SortedStringArrayTitleCase/coerce.d.ts +1 -0
- package/dist/es/es2018/types/src/validation/utils.d.ts +5 -0
- package/dist/es/es2018/types/src/wire/createContentDocumentAndVersion/configurationTypes.d.ts +2 -3
- package/dist/es/es2018/types/src/wire/createRecord/configurationTypes.d.ts +2 -3
- package/dist/es/es2018/types/src/wire/deleteRecord/configurationTypes.d.ts +3 -2
- package/dist/es/es2018/types/src/wire/getLookupRecords/index.d.ts +3 -1
- package/dist/es/es2018/types/src/wire/graphql/configurationTypes.d.ts +3 -3
- package/dist/es/es2018/types/src/wire/graphqlBatch/configurationTypes.d.ts +2 -3
- package/dist/es/es2018/types/src/wire/performQuickAction/index.d.ts +1 -1
- package/dist/es/es2018/types/src/wire/performUpdateRecordQuickAction/index.d.ts +1 -1
- package/dist/es/es2018/types/src/wire/updateRecord/configurationTypes.d.ts +2 -3
- package/dist/es/es2018/uiapi-records-service.js +698 -752
- package/package.json +6 -6
- package/sfdc/graphqlAdapters.js +3 -3
- package/sfdc/index.js +720 -774
- package/src/raml/api.raml +7 -3
- package/src/raml/luvio.raml +4 -2
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { AdapterConfigMetadata as $64$luvio_engine_AdapterConfigMetadata, Luvio as $64$luvio_engine_Luvio, NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata, Fragment as $64$luvio_engine_Fragment, Snapshot as $64$luvio_engine_Snapshot, FetchResponse as $64$luvio_engine_FetchResponse, ErrorResponse as $64$luvio_engine_ErrorResponse, DispatchResourceRequestContext as $64$luvio_engine_DispatchResourceRequestContext, CoercedAdapterRequestContext as $64$luvio_engine_CoercedAdapterRequestContext, StoreLookup as $64$luvio_engine_StoreLookup, AdapterFactory as $64$luvio_engine_AdapterFactory } from '@luvio/engine';
|
|
2
2
|
import { Untrusted as adapter$45$utils_Untrusted, AdapterValidationConfig as adapter$45$utils_AdapterValidationConfig } from './adapter-utils';
|
|
3
3
|
import { RecordInputRepresentation as types_RecordInputRepresentation_RecordInputRepresentation } from '../types/RecordInputRepresentation';
|
|
4
|
+
import { ListOrderedByInfoInputRepresentation as types_ListOrderedByInfoInputRepresentation_ListOrderedByInfoInputRepresentation } from '../types/ListOrderedByInfoInputRepresentation';
|
|
4
5
|
import { ResourceRequestConfig as resources_postUiApiLookupsByFieldApiNameAndObjectApiName_ResourceRequestConfig } from '../resources/postUiApiLookupsByFieldApiNameAndObjectApiName';
|
|
5
6
|
import { LookupValuesRepresentation as types_LookupValuesRepresentation_LookupValuesRepresentation } from '../types/LookupValuesRepresentation';
|
|
6
7
|
export declare const adapterName = "getLookupRecords";
|
|
@@ -16,7 +17,8 @@ export interface GetLookupRecordsConfig {
|
|
|
16
17
|
searchType?: string;
|
|
17
18
|
sourceRecordId?: string;
|
|
18
19
|
targetApiName?: string;
|
|
19
|
-
sourceRecord?: types_RecordInputRepresentation_RecordInputRepresentation
|
|
20
|
+
sourceRecord?: types_RecordInputRepresentation_RecordInputRepresentation;
|
|
21
|
+
orderBy?: Array<types_ListOrderedByInfoInputRepresentation_ListOrderedByInfoInputRepresentation>;
|
|
20
22
|
}
|
|
21
23
|
export declare const createResourceParams: (config: GetLookupRecordsConfig) => resources_postUiApiLookupsByFieldApiNameAndObjectApiName_ResourceRequestConfig;
|
|
22
24
|
export declare function keyBuilder(luvio: $64$luvio_engine_Luvio, config: GetLookupRecordsConfig): string;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { RecordInputRepresentation as types_RecordInputRepresentation_RecordInputRepresentation } from '../types/RecordInputRepresentation';
|
|
2
|
+
import { ListOrderedByInfoInputRepresentation as types_ListOrderedByInfoInputRepresentation_ListOrderedByInfoInputRepresentation } from '../types/ListOrderedByInfoInputRepresentation';
|
|
2
3
|
import { Luvio as $64$luvio_engine_Luvio, Fragment as $64$luvio_engine_Fragment, NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata, FetchResponse as $64$luvio_engine_FetchResponse, SnapshotRefresh as $64$luvio_engine_SnapshotRefresh, FulfilledSnapshot as $64$luvio_engine_FulfilledSnapshot, StaleSnapshot as $64$luvio_engine_StaleSnapshot, PendingSnapshot as $64$luvio_engine_PendingSnapshot, ErrorResponse as $64$luvio_engine_ErrorResponse, ErrorSnapshot as $64$luvio_engine_ErrorSnapshot, ResourceRequest as $64$luvio_engine_ResourceRequest } from '@luvio/engine';
|
|
3
4
|
import { LookupValuesRepresentation as types_LookupValuesRepresentation_LookupValuesRepresentation } from '../types/LookupValuesRepresentation';
|
|
4
5
|
export interface ResourceRequestConfig {
|
|
@@ -16,7 +17,8 @@ export interface ResourceRequestConfig {
|
|
|
16
17
|
targetApiName?: string;
|
|
17
18
|
};
|
|
18
19
|
body: {
|
|
19
|
-
sourceRecord?: types_RecordInputRepresentation_RecordInputRepresentation
|
|
20
|
+
sourceRecord?: types_RecordInputRepresentation_RecordInputRepresentation;
|
|
21
|
+
orderBy?: Array<types_ListOrderedByInfoInputRepresentation_ListOrderedByInfoInputRepresentation>;
|
|
20
22
|
};
|
|
21
23
|
}
|
|
22
24
|
export declare function select(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig): $64$luvio_engine_Fragment;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
+
import { ListOrderedByInfoInputRepresentation as ListOrderedByInfoInputRepresentation_ListOrderedByInfoInputRepresentation } from './ListOrderedByInfoInputRepresentation';
|
|
1
2
|
import { RecordInputRepresentation as RecordInputRepresentation_RecordInputRepresentation } from './RecordInputRepresentation';
|
|
2
3
|
import { IngestPath as $64$luvio_engine_IngestPath, Luvio as $64$luvio_engine_Luvio, Store as $64$luvio_engine_Store, FragmentSelection as $64$luvio_engine_FragmentSelection, ResourceIngest as $64$luvio_engine_ResourceIngest, DurableStoreKeyMetadataMap as $64$luvio_engine_DurableStoreKeyMetadataMap, NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata } from '@luvio/engine';
|
|
3
|
-
export declare const VERSION = "
|
|
4
|
+
export declare const VERSION = "62c473d88e350d46257d855cc52eec00";
|
|
4
5
|
export declare function validate(obj: any, path?: string): TypeError | null;
|
|
5
6
|
export declare const RepresentationType: string;
|
|
6
7
|
export declare function normalize(input: LookupPOSTRequestBodyRepresentation, existing: LookupPOSTRequestBodyRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): LookupPOSTRequestBodyRepresentationNormalized;
|
|
@@ -15,8 +16,9 @@ export declare function getTypeCacheKeys(rootKeySet: $64$luvio_engine_DurableSto
|
|
|
15
16
|
* (none)
|
|
16
17
|
*/
|
|
17
18
|
export interface LookupPOSTRequestBodyRepresentationNormalized {
|
|
18
|
-
/** The
|
|
19
|
-
|
|
19
|
+
/** The sorting preference for the results. */
|
|
20
|
+
orderBy?: Array<ListOrderedByInfoInputRepresentation_ListOrderedByInfoInputRepresentation>;
|
|
21
|
+
sourceRecord?: RecordInputRepresentation_RecordInputRepresentation;
|
|
20
22
|
}
|
|
21
23
|
/**
|
|
22
24
|
* A lookup POST request body.
|
|
@@ -25,5 +27,6 @@ export interface LookupPOSTRequestBodyRepresentationNormalized {
|
|
|
25
27
|
* (none)
|
|
26
28
|
*/
|
|
27
29
|
export interface LookupPOSTRequestBodyRepresentation {
|
|
28
|
-
|
|
30
|
+
orderBy?: Array<ListOrderedByInfoInputRepresentation_ListOrderedByInfoInputRepresentation>;
|
|
31
|
+
sourceRecord?: RecordInputRepresentation_RecordInputRepresentation;
|
|
29
32
|
}
|
|
@@ -61,6 +61,8 @@ export type { DraftAwareUpdateRecordAdapter } from './wire/updateRecord/configur
|
|
|
61
61
|
export type { DraftAwareDeleteRecordAdapter } from './wire/deleteRecord/configurationTypes';
|
|
62
62
|
export type { DraftAwareCreateContentDocumentAndVersionAdapter } from './wire/createContentDocumentAndVersion/configurationTypes';
|
|
63
63
|
export type { DraftAwareCreateContentVersionAdapter } from './wire/createContentVersion/configurationTypes';
|
|
64
|
+
export type { DraftAwarePerformQuickActionAdapter } from './wire/performQuickAction/configurationTypes';
|
|
65
|
+
export type { DraftAwarePerformUpdateRecordQuickActionAdapter } from './wire/performUpdateRecordQuickAction/configurationTypes';
|
|
64
66
|
export type { DraftAwareGraphQLAdapter } from './wire/graphql/configurationTypes';
|
|
65
67
|
export type { EnvironmentAwareGraphQLBatchAdapter } from './wire/graphqlBatch/configurationTypes';
|
|
66
68
|
export type { ContentDocumentCompositeRepresentation } from './generated/types/ContentDocumentCompositeRepresentation';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function toSortedStringArrayTitleCase(value: unknown): Array<string> | undefined;
|
|
@@ -22,3 +22,8 @@ export declare function dedupe<T extends string>(value: T[]): T[];
|
|
|
22
22
|
* If the "compare" array is empty, "source" array itself is returned, not a shallow copy
|
|
23
23
|
*/
|
|
24
24
|
export declare function difference(source: string[], compare: string[]): string[];
|
|
25
|
+
/**
|
|
26
|
+
* @param word The string to title case
|
|
27
|
+
* @returns The sames string but in title case
|
|
28
|
+
*/
|
|
29
|
+
export declare function toTitleCase(word: string): string;
|
package/dist/es/es2018/types/src/wire/createContentDocumentAndVersion/configurationTypes.d.ts
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import type { AdapterRequestContext, Snapshot } from '@luvio/engine';
|
|
1
|
+
import type { AdapterRequestContext, ResourceRequest, Snapshot } from '@luvio/engine';
|
|
2
2
|
import type { ContentDocumentCompositeRepresentation } from '../../generated/types/ContentDocumentCompositeRepresentation';
|
|
3
|
-
import type { buildNetworkSnapshot } from './buildNetworkSnapshot';
|
|
4
3
|
import type { CreateContentDocumentAndVersionConfig } from './AdapterConfig';
|
|
5
|
-
export type DraftAwareCreateContentDocumentAndVersionAdapter = (config: CreateContentDocumentAndVersionConfig,
|
|
4
|
+
export type DraftAwareCreateContentDocumentAndVersionAdapter = (config: CreateContentDocumentAndVersionConfig, requestBuilder: (config: CreateContentDocumentAndVersionConfig) => ResourceRequest, requestContext?: AdapterRequestContext) => Promise<Snapshot<ContentDocumentCompositeRepresentation>>;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import type { Snapshot } from '@luvio/engine';
|
|
1
|
+
import type { ResourceRequest, Snapshot } from '@luvio/engine';
|
|
2
2
|
import type { CreateRecordConfig } from '../../generated/adapters/createRecord';
|
|
3
3
|
import type { RecordRepresentation } from '../../generated/types/RecordRepresentation';
|
|
4
|
-
|
|
5
|
-
export type DraftAwareCreateRecordAdapter = (config: CreateRecordConfig, networkSnapshotBuilder: typeof buildNetworkSnapshot) => Promise<Snapshot<RecordRepresentation>>;
|
|
4
|
+
export type DraftAwareCreateRecordAdapter = (config: CreateRecordConfig, requestBuilder: (config: CreateRecordConfig) => ResourceRequest) => Promise<Snapshot<RecordRepresentation>>;
|
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
|
|
1
|
+
import type { ResourceRequest } from '@luvio/engine';
|
|
2
|
+
import type { DeleteRecordConfig } from '../../generated/adapters/deleteRecord';
|
|
3
|
+
export type DraftAwareDeleteRecordAdapter = (config: DeleteRecordConfig, requestBuilder: (config: DeleteRecordConfig) => ResourceRequest) => Promise<void>;
|
|
@@ -3,6 +3,7 @@ import type { LookupValuesRepresentation } from '../../generated/types/LookupVal
|
|
|
3
3
|
import type { GetLookupRecordsConfig } from '../../generated/adapters/getLookupRecords';
|
|
4
4
|
import type { FieldId } from '../../primitives/FieldId';
|
|
5
5
|
import type { RecordInputRepresentation as types_RecordInputRepresentation_RecordInputRepresentation } from '../../generated/types/RecordInputRepresentation';
|
|
6
|
+
import type { ListOrderedByInfoInputRepresentation as types_ListOrderedByInfoInputRepresentation } from '../../generated/types/ListOrderedByInfoInputRepresentation';
|
|
6
7
|
interface GetLookupRecordsConfigRequestParams {
|
|
7
8
|
q?: string;
|
|
8
9
|
page?: number;
|
|
@@ -11,7 +12,8 @@ interface GetLookupRecordsConfigRequestParams {
|
|
|
11
12
|
searchType?: 'Recent' | 'Search' | 'TypeAhead';
|
|
12
13
|
sourceRecordId?: string;
|
|
13
14
|
targetApiName?: string;
|
|
14
|
-
sourceRecord?: types_RecordInputRepresentation_RecordInputRepresentation
|
|
15
|
+
sourceRecord?: types_RecordInputRepresentation_RecordInputRepresentation;
|
|
16
|
+
orderBy?: types_ListOrderedByInfoInputRepresentation[];
|
|
15
17
|
}
|
|
16
18
|
export interface GetLookupRecordsAdapterConfig {
|
|
17
19
|
fieldApiName: string | FieldId;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { AvailableSnapshot, AdapterRequestContext
|
|
2
|
-
import type {
|
|
1
|
+
import type { AvailableSnapshot, AdapterRequestContext } from '@luvio/engine';
|
|
2
|
+
import type { GraphqlConfig } from '../../generated/adapters/graphql';
|
|
3
3
|
import type { GraphQLRepresentation } from '../../generated/types/GraphQLRepresentation';
|
|
4
|
-
export type DraftAwareGraphQLAdapter = (config: GraphqlConfig,
|
|
4
|
+
export type DraftAwareGraphQLAdapter = (config: GraphqlConfig, requestContext?: AdapterRequestContext) => Promise<AvailableSnapshot<GraphQLRepresentation>>;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import type { AvailableSnapshot, AdapterRequestContext
|
|
1
|
+
import type { AvailableSnapshot, AdapterRequestContext } from '@luvio/engine';
|
|
2
2
|
import type { GraphqlBatchConfig } from '../../wire/graphqlBatch';
|
|
3
3
|
import type { GraphQLBatchRepresentation } from '../../wire/graphqlBatch/postGraphqlBatch';
|
|
4
|
-
|
|
5
|
-
export type EnvironmentAwareGraphQLBatchAdapter = (config: GraphqlBatchConfig, buildCachedSnapshotCachePolicy: (context: BatchBuildSnapshotContext, storeLookup: StoreLookup<GraphQLBatchRepresentation, unknown>) => Snapshot<GraphQLBatchRepresentation, any>, buildNetworkSnapshotCachePolicy: (context: BatchBuildSnapshotContext, coercedAdapterRequestContext: CoercedAdapterRequestContext) => Promise<Snapshot<GraphQLBatchRepresentation, any>>, requestContext?: AdapterRequestContext) => Promise<AvailableSnapshot<GraphQLBatchRepresentation>>;
|
|
4
|
+
export type EnvironmentAwareGraphQLBatchAdapter = (config: GraphqlBatchConfig, requestContext?: AdapterRequestContext) => Promise<AvailableSnapshot<GraphQLBatchRepresentation>>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import type { Luvio, Snapshot } from '@luvio/engine';
|
|
2
2
|
import type { QuickActionExecutionRepresentation } from '../../generated/types/QuickActionExecutionRepresentation';
|
|
3
|
-
export declare const factory: (luvio: Luvio) => (
|
|
3
|
+
export declare const factory: (luvio: Luvio) => (untrustedConfig: unknown) => Promise<Snapshot<QuickActionExecutionRepresentation>>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import type { Luvio, Snapshot } from '@luvio/engine';
|
|
2
2
|
import type { QuickActionExecutionRepresentation } from '../../generated/types/QuickActionExecutionRepresentation';
|
|
3
|
-
export declare const factory: (luvio: Luvio) => (
|
|
3
|
+
export declare const factory: (luvio: Luvio) => (untrustedConfig: unknown) => Promise<Snapshot<QuickActionExecutionRepresentation>>;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import type { Snapshot } from '@luvio/engine';
|
|
1
|
+
import type { ResourceRequest, Snapshot } from '@luvio/engine';
|
|
2
2
|
import type { UpdateRecordConfig } from '../../generated/adapters/updateRecord';
|
|
3
3
|
import type { RecordRepresentation } from '../../generated/types/RecordRepresentation';
|
|
4
|
-
|
|
5
|
-
export type DraftAwareUpdateRecordAdapter = (config: UpdateRecordConfig, networkSnapshotBuilder: typeof buildNetworkSnapshot) => Promise<Snapshot<RecordRepresentation>>;
|
|
4
|
+
export type DraftAwareUpdateRecordAdapter = (config: UpdateRecordConfig, requestBuilder: (config: UpdateRecordConfig) => ResourceRequest) => Promise<Snapshot<RecordRepresentation>>;
|