@salesforce/lds-adapters-community-info 0.1.0-dev1

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.
@@ -0,0 +1,62 @@
1
+ import { Adapter as $64$luvio_engine_Adapter, Snapshot as $64$luvio_engine_Snapshot, UnfulfilledSnapshot as $64$luvio_engine_UnfulfilledSnapshot, AdapterConfigMetadata as $64$luvio_engine_AdapterConfigMetadata } from '@luvio/engine';
2
+ export declare const ObjectPrototypeHasOwnProperty: (v: PropertyKey) => boolean;
3
+ declare const ObjectKeys: {
4
+ (o: object): string[];
5
+ (o: {}): string[];
6
+ }, ObjectCreate: {
7
+ (o: object | null): any;
8
+ (o: object | null, properties: PropertyDescriptorMap & ThisType<any>): any;
9
+ };
10
+ export { ObjectCreate, ObjectKeys };
11
+ export declare const ArrayIsArray: (arg: any) => arg is any[];
12
+ export declare const ArrayPrototypePush: (...items: any[]) => number;
13
+ export interface AdapterValidationConfig {
14
+ displayName: string;
15
+ parameters: {
16
+ required: string[];
17
+ optional: string[];
18
+ unsupported?: string[];
19
+ };
20
+ }
21
+ /**
22
+ * Validates an adapter config is well-formed.
23
+ * @param config The config to validate.
24
+ * @param adapter The adapter validation configuration.
25
+ * @param oneOf The keys the config must contain at least one of.
26
+ * @throws A TypeError if config doesn't satisfy the adapter's config validation.
27
+ */
28
+ export declare function validateConfig<T>(config: Untrusted<T>, adapter: AdapterValidationConfig, oneOf?: string[]): void;
29
+ export declare function untrustedIsObject<Base>(untrusted: unknown): untrusted is Untrusted<Base>;
30
+ export type UncoercedConfiguration<Base, Options extends {
31
+ [key in keyof Base]?: any;
32
+ }> = {
33
+ [Key in keyof Base]?: Base[Key] | Options[Key];
34
+ };
35
+ export type Untrusted<Base> = Partial<Base>;
36
+ export declare function areRequiredParametersPresent<T>(config: any, configPropertyNames: AdapterValidationConfig): config is T;
37
+ export declare function refreshable<C, D, R>(adapter: $64$luvio_engine_Adapter<C, D>, resolve: (config: unknown) => Promise<$64$luvio_engine_Snapshot<R>>): $64$luvio_engine_Adapter<C, D>;
38
+ export declare const SNAPSHOT_STATE_FULFILLED = "Fulfilled";
39
+ export declare const SNAPSHOT_STATE_UNFULFILLED = "Unfulfilled";
40
+ export declare const snapshotRefreshOptions: {
41
+ overrides: {
42
+ headers: {
43
+ 'Cache-Control': string;
44
+ };
45
+ };
46
+ };
47
+ /**
48
+ * A deterministic JSON stringify implementation. Heavily adapted from https://github.com/epoberezkin/fast-json-stable-stringify.
49
+ * This is needed because insertion order for JSON.stringify(object) affects output:
50
+ * JSON.stringify({a: 1, b: 2})
51
+ * "{"a":1,"b":2}"
52
+ * JSON.stringify({b: 2, a: 1})
53
+ * "{"b":2,"a":1}"
54
+ * @param data Data to be JSON-stringified.
55
+ * @returns JSON.stringified value with consistent ordering of keys.
56
+ */
57
+ export declare function stableJSONStringify(node: any): string | undefined;
58
+ export declare function getFetchResponseStatusText(status: number): string;
59
+ export declare function isUnfulfilledSnapshot<T, U>(snapshot: $64$luvio_engine_Snapshot<T, U>): snapshot is $64$luvio_engine_UnfulfilledSnapshot<T, U>;
60
+ export declare function generateParamConfigMetadata(name: string, required: boolean, resourceType: $64$luvio_engine_AdapterConfigMetadata['resourceType'], typeCheckShape: $64$luvio_engine_AdapterConfigMetadata['typeCheckShape'], isArrayShape?: boolean, coerceFn?: (v: unknown) => unknown): $64$luvio_engine_AdapterConfigMetadata;
61
+ export declare function buildAdapterValidationConfig(displayName: string, paramsMeta: $64$luvio_engine_AdapterConfigMetadata[]): AdapterValidationConfig;
62
+ export declare const keyPrefix = "CommunityInfo";
@@ -0,0 +1,27 @@
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
+ import { Untrusted as adapter$45$utils_Untrusted, AdapterValidationConfig as adapter$45$utils_AdapterValidationConfig } from './adapter-utils';
3
+ import { ResourceRequestConfig as resources_getConnectCommunities_ResourceRequestConfig } from '../resources/getConnectCommunities';
4
+ import { CommunityCollectionRepresentation as types_CommunityCollectionRepresentation_CommunityCollectionRepresentation } from '../types/CommunityCollectionRepresentation';
5
+ export declare const adapterName = "getCommunities";
6
+ export declare const getCommunities_ConfigPropertyMetadata: $64$luvio_engine_AdapterConfigMetadata[];
7
+ export declare const getCommunities_ConfigPropertyNames: adapter$45$utils_AdapterValidationConfig;
8
+ export interface GetCommunitiesConfig {
9
+ status?: string;
10
+ }
11
+ export declare const createResourceParams: (config: GetCommunitiesConfig) => resources_getConnectCommunities_ResourceRequestConfig;
12
+ export declare function keyBuilder(luvio: $64$luvio_engine_Luvio, config: GetCommunitiesConfig): string;
13
+ export declare function keyBuilder_StructuredKey(luvio: $64$luvio_engine_Luvio, config: GetCommunitiesConfig): $64$luvio_engine_NormalizedKeyMetadata;
14
+ export declare function typeCheckConfig(untrustedConfig: adapter$45$utils_Untrusted<GetCommunitiesConfig>): adapter$45$utils_Untrusted<GetCommunitiesConfig>;
15
+ export declare function validateAdapterConfig(untrustedConfig: unknown, configPropertyNames: adapter$45$utils_AdapterValidationConfig): GetCommunitiesConfig | null;
16
+ export declare function adapterFragment(luvio: $64$luvio_engine_Luvio, config: GetCommunitiesConfig): $64$luvio_engine_Fragment;
17
+ export declare function buildCachedSnapshot(luvio: $64$luvio_engine_Luvio, config: GetCommunitiesConfig): $64$luvio_engine_Snapshot<types_CommunityCollectionRepresentation_CommunityCollectionRepresentation, any>;
18
+ export declare function onFetchResponseSuccess(luvio: $64$luvio_engine_Luvio, config: GetCommunitiesConfig, resourceParams: resources_getConnectCommunities_ResourceRequestConfig, response: $64$luvio_engine_FetchResponse<types_CommunityCollectionRepresentation_CommunityCollectionRepresentation>): Promise<import("@luvio/engine").FulfilledSnapshot<types_CommunityCollectionRepresentation_CommunityCollectionRepresentation, {}> | import("@luvio/engine").StaleSnapshot<types_CommunityCollectionRepresentation_CommunityCollectionRepresentation, {}> | import("@luvio/engine").PendingSnapshot<types_CommunityCollectionRepresentation_CommunityCollectionRepresentation, any>>;
19
+ export declare function onFetchResponseError(luvio: $64$luvio_engine_Luvio, config: GetCommunitiesConfig, resourceParams: resources_getConnectCommunities_ResourceRequestConfig, response: $64$luvio_engine_ErrorResponse): Promise<import("@luvio/engine").ErrorSnapshot>;
20
+ export declare function buildNetworkSnapshot(luvio: $64$luvio_engine_Luvio, config: GetCommunitiesConfig, options?: $64$luvio_engine_DispatchResourceRequestContext): Promise<$64$luvio_engine_Snapshot<types_CommunityCollectionRepresentation_CommunityCollectionRepresentation, any>>;
21
+ export type BuildSnapshotContext = {
22
+ luvio: $64$luvio_engine_Luvio;
23
+ config: GetCommunitiesConfig;
24
+ };
25
+ export declare function buildNetworkSnapshotCachePolicy(context: BuildSnapshotContext, coercedAdapterRequestContext: $64$luvio_engine_CoercedAdapterRequestContext): Promise<$64$luvio_engine_Snapshot<types_CommunityCollectionRepresentation_CommunityCollectionRepresentation, any>>;
26
+ export declare function buildCachedSnapshotCachePolicy(context: BuildSnapshotContext, storeLookup: $64$luvio_engine_StoreLookup<types_CommunityCollectionRepresentation_CommunityCollectionRepresentation>): $64$luvio_engine_Snapshot<types_CommunityCollectionRepresentation_CommunityCollectionRepresentation, any>;
27
+ export declare const getCommunitiesAdapterFactory: $64$luvio_engine_AdapterFactory<GetCommunitiesConfig, types_CommunityCollectionRepresentation_CommunityCollectionRepresentation>;
@@ -0,0 +1,27 @@
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
+ import { Untrusted as adapter$45$utils_Untrusted, AdapterValidationConfig as adapter$45$utils_AdapterValidationConfig } from './adapter-utils';
3
+ import { ResourceRequestConfig as resources_getConnectCommunitiesByCommunityId_ResourceRequestConfig } from '../resources/getConnectCommunitiesByCommunityId';
4
+ import { CommunityRepresentation as types_CommunityRepresentation_CommunityRepresentation } from '../types/CommunityRepresentation';
5
+ export declare const adapterName = "getCommunity";
6
+ export declare const getCommunity_ConfigPropertyMetadata: $64$luvio_engine_AdapterConfigMetadata[];
7
+ export declare const getCommunity_ConfigPropertyNames: adapter$45$utils_AdapterValidationConfig;
8
+ export interface GetCommunityConfig {
9
+ communityId: string;
10
+ }
11
+ export declare const createResourceParams: (config: GetCommunityConfig) => resources_getConnectCommunitiesByCommunityId_ResourceRequestConfig;
12
+ export declare function keyBuilder(luvio: $64$luvio_engine_Luvio, config: GetCommunityConfig): string;
13
+ export declare function keyBuilder_StructuredKey(luvio: $64$luvio_engine_Luvio, config: GetCommunityConfig): $64$luvio_engine_NormalizedKeyMetadata;
14
+ export declare function typeCheckConfig(untrustedConfig: adapter$45$utils_Untrusted<GetCommunityConfig>): adapter$45$utils_Untrusted<GetCommunityConfig>;
15
+ export declare function validateAdapterConfig(untrustedConfig: unknown, configPropertyNames: adapter$45$utils_AdapterValidationConfig): GetCommunityConfig | null;
16
+ export declare function adapterFragment(luvio: $64$luvio_engine_Luvio, config: GetCommunityConfig): $64$luvio_engine_Fragment;
17
+ export declare function buildCachedSnapshot(luvio: $64$luvio_engine_Luvio, config: GetCommunityConfig): $64$luvio_engine_Snapshot<types_CommunityRepresentation_CommunityRepresentation, any>;
18
+ export declare function onFetchResponseSuccess(luvio: $64$luvio_engine_Luvio, config: GetCommunityConfig, resourceParams: resources_getConnectCommunitiesByCommunityId_ResourceRequestConfig, response: $64$luvio_engine_FetchResponse<types_CommunityRepresentation_CommunityRepresentation>): Promise<import("@luvio/engine").FulfilledSnapshot<types_CommunityRepresentation_CommunityRepresentation, {}> | import("@luvio/engine").StaleSnapshot<types_CommunityRepresentation_CommunityRepresentation, {}> | import("@luvio/engine").PendingSnapshot<types_CommunityRepresentation_CommunityRepresentation, any>>;
19
+ export declare function onFetchResponseError(luvio: $64$luvio_engine_Luvio, config: GetCommunityConfig, resourceParams: resources_getConnectCommunitiesByCommunityId_ResourceRequestConfig, response: $64$luvio_engine_ErrorResponse): Promise<import("@luvio/engine").ErrorSnapshot>;
20
+ export declare function buildNetworkSnapshot(luvio: $64$luvio_engine_Luvio, config: GetCommunityConfig, options?: $64$luvio_engine_DispatchResourceRequestContext): Promise<$64$luvio_engine_Snapshot<types_CommunityRepresentation_CommunityRepresentation, any>>;
21
+ export type BuildSnapshotContext = {
22
+ luvio: $64$luvio_engine_Luvio;
23
+ config: GetCommunityConfig;
24
+ };
25
+ export declare function buildNetworkSnapshotCachePolicy(context: BuildSnapshotContext, coercedAdapterRequestContext: $64$luvio_engine_CoercedAdapterRequestContext): Promise<$64$luvio_engine_Snapshot<types_CommunityRepresentation_CommunityRepresentation, any>>;
26
+ export declare function buildCachedSnapshotCachePolicy(context: BuildSnapshotContext, storeLookup: $64$luvio_engine_StoreLookup<types_CommunityRepresentation_CommunityRepresentation>): $64$luvio_engine_Snapshot<types_CommunityRepresentation_CommunityRepresentation, any>;
27
+ export declare const getCommunityAdapterFactory: $64$luvio_engine_AdapterFactory<GetCommunityConfig, types_CommunityRepresentation_CommunityRepresentation>;
@@ -0,0 +1,3 @@
1
+ export { getCommunitiesAdapterFactory } from '../adapters/getCommunities';
2
+ export { getCommunityAdapterFactory } from '../adapters/getCommunity';
3
+ export { notifyUpdateAvailableFactory as notifyCommunityUpdateAvailableFactory } from '../types/CommunityRepresentation';
@@ -0,0 +1,7 @@
1
+ declare let getCommunities: any;
2
+ declare let getCommunity: any;
3
+ declare let getCommunities_imperative: any;
4
+ declare let getCommunity_imperative: any;
5
+ declare let notifyCommunityUpdateAvailable: any;
6
+ export { getCommunities, getCommunity, getCommunities_imperative, getCommunity_imperative };
7
+ export { notifyCommunityUpdateAvailable };
@@ -0,0 +1,15 @@
1
+ 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';
2
+ import { CommunityCollectionRepresentation as types_CommunityCollectionRepresentation_CommunityCollectionRepresentation } from '../types/CommunityCollectionRepresentation';
3
+ export interface ResourceRequestConfig {
4
+ queryParams: {
5
+ status?: string;
6
+ };
7
+ }
8
+ export declare function select(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig): $64$luvio_engine_Fragment;
9
+ export declare function keyBuilder(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig): string;
10
+ export declare function keyBuilder_StructuredKey(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig): $64$luvio_engine_NormalizedKeyMetadata;
11
+ export declare function getResponseCacheKeys(storeKeyMap: any, luvio: $64$luvio_engine_Luvio, resourceParams: ResourceRequestConfig, response: types_CommunityCollectionRepresentation_CommunityCollectionRepresentation): void;
12
+ export declare function ingestSuccess(luvio: $64$luvio_engine_Luvio, resourceParams: ResourceRequestConfig, response: $64$luvio_engine_FetchResponse<types_CommunityCollectionRepresentation_CommunityCollectionRepresentation>, snapshotRefresh?: $64$luvio_engine_SnapshotRefresh<types_CommunityCollectionRepresentation_CommunityCollectionRepresentation>): $64$luvio_engine_FulfilledSnapshot<types_CommunityCollectionRepresentation_CommunityCollectionRepresentation, {}> | $64$luvio_engine_StaleSnapshot<types_CommunityCollectionRepresentation_CommunityCollectionRepresentation, {}> | $64$luvio_engine_PendingSnapshot<types_CommunityCollectionRepresentation_CommunityCollectionRepresentation, any>;
13
+ export declare function ingestError(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig, error: $64$luvio_engine_ErrorResponse, snapshotRefresh?: $64$luvio_engine_SnapshotRefresh<types_CommunityCollectionRepresentation_CommunityCollectionRepresentation>): $64$luvio_engine_ErrorSnapshot;
14
+ export declare function createResourceRequest(config: ResourceRequestConfig): $64$luvio_engine_ResourceRequest;
15
+ export default createResourceRequest;
@@ -0,0 +1,15 @@
1
+ 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';
2
+ import { CommunityRepresentation as types_CommunityRepresentation_CommunityRepresentation } from '../types/CommunityRepresentation';
3
+ export interface ResourceRequestConfig {
4
+ urlParams: {
5
+ communityId: string;
6
+ };
7
+ }
8
+ export declare function select(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig): $64$luvio_engine_Fragment;
9
+ export declare function keyBuilder(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig): string;
10
+ export declare function keyBuilder_StructuredKey(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig): $64$luvio_engine_NormalizedKeyMetadata;
11
+ export declare function getResponseCacheKeys(storeKeyMap: any, luvio: $64$luvio_engine_Luvio, resourceParams: ResourceRequestConfig, response: types_CommunityRepresentation_CommunityRepresentation): void;
12
+ export declare function ingestSuccess(luvio: $64$luvio_engine_Luvio, resourceParams: ResourceRequestConfig, response: $64$luvio_engine_FetchResponse<types_CommunityRepresentation_CommunityRepresentation>, snapshotRefresh?: $64$luvio_engine_SnapshotRefresh<types_CommunityRepresentation_CommunityRepresentation>): $64$luvio_engine_FulfilledSnapshot<types_CommunityRepresentation_CommunityRepresentation, {}> | $64$luvio_engine_StaleSnapshot<types_CommunityRepresentation_CommunityRepresentation, {}> | $64$luvio_engine_PendingSnapshot<types_CommunityRepresentation_CommunityRepresentation, any>;
13
+ export declare function ingestError(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig, error: $64$luvio_engine_ErrorResponse, snapshotRefresh?: $64$luvio_engine_SnapshotRefresh<types_CommunityRepresentation_CommunityRepresentation>): $64$luvio_engine_ErrorSnapshot;
14
+ export declare function createResourceRequest(config: ResourceRequestConfig): $64$luvio_engine_ResourceRequest;
15
+ export default createResourceRequest;
@@ -0,0 +1,42 @@
1
+ import { IngestPath as $64$luvio_engine_IngestPath, Luvio as $64$luvio_engine_Luvio, Store as $64$luvio_engine_Store, ResourceIngest as $64$luvio_engine_ResourceIngest, FragmentSelection as $64$luvio_engine_FragmentSelection, LinkSelection as $64$luvio_engine_LinkSelection, StoreLink as $64$luvio_engine_StoreLink, DurableStoreKeyMetadataMap as $64$luvio_engine_DurableStoreKeyMetadataMap, NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata } from '@luvio/engine';
2
+ import { CommunityRepresentation as CommunityRepresentation_CommunityRepresentation } from './CommunityRepresentation';
3
+ export declare const TTL = 60000;
4
+ export declare const VERSION = "e6f9ff44e6e76bc78cc1e0730e8459c9";
5
+ export declare function validate(obj: any, path?: string): TypeError | null;
6
+ export declare const RepresentationType: string;
7
+ export declare function normalize(input: CommunityCollectionRepresentation, existing: CommunityCollectionRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): CommunityCollectionRepresentationNormalized;
8
+ export interface DynamicIngestParams {
9
+ communities: $64$luvio_engine_ResourceIngest;
10
+ }
11
+ export declare function dynamicNormalize(ingestParams: DynamicIngestParams): (input: CommunityCollectionRepresentation, existing: CommunityCollectionRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number) => CommunityCollectionRepresentationNormalized;
12
+ export declare const select: () => $64$luvio_engine_FragmentSelection;
13
+ export interface DynamicSelectParams {
14
+ communities?: $64$luvio_engine_LinkSelection;
15
+ }
16
+ export declare const dynamicSelect: (params: DynamicSelectParams) => $64$luvio_engine_FragmentSelection;
17
+ export declare function equals(existing: CommunityCollectionRepresentationNormalized, incoming: CommunityCollectionRepresentationNormalized): boolean;
18
+ export declare const ingest: $64$luvio_engine_ResourceIngest;
19
+ export declare function getTypeCacheKeys(rootKeySet: $64$luvio_engine_DurableStoreKeyMetadataMap, luvio: $64$luvio_engine_Luvio, input: CommunityCollectionRepresentation, fullPathFactory: () => string | $64$luvio_engine_NormalizedKeyMetadata): void;
20
+ export declare function dynamicIngest(ingestParams: DynamicIngestParams): $64$luvio_engine_ResourceIngest;
21
+ /**
22
+ * A list of Communities.
23
+ *
24
+ * Keys:
25
+ * (none)
26
+ */
27
+ export interface CommunityCollectionRepresentationNormalized {
28
+ /** List of communities available to the current user. */
29
+ communities: Array<$64$luvio_engine_StoreLink>;
30
+ /** Total number of communities available to the current user. */
31
+ total: number;
32
+ }
33
+ /**
34
+ * A list of Communities.
35
+ *
36
+ * Keys:
37
+ * (none)
38
+ */
39
+ export interface CommunityCollectionRepresentation {
40
+ communities: Array<CommunityRepresentation_CommunityRepresentation>;
41
+ total: number;
42
+ }
@@ -0,0 +1,108 @@
1
+ import { KeyMetadata as $64$luvio_engine_KeyMetadata, NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata, Luvio as $64$luvio_engine_Luvio, IngestPath as $64$luvio_engine_IngestPath, Store as $64$luvio_engine_Store, FragmentSelection as $64$luvio_engine_FragmentSelection, ResourceIngest as $64$luvio_engine_ResourceIngest, DurableStoreKeyMetadataMap as $64$luvio_engine_DurableStoreKeyMetadataMap } from '@luvio/engine';
2
+ export declare const TTL = 3600000;
3
+ export declare const VERSION = "a4ffd78a9a641066e050c5a37a879702";
4
+ export declare function validate(obj: any, path?: string): TypeError | null;
5
+ export declare const RepresentationType: string;
6
+ export interface KeyParams extends $64$luvio_engine_KeyMetadata {
7
+ id: string | null;
8
+ }
9
+ export type CommunityRepresentationNormalizedKeyMetadata = KeyParams & $64$luvio_engine_NormalizedKeyMetadata;
10
+ export type PartialCommunityRepresentationNormalizedKeyMetadata = Partial<KeyParams> & $64$luvio_engine_NormalizedKeyMetadata;
11
+ export declare function keyBuilder(luvio: $64$luvio_engine_Luvio, config: KeyParams): string;
12
+ export declare function keyBuilder_StructuredKey(luvio: $64$luvio_engine_Luvio, config: KeyParams): CommunityRepresentationNormalizedKeyMetadata;
13
+ export declare function keyBuilderFromType(luvio: $64$luvio_engine_Luvio, object: CommunityRepresentation): string;
14
+ export declare function keyBuilderFromType_StructuredKey(luvio: $64$luvio_engine_Luvio, object: CommunityRepresentation): $64$luvio_engine_NormalizedKeyMetadata;
15
+ export declare function normalize(input: CommunityRepresentation, existing: CommunityRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): CommunityRepresentationNormalized;
16
+ export declare const select: () => $64$luvio_engine_FragmentSelection;
17
+ export declare function equals(existing: CommunityRepresentationNormalized, incoming: CommunityRepresentationNormalized): boolean;
18
+ export declare const ingest: $64$luvio_engine_ResourceIngest;
19
+ export declare function getTypeCacheKeys(rootKeySet: $64$luvio_engine_DurableStoreKeyMetadataMap, luvio: $64$luvio_engine_Luvio, input: CommunityRepresentation, fullPathFactory: () => string | $64$luvio_engine_NormalizedKeyMetadata): void;
20
+ /**
21
+ * Communities are customizable public or private spaces for employees, customers, and partners to collaborate on best practices and business processes.
22
+ *
23
+ * Keys:
24
+ * id (string | null): id
25
+ */
26
+ export interface CommunityRepresentationNormalized {
27
+ /** Specifies whether guest users can access public Chatter groups in the community without logging in. */
28
+ allowChatterAccessWithoutLogin: boolean | null;
29
+ /** Specifies whether members of this community are allowed to flag content. */
30
+ allowMembersToFlag: boolean | null;
31
+ /** Specifies whether the Service Not Available page is an auto-generated Experience Builder-based page (true) or a static resource page that is set in Workspaces|Administration|Pages (false). */
32
+ builderBasedSnaEnabled: boolean | null;
33
+ /** Builder URL for the Community */
34
+ builderUrl: string | null;
35
+ /** 18-character content space Id of the managed content for Enhanced Site. */
36
+ contentSpaceId: string | null;
37
+ /** Community’s description. */
38
+ description: string | null;
39
+ /** Specifies whether guest members can see other members of the community or not. */
40
+ guestMemberVisibilityEnabled: boolean | null;
41
+ /** 18-character Id of the community. */
42
+ id: string | null;
43
+ /** Specifies whether image optimization is enabled for sites hosted on iCDN platforms or not */
44
+ imageOptimizationCDNEnabled: boolean | null;
45
+ /** Specifies if members of the community can invite other members to the community, true if they can, false otherwise. */
46
+ invitationsEnabled: boolean | null;
47
+ /** Specifies if the community is able to have knowledgeable users on topics and knowledgeable about topics. */
48
+ knowledgeableEnabled: boolean | null;
49
+ /** Full login URL for the Community */
50
+ loginUrl: string | null;
51
+ /** Specifies whether members can see other members of the community or not.This is honored when 'Control user visibility within a community' perm is enabled */
52
+ memberVisibilityEnabled: boolean | null;
53
+ /** Community's name. */
54
+ name: string | null;
55
+ /** Specifies whether nickname display is enabled in the community or not. */
56
+ nicknameDisplayEnabled: boolean | null;
57
+ /** Specifies if members of the community can send and receive Private Messages to other members in the community, true if they can, false otherwise. */
58
+ privateMessagesEnabled: boolean | null;
59
+ /** Specifies whether Reputation is calculated and displayed for community members. */
60
+ reputationEnabled: boolean | null;
61
+ /** Specifies if a welcome email is automatically generated and sent to any new member. true if email is sent, false otherwise */
62
+ sendWelcomeEmail: boolean | null;
63
+ /** Specifies whether the community is site.com template enabled or not. */
64
+ siteAsContainerEnabled: boolean | null;
65
+ /** Site URL for the Community, which is custom domain + URL prefix. */
66
+ siteUrl: string | null;
67
+ /** Community's publish status. */
68
+ status: string | null;
69
+ /** Community’s template name. */
70
+ templateName: string | null;
71
+ /** Full URL to community. */
72
+ url: string | null;
73
+ /** Community-specific URL prefix. */
74
+ urlPathPrefix: string | null;
75
+ }
76
+ /**
77
+ * Communities are customizable public or private spaces for employees, customers, and partners to collaborate on best practices and business processes.
78
+ *
79
+ * Keys:
80
+ * id (string | null): id
81
+ */
82
+ export interface CommunityRepresentation {
83
+ allowChatterAccessWithoutLogin: boolean | null;
84
+ allowMembersToFlag: boolean | null;
85
+ builderBasedSnaEnabled: boolean | null;
86
+ builderUrl: string | null;
87
+ contentSpaceId: string | null;
88
+ description: string | null;
89
+ guestMemberVisibilityEnabled: boolean | null;
90
+ id: string | null;
91
+ imageOptimizationCDNEnabled: boolean | null;
92
+ invitationsEnabled: boolean | null;
93
+ knowledgeableEnabled: boolean | null;
94
+ loginUrl: string | null;
95
+ memberVisibilityEnabled: boolean | null;
96
+ name: string | null;
97
+ nicknameDisplayEnabled: boolean | null;
98
+ privateMessagesEnabled: boolean | null;
99
+ reputationEnabled: boolean | null;
100
+ sendWelcomeEmail: boolean | null;
101
+ siteAsContainerEnabled: boolean | null;
102
+ siteUrl: string | null;
103
+ status: string | null;
104
+ templateName: string | null;
105
+ url: string | null;
106
+ urlPathPrefix: string | null;
107
+ }
108
+ export declare const notifyUpdateAvailableFactory: (luvio: $64$luvio_engine_Luvio) => (configs: Partial<KeyParams>[]) => Promise<void>;
@@ -0,0 +1,32 @@
1
+ import { NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata } from '@luvio/engine';
2
+ export declare const ObjectKeys: {
3
+ (o: object): string[];
4
+ (o: {}): string[];
5
+ }, ObjectCreate: {
6
+ (o: object | null): any;
7
+ (o: object | null, properties: PropertyDescriptorMap & ThisType<any>): any;
8
+ }, ObjectAssign: {
9
+ <T extends {}, U>(target: T, source: U): T & U;
10
+ <T_1 extends {}, U_1, V>(target: T_1, source1: U_1, source2: V): T_1 & U_1 & V;
11
+ <T_2 extends {}, U_2, V_1, W>(target: T_2, source1: U_2, source2: V_1, source3: W): T_2 & U_2 & V_1 & W;
12
+ (target: object, ...sources: any[]): any;
13
+ };
14
+ export declare const ArrayIsArray: (arg: any) => arg is any[];
15
+ export declare const JSONStringify: {
16
+ (value: any, replacer?: ((this: any, key: string, value: any) => any) | undefined, space?: string | number | undefined): string;
17
+ (value: any, replacer?: (string | number)[] | null | undefined, space?: string | number | undefined): string;
18
+ };
19
+ type AllowedPrimitives = boolean | string | number | Date | null;
20
+ type Value<T> = T extends AllowedPrimitives ? T : RecursivePartial<T>;
21
+ export type RecursivePartial<T> = null | {
22
+ [P in keyof T]?: T[P] extends Array<infer U> ? Array<Value<U>> | null : Value<T[P]> | null;
23
+ };
24
+ export declare function equalsArray<U, V extends U[]>(a: V, b: V, equalsItem: (itemA: U, itemB: U) => boolean | void): boolean;
25
+ export declare function equalsObject<U, V extends {
26
+ [key: string]: U;
27
+ }>(a: V, b: V, equalsProp: (propA: U, propB: U) => boolean | void): boolean;
28
+ export declare function createLink(ref: string | $64$luvio_engine_NormalizedKeyMetadata): {
29
+ __ref: string;
30
+ };
31
+ export declare function assignMetadataLink(entry: any, metadataKey: string | $64$luvio_engine_NormalizedKeyMetadata): void;
32
+ export {};
package/package.json ADDED
@@ -0,0 +1,76 @@
1
+ {
2
+ "name": "@salesforce/lds-adapters-community-info",
3
+ "version": "0.1.0-dev1",
4
+ "license": "SEE LICENSE IN LICENSE.txt",
5
+ "description": "Gets info about the community",
6
+ "main": "dist/es/es2018/community-info.js",
7
+ "module": "dist/es/es2018/community-info.js",
8
+ "types": "dist/es/es2018/types/src/generated/artifacts/main.d.ts",
9
+ "files": [
10
+ "dist",
11
+ "sfdc",
12
+ "src/raml/*"
13
+ ],
14
+ "exports": {
15
+ ".": {
16
+ "types": "./dist/es/es2018/types/src/generated/artifacts/main.d.ts",
17
+ "import": "./dist/es/es2018/community-info.js",
18
+ "require": "./dist/es/es2018/community-info.js"
19
+ },
20
+ "./sfdc": {
21
+ "types": "./sfdc/index.d.ts",
22
+ "import": "./sfdc/index.js",
23
+ "default": "./sfdc/index.js"
24
+ }
25
+ },
26
+ "contributors": [
27
+ "lei.dai@salesforce.com"
28
+ ],
29
+ "sfdc": {
30
+ "path": "forcelds/ldsAdaptersCommunityInfo/",
31
+ "namespace": "lightning",
32
+ "module": "communityInfoApi"
33
+ },
34
+ "scripts": {
35
+ "build": "yarn build:services",
36
+ "build:karma": "rollup --bundleConfigAsCjs --config rollup.config.karma.js",
37
+ "build:raml": "luvio generate src/raml/luvio.raml src/generated -p '../lds-compiler-plugins'",
38
+ "build:services": "rollup --bundleConfigAsCjs --config rollup.config.js",
39
+ "clean": "rm -rf dist sfdc src/generated karma/dist",
40
+ "release:core": "../../scripts/release/core.js --adapter=lds-adapters-community-info",
41
+ "release:corejar": "yarn build && packages/core-build/scripts/core.js --adapter=lds-adapters-community-info",
42
+ "start": "nx build:karma && karma start",
43
+ "test": "nx build:karma && karma start --single-run",
44
+ "test:unit": "jest"
45
+ },
46
+ "dependencies": {
47
+ "@salesforce/lds-bindings": "^0.1.0-dev1"
48
+ },
49
+ "devDependencies": {
50
+ "@salesforce/lds-compiler-plugins": "^0.1.0-dev1",
51
+ "@salesforce/lds-karma": "^0.1.0-dev1"
52
+ },
53
+ "nx": {
54
+ "targets": {
55
+ "build": {
56
+ "outputs": [
57
+ "{projectRoot}/dist",
58
+ "{projectRoot}/sfdc"
59
+ ]
60
+ },
61
+ "build:raml": {
62
+ "outputs": [
63
+ "{projectRoot}/src/generated"
64
+ ]
65
+ },
66
+ "build:karma": {
67
+ "outputs": [
68
+ "{projectRoot}/karma/dist"
69
+ ]
70
+ }
71
+ }
72
+ },
73
+ "volta": {
74
+ "extends": "../../package.json"
75
+ }
76
+ }
@@ -0,0 +1 @@
1
+ export * from '../dist/es/es2018/types/src/generated/artifacts/sfdc';