@openfin/workspace 13.1.5 → 14.0.14

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.
Files changed (71) hide show
  1. package/README.md +14 -14
  2. package/client-api/src/dock.d.ts +46 -10
  3. package/client-api/src/home.d.ts +76 -5
  4. package/client-api/src/home.test.d.ts +1 -1
  5. package/client-api/src/index.d.ts +10 -10
  6. package/client-api/src/integrations/microsoft.shapes.d.ts +9 -9
  7. package/client-api/src/internal/home/handlers/data.d.ts +3 -0
  8. package/client-api/src/internal/home/handlers/data.test.d.ts +1 -0
  9. package/client-api/src/internal/home/handlers/disconnect.d.ts +1 -0
  10. package/client-api/src/internal/home/handlers/disconnect.test.d.ts +1 -0
  11. package/client-api/src/internal/home/handlers/index.d.ts +6 -0
  12. package/client-api/src/internal/home/handlers/index.test.d.ts +1 -0
  13. package/client-api/src/internal/home/handlers/result-dispatch.d.ts +3 -0
  14. package/client-api/src/internal/home/handlers/result-dispatch.test.d.ts +1 -0
  15. package/client-api/src/internal/home/handlers/search-close.d.ts +5 -0
  16. package/client-api/src/internal/home/handlers/search-close.test.d.ts +1 -0
  17. package/client-api/src/internal/home/index.d.ts +4 -0
  18. package/client-api/src/internal/home/requests.d.ts +5 -0
  19. package/client-api/src/internal/providers.d.ts +63 -0
  20. package/client-api/src/internal/providers.test.d.ts +1 -0
  21. package/client-api/src/internal/storefront/handlers.d.ts +9 -0
  22. package/client-api/src/internal/storefront/index.d.ts +4 -0
  23. package/client-api/src/{internal.d.ts → internal/try-dispatch.d.ts} +1 -1
  24. package/client-api/src/legacy.d.ts +4 -3
  25. package/client-api/src/shapes/common.d.ts +20 -3
  26. package/client-api/src/shapes/dock.d.ts +97 -85
  27. package/client-api/src/shapes/home.d.ts +49 -138
  28. package/client-api/src/shapes/notifications.d.ts +2 -2
  29. package/client-api/src/shapes/store.d.ts +31 -14
  30. package/client-api/src/shapes/templates.d.ts +11 -11
  31. package/client-api/src/store.d.ts +31 -15
  32. package/client-api-platform/src/init/utils.d.ts +2 -2
  33. package/client-api-platform/src/shapes.d.ts +46 -39
  34. package/common/src/api/action.d.ts +1 -1
  35. package/common/src/api/home.d.ts +25 -0
  36. package/common/src/api/pages/shapes.d.ts +6 -6
  37. package/common/src/api/protocol/browser.d.ts +1 -1
  38. package/common/src/api/protocol/shapes/search.d.ts +96 -0
  39. package/common/src/api/protocol/shapes/workspace.d.ts +13 -13
  40. package/common/src/api/protocol/workspace-platform.d.ts +1 -1
  41. package/common/src/api/protocol/workspace.d.ts +2 -0
  42. package/common/src/api/provider.d.ts +24 -9
  43. package/common/src/api/search/aggregate-search-results.d.ts +10 -0
  44. package/common/src/api/search/common.d.ts +15 -0
  45. package/common/src/api/shapes/home.d.ts +186 -0
  46. package/common/src/api/theming.d.ts +18 -6
  47. package/common/src/utils/a11y/search.a11y.d.ts +10 -10
  48. package/common/src/utils/application.d.ts +2 -2
  49. package/common/src/utils/context-menu.d.ts +1 -1
  50. package/common/src/utils/layout.d.ts +3 -3
  51. package/common/src/utils/menu-window-provider.d.ts +2 -2
  52. package/common/src/utils/route.d.ts +0 -1
  53. package/common/src/utils/snapshot.d.ts +3 -3
  54. package/common/src/utils/types.d.ts +7 -7
  55. package/common/src/utils/usage-register.d.ts +2 -2
  56. package/home.js +128 -23
  57. package/home.js.map +1 -1
  58. package/index.js +127 -22
  59. package/index.js.map +1 -1
  60. package/notifications.js +124 -19
  61. package/notifications.js.map +1 -1
  62. package/package.json +3 -3
  63. package/search-api/src/fin/shapes.d.ts +2 -2
  64. package/search-api/src/internal-shapes.d.ts +2 -0
  65. package/search-api/src/provider/remote/deregistration.d.ts +2 -1
  66. package/search-api/src/provider/remote/info.d.ts +1 -1
  67. package/search-api/src/provider/remote/registration.d.ts +1 -1
  68. package/search-api/src/shapes.d.ts +16 -21
  69. package/store.js +130 -25
  70. package/store.js.map +1 -1
  71. package/common/src/api/search.d.ts +0 -18
