@openfin/core 30.73.21 → 30.73.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/package.json +1 -1
- package/src/OpenFin.d.ts +14 -0
- package/src/api/application/Factory.d.ts +1 -1
- package/src/api/application/Instance.d.ts +1 -1
- package/src/api/base.d.ts +4 -3
- package/src/api/clipboard/index.d.ts +1 -1
- package/src/api/events/application.d.ts +1 -1
- package/src/api/events/globalHotkey.d.ts +3 -2
- package/src/api/events/system.d.ts +1 -1
- package/src/api/events/view.d.ts +1 -1
- package/src/api/events/webcontents.d.ts +1 -1
- package/src/api/events/window.d.ts +1 -1
- package/src/api/external-application/Factory.d.ts +1 -1
- package/src/api/external-application/Instance.d.ts +1 -1
- package/src/api/fin.d.ts +3 -2
- package/src/api/frame/Factory.d.ts +1 -1
- package/src/api/frame/Instance.d.ts +1 -1
- package/src/api/global-hotkey/index.d.ts +1 -1
- package/src/api/interappbus/channel/channel.d.ts +6 -5
- package/src/api/interappbus/channel/client.d.ts +2 -2
- package/src/api/interappbus/channel/connection-manager.d.ts +1 -1
- package/src/api/interappbus/channel/index.d.ts +4 -3
- package/src/api/interappbus/channel/protocols/classic/strategy.d.ts +3 -2
- package/src/api/interappbus/channel/protocols/rtc/endpoint.d.ts +3 -2
- package/src/api/interappbus/channel/protocols/rtc/strategy.d.ts +3 -2
- package/src/api/interappbus/channel/protocols/strategy.d.ts +3 -2
- package/src/api/interappbus/channel/provider.d.ts +3 -3
- package/src/api/interop/Factory.d.ts +1 -1
- package/src/api/interop/InteropBroker.d.ts +3 -2
- package/src/api/interop/InteropClient.d.ts +1 -1
- package/src/api/interop/SessionContextGroupBroker.d.ts +1 -1
- package/src/api/interop/SessionContextGroupClient.d.ts +1 -1
- package/src/api/interop/fdc3/PrivateChannelClient.d.ts +1 -1
- package/src/api/interop/fdc3/PrivateChannelProvider.d.ts +1 -1
- package/src/api/interop/fdc3/fdc3-1.2.d.ts +1 -1
- package/src/api/interop/fdc3/fdc3-2.0.d.ts +2 -2
- package/src/api/interop/fdc3/utils.d.ts +3 -3
- package/src/api/interop/utils.d.ts +1 -1
- package/src/api/me.d.ts +3 -2
- package/src/api/platform/Factory.d.ts +1 -1
- package/src/api/platform/Instance.d.ts +13 -1
- package/src/api/platform/Instance.js +15 -0
- package/src/api/platform/common-utils.d.ts +2 -2
- package/src/api/platform/layout/Factory.d.ts +3 -2
- package/src/api/platform/layout/Instance.d.ts +5 -4
- package/src/api/platform/layout/controllers/tab-drag-controller.d.ts +1 -1
- package/src/api/platform/layout/shapes.d.ts +3 -2
- package/src/api/platform/layout/utils/view-overlay.d.ts +1 -1
- package/src/api/snapshot-source/Factory.d.ts +1 -1
- package/src/api/snapshot-source/Instance.d.ts +1 -1
- package/src/api/snapshot-source/utils.d.ts +1 -1
- package/src/api/system/index.d.ts +1 -1
- package/src/api/view/Factory.d.ts +1 -1
- package/src/api/view/Instance.d.ts +1 -1
- package/src/api/webcontents/main.d.ts +1 -1
- package/src/api/window/Factory.d.ts +1 -1
- package/src/api/window/Instance.d.ts +1 -1
- package/src/browser.d.ts +1 -1
- package/src/environment/browser.d.ts +3 -2
- package/src/environment/environment.d.ts +3 -2
- package/src/environment/node-env.d.ts +3 -2
- package/src/environment/openfin-env.d.ts +3 -2
- package/src/fdc3.d.ts +1 -1
- package/src/mock.d.ts +1 -1
- package/src/mock.js +0 -1
- package/src/shapes/WebOptions.d.ts +1 -1
- package/src/shapes/WindowOptions.d.ts +1 -1
- package/src/shapes/protocol.d.ts +1 -1
- package/src/transport/transport.d.ts +2 -2
package/package.json
CHANGED
package/src/OpenFin.d.ts
CHANGED
|
@@ -429,6 +429,12 @@ export declare type ConstViewOptions = {
|
|
|
429
429
|
enableBeforeUnload: boolean;
|
|
430
430
|
accelerator?: Partial<Accelerator>;
|
|
431
431
|
};
|
|
432
|
+
export declare type ViewState = ViewCreationOptions & {
|
|
433
|
+
backgroundThrottling: boolean;
|
|
434
|
+
componentName: 'view';
|
|
435
|
+
initialUrl: string;
|
|
436
|
+
minWidth?: number;
|
|
437
|
+
};
|
|
432
438
|
export declare type Certificate = {
|
|
433
439
|
data: string;
|
|
434
440
|
fingerprint: string;
|
|
@@ -673,6 +679,14 @@ export declare type PlatformProvider = {
|
|
|
673
679
|
* @return { Promise<Snapshot> } Snapshot of current platform state.
|
|
674
680
|
*/
|
|
675
681
|
getSnapshot(payload: undefined, identity: Identity): Promise<Snapshot>;
|
|
682
|
+
/**
|
|
683
|
+
* Gets the current state of a single view and returns an object with the options needed to restore that view as part of a snapshot.
|
|
684
|
+
* @param { Identity } payload Identity of the view.
|
|
685
|
+
* @return { Promise<ViewState> }
|
|
686
|
+
*/
|
|
687
|
+
getViewSnapshot(payload: {
|
|
688
|
+
viewIdentity: Identity;
|
|
689
|
+
}): Promise<ViewState>;
|
|
676
690
|
/**
|
|
677
691
|
* Called when a snapshot is being applied and some windows in that snapshot would be fully or partially off-screen.
|
|
678
692
|
* Returns an array of windows with modified positions, such that any off-screen windows are positioned in the top left
|
package/src/api/base.d.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
2
|
import { EventEmitter } from 'events';
|
|
3
|
-
import * as OpenFin from '../OpenFin';
|
|
3
|
+
import type * as OpenFin from '../OpenFin';
|
|
4
4
|
import Transport from '../transport/transport';
|
|
5
5
|
import Fin from './fin';
|
|
6
6
|
import { BaseEventMap } from './events/base';
|
|
7
|
-
|
|
8
|
-
|
|
7
|
+
declare type ApplicationIdentity = OpenFin.ApplicationIdentity;
|
|
8
|
+
declare type Identity = OpenFin.Identity;
|
|
9
9
|
export declare class Base {
|
|
10
10
|
wire: Transport;
|
|
11
11
|
constructor(wire: Transport);
|
|
@@ -44,3 +44,4 @@ export declare class Reply<TOPIC extends string, TYPE extends string | void> imp
|
|
|
44
44
|
uuid: string;
|
|
45
45
|
name: string;
|
|
46
46
|
}
|
|
47
|
+
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as OpenFin from '../../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../../OpenFin';
|
|
2
2
|
import { ApplicationEvent, BaseEventMap, WindowEvent } from './base';
|
|
3
3
|
import { PropagatedWindowEvents, WindowAlertRequestedEvent, WindowAuthRequestedEvent, WindowEndLoadEvent, WindowPerformanceReport } from './window';
|
|
4
4
|
import { PropagatedViewEvents } from './view';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import * as OpenFin from '../../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../../OpenFin';
|
|
2
2
|
import { BaseEventMap, RuntimeEvent } from './base';
|
|
3
|
-
|
|
3
|
+
declare type Identity = OpenFin.Identity;
|
|
4
4
|
export interface GlobalHotkeyEvent<Type> extends RuntimeEvent<'global-hotkey', Type> {
|
|
5
5
|
identity: Identity;
|
|
6
6
|
hotkey: string;
|
|
@@ -9,3 +9,4 @@ export interface GlobalHotkeyEvents extends BaseEventMap {
|
|
|
9
9
|
registered: GlobalHotkeyEvent<'registered'>;
|
|
10
10
|
unregistered: GlobalHotkeyEvent<'unregistered'>;
|
|
11
11
|
}
|
|
12
|
+
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as OpenFin from '../../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../../OpenFin';
|
|
2
2
|
import { ApplicationEvent, BaseEvent, BaseEventMap } from './base';
|
|
3
3
|
import { PropagatedWindowEvents } from './window';
|
|
4
4
|
import { PropagatedApplicationEvents } from './application';
|
package/src/api/events/view.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as OpenFin from '../../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../../OpenFin';
|
|
2
2
|
import { CertificateSelectionShownEvent, WebContentsEventMapping, WindowResourceLoadFailedEvent, WindowResourceResponseReceivedEvent } from './webcontents';
|
|
3
3
|
import { BaseEventMap, WindowEvent } from './base';
|
|
4
4
|
import { WindowNavigationRejectedEvent } from './window';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as OpenFin from '../../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../../OpenFin';
|
|
2
2
|
import { CrashedEvent } from './application';
|
|
3
3
|
import { BaseEventMap, WindowEvent } from './base';
|
|
4
4
|
import { CertificateSelectionShownEvent, WebContentsEventMapping, WindowResourceLoadFailedEvent, WindowResourceResponseReceivedEvent } from './webcontents';
|
package/src/api/fin.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
2
|
import { EventEmitter } from 'events';
|
|
3
|
-
import * as OpenFin from '../OpenFin';
|
|
3
|
+
import type * as OpenFin from '../OpenFin';
|
|
4
4
|
import Transport from '../transport/transport';
|
|
5
5
|
import System from './system/index';
|
|
6
6
|
import _WindowModule from './window/index';
|
|
@@ -15,7 +15,7 @@ import PlatformModule from './platform/index';
|
|
|
15
15
|
import { Me } from './me';
|
|
16
16
|
import InteropModule from './interop';
|
|
17
17
|
import SnapshotSourceModule from './snapshot-source';
|
|
18
|
-
|
|
18
|
+
declare type EntityType = OpenFin.EntityType;
|
|
19
19
|
export interface FinApi<MeType extends EntityType> {
|
|
20
20
|
readonly System: System;
|
|
21
21
|
readonly Window: _WindowModule;
|
|
@@ -48,3 +48,4 @@ export default class Fin<MeType extends EntityType = EntityType> extends EventEm
|
|
|
48
48
|
readonly me: Me<MeType>;
|
|
49
49
|
constructor(wire: Transport<MeType>);
|
|
50
50
|
}
|
|
51
|
+
export {};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import * as OpenFin from '../../../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../../../OpenFin';
|
|
2
2
|
import Transport from '../../../transport/transport';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
declare type ProviderIdentity = OpenFin.ProviderIdentity;
|
|
4
|
+
declare type ChannelMiddleware = OpenFin.ChannelMiddleware;
|
|
5
|
+
declare type ErrorMiddleware = OpenFin.ErrorMiddleware;
|
|
6
|
+
declare type ChannelAction = OpenFin.ChannelAction;
|
|
7
7
|
export declare class ProtectedItems {
|
|
8
8
|
providerIdentity: ProviderIdentity;
|
|
9
9
|
wire: Transport;
|
|
@@ -25,3 +25,4 @@ export declare class ChannelBase {
|
|
|
25
25
|
setDefaultAction(func: ChannelMiddleware): void;
|
|
26
26
|
register(topic: string, listener: ChannelAction): boolean;
|
|
27
27
|
}
|
|
28
|
+
export {};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import * as OpenFin from '../../../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../../../OpenFin';
|
|
2
2
|
import { ChannelBase } from './channel';
|
|
3
3
|
import Transport from '../../../transport/transport';
|
|
4
4
|
import { AnyStrategy } from './protocols/strategy-types';
|
|
5
|
-
|
|
5
|
+
declare type ProviderIdentity = OpenFin.ProviderIdentity;
|
|
6
6
|
declare type DisconnectionListener = (providerIdentity: ProviderIdentity) => any;
|
|
7
7
|
interface RoutingInfo extends ProviderIdentity {
|
|
8
8
|
endpointId: string;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import * as OpenFin from '../../../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../../../OpenFin';
|
|
2
2
|
import ChannelClient from './client';
|
|
3
3
|
import { ChannelProvider } from './provider';
|
|
4
4
|
import { EmitterBase } from '../../base';
|
|
5
5
|
import Transport, { Message } from '../../../transport/transport';
|
|
6
6
|
import { ChannelEvents } from '../../events/channel';
|
|
7
|
-
|
|
8
|
-
|
|
7
|
+
declare type ProviderIdentity = OpenFin.ProviderIdentity;
|
|
8
|
+
declare type Identity = OpenFin.Identity;
|
|
9
9
|
export interface ChannelMessage extends Message<any> {
|
|
10
10
|
senderIdentity: Identity;
|
|
11
11
|
ackToSender: any;
|
|
@@ -21,3 +21,4 @@ export declare class Channel extends EmitterBase<ChannelEvents> {
|
|
|
21
21
|
connect(channelName: string, options?: OpenFin.ChannelConnectOptions): Promise<ChannelClient>;
|
|
22
22
|
create(channelName: string, options?: OpenFin.ChannelCreateOptions): Promise<ChannelProvider>;
|
|
23
23
|
}
|
|
24
|
+
export {};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import * as OpenFin from '../../../../../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../../../../../OpenFin';
|
|
2
2
|
import Transport from '../../../../../transport/transport';
|
|
3
3
|
import { MessageReceiver } from './message-receiver';
|
|
4
4
|
import { ChannelStrategy, EndpointPayload } from '../strategy';
|
|
5
5
|
import { LocalSupportedProtocol } from '..';
|
|
6
|
-
|
|
6
|
+
declare type ProviderIdentity = OpenFin.ProviderIdentity;
|
|
7
7
|
export declare class ClassicStrategy implements ChannelStrategy<EndpointPayload> {
|
|
8
8
|
#private;
|
|
9
9
|
private messageReceiver;
|
|
@@ -21,3 +21,4 @@ export declare class ClassicStrategy implements ChannelStrategy<EndpointPayload>
|
|
|
21
21
|
isValidEndpointPayload(payload: any): payload is EndpointPayload;
|
|
22
22
|
}
|
|
23
23
|
export declare const ClassicInfo: LocalSupportedProtocol;
|
|
24
|
+
export {};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import * as OpenFin from '../../../../../OpenFin';
|
|
2
|
-
|
|
1
|
+
import type * as OpenFin from '../../../../../OpenFin';
|
|
2
|
+
declare type ProviderIdentity = OpenFin.ProviderIdentity;
|
|
3
3
|
export interface RTCEndpointChannels {
|
|
4
4
|
request: RTCDataChannel;
|
|
5
5
|
response: RTCDataChannel;
|
|
@@ -22,3 +22,4 @@ export declare class RTCEndpoint {
|
|
|
22
22
|
close: () => void;
|
|
23
23
|
get connected(): boolean;
|
|
24
24
|
}
|
|
25
|
+
export {};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import * as OpenFin from '../../../../../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../../../../../OpenFin';
|
|
2
2
|
import { ChannelStrategy } from '../strategy';
|
|
3
3
|
import { RTCPacket } from './endpoint';
|
|
4
4
|
import { LocalSupportedProtocol } from '..';
|
|
5
|
-
|
|
5
|
+
declare type ProviderIdentity = OpenFin.ProviderIdentity;
|
|
6
6
|
export interface RTCStrategyEndpointPayload {
|
|
7
7
|
endpointIdentity: OpenFin.ClientIdentity | ProviderIdentity;
|
|
8
8
|
rtc: RTCPacket;
|
|
@@ -21,3 +21,4 @@ export declare class RTCStrategy implements ChannelStrategy<RTCStrategyEndpointP
|
|
|
21
21
|
isValidEndpointPayload(payload: any): payload is RTCStrategyEndpointPayload;
|
|
22
22
|
}
|
|
23
23
|
export declare const RTCInfo: LocalSupportedProtocol;
|
|
24
|
+
export {};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import * as OpenFin from '../../../../OpenFin';
|
|
2
|
-
|
|
1
|
+
import type * as OpenFin from '../../../../OpenFin';
|
|
2
|
+
declare type ProviderIdentity = OpenFin.ProviderIdentity;
|
|
3
3
|
export interface ChannelStrategy<T extends unknown> {
|
|
4
4
|
onEndpointDisconnect(endpointId: string, listener: () => void): void;
|
|
5
5
|
receive(listener: (action: string, payload: any, identity: any) => Promise<any>): void;
|
|
@@ -14,3 +14,4 @@ export declare type EndpointIdentity = OpenFin.ClientIdentity | ProviderIdentity
|
|
|
14
14
|
export declare type EndpointPayload = {
|
|
15
15
|
endpointIdentity: EndpointIdentity;
|
|
16
16
|
};
|
|
17
|
+
export {};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import * as OpenFin from '../../../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../../../OpenFin';
|
|
2
2
|
import { ChannelBase } from './channel';
|
|
3
3
|
import Transport from '../../../transport/transport';
|
|
4
4
|
import { AnyStrategy } from './protocols/strategy-types';
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
declare type ProviderIdentity = OpenFin.ProviderIdentity;
|
|
6
|
+
declare type ClientIdentity = OpenFin.ClientIdentity;
|
|
7
7
|
export declare type ConnectionListener = (identity: ClientIdentity, connectionMessage?: any) => Promise<any> | any;
|
|
8
8
|
export declare type DisconnectionListener = (identity: ClientIdentity) => any;
|
|
9
9
|
declare type ClientConnectionPayload = OpenFin.ClientIdentity & OpenFin.ClientInfo;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { TargetApp } from './fdc3/shapes/fdc3v1';
|
|
2
2
|
import { AppIdentifier } from './fdc3/shapes/fdc3v2';
|
|
3
|
-
import * as OpenFin from '../../OpenFin';
|
|
3
|
+
import type * as OpenFin from '../../OpenFin';
|
|
4
4
|
import { Base } from '../base';
|
|
5
5
|
import type Transport from '../../transport/transport';
|
|
6
|
-
|
|
6
|
+
declare type Identity = OpenFin.Identity;
|
|
7
7
|
/**
|
|
8
8
|
* {@link https://developers.openfin.co/of-docs/docs/enable-color-linking **THE INTEROP API IS EXPERIMENTAL. IF YOU WOULD LIKE TO USE IT, PLEASE USE OUR DEFAULT IMPLEMENTATION IN BROWSER**}
|
|
9
9
|
*
|
|
@@ -466,3 +466,4 @@ export declare class InteropBroker extends Base {
|
|
|
466
466
|
*/
|
|
467
467
|
isActionAuthorized(_action: string, _payload: any, _identity: OpenFin.ClientIdentity): Promise<boolean> | boolean;
|
|
468
468
|
}
|
|
469
|
+
export {};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import * as FDC3v1 from './shapes/fdc3v1';
|
|
2
|
-
import * as FDC3v2 from './shapes/fdc3v2';
|
|
1
|
+
import type * as FDC3v1 from './shapes/fdc3v1';
|
|
2
|
+
import type * as FDC3v2 from './shapes/fdc3v2';
|
|
3
3
|
import { Base } from '../../base';
|
|
4
4
|
import Transport from '../../../transport/transport';
|
|
5
5
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { TargetApp } from './shapes/fdc3v1';
|
|
2
|
-
import { AppIdentifier, IntentResolution, Channel, PrivateChannel, Context } from './shapes/fdc3v2';
|
|
3
|
-
import * as OpenFin from '../../../OpenFin';
|
|
1
|
+
import type { TargetApp } from './shapes/fdc3v1';
|
|
2
|
+
import type { AppIdentifier, IntentResolution, Channel, PrivateChannel, Context } from './shapes/fdc3v2';
|
|
3
|
+
import type * as OpenFin from '../../../OpenFin';
|
|
4
4
|
import { PrivateChannelClient } from './PrivateChannelClient';
|
|
5
5
|
interface UnsupportedChannelApis {
|
|
6
6
|
addContextListener(): Error;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as OpenFin from '../../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../../OpenFin';
|
|
2
2
|
export declare const generateId: () => string;
|
|
3
3
|
export declare const wrapInTryCatch: <T>(f: (...args: any[]) => T, prefix?: string) => (...args: any[]) => T;
|
|
4
4
|
export declare const wrapContextHandler: (handler: OpenFin.ContextHandler, handlerId: string) => (context: OpenFin.Context) => Promise<void>;
|
package/src/api/me.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import * as OpenFin from '../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../OpenFin';
|
|
2
2
|
import type Transport from '../transport/transport';
|
|
3
3
|
import type { InteropClient } from './interop';
|
|
4
4
|
export declare const environmentUnsupportedMessage = "You are not running in OpenFin.";
|
|
5
|
-
|
|
5
|
+
declare type EntityType = OpenFin.EntityType;
|
|
6
6
|
export declare type EntityTypeHelpers<T extends EntityType> = T extends 'view' ? {
|
|
7
7
|
isView: true;
|
|
8
8
|
isWindow: false;
|
|
@@ -37,3 +37,4 @@ export declare type Me<MeType extends EntityType> = OpenFin.EntityInfo & (MeType
|
|
|
37
37
|
isOpenFin: boolean;
|
|
38
38
|
};
|
|
39
39
|
export declare function getMe<MeType extends EntityType>(wire: Transport<MeType>): Me<MeType>;
|
|
40
|
+
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as OpenFin from '../../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../../OpenFin';
|
|
2
2
|
import { View } from '../view';
|
|
3
3
|
import { EmitterBase } from '../base';
|
|
4
4
|
import { Channel } from '../interappbus/channel/index';
|
|
@@ -65,6 +65,18 @@ export declare class Platform extends EmitterBase<PlatformEvents> {
|
|
|
65
65
|
* @tutorial Platform.getSnapshot
|
|
66
66
|
*/
|
|
67
67
|
getSnapshot(): Promise<OpenFin.Snapshot>;
|
|
68
|
+
/**
|
|
69
|
+
* Returns a snapshot of a single view's options in its current state.
|
|
70
|
+
*
|
|
71
|
+
* Can be used to restore a view to a previous state.
|
|
72
|
+
*
|
|
73
|
+
* NOTE: this method is meant for advanced usage only, it is not recommended to manage the state of individual views.
|
|
74
|
+
*
|
|
75
|
+
* @param { Identity } viewIdentity View identity
|
|
76
|
+
* @returns { Promise<ViewState> }
|
|
77
|
+
* @tutorial Platform.getViewSnapshot
|
|
78
|
+
*/
|
|
79
|
+
getViewSnapshot(viewIdentity: OpenFin.Identity): Promise<OpenFin.ViewState>;
|
|
68
80
|
/**
|
|
69
81
|
* Adds a snapshot to a running Platform.
|
|
70
82
|
* Requested snapshot must be a valid Snapshot object, or a url or filepath to such an object.
|
|
@@ -173,6 +173,21 @@ class Platform extends base_1.EmitterBase {
|
|
|
173
173
|
const client = await this.getClient();
|
|
174
174
|
return client.dispatch('get-snapshot');
|
|
175
175
|
}
|
|
176
|
+
/**
|
|
177
|
+
* Returns a snapshot of a single view's options in its current state.
|
|
178
|
+
*
|
|
179
|
+
* Can be used to restore a view to a previous state.
|
|
180
|
+
*
|
|
181
|
+
* NOTE: this method is meant for advanced usage only, it is not recommended to manage the state of individual views.
|
|
182
|
+
*
|
|
183
|
+
* @param { Identity } viewIdentity View identity
|
|
184
|
+
* @returns { Promise<ViewState> }
|
|
185
|
+
* @tutorial Platform.getViewSnapshot
|
|
186
|
+
*/
|
|
187
|
+
async getViewSnapshot(viewIdentity) {
|
|
188
|
+
const client = await this.getClient();
|
|
189
|
+
return client.dispatch('get-view-snapshot', { viewIdentity });
|
|
190
|
+
}
|
|
176
191
|
/**
|
|
177
192
|
* Adds a snapshot to a running Platform.
|
|
178
193
|
* Requested snapshot must be a valid Snapshot object, or a url or filepath to such an object.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import * as OpenFin from '../../OpenFin';
|
|
2
|
-
|
|
1
|
+
import type * as OpenFin from '../../OpenFin';
|
|
2
|
+
declare type LayoutPresetType = OpenFin.LayoutPresetType;
|
|
3
3
|
export declare function isValidPresetType(type: LayoutPresetType): type is LayoutPresetType;
|
|
4
4
|
declare const _default: {
|
|
5
5
|
isValidPresetType: typeof isValidPresetType;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import * as OpenFin from '../../../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../../../OpenFin';
|
|
2
2
|
import { Layout } from './Instance';
|
|
3
3
|
import { Base } from '../../base';
|
|
4
|
-
|
|
4
|
+
declare type InitLayoutOptions = OpenFin.InitLayoutOptions;
|
|
5
5
|
/**
|
|
6
6
|
* InitLayoutOptions interface
|
|
7
7
|
* @typedef { object } InitLayoutOptions
|
|
@@ -107,3 +107,4 @@ export declare class LayoutModule extends Base {
|
|
|
107
107
|
*/
|
|
108
108
|
init: (options?: InitLayoutOptions) => Promise<OpenFin.Layout>;
|
|
109
109
|
}
|
|
110
|
+
export {};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import * as OpenFin from '../../../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../../../OpenFin';
|
|
2
2
|
import Transport from '../../../transport/transport';
|
|
3
3
|
import { Base } from '../../base';
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
4
|
+
declare type Identity = OpenFin.Identity;
|
|
5
|
+
declare type InitLayoutOptions = OpenFin.InitLayoutOptions;
|
|
6
|
+
declare type PresetLayoutOptions = OpenFin.PresetLayoutOptions;
|
|
7
7
|
/**
|
|
8
8
|
* @lends Platform#Layout
|
|
9
9
|
*/
|
|
@@ -48,3 +48,4 @@ export declare class Layout extends Base {
|
|
|
48
48
|
*/
|
|
49
49
|
applyPreset: (options: PresetLayoutOptions) => Promise<void>;
|
|
50
50
|
}
|
|
51
|
+
export {};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import * as OpenFin from '../../../OpenFin';
|
|
2
|
-
|
|
1
|
+
import type * as OpenFin from '../../../OpenFin';
|
|
2
|
+
declare type LayoutPresetType = OpenFin.LayoutPresetType;
|
|
3
3
|
export interface InitLayoutOptions {
|
|
4
4
|
containerId?: string;
|
|
5
5
|
}
|
|
@@ -10,3 +10,4 @@ export interface DragPayload {
|
|
|
10
10
|
'view-config': OpenFin.ViewCreationOptions;
|
|
11
11
|
'view-identity': [string, string, string];
|
|
12
12
|
}
|
|
13
|
+
export {};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import * as OpenFin from '../../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../../OpenFin';
|
|
2
2
|
export declare const getSnapshotSourceChannelName: (id: OpenFin.ApplicationIdentity) => string;
|
package/src/browser.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import * as OpenFin from '../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../OpenFin';
|
|
2
2
|
import { NewConnectConfig } from '../transport/wire';
|
|
3
3
|
import { ChildContentOptions, Environment } from './environment';
|
|
4
|
-
|
|
4
|
+
declare type EntityType = OpenFin.EntityType;
|
|
5
5
|
export declare class BrowserEnvironment implements Environment {
|
|
6
6
|
getManagerConstructor(): Promise<any>;
|
|
7
7
|
getProviderInitializer(): Promise<any>;
|
|
@@ -24,3 +24,4 @@ export declare class BrowserEnvironment implements Environment {
|
|
|
24
24
|
getWsConstructor(): typeof WebSocket;
|
|
25
25
|
whenReady(): Promise<void>;
|
|
26
26
|
}
|
|
27
|
+
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import * as OpenFin from '../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../OpenFin';
|
|
2
2
|
import { NewConnectConfig } from '../transport/wire';
|
|
3
|
-
|
|
3
|
+
declare type EntityType = OpenFin.EntityType;
|
|
4
4
|
export interface Environment {
|
|
5
5
|
getManagerConstructor(): Promise<any>;
|
|
6
6
|
getProviderInitializer(): Promise<any>;
|
|
@@ -28,3 +28,4 @@ export interface ChildContentOptions {
|
|
|
28
28
|
entityType: EntityType;
|
|
29
29
|
}
|
|
30
30
|
export declare const notImplementedEnvErrorMsg = "Not implemented in this environment";
|
|
31
|
+
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import * as OpenFin from '../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../OpenFin';
|
|
2
2
|
import { Environment } from './environment';
|
|
3
3
|
import { NewConnectConfig } from '../transport/wire';
|
|
4
|
-
|
|
4
|
+
declare type EntityType = OpenFin.EntityType;
|
|
5
5
|
export default class NodeEnvironment implements Environment {
|
|
6
6
|
getDefaultChannelOptions(): {
|
|
7
7
|
create: OpenFin.ChannelCreateOptions;
|
|
@@ -25,3 +25,4 @@ export default class NodeEnvironment implements Environment {
|
|
|
25
25
|
getUrl: () => string;
|
|
26
26
|
getWsConstructor(): typeof WebSocket;
|
|
27
27
|
}
|
|
28
|
+
export {};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import * as OpenFin from '../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../OpenFin';
|
|
2
2
|
import { ChildContentOptions, Environment } from './environment';
|
|
3
3
|
import { NewConnectConfig } from '../transport/wire';
|
|
4
4
|
import { BrowserEnvironment } from './browser';
|
|
5
|
-
|
|
5
|
+
declare type EntityType = OpenFin.EntityType;
|
|
6
6
|
export default class OpenFinEnvironment extends BrowserEnvironment implements Environment {
|
|
7
7
|
#private;
|
|
8
8
|
private raiseEventAsync;
|
|
@@ -26,3 +26,4 @@ export default class OpenFinEnvironment extends BrowserEnvironment implements En
|
|
|
26
26
|
raiseEvent: (eventName: string, eventArgs: any) => void;
|
|
27
27
|
whenReady(): Promise<void>;
|
|
28
28
|
}
|
|
29
|
+
export {};
|
package/src/fdc3.d.ts
CHANGED
package/src/mock.d.ts
CHANGED
package/src/mock.js
CHANGED
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.fin = void 0;
|
|
4
4
|
const events_1 = require("events");
|
|
5
|
-
const OpenFin = require("./OpenFin");
|
|
6
5
|
/* eslint-disable import/prefer-default-export */
|
|
7
6
|
/* eslint-disable spaced-comment */
|
|
8
7
|
/* eslint-disable @typescript-eslint/triple-slash-reference */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as OpenFin from '../OpenFin';
|
|
1
|
+
import type * as OpenFin from '../OpenFin';
|
|
2
2
|
import { ERROR_BOX_TYPES } from './ERROR_BOX_TYPES';
|
|
3
3
|
import { WebOptions } from './WebOptions';
|
|
4
4
|
export interface WindowOptions extends Partial<OpenFin.WindowOptions>, Partial<WindowInternalOptions> {
|
package/src/shapes/protocol.d.ts
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
2
|
import { EventEmitter } from 'events';
|
|
3
|
-
import * as OpenFin from '../OpenFin';
|
|
3
|
+
import type * as OpenFin from '../OpenFin';
|
|
4
4
|
import { ExistingConnectConfig, InternalConnectConfig, RemoteConfig, Wire, WireConstructor } from './wire';
|
|
5
5
|
import { Environment } from '../environment/environment';
|
|
6
6
|
import { RuntimeEvent } from '../api/events/base';
|
|
7
7
|
import EventAggregator from '../api/events/eventAggregator';
|
|
8
8
|
import { EntityTypeHelpers } from '../api/me';
|
|
9
9
|
import { ProtocolMap } from '../shapes/protocol';
|
|
10
|
-
|
|
10
|
+
declare type EntityType = OpenFin.EntityType;
|
|
11
11
|
export declare type MessageHandler = (data: any) => boolean;
|
|
12
12
|
declare class Transport<MeType extends EntityType = EntityType> extends EventEmitter {
|
|
13
13
|
#private;
|