@openfin/workspace-platform 45.0.14 → 45.1.0-alpha.70935252

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 (60) hide show
  1. package/284.js +2 -0
  2. package/284.js.map +1 -0
  3. package/client-api/src/internal/home/index.d.ts +1 -1
  4. package/client-api/src/internal/providers.d.ts +4 -3
  5. package/client-api-platform/src/api/app-directory.d.ts +1 -1
  6. package/client-api-platform/src/api/language.d.ts +3 -2
  7. package/client-api-platform/src/index.d.ts +2 -0
  8. package/client-api-platform/src/init/override-callback/view-components.d.ts +18 -1
  9. package/client-api-platform/src/init/override-callback/view-defaults.d.ts +2 -1
  10. package/client-api-platform/src/init/view-tab-new-tab-shortcut-usage.d.ts +2 -0
  11. package/client-api-platform/src/shapes.d.ts +106 -9
  12. package/common/src/api/home-search-host.d.ts +8 -0
  13. package/common/src/api/home-vpw-search-channel.d.ts +2 -0
  14. package/common/src/api/home-vpw-search-host.d.ts +4 -0
  15. package/common/src/api/i18next.d.ts +2 -2
  16. package/common/src/api/protocol/workspace.d.ts +1 -0
  17. package/common/src/api/theming.d.ts +1 -1
  18. package/common/src/api/workspace-events.d.ts +53 -0
  19. package/common/src/errors/AppError.d.ts +37 -0
  20. package/common/src/errors/errors.d.ts +23 -0
  21. package/common/src/errors/index.d.ts +6 -0
  22. package/common/src/errors/result.d.ts +23 -0
  23. package/common/src/errors/toAppError.d.ts +14 -0
  24. package/common/src/utils/color-linking.d.ts +38 -1
  25. package/common/src/utils/context-menu.d.ts +1 -0
  26. package/common/src/utils/layout.d.ts +9 -3
  27. package/common/src/utils/navigate.d.ts +23 -0
  28. package/common/src/utils/network-errors.d.ts +1 -0
  29. package/common/src/utils/route.d.ts +2 -0
  30. package/common/src/utils/usage-register.d.ts +15 -1
  31. package/common/src/utils/window.d.ts +3 -1
  32. package/externals.report.json +12 -12
  33. package/home-vpw/src/api/constants.d.ts +3 -0
  34. package/home-vpw/src/api/ensure-infrastructure.d.ts +6 -0
  35. package/home-vpw/src/api/index.d.ts +3 -0
  36. package/home-vpw/src/api/internal/channel-handlers.d.ts +23 -0
  37. package/home-vpw/src/api/internal/provider-registration.d.ts +8 -0
  38. package/home-vpw/src/api/internal/providers-map.d.ts +22 -0
  39. package/home-vpw/src/api/launch.d.ts +6 -0
  40. package/home-vpw/src/api/protocol.d.ts +25 -0
  41. package/home-vpw/src/api/provider.d.ts +19 -0
  42. package/home-vpw/src/api/register.d.ts +10 -0
  43. package/home-vpw/src/api/visibility.d.ts +3 -0
  44. package/index.js +1 -1
  45. package/index.js.map +1 -1
  46. package/package.json +2 -2
  47. package/storefront-vpw/src/api/constants.d.ts +2 -0
  48. package/storefront-vpw/src/api/ensure-infrastructure.d.ts +6 -0
  49. package/storefront-vpw/src/api/index.d.ts +5 -0
  50. package/storefront-vpw/src/api/internal/assert-provider-process.d.ts +2 -0
  51. package/storefront-vpw/src/api/internal/provider-registration.d.ts +7 -0
  52. package/storefront-vpw/src/api/internal/providers-map.d.ts +23 -0
  53. package/storefront-vpw/src/api/launch.d.ts +2 -0
  54. package/storefront-vpw/src/api/protocol.d.ts +29 -0
  55. package/storefront-vpw/src/api/provider.d.ts +23 -0
  56. package/storefront-vpw/src/api/register.d.ts +79 -0
  57. package/storefront-vpw/src/api/visibility.d.ts +43 -0
  58. package/storefront-vpw/src/shapes/index.d.ts +1 -0
  59. package/storefront-vpw/src/shapes/shapes.d.ts +4 -0
  60. package/workspace_platform.zip +0 -0