package/README.md CHANGED
@@ -4,20 +4,20 @@ The Workspace Client APIs enable custom integrations with OpenFin Workspace.
4
4
 
5
5
  ## Prerequisites
6
6
 
7
- - [Node.js](https://nodejs.org/en/) v16.0.0 or higher
8
- - [npm](https://www.npmjs.com/)
7
+ - [Node.js](https://nodejs.org/en/) v16.0.0 or higher
8
+ - [npm](https://www.npmjs.com/)
9
9
 
10
10
  ## Install
11
11
 
12
12
  With npm:
13
13
 
14
- ```
14
+ ```sh
15
15
  $ npm i @openfin/workspace@latest
16
16
  ```
17
17
 
18
18
  With yarn:
19
19
 
20
- ```
20
+ ```sh
21
21
  $ yarn global add @openfin/workspace
22
22
  ```
23
23
 
@@ -27,8 +27,8 @@ Prior to using Workspace, a Workspace Platform must be initialized.
27
27
 
28
28
  ### Home API
29
29
 
30
- - [Overview](https://developers.openfin.co/of-docs/docs/cli-providers)
31
- - [API Reference](https://developer.openfin.co/workspace/docs/api/latest/modules/home.html)
30
+ - [Overview](https://developers.openfin.co/of-docs/docs/cli-providers)
31
+ - [API Reference](https://developer.openfin.co/workspace/docs/api/latest/modules/home.html)
32
32
 
33
33
  ```ts
34
34
  import Home, CLIProvider from '@openfin/workspace';
@@ -64,8 +64,8 @@ searchButton.addEventListener('click', () => {
64
64
 
65
65
  ### Storefront API
66
66
 
67
- - [Overview](https://developers.openfin.co/of-docs/docs/provide-storefront-content)
68
- - [API Reference](https://developer.openfin.co/workspace/docs/api/latest/modules/store.html)
67
+ - [Overview](https://developers.openfin.co/of-docs/docs/provide-storefront-content)
68
+ - [API Reference](https://developer.openfin.co/workspace/docs/api/latest/modules/store.html)
69
69
 
70
70
  ```ts
71
71
  import { Storefront, StorefrontProvider } from "@openfin/workspace";
@@ -97,8 +97,8 @@ await Storefront.show();
97
97
 
98
98
  ### Dock API
99
99
 
100
- - [Overview](https://developers.openfin.co/of-docs/docs/dock-overview)
101
- - [API Reference](https://developer.openfin.co/workspace/docs/api/latest/modules/dock.html)
100
+ - [Overview](https://developers.openfin.co/of-docs/docs/dock-overview)
101
+ - [API Reference](https://developer.openfin.co/workspace/docs/api/latest/modules/dock.html)
102
102
 
103
103
  ```ts
104
104
  const provider: DockProvider = {
@@ -154,7 +154,7 @@ await Dock.show();
154
154
 
155
155
  ## For more information
156
156
 
157
- - [Developer guide](https://developers.openfin.co/of-docs/docs/overview-of-workspace).
158
- - [API reference](https://developer.openfin.co/workspace/docs/api/latest/index.html).
159
- - See the [workspace-starter](https://github.com/built-on-openfin/workspace-starter) project for example code.
160
- - See the [versions page](https://developer.openfin.co/versions/#/?product=Workspace) for a list of all available versions.
157
+ - [Developer guide](https://developers.openfin.co/of-docs/docs/overview-of-workspace).
158
+ - [API reference](https://developer.openfin.co/workspace/docs/api/latest/index.html).
159
+ - See the [workspace-starter](https://github.com/built-on-openfin/workspace-starter) project for example code.
160
+ - See the [versions page](https://developer.openfin.co/versions/#/?product=Workspace) for a list of all available versions.
@@ -2,9 +2,23 @@ import type { DockProvider } from './shapes/dock';
2
2
  import { DockProviderRegistration } from './shapes/dock';
3
3
  export * from './shapes/dock';
4
4
  /**
5
- * Registers a Dock provider
6
- * @returns promise - invokes action
5
+ * API function to register a Dock provider.
6
+ *
7
+ * @remarks A Workspace Platform must be initialized.
8
+ *
9
+ * @throws An error if the Workspace Platform is not initialized.
10
+ * @throws An error if a Dock provider for this Workspace Platform is already registered.
11
+ * @throws An error if the Dock provider configuration contains buttons with duplicate ids. If no ids are specified, the buttons will be assigned ids automatically.
12
+ *
13
+ * @param provider - The Dock provider to register.
14
+ *
15
+ * @returns A promise that resolves with a `DockProviderRegistration` object once the Dock provider is successfully registered. This contains the client API version, Workspace Version and a function to update the Dock provider configuration.
16
+ *
17
+ * @example Register a Dock provider with a single button.
18
+ *
7
19
  * ```ts
20
+ * import { Dock, type DockProvider } from '@openfin/workspace';
21
+ *
8
22
  * const provider: DockProvider = {
9
23
  * id: 'provider-id',
10
24
  * title: 'Sample Dock',
@@ -21,36 +35,58 @@ export * from './shapes/dock';
21
35
  * };
22
36
  *
23
37
  * await Dock.register(provider)
38
+ *
39
+ * await Dock.show()
24
40
  * ```
25
41
  */
26
42
  export declare const register: (provider: DockProvider) => Promise<DockProviderRegistration>;
27
43
  /**
28
- * API function to Deregister a Dock provider
44
+ * API function to deregister a Dock provider.
45
+ *
46
+ * @remarks A Workspace Platform must be initialized, and the Dock provider must be registered for this function to take effect.
47
+ *
48
+ * @throws an error if the provider is not registered.
29
49
  *
30
- * @returns a promise that resolves once the dock is deregistered
50
+ * @returns a promise that resolves once the Dock provider is successfully deregistered.
51
+ *
52
+ * @example Deregister a Dock provider.
31
53
  *
32
54
  * ```ts
55
+ * import { Dock } from '@openfin/workspace';
56
+ *
33
57
  * await Dock.deregister();
34
58
  * ```
35
59
  */
36
60
  export declare const deregister: () => Promise<void>;
37
61
  /**
38
- * API function to minimize Dock
62
+ * API function to show the Dock UI.
63
+ *
64
+ * @remarks A Workspace Platform must be initialized, and at least one Dock provider must be registered for this function to take effect.
39
65
  *
40
- * @returns a promise that resolves once the dock is minimized
66
+ * @returns a promise that resolves once the Dock UI is hidden
67
+ *
68
+ * @example Show a Dock provider.
41
69
  *
42
70
  * ```ts
43
- * await Dock.minimize();
71
+ * import { Dock } from '@openfin/workspace';
72
+ *
73
+ * await Dock.show();
44
74
  * ```
45
75
  */
46
76
  export declare const minimize: () => Promise<void>;
47
77
  /**
48
- * API function to show Dock
78
+ * API function to hide the Dock UI.
79
+ *
80
+ * @remarks A Workspace Platform must be initialized, and at least one Dock provider must be registered for this function to take effect.
81
+ *
82
+ * @returns a promise that resolves once the Dock UI is hidden
49
83
  *
50
- * @returns a promise that resolves once the dock is shown
84
+ * @example Hide a Dock provider.
51
85
  *
52
86
  * ```ts
53
- * await Dock.show();
87
+ * import { Dock } from '@openfin/workspace';
88
+ *
89
+ * await Dock.hide();
54
90
  * ```
55
91
  */
56
92
  export declare const show: () => Promise<void>;
@@ -2,20 +2,91 @@ import type { CLIProvider, HomeProvider } from './shapes/home';
2
2
  import { HomeRegistration } from './shapes/home';
3
3
  export * from './shapes/home';
4
4
  /**
5
- * Register a provider that can return search results to Home.
6
- * @param provider the Home provider implementation.
5
+ * API function to register a Home provider.
6
+ *
7
+ * @remarks A Workspace Platform must be initialized.
8
+ *
9
+ * @throws An error if the Workspace Platform is not initialized.
10
+ * @throws An error if a Home provider with the same `id` is already registered.
11
+ *
12
+ * @param provider - The Home provider to register.
13
+ *
14
+ * @returns A promise that resolves with a `HomeRegistration` object once the Dock provider is successfully registered. This contains the client API version, Workspace Version and a function to set the search query.
15
+ *
16
+ * @example **Register a Basic Home provider**
17
+ *
18
+ * ```ts
19
+ * import { Home, type HomeProvider } from '@openfin/workspace';
20
+ *
21
+ * const provider: HomeProvider = {
22
+ * title: "My Home Provider"
23
+ * inputPlaceholder: "Search with My Home Provider",
24
+ * icon: "https://www.openfin.co/favicon-32x32.png",
25
+ * listTitle: "My Home Provider Results",
26
+ * logoUrl: "https://www.openfin.co/favicon-32x32.png",
27
+ * id: "my-home-provider",
28
+ * onUserInput: (req, res) => {
29
+ * console.log(req.query);
30
+ * return { results: [], context: { filters: [] } }
31
+ * },
32
+ * dispatchFocusEvents: true,
33
+ * };
34
+ *
35
+ * await Home.register(provider)
36
+ *
37
+ * await Home.show()
38
+ * ```
7
39
  */
8
40
  export declare const register: (provider: HomeProvider | CLIProvider) => Promise<HomeRegistration>;
9
41
  /**
10
- * Deregister a provider.
42
+ * API function to deregister a Home provider.
43
+ *
44
+ * @remarks A Workspace Platform must be initialized, and the Home provider must be registered for this function to take effect.
45
+ *
46
+ * @throws an error if the provider is not registered.
47
+ *
11
48
  * @param providerId the Home provider ID.
49
+ *
50
+ * @returns a promise that resolves once the Home provider is successfully deregistered.
51
+ *
52
+ * @example Deregister a Home provider.
53
+ *
54
+ * ```ts
55
+ * import { Home } from '@openfin/workspace';
56
+ *
57
+ * await Home.deregister('my-home-provider');
58
+ * ```
12
59
  */
13
60
  export declare const deregister: (providerId: string) => Promise<void>;
14
61
  /**
15
- * Show the Home UI.
62
+ * API function to show the Home UI.
63
+ *
64
+ * @remarks A Workspace Platform must be initialized, and at least one Home provider must be registered for this function to take effect.
65
+ *
66
+ * @returns a promise that resolves once the Home UI is hidden
67
+ *
68
+ * @example Show a Home provider.
69
+ *
70
+ * ```ts
71
+ * import { Home } from '@openfin/workspace';
72
+ *
73
+ * await Home.show();
74
+ * ```
16
75
  */
17
76
  export declare function show(): Promise<void>;
18
77
  /**
19
- * Hide the Home UI.
78
+ * API function to hide the Home UI.
79
+ *
80
+ * @remarks A Workspace Platform must be initialized, and at least one Home provider must be registered for this function to take effect.
81
+ *
82
+ * @returns a promise that resolves once the Home UI is hidden
83
+ *
84
+ * @example Hide a Home provider.
85
+ *
86
+ * ```ts
87
+ * import { Home } from '@openfin/workspace';
88
+ *
89
+ * await Home.hide();
90
+ * ```
20
91
  */
21
92
  export declare function hide(): Promise<void>;
@@ -1 +1 @@
1
- export {};
1
+ import '@common/test/fin-mocks';
@@ -9,22 +9,22 @@ export * from './shapes/home';
9
9
  export * from './shapes/store';
10
10
  export * from './shapes/dock';
11
11
  /**
12
- Namespace for Storefront integrations.
13
- */
12
+ * Namespace for Storefront integrations.
13
+ */
14
14
  export { StorefrontAPI as Storefront };
15
15
  /**
16
- Namespace for Home integrations.
17
- */
16
+ * Namespace for Home integrations.
17
+ */
18
18
  export { HomeAPI as Home };
19
19
  /**
20
- Namespace for Dock integrations.
21
- */
20
+ * Namespace for Dock integrations.
21
+ */
22
22
  export { DockAPI as Dock };
23
23
  /**
24
- Namespace for Legacy integrations.
25
- */
24
+ * Namespace for Legacy integrations.
25
+ */
26
26
  export { LegacyAPI as Legacy };
27
27
  /**
28
- Namespace for Microflows integrations.
29
- */
28
+ * Namespace for Microflows integrations.
29
+ */
30
30
  export { IntegrationsAPI as Integrations };
@@ -148,17 +148,17 @@ export interface Microsoft365IntegrationConfig extends WorkflowIntegrationConfig
148
148
  /**
149
149
  * @internal
150
150
  */
151
- declare type MicrosoftGraphAPIHttpMethod = 'GET' | 'HEAD' | 'PATCH' | 'POST' | 'PUT' | 'DELETE';
151
+ type MicrosoftGraphAPIHttpMethod = 'GET' | 'HEAD' | 'PATCH' | 'POST' | 'PUT' | 'DELETE';
152
152
  /**
153
153
  * https://docs.microsoft.com/en-us/graph/json-batching#request-format
154
154
  * @internal
155
155
  */
156
- export declare type GraphBatchRequest = GraphBatchRequestItem[];
156
+ export type GraphBatchRequest = GraphBatchRequestItem[];
157
157
  /**
158
158
  * https://docs.microsoft.com/en-us/graph/json-batching#request-format
159
159
  * @internal
160
160
  */
161
- export declare type GraphBatchRequestItem = {
161
+ export type GraphBatchRequestItem = {
162
162
  body?: any;
163
163
  headers?: {
164
164
  [id: string]: string;
@@ -170,13 +170,13 @@ export declare type GraphBatchRequestItem = {
170
170
  /**
171
171
  * @internal
172
172
  */
173
- export declare type GraphBatchRequestResponse = {
173
+ export type GraphBatchRequestResponse = {
174
174
  responses: GraphBatchRequestResponseItem[];
175
175
  };
176
176
  /**
177
177
  * @internal
178
178
  */
179
- export declare type GraphBatchRequestResponseItem = {
179
+ export type GraphBatchRequestResponseItem = {
180
180
  body: any;
181
181
  headers: HeadersInit;
182
182
  id: string;
@@ -185,15 +185,15 @@ export declare type GraphBatchRequestResponseItem = {
185
185
  /**
186
186
  * @internal
187
187
  */
188
- export declare type GraphListResponse<T = unknown> = {
188
+ export type GraphListResponse<T = unknown> = {
189
189
  value: T[];
190
190
  };
191
191
  /** @internal */
192
- export declare type Microsoft365DocumentType = 'Email' | 'Chat Message' | 'Event' | 'Document' | 'Contact' | 'User' | 'List';
192
+ export type Microsoft365DocumentType = 'Email' | 'Chat Message' | 'Event' | 'Document' | 'Contact' | 'User' | 'List';
193
193
  /** @internal */
194
- declare type Microsoft365TypeFilterType = 'Document' | 'Contact' | 'Chat Message' | 'Message' | 'Event' | 'List';
194
+ type Microsoft365TypeFilterType = 'Document' | 'Contact' | 'Chat Message' | 'Message' | 'Event' | 'List';
195
195
  /** @internal */
196
- export declare type Microsoft365HomeSearchFilterTypeFilter = {
196
+ export type Microsoft365HomeSearchFilterTypeFilter = {
197
197
  value: Microsoft365TypeFilterType;
198
198
  isSelected: boolean;
199
199
  };
@@ -0,0 +1,3 @@
1
+ import { HomeClientApiDataRequest, HomeInternalDataResponse, HomeInternalErrorResponse, InternalDataResponse } from '../../../../../common/src/api/shapes/home';
2
+ export declare function pushDataResponse(res: InternalDataResponse): Promise<void>;
3
+ export declare function handleDataRequest(req: HomeClientApiDataRequest): Promise<HomeInternalDataResponse | HomeInternalErrorResponse>;
@@ -0,0 +1 @@
1
+ export declare function handleChannelDisconnection(): Promise<void>;
@@ -0,0 +1,6 @@
1
+ import { SearchAPIClientChannelClient } from '../../../../../common/src/api/protocol/shapes/search';
2
+ type HomeWorkspaceAPIClientChannelClient = SearchAPIClientChannelClient & {
3
+ homeChannelActionsRegistered?: boolean;
4
+ };
5
+ export declare function registerHomeChannelClientActions(channel: HomeWorkspaceAPIClientChannelClient): void;
6
+ export {};
@@ -0,0 +1,3 @@
1
+ import type OpenFin from '@openfin/core';
2
+ import type { HomeClientApiDispatchRequest } from '../../../../../common/src/api/shapes/home';
3
+ export declare function handleResultDispatch(req: HomeClientApiDispatchRequest, identity: OpenFin.Identity): Promise<void>;
@@ -0,0 +1,5 @@
1
+ import type { HomeClientApiSearchCloseRequest } from '../../../../../common/src/api/shapes/home';
2
+ /**
3
+ * Listens for search requests that have been closed.
4
+ */
5
+ export declare function handleSearchRequestClose(req: HomeClientApiSearchCloseRequest): void;
@@ -0,0 +1,4 @@
1
+ import { ProvidersMap } from '../../../../client-api/src/internal/providers';
2
+ import { CLIProvider, HomeProvider, RegisterMetaInfoInternal } from '../..';
3
+ export declare const HomeProviders: ProvidersMap<HomeProvider | CLIProvider>;
4
+ export declare const registerHomeProviderInternal: (provider: HomeProvider | CLIProvider) => Promise<RegisterMetaInfoInternal>;
@@ -0,0 +1,5 @@
1
+ import type { InternalSearchListenerRequest } from '../../../../common/src/api/shapes/home';
2
+ /**
3
+ * Map of search requests.
4
+ */
5
+ export declare const searchRequests: Map<string, InternalSearchListenerRequest>;
@@ -0,0 +1,63 @@
1
+ import { ProviderType } from '../../../common/src/api/provider';
2
+ export declare class ProviderNotRegisteredError extends Error {
3
+ constructor(providerType: ProviderType, id?: string);
4
+ }
5
+ export declare class ProviderAlreadyRegisteredError extends Error {
6
+ constructor(providerType: ProviderType, id?: string);
7
+ }
8
+ export declare class FailedToGetProviderError extends Error {
9
+ constructor(providerType: ProviderType, id?: string);
10
+ }
11
+ /**
12
+ * Utility class for managing providers.
13
+ */
14
+ export declare class ProvidersMap<T extends {
15
+ id: string;
16
+ }> {
17
+ private readonly providersMap;
18
+ private readonly providerType;
19
+ constructor(providerType: ProviderType);
20
+ /**
21
+ * Asserts that a provider is not already registered.
22
+ * @param provider The provider to check.
23
+ * @throws ProviderAlreadyRegisteredError if the provider already exists.
24
+ */
25
+ assertNotAlreadyRegistered(id: string): void;
26
+ /**
27
+ * Asserts that a provider is registered.
28
+ * @param provider The provider to check.
29
+ * @throws ProviderAlreadyRegisteredError if the provider already exists.
30
+ */
31
+ assertRegistered(id: string): void;
32
+ /**
33
+ * Gets a provider by id.
34
+ * @param id The id of the provider to get.
35
+ * @returns The provider if it exists, otherwise undefined.
36
+ */
37
+ getProvider(id: string): T | undefined;
38
+ /**
39
+ * Checks if a provider exists.
40
+ * @param id The id of the provider to check.
41
+ * @returns True if the provider exists, otherwise false.
42
+ */
43
+ hasProvider(id: string): boolean;
44
+ /**
45
+ * Sets a provider.
46
+ * @param provider The provider to set.
47
+ */
48
+ setProvider(provider: T): void;
49
+ /**
50
+ * Deletes a provider.
51
+ * @param id The id of the provider to delete.
52
+ */
53
+ deleteProvider(id: string): void;
54
+ /**
55
+ * Gets a provider by id or throws an error if it does not exist.
56
+ * @param id The id of the provider to get.
57
+ * @returns The provider if it exists.
58
+ * @throws An error if the provider does not exist.
59
+ * @see {@link ProviderNotRegisteredError}
60
+ */
61
+ getProviderOrFail(id: string): T;
62
+ clearProviders(): void;
63
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,9 @@
1
+ import { WorkspaceAPIClientChannelClient } from '../../../../common/src/api/protocol/workspace';
2
+ type StorefrontWorkspaceAPIClientChannelClient = WorkspaceAPIClientChannelClient & {
3
+ storefrontChannelActionsRegistered?: boolean;
4
+ };
5
+ /**
6
+ * Registers a channel action for each function in the Storefront provider.
7
+ */
8
+ export declare const registerStorefrontChannelClientActions: (channel: StorefrontWorkspaceAPIClientChannelClient) => void;
9
+ export {};
@@ -0,0 +1,4 @@
1
+ import { ProvidersMap } from '../../../../client-api/src/internal/providers';
2
+ import { RegisterMetaInfoInternal, StorefrontProvider } from '../../../../client-api/src/shapes';
3
+ export declare const StorefrontProviders: ProvidersMap<StorefrontProvider>;
4
+ export declare const registerStorefrontProviderInternal: (provider: StorefrontProvider) => Promise<RegisterMetaInfoInternal>;
@@ -1,4 +1,4 @@
1
- import { WorkspaceChannelAction } from '../../common/src/api/protocol/shapes/workspace';
1
+ import { WorkspaceChannelAction } from '../../../common/src/api/protocol/shapes/workspace';
2
2
  export interface ChannelDispatch {
3
3
  action: WorkspaceChannelAction;
4
4
  payload?: any;
@@ -1,3 +1,4 @@
1
- import * as workspacesApi from '../../common/src/api/workspaces';
2
- export declare const getPages: () => Promise<import("@common/api/pages/shapes").Page[]>;
3
- export declare const getWorkspaces: () => Promise<workspacesApi.Workspace[]>;
1
+ /** @deprecated */
2
+ export declare const getPages: () => unknown;
3
+ /** @deprecated */
4
+ export declare const getWorkspaces: () => unknown;
@@ -1,14 +1,31 @@
1
1
  export type { Action, DispatchedAction, DispatchedSearchResult, SearchListenerRequest, SearchListenerResponse, SearchProviderInfo, SearchResult, ScoreOrder, SearchTag, SearchProvider, UserInputListener, ResultDispatchListener, SearchResponse } from '../../../search-api/src/index';
2
2
  export type { Workspace } from '../../../common/src/api/workspaces';
3
- export type { Page, PageLayout, PageLayoutDetails, PanelConfig, PanelConfigHorizontal, PanelConfigVertical, PanelPosition } from '../../../common/src/api/pages/shapes';
4
3
  export { SearchTagBackground, ActionTrigger } from '../../../search-api/src/shapes';
5
4
  export type { ProviderInfo } from './provider';
6
5
  export type { BaseCustomButtonConfig, BaseCustomDropdownConfig, BaseCustomDropdownItem, BaseCustomDropdownItems, CustomActionSpecifier, CustomButtonConfig, CustomDropdownConfig } from '../../../common/src/api/action';
7
6
  /**
8
- * return by component.register function
7
+ * Registration meta info
8
+ *
9
+ * Returned when a Workspace component is registered.
9
10
  */
10
11
  export interface RegistrationMetaInfo {
12
+ /**
13
+ * Client API version
14
+ *
15
+ * This is the version of the Workspace client API that is being used to register the component.
16
+ */
11
17
  clientAPIVersion: string;
18
+ /**
19
+ * Workspace version
20
+ *
21
+ * This is the version of Workspace that the Workspace component is running on.
22
+ * This could be used to determine if the component is running on a version of Workspace that supports a particular feature.
23
+ */
12
24
  workspaceVersion: string;
13
25
  }
14
- export declare type RegisterMetaInfoInternal = Pick<RegistrationMetaInfo, 'workspaceVersion'>;
26
+ /**
27
+ * Response from the Workspace Provider when a component is registered.
28
+ *
29
+ * @internal
30
+ */
31
+ export type RegisterMetaInfoInternal = Pick<RegistrationMetaInfo, 'workspaceVersion'>;