@openfin/workspace 24.1.0 → 24.1.2-alpha.c84bc0a1

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 (52) hide show
  1. package/client-api/src/dock.test.d.ts +1 -0
  2. package/client-api/src/internal/providers.d.ts +26 -0
  3. package/client-api-platform/src/api/app-directory.d.ts +1 -1
  4. package/client-api-platform/src/api/context-menu/index.d.ts +2 -2
  5. package/client-api-platform/src/api/controllers/storage-proxies/channel-storage-proxy.d.ts +19 -0
  6. package/client-api-platform/src/api/controllers/storage-proxies/local-storage-proxy.d.ts +12 -0
  7. package/client-api-platform/src/api/controllers/theme-storage-controller-store.d.ts +17 -0
  8. package/client-api-platform/src/api/controllers/theme-storage-controller.d.ts +25 -19
  9. package/client-api-platform/src/api/pages/index.d.ts +7 -2
  10. package/client-api-platform/src/api/theming.d.ts +2 -0
  11. package/client-api-platform/src/api/utils.d.ts +2 -7
  12. package/client-api-platform/src/init/browser-window-focus.d.ts +4 -0
  13. package/client-api-platform/src/init/index.d.ts +2 -1
  14. package/client-api-platform/src/init/override-callback/browser-defaults.d.ts +1 -1
  15. package/client-api-platform/src/init/override-callback/page-defaults.d.ts +1 -1
  16. package/client-api-platform/src/init/theming.d.ts +4 -3
  17. package/client-api-platform/src/shapes.d.ts +93 -3
  18. package/common/src/api/pages/attached.d.ts +0 -5
  19. package/common/src/api/pages/enterprise-shapes.d.ts +4 -0
  20. package/common/src/api/pages/shapes.d.ts +8 -0
  21. package/common/src/api/protocol/browser.d.ts +0 -2
  22. package/common/src/api/protocol/workspace-platform.d.ts +3 -1
  23. package/common/src/api/theming.d.ts +1 -0
  24. package/common/src/test/logger-mock.d.ts +5 -0
  25. package/common/src/utils/application.d.ts +7 -0
  26. package/common/src/utils/context-menu.d.ts +2 -2
  27. package/common/src/utils/enterprise-channels.d.ts +3 -0
  28. package/common/src/utils/env.d.ts +1 -1
  29. package/common/src/utils/indicators/showIndicator.d.ts +8 -1
  30. package/common/src/utils/indicators/workspace-indicators.d.ts +13 -0
  31. package/common/src/utils/modal-bounds.d.ts +20 -0
  32. package/common/src/utils/os.d.ts +2 -0
  33. package/common/src/utils/popup-window.d.ts +38 -21
  34. package/common/src/utils/route.d.ts +2 -0
  35. package/common/src/utils/window.d.ts +2 -1
  36. package/common/src/utils/workspace-modals.d.ts +3 -0
  37. package/dock3/src/api/protocol.d.ts +2 -0
  38. package/externals.report.json +9 -9
  39. package/home.js +1 -2
  40. package/home.js.map +1 -1
  41. package/index.js +1 -2
  42. package/index.js.map +1 -1
  43. package/notifications.js +1 -2
  44. package/notifications.js.map +1 -1
  45. package/package.json +4 -3
  46. package/store.js +1 -2
  47. package/store.js.map +1 -1
  48. package/common/src/api/tabs.d.ts +0 -16
  49. package/home.js.LICENSE.txt +0 -1
  50. package/index.js.LICENSE.txt +0 -1
  51. package/notifications.js.LICENSE.txt +0 -1
  52. package/store.js.LICENSE.txt +0 -1
@@ -50,6 +50,13 @@ export declare function showSuccess(payload: ShowSuccessPayload): Promise<void>;
50
50
  */
51
51
  export declare function showInfo(payload: ShowInfoPayload): Promise<void>;
52
52
  /**
53
- * Creates a window centered on monitor containing a success indicator for switching workspaces
53
+ * Creates a window centered on monitor containing a success indicator for switching workspaces.
54
+ * No-ops when `suppressWorkspaceSwitched` has been set via `BrowserInitConfig.indicators`.
54
55
  */
55
56
  export declare function showSwitchWorkspaceSuccess(): Promise<void>;