@@ -11,22 +11,36 @@ export declare enum ComponentName {
11
11
  Dock = "Dock",
12
12
  EnterpriseDock = "EnterpriseDock",
13
13
  Home = "Home",
14
+ HomeVpw = "HomeVpw",
14
15
  Notification = "Notification",
15
16
  Storefront = "Storefront",
16
17
  Platform = "Platform",
17
18
  Theming = "Theming",
18
19
  Microflow = "Microflow",
19
- SupertabHideShowTabs = "PRODM-318: Supertab Hide/Show Tab Headers"
20
+ SuppressWorkspaceSwitched = "SuppressWorkspaceSwitched",
21
+ SuppressWorkspaceSaved = "SuppressWorkspaceSaved",
22
+ AllowDuplicatePageTitles = "AllowDuplicatePageTitles",
23
+ PagePinning = "PagePinning",
24
+ ViewTabNewTabShortcut = "ViewTabNewTabShortcut",
25
+ SupertabHideShowTabs = "PRODM-318: Supertab Hide/Show Tab Headers",
26
+ StorefrontVpw = "PRODM-171: VPW Storefront"
20
27
  }
21
28
  export declare const registerBrowserUsage: (status: RegisterUsageStatus) => void;
22
29
  export declare const registerHomeUsage: (status: RegisterUsageStatus) => void;
23
30
  export declare const registerStorefrontUsage: (status: RegisterUsageStatus) => void;
31
+ export declare const registerHomeVpwUsage: (status: RegisterUsageStatus) => void;
24
32
  export declare const registerDockUsage: (status: RegisterUsageStatus) => void;
25
33
  export declare const registerNotificationUsage: (status: RegisterUsageStatus) => void;
26
34
  export declare const registerPlatformUsage: (status: RegisterUsageStatus) => void;
27
35
  export declare const registerThemingUsage: (status: RegisterUsageStatus) => void;
28
36
  export declare const registerMicroflowUsage: (microflowName: string, status: RegisterUsageStatus) => void;
37
+ export declare const registerSuppressWorkspaceSwitchedUsage: (status: RegisterUsageStatus) => void;
38
+ export declare const registerSuppressWorkspaceSavedUsage: (status: RegisterUsageStatus) => void;
39
+ export declare const registerAllowDuplicatePageTitlesUsage: (status: RegisterUsageStatus) => void;
40
+ export declare const registerPagePinningUsage: (status: RegisterUsageStatus) => void;
41
+ export declare const registerViewTabNewTabShortcutUsage: (status: RegisterUsageStatus) => void;
29
42
  export declare const registerSupertabHideShowTabsUsage: () => void;
43
+ export declare const registerStorefrontVpwUsage: (status: RegisterUsageStatus) => void;
30
44
  export type AnalyticsSource = 'Browser' | 'Dock' | 'Home' | 'Notification' | 'Store' | 'Platform' | 'Theming' | 'Interop';
31
45
  /**
32
46
  * Event for analytics
@@ -26,7 +26,9 @@ export declare enum WindowName {
26
26
  ApplyAndPublishModal = "here-apply-and-publish-modal",
27
27
  PublishOnCloseModal = "here-publish-on-close-modal",
28
28
  DesktopSignalsModal = "here-desktop-signals-modal",
29
- IntentsResolverModal = "here-intents-resolver-modal"
29
+ IntentsResolverModal = "here-intents-resolver-modal",
30
+ /** Browser-zone Home VPW window (platform child window). */
31
+ HomeVpw = "home-vpw"
30
32
  }
31
33
  export interface WindowIdentity {
32
34
  uuid: ApplicationUUID | string;
@@ -21,14 +21,6 @@
21
21
  "issuer": "common/src/utils/color-linking.ts"
22
22
  }
