@openfin/workspace 18.1.22 → 18.1.23
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/context-menu/utils.d.ts +1 -0
- package/client-api-platform/src/shapes.d.ts +20 -1
- package/common/src/api/pages/shapes.d.ts +14 -0
- package/common/src/api/protocol/workspace-platform.d.ts +2 -0
- package/common/src/utils/workspace-modals.d.ts +2 -0
- package/home.js +1 -1
- package/home.js.map +1 -1
- package/index.js +1 -1
- package/index.js.map +1 -1
- package/notifications.js +1 -1
- package/notifications.js.map +1 -1
- package/package.json +1 -1
- package/store.js +2 -2
- package/store.js.map +1 -1
|
@@ -40,3 +40,4 @@ export declare const closeOtherPagesHandler: (identity: OpenFin.Identity, pageId
|
|
|
40
40
|
* @param viewIdentities Array of views to execute print on.
|
|
41
41
|
*/
|
|
42
42
|
export declare const printSelectedViews: (viewIdentities: OpenFin.Identity[]) => Promise<void>;
|
|
43
|
+
export declare const deletePageHandler: (identity: OpenFin.Identity, pageId?: string) => Promise<void>;
|
|
@@ -4,7 +4,7 @@ import type { AnalyticsEvent, AnalyticsEventInternal } from '../../common/src/ut
|
|
|
4
4
|
import { CustomActionSpecifier, CustomButtonConfig } from '../../common/src/api/action';
|
|
5
5
|
import { Resource } from '../../common/src/api/i18next';
|
|
6
6
|
import { TrackedSite } from '../../common/src/api/pages/idb';
|
|
7
|
-
import type { AttachedPage, CopyPagePayload, HandleSaveModalOnPageClosePayload, Page, PageWithUpdatableRuntimeAttribs, SaveModalOnPageCloseResult } from '../../common/src/api/pages/shapes';
|
|
7
|
+
import type { AddDefaultPagePayload, AttachedPage, CopyPagePayload, HandleSaveModalOnPageClosePayload, Page, PageWithUpdatableRuntimeAttribs, SaveModalOnPageCloseResult } from '../../common/src/api/pages/shapes';
|
|
8
8
|
import { SetActivePageForWindowPayload } from '../../common/src/api/pages/shapes';
|
|
9
9
|
import { NotificationsCustomManifestOptions } from '../../common/src/api/shapes/notifications';
|
|
10
10
|
import type { CustomThemes } from '../../common/src/api/theming';
|
|
@@ -154,6 +154,7 @@ export declare enum PageTabContextMenuOptionType {
|
|
|
154
154
|
Rename = "Rename",
|
|
155
155
|
Save = "Save",
|
|
156
156
|
SaveAs = "Save As",
|
|
157
|
+
DeletePage = "Delete Page",
|
|
157
158
|
SaveWorkspaceAs = "SaveWorkspaceAs",
|
|
158
159
|
Refresh = "Refresh",
|
|
159
160
|
CloseOthers = "Close others",
|
|
@@ -1028,6 +1029,19 @@ export interface BrowserWindowModule {
|
|
|
1028
1029
|
_reparentPage(req: ReparentPageRequest & {
|
|
1029
1030
|
index?: number;
|
|
1030
1031
|
}): Promise<void>;
|
|
1032
|
+
/**
|
|
1033
|
+
* ```ts
|
|
1034
|
+
*
|
|
1035
|
+
* const newPage = await makeNewLandingPage();
|
|
1036
|
+
* const { newPageUrl } = await getLandingPageUrls();
|
|
1037
|
+
* const browser = getCurrentSync().Browser.wrapSync(currentOFIdentity);
|
|
1038
|
+
* const actualNewPageUrl = newPageUrl ? newPageUrl : undefined;
|
|
1039
|
+
* await browser._addDefaultPage({ identity: currentOFIdentity, page: newPage, newPageUrl: actualNewPageUrl });
|
|
1040
|
+
* ```
|
|
1041
|
+
* @param req the default page request object
|
|
1042
|
+
* @internal
|
|
1043
|
+
*/
|
|
1044
|
+
_addDefaultPage(req: AddDefaultPagePayload): Promise<void>;
|
|
1031
1045
|
/** @internal */
|
|
1032
1046
|
_trackRemovedTab(req: any): Promise<void>;
|
|
1033
1047
|
/** @internal */
|
|
@@ -1820,6 +1834,11 @@ export interface WorkspacePlatformProvider extends OpenFin.PlatformProvider {
|
|
|
1820
1834
|
* @param locale in ISO language code format
|
|
1821
1835
|
*/
|
|
1822
1836
|
setLanguage(locale: Locale): Promise<void>;
|
|
1837
|
+
/**
|
|
1838
|
+
* Implementation for adding custom default page
|
|
1839
|
+
* @param payload {@link AddDefaultPagePayload}
|
|
1840
|
+
*/
|
|
1841
|
+
addDefaultPage(payload: AddDefaultPagePayload): Promise<void>;
|
|
1823
1842
|
/** @internal */
|
|
1824
1843
|
restoreRemovedTabInternal(): Promise<void>;
|
|
1825
1844
|
/** @internal */
|
|
@@ -213,4 +213,18 @@ export interface CopyPagePayload {
|
|
|
213
213
|
/** Specifies the trigger for creating a copy. */
|
|
214
214
|
reason: 'save-as' | 'duplicate';
|
|
215
215
|
}
|
|
216
|
+
export type AddDefaultPagePayload = {
|
|
217
|
+
/** The OF window identity to attach the pages to. */
|
|
218
|
+
identity: OpenFin.Identity;
|
|
219
|
+
/** The page to attach. */
|
|
220
|
+
page: PageWithUpdatableRuntimeAttribs;
|
|
221
|
+
/** The newPageUrl provided. */
|
|
222
|
+
newPageUrl: string;
|
|
223
|
+
};
|
|
224
|
+
export type AddPagePayload = {
|
|
225
|
+
/** The OF window identity to attach the pages to. */
|
|
226
|
+
identity: OpenFin.Identity;
|
|
227
|
+
/** The page to attach. */
|
|
228
|
+
page: PageWithUpdatableRuntimeAttribs;
|
|
229
|
+
};
|
|
216
230
|
export {};
|
|
@@ -24,6 +24,8 @@ export declare enum WorkspacePlatformChannelAction {
|
|
|
24
24
|
DetachPagesFromWindow = "detachPagesFromWindow",
|
|
25
25
|
ReorderPagesForWindow = "reorderPagesForWindow",
|
|
26
26
|
SetActivePage = "setActivePage",
|
|
27
|
+
AddPage = "addPage",
|
|
28
|
+
AddDefaultPage = "addDefaultPage",
|
|
27
29
|
GetAllAttachedPages = "getAllAttachedPages",
|
|
28
30
|
GetActivePageIdForWindow = "getActivePageIdForWindow",
|
|
29
31
|
GetPagesForWindow = "getPagesForWindow",
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type OpenFin from '@openfin/core';
|
|
2
2
|
import { ResponseModalConfig } from '../../../common/src/utils/menu-config';
|
|
3
3
|
export declare const restoreChangesMenu: (windowIdentity: OpenFin.Identity) => Promise<ResponseModalConfig>;
|
|
4
|
+
export declare const deletePageMenu: (windowIdentity: OpenFin.Identity, pageTitle: string) => Promise<ResponseModalConfig>;
|
|
4
5
|
/**
|
|
5
6
|
*
|
|
6
7
|
* @param targetWindowIdentity Parent or Current OpenFin Window Identity
|
|
@@ -21,3 +22,4 @@ export declare const showPlatformQuitModal: (windowIdentity: OpenFin.Identity, w
|
|
|
21
22
|
export declare const showQuitBrowserModal: (windowIdentity: OpenFin.Identity) => Promise<boolean>;
|
|
22
23
|
export declare const showRestoreChangesModal: (windowIdentity: OpenFin.Identity) => Promise<boolean>;
|
|
23
24
|
export declare const getOverwriteWorkspaceMenu: (workspaceTitle: string) => Promise<ResponseModalConfig>;
|
|
25
|
+
export declare const showDeletePageModal: (windowIdentity: OpenFin.Identity, pageTitle: string) => Promise<boolean>;
|