57
+ /**
58
+ * Creates a success indicator for workspace save and save-as operations.
59
+ * No-ops when `suppressWorkspaceSaved` has been set via `BrowserInitConfig.indicators`.
60
+ * Rename operations are intentionally unaffected — use `showSuccess` directly for those.
61
+ */
62
+ export declare const showWorkspaceSavedSuccess: (payload: ShowSuccessPayload) => Promise<void>;
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Configuration for suppressing workspace success indicators.
3
+ */
4
+ export interface WorkspaceIndicatorConfig {
5
+ /** Suppress the "Workspace Switched" indicator on all applyWorkspace calls. @default false */
6
+ suppressWorkspaceSwitched?: boolean;
7
+ /** Suppress the "Workspace Saved" indicator on regular workspace save only. Save-as and rename are unaffected. @default false */
8
+ suppressWorkspaceSaved?: boolean;
9
+ }
10
+ export declare const initWorkspaceIndicators: (config?: WorkspaceIndicatorConfig) => void;
11
+ export declare const getSuppressWorkspaceSwitched: () => boolean;
12
+ /** Returns true when the "Workspace Saved" indicator should be suppressed (save only; save-as and rename are unaffected). */
13
+ export declare const getSuppressWorkspaceSaved: () => boolean;
@@ -1,4 +1,5 @@
1
1
  import type OpenFin from '@openfin/core';
2
+ import { AnchorBehavior } from '../../../client-api-platform/src/api/context-menu';
2
3
  import { ResponseModalConfig } from './menu-config';
3
4
  import { Point } from './window';
4
5
  /**
@@ -59,3 +60,22 @@ export declare function getBoundsCenteredAndFitOnMonitor(height: number, width:
59
60
  left: number;
60
61
  top: number;
61
62
  }>;
63
+ /**
64
+ * Calculates the final popup bounds relative to a parent window, accounting for:
65
+ * - Windows 10/11 maximized window shadow offset (Electron bug)
66
+ * - Anchor behavior (e.g. BottomRight, TopLeft)
67
+ * - Off-screen clamping to keep the popup within monitor bounds
68
+ *
69
+ * @param parentIdentity - The identity of the parent window.
70
+ * @param contentDimensions - The width and height of the popup content.
71
+ * @param position - The desired x/y position relative to the parent window.
72
+ * @param anchorBehavior - Optional anchor behavior to adjust positioning.
73
+ * @returns Bounds relative to the parent window, clamped to the nearest monitor.
74
+ */
75
+ export declare const getPopupBoundsRelativeToParent: (parentIdentity: OpenFin.Identity, contentDimensions: {
76
+ width: number;
77
+ height: number;
78
+ }, position: {
79
+ x: number;
80
+ y: number;
81
+ }, anchorBehavior?: AnchorBehavior) => Promise<OpenFin.Bounds>;
@@ -1,2 +1,4 @@
1
+ /** @internal Reset cached host specs — only for test isolation */
2
+ export declare const resetHostSpecsCache: () => void;
1
3
  export declare const isOSWindows: () => Promise<boolean>;
2
4
  export declare const isWindows10Or11: () => Promise<boolean>;
@@ -39,19 +39,19 @@ export type BrowserSearchMenuKeyboardEvent = {
39
39
  altKey?: boolean;
40
40
  };
41
41
  };