23
23
  ],
24
- "lodash.clonedeep": [
25
- {
26
- "type": "explicit",
27
- "version": "4.5.0",
28
- "packageName": "common/package.json",
29
- "issuer": "common/src/utils/layout.ts"
30
- }
31
- ],
32
24
  "react-i18next": [
33
25
  {
34
26
  "type": "explicit",
@@ -45,13 +37,15 @@
45
37
  "issuer": "common/src/api/i18next.ts"
46
38
  }
47
39
  ],
48
- "dexie": [
40
+ "lodash.clonedeep": [
49
41
  {
50
42
  "type": "explicit",
51
- "version": "^4.0.11",
43
+ "version": "4.5.0",
52
44
  "packageName": "common/package.json",
53
- "issuer": "common/src/api/pages/idb.ts"
54
- },
45
+ "issuer": "common/src/utils/layout.ts"
46
+ }
47
+ ],
48
+ "dexie": [
55
49
  {
56
50
  "type": "explicit",
57
51
  "version": "^4.0.11",
@@ -64,6 +58,12 @@
64
58
  "packageName": "dock3/package.json",
65
59
  "issuer": "dock3/src/api/idb.ts"
66
60
  },
61
+ {
62
+ "type": "explicit",
63
+ "version": "^4.0.11",
64
+ "packageName": "common/package.json",
65
+ "issuer": "common/src/api/pages/idb.ts"
66
+ },
67
67
  {
68
68
  "type": "explicit",
69
69
  "version": "^4.0.11",
@@ -0,0 +1,3 @@
1
+ import { WindowName } from '../../../common/src/utils/window';
2
+ export declare const HOME_VPW_WINDOW_NAME = WindowName.HomeVpw;
3
+ export declare const getHomeVpwChannelName: (uuid?: string) => string;
@@ -0,0 +1,6 @@
1
+ import type { CLIProvider, HomeProvider } from '../../../client-api/src/shapes';
2
+ import { HomeVpwProvider } from './provider';
3
+ /** Creates the platform channel and {@link HomeVpwProvider} instance if not already running. */
4
+ export declare const ensureHomeVpwChannel: () => Promise<HomeVpwProvider>;
5
+ /** Launches the browser-zone Home VPW window and waits for the client `ready` handshake. */
6
+ export declare const launchHomeVpwWindow: (provider: Pick<HomeProvider | CLIProvider, "id" | "title" | "icon" | "subHeader">) => Promise<void>;
@@ -0,0 +1,3 @@
1
+ export { deregister, hide, register, show } from './register';
2
+ export type { CLIProvider, HomeProvider, HomeRegistration, SetSearchQueryOptions } from './register';
3
+ export { getHomeVpwChannelName, HOME_VPW_WINDOW_NAME } from './constants';
@@ -0,0 +1,23 @@
1
+ import type OpenFin from '@openfin/core';
2
+ import { withDisconnectListener } from '../../../../common/src/utils/channels';
3
+ import { SearchAPIClientChannelClient } from '../../../../common/src/api/protocol/shapes/search';
4
+ import type { HomeClientApiDataRequest, HomeClientApiDispatchRequest, HomeClientApiSearchCloseRequest, HomeInternalDataResponse, HomeInternalErrorResponse, InternalSearchListenerRequest } from '../../../../common/src/api/shapes/home';
5
+ import { HomeVpwProvidersMap } from './providers-map';
6
+ import type { CLIProvider, HomeProvider } from '../../../../client-api/src/shapes';
7
+ export type HomeVpwChannelHandlersContext = {
8
+ providers: HomeVpwProvidersMap<HomeProvider | CLIProvider>;
9
+ searchRequests: Map<string, InternalSearchListenerRequest>;
10
+ getSearchClientAPIChannelClient: () => Promise<withDisconnectListener<SearchAPIClientChannelClient>>;
11
+ };
12
+ export type HomeVpwChannelHandlers = {
13
+ handleDataRequest: (req: HomeClientApiDataRequest) => Promise<HomeInternalDataResponse | HomeInternalErrorResponse>;
14
+ handleResultDispatch: (req: HomeClientApiDispatchRequest, identity: OpenFin.Identity) => Promise<void>;
15
+ handleSearchRequestClose: (req: HomeClientApiSearchCloseRequest) => void;
16
+ handleChannelDisconnection: () => Promise<void>;
17
+ };
18
+ export declare const createHomeVpwChannelHandlers: (ctx: HomeVpwChannelHandlersContext) => HomeVpwChannelHandlers;
19
+ type HomeVpwSearchChannelClient = withDisconnectListener<SearchAPIClientChannelClient> & {
20
+ homeVpwChannelActionsRegistered?: boolean;
21
+ };
22
+ export declare const registerHomeVpwChannelClientActions: (channel: HomeVpwSearchChannelClient, handlers: HomeVpwChannelHandlers) => void;
23
+ export {};
@@ -0,0 +1,8 @@
1
+ import type { CLIProvider, HomeProvider, RegisterMetaInfoInternal } from '../../../../client-api/src/shapes';
2
+ import { HomeVpwProvidersMap } from './providers-map';
3
+ /** VPW search providers — separate from legacy Home provider registration in client-api. */
4
+ export declare const HomeVpwProviders: HomeVpwProvidersMap<HomeProvider | CLIProvider>;
5
+ export declare const registerHomeVpwProviderInternal: (provider: HomeProvider | CLIProvider) => Promise<RegisterMetaInfoInternal>;
6
+ export declare const registerHomeVpwBuiltinProviderInternal: (provider: HomeProvider | CLIProvider) => Promise<RegisterMetaInfoInternal | void>;
7
+ export declare const deregisterHomeVpwProviderInternal: (providerId: string) => Promise<void>;
8
+ export declare const hasRegisteredHomeVpwIntegrator: () => boolean;
@@ -0,0 +1,22 @@
1
+ import { PlatformError } from '../../../../common/src/errors';
2
+ type HomeVpwProviderRecord = {
3
+ id: string;
4
+ };
5
+ export declare class HomeVpwProviderAlreadyRegisteredError extends PlatformError {
6
+ constructor(id: string);
7
+ }
8
+ /**
9
+ * In-process registry for Home VPW search provider callbacks.
10
+ * VPW-only — not shared with legacy Home provider registration in client-api.
11
+ */
12
+ export declare class HomeVpwProvidersMap<T extends HomeVpwProviderRecord> {
13
+ private readonly providersMap;
14
+ getProvider(id: string): T | undefined;
15
+ hasProvider(id: string): boolean;
16
+ assertNotAlreadyRegistered(id: string): void;
17
+ hasProviderMatching(predicate: (id: string) => boolean): boolean;
18
+ addProvider(provider: T): void;
19
+ deleteProvider(id: string): void;
20
+ getProviderOrFail(id: string): T;
21
+ }
22
+ export {};
@@ -0,0 +1,6 @@
1
+ import type { CLIProvider, HomeProvider } from '../../../client-api/src/shapes';
2
+ /**
3
+ * Create the Home VPW window from the Workspace Platform (e.g. Studio).
4
+ * Uses fin.Window.create so creation runs in the platform process — same pattern as Dock3.
5
+ */
6
+ export declare const launchHomeVpw: (provider: Pick<HomeProvider | CLIProvider, "subHeader">) => Promise<void>;
@@ -0,0 +1,25 @@
1
+ import type { OpenFin } from '@openfin/core';
2
+ type ChannelActionMap = {
3
+ [action: string]: (...args: any[]) => any;
4
+ };
5
+ type TypedChannelClient<ProviderActions extends ChannelActionMap, ClientActions extends ChannelActionMap> = Omit<OpenFin.ChannelClient, 'dispatch' | 'register'> & {
6
+ dispatch: <T extends keyof ProviderActions>(action: T, payload: Parameters<ProviderActions[T]>[0]) => Promise<Awaited<ReturnType<ProviderActions[T]>>>;
7
+ register: <T extends keyof ClientActions>(action: T, handler: (payload: Parameters<ClientActions[T]>[0], id: OpenFin.ProviderIdentity | OpenFin.ClientIdentity) => Promise<Awaited<ReturnType<ClientActions[T]>>>) => boolean;
8
+ };
9
+ type TypedChannelProvider<ProviderActions extends ChannelActionMap, ClientActions extends ChannelActionMap> = Omit<OpenFin.ChannelProvider, 'dispatch' | 'register'> & {
10
+ dispatch: <T extends keyof ClientActions>(to: OpenFin.ClientIdentity, action: T, payload: Parameters<ClientActions[T]>[0]) => Promise<Awaited<ReturnType<ClientActions[T]>>>;
11
+ register: <T extends keyof ProviderActions>(action: T, handler: (payload: Parameters<ProviderActions[T]>[0], id: OpenFin.ProviderIdentity | OpenFin.ClientIdentity) => Promise<Awaited<ReturnType<ProviderActions[T]>>>) => boolean;
12
+ };
13
+ export type SetSearchQueryPayload = {
14
+ query: string;
15
+ providerId?: string;
16
+ context?: Record<string, unknown>;
17
+ };
18
+ export type SearchInvokedPayload = {
19
+ query?: string;
20
+ providerId?: string;
21
+ context?: Record<string, unknown>;
22
+ };
23
+ export type HomeVpwChannelProvider = TypedChannelProvider<HomeVpwChannelProviderChannelActions, HomeVpwChannelClientChannelActions>;
24
+ export type HomeVpwChannelClient = TypedChannelClient<HomeVpwChannelProviderChannelActions, HomeVpwChannelClientChannelActions>;
25
+ export {};
@@ -0,0 +1,19 @@
1
+ import type { OpenFin } from '@openfin/core';
2
+ import type { HomeVpwChannelProvider } from './protocol';
3
+ export declare class HomeVpwProvider {
4
+ #private;
5
+ static getOverrideConstructor(channel: HomeVpwChannelProvider): new () => HomeVpwProvider;
6
+ static instance: HomeVpwProvider | null;
7
+ constructor(channel: HomeVpwChannelProvider);
8
+ get ready(): Promise<void>;
9
+ private ensureClientConnected;
10
+ show(): Promise<void>;
11
+ showWhenReady(): Promise<void>;
12
+ hide(): Promise<void>;
13
+ shutdown(): Promise<void>;
14
+ getWindowSync(): OpenFin.Window;
15
+ dispatchSearchInvoked(query?: string, providerId?: string, context?: Record<string, unknown>): Promise<void>;
16
+ dispatchSetSearchQuery(query: string, providerId?: string, context?: Record<string, unknown>): Promise<void>;
17
+ private registerChannelActions;
18
+ }
19
+ export type HomeVpwConstructorOverride = (Base: new () => HomeVpwProvider) => new () => HomeVpwProvider;
@@ -0,0 +1,10 @@
1
+ import type { CLIProvider, HomeProvider, HomeRegistration } from '../../../client-api/src/shapes';
2
+ export type { CLIProvider, HomeProvider, HomeRegistration, SetSearchQueryOptions } from '../../../client-api/src/shapes';
3
+ export { hide, show } from './visibility';
4
+ /**
5
+ * Register a Home VPW integrator — stands up channel, browser-zone window, and search topic registration.
6
+ * Mirrors legacy Home.register: window is created hidden; call show to display.
7
+ */
8
+ export declare const register: (provider: HomeProvider | CLIProvider) => Promise<HomeRegistration>;
9
+ export declare const deregister: (providerId: string) => Promise<void>;
10
+ export declare const registerBuiltin: (provider: HomeProvider | CLIProvider) => Promise<void>;
@@ -0,0 +1,3 @@
1
+ export declare const show: () => Promise<void>;
2
+ export declare const hide: () => Promise<void>;
3
+ export declare const showWhenReady: () => Promise<void>;