@openfin/workspace-platform 23.0.0 → 23.0.1-alpha.0966d5cc

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 (38) hide show
  1. package/client-api/src/shapes/index.d.ts +1 -1
  2. package/client-api-platform/src/api/app-directory.d.ts +1 -1
  3. package/client-api-platform/src/api/controllers/theme-storage-controller-store.d.ts +16 -2
  4. package/client-api-platform/src/api/controllers/theme-storage-controller.d.ts +26 -23
  5. package/client-api-platform/src/api/dock.d.ts +2 -2
  6. package/client-api-platform/src/api/theming.d.ts +3 -2
  7. package/client-api-platform/src/api/utils.d.ts +11 -0
  8. package/client-api-platform/src/init/override-callback/enterprise-page-required-layout-settings.d.ts +5 -0
  9. package/client-api-platform/src/init/override-callback/view-components.d.ts +1 -1
  10. package/client-api-platform/src/init/override-callback/view-defaults.d.ts +2 -1
  11. package/client-api-platform/src/init/theming.d.ts +5 -2
  12. package/client-api-platform/src/shapes.d.ts +109 -10
  13. package/common/src/api/protocol/notifications.d.ts +8 -0
  14. package/common/src/api/protocol/workspace-platform.d.ts +5 -2
  15. package/common/src/api/protocol/workspace.d.ts +2 -2
  16. package/common/src/api/shapes/notifications.d.ts +1 -0
  17. package/common/src/api/theming.d.ts +27 -14
  18. package/common/src/utils/application.d.ts +7 -0
  19. package/common/src/utils/find-in-page/findInPageChannel.d.ts +37 -0
  20. package/common/src/utils/find-in-page/showFindInPageHandler.d.ts +2 -0
  21. package/common/src/utils/global-context-menu.d.ts +7 -0
  22. package/common/src/utils/layout.d.ts +37 -8
  23. package/common/src/utils/logger.d.ts +110 -1
  24. package/common/src/utils/menu-window-provider.d.ts +7 -3
  25. package/common/src/utils/merge-deep.d.ts +1 -0
  26. package/common/src/utils/namespaced-local-storage.d.ts +4 -3
  27. package/common/src/utils/popup-window.d.ts +1 -0
  28. package/common/src/utils/route.d.ts +5 -1
  29. package/common/src/utils/theming.d.ts +6 -0
  30. package/common/src/utils/window.d.ts +12 -9
  31. package/dock3/src/api/utils.d.ts +11 -0
  32. package/dock3/src/shapes/shapes.d.ts +4 -0
  33. package/externals.report.json +20 -63
  34. package/index.js +1 -1485
  35. package/index.js.map +1 -1
  36. package/package.json +5 -12
  37. package/common/src/brand/default-brand.d.ts +0 -8
  38. package/workspace_platform.zip +0 -0
@@ -1,5 +1,5 @@
1
1
  /**
2
- * WARNING: Do not export from './notifications' here. Not unless we move 'openfin-notifications' here.
2
+ * WARNING: Do not export from './notifications' here. Not unless we move '@openfin/notifications' here.
3
3
  */
4
4
  export * from './common';
5
5
  export * from './home';
@@ -7,7 +7,7 @@ import type { LaunchAppRequest, SearchSitesRequest, SearchSitesResponse, Site }
7
7
  * @param app the app directory entry.
8
8
  * @param opts launch options.
9
9
  */
10
- export declare function launchApp({ app, target }: LaunchAppRequest): Promise<void | OpenFin.Identity | OpenFin.Application | OpenFin.View | OpenFin.Platform>;
10
+ export declare function launchApp({ app, target }: LaunchAppRequest): Promise<void | OpenFin.Identity | OpenFin.View | OpenFin.Platform | OpenFin.Application>;
11
11
  export declare const enterpriseAppDirectoryChannelClient: () => Promise<OpenFin.ChannelClient>;
12
12
  export declare function getResults(payload: {
13
13
  req: SearchSitesRequest;
@@ -1,5 +1,19 @@
1
- import { GeneratedPalettes } from '../../../../common/src/api/theming';
1
+ import { GeneratedPalettes, NotificationIndicatorColorsParsed } from '../../../../common/src/api/theming';
2
2
  import { ThemeStorageController } from '../../../../client-api-platform/src/api/controllers/theme-storage-controller';
3
3
  import { CustomThemes } from '../../../../client-api-platform/src/shapes';
4
- export declare const initialiseStoragePalettes: (customThemes: CustomThemes | undefined, isWindows: boolean) => CustomThemes | GeneratedPalettes;
4
+ /**
5
+ * Initialises the storage palettes from the custom themes. This function is called on platform init.
6
+ * This function takes both the legacy themes and the new theme system tokens and
7
+ * passes them into the theme engine to generate the css variables.
8
+ *
9
+ * @param customThemes the custom themes to initialise the storage palettes from.
10
+ * @param isWindows whether the operating system is Windows.
11
+ * @returns the generated palettes fromt the theme engine, theme palette sheet which is injected into the DOM, and legacy theme object if it exists.
12
+ */
13
+ export declare const initialiseStoragePalettes: (customThemes: CustomThemes | undefined, isWindows: boolean) => {
14
+ generatedPalettes: GeneratedPalettes;
15
+ themePaletteSheet: string;
16
+ legacyTheme: CustomThemes | null;
17
+ notificationIndicatorColors: NotificationIndicatorColorsParsed | null;
18
+ };
5
19
  export declare const getThemeStorageController: () => ThemeStorageController;
@@ -1,3 +1,5 @@
1
+ import { GeneratedPalettes } from '../../../../common/src/api/theming';
2
+ import { StorageProxy } from '../../../../client-api-platform/src/api/utils';
1
3
  import { ColorSchemeOptionType, CustomPaletteSet } from '../../../../client-api-platform/src/shapes';
2
4
  /**
3
5
  * Palette extensions can be used to add new variables to the palette set.
@@ -5,21 +7,8 @@ import { ColorSchemeOptionType, CustomPaletteSet } from '../../../../client-api-
5
7
  * This is particularly useful if a value uses a different palette constant depending on scheme.
6
8
  */
7
9
  export declare const getPaletteExtensions: (palette: CustomPaletteSet, paletteScheme: "light" | "dark", isWindows: boolean) => {
8
- dockExpandedContainerBorderColor: string;
9
10
  dockExpandedContainerBorderRadius: string;
10
- dockExpandedContainerBackground: string;
11
11
  fillerBackgroundColor: string;
12
- dockCompanionContainerBackground: string;
13
- dockComponentContainerBackground: string;
14
- styledDropdownActiveBackground: string;
15
- contentMenuWrapperInternalDivBorderColor: string;
16
- contentMenuItemContainerActiveBackground: string;
17
- contentMenuItemContainerHoverBackground: string;
18
- contentMenuHeaderBorderColor: string;
19
- dockCompanionSeparatorBorderColor: string;
20
- dockComponentContainerBorderColor: string;
21
- companionDockButtonActiveBackground: string;
22
- companionDockButtonHoverBackground: string;
23
12
  'computed-scrollbar-thumb-alpha': number;
24
13
  'computed-scrollbar-track-alpha': number;
25
14
  'scrollbar-thumb-rgb': string;
@@ -38,20 +27,33 @@ export declare class ThemeStorageController {
38
27
  private providerStorage;
39
28
  private darkPaletteVars?;
40
29
  private lightPaletteVars?;
41
- private workspaceStorage?;
42
30
  private themePaletteSheet?;
31
+ private generatedPalettes?;
32
+ private workspaceStorage?;
33
+ private recreateFactory?;
43
34
  constructor(providerStorage: Pick<Storage, 'getItem' | 'setItem'>);
44
- private getVarsByScheme;
45
35
  /**
46
36
  * Set the current Storage Proxy to enable Workspace Storage properties to be populated.
47
- *
48
- * Currently, we only support same Storage Based theming for same origin scenarios like EB, where the provider
49
- * is in the same origin as the workspace pages.
50
- *
51
- * A workaround that can be leveraged in cross origin scenarios (which is the majority of the workspace use case) is available in this commit: 233e843cda6cd68968fd5831fb20597e0d5bb7cc
52
- * `git revert 233e843cda6cd68968fd5831fb20597e0d5bb7cc --no-commit`
53
37
  */
54
- setWorkspaceStorage: (proxy: Pick<Storage, "setItem">) => void;
38
+ setWorkspaceStorageProxy: (proxy: StorageProxy) => void;
39
+ /**
40
+ * Set a factory to recreate the storage proxy if it was destroyed (e.g. when a new browser
41
+ * window is opened after the last one closed with preventQuitOnLastWindowClosed true).
42
+ * Called once at platform init; avoids createWindow needing URL/env dependencies.
43
+ */
44
+ setRecreateFactory: (factory: () => Promise<StorageProxy>) => void;
45
+ /**
46
+ * Close the storage proxy window and clear the reference. Called when the last browser window
47
+ * closes so the platform can quit (storage proxy would otherwise keep the process alive).
48
+ * Clears the reference before awaiting destroy() to avoid a race with ensureWorkspaceStorageProxy.
49
+ */
50
+ destroyWorkspaceStorageProxy: () => Promise<void>;
51
+ /**
52
+ * Ensure the workspace storage proxy exists, recreating via the factory set at init if it was
53
+ * previously destroyed. No-op if no factory was set (e.g. in tests). Call before using
54
+ * workspace storage (e.g. when creating a browser window).
55
+ */
56
+ ensureWorkspaceStorageProxy: () => Promise<void>;
55
57
  /**
56
58
  * Check if there's an explicit user preference stored in localStorage.
57
59
  * A user preference is indicated by the presence of a SelectedColorScheme key. Which is something assigned if you click on the Appearance dropdown.
@@ -62,7 +64,7 @@ export declare class ThemeStorageController {
62
64
  * Synchronize the current palette and scheme with workspace's storage instance if
63
65
  * storage based theming is enabled. Only syncs when user has explicitly selected a scheme.
64
66
  */
65
- trySynchronizeWorkspaceStorage: () => void;
67
+ trySynchronizeWorkspaceStorage: () => Promise<void>;
66
68
  /**
67
69
  * Set the current Palette to be used by workspace. This palette will be converted into
68
70
  * css vars and combined into a single stylesheet. This stylesheet is exposed in localstorage
@@ -87,6 +89,7 @@ export declare class ThemeStorageController {
87
89
  * @param scheme The default scheme specified in the palette
88
90
  */
89
91
  setThemeDefaultScheme(scheme: ColorSchemeOptionType): void;
92
+ setGeneratedPalettes(generatedPalettes: GeneratedPalettes): void;
90
93
  /**
91
94
  * Returns the current scheme
92
95
  * @returns 'light' | 'system' | 'dark'
@@ -1,5 +1,5 @@
1
- import { ContentMenuEntry } from '@openfin/ui-library';
2
- import { DockCompanionButton, DockEntry, LaunchDockEntryPayload, Collection } from '../../../client-api-platform/src/shapes';
1
+ import type { ContentMenuEntry } from '@openfin/ui-library';
2
+ import { Collection, DockCompanionButton, DockEntry, LaunchDockEntryPayload } from '../../../client-api-platform/src/shapes';
3
3
  export declare const DockCompanionUpdatesPrefix = "dock-companion-updates";
4
4
  export declare const refreshDockBookmarksPanel: () => Promise<void>;
5
5
  export declare const updateDockFavoriteEntries: (favorites: DockEntry[]) => Promise<void>;
@@ -1,5 +1,5 @@
1
1
  import type OpenFin from '@openfin/core';
2
- import type { GenerateThemeParams, LegacyPalettes } from '../../../common/src/api/theming';
2
+ import type { BaseThemeOptions, CustomTheme, GenerateThemeParams } from '../../../common/src/api/theming';
3
3
  import { ColorSchemeOptionType, ThemeApi } from '../../../client-api-platform/src/shapes';
4
4
  export declare const getThemingApi: (identity: OpenFin.ApplicationIdentity) => ThemeApi;
5
5
  export declare const dispatchThemeToWorkspaceProvider: (themeData: {
@@ -13,4 +13,5 @@ export declare const dispatchThemeToWorkspaceProvider: (themeData: {
13
13
  export declare const setSelectedScheme: (schemeType: ColorSchemeOptionType) => Promise<void>;
14
14
  export declare const getSelectedScheme: () => ColorSchemeOptionType | null | undefined;
15
15
  export declare const getThemePaletteSheet: () => string | undefined;
16
- export declare const mapLegacyThemeToCustomTheme: (legacyTheme: LegacyPalettes) => GenerateThemeParams;
16
+ export declare const mapLegacyThemeToCustomTheme: (legacyTheme: CustomTheme) => GenerateThemeParams;
17
+ export declare const mapLegacyBrandIcons: (legacyBrand: BaseThemeOptions["brand"]) => GenerateThemeParams[1];
@@ -1 +1,12 @@
1
1
  export declare const listenForStoreClose: () => void;
2
+ export type StorageProxy = {
3
+ setItem: (data: string, value: string) => Promise<void>;
4
+ destroy: () => Promise<void>;
5
+ };
6
+ export declare const createStorageProxy: (url: string) => Promise<StorageProxy>;
7
+ /**
8
+ * Ensure the workspace storage proxy window exists. Recreates it if it was previously destroyed
9
+ * (e.g. when the last browser window closed with preventQuitOnLastWindowClosed true and a new
10
+ * browser window is now being created). Uses the factory registered at init; no-op in tests.
11
+ */
12
+ export declare const ensureWorkspaceStorageProxy: () => Promise<void>;
@@ -2,4 +2,9 @@ import { PageLayout } from '../../../../common/src/api/pages/shapes';
2
2
  export type EnterprisePageRequiredLayoutSettings = {
3
3
  newTabButtonUrl: string;
4
4
  };
5
+ /**
6
+ * Applies required layout settings for enterprise pages.
7
+ * Always sets the newTabButton URL to ensure pages from storage or other sources
8
+ * have the correct landing page URL.
9
+ */
5
10
  export declare const applyEnterprisePageRequiredLayoutSettings: (requiredSettings: EnterprisePageRequiredLayoutSettings, layout: PageLayout) => void;
@@ -1,2 +1,2 @@
1
1
  import { OpenFin } from '@openfin/core';
2
- export declare const createNonLayoutViewComponents: (overrideOptions: OpenFin.PlatformWindowCreationOptions) => Promise<void>;
2
+ export declare const createNonLayoutViewComponents: (isEnterprise: boolean, overrideOptions: OpenFin.PlatformWindowCreationOptions) => Promise<void[]>;
@@ -1,7 +1,8 @@
1
1
  import type OpenFin from '@openfin/core';
2
2
  type DefaultViewOptions = Partial<OpenFin.MutableViewOptions> & {
3
3
  downloadShelf?: OpenFin.ConstWindowOptions['downloadShelf'];
4
+ hotkeys?: OpenFin.ViewOptions['hotkeys'];
4
5
  };
5
6
  export declare const DEFAULT_VIEW_OPTIONS: DefaultViewOptions;
6
- export declare function applyViewDefaults(options: Partial<OpenFin.ViewOptions>, initViewOptions?: Partial<OpenFin.ViewOptions>): any;
7
+ export declare function applyViewDefaults(options: Partial<OpenFin.ViewOptions>, initViewOptions?: Partial<OpenFin.ViewOptions>): Promise<any>;
7
8
  export {};
@@ -1,6 +1,9 @@
1
- import { GeneratedPalettes } from '../../../common/src/api/theming';
1
+ import { GeneratedPalettes, NotificationIndicatorColorsParsed } from '../../../common/src/api/theming';
2
2
  import { CustomThemes } from '../shapes';
3
- export declare const getThemes: () => CustomThemes | GeneratedPalettes;
3
+ export declare const getThemes: () => CustomThemes | null;
4
+ export declare const getGeneratedPalettes: () => GeneratedPalettes;
5
+ export declare const getThemePaletteSheet: () => string;
6
+ export declare const getNotificationIndicatorColorsInternal: () => NotificationIndicatorColorsParsed;
4
7
  /**
5
8
  * initTheming()
6
9
  * @param customThemes array of theme objects
@@ -1,11 +1,11 @@
1
1
  import type OpenFin from '@openfin/core';
2
- import { IconProps, IconType, Languages } from '@openfin/ui-library';
2
+ import type { IconProps, IconType, Languages } from '@openfin/ui-library';
3
3
  import type { AnalyticsEvent } from '../../common/src/utils/usage-register';
4
- import { CustomActionSpecifier, CustomButtonConfig } from '../../common/src/api/action';
5
- import { AddDefaultPagePayload, AttachedPage, BookmarkNode, CopyPagePayload, HandlePagesAndWindowClosePayload, HandlePagesAndWindowCloseResult, HandleSaveModalOnPageClosePayload, Page, PageLayoutsWithSelectedViews, PageWithUpdatableRuntimeAttribs, SaveModalOnPageCloseResult, SetActivePageForWindowPayload, ShouldPageClosePayload, ShouldPageCloseResult, ViewsPreventingUnloadPayload } from '../../common/src/api/pages/shapes';
6
- import { NotificationsCustomManifestOptions } from '../../common/src/api/shapes/notifications';
4
+ import type { CustomActionSpecifier, CustomButtonConfig } from '../../common/src/api/action';
5
+ import type { AddDefaultPagePayload, AttachedPage, BookmarkNode, CopyPagePayload, HandlePagesAndWindowClosePayload, HandlePagesAndWindowCloseResult, HandleSaveModalOnPageClosePayload, Page, PageLayoutsWithSelectedViews, PageWithUpdatableRuntimeAttribs, SaveModalOnPageCloseResult, SetActivePageForWindowPayload, ShouldPageClosePayload, ShouldPageCloseResult, ViewsPreventingUnloadPayload } from '../../common/src/api/pages/shapes';
6
+ import type { NotificationsCustomManifestOptions } from '../../common/src/api/shapes/notifications';
7
7
  import type { CustomThemes, GeneratedPalettes } from '../../common/src/api/theming';
8
- import { App, DockProviderConfigWithIdentity, StoreButtonConfig } from '../../client-api/src/shapes';
8
+ import type { App, DockProviderConfigWithIdentity, StoreButtonConfig } from '../../client-api/src/shapes';
9
9
  import type { WorkflowIntegration } from '../../client-api/src/shapes/integrations';
10
10
  export * from '../../dock3/src/shapes';
11
11
  export { AppManifestType } from '../../client-api/src/shapes';
@@ -13,7 +13,7 @@ export type { App, AppIntent, Image } from '../../client-api/src/shapes';
13
13
  export type { CustomActionSpecifier, CustomButtonConfig } from '../../common/src/api/action';
14
14
  export type { AttachedPage, Page, PageLayout, PageLayoutDetails, PageWithUpdatableRuntimeAttribs, PanelConfigHorizontal, PanelConfigVertical, PanelConfig, ExtendedPanelConfig, CopyPagePayload, HandleSaveModalOnPageClosePayload, SaveModalOnPageCloseResult, SetActivePageForWindowPayload, ShouldPageClosePayload, ShouldPageCloseResult, ViewsPreventingUnloadPayload } from '../../common/src/api/pages/shapes';
15
15
  export { PanelPosition } from '../../common/src/api/pages/shapes';
16
- export type { CustomThemes, CustomThemeOptions, CustomThemeOptionsWithScheme, CustomPaletteSet, BaseThemeOptions, ThemeExtension, WorkspaceThemeSet, NotificationIndicatorColorsSet, NotificationIndicatorColorsSetDarkScheme, NotificationIndicatorColorsSetLightScheme, NotificationIndicatorColorsWithScheme } from '../../common/src/api/theming';
16
+ export type { CustomThemes, CustomThemeOptions, ThemeOptions, CustomThemeOptionsWithScheme, CustomPaletteSet, BaseThemeOptions, ThemeExtension, WorkspaceThemeSet, NotificationIndicatorColorsSet, NotificationIndicatorColorsSetDarkScheme, NotificationIndicatorColorsSetLightScheme, NotificationIndicatorColorsWithScheme } from '../../common/src/api/theming';
17
17
  export type { AnalyticsEvent } from '../../common/src/utils/usage-register';
18
18
  export type { WorkflowIntegration } from '../../client-api/src/shapes/integrations';
19
19
  /**
@@ -119,6 +119,7 @@ export declare enum GlobalContextMenuOptionType {
119
119
  Downloads = "Downloads",
120
120
  OpenStorefront = "OpenStorefront",
121
121
  ManageDesktopSignals = "ManageDesktopSignals",
122
+ FindInPage = "FindInPage",
122
123
  Appearance = "Appearance",
123
124
  Quit = "Quit",
124
125
  Custom = "Custom"
@@ -222,6 +223,40 @@ export type OpenGlobalContextMenuPayload = OpenGlobalContextMenuRequest & {
222
223
  callback: (data: GlobalContextMenuItemData, payload: OpenGlobalContextMenuPayload) => any;
223
224
  };
224
225
  export type ViewTabContextMenuTemplate = OpenFin.MenuItemTemplate<ViewTabMenuData>;
226
+ /**
227
+ * UI elements within a view tab that can be navigated to via keyboard.
228
+ */
229
+ export type ViewTabElements = 'inactive-tab' | 'active-tab' | 'inactive-tab-close-button' | 'active-tab-close-button' | 'add-tab-button';
230
+ /**
231
+ * Configuration options for view tab keyboard navigation behavior.
232
+ */
233
+ export interface ViewTabOptions {
234
+ /**
235
+ * Elements in the view tab that are able to be focused using
236
+ * arrow keys when an element in the view is selected.
237
+ * The order of the items in the array have no impact.
238
+ * Note: these are not mutually exclusive and can overlap.
239
+ * Default (when undefined): ["inactive-tab","active-tab","active-tab-close-button","inactive-tab-close-button","add-tab-button"]
240
+ */
241
+ arrowNavigation?: ViewTabElements[];
242
+ /**
243
+ * Elements in the view tab that are able to be focused using
244
+ * tab and shift+tab when an element in the view is selected.
245
+ * The order of the items in the array have no impact.
246
+ * Note: these are not mutually exclusive and can overlap.
247
+ * Default (when undefined): ["active-tab","add-tab-button"]
248
+ */
249
+ tabNavigation?: ViewTabElements[];
250
+ }
251
+ /**
252
+ * Configuration options for accessibility features in the Browser.
253
+ */
254
+ export interface AccessibilityOptions {
255
+ /**
256
+ * View tab keyboard navigation options.
257
+ */
258
+ viewTabOptions?: ViewTabOptions;
259
+ }
225
260
  /**
226
261
  * Request for opening a view tab context menu in Browser.
227
262
  */
@@ -363,6 +398,7 @@ export declare enum BrowserButtonType {
363
398
  LockUnlockPage = "LockUnlockPage",
364
399
  SaveMenu = "SaveMenu",
365
400
  SavePage = "SavePage",
401
+ Download = "Download",
366
402
  Minimise = "Minimise",
367
403
  Maximise = "Maximise",
368
404
  Close = "Close",
@@ -628,6 +664,30 @@ export interface BrowserWorkspacePlatformWindowOptions {
628
664
  minWidth?: string;
629
665
  maxWidth?: string;
630
666
  };
667
+ /**
668
+ * Accessibility options for the browser window.
669
+ * These options override the default accessibility options set at the platform or browser initialization level.
670
+ *
671
+ * @example
672
+ * ```ts
673
+ * import * as WorkspacePlatform from '@openfin/workspace-platform';
674
+ *
675
+ * const platform = WorkspacePlatform.getCurrentSync();
676
+ * const browserWin = platform.Browser.createWindow({
677
+ * ...,
678
+ * workspacePlatform: {
679
+ * ...,
680
+ * accessibilityOptions: {
681
+ * viewTabOptions: {
682
+ * arrowNavigation: ["inactive-tab", "active-tab"],
683
+ * tabNavigation: ["active-tab"]
684
+ * }
685
+ * }
686
+ * }
687
+ * });
688
+ * ```
689
+ */
690
+ accessibilityOptions?: AccessibilityOptions;
631
691
  /**
632
692
  * Use when you want to display navigation buttons in Browser toolbar. Disabled by default.
633
693
  *
@@ -1418,12 +1478,27 @@ export interface LaunchAppRequest {
1418
1478
  target?: OpenFin.EntityInfo;
1419
1479
  app: App;
1420
1480
  }
1421
- /**
1422
- * Get Themes from API
1423
- */
1424
1481
  export interface ThemeApi {
1425
- getThemes(): Promise<CustomThemes | GeneratedPalettes>;
1482
+ /**
1483
+ * @deprecated This method is deprecated. It is recommended to use {@link getGeneratedPalettes} instead.
1484
+ * Get the legacy themes from the platform provider.
1485
+ * @returns the legacy themes or null if the platform provider is using the new theme system.
1486
+ */
1487
+ getThemes(): Promise<CustomThemes | null>;
1488
+ /**
1489
+ * Get the generated palettes from the platform provider.
1490
+ * @returns the generated palettes.
1491
+ */
1492
+ getGeneratedPalettes(): Promise<GeneratedPalettes>;
1493
+ /**
1494
+ * Set the selected scheme for the platform provider.
1495
+ * @param newScheme the new scheme to set.
1496
+ */
1426
1497
  setSelectedScheme(newScheme: ColorSchemeOptionType): Promise<void>;
1498
+ /**
1499
+ * Get the selected scheme from the platform provider.
1500
+ * @returns the selected scheme.
1501
+ */
1427
1502
  getSelectedScheme(): Promise<ColorSchemeOptionType>;
1428
1503
  }
1429
1504
  /**
@@ -1591,6 +1666,7 @@ export interface WorkspacePlatformModule extends OpenFin.Platform {
1591
1666
  setLanguage(locale: Locale): Promise<void>;
1592
1667
  /**
1593
1668
  * Implementation for getting the notifications workspace platform configuration.
1669
+ * @deprecated Notifications config is now part of the platform manifest and is automatically resolved by the notifications API. Do not use this method as it will not return the correct configuration.
1594
1670
  */
1595
1671
  getNotificationsConfig(): Promise<NotificationsCustomManifestOptions | undefined>;
1596
1672
  /**
@@ -2085,6 +2161,7 @@ export interface WorkspacePlatformInitConfig {
2085
2161
  /**
2086
2162
  * Config for overriding default notifications behaviour.
2087
2163
  * Leave undefined to use OpenFin hosted Notification Center.
2164
+ * @deprecated Notifications config is now part of the platform manifest and is automatically resolved by the notifications API. Do not use this property as it will not have any effect.
2088
2165
  */
2089
2166
  notifications?: NotificationsCustomManifestOptions;
2090
2167
  /**
@@ -2264,6 +2341,28 @@ export interface BrowserInitConfig {
2264
2341
  * that are PNGs you will need to update these assets for best results.
2265
2342
  */
2266
2343
  browserIconSize?: IconSize;
2344
+ /**
2345
+ * Default accessibility options that will be applied to all browser windows.
2346
+ * These options can be overridden at the window creation level via workspacePlatform.accessibilityOptions.
2347
+ *
2348
+ * @example
2349
+ * ```ts
2350
+ * import * as WorkspacePlatform from '@openfin/workspace-platform';
2351
+ *
2352
+ * await WorkspacePlatform.init({
2353
+ * browser: {
2354
+ * title: "My Browser",
2355
+ * accessibilityOptions: {
2356
+ * viewTabOptions: {
2357
+ * arrowNavigation: ["inactive-tab", "active-tab"],
2358
+ * tabNavigation: ["active-tab"]
2359
+ * }
2360
+ * }
2361
+ * }
2362
+ * });
2363
+ * ```
2364
+ */
2365
+ accessibilityOptions?: AccessibilityOptions;
2267
2366
  /**
2268
2367
  * Override workspace platform behavior
2269
2368
  *
@@ -1,5 +1,6 @@
1
1
  import type OpenFin from '@openfin/core';
2
2
  import { ColorSchemeOptionType } from '../../../../client-api-platform/src/shapes';
3
+ import { NotificationsCustomManifestOptions } from '../shapes/notifications';
3
4
  export declare const NOTIFICATIONS_SYNC_CHANNEL = "of-workspace-notifications-sync";
4
5
  export declare enum NotificationsChannelAction {
5
6
  UpdatePlatformThemeScheme = "update-platform-theme-scheme"
@@ -10,5 +11,12 @@ export interface UpdatePlatformSchemePayload {
10
11
  interface NotificationsSyncChannelClient extends OpenFin.ChannelClient {
11
12
  dispatch(action: NotificationsChannelAction.UpdatePlatformThemeScheme, payload: UpdatePlatformSchemePayload): Promise<void>;
12
13
  }
14
+ export type ManifestNotificationsConfig = {
15
+ notifications?: {
16
+ customManifest?: NotificationsCustomManifestOptions;
17
+ };
18
+ };
19
+ export declare function getNotificationCenterUuid(): Promise<string>;
20
+ export declare function getSyncChannelName(): Promise<string>;
13
21
  export declare const getNotificationsSyncChannelClient: () => Promise<NotificationsSyncChannelClient>;
14
22
  export {};
@@ -35,6 +35,8 @@ export declare enum WorkspacePlatformChannelAction {
35
35
  GetLastFocusedBrowserWindow = "getLastFocusedBrowserWindow",
36
36
  GetPageByViewIdentity = "getPageByViewIdentity",
37
37
  GetThemes = "getThemes",
38
+ GetGeneratedPalettes = "getGeneratedPalettes",
39
+ GetThemePaletteSheet = "getThemePaletteSheet",
38
40
  GetSelectedScheme = "getSelectedScheme",
39
41
  SetSelectedScheme = "setSelectedScheme",
40
42
  OpenGlobalContextMenuInternal = "openGlobalContextMenuInternal",
@@ -78,7 +80,7 @@ export declare enum WorkspacePlatformChannelAction {
78
80
  HandleRequestNavigationInternal = "handleRequestNavigationInternal",// Enterprise
79
81
  RefreshBookmarksInternal = "refreshBookmarksInternal",// Enterprise
80
82
  LaunchBookmarkInternal = "launchBookmarkInternal",// Enterprise
81
- GetNotificationsConfig = "getNotificationsConfig",
83
+ GetNotificationsConfig = "getNotificationsConfig",// Deprecated
82
84
  UpdateDockFavoritesInternal = "updateDockFavoritesInternal",// Enterprise
83
85
  UpdateContentMenuInternal = "updateContentMenuInternal",// Enterprise
84
86
  LaunchDockEntryInternal = "launchDockEntryInternal",// Enterprise
@@ -93,7 +95,8 @@ export declare enum WorkspacePlatformChannelAction {
93
95
  AddDockFavoriteInternal = "addDockFavoriteInternal",// Enterprise
94
96
  FocusAndExpandSearchInternal = "focusAndExpandSearchInternal",// Enterprise
95
97
  SendUpdateVersionModalResponseInternal = "sendUpdateVersionModalResponseInternal",// Enterprise
96
- ShowUpdateVersionModalInternal = "showUpdateVersionModalInternal"
98
+ ShowUpdateVersionModalInternal = "showUpdateVersionModalInternal",// Enterprise
99
+ GetNotificationIndicatorColorsInternal = "getNotificationIndicatorColorsInternal"
97
100
  }
98
101
  export type PlatFormSupportedFeatures = boolean | {
99
102
  isWorkspacePlatform: boolean;
@@ -19,8 +19,8 @@ export declare const launchProvider: () => Promise<void>;
19
19
  */
20
20
  export declare const getChannelClientAndLaunchProvider: () => Promise<WorkspaceComponentChannelClient>;
21
21
  /**
22
- * Launches the Workspace provider if it is not running.
22
+ * Gets the theme data from the Platform provider, then launches the Workspace provider if it is not running, and then dispatches the theme data to the Workspace provider.
23
23
  * Then gets a Channel Client that is connected to the Workspace Provider.
24
24
  * @returns the Channel Client that is connected to the Workspace Provider.
25
25
  */
26
- export declare const getClientAPIChannelClientAndLaunchProvider: () => Promise<WorkspaceAPIClientChannelClient>;
26
+ export declare const getChannelClientAndInitializeWorkspaceProvider: () => Promise<WorkspaceAPIClientChannelClient>;
@@ -1,5 +1,6 @@
1
1
  /**
2
2
  * Options for using privately hosted notification service.
3
+ * @deprecated Custom manifest is now part of the platform manifest and is automatically resolved by the notifications API. Do not use this type as it will be ignored.
3
4
  */
4
5
  export type NotificationsCustomManifestOptions = {
5
6
  /**
@@ -1,8 +1,13 @@
1
1
  import type { DefaultTheme } from 'styled-components';
2
2
  import type OpenFin from '@openfin/core';
3
- import { type ColorSchemeType, type ThemeSet, Palette } from '@openfin/ui-library';
3
+ import type { ColorSchemeType, ThemeSet } from '@openfin/ui-library';
4
4
  import { ColorSchemeOptionType } from '../../../client-api-platform/src/shapes';
5
5
  import type { generateTheme } from '@openfin/theme-engine';
6
+ export declare const ColorScheme: {
7
+ light: string;
8
+ dark: string;
9
+ system: string;
10
+ };
6
11
  export type WorkspaceComponentSetSelectedSchemePayload = {
7
12
  newScheme: ColorSchemeOptionType;
8
13
  identity: OpenFin.Identity;
@@ -35,6 +40,13 @@ export interface NotificationIndicatorColorsSetLightScheme {
35
40
  dark?: NotificationIndicatorColorsSet;
36
41
  light: NotificationIndicatorColorsSet;
37
42
  }
43
+ export type NotificationIndicatorColors = Record<string, Omit<NotificationIndicatorColorsSet, 'foreground'> & {
44
+ foreground: string;
45
+ }>;
46
+ export type NotificationIndicatorColorsParsed = {
47
+ dark: NotificationIndicatorColors;
48
+ light: NotificationIndicatorColors;
49
+ };
38
50
  export type NotificationIndicatorColorsWithScheme = Record<string, NotificationIndicatorColorsSetDarkScheme | NotificationIndicatorColorsSetLightScheme>;
39
51
  export interface BaseThemeOptions {
40
52
  label: string;
@@ -65,7 +77,7 @@ export type CustomThemeOptions = BaseThemeOptions & {
65
77
  * };
66
78
  * ```
67
79
  */
68
- notificationIndicatorColors?: Record<string, NotificationIndicatorColorsSet>;
80
+ notificationIndicatorColors?: NotificationIndicatorColors;
69
81
  };
70
82
  export type CustomThemeOptionsWithScheme = BaseThemeOptions & {
71
83
  /**
@@ -124,12 +136,16 @@ export type CustomThemeOptionsWithScheme = BaseThemeOptions & {
124
136
  export type ThemeOptions = BaseThemeOptions & {
125
137
  seed: Parameters<typeof generateTheme>[0];
126
138
  overrides?: Parameters<typeof generateTheme>[1];
139
+ default?: Exclude<ColorSchemeOptionType, 'system'>;
140
+ } & {
141
+ notificationIndicatorColors?: NotificationIndicatorColorsWithScheme | NotificationIndicatorColors;
127
142
  };
128
143
  type GenerateThemeReturn = ReturnType<typeof generateTheme>;
129
144
  export type GeneratedPalettes = Pick<GenerateThemeReturn, 'dark' | 'light'>;
130
145
  export type LegacyPalettes = CustomThemeOptions | CustomThemeOptionsWithScheme;
131
146
  export type GenerateThemeParams = Parameters<typeof generateTheme>;
132
- export type CustomThemes = (CustomThemeOptions | CustomThemeOptionsWithScheme | ThemeOptions)[];
147
+ export type CustomTheme = CustomThemeOptions | CustomThemeOptionsWithScheme | ThemeOptions;
148
+ export type CustomThemes = CustomTheme[];
133
149
  export interface PreloadedThemeData {
134
150
  themes: CustomThemes | GeneratedPalettes;
135
151
  selectedScheme: ColorSchemeOptionType;
@@ -274,17 +290,14 @@ export declare const OpenFinDarkTheme: {
274
290
  borderNeutral: "#C0C1C2";
275
291
  };
276
292
  export declare const DefaultOpenFinTheme: CustomThemes;
277
- export declare const getComputedPaletteSets: (customTheme: CustomThemeOptions | CustomThemeOptionsWithScheme) => WorkspaceThemeSet;
278
- /**
279
- * Transforms input {@link CustomThemes} to {@link ComputedThemes} used by Workspace Platform / Notifications Platform.
280
- *
281
- * @param customThemes array of themes to transform
282
- * @param storedScheme sets the default scheme if provided
283
- * @returns array of {@link ComputedThemes | computed themes}
284
- */
285
- export declare const computeThemes: (customThemes: CustomThemes | GeneratedPalettes, storedScheme?: ColorSchemeOptionType) => ComputedThemes;
286
- export declare const getComputedPlatformTheme: (platformIdentity: OpenFin.Identity) => Promise<ComputedTheme>;
293
+ export declare const parseNotificationIndicatorColors: (customTheme: CustomTheme) => NotificationIndicatorColorsParsed;
294
+ export declare const constructThemePaletteSheet: (themes: GeneratedPalettes) => string;
295
+ export declare const getComputedPlatformTheme: (platformIdentity: OpenFin.Identity) => Promise<{
296
+ theme: CustomThemes | GeneratedPalettes;
297
+ defaultScheme: ColorSchemeOptionType;
298
+ themePaletteSheet: string;
299
+ }>;
287
300
  export declare const setSelectedScheme: (ctx: ColorSchemeOptionType) => Promise<void>;
288
301
  export declare const getComputedScheme: (identity?: OpenFin.Identity) => Promise<Exclude<ColorSchemeType, "system">>;
289
- export declare const getComputedBackgroundColor: (paletteKey: keyof typeof Palette, defaultColor?: string) => Promise<string>;
302
+ export declare const getComputedBackgroundColor: (platformIdentity: OpenFin.Identity) => Promise<string>;
290
303
  export {};
@@ -23,3 +23,10 @@ export type ApplicationInfoExtended = OpenFin.ApplicationInfo & {
23
23
  };
24
24
  export declare const getCurrentOFApplication: () => OpenFin.Application;
25
25
  export declare const getWorkspaceOFApplication: () => OpenFin.Application;
26
+ /**
27
+ * Gets the application manifest, caching the result after the first call.
28
+ * The manifest never changes during the application lifecycle, so this avoids redundant async calls.
29
+ * Uses promise-based caching to prevent race conditions when multiple calls occur before the first completes.
30
+ * @returns A Promise resolving to the application manifest
31
+ */
32
+ export declare const getCachedManifest: () => Promise<OpenFin.Manifest>;
@@ -0,0 +1,37 @@
1
+ export type FindInPageChannelMessagePayload = {
2
+ type: 'close';
3
+ } | {
4
+ type: 'find-text-changed';
5
+ value: string;
6
+ } | {
7
+ type: 'focus-input';
8
+ } | {
9
+ type: 'hide-from-search-menu';
10
+ } | {
11
+ type: 'next-result';
12
+ } | {
13
+ type: 'previous-result';
14
+ } | {
15
+ type: 'show';
16
+ } | {
17
+ type: 'update-state';
18
+ currentResultIndex?: number | null;
19
+ totalResults?: number | null;
20
+ value?: string | null;
21
+ } | {
22
+ type: 'view-ready';
23
+ } | {
24
+ type: 'window-ready';
25
+ };
26
+ /**
27
+ * Closes the find in page channel
28
+ */
29
+ export declare const closeFindInPageChannel: (channel: BroadcastChannel) => void;
30
+ /**
31
+ * Creates a new find in page channel
32
+ */
33
+ export declare const createFindInPageChannel: (windowName?: string) => Promise<BroadcastChannel>;
34
+ /**
35
+ * Sends a message via the find in page channel
36
+ */
37
+ export declare const sendFindInPageMessage: (channel: BroadcastChannel, message: FindInPageChannelMessagePayload) => void;
@@ -0,0 +1,2 @@
1
+ import type OpenFin from '@openfin/core';
2
+ export declare const showFindInPageInTargetWindow: (windowIdentity: OpenFin.Identity) => Promise<void>;
@@ -74,6 +74,13 @@ export declare const manageDesktopSignals: () => {
74
74
  type: WP.GlobalContextMenuOptionType;
75
75
  };
76
76
  };
77
+ export declare const findInPage: () => {
78
+ type: MenuItemType;
79
+ label: string;
80
+ data: {
81
+ type: WP.GlobalContextMenuOptionType;
82
+ };
83
+ };
77
84
  export declare const renameWorkspace: () => {
78
85
  type: MenuItemType;
79
86
  label: string;