42
- export declare enum EnterpriseMenuType {
42
+ export declare enum PopupWindowMenuType {
43
43
  GlobalMenu = "global-menu",
44
44
  ContextMenu = "context-menu",
45
45
  RenameSupertab = "rename-supertab",
46
46
  AddEditBookmark = "add-edit-bookmark",
47
47
  DropdownMenu = "dropdown-menu",
48
- ZoomControls = "zoom-controls"
48
+ TabSearch = "tab-search"
49
49
  }
50
50
  export type BookmarkButtonPayload = {
51
51
  selectedViewIdentity: OpenFin.Identity;
52
52
  };
53
- export type BaseEnterpriseMenuChannelMessage = {
54
- type: EnterpriseMenuType;
53
+ export type BasePopupMenuChannelMessage = {
54
+ type: PopupWindowMenuType;
55
55
  /**
56
56
  * The identity of the window the dialog/menu invocation came from.
57
57
  */
@@ -67,29 +67,35 @@ export type BaseEnterpriseMenuChannelMessage = {
67
67
  x: number;
68
68
  y: number;
69
69
  };
70
- export type ContextMenuChannelMessage = BaseEnterpriseMenuChannelMessage & {
71
- type: EnterpriseMenuType.ContextMenu | EnterpriseMenuType.GlobalMenu;
70
+ export type ContextMenuChannelMessage = BasePopupMenuChannelMessage & {
71
+ type: PopupWindowMenuType.ContextMenu | PopupWindowMenuType.GlobalMenu;
72
72
  /**
73
73
  * The unique request ID of the context menu invocation.
74
74
  */
75
75
  requestId: string;
76
76
  payload: OpenFin.ShowPopupMenuOptions;
77
77
  };
78
- export type BookmarkDialogChannelMessage = BaseEnterpriseMenuChannelMessage & {
79
- type: EnterpriseMenuType.AddEditBookmark;
78
+ export type BookmarkDialogChannelMessage = BasePopupMenuChannelMessage & {
79
+ type: PopupWindowMenuType.AddEditBookmark;
80
80
  payload: BookmarkButtonPayload;
81
81
  };
82
- export type ZoomControlsDialogPayload = {
83
- selectedViewIdentity?: OpenFin.Identity;
84
- zoomPercent?: number;
85
- openedViaMouseClick?: boolean;
86
- };
87
- export type ZoomControlsDialogChannelMessage = BaseEnterpriseMenuChannelMessage & {
88
- type: EnterpriseMenuType.ZoomControls;
89
- payload: ZoomControlsDialogPayload;
82
+ /** Sent from browser to zoom dialog window to position and hydrate UI (initial open or live sync). */
83
+ export type ZoomControlsDialogStateMessage = {
84
+ /**
85
+ * The identity of the window the dialog/menu invocation came from.
86
+ */
87
+ parentIdentity: OpenFin.Identity;
88
+ x: number;
89
+ y: number;
90
+ payload: {
91
+ selectedViewIdentity?: OpenFin.Identity;
92
+ zoomPercent?: number;
93
+ openedViaMouseClick?: boolean;
94
+ };
90
95
  };
91
- export type DropdownMenuChannelMessage = BaseEnterpriseMenuChannelMessage & {
92
- type: EnterpriseMenuType.DropdownMenu;
96
+ export declare const ZOOM_DIALOG_CHANNEL_ACTION: "state";
97
+ export type DropdownMenuChannelMessage = BasePopupMenuChannelMessage & {
98
+ type: PopupWindowMenuType.DropdownMenu;
93
99
  payload: {
94
100
  template: Array<OpenFin.MenuItemTemplate>;
95
101
  /**
@@ -98,8 +104,8 @@ export type DropdownMenuChannelMessage = BaseEnterpriseMenuChannelMessage & {
98
104
  width: number;
99
105
  };
100
106
  };
101
- export type RenameSupertabChannelMessage = BaseEnterpriseMenuChannelMessage & {
102
- type: EnterpriseMenuType.RenameSupertab;
107
+ export type RenameSupertabChannelMessage = BasePopupMenuChannelMessage & {
108
+ type: PopupWindowMenuType.RenameSupertab;
103
109
  payload: {
104
110
  /**
105
111
  * The pageId of the page being renamed.
@@ -107,6 +113,18 @@ export type RenameSupertabChannelMessage = BaseEnterpriseMenuChannelMessage & {
107
113
  pageId: string;
108
114
  };
109
115
  };
116
+ export type TabSearchModalContent = {
117
+ variant: 'page' | 'view';
118
+ tabs: {
119
+ title: string;
120
+ id: string;
121
+ }[];
122
+ };
123
+ export type TabSearchChannelMessage = BasePopupMenuChannelMessage & {
124
+ type: PopupWindowMenuType.TabSearch;
125
+ requestId: string;
126
+ payload: TabSearchModalContent;
127
+ };
110
128
  export type SearchMenuChannelResponse = {
111
129
  type: 'ready';
112
130
  } | {
@@ -135,5 +153,4 @@ export type SearchMenuChannelResponse = {
135
153
  type: 'single-provider-results-announcement';
136
154
  message: string;
137
155
  };
138
- export declare function showPopupWin<T extends keyof UserMenuParams>(parentWindow: OpenFin.Window, params: UserMenuParams[T], windowOpts: OpenFin.PopupOptions): Promise<OpenFin.PopupResult>;
139
156
  export {};
@@ -31,6 +31,7 @@ declare enum BrowserRoute {
31
31
  EnterpriseAboutPage = "/popup-menu/about/",
32
32
  StorageProxy = "/storage-proxy",
33
33
  DropdownMenu = "/dropdown-menu/",
34
+ TabSearchModal = "/popup-menu/tab-search-modal/",
34
35
  EnterpriseDock = "/dock/",
35
36
  ZoomControlsDialog = "/zoom-controls-dialog/",
36
37
  DesktopSignalsModal = "/popup-menu/desktop-signals-modal/",
@@ -54,6 +55,7 @@ declare const PageRoute: {
54
55
  EnterpriseAboutPage: BrowserRoute.EnterpriseAboutPage;
55
56
  StorageProxy: BrowserRoute.StorageProxy;
56
57
  DropdownMenu: BrowserRoute.DropdownMenu;
58
+ TabSearchModal: BrowserRoute.TabSearchModal;
57
59
  EnterpriseDock: BrowserRoute.EnterpriseDock;
58
60
  ZoomControlsDialog: BrowserRoute.ZoomControlsDialog;
59
61
  DesktopSignalsModal: BrowserRoute.DesktopSignalsModal;
@@ -19,10 +19,12 @@ export declare enum WindowName {
19
19
  DockSaveWorkspaceMenu = "openfin-dock3-save-workspace-menu",
20
20
  DropdownMenu = "openfin-enterprise-dropdown-menu",
21
21
  EnterpriseContextMenu = "openfin-enterprise-context-menu",
22
+ TabSearchMenu = "openfin-browser-tab-search-menu",
22
23
  EnterpriseBookmarkDialogWindow = "openfin-enterprise-bookmark-dialog",
23
24
  ZoomControlsDialog = "here-zoom-controls-dialog",
24
25
  UpdateVersionModal = "here-update-version-modal",
25
26
  ApplyAndPublishModal = "here-apply-and-publish-modal",
27
+ PublishOnCloseModal = "here-publish-on-close-modal",
26
28
  DesktopSignalsModal = "here-desktop-signals-modal",
27
29
  IntentsResolverModal = "here-intents-resolver-modal"
28
30
  }
@@ -144,7 +146,6 @@ export declare function animateSize(width: number, height: number): Promise<void
144
146
  * @returns boolean
145
147
  */
146
148
  export declare const isBrowserWindow: (identity: OpenFin.Identity) => Promise<any>;
147
- export declare const isModalWindowExceptZoomDialog: (identity: OpenFin.Identity) => boolean;
148
149
  /**
149
150
  * Force document body size. Called when resizing or on scaling changes.
150
151
  */
@@ -35,6 +35,9 @@ export declare const showUpdateVersionModal: ({ identity, title, description }:
35
35
  description: string;
36
36
  }) => Promise<ModalResponseEvent["data"]>;
37
37
  export declare const showApplyAndPublishModal: (identity: OpenFin.Identity) => Promise<boolean>;
38
+ export declare const showPublishOnCloseModal: (windowIdentity: OpenFin.Identity) => Promise<{
39
+ data: ModalResponseEvent["data"];
40
+ }>;
38
41
  /**
39
42
  * Shows the intents resolver modal and returns the user's selection
40
43
  * @param request - The request containing modal configuration
@@ -1,6 +1,7 @@
1
1
  import type { OpenFin } from '@openfin/core';
2
2
  import { BaseCustomDropdownItem } from '../../../client-api/src/shapes';
3
3
  import { BookmarkDockEntryPayload, DockEntry, LaunchDockEntryPayload, Collection } from '../../../client-api-platform/src/shapes';
4
+ import { WorkspaceIndicatorConfig } from '../../../common/src/utils/indicators/workspace-indicators';
4
5
  import { Dock3Config, DockCompanionButton } from '../../../dock3/src/shapes';
5
6
  /**
6
7
  * Payload for more menu custom option actions
@@ -40,6 +41,7 @@ export type Dock3ChannelClientChannelActions = {
40
41
  'navigate-content-menu': (payload: {
41
42
  targetId: string;
42
43
  }) => void;
44
+ 'handle-indicator-config': (payload: WorkspaceIndicatorConfig) => void;
43
45
  };
44
46
  /**
45
47
  * @internal
@@ -2,11 +2,19 @@
2
2
  "@openfin/notifications": [
3
3
  {
4
4
  "type": "explicit",
5
- "version": "2.14.0-alpha-4509",
5
+ "version": "2.14.0-alpha-4620",
6
6
  "packageName": "client-api/package.json",
7
7
  "issuer": "client-api/src/notifications.ts"
8
8
  }
9
9
  ],
10
+ "@openfin/microsoft365": [
11
+ {
12
+ "type": "explicit",
13
+ "version": "^1.1.0",
14
+ "packageName": "client-api/package.json",
15
+ "issuer": "client-api/src/integrations/microsoft.ts"
16
+ }
17
+ ],
10
18
  "title-case": [
11
19
  {
12
20
  "type": "explicit",
@@ -21,14 +29,6 @@
21
29
  "issuer": "common/src/utils/color-linking.ts"
22
30
  }
23
31
  ],
24
- "@openfin/microsoft365": [
25
- {
26
- "type": "explicit",
27
- "version": "^1.1.0",
28
- "packageName": "client-api/package.json",
29
- "issuer": "client-api/src/integrations/microsoft.ts"
30
- }
31
- ],
32
32
  "lodash.debounce": [
33
33
  {
34
34
  "type": "explicit",