@openfin/workspace-platform 5.2.0 → 5.5.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/README.md +31 -4
- package/client-api/src/shapes.d.ts +597 -0
- package/{index.ts → client-api-platform/index.d.ts} +0 -0
- package/client-api-platform/src/api/app-directory.d.ts +7 -0
- package/client-api-platform/src/api/browser/browser-module.d.ts +13 -0
- package/client-api-platform/src/api/browser/index.d.ts +22 -0
- package/client-api-platform/src/api/pages/helper.d.ts +22 -0
- package/client-api-platform/src/api/pages/index.d.ts +30 -0
- package/client-api-platform/src/api/protocol.d.ts +48 -0
- package/client-api-platform/src/api/storage.d.ts +10 -0
- package/client-api-platform/src/api/theming.d.ts +5 -0
- package/client-api-platform/src/api/workspace-module.d.ts +3 -0
- package/client-api-platform/src/index.d.ts +41 -0
- package/client-api-platform/src/init/browser-window-focus.d.ts +19 -0
- package/client-api-platform/src/init/cleanup.d.ts +1 -0
- package/client-api-platform/src/init/index.d.ts +5 -0
- package/client-api-platform/src/init/override-callback.d.ts +3 -0
- package/client-api-platform/src/init/theming.d.ts +9 -0
- package/client-api-platform/src/init/utils.d.ts +45 -0
- package/client-api-platform/src/shapes.d.ts +673 -0
- package/client-api-platform/src/umd.d.ts +1 -0
- package/common/src/api/pages/attached.d.ts +101 -0
- package/common/src/api/pages/idb.d.ts +12 -0
- package/common/src/api/pages/index.d.ts +22 -0
- package/common/src/api/pages/legacy.d.ts +16 -0
- package/common/src/api/pages/shapes.d.ts +77 -0
- package/common/src/api/protocol.d.ts +64 -0
- package/common/src/api/theming.d.ts +62 -0
- package/common/src/api/workspaces/index.d.ts +7 -0
- package/common/src/utils/application.d.ts +38 -0
- package/common/src/utils/channels.d.ts +8 -0
- package/common/src/utils/debounce.d.ts +16 -0
- package/common/src/utils/defer-auto-show.d.ts +18 -0
- package/common/src/utils/env.d.ts +36 -0
- package/common/src/utils/layout.d.ts +52 -0
- package/common/src/utils/local-storage-key.d.ts +8 -0
- package/common/src/utils/logger/index.d.ts +26 -0
- package/common/src/utils/logger/manager.d.ts +35 -0
- package/common/src/utils/logger/shapes.d.ts +27 -0
- package/common/src/utils/route.d.ts +55 -0
- package/common/src/utils/shared-emitter.d.ts +10 -0
- package/common/src/utils/snapshot.d.ts +33 -0
- package/common/src/utils/strings.d.ts +5 -0
- package/common/src/utils/theming.d.ts +57 -0
- package/common/src/utils/umd.d.ts +2 -0
- package/common/src/utils/window.d.ts +150 -0
- package/index.d.ts +1 -0
- package/index.js +2 -0
- package/index.js.map +1 -0
- package/package.json +1 -34
- package/search-api/src/client/index.d.ts +6 -0
- package/search-api/src/client/internal.d.ts +38 -0
- package/search-api/src/client/remote/channel-client-factory.d.ts +2 -0
- package/search-api/src/client/remote/channel-client.d.ts +9 -0
- package/search-api/src/client/remote/data.d.ts +16 -0
- package/search-api/src/client/remote/disconnect.d.ts +7 -0
- package/search-api/src/client/remote/dispatch.d.ts +9 -0
- package/search-api/src/client/remote/requests.d.ts +5 -0
- package/search-api/src/client/remote/search-close.d.ts +14 -0
- package/search-api/src/common.d.ts +104 -0
- package/search-api/src/errors.d.ts +5 -0
- package/search-api/src/fin/index.d.ts +6 -0
- package/search-api/src/fin/shapes.d.ts +23 -0
- package/search-api/src/index.d.ts +7 -0
- package/search-api/src/internal-shapes.d.ts +134 -0
- package/search-api/src/logger.d.ts +1 -0
- package/search-api/src/provider/index.d.ts +8 -0
- package/search-api/src/provider/internal.d.ts +33 -0
- package/search-api/src/provider/remote/channel-factory.d.ts +6 -0
- package/search-api/src/provider/remote/channel.d.ts +23 -0
- package/search-api/src/provider/remote/connection.d.ts +20 -0
- package/search-api/src/provider/remote/data.d.ts +23 -0
- package/search-api/src/provider/remote/deregistration.d.ts +5 -0
- package/search-api/src/provider/remote/disconnect.d.ts +1 -0
- package/search-api/src/provider/remote/disconnection.d.ts +9 -0
- package/search-api/src/provider/remote/dispatch.d.ts +7 -0
- package/search-api/src/provider/remote/info.d.ts +5 -0
- package/search-api/src/provider/remote/registration.d.ts +23 -0
- package/search-api/src/provider/remote/search-close.d.ts +14 -0
- package/search-api/src/provider/remote/search.d.ts +8 -0
- package/search-api/src/shapes.d.ts +542 -0
- package/.eslintignore +0 -1
- package/.eslintrc.js +0 -2
- package/.prettierrc.js +0 -2
- package/babel.config.js +0 -2
- package/jest.config.js +0 -2
- package/src/api/app-directory.ts +0 -45
- package/src/api/browser/browser-module.ts +0 -65
- package/src/api/browser/index.ts +0 -46
- package/src/api/pages/helper.ts +0 -113
- package/src/api/pages/index.ts +0 -164
- package/src/api/protocol.ts +0 -60
- package/src/api/storage.ts +0 -32
- package/src/api/workspace-module.ts +0 -36
- package/src/index.ts +0 -35
- package/src/init/browser-window-focus.ts +0 -59
- package/src/init/cleanup.ts +0 -87
- package/src/init/index.ts +0 -42
- package/src/init/override-callback.ts +0 -159
- package/src/init/utils.ts +0 -164
- package/src/shapes.ts +0 -160
- package/src/umd.ts +0 -5
- package/tsconfig.json +0 -13
- package/webpack.common.config.js +0 -1
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* All routes that serve HTML pages for the app.
|
|
3
|
+
* Routes should include the zone the the HTML page is a part of.
|
|
4
|
+
* Make sure to include trailing slash, as it is essential for deployed version to route correctly.
|
|
5
|
+
*/
|
|
6
|
+
export declare enum PageRoute {
|
|
7
|
+
HomeIndex = "/home/",
|
|
8
|
+
HomeSearch = "/home/search/",
|
|
9
|
+
HomePagesRename = "/home/pages/rename/",
|
|
10
|
+
Dock = "/home/dock/",
|
|
11
|
+
BrowserPagesLanding = "/browser/pages/landing/",
|
|
12
|
+
HomeIndicator = "/home/indicator/",
|
|
13
|
+
Browser = "/browser/",
|
|
14
|
+
BrowserPopupMenu = "/browser/popup-menu/",
|
|
15
|
+
Provider = "/provider/",
|
|
16
|
+
BrowserPopupMenuSharePage = "/browser/popup-menu/share-page/",
|
|
17
|
+
BrowserPopupMenuSavePage = "/browser/popup-menu/save-page/",
|
|
18
|
+
BrowserPopupMenuLayouts = "/browser/popup-menu/layouts/layouts/",
|
|
19
|
+
BrowserPopupMenuColorLinking = "/browser/popup-menu/color-linking/color-linking/",
|
|
20
|
+
BrowserIndicator = "/browser/indicator/",
|
|
21
|
+
ResponseModal = "/browser/popup-menu/response-modal/",
|
|
22
|
+
Docs = "/provider/docs/",
|
|
23
|
+
Storefront = "/storefront/",
|
|
24
|
+
DeprecatedAlert = "/provider/deprecated-alert/"
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* All routes that serve assets. (icons, json, etc.)
|
|
28
|
+
*/
|
|
29
|
+
export declare enum AssetRoute {
|
|
30
|
+
IconOpenFinLogo = "/icons/openfinlogo.svg",
|
|
31
|
+
IconFilter = "/icons/filter.svg"
|
|
32
|
+
}
|
|
33
|
+
declare const _default: {
|
|
34
|
+
HomeIndex: PageRoute.HomeIndex;
|
|
35
|
+
HomeSearch: PageRoute.HomeSearch;
|
|
36
|
+
HomePagesRename: PageRoute.HomePagesRename;
|
|
37
|
+
Dock: PageRoute.Dock;
|
|
38
|
+
BrowserPagesLanding: PageRoute.BrowserPagesLanding;
|
|
39
|
+
HomeIndicator: PageRoute.HomeIndicator;
|
|
40
|
+
Browser: PageRoute.Browser;
|
|
41
|
+
BrowserPopupMenu: PageRoute.BrowserPopupMenu;
|
|
42
|
+
Provider: PageRoute.Provider;
|
|
43
|
+
BrowserPopupMenuSharePage: PageRoute.BrowserPopupMenuSharePage;
|
|
44
|
+
BrowserPopupMenuSavePage: PageRoute.BrowserPopupMenuSavePage;
|
|
45
|
+
BrowserPopupMenuLayouts: PageRoute.BrowserPopupMenuLayouts;
|
|
46
|
+
BrowserPopupMenuColorLinking: PageRoute.BrowserPopupMenuColorLinking;
|
|
47
|
+
BrowserIndicator: PageRoute.BrowserIndicator;
|
|
48
|
+
ResponseModal: PageRoute.ResponseModal;
|
|
49
|
+
Docs: PageRoute.Docs;
|
|
50
|
+
Storefront: PageRoute.Storefront;
|
|
51
|
+
DeprecatedAlert: PageRoute.DeprecatedAlert;
|
|
52
|
+
IconOpenFinLogo: AssetRoute.IconOpenFinLogo;
|
|
53
|
+
IconFilter: AssetRoute.IconFilter;
|
|
54
|
+
};
|
|
55
|
+
export default _default;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare type Listener = (...args: any[]) => void;
|
|
2
|
+
/**
|
|
3
|
+
* Creates an event emitter that is shared between all windows within the same domain.
|
|
4
|
+
*/
|
|
5
|
+
export default function makeSharedEmitter<E extends string | number, L extends Listener>(id: string): {
|
|
6
|
+
emit: (event: E, ...payload: any[]) => Promise<void>;
|
|
7
|
+
addListener: (event: E, listener: L) => void;
|
|
8
|
+
removeListener: (event: E, listener: L) => void;
|
|
9
|
+
once: (event: E, listener: L) => void;
|
|
10
|
+
};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/// <reference types="openfin-adapter/fin" />
|
|
2
|
+
export declare type SnapshotDetailsExtended = OpenFin.Snapshot['snapshotDetails'] & {
|
|
3
|
+
machineId: string;
|
|
4
|
+
machineName?: string;
|
|
5
|
+
};
|
|
6
|
+
export declare type SnapshotExtended = {
|
|
7
|
+
snapshotDetails: SnapshotDetailsExtended;
|
|
8
|
+
windows: OpenFin.WindowOptions[];
|
|
9
|
+
};
|
|
10
|
+
export declare type ApplySnapshotOptionsExtended = OpenFin.ApplySnapshotOptions & {
|
|
11
|
+
attachToExistingWindow: boolean;
|
|
12
|
+
};
|
|
13
|
+
/**
|
|
14
|
+
* Set a friendly name of the current machine.
|
|
15
|
+
* @param name the friendly name.
|
|
16
|
+
*/
|
|
17
|
+
export declare function setMachineName(name: string): void;
|
|
18
|
+
/**
|
|
19
|
+
* Get the machine's friendly name.
|
|
20
|
+
* @returns the machine's friendly name.
|
|
21
|
+
*/
|
|
22
|
+
export declare function getMachineName(): string;
|
|
23
|
+
/**
|
|
24
|
+
* Get the current machine ID.
|
|
25
|
+
* @returns the machine ID.
|
|
26
|
+
*/
|
|
27
|
+
export declare function getMachineId(): Promise<string>;
|
|
28
|
+
/**
|
|
29
|
+
* Get a snapshot with extra snapshot details.
|
|
30
|
+
* @param snapshot the snapshot to extend.
|
|
31
|
+
* @returns the snapshot with more snapshot details.
|
|
32
|
+
*/
|
|
33
|
+
export declare function getSnapshotExtended(snapshot?: OpenFin.Snapshot): Promise<SnapshotExtended>;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export declare const capitalize: (s: string) => string;
|
|
2
|
+
export declare const titleize: (s: string) => string;
|
|
3
|
+
export declare const pascalize: (s: string) => string;
|
|
4
|
+
export declare const slugify: (s: string) => string;
|
|
5
|
+
export declare const isStringMatchesQuery: (title: string, query?: string) => boolean;
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { CustomPaletteSet } from '../../../common/src/api/theming';
|
|
2
|
+
/**
|
|
3
|
+
* Get hue from a CSS color
|
|
4
|
+
*
|
|
5
|
+
* The getHue function is used manage extracting hue from 3 types of css
|
|
6
|
+
* string input types. An object including hue, hsl, hsla, lightness and
|
|
7
|
+
* saturation are returned.
|
|
8
|
+
*
|
|
9
|
+
* Each function was copied css tricks and modified to fit this platform.
|
|
10
|
+
* Links above each function for technical details.
|
|
11
|
+
*
|
|
12
|
+
* Allowed formats:
|
|
13
|
+
* RGB with or with out the alpha rgb(x,x,x) or rgba(x,x,x,x)
|
|
14
|
+
* HEX 3 or 6 characters, plus hashtag #333 or #333333
|
|
15
|
+
* HSL with or with out the alhpa hsl(x,x%,x%) or hsla(x,x%,x%,x)
|
|
16
|
+
*
|
|
17
|
+
* The hue value is used later to build an array of background colors in the
|
|
18
|
+
* theme that are various shades of the hue returned from this function.
|
|
19
|
+
*
|
|
20
|
+
* An invalid format should error telling the integrator how to fix the error.
|
|
21
|
+
* - Error for missing required options
|
|
22
|
+
* - Error for invalid css strings that are unable to be processed
|
|
23
|
+
*
|
|
24
|
+
* @param colorInput string - Supported formats rgb/RGB/rgba/RGBA, #000/#000000, hsl/HSL/hsla/HSLA
|
|
25
|
+
* @returns hue as string
|
|
26
|
+
*/
|
|
27
|
+
export declare const getHue: (colorInput: string) => string;
|
|
28
|
+
export declare const makeBackgroundLayers: (hue: string) => {
|
|
29
|
+
light: {
|
|
30
|
+
background1: string;
|
|
31
|
+
background2: string;
|
|
32
|
+
background3: string;
|
|
33
|
+
background4: string;
|
|
34
|
+
background5: string;
|
|
35
|
+
background6: string;
|
|
36
|
+
};
|
|
37
|
+
dark: {
|
|
38
|
+
background1: string;
|
|
39
|
+
background2: string;
|
|
40
|
+
background3: string;
|
|
41
|
+
background4: string;
|
|
42
|
+
background5: string;
|
|
43
|
+
background6: string;
|
|
44
|
+
};
|
|
45
|
+
};
|
|
46
|
+
/**
|
|
47
|
+
* makePalette() - generic - doesn't care about scheme
|
|
48
|
+
*
|
|
49
|
+
* Accepts a default palette object, and a custom palette object.
|
|
50
|
+
* The default object gets overrides from customPalette and returns a new palette object.
|
|
51
|
+
* @param defaultPalette
|
|
52
|
+
* @param customPalette
|
|
53
|
+
* @returns { light: newPalette, dark: newPalette }
|
|
54
|
+
*
|
|
55
|
+
* TODO: DefaultPaletteSet isn't working, need to redo.
|
|
56
|
+
*/
|
|
57
|
+
export declare const makePalette: (defaultPalette: any, customPalette: CustomPaletteSet) => CustomPaletteSet;
|
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
/// <reference types="openfin-adapter/fin" />
|
|
2
|
+
import type { Fin } from 'openfin-adapter';
|
|
3
|
+
import type { _Window } from 'openfin-adapter/src/api/window';
|
|
4
|
+
import { ApplicationUUID } from './application';
|
|
5
|
+
export declare type WindowFin = Fin<'window'>;
|
|
6
|
+
export declare enum WindowName {
|
|
7
|
+
Home = "openfin-home",
|
|
8
|
+
Dock = "openfin-dock",
|
|
9
|
+
Storefront = "openfin-storefront",
|
|
10
|
+
HomeInternal = "openfin-home-internal",
|
|
11
|
+
BrowserMenu = "openfin-browser-menu",
|
|
12
|
+
BrowserIndicator = "openfin-browser-indicator",
|
|
13
|
+
BrowserWindow = "internal-generated-window"
|
|
14
|
+
}
|
|
15
|
+
export declare enum WindowEvent {
|
|
16
|
+
Shown = "shown",
|
|
17
|
+
BoundsChanged = "bounds-changed",
|
|
18
|
+
LayoutReady = "layout-ready",
|
|
19
|
+
EndUserBoundsChanging = "end-user-bounds-changing",
|
|
20
|
+
Blurred = "blurred",
|
|
21
|
+
CloseRequested = "close-requested",
|
|
22
|
+
Focused = "focused",
|
|
23
|
+
ShowRequested = "show-requested",
|
|
24
|
+
ViewCrashed = "view-crashed",
|
|
25
|
+
ViewAttached = "view-attached",
|
|
26
|
+
ViewDetached = "view-detached",
|
|
27
|
+
ViewPageTitleUpdated = "view-page-title-updated",
|
|
28
|
+
ViewDestroyed = "view-destroyed"
|
|
29
|
+
}
|
|
30
|
+
export interface WindowIdentity {
|
|
31
|
+
uuid: ApplicationUUID | string;
|
|
32
|
+
name: WindowName | string;
|
|
33
|
+
}
|
|
34
|
+
export interface WindowCreationOptionsExtended extends OpenFin.PlatformWindowCreationOptions {
|
|
35
|
+
backgroundThrottling?: boolean;
|
|
36
|
+
}
|
|
37
|
+
interface Point {
|
|
38
|
+
left: number;
|
|
39
|
+
top: number;
|
|
40
|
+
}
|
|
41
|
+
interface Size {
|
|
42
|
+
height: number;
|
|
43
|
+
width: number;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Gets the center point of a window given its bounds
|
|
47
|
+
* @param bounds OpenFin bounds - left, top, height, width
|
|
48
|
+
* @returns coords representing the center - left, top
|
|
49
|
+
*/
|
|
50
|
+
export declare const getCenterFromBounds: (bounds: OpenFin.WindowBounds) => Point;
|
|
51
|
+
/**
|
|
52
|
+
* Gets the top and left coords of a window given its size and center point
|
|
53
|
+
* @param center point representing the desired center coords
|
|
54
|
+
* @param size height and width of the window
|
|
55
|
+
* @returns coords representing the left, top of window given the center point
|
|
56
|
+
*/
|
|
57
|
+
export declare const getBoundsFromCenter: (center: Point, size: Size) => Point;
|
|
58
|
+
/**
|
|
59
|
+
* Get a wrapped OpenFin window.
|
|
60
|
+
*
|
|
61
|
+
* This method can only be used in an OF env.
|
|
62
|
+
* If used outside of OF, such as in a pre-rendering context, will throw a clear and traceable error.
|
|
63
|
+
*
|
|
64
|
+
* @param identity the window identity.
|
|
65
|
+
* @returns the wrapped OpenFin window identity.
|
|
66
|
+
*/
|
|
67
|
+
export declare function getOFWindow(identity: WindowIdentity): _Window;
|
|
68
|
+
/**
|
|
69
|
+
* The OpenFin identity for the current window.
|
|
70
|
+
*/
|
|
71
|
+
export declare const currentOFIdentity: WindowIdentity;
|
|
72
|
+
/**
|
|
73
|
+
* Get the current OpenFin window.
|
|
74
|
+
*/
|
|
75
|
+
export declare function getCurrentOFWindow(): _Window;
|
|
76
|
+
/**
|
|
77
|
+
* The OpenFin identity for Home.
|
|
78
|
+
*/
|
|
79
|
+
export declare const homeOFIdentity: WindowIdentity;
|
|
80
|
+
export declare const dockOFIdentity: WindowIdentity;
|
|
81
|
+
export declare const StorefrontOFIdentity: WindowIdentity;
|
|
82
|
+
export declare const providerOFIdentity: WindowIdentity;
|
|
83
|
+
/**
|
|
84
|
+
* Get the Home OpenFin window.
|
|
85
|
+
*/
|
|
86
|
+
export declare function getHomeOFWindow(): _Window;
|
|
87
|
+
export declare function getDockOFWindow(): _Window;
|
|
88
|
+
/**
|
|
89
|
+
* Helper for max and restoring a window.
|
|
90
|
+
* @param identity the identity of the window to maximize or restore.
|
|
91
|
+
*/
|
|
92
|
+
export declare function maxOrRestore(identity: WindowIdentity): Promise<void>;
|
|
93
|
+
/**
|
|
94
|
+
* Helper for showing a window.
|
|
95
|
+
* This method ensures the window is shown, brought to front and focused.
|
|
96
|
+
* @param identity the identity of the window to show.
|
|
97
|
+
*/
|
|
98
|
+
export declare function showAndFocus(identity: WindowIdentity): Promise<void>;
|
|
99
|
+
/**
|
|
100
|
+
* Helper for hiding a window.
|
|
101
|
+
* This method ensures the window is hidden and blurred.
|
|
102
|
+
* @param identity the identity of the window to hide.
|
|
103
|
+
*/
|
|
104
|
+
export declare function hideAndBlur(identity: WindowIdentity): Promise<void>;
|
|
105
|
+
/**
|
|
106
|
+
* Helper for showing / hiding a window.
|
|
107
|
+
* This method calls showAndFocus / hideAndBlur
|
|
108
|
+
* @param identity the identity of the window to hide.
|
|
109
|
+
*/
|
|
110
|
+
export declare function toggleVisibility(identity: WindowIdentity): Promise<void>;
|
|
111
|
+
export declare const toggleDock: () => Promise<void>;
|
|
112
|
+
export declare const showAndFocusDock: () => Promise<void>;
|
|
113
|
+
export declare function isAnimatingSize(): boolean;
|
|
114
|
+
/**
|
|
115
|
+
* Resizes a window to width and height saved in the store
|
|
116
|
+
* if they differ from current window size.
|
|
117
|
+
*/
|
|
118
|
+
export declare function restoreWindowSize(): Promise<void>;
|
|
119
|
+
export declare function animateSize(width: number, height: number): Promise<void>;
|
|
120
|
+
/**
|
|
121
|
+
* Returns true if the window name is that of a browser window.
|
|
122
|
+
* @param name the window name.
|
|
123
|
+
* @returns true if the name is that of a browser window's.
|
|
124
|
+
*/
|
|
125
|
+
export declare const isBrowserWindow: (name: string) => boolean;
|
|
126
|
+
/**
|
|
127
|
+
* Force document body size. Called when resizing or on scaling changes.
|
|
128
|
+
*/
|
|
129
|
+
export declare function forceBodySize(): void;
|
|
130
|
+
/**
|
|
131
|
+
* Gets all currently open browser windows.
|
|
132
|
+
*/
|
|
133
|
+
export declare function getBrowserWindows(): Promise<_Window[]>;
|
|
134
|
+
/**
|
|
135
|
+
* Closes all currently open Browser windows.
|
|
136
|
+
*/
|
|
137
|
+
export declare function closeBrowserWindows(): Promise<void>;
|
|
138
|
+
/**
|
|
139
|
+
* Returns true if the OpenFin window for the provided identity is running.
|
|
140
|
+
* */
|
|
141
|
+
export declare const isWindowRunning: (identity: WindowIdentity) => Promise<boolean>;
|
|
142
|
+
/**
|
|
143
|
+
* Check if Storefront window is running.
|
|
144
|
+
* @returns true if the Storefront window is running.
|
|
145
|
+
*/
|
|
146
|
+
export declare const isStorefrontWindowRunning: () => Promise<boolean>;
|
|
147
|
+
export declare const isHomeWindowRunning: () => Promise<boolean>;
|
|
148
|
+
export declare const showAndFocusStorefront: () => Promise<void>;
|
|
149
|
+
export declare const centerWindowIfOffScreen: (windowIdentity?: WindowIdentity) => Promise<void>;
|
|
150
|
+
export {};
|
package/index.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './client-api-platform/src';
|
package/index.js
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
(()=>{var e={282:(e,t,n)=>{e=n.nmd(e);var o="__lodash_hash_undefined__",r=9007199254740991,a="[object Arguments]",i="[object Function]",s="[object Object]",c=/^\[object .+?Constructor\]$/,u=/^(?:0|[1-9]\d*)$/,d={};d["[object Float32Array]"]=d["[object Float64Array]"]=d["[object Int8Array]"]=d["[object Int16Array]"]=d["[object Int32Array]"]=d["[object Uint8Array]"]=d["[object Uint8ClampedArray]"]=d["[object Uint16Array]"]=d["[object Uint32Array]"]=!0,d[a]=d["[object Array]"]=d["[object ArrayBuffer]"]=d["[object Boolean]"]=d["[object DataView]"]=d["[object Date]"]=d["[object Error]"]=d[i]=d["[object Map]"]=d["[object Number]"]=d[s]=d["[object RegExp]"]=d["[object Set]"]=d["[object String]"]=d["[object WeakMap]"]=!1;var l="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g,p="object"==typeof self&&self&&self.Object===Object&&self,f=l||p||Function("return this")(),g=t&&!t.nodeType&&t,w=g&&e&&!e.nodeType&&e,h=w&&w.exports===g,y=h&&l.process,v=function(){try{return w&&w.require&&w.require("util").types||y&&y.binding&&y.binding("util")}catch(e){}}(),m=v&&v.isTypedArray;function P(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}var S,b,_,I=Array.prototype,A=Function.prototype,O=Object.prototype,W=f["__core-js_shared__"],R=A.toString,E=O.hasOwnProperty,C=(S=/[^.]+$/.exec(W&&W.keys&&W.keys.IE_PROTO||""))?"Symbol(src)_1."+S:"",T=O.toString,k=R.call(Object),F=RegExp("^"+R.call(E).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),L=h?f.Buffer:void 0,U=f.Symbol,j=f.Uint8Array,$=(L&&L.allocUnsafe,b=Object.getPrototypeOf,_=Object,function(e){return b(_(e))}),B=Object.create,D=O.propertyIsEnumerable,M=I.splice,x=U?U.toStringTag:void 0,G=function(){try{var e=se(Object,"defineProperty");return e({},"",{}),e}catch(e){}}(),N=L?L.isBuffer:void 0,z=Math.max,V=Date.now,q=se(f,"Map"),H=se(Object,"create"),Y=function(){function e(){}return function(t){if(!me(t))return{};if(B)return B(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();function K(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var o=e[t];this.set(o[0],o[1])}}function J(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var o=e[t];this.set(o[0],o[1])}}function Z(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var o=e[t];this.set(o[0],o[1])}}function X(e){var t=this.__data__=new J(e);this.size=t.size}function Q(e,t,n){(void 0!==n&&!pe(e[t],n)||void 0===n&&!(t in e))&&ne(e,t,n)}function ee(e,t,n){var o=e[t];E.call(e,t)&&pe(o,n)&&(void 0!==n||t in e)||ne(e,t,n)}function te(e,t){for(var n=e.length;n--;)if(pe(e[n][0],t))return n;return-1}function ne(e,t,n){"__proto__"==t&&G?G(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}K.prototype.clear=function(){this.__data__=H?H(null):{},this.size=0},K.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},K.prototype.get=function(e){var t=this.__data__;if(H){var n=t[e];return n===o?void 0:n}return E.call(t,e)?t[e]:void 0},K.prototype.has=function(e){var t=this.__data__;return H?void 0!==t[e]:E.call(t,e)},K.prototype.set=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=H&&void 0===t?o:t,this},J.prototype.clear=function(){this.__data__=[],this.size=0},J.prototype.delete=function(e){var t=this.__data__,n=te(t,e);return!(n<0||(n==t.length-1?t.pop():M.call(t,n,1),--this.size,0))},J.prototype.get=function(e){var t=this.__data__,n=te(t,e);return n<0?void 0:t[n][1]},J.prototype.has=function(e){return te(this.__data__,e)>-1},J.prototype.set=function(e,t){var n=this.__data__,o=te(n,e);return o<0?(++this.size,n.push([e,t])):n[o][1]=t,this},Z.prototype.clear=function(){this.size=0,this.__data__={hash:new K,map:new(q||J),string:new K}},Z.prototype.delete=function(e){var t=ie(this,e).delete(e);return this.size-=t?1:0,t},Z.prototype.get=function(e){return ie(this,e).get(e)},Z.prototype.has=function(e){return ie(this,e).has(e)},Z.prototype.set=function(e,t){var n=ie(this,e),o=n.size;return n.set(e,t),this.size+=n.size==o?0:1,this},X.prototype.clear=function(){this.__data__=new J,this.size=0},X.prototype.delete=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n},X.prototype.get=function(e){return this.__data__.get(e)},X.prototype.has=function(e){return this.__data__.has(e)},X.prototype.set=function(e,t){var n=this.__data__;if(n instanceof J){var o=n.__data__;if(!q||o.length<199)return o.push([e,t]),this.size=++n.size,this;n=this.__data__=new Z(o)}return n.set(e,t),this.size=n.size,this};function oe(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":x&&x in Object(e)?function(e){var t=E.call(e,x),n=e[x];try{e[x]=void 0;var o=!0}catch(e){}var r=T.call(e);return o&&(t?e[x]=n:delete e[x]),r}(e):function(e){return T.call(e)}(e)}function re(e){return Pe(e)&&oe(e)==a}function ae(e,t,n,o,r){e!==t&&function(e,t,n){for(var o=-1,r=Object(e),a=n(e),i=a.length;i--;){var s=a[++o];if(!1===t(r[s],s,r))break}}(t,(function(a,i){if(r||(r=new X),me(a))!function(e,t,n,o,r,a,i){var c=de(e,n),u=de(t,n),d=i.get(u);if(d)Q(e,n,d);else{var l,p,f,g,w,h=a?a(c,u,n+"",e,t,i):void 0,y=void 0===h;if(y){var v=ge(u),m=!v&&he(u),P=!v&&!m&&Se(u);h=u,v||m||P?ge(c)?h=c:Pe(w=c)&&we(w)?h=function(e,t){var n=-1,o=e.length;for(t||(t=Array(o));++n<o;)t[n]=e[n];return t}(c):m?(y=!1,h=function(e,t){return e.slice()}(u)):P?(y=!1,g=new(f=(l=u).buffer).constructor(f.byteLength),new j(g).set(new j(f)),p=g,h=new l.constructor(p,l.byteOffset,l.length)):h=[]:function(e){if(!Pe(e)||oe(e)!=s)return!1;var t=$(e);if(null===t)return!0;var n=E.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&R.call(n)==k}(u)||fe(u)?(h=c,fe(c)?h=function(e){return function(e,t,n,o){var r=!n;n||(n={});for(var a=-1,i=t.length;++a<i;){var s=t[a],c=void 0;void 0===c&&(c=e[s]),r?ne(n,s,c):ee(n,s,c)}return n}(e,be(e))}(c):me(c)&&!ye(c)||(h=function(e){return"function"!=typeof e.constructor||ue(e)?{}:Y($(e))}(u))):y=!1}y&&(i.set(u,h),r(h,u,o,a,i),i.delete(u)),Q(e,n,h)}}(e,t,i,n,ae,o,r);else{var c=o?o(de(e,i),a,i+"",e,t,r):void 0;void 0===c&&(c=a),Q(e,i,c)}}),be)}function ie(e,t){var n,o,r=e.__data__;return("string"==(o=typeof(n=t))||"number"==o||"symbol"==o||"boolean"==o?"__proto__"!==n:null===n)?r["string"==typeof t?"string":"hash"]:r.map}function se(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return function(e){return!(!me(e)||function(e){return!!C&&C in e}(e))&&(ye(e)?F:c).test(function(e){if(null!=e){try{return R.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e))}(n)?n:void 0}function ce(e,t){var n=typeof e;return!!(t=null==t?r:t)&&("number"==n||"symbol"!=n&&u.test(e))&&e>-1&&e%1==0&&e<t}function ue(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||O)}function de(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}var le=function(e){var t=0,n=0;return function(){var o=V(),r=16-(o-n);if(n=o,r>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}(G?function(e,t){return G(e,"toString",{configurable:!0,enumerable:!1,value:(n=t,function(){return n}),writable:!0});var n}:Ae);function pe(e,t){return e===t||e!=e&&t!=t}var fe=re(function(){return arguments}())?re:function(e){return Pe(e)&&E.call(e,"callee")&&!D.call(e,"callee")},ge=Array.isArray;function we(e){return null!=e&&ve(e.length)&&!ye(e)}var he=N||function(){return!1};function ye(e){if(!me(e))return!1;var t=oe(e);return t==i||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}function ve(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=r}function me(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function Pe(e){return null!=e&&"object"==typeof e}var Se=m?function(e){return function(t){return e(t)}}(m):function(e){return Pe(e)&&ve(e.length)&&!!d[oe(e)]};function be(e){return we(e)?function(e,t){var n=ge(e),o=!n&&fe(e),r=!n&&!o&&he(e),a=!n&&!o&&!r&&Se(e),i=n||o||r||a,s=i?function(e,t){for(var n=-1,o=Array(e);++n<e;)o[n]=t(n);return o}(e.length,String):[],c=s.length;for(var u in e)!t&&!E.call(e,u)||i&&("length"==u||r&&("offset"==u||"parent"==u)||a&&("buffer"==u||"byteLength"==u||"byteOffset"==u)||ce(u,c))||s.push(u);return s}(e,!0):function(e){if(!me(e))return function(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t}(e);var t=ue(e),n=[];for(var o in e)("constructor"!=o||!t&&E.call(e,o))&&n.push(o);return n}(e)}var _e,Ie=(_e=function(e,t,n,o){ae(e,t,n,o)},function(e,t){return le(function(e,t,n){return t=z(void 0===t?e.length-1:t,0),function(){for(var o=arguments,r=-1,a=z(o.length-t,0),i=Array(a);++r<a;)i[r]=o[t+r];r=-1;for(var s=Array(t+1);++r<t;)s[r]=o[r];return s[t]=n(i),P(e,this,s)}}(e,t,Ae),e+"")}((function(e,t){var n=-1,o=t.length,r=o>1?t[o-1]:void 0,a=o>2?t[2]:void 0;for(r=_e.length>3&&"function"==typeof r?(o--,r):void 0,a&&function(e,t,n){if(!me(n))return!1;var o=typeof t;return!!("number"==o?we(n)&&ce(t,n.length):"string"==o&&t in n)&&pe(n[t],e)}(t[0],t[1],a)&&(r=o<3?void 0:r,o=1),e=Object(e);++n<o;){var i=t[n];i&&_e(e,i,n,r)}return e})));function Ae(e){return e}e.exports=Ie},485:function(e){var t;t=function(){var e=JSON.parse('{"$":"dollar","%":"percent","&":"and","<":"less",">":"greater","|":"or","¢":"cent","£":"pound","¤":"currency","¥":"yen","©":"(c)","ª":"a","®":"(r)","º":"o","À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","Æ":"AE","Ç":"C","È":"E","É":"E","Ê":"E","Ë":"E","Ì":"I","Í":"I","Î":"I","Ï":"I","Ð":"D","Ñ":"N","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","Ù":"U","Ú":"U","Û":"U","Ü":"U","Ý":"Y","Þ":"TH","ß":"ss","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","æ":"ae","ç":"c","è":"e","é":"e","ê":"e","ë":"e","ì":"i","í":"i","î":"i","ï":"i","ð":"d","ñ":"n","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","ù":"u","ú":"u","û":"u","ü":"u","ý":"y","þ":"th","ÿ":"y","Ā":"A","ā":"a","Ă":"A","ă":"a","Ą":"A","ą":"a","Ć":"C","ć":"c","Č":"C","č":"c","Ď":"D","ď":"d","Đ":"DJ","đ":"dj","Ē":"E","ē":"e","Ė":"E","ė":"e","Ę":"e","ę":"e","Ě":"E","ě":"e","Ğ":"G","ğ":"g","Ģ":"G","ģ":"g","Ĩ":"I","ĩ":"i","Ī":"i","ī":"i","Į":"I","į":"i","İ":"I","ı":"i","Ķ":"k","ķ":"k","Ļ":"L","ļ":"l","Ľ":"L","ľ":"l","Ł":"L","ł":"l","Ń":"N","ń":"n","Ņ":"N","ņ":"n","Ň":"N","ň":"n","Ō":"O","ō":"o","Ő":"O","ő":"o","Œ":"OE","œ":"oe","Ŕ":"R","ŕ":"r","Ř":"R","ř":"r","Ś":"S","ś":"s","Ş":"S","ş":"s","Š":"S","š":"s","Ţ":"T","ţ":"t","Ť":"T","ť":"t","Ũ":"U","ũ":"u","Ū":"u","ū":"u","Ů":"U","ů":"u","Ű":"U","ű":"u","Ų":"U","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","ź":"z","Ż":"Z","ż":"z","Ž":"Z","ž":"z","Ə":"E","ƒ":"f","Ơ":"O","ơ":"o","Ư":"U","ư":"u","Lj":"LJ","lj":"lj","Nj":"NJ","nj":"nj","Ș":"S","ș":"s","Ț":"T","ț":"t","ə":"e","˚":"o","Ά":"A","Έ":"E","Ή":"H","Ί":"I","Ό":"O","Ύ":"Y","Ώ":"W","ΐ":"i","Α":"A","Β":"B","Γ":"G","Δ":"D","Ε":"E","Ζ":"Z","Η":"H","Θ":"8","Ι":"I","Κ":"K","Λ":"L","Μ":"M","Ν":"N","Ξ":"3","Ο":"O","Π":"P","Ρ":"R","Σ":"S","Τ":"T","Υ":"Y","Φ":"F","Χ":"X","Ψ":"PS","Ω":"W","Ϊ":"I","Ϋ":"Y","ά":"a","έ":"e","ή":"h","ί":"i","ΰ":"y","α":"a","β":"b","γ":"g","δ":"d","ε":"e","ζ":"z","η":"h","θ":"8","ι":"i","κ":"k","λ":"l","μ":"m","ν":"n","ξ":"3","ο":"o","π":"p","ρ":"r","ς":"s","σ":"s","τ":"t","υ":"y","φ":"f","χ":"x","ψ":"ps","ω":"w","ϊ":"i","ϋ":"y","ό":"o","ύ":"y","ώ":"w","Ё":"Yo","Ђ":"DJ","Є":"Ye","І":"I","Ї":"Yi","Ј":"J","Љ":"LJ","Њ":"NJ","Ћ":"C","Џ":"DZ","А":"A","Б":"B","В":"V","Г":"G","Д":"D","Е":"E","Ж":"Zh","З":"Z","И":"I","Й":"J","К":"K","Л":"L","М":"M","Н":"N","О":"O","П":"P","Р":"R","С":"S","Т":"T","У":"U","Ф":"F","Х":"H","Ц":"C","Ч":"Ch","Ш":"Sh","Щ":"Sh","Ъ":"U","Ы":"Y","Ь":"","Э":"E","Ю":"Yu","Я":"Ya","а":"a","б":"b","в":"v","г":"g","д":"d","е":"e","ж":"zh","з":"z","и":"i","й":"j","к":"k","л":"l","м":"m","н":"n","о":"o","п":"p","р":"r","с":"s","т":"t","у":"u","ф":"f","х":"h","ц":"c","ч":"ch","ш":"sh","щ":"sh","ъ":"u","ы":"y","ь":"","э":"e","ю":"yu","я":"ya","ё":"yo","ђ":"dj","є":"ye","і":"i","ї":"yi","ј":"j","љ":"lj","њ":"nj","ћ":"c","ѝ":"u","џ":"dz","Ґ":"G","ґ":"g","Ғ":"GH","ғ":"gh","Қ":"KH","қ":"kh","Ң":"NG","ң":"ng","Ү":"UE","ү":"ue","Ұ":"U","ұ":"u","Һ":"H","һ":"h","Ә":"AE","ә":"ae","Ө":"OE","ө":"oe","฿":"baht","ა":"a","ბ":"b","გ":"g","დ":"d","ე":"e","ვ":"v","ზ":"z","თ":"t","ი":"i","კ":"k","ლ":"l","მ":"m","ნ":"n","ო":"o","პ":"p","ჟ":"zh","რ":"r","ს":"s","ტ":"t","უ":"u","ფ":"f","ქ":"k","ღ":"gh","ყ":"q","შ":"sh","ჩ":"ch","ც":"ts","ძ":"dz","წ":"ts","ჭ":"ch","ხ":"kh","ჯ":"j","ჰ":"h","Ẁ":"W","ẁ":"w","Ẃ":"W","ẃ":"w","Ẅ":"W","ẅ":"w","ẞ":"SS","Ạ":"A","ạ":"a","Ả":"A","ả":"a","Ấ":"A","ấ":"a","Ầ":"A","ầ":"a","Ẩ":"A","ẩ":"a","Ẫ":"A","ẫ":"a","Ậ":"A","ậ":"a","Ắ":"A","ắ":"a","Ằ":"A","ằ":"a","Ẳ":"A","ẳ":"a","Ẵ":"A","ẵ":"a","Ặ":"A","ặ":"a","Ẹ":"E","ẹ":"e","Ẻ":"E","ẻ":"e","Ẽ":"E","ẽ":"e","Ế":"E","ế":"e","Ề":"E","ề":"e","Ể":"E","ể":"e","Ễ":"E","ễ":"e","Ệ":"E","ệ":"e","Ỉ":"I","ỉ":"i","Ị":"I","ị":"i","Ọ":"O","ọ":"o","Ỏ":"O","ỏ":"o","Ố":"O","ố":"o","Ồ":"O","ồ":"o","Ổ":"O","ổ":"o","Ỗ":"O","ỗ":"o","Ộ":"O","ộ":"o","Ớ":"O","ớ":"o","Ờ":"O","ờ":"o","Ở":"O","ở":"o","Ỡ":"O","ỡ":"o","Ợ":"O","ợ":"o","Ụ":"U","ụ":"u","Ủ":"U","ủ":"u","Ứ":"U","ứ":"u","Ừ":"U","ừ":"u","Ử":"U","ử":"u","Ữ":"U","ữ":"u","Ự":"U","ự":"u","Ỳ":"Y","ỳ":"y","Ỵ":"Y","ỵ":"y","Ỷ":"Y","ỷ":"y","Ỹ":"Y","ỹ":"y","–":"-","‘":"\'","’":"\'","“":"\\"","”":"\\"","„":"\\"","†":"+","•":"*","…":"...","₠":"ecu","₢":"cruzeiro","₣":"french franc","₤":"lira","₥":"mill","₦":"naira","₧":"peseta","₨":"rupee","₩":"won","₪":"new shequel","₫":"dong","€":"euro","₭":"kip","₮":"tugrik","₯":"drachma","₰":"penny","₱":"peso","₲":"guarani","₳":"austral","₴":"hryvnia","₵":"cedi","₸":"kazakhstani tenge","₹":"indian rupee","₺":"turkish lira","₽":"russian ruble","₿":"bitcoin","℠":"sm","™":"tm","∂":"d","∆":"delta","∑":"sum","∞":"infinity","♥":"love","元":"yuan","円":"yen","﷼":"rial"}'),t=JSON.parse('{"de":{"Ä":"AE","ä":"ae","Ö":"OE","ö":"oe","Ü":"UE","ü":"ue","%":"prozent","&":"und","|":"oder","∑":"summe","∞":"unendlich","♥":"liebe"},"es":{"%":"por ciento","&":"y","<":"menor que",">":"mayor que","|":"o","¢":"centavos","£":"libras","¤":"moneda","₣":"francos","∑":"suma","∞":"infinito","♥":"amor"},"fr":{"%":"pourcent","&":"et","<":"plus petit",">":"plus grand","|":"ou","¢":"centime","£":"livre","¤":"devise","₣":"franc","∑":"somme","∞":"infini","♥":"amour"},"pt":{"%":"porcento","&":"e","<":"menor",">":"maior","|":"ou","¢":"centavo","∑":"soma","£":"libra","∞":"infinito","♥":"amor"},"uk":{"И":"Y","и":"y","Й":"Y","й":"y","Ц":"Ts","ц":"ts","Х":"Kh","х":"kh","Щ":"Shch","щ":"shch","Г":"H","г":"h"},"vi":{"Đ":"D","đ":"d"}}');function n(n,o){if("string"!=typeof n)throw new Error("slugify: string argument expected");var r=t[(o="string"==typeof o?{replacement:o}:o||{}).locale]||{},a=void 0===o.replacement?"-":o.replacement,i=n.normalize().split("").reduce((function(t,n){return t+(r[n]||e[n]||(n===a?" ":n)).replace(o.remove||/[^\w\s$*_+~.()'"!\-:@]+/g,"")}),"");return o.strict&&(i=i.replace(/[^A-Za-z0-9\s]/g,"")),i=i.trim().replace(/\s+/g,a),o.lower&&(i=i.toLowerCase()),i}return n.extend=function(t){Object.assign(e,t)},n},e.exports=t(),e.exports.default=t()}},t={};function n(o){var r=t[o];if(void 0!==r)return r.exports;var a=t[o]={id:o,loaded:!1,exports:{}};return e[o].call(a.exports,a,a.exports,n),a.loaded=!0,a.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var o in t)n.o(t,o)&&!n.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.nmd=e=>(e.paths=[],e.children||(e.children=[]),e);var o={};(()=>{"use strict";n.r(o),n.d(o,{AppManifestType:()=>vn,getCurrentSync:()=>Zn,init:()=>Kn,wrapSync:()=>Jn});var e={};n.r(e),n.d(e,{subscribe:()=>Ft});var t,r,a={};n.r(a),n.d(a,{create:()=>pn}),function(e){e.Local="local",e.Dev="dev",e.Staging="staging",e.Prod="prod"}(r||(r={}));const i="undefined"!=typeof window&&"undefined"!=typeof fin,s=("undefined"==typeof process||null===(t=process.env)||void 0===t||t.JEST_WORKER_ID,"undefined"!=typeof window),c=s&&"undefined"!=typeof indexedDB,u=s?window.origin:r.Local,d=i&&fin.me.uuid,l=i&&fin.me.name,p=i&&fin.me.entityType,f="undefined"!=typeof ENV?ENV:r.Local,g=(r.Local,r.Dev,r.Staging,r.Prod,e=>e.startsWith("http://")||e.startsWith("https://")?e:u+e),w=("undefined"!=typeof WORKSPACE_APPS_URL&&g(WORKSPACE_APPS_URL),"undefined"!=typeof WORKSPACE_STOREFRONT_FOOTER_URL&&g(WORKSPACE_STOREFRONT_FOOTER_URL),"undefined"!=typeof WORKSPACE_STOREFRONT_LANDING_PAGE_URL&&g(WORKSPACE_STOREFRONT_LANDING_PAGE_URL),"undefined"!=typeof WORKSPACE_STOREFRONT_NAVIGATION_URL&&g(WORKSPACE_STOREFRONT_NAVIGATION_URL),"undefined"!=typeof WORKSPACE_SHARE_URL&&g(WORKSPACE_SHARE_URL),g("https://cdn.openfin.co/workspace/5.5.0"),g("https://cdn.openfin.co/workspace/5.5.0"));var h,y;"undefined"!=typeof window&&new Promise((e=>window.addEventListener("load",(()=>window.requestAnimationFrame((()=>e())))))),(y=h||(h={})).LaunchApp="launchApp",y.SavePage="savePage",y.GetSavedPage="getSavedPage",y.CreateSavedPage="createSavedPage",y.UpdateSavedPage="updateSavedPage",y.DeleteSavedPage="deleteSavedPage",y.GetSavedPages="getSavedPages",y.CreateSavedPageInternal="createSavedPageInternal",y.UpdateSavedPageInternal="updateSavedPageInternal",y.DeleteSavedPageInternal="deleteSavedPageInternal",y.SharePage="sharePage",y.LaunchPage="launchPage",y.UpdatePageForWindow="updatePageForWindow",y.AttachPagesToWindow="attachPagesToWindow",y.DetachPagesFromWindow="detachPagesFromWindow",y.ReorderPagesForWindow="reorderPagesForWindow",y.SetActivePage="setActivePage",y.GetAllAttachedPages="getAllAttachedPages",y.GetActivePageIdForWindow="getActivePageIdForWindow",y.GetPagesForWindow="getPagesForWindow",y.GetPageForWindow="getPageForWindow",y.GetSavedPageMetadata="getSavedPageMetadata",y.GetUniquePageTitle="getUniquePageTitle",y.GetLastFocusedBrowserWindow="getLastFocusedBrowserWindow",y.GetThemes="getThemes";const v=async e=>{const t=fin.Platform.wrapSync(e),n=await t.getClient(),o="Target is not a Workspace Platform. Target must call WorkspacePlatform.init";try{if(!0===await n.dispatch("isWorkspacePlatform"))return n;throw new Error(o)}catch(e){throw new Error(o)}},m=e=>({identity:e,openfinWindow:fin.Window.wrapSync(e),getPages:async()=>(await v(e)).dispatch(h.GetPagesForWindow,e),getPage:async t=>(await v(e)).dispatch(h.GetPageForWindow,{identity:e,pageId:t}),addPage:async t=>{const n=await v(e);(null==t?void 0:t.title)||(t.title=await n.dispatch(h.GetUniquePageTitle,void 0));const o=(await n.dispatch(h.GetAllAttachedPages,void 0)).find((e=>e.pageId===t.pageId||e.title===t.title));if(o)throw o.pageId===t.pageId?new Error(`page with id ${t.pageId} is already attached to a browser window ${o.parentIdentity.name}`):new Error(`page with title ${t.title} is already attached to a browser window ${o.parentIdentity.name}`);const r={identity:e,pages:[t]};return n.dispatch(h.AttachPagesToWindow,r)},removePage:async t=>(await v(e)).dispatch(h.DetachPagesFromWindow,{identity:e,pageIds:[t]}),setActivePage:async t=>(await v(e)).dispatch(h.SetActivePage,{identity:e,pageId:t}),updatePage:async t=>{const n=await v(e);return t.identity=e,n.dispatch(h.UpdatePageForWindow,t)},reorderPages:async t=>{const n=await v(e);return t.identity=e,n.dispatch(h.ReorderPagesForWindow,t)}}),P=e=>{const t=fin.Platform.wrapSync(e),n=async()=>(await t.getClient()).dispatch(h.GetAllAttachedPages,void 0);return{wrapSync:e=>m(e),createWindow:async e=>{const n=await t.createWindow(e);return m(n.identity)},getAllAttachedPages:n,getAllWindows:async()=>(await fin.Application.wrapSync(e).getChildWindows()).filter((e=>e.identity.name.includes("internal-generated-window-"))).map((e=>m(e.identity))),launchPage:async e=>{const o=await t.getClient();await o.dispatch(h.LaunchPage,{page:e,attachToExistingWindow:!0});const r=(await n()).find((t=>t.pageId===e.pageId));return m(r.parentIdentity)},getUniquePageTitle:async t=>(await v(e)).dispatch(h.GetUniquePageTitle,t),getLastFocusedWindow:async()=>(await v(e)).dispatch(h.GetLastFocusedBrowserWindow,void 0)}},S=e=>({createPage:async t=>(await v(e)).dispatch(h.CreateSavedPageInternal,t),deletePage:async t=>(await v(e)).dispatch(h.DeleteSavedPageInternal,t),updatePage:async t=>(await v(e)).dispatch(h.UpdateSavedPageInternal,t),getPage:async t=>(await v(e)).dispatch(h.GetSavedPage,t),getPages:async t=>(await v(e)).dispatch(h.GetSavedPages,t),savePage:async t=>(await v(e)).dispatch(h.SavePage,t)}),b=e=>({getThemes:async()=>(await v(e)).dispatch(h.GetThemes,void 0)});let _=[];const I=()=>_;var A,O,W;!function(e){e.Workspace="openfin-browser"}(A||(A={})),function(e){e.RunRequested="run-requested",e.WindowOptionsChanged="window-options-changed",e.WindowClosed="window-closed",e.WindowCreated="window-created"}(O||(O={})),function(e){e.FinProtocol="fin-protocol"}(W||(W={}));const R={uuid:d,name:d},E=(A.Workspace,A.Workspace,e=>{if(!i)throw new Error("getApplication cannot be used in a non OpenFin env. Avoid using this during pre-rendering.");return fin.Application.wrapSync(e)});var C,T,k;function F(e){if(!i)throw new Error("getOFWindow can only be used in an OpenFin env. Avoid calling this method during pre-rendering.");return fin.Window.wrapSync(e)}!function(e){e.Home="openfin-home",e.Dock="openfin-dock",e.Storefront="openfin-storefront",e.HomeInternal="openfin-home-internal",e.BrowserMenu="openfin-browser-menu",e.BrowserIndicator="openfin-browser-indicator",e.BrowserWindow="internal-generated-window"}(C||(C={})),(k=T||(T={})).Shown="shown",k.BoundsChanged="bounds-changed",k.LayoutReady="layout-ready",k.EndUserBoundsChanging="end-user-bounds-changing",k.Blurred="blurred",k.CloseRequested="close-requested",k.Focused="focused",k.ShowRequested="show-requested",k.ViewCrashed="view-crashed",k.ViewAttached="view-attached",k.ViewDetached="view-detached",k.ViewPageTitleUpdated="view-page-title-updated",k.ViewDestroyed="view-destroyed";const L={name:l,uuid:d};function U(){return F(L)}C.Home,A.Workspace,C.Dock,A.Workspace,C.Storefront,A.Workspace,A.Workspace,A.Workspace;const j=e=>e.startsWith(C.BrowserWindow);async function $(){return(await fin.Application.getCurrentSync().getChildWindows()).filter((e=>j(e.identity.name)))}var B,D;(D=B||(B={})).LastLaunchedWorkspaceId="activeWorkspaceId",D.LastFocusedBrowserWindow="lastFocusedBrowserWindow",D.MachineName="machineName",D.NewTabPageLayout="NewTabPageLayout",D.NewTabPageSort="NewTabPageSort";const M=B,x={trace:!0,debug:"undefined"!=typeof LOG_DEBUG&&LOG_DEBUG,info:!1,warn:!0,error:!0,fatal:!0};function G(e,t){const n=void 0===t?x:{...x,...t},o=e?`${e} : `:"";return{trace:n.trace?(e,...t)=>{console.trace(`%c${o}${e}`,"color:#7795f7",...t)}:(e,...t)=>{},debug:n.debug?(e,...t)=>{console.info(`%c${o}${e}`,"color:#86db94",...t)}:(e,...t)=>{},info:n.info?(e,...t)=>{console.debug(`%c${o}${e}`,"color:#ffffff",...t)}:(e,...t)=>{},warn:n.warn?(e,...t)=>{console.warn(`%c${o}${e}`,"color:#edad68",...t)}:(e,...t)=>{},error:n.error?(e,t,...n)=>{console.error(`%c${o}${e}`,"color:#f55d67",...n,t)}:(e,t,...n)=>{},fatal:n.fatal?(e,t,...n)=>{console.error(`%c${o}${e}`,"color:#f70723",...n,t)}:(e,t,...n)=>{}}}const N=G("api.platform-window-focus");async function z(){if("undefined"!=typeof localStorage)try{const e=localStorage.getItem(M.LastFocusedBrowserWindow),t=JSON.parse(e);if(await(e=>F(e).getOptions().then((()=>!0)).catch((()=>!1)))(t))return t}catch(e){N.error("failed to get last focused browser window: ",e)}}function V(e=fin.me.identity){j(e.name)&&function(e){if("undefined"!=typeof localStorage)try{const t=JSON.stringify(e);localStorage.setItem(M.LastFocusedBrowserWindow,t)}catch(e){N.error("failed to save last focused browser window: ",e)}}(e)}var q;G("utils.layout"),function(e){e.TabCreated="tab-created",e.ContainerCreated="container-created",e.ContainerResized="container-resized"}(q||(q={}));const H=e=>{const t=[];return(e&&Array.isArray(e)?e:[]).forEach((e=>{if("component"===e.type)return t.push(e.componentState);const n=H(e.content);t.push(...n)})),t};new Map;const Y=G("utils.channels"),K=s&&"complete"!==document.readyState&&new Promise((e=>document.addEventListener("readystatechange",(()=>{"complete"===document.readyState&&e()}))));function J(e){let t;return()=>{if(!i)throw new Error("getChannelClient cannot be used outside an OpenFin env. Avoid using this method during pre-rendering.");return t||(Y.debug(`connecting to channel provider ${e}`),t=(async()=>{await K;const n=await fin.InterApplicationBus.Channel.connect(e);return n.onDisconnection((async()=>{Y.warn(`disconnected from channel provider ${e}`),t=void 0})),n})().then((t=>(Y.debug(`connected to channel provider ${e}`),t))).catch((t=>{Y.error(`failed to connect to channel provider ${e}`,t)}))),t}}var Z,X;!function(e){e.GetPages="get-pages",e.GetActivePageForWindow="get-active-page-for-window",e.AttachPagesToWindow="attach-pages-to-window",e.DetachPagesFromWindow="detach-pages-from-window",e.SetActivePageForWindow="set-active-page-for-window",e.RenamePage="rename-page",e.ReorderPagesForWindow="reorder-pages-for-window",e.UpdatePageForWindow="update-page-for-window",e.UpdatePagesWindowOptions="update-pages-window-options",e.IsDetachingPages="is-detaching-pages",e.IsActivePageChanging="is-active-page-changing"}(Z||(Z={})),function(e){e.AttachedPagesToWindow="attached-pages-to-window",e.DetachedPagesFromWindow="detached-pages-from-window"}(X||(X={}));const Q=new Map,ee=e=>{const t=(e=>`__running_pages__-${e.uuid}-${e.name}`)(e);return Q.has(t)||Q.set(t,J(t)),Q.get(t)()},te=(new Map,async e=>{const t=await ee(e);return await t.dispatch(Z.GetPages)}),ne=async e=>(await ee(e.identity)).dispatch(Z.UpdatePageForWindow,e),oe=async()=>{const e=await $();return(await Promise.all(e.map((async({identity:e})=>te(e))))).reduce(((e,t)=>e.concat(t)),[])},re=async()=>(await v(L)).dispatch(h.GetSavedPages,void 0),ae=async e=>(await v(L)).dispatch(h.GetSavedPage,e),ie=async(e,t)=>{const n=await(async e=>(await oe()).find((t=>t.pageId===e)))(e);return!n||n.title===t.title&&e===t.pageId||await ne({identity:n.parentIdentity,pageId:e,page:{pageId:t.pageId,title:t.title}}),n},se=async({page:e})=>{await ie(e.pageId,e),await(async e=>(await v(L)).dispatch(h.CreateSavedPage,e))({page:e})},ce=async e=>{await ae(e)&&await(async e=>(await v(L)).dispatch(h.DeleteSavedPage,e))(e)},ue=async({pageId:e,page:t})=>(await ie(e,t),await(async e=>(await v(L)).dispatch(h.UpdateSavedPage,e))({pageId:e,page:t})),de=async e=>await ae(e.pageId)?ue({pageId:e.pageId,page:e}):se({page:e}),le=async e=>{await(async e=>(await ee(e.identity)).dispatch(Z.AttachPagesToWindow,e))(e)},pe=async e=>{await ne(e)},fe=async e=>{await(async e=>(await ee(e.identity)).dispatch(Z.DetachPagesFromWindow,e))(e)},ge=async e=>{await(async e=>(await ee(e.identity)).dispatch(Z.SetActivePageForWindow,e))(e)},we=e=>te(e),he=async({identity:e,pageId:t})=>(await we(e)).find((e=>e.pageId===t)),ye=async e=>{await(async e=>(await ee(e.identity)).dispatch(Z.ReorderPagesForWindow,e))(e)},ve=(e,t)=>!t.find((t=>t===e)),me=(e,t)=>`${e} (${t})`;async function Pe(e="Untitled Page"){const[t,n]=await Promise.all([re(),oe()]),o=[...t,...n].map((({title:e})=>e));if(!o.find((t=>t===e)))return e;let r=1;const a=e.replace(/ \(.+\)$/,"");for(;!ve(me(a,r),o);)r+=1;return me(a,r)}const Se=G("api.cleanup"),be=new Map,_e=e=>`${e.uuid}-${e.name}`,Ie=((e,t=0)=>{let n,o,r=!1;const a=async o=>{const i=await e(...o);if(r){await new Promise((e=>setTimeout(e,t)));const e=n;return n=void 0,r=!1,a(e)}return i};return(...e)=>(o?(r=!0,n=e):o=a(e).then((e=>(o=void 0,e))),o)})((async function(){Se.debug("scheduling views to cleanup");const e=await oe(),t=new Set;e.forEach((e=>{H(e.layout.content).forEach((e=>{if(e.name){const n=_e(e);t.add(n),Se.debug(`preserving view with id ${n}`)}}))}));const n=U();(await n.getCurrentViews()).forEach((({identity:e})=>{const n=_e(e);if(t.has(n)||be.has(n))return;const o=setTimeout((()=>{Se.debug(`destroying view with id ${n}`),fin.View.wrapSync(e).destroy(),be.delete(n)}),5e3);Se.debug(`scheduled cleanup of view with id ${n}`),be.set(n,o)})),be.forEach(((e,n)=>{t.has(n)&&(clearTimeout(e),be.delete(n),Se.debug(`cancelled scheduled cleanup of view with id ${n}`))}))}),2500),Ae=({name:e})=>{j(e)&&Ie()};function Oe(){return localStorage.getItem(M.MachineName)}let We,Re;async function Ee(){return We||(We=await fin.System.getMachineId()),We}async function Ce(e){var t;const n=e||await fin.Platform.getCurrentSync().getSnapshot();if(null===(t=n.snapshotDetails)||void 0===t?void 0:t.machineId)return n;const o=Oe();return{...n,snapshotDetails:{...e.snapshotDetails,machineId:await Ee(),machineName:o}}}function Te(e){return new Promise(((t,n)=>{e.oncomplete=e.onsuccess=()=>t(e.result),e.onabort=e.onerror=()=>n(e.error)}))}function ke(e,t){const n=indexedDB.open(e);n.onupgradeneeded=()=>n.result.createObjectStore(t);const o=Te(n);return(e,n)=>o.then((o=>n(o.transaction(t,e).objectStore(t))))}function Fe(){return Re||(Re=ke("keyval-store","keyval")),Re}n(485);const Le=c&&ke("openfin-home-pages","pages");async function Ue(e){const t=await function(e,t=Fe()){return t("readonly",(t=>Te(t.get(e))))}(e,Le);return t?(t.pageId=e.toString(),t.title=t.title||t.pageId,t):null}async function je(e){const t=await function(e=Fe()){const t=[];return function(e,t){return e("readonly",(e=>(e.openCursor().onsuccess=function(){this.result&&(t(this.result),this.result.continue())},Te(e.transaction))))}(e,(e=>t.push(e.key))).then((()=>t))}(Le),n=await Promise.all(t.map((e=>Ue(e.toString()))));return e?n.filter((t=>((e,t="")=>e.toLowerCase().includes(t.toLowerCase()))(t.title,e))):n}async function $e({page:e}){await function(e,t,n=Fe()){return n("readwrite",(n=>(n.put(t,e),Te(n.transaction))))}(e.pageId,e,Le)}async function Be(e){await function(e,t=Fe()){return t("readwrite",(t=>(t.delete(e),Te(t.transaction))))}(e,Le)}async function De({pageId:e,page:t}){if(void 0===await Ue(e))throw new Error("page not found");await $e({page:t}),e!==t.pageId&&await Be(e)}var Me;!function(e){e[e.Initial=0]="Initial",e[e.Open=1]="Open",e[e.Close=2]="Close"}(Me||(Me={}));const xe="0",Ge="5",Ne="6",ze=()=>{};function Ve(e,t){return e?`${e}-${t}`:t}function qe(e){return`__search-${e}-topic__`}const He=new Map;function Ye(e,t){He.has(e)||He.set(e,new Set),He.get(e).add(t)}function Ke(e,t){const n=He.get(e);n&&n.delete(t)}const Je=new Map;function Ze(e,t){Je.has(e)||Je.set(e,new Set),Je.get(e).add(t)}function Xe(e,t){const n=Je.get(e);n&&n.delete(t)}const Qe=new Map;function et(e,t){Qe.has(e)||Qe.set(e,new Map),Qe.get(e).set(t.id,t);const n=He.get(e);n&&n.forEach((e=>e()))}function tt(e,t){const n=Qe.get(e);if(!n)return;n.delete(t);const o=Je.get(e);o&&o.forEach((e=>e()))}function nt(e){return Qe.get(e)?[...Qe.get(e).values()]:[]}function ot(e){const t=Qe.get(e);t&&t.clear()}function rt(e,t){const n=Qe.get(e);return n?n.get(t):null}function at(e,t,n){return{...e,action:n||e.actions[0],dispatcherIdentity:t}}function it(e,t,n="ascending"){const o=e||[];if(!(null==t?void 0:t.length))return o;const r=[],a=new Map;t.forEach((e=>{if(e.key)return a.set(e.key,e);r.push(e)}));let i=o.map((e=>{const{key:t}=e;if(t&&a.has(t)){const e=a.get(t);return a.delete(t),e}return e}));return i.push(...a.values(),...r),i="ascending"===n?i.sort(((e,t)=>(null!==e.score&&void 0!==e.score?e.score:1/0)-(null!==t.score&&void 0!==t.score?t.score:1/0))):i.sort(((e,t)=>(null!==t.score&&void 0!==t.score?t.score:1/0)-(null!==e.score&&void 0!==e.score?e.score:1/0))),i}function st(e){const t={};let n=[],o=[],r=Me.Initial;t.getStatus=()=>r,t.getResultBuffer=()=>n,t.setResultBuffer=e=>{n=e,(null==n?void 0:n.length)&&t.onChange()},t.getRevokedBuffer=()=>o,t.setRevokedBuffer=e=>{o=e,(null==o?void 0:o.length)&&t.onChange()},t.onChange=ze;const a={};return t.res=a,a.close=()=>{r!==Me.Close&&(r=Me.Close,t.onChange())},a.open=()=>{r!==Me.Open&&(r=Me.Open,t.onChange())},a.respond=n=>{const o=it(t.getResultBuffer(),n,e);t.setResultBuffer(o)},a.revoke=(...e)=>{const n=new Set(e),o=t.getResultBuffer().filter((({key:e})=>{const t=n.has(e);return t&&n.delete(e),!t}));t.setResultBuffer(o),n.size&&(t.getRevokedBuffer().forEach((e=>n.add(e))),t.setRevokedBuffer([...n]))},t}function ct(e,t,n){const o=new Set;let r=!1;return{close:()=>{r=!0;for(const e of o)e()},req:{id:t,topic:e,...n,context:(null==n?void 0:n.context)||{},onClose:e=>{o.add(e),r&&e()},removeListener:e=>{o.delete(e)}}}}function ut(){return{name:fin.me.name,uuid:fin.me.uuid}}function dt(){let e;try{const t=fin.Platform.getCurrentSync();if(!(null==t?void 0:t.identity))return;e=t.identity.uuid}catch(e){}return e}const lt="deregistered or does not exist",pt=new Error(`provider ${lt}`),ft=new Error("provider with name already exists"),gt=new Error("bad payload"),wt=new Error("subscription rejected"),ht=new Error(`channel ${lt}`),yt=new Map;function vt(e){const t=mt(e);if(t)return t;throw ht}function mt(e){const t=yt.get(e);if(t)return t}function Pt(e,t){yt.set(e,t)}function St(e){console.error("OpenFin Search API: ",e)}const bt=new Map;function _t(e){bt.has(e)||bt.set(e,new Map);const t=bt.get(e);return{getRequestsForIdentity:e=>{const n=function(e){return`${e.uuid}:${e.name}`}(e);return t.has(n)||t.set(n,new Map),t.get(n)}}}async function It(e,t){return(await vt(e)).dispatch(xe,t)}function At({namespacedTopic:e,topic:t}){const n=rt.bind(null,e),o=_t(e),r=It.bind(null,e);return async(e,a)=>{if(!e||!e.id||!e.providerId){const e=gt;return St(e),{error:e.message}}const{id:i,providerId:s}=e,c=n(s);if(!c){const e=pt;return St(e),{error:e.message}}const u=o.getRequestsForIdentity(a);let d=u.get(e.id);d||(d=ct(t,i,e),u.set(e.id,d));const l=st(),p=()=>{const e=l.getResultBuffer();l.setResultBuffer([]);const t=l.getRevokedBuffer();l.setRevokedBuffer([]);const n=l.getStatus();r({id:i,providerId:s,results:e,revoked:t,status:n})};let f=!0,g=!1;l.onChange=()=>{if(f)return f=!1,void p();g||(g=!0,setTimeout((()=>{g=!1,p()}),100))};try{const{results:e,context:t}=await c.onUserInput(d.req,l.res),n=l.getStatus();return{id:i,providerId:s,status:n,results:e,context:t}}catch(e){return St(e),{id:i,providerId:s,error:e.message}}}}async function Ot(e,t,n){const o=n||await vt(e),r=ut(),a={identity:r,...t,onUserInput:void 0,onResultDispatch:void 0};await o.dispatch("2",a),et(e,{identity:r,...t})}async function Wt(e,t){const n=await vt(e);return await n.dispatch("3",t),tt(e,t)}async function Rt(e,t,n,o){const r=at(n,ut(),o),a=rt(e,t);if(a){const{onResultDispatch:e}=a;if(!e)return;return e(r)}const i={providerId:t,result:r};return(await vt(e)).dispatch(Ge,i)}async function Et(e,t){const n={...t,context:(null==t?void 0:t.context)||{}},o={},r=async function*(e,t,{setState:n}){const o=await vt(e);for(;;){const e=await o.dispatch("1",t),r=e.error;if(r)throw new Error(r);const a=e;if(t.id=a.id,n(a.state),a.done)return a.value;yield a.value}}(e,n,{setState:e=>{o.state=e}});let a=await r.next();return o.id=n.id,o.close=()=>{!async function(e,t){(await vt(e)).dispatch(Ne,{id:t})}(e,o.id)},o.next=()=>{if(a){const e=a;return a=void 0,e}return r.next()},o}async function Ct(e){return(await vt(e)).dispatch("4",null)}async function Tt(e){const t=await vt(e);var n;n=e,yt.delete(n),ot(e),await t.disconnect()}async function kt(e){const{namespacedTopic:t}=e,n=qe(t),o=await async function(e){for(let t=0;t<50;t++)try{return await fin.InterApplicationBus.Channel.connect(e,{wait:!1})}catch(e){if(49===t)throw e;await new Promise((e=>setTimeout(e,1e3)))}}(n);return o.register(xe,At(e)),o.register(Ne,function(e){const t=_t(e);return(e,n)=>{const o=t.getRequestsForIdentity(n),r=o.get(e.id);r&&(r.close(),o.delete(e.id))}}(t)),o.register(Ge,function(e){return async(t,n)=>{if(!t||!t.providerId||!t.result)return void St(gt);const o=rt(e,t.providerId);if(!o)return void St(pt);const{onResultDispatch:r}=o;return r?(t.result.dispatcherIdentity=n,r(t.result)):void 0}}(t)),o.onDisconnection(function(e){const{namespacedTopic:t}=e,n=_t(t);return async o=>{if(!mt(t))return;const r=n.getRequestsForIdentity(o);for(const{req:e,close:t}of r.values())t(),r.delete(e.id);Pt(t,(async e=>{const{namespacedTopic:t}=e,n=await kt(e);for(const e of nt(t))await Ot(t,e,n);return n})(e))}}(e)),o}async function Ft(e){const t=("string"==typeof e?e:null==e?void 0:e.topic)||"all",n=("string"==typeof e?null:null==e?void 0:e.uuid)||dt(),o=Ve(n,t),r={topic:t,namespace:n,namespacedTopic:o};let a=mt(o);return a||(a=kt(r),Pt(o,a),await a),{getAllProviders:Ct.bind(null,o),register:Ot.bind(null,o),search:Et.bind(null,o),deregister:Wt.bind(null,o),dispatch:Rt.bind(null,o),disconnect:Tt.bind(null,o)}}const Lt=new Map;function Ut(e){const t=jt(e);if(t)return t;throw ht}function jt(e){const t=Lt.get(e);if(t)return t}const $t=new Map;function Bt(e,t){$t.has(e)||$t.set(e,new Set),$t.get(e).add(t)}function Dt(e,t){const n=$t.get(e);n&&n.delete(t)}var Mt,xt;function Gt(e){return[...nt(e)].map((e=>({...e,onUserInput:void 0,onResultDispatch:void 0})))}function Nt(e,t){if(rt(e,t.id))throw new Error("provider with name already exists");et(e,{identity:ut(),...t})}function zt(e,t){tt(e,t)}async function Vt(e,t,n,o){const r=rt(e,t);if(!r)throw pt;const{onResultDispatch:a}=r;if(a)return a(at(n,ut(),o))}!function(e){e.Fetching="fetching",e.Fetched="fetched",e.Complete="complete"}(Mt||(Mt={})),function(e){e.Active="active",e.Default="default"}(xt||(xt={}));let qt=0;function Ht({namespacedTopic:e,topic:t},n){qt+=1;const o=ct(t,qt.toString(),n);let r;return r=async function*(e,t,n){const o=function(e,t){const n=[],o=[],r=[],a=[];for(const i of e){const e=st(i.scoreOrder),s={results:[],provider:{id:i.id,identity:i.identity,title:i.title,scoreOrder:i.scoreOrder,icon:i.icon}};n.push(s),o.push(e);const c=(async()=>{try{const{results:n,context:o}=await i.onUserInput(t,e.res);s.results=it(s.results,n),s.context={...s.context,...o}}catch(e){s.error=e}c.done=!0})();a.push(c),r.push(r.length)}return{providerResponses:n,listenerResponses:o,openListenerResponses:r,initialResponsePromises:a}}(t.targets?t.targets.map((t=>rt(e,t))).filter((e=>!!e)):[...nt(e).filter((e=>!e.hidden))],t),{providerResponses:r,listenerResponses:a}=o;let{openListenerResponses:i,initialResponsePromises:s}=o,c=Mt.Fetching;const u=e=>{c=e,n.setState(c)};let d,l=!1;t.onClose((()=>{l=!0,d&&d()}));do{let e=!1;if(s.length){const t=[];for(const n of s)n.done?e=!0:t.push(n);s=t,s.length||(u(Mt.Fetched),e=!0)}let t,n=!1;const o=()=>{n=!0,t&&t()},p=[];for(const t of i){const n=a[t],i=r[t],s=n.getStatus();(s===Me.Open||c===Mt.Fetching&&s===Me.Initial)&&(p.push(t),n.onChange=o);const u=n.getResultBuffer();u.length&&(n.setResultBuffer([]),i.results=it(i.results,u),e=!0);const d=n.getRevokedBuffer();if(d.length){n.setRevokedBuffer([]);const t=new Set(d);i.results=i.results.filter((({key:e})=>!t.has(e))),e=!0}}if(i=p,e&&(yield r),l)break;n||(i.length||s.length)&&await Promise.race([...s,new Promise((e=>{t=e})),new Promise((e=>{d=e}))])}while(i.length||s.length);return u(Mt.Complete),r}(e,o.req,{setState:e=>{r.state=e}}),r.id=qt.toString(),r.close=o.close,r.state=Mt.Fetching,r}const Yt=new Map;function Kt(e,t){return`${e}:${t}`}function Jt(e,t,n){return Ut(e).dispatch(t,Ne,{id:n})}async function Zt(e,t,{id:n,query:o,context:r,targets:a}){const i=Ut(e),s={id:n,query:o,context:r,targets:a,providerId:t.id},c=await i.dispatch(t.identity,xe,s),u=c.error;if(u)throw new Error(u);return c}const Xt=new Map;function Qt(e,t,n){return`${e}:${t.name}:${t.uuid}:${n}`}const en=new Map;function tn(e,t,n){return`${e}:${t}:${n}`}function nn(e,t){const n=Qt.bind(null,e,t.identity),o=Jt.bind(null,e,t.identity),r=Zt.bind(null,e,t);return async(a,i)=>{const s=n(a.id);if(!Xt.has(s)){const e=()=>{o(a.id),Xt.delete(s)};Xt.set(s,e),a.onClose(e)}const c=tn(e,t.id,a.id),u=()=>{en.delete(c),i.close()};a.onClose(u),en.set(c,(e=>{var t,n;(null===(t=e.results)||void 0===t?void 0:t.length)&&i.respond(e.results),(null===(n=e.revoked)||void 0===n?void 0:n.length)&&i.revoke(...e.revoked),e.status===Me.Open&&i.open(),e.status===Me.Close&&u()}));const d=await r(a);return d.status===Me.Open&&i.open(),d.status!==Me.Close&&d.status!==Me.Initial||u(),d}}function on(e,t){return async n=>{const o=Ut(e),r={providerId:t.id,result:n};return o.dispatch(t.identity,Ge,r)}}const rn=new Map;function an(e,t){return`${e}-${t.name}-${t.uuid}`}const sn=new Map;function cn(e,t){sn.has(e)||sn.set(e,new Set),sn.get(e).add(t)}function un(e,t){const n=sn.get(e);n&&n.delete(t)}async function dn(e){const{namespacedTopic:t}=e,n=qe(e.namespacedTopic),o=await(r=n,fin.InterApplicationBus.Channel.create(r));var r;return o.onConnection(function({namespacedTopic:e}){return async t=>{const n=$t.get(e);if(n)for(const e of n)if(!await e(t))throw wt}}(e)),o.onDisconnection(function(e){return async t=>{!function(e,t){const n=an(e,t),o=rn.get(n);if(o){for(const t of o)tt(e,t);rn.delete(n)}}(e,t);const n=sn.get(e);n&&n.forEach((e=>e(t)))}}(t)),o.register(Ne,function(e){return t=>function(e,t){const n=Kt(e,t),o=Yt.get(n);o&&o.generator.close()}(e,t.id)}(t)),o.register(xe,function(e){return t=>{const n=tn(e,t.providerId,t.id),o=en.get(n);o&&o(t)}}(t)),o.register("2",function(e){return(t,n)=>{if(!t||!t.id)return St(new Error(JSON.stringify(t))),void St(gt);if(rt(e,t.id))throw ft;t.identity=n,function(e,t){const n=an(e,t.identity);rn.has(n)||rn.set(n,[]),rn.get(n).push(t.id),et(e,{...t,onUserInput:nn(e,t),onResultDispatch:on(e,t)})}(e,t)}}(t)),o.register("3",function(e){return t=>{t?function(e,t){const n=rt(e,t);if(!n)return;const o=an(e,n.identity),r=rn.get(o);if(r){const n=r.findIndex((e=>e===t));-1!==n&&(r.splice(n,1),tt(e,t))}}(e,t):St(gt)}}(t)),o.register("4",function(e){return async()=>Gt(e)}(t)),o.register("1",function(e){return async(t,...n)=>{if(!t)return St(gt),{error:gt.message};let o;if(t.id)o=Kt(e.namespacedTopic,t.id);else{const n=Ht(e,t);o=Kt(e.namespacedTopic,n.id),t.id=n.id,Yt.set(o,{generator:n})}const r=Yt.get(o);clearTimeout(r.timeout);const a=await r.generator.next();return r.timeout=function(e){return window.setTimeout((()=>{Yt.delete(e)}),1e4)}(o),{...a,id:t.id,state:r.generator.state}}}(e)),o.register(Ge,function(e){return async(t,n)=>{if(!t||!t.providerId||!t.result)return void St(gt);const o=rt(e,t.providerId);if(!o)throw pt;const{onResultDispatch:r}=o;return r?(t.result.dispatcherIdentity=n,r(t.result)):void 0}}(t)),o}async function ln(e){const t=Ut(e);var n;n=e,Lt.delete(n),await t.destroy(),ot(e)}async function pn(e){const t=("string"==typeof e?e:null==e?void 0:e.topic)||"all",n=dt(),o=Ve(n,t),r={topic:t,namespace:n,namespacedTopic:o};let a=jt(o);a||(a=await dn(r),function(e,t){Lt.set(e,t)}(o,a));const i=Dt.bind(null,o),s=un.bind(null,o),c=Ke.bind(null,o),u=Xe.bind(null,o);return{getAllProviders:Gt.bind(null,o),search:Ht.bind(null,r),register:Nt.bind(null,o),deregister:zt.bind(null,o),onSubscription:Bt.bind(null,o),onDisconnect:cn.bind(null,o),onRegister:Ye.bind(null,o),onDeregister:Ze.bind(null,o),dispatch:Vt.bind(null,r),disconnect:ln.bind(null,o),removeListener:e=>{i(e),s(e),c(e),u(e)}}}const{create:fn}=a,{subscribe:gn}=e,wn={create:fn,subscribe:gn,defaultTopic:"all"},hn=()=>{const e=window;e.search=wn,e.fin&&(e.fin.Search=wn)},yn=e=>{const t=()=>{hn(),window.removeEventListener(e,t)};return t};if("undefined"!=typeof window){hn();const e="load",t=yn(e);window.addEventListener(e,t);const n="DOMContentLoaded",o=yn(n);window.addEventListener(n,o)}var vn,mn,Pn,Sn,bn,_n;async function In({app:e,target:t}){const n=fin.Platform.getCurrentSync();switch(e.manifestType){case vn.Snapshot:return n.applySnapshot(e.manifest);case vn.View:return async function(e,t){const n=fin.Platform.getCurrentSync();if("view"===t.entityType){const n=fin.View.wrapSync(t),o=await n.getParentLayout();return await o.replaceView(t,{manifestUrl:e.manifest,url:void 0,target:void 0}),n.destroy()}return n.createView({name:void 0,url:void 0,manifestUrl:e.manifest,target:void 0})}(e,t);case vn.External:return fin.System.launchExternalProcess({path:e.manifest,uuid:e.appId});default:return fin.Application.startFromManifest(e.manifest)}}!function(e){e.Snapshot="snapshot",e.Manifest="manifest",e.View="view",e.External="external"}(vn||(vn={})),function(e){e.LandingPage="landingPage",e.AppGrid="appGrid"}(mn||(mn={})),function(e){e.Suggestion="suggestion"}(Pn||(Pn={})),function(e){e.Contact="Contact",e.List="List",e.Plain="Plain",e.SimpleText="SimpleText"}(Sn||(Sn={})),function(e){e.MultiSelect="MultiSelect"}(bn||(bn={}));var An=new Uint8Array(16);function On(){if(!_n&&!(_n="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto)))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return _n(An)}const Wn=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,Rn=function(e){return"string"==typeof e&&Wn.test(e)};for(var En=[],Cn=0;Cn<256;++Cn)En.push((Cn+256).toString(16).substr(1));const Tn=function(e,t,n){var o=(e=e||{}).random||(e.rng||On)();if(o[6]=15&o[6]|64,o[8]=63&o[8]|128,t){n=n||0;for(var r=0;r<16;++r)t[n+r]=o[r];return t}return function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=(En[e[t+0]]+En[e[t+1]]+En[e[t+2]]+En[e[t+3]]+"-"+En[e[t+4]]+En[e[t+5]]+"-"+En[e[t+6]]+En[e[t+7]]+"-"+En[e[t+8]]+En[e[t+9]]+"-"+En[e[t+10]]+En[e[t+11]]+En[e[t+12]]+En[e[t+13]]+En[e[t+14]]+En[e[t+15]]).toLowerCase();if(!Rn(n))throw TypeError("Stringified UUID is invalid");return n}(o)};var kn;!function(e){e.RegisterStorefrontProvider="register-storefront-provider",e.DeregisterStorefrontProvider="deregister-storefront-provider",e.GetStorefrontProviders="get-storefront-providers",e.HideStorefront="hide-storefront",e.GetStorefrontProviderApps="get-storefront-provider-apps",e.GetStorefrontProviderLandingPage="get-storefront-provider-landing-page",e.GetStorefrontProviderFooter="get-storefront-provider-footer",e.GetStorefrontProviderNavigation="get-storefront-provider-navigation",e.LaunchStorefrontProviderApp="launch-storefront-provider-app",e.ShowStorefront="show-storefront",e.CreateStorefrontWindow="create-storefront-window",e.ShowHome="show-home",e.HideHome="hide-home",e.AssignHomeSearchContext="assign-home-search-context",e.GetLegacyPages="get-legacy-pages",e.GetLegacyWorkspaces="get-legacy-workspaces",e.GetComputedPlatformTheme="get-computed-platform-theme"}(kn||(kn={})),J("__of_workspace_protocol__");var Fn,Ln,Un=n(282),jn=n.n(Un);!function(e){e.HomeIndex="/home/",e.HomeSearch="/home/search/",e.HomePagesRename="/home/pages/rename/",e.Dock="/home/dock/",e.BrowserPagesLanding="/browser/pages/landing/",e.HomeIndicator="/home/indicator/",e.Browser="/browser/",e.BrowserPopupMenu="/browser/popup-menu/",e.Provider="/provider/",e.BrowserPopupMenuSharePage="/browser/popup-menu/share-page/",e.BrowserPopupMenuSavePage="/browser/popup-menu/save-page/",e.BrowserPopupMenuLayouts="/browser/popup-menu/layouts/layouts/",e.BrowserPopupMenuColorLinking="/browser/popup-menu/color-linking/color-linking/",e.BrowserIndicator="/browser/indicator/",e.ResponseModal="/browser/popup-menu/response-modal/",e.Docs="/provider/docs/",e.Storefront="/storefront/",e.DeprecatedAlert="/provider/deprecated-alert/"}(Fn||(Fn={})),function(e){e.IconOpenFinLogo="/icons/openfinlogo.svg",e.IconFilter="/icons/filter.svg"}(Ln||(Ln={}));const $n=w+{...Ln,...Fn}.Browser,Bn=(e,t)=>{if(Array.isArray(t))return t};function Dn(e,t){const n=jn()({},t,e,Bn);return n.detachOnClose=!0,n}async function Mn(e,t,n){const o=e.manifestUrl?await t({manifestUrl:e.manifestUrl},n):void 0;if((null==o?void 0:o.interop)&&e.interop){const t={...e,...o,interop:e.interop};return delete t.manifestUrl,t}return e}const xn=e=>{var t,n;const o=e.name===C.Home,r=null===(t=e.name)||void 0===t?void 0:t.startsWith(C.HomeInternal),a=null===(n=e.name)||void 0===n?void 0:n.startsWith(C.BrowserMenu);return!o&&!r&&!a},Gn=e=>"workspacePlatform"in e?e:(({workstacks:e,pages:t,...n})=>({...n,workspacePlatform:{pages:t||e||null}}))(e),Nn={contextMenuSettings:{reload:!1},backgroundThrottling:!0,url:$n,contextMenu:!0,cornerRounding:{height:8,width:8},closeOnLastViewRemoved:!1,experimental:{showFavicons:!0,defaultFaviconUrl:`${w}/icons/defaultFavicon.svg`},permissions:{System:{openUrlWithBrowser:{enabled:!0,protocols:["mailto"]}}}},zn={dimensions:{borderWidth:3,headerHeight:30}},Vn=e=>{const t=fin.Window.wrapSync(e);return Promise.all([t.bringToFront(),t.restore(),t.focus()])};const qn=e=>async t=>{class n extends t{constructor(){super(...arguments),this.isWorkspacePlatform=()=>!0,this.getSavedPage=Ue,this.getSavedPages=je,this.createSavedPage=$e,this.deleteSavedPage=Be,this.updateSavedPage=De,this.attachPagesToWindow=le,this.addPage=le,this.detachPagesFromWindow=fe,this.getAllAttachedPages=oe,this.getPagesForWindow=we,this.getPageForWindow=he,this.setActivePage=ge,this.launchApp=In,this.savePage=de,this.createSavedPageInternal=se,this.updateSavedPageInternal=ue,this.deleteSavedPageInternal=ce,this.reorderPagesForWindow=ye,this.getUniquePageTitle=Pe,this.updatePageForWindow=pe,this.getLastFocusedBrowserWindow=z,this.getThemes=I}async getSnapshot(){const e=await async function(e){const t=await $();return await Promise.all(t.map((({identity:e})=>(async e=>(await ee(e)).dispatch(Z.UpdatePagesWindowOptions))(e)))),e?e():Ce()}((async()=>Ce(await super.getSnapshot(void 0,fin.me.identity))));return{...e,windows:e.windows.filter(xn)}}async applySnapshot({snapshot:e,options:t}){(null==t?void 0:t.closeExistingWindows)&&await async function(){const e=await $();await Promise.all(e.map((e=>e.close(!0).catch((()=>{})))))}();let n=e;return"string"==typeof n&&(n=await super.fetchManifest({manifestUrl:n},fin.me.identity)),async function(e,t){var n;const o=await oe(),r=(null===(n=e.snapshotDetails)||void 0===n?void 0:n.monitorInfo)||await fin.System.getMonitorInfo(),a=(e.windows||[]).filter((({layout:e})=>!!e)),i=new Map;o.forEach((e=>i.set(e.pageId,e)));const s=[],c=a.map((async e=>{var t;const n=Gn(e),o=[],r=(e=>{let t=!1;const n=(e||[]).map((e=>{const n={pageId:(o=e).pageId||o.id,title:o.title||o.name,isReadOnly:o.isReadOnly,layout:o.layout,isActive:o.isActive};var o;return t&&n.isActive&&(n.isActive=!1),n.isActive&&(t=!0),n}));return!t&&n.length&&(n[0].isActive=!0),n})(null===(t=null==n?void 0:n.workspacePlatform)||void 0===t?void 0:t.pages);if(!(null==r?void 0:r.length)){const e=await Pe();o.push(await(async(e,t)=>{const n=await(async e=>({...e,layoutDetails:{machineId:await Ee(),machineName:Oe()}}))(t);return{pageId:Tn(),title:e,layout:n,isReadOnly:!1,hasUnsavedChanges:!0}})(e,n.layout))}let a;r.forEach((e=>{const t=i.get(e.pageId);t?a=t:o.push(e)})),a&&await Promise.all([ge({identity:a.parentIdentity,pageId:a.pageId}),Vn(a.parentIdentity)]),o.length&&s.push({...n,workspacePlatform:{...n.workspacePlatform,pages:o}})}));if(await Promise.all(c),!s.length)return;const u=fin.Platform.getCurrentSync();return(t||u.applySnapshot.bind(u))({...e,snapshotDetails:{...e.snapshotDetails,monitorInfo:r},windows:s})}(n,(e=>super.applySnapshot({snapshot:e,options:{...t,closeExistingWindows:!1}})))}async createWindow(t,n){let o=Gn(t);const r=await this.getThemes();return o=((e,t,n)=>{var o;let r=e;const a=null===(o=null==r?void 0:r.workspacePlatform)||void 0===o?void 0:o.pages;if(a){const e=a.find((e=>e.isActive));e?r.layout=e.layout:(a[0].isActive=!0,r.layout=a[0].layout)}if(r.layout){if(r=jn()({},t,r,Nn,Bn),r.layout=jn()(r.layout,zn,Bn),(r.icon||r.taskbarIcon)&&(r.taskbarIconGroup=r.taskbarIconGroup||fin.me.identity.uuid),!r.backgroundColor){const e=null==n?void 0:n.palette;r.backgroundColor=(null==e?void 0:e.background2)||(null==e?void 0:e.backgroundPrimary)}const e=r.workspacePlatform.newTabUrl;e&&(r.layout.settings||(r.layout.settings={}),r.layout.settings.newTabButton={url:e}),r=function(e){const t=e;return t.workspacePlatform._internalAutoShow=t.workspacePlatform._internalAutoShow||void 0===t.autoShow||t.autoShow,t.autoShow=!1,t}(r)}return r})(o,e.defaultWindowOptions,r[0]),o=await(async e=>{const t=await fin.System.getMonitorInfo(),n=t.primaryMonitor.availableRect.bottom-t.primaryMonitor.availableRect.top,o=t.primaryMonitor.availableRect.right-t.primaryMonitor.availableRect.left;return e.defaultHeight=e.defaultHeight||"800",e.defaultWidth=e.defaultWidth||"800",n<e.defaultHeight&&(e.defaultHeight=n),o<e.defaultWidth&&(e.defaultWidth=o),e})(o),super.createWindow(o,n)}async createView(t,n){return t.opts=Dn(t.opts,e.defaultViewOptions),t.opts=await Mn(t.opts,this.fetchManifest,n),super.createView(t,n)}async replaceView(t,n){return t.opts.newView=await Dn(t.opts.newView,e.defaultViewOptions),t.opts.newView=await Mn(t.opts.newView,this.fetchManifest,n),super.replaceView(t,n)}async replaceLayout(e,t){var n;return null===(n=e.opts.layout)||void 0===n||delete n.dimensions,super.replaceLayout(e,t)}async closeView(e,t){const n=fin.View.wrapSync(e.view);await super.closeView(e,t),await n.destroy().catch((e=>e))}}return"function"==typeof(null==e?void 0:e.overrideCallback)?e.overrideCallback(n):new n};async function Hn(){(function(){const e=E(R);e.addListener(O.WindowOptionsChanged,Ie),e.addListener(O.WindowClosed,Ae),e.addListener(O.WindowCreated,Ae)})(),async function(){const e=fin.Application.getCurrentSync();await e.addListener("window-focused",V)}(),f!==r.Local&&U().addListener(T.ShowRequested,(()=>async function(e){const t=F(e);await t.blur(),await t.hide()}(L)))}let Yn;const Kn=async e=>{const t="23.96.67.7".split(".").map((e=>parseInt(e))),n=await(async e=>new Promise((async t=>{const n=(await fin.System.getVersion()).split(".").map((e=>parseInt(e)));t(e.every(((t,o)=>!(o<3)||n[o]===e[o])))})))(t),o=null==e?void 0:e.theme;var r;if(o&&((r=o).forEach((e=>{const t=e.palette.backgroundPrimary;if(!t.includes("#")&&!t.includes("rgb")&&!t.includes("hsl"))throw new Error("Background primary color is not the right format.")})),_=r),n)return function(e){if(!i)throw new Error("Cannot be used outside an OpenFin env.");return Yn||(fin.Platform.getCurrentSync().once("platform-api-ready",(()=>Hn())),Yn=fin.Platform.init({overrideCallback:qn(e),interopOverride:null==e?void 0:e.interopOverride})),Yn}(null==e?void 0:e.browser);throw new Error(`Runtime version is not supported. ${t[0]}.${t[1]}.${t[2]}.* is required`)},Jn=e=>(e=>{const t=fin.Platform.wrapSync(e);return Object.assign(t,{applySnapshot:async t=>{if("string"!=typeof t&&!(null==t?void 0:t.windows))throw new Error("Not a valid browser snapshot");return fin.Platform.wrapSync(e).applySnapshot(t)},getSnapshot:()=>fin.Platform.wrapSync(e).getSnapshot().then((e=>e)),launchApp:async t=>(t.target||(t.target={uuid:d,name:l,entityType:p||"unknown"}),(await v(e)).dispatch(h.LaunchApp,t)),Theme:b(e),Browser:P(e),Storage:S(e)})})(e),Zn=()=>Jn(fin.me.identity)})(),module.exports=o})();
|
|
2
|
+
//# sourceMappingURL=index.js.map
|