@openfin/workspace 18.1.30 → 19.0.0
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.
- package/client-api-platform/src/api/app-directory.d.ts +0 -4
- package/client-api-platform/src/api/context-menu/browser-pagetab-handler.d.ts +1 -1
- package/client-api-platform/src/api/context-menu/index.d.ts +4 -10
- package/client-api-platform/src/shapes.d.ts +22 -69
- package/common/src/api/protocol/browser.d.ts +1 -2
- package/common/src/api/protocol/workspace-platform.d.ts +1 -1
- package/common/src/utils/context-menu.d.ts +1 -4
- package/common/src/utils/route.d.ts +1 -2
- package/common/src/utils/window.d.ts +0 -1
- package/home.js +7 -120
- package/home.js.map +1 -1
- package/index.js +2 -115
- package/index.js.map +1 -1
- package/notifications.js +42 -155
- package/notifications.js.map +1 -1
- package/package.json +3 -3
- package/store.js +7 -120
- package/store.js.map +1 -1
- package/common/src/utils/enterprise-context-menu-cahnnels.d.ts +0 -4
- package/common/src/utils/menu.d.ts +0 -22
- package/common/src/utils/popup-window.d.ts +0 -59
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import type OpenFin from '@openfin/core';
|
|
2
|
-
import { App } from '../../../client-api/src/shapes';
|
|
3
2
|
import type { LaunchAppRequest, SearchSitesRequest, SearchSitesResponse, Site } from '../shapes';
|
|
4
3
|
/**
|
|
5
4
|
* Launch the app described by an App Directory entry.
|
|
@@ -16,6 +15,3 @@ export declare function getResults(payload: {
|
|
|
16
15
|
export declare function getCuratedContent(payload: {
|
|
17
16
|
identity: OpenFin.Identity;
|
|
18
17
|
}): Promise<Site[]>;
|
|
19
|
-
export declare function getRecentlyVisited(payload: {
|
|
20
|
-
identity: OpenFin.Identity;
|
|
21
|
-
}): Promise<App[]>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { OpenPageTabContextMenuPayload } from '../../../../client-api-platform/src/index';
|
|
2
2
|
import { PageTabContextMenuItemData } from '../../../../client-api-platform/src/shapes';
|
|
3
|
-
export declare const pageTabContextMenuItemHandler: (data: PageTabContextMenuItemData, payload: OpenPageTabContextMenuPayload
|
|
3
|
+
export declare const pageTabContextMenuItemHandler: (data: PageTabContextMenuItemData, payload: OpenPageTabContextMenuPayload) => Promise<void>;
|
|
@@ -1,19 +1,13 @@
|
|
|
1
1
|
import type OpenFin from '@openfin/core';
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
export declare enum AnchorBehavior {
|
|
5
|
-
BottomLeft = 0,
|
|
6
|
-
BottomRight = 1,
|
|
7
|
-
Center = 2
|
|
8
|
-
}
|
|
9
|
-
export declare const openCommonContextMenu: (payload: OpenGlobalContextMenuPayload | OpenViewTabContextMenuPayload | OpenPageTabContextMenuPayload | OpenSaveButtonContextMenuPayload, _callerIdentity: OpenFin.Identity, type?: ContextMenuType, anchorBehavior?: AnchorBehavior) => Promise<void>;
|
|
10
|
-
export declare function openGlobalContextMenuInternal(this: WorkspacePlatformProvider, payload: InternalOpenGlobalContextMenuRequest & {
|
|
2
|
+
import { OpenGlobalContextMenuPayload, OpenGlobalContextMenuRequest, OpenPageTabContextMenuPayload, OpenPageTabContextMenuRequest, OpenSaveButtonContextMenuPayload, OpenSaveButtonContextMenuRequest, OpenViewTabContextMenuPayload, OpenViewTabContextMenuRequest, WorkspacePlatformProvider } from '../../../../client-api-platform/src/shapes';
|
|
3
|
+
export declare function openGlobalContextMenuInternal(this: WorkspacePlatformProvider, payload: OpenGlobalContextMenuRequest & {
|
|
11
4
|
identity: OpenFin.Identity;
|
|
12
5
|
}, callerIdentity: OpenFin.Identity): Promise<void>;
|
|
6
|
+
export declare const openCommonContextMenu: (payload: OpenGlobalContextMenuPayload | OpenViewTabContextMenuPayload | OpenPageTabContextMenuPayload | OpenSaveButtonContextMenuPayload, _callerIdentity: OpenFin.Identity) => Promise<void>;
|
|
13
7
|
export declare function openViewTabContextMenuInternal(this: WorkspacePlatformProvider, payload: OpenViewTabContextMenuRequest & {
|
|
14
8
|
identity: OpenFin.Identity;
|
|
15
9
|
}, callerIdentity: OpenFin.Identity): Promise<void>;
|
|
16
|
-
export declare function openPageTabContextMenuInternal(this: WorkspacePlatformProvider, payload:
|
|
10
|
+
export declare function openPageTabContextMenuInternal(this: WorkspacePlatformProvider, payload: OpenPageTabContextMenuRequest & {
|
|
17
11
|
identity: OpenFin.Identity;
|
|
18
12
|
}, callerIdentity: OpenFin.Identity): Promise<void>;
|
|
19
13
|
export declare function openSaveButtonContextMenuInternal(this: WorkspacePlatformProvider, payload: OpenSaveButtonContextMenuRequest & {
|
|
@@ -87,9 +87,9 @@ export interface ReorderPagesRequest {
|
|
|
87
87
|
* Request for opening a logo context menu in Browser.
|
|
88
88
|
*/
|
|
89
89
|
export interface OpenGlobalContextMenuRequest {
|
|
90
|
-
/**
|
|
90
|
+
/** Screen x-coordinate where context menu should be shown. */
|
|
91
91
|
x: number;
|
|
92
|
-
/**
|
|
92
|
+
/** Screen y-coordinate where context menu should be shown. */
|
|
93
93
|
y: number;
|
|
94
94
|
/** Miscellaneous options necessary for implementing custom logic in the provider override. */
|
|
95
95
|
customData?: any;
|
|
@@ -225,37 +225,28 @@ export type OpenGlobalContextMenuPayload = OpenGlobalContextMenuRequest & {
|
|
|
225
225
|
/** Default function that handles stock context menu options. */
|
|
226
226
|
callback: (data: GlobalContextMenuItemData, payload: OpenGlobalContextMenuPayload) => any;
|
|
227
227
|
};
|
|
228
|
-
/**
|
|
229
|
-
* Request for opening the global context menu with custom context menu in Enterprise Browser.
|
|
230
|
-
* @internal
|
|
231
|
-
*/
|
|
232
|
-
export type InternalOpenGlobalContextMenuRequest = OpenGlobalContextMenuRequest & {
|
|
233
|
-
/** Coordinates associated with a target element for a custom context menu request. */
|
|
234
|
-
rect?: DOMRect;
|
|
235
|
-
};
|
|
236
228
|
export type ViewTabContextMenuTemplate = OpenFin.MenuItemTemplate<ViewTabMenuData>;
|
|
237
229
|
/**
|
|
238
230
|
* Request for opening a view tab context menu in Browser.
|
|
239
231
|
*/
|
|
240
232
|
export interface OpenViewTabContextMenuRequest {
|
|
241
|
-
/**
|
|
233
|
+
/** Screen x-coordinate where context menu should be shown. */
|
|
242
234
|
x: number;
|
|
243
|
-
/**
|
|
235
|
+
/** Screen y-coordinate where context menu should be shown. */
|
|
244
236
|
y: number;
|
|
245
237
|
/** Miscellaneous options necessary for implementing custom logic in the provider override. */
|
|
246
238
|
customData?: any;
|
|
247
239
|
/** Template defining the options to show in the context menu. */
|
|
248
240
|
template: ViewTabContextMenuTemplate[];
|
|
249
|
-
/** Ids of selected views */
|
|
250
241
|
selectedViews: OpenFin.Identity[];
|
|
251
242
|
}
|
|
252
243
|
/**
|
|
253
244
|
* Request for opening a page tab context menu in Browser.
|
|
254
245
|
*/
|
|
255
246
|
export interface OpenPageTabContextMenuRequest {
|
|
256
|
-
/**
|
|
247
|
+
/** Screen x-coordinate where context menu should be shown. */
|
|
257
248
|
x: number;
|
|
258
|
-
/**
|
|
249
|
+
/** Screen y-coordinate where context menu should be shown. */
|
|
259
250
|
y: number;
|
|
260
251
|
/** Miscellaneous options necessary for implementing custom logic in the provider override. */
|
|
261
252
|
customData?: any;
|
|
@@ -352,14 +343,6 @@ export type OpenPageTabContextMenuPayload = OpenPageTabContextMenuRequest & {
|
|
|
352
343
|
/** Default function that handles stock context menu options. */
|
|
353
344
|
callback: (data: PageTabContextMenuItemData, req: OpenPageTabContextMenuPayload) => any;
|
|
354
345
|
};
|
|
355
|
-
/**
|
|
356
|
-
* Request for opening the global context menu with custom context menu in Enterprise Browser.
|
|
357
|
-
* @internal
|
|
358
|
-
*/
|
|
359
|
-
export type InternalOpenPageTabContextMenuRequest = OpenPageTabContextMenuRequest & {
|
|
360
|
-
/** Coordinates associated with a target element for a custom context menu request. */
|
|
361
|
-
rect?: DOMRect;
|
|
362
|
-
};
|
|
363
346
|
/**
|
|
364
347
|
* Request to update the attributes of a page in which is attached to a running browser window.
|
|
365
348
|
*/
|
|
@@ -540,9 +523,9 @@ export interface SaveButtonContextMenuItemTemplate extends OpenFin.MenuItemTempl
|
|
|
540
523
|
* Request for opening a context menu from save button in Browser.
|
|
541
524
|
*/
|
|
542
525
|
export interface OpenSaveButtonContextMenuRequest {
|
|
543
|
-
/**
|
|
526
|
+
/** Screen x-coordinate where context menu should be shown. */
|
|
544
527
|
x: number;
|
|
545
|
-
/**
|
|
528
|
+
/** Screen y-coordinate where context menu should be shown. */
|
|
546
529
|
y: number;
|
|
547
530
|
/** Screen x-coordinate of save button */
|
|
548
531
|
buttonLeft: number;
|
|
@@ -1003,11 +986,11 @@ export interface BrowserWindowModule {
|
|
|
1003
986
|
* @param req the global context menu request.
|
|
1004
987
|
* @internal
|
|
1005
988
|
*/
|
|
1006
|
-
_openGlobalContextMenu(req:
|
|
989
|
+
_openGlobalContextMenu(req: OpenGlobalContextMenuRequest): Promise<void>;
|
|
1007
990
|
/** @internal */
|
|
1008
991
|
_openViewTabContextMenu(req: OpenViewTabContextMenuRequest): Promise<void>;
|
|
1009
992
|
/** @internal */
|
|
1010
|
-
_openPageTabContextMenu(req:
|
|
993
|
+
_openPageTabContextMenu(req: OpenPageTabContextMenuRequest): Promise<void>;
|
|
1011
994
|
/** @internal */
|
|
1012
995
|
_openSaveButtonContextMenu(req: OpenSaveButtonContextMenuRequest): Promise<void>;
|
|
1013
996
|
/**
|
|
@@ -1066,7 +1049,7 @@ export interface BrowserWindowModule {
|
|
|
1066
1049
|
/** @internal */
|
|
1067
1050
|
_trackVisitedSite(req: any): Promise<void>;
|
|
1068
1051
|
/** @internal */
|
|
1069
|
-
|
|
1052
|
+
_getRecentVisitedSites(req?: number): Promise<any[]>;
|
|
1070
1053
|
/** @internal */
|
|
1071
1054
|
_getFrequentlyVisitedSites(req?: any): Promise<any[]>;
|
|
1072
1055
|
/** @internal */
|
|
@@ -1084,7 +1067,6 @@ export type NavigationRequest = {
|
|
|
1084
1067
|
viewIdentity: OpenFin.Identity;
|
|
1085
1068
|
} & ({
|
|
1086
1069
|
action: 'result-selected';
|
|
1087
|
-
trigger?: SiteAction;
|
|
1088
1070
|
site: Site;
|
|
1089
1071
|
} | (SearchSitesRequest & {
|
|
1090
1072
|
action: 'search-input';
|
|
@@ -1098,58 +1080,29 @@ export type SearchSitesRequest = {
|
|
|
1098
1080
|
/**
|
|
1099
1081
|
* @internal
|
|
1100
1082
|
*/
|
|
1101
|
-
export type SearchSitesResponse =
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
id: string;
|
|
1107
|
-
title: string;
|
|
1108
|
-
altText?: string;
|
|
1109
|
-
lightIcon?: string;
|
|
1110
|
-
darkIcon?: string;
|
|
1083
|
+
export type SearchSitesResponse = {
|
|
1084
|
+
suggestions?: Site[];
|
|
1085
|
+
favorites?: Site[];
|
|
1086
|
+
bookmarks?: Site[];
|
|
1087
|
+
platformContent?: Site[];
|
|
1111
1088
|
};
|
|
1112
1089
|
/**
|
|
1113
1090
|
* @internal
|
|
1114
1091
|
*/
|
|
1115
|
-
export type
|
|
1092
|
+
export type Site = {
|
|
1116
1093
|
id: string;
|
|
1117
1094
|
title: string;
|
|
1118
|
-
subTitle?: string;
|
|
1119
1095
|
cta?: string;
|
|
1120
|
-
actions?: SiteAction[];
|
|
1121
|
-
};
|
|
1122
|
-
/**
|
|
1123
|
-
* @internal
|
|
1124
|
-
*/
|
|
1125
|
-
export type AppSite = SiteInfo & {
|
|
1126
1096
|
type: 'app' | 'website';
|
|
1127
|
-
url
|
|
1097
|
+
url: string;
|
|
1128
1098
|
icon: string;
|
|
1129
|
-
options?: {
|
|
1130
|
-
icon?: {
|
|
1131
|
-
size?: 'standard' | 'large';
|
|
1132
|
-
};
|
|
1133
|
-
};
|
|
1134
1099
|
customData?: unknown;
|
|
1135
|
-
}
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
export type WorkspaceSite = SiteInfo & {
|
|
1100
|
+
} | {
|
|
1101
|
+
id: string;
|
|
1102
|
+
title: string;
|
|
1103
|
+
cta?: string;
|
|
1140
1104
|
type: 'page' | 'workspace';
|
|
1141
1105
|
};
|
|
1142
|
-
/**
|
|
1143
|
-
* @internal
|
|
1144
|
-
*/
|
|
1145
|
-
export type Site = AppSite | WorkspaceSite;
|
|
1146
|
-
/**
|
|
1147
|
-
* @internal
|
|
1148
|
-
* action is undefined when the site is actioned with the default action.
|
|
1149
|
-
*/
|
|
1150
|
-
export type ActionedSite = Site & {
|
|
1151
|
-
action?: SiteAction;
|
|
1152
|
-
};
|
|
1153
1106
|
/**
|
|
1154
1107
|
* Factory for wrapping browser windows and global operations.
|
|
1155
1108
|
*/
|
|
@@ -56,8 +56,7 @@ export declare enum PageChannelAction {
|
|
|
56
56
|
*/
|
|
57
57
|
export declare enum EnterpriseAppDirectoryChannelAction {
|
|
58
58
|
GetApps = "get-apps",
|
|
59
|
-
GetCuratedContent = "get-curated-content"
|
|
60
|
-
GetRecentlyVisited = "get-recently-visited"
|
|
59
|
+
GetCuratedContent = "get-curated-content"
|
|
61
60
|
}
|
|
62
61
|
export declare const BrowserChannelAction: {
|
|
63
62
|
GetPages: PageChannelAction.GetPages;
|
|
@@ -65,7 +65,7 @@ export declare enum WorkspacePlatformChannelAction {
|
|
|
65
65
|
TrackRemovedTabInternal = "trackRemovedTabInternal",
|
|
66
66
|
RestoreRemovedTabInternal = "restoreRemovedTabInternal",
|
|
67
67
|
TrackVisitedSiteInternal = "trackVisitedSiteInternal",
|
|
68
|
-
|
|
68
|
+
GetRecentVisitedSitesInternal = "getRecentVisitedSitesInternal",
|
|
69
69
|
GetFrequentlyVisitedSitesInternal = "getFrequentlyVisitedSitesInternal",
|
|
70
70
|
SearchSitesInternal = "searchSitesInternal",
|
|
71
71
|
GetCuratedContentInternal = "getCuratedContentInternal",
|
|
@@ -1,6 +1,4 @@
|
|
|
1
1
|
import type OpenFin from '@openfin/core';
|
|
2
|
-
import { AnchorBehavior } from '../../../client-api-platform/src/api/context-menu';
|
|
3
|
-
import { ContextMenuType } from './popup-window';
|
|
4
2
|
export declare enum MenuItemType {
|
|
5
3
|
Label = "normal",
|
|
6
4
|
Separator = "separator",
|
|
@@ -10,8 +8,7 @@ export declare enum MenuItemType {
|
|
|
10
8
|
export type ShowContextMenuResponse = OpenFin.MenuResult & {
|
|
11
9
|
data: any;
|
|
12
10
|
};
|
|
13
|
-
export
|
|
14
|
-
export declare const showEnterpriseContextMenu: (opts: OpenFin.ShowPopupMenuOptions, type: ContextMenuType, anchorBehavior: AnchorBehavior, win?: OpenFin.Window) => Promise<ShowContextMenuResponse>;
|
|
11
|
+
export default function showContextMenu(opts: OpenFin.ShowPopupMenuOptions, win?: OpenFin.Window): Promise<ShowContextMenuResponse>;
|
|
15
12
|
export declare const Separator: OpenFin.MenuItemTemplate;
|
|
16
13
|
export declare const EmptyContextMenuItem: OpenFin.MenuItemTemplate;
|
|
17
14
|
export declare const DefaultSaveMenuBounds: {
|
|
@@ -22,8 +22,7 @@ export declare enum PageRoute {
|
|
|
22
22
|
Storefront = "/storefront/",
|
|
23
23
|
DeprecatedAlert = "/provider/deprecated-alert/",
|
|
24
24
|
Analytics = "/provider/analytics/",
|
|
25
|
-
EnterpriseBrowser = "/browser/enterprise/"
|
|
26
|
-
EnterpriseContextMenu = "/browser/enterprise/context-menu/"
|
|
25
|
+
EnterpriseBrowser = "/browser/enterprise/"
|
|
27
26
|
}
|
|
28
27
|
export declare const Assets: {
|
|
29
28
|
readonly IconOpenFinLogo: "/icons/openfinlogo.svg";
|
|
@@ -10,7 +10,6 @@ export declare enum WindowName {
|
|
|
10
10
|
BrowserIndicator = "openfin-browser-indicator",
|
|
11
11
|
BrowserWindow = "internal-generated-window",
|
|
12
12
|
ClassicWindow = "internal-generated-classic-window",
|
|
13
|
-
EnterpriseContextMenu = "openfin-enterprise-context-menu",
|
|
14
13
|
BrowserAddressSearchPrefix = "openfin-browser-menu-address-search-"
|
|
15
14
|
}
|
|
16
15
|
export interface WindowIdentity {
|