New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@types/openfin

Package Overview
Dependencies
Maintainers
1
Versions
86
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/openfin - npm Package Compare versions

Comparing version

to
51.0.0

openfin/_v2/api/system/certifiedAppInfo.d.ts

55

openfin/_v2/api/application/application.d.ts

@@ -7,3 +7,3 @@ import { EmitterBase, Base, Reply } from '../base';

import Transport from '../../transport/transport';
import { Bounds } from '../../shapes';
import { Bounds } from '../../shapes/shapes';
import { ApplicationEvents } from '../events/application';

@@ -135,16 +135,16 @@ import { ApplicationOption } from './applicationOption';

/**
* DEPRECATED method to create a new Application. Use {@link Application.start} instead.
* @param { ApplicationOption } appOptions
* @return {Promise.<Application>}
* @tutorial Application.create
* @ignore
*/
* DEPRECATED method to create a new Application. Use {@link Application.start} instead.
* @param { ApplicationOption } appOptions
* @return {Promise.<Application>}
* @tutorial Application.create
* @ignore
*/
create(appOptions: ApplicationOption): Promise<Application>;
/**
* Creates and starts a new Application.
* @param { ApplicationOption } appOptions
* @return {Promise.<Application>}
* @tutorial Application.start
* @static
*/
* Creates and starts a new Application.
* @param { ApplicationOption } appOptions
* @return {Promise.<Application>}
* @tutorial Application.start
* @static
*/
start(appOptions: ApplicationOption): Promise<Application>;

@@ -327,7 +327,7 @@ /**

/**
* Retrieves current application's views.
* @experimental
* @return {Promise.Array.<View>}
* @tutorial Application.getViews
*/
* Retrieves current application's views.
* @experimental
* @return {Promise.Array.<View>}
* @tutorial Application.getViews
*/
getViews(): Promise<Array<View>>;

@@ -347,8 +347,8 @@ /**

/**
* Manually registers a user with the licensing service. The only data sent by this call is userName and appName.
* @param { string } userName - username to be passed to the RVM.
* @param { string } appName - app name to be passed to the RVM.
* @return {Promise.<void>}
* @tutorial Application.registerUser
*/
* Manually registers a user with the licensing service. The only data sent by this call is userName and appName.
* @param { string } userName - username to be passed to the RVM.
* @param { string } appName - app name to be passed to the RVM.
* @return {Promise.<void>}
* @tutorial Application.registerUser
*/
registerUser(userName: string, appName: string): Promise<void>;

@@ -407,2 +407,9 @@ /**

/**
* Sets the query string in all shortcuts for this app. Requires RVM 5.5+.
* @param { string } queryString The new query string for this app's shortcuts.
* @return {Promise.<void>}
* @tutorial Application.setShortcutQueryParams
*/
setShortcutQueryParams(queryString: string): Promise<void>;
/**
* Sets the zoom level of the application. The original size is 0 and each increment above or below represents zooming 20%

@@ -409,0 +416,0 @@ * larger or smaller to default limits of 300% and 50% of original size, respectively.

import { WindowOption } from '../window/windowOption';
import { ShortcutOverride } from '../../shapes';
import { ShortcutOverride } from '../../shapes/shapes';
import { ViewCreationOptions } from '../view/view';

@@ -4,0 +4,0 @@ export interface ApplicationOption extends LegacyWinOptionsInAppOptions {

@@ -1,5 +0,4 @@

/// <reference types="node" />
import { EventEmitter } from 'events';
import Transport from '../transport/transport';
import { Identity } from '../identity';
import { EventEmitter } from 'events';
import { EmitterAccessor } from './events/emitterMap';

@@ -14,4 +13,5 @@ import { BaseEventMap } from './events/base';

private _topic;
protected topic: string;
readonly me: Identity;
protected get topic(): string;
protected set topic(t: string);
get me(): Identity;
protected isNodeEnvironment: () => boolean;

@@ -30,4 +30,4 @@ protected isOpenFinEnvironment: () => boolean;

listenerCount: (type: string | symbol) => number;
protected registerEventListener: (eventType: string | symbol | Extract<keyof EventTypes, string>, options?: SubOptions) => Promise<EventEmitter>;
protected deregisterEventListener: (eventType: string | symbol | Extract<keyof EventTypes, string>, options?: SubOptions) => Promise<void | EventEmitter>;
protected registerEventListener: (eventType: Extract<keyof EventTypes, string> | string | symbol, options?: SubOptions) => Promise<EventEmitter>;
protected deregisterEventListener: (eventType: Extract<keyof EventTypes, string> | string | symbol, options?: SubOptions) => Promise<void | EventEmitter>;
on: <E extends string | symbol | Extract<keyof EventTypes, string>>(eventType: E, listener: (payload: E extends keyof EventTypes ? EventTypes[E] : any, ...args: any[]) => void, options?: SubOptions) => Promise<this>;

@@ -39,4 +39,5 @@ addListener: <E extends string | symbol | Extract<keyof EventTypes, string>>(eventType: E, listener: (payload: E extends keyof EventTypes ? EventTypes[E] : any, ...args: any[]) => void, options?: SubOptions) => Promise<this>;

removeListener: <E extends string | symbol | Extract<keyof EventTypes, string>>(eventType: E, listener: (payload: E extends keyof EventTypes ? EventTypes[E] : any, ...args: any[]) => void, options?: SubOptions) => Promise<this>;
protected deregisterAllListeners: (eventType: string | symbol | Extract<keyof EventTypes, string>) => Promise<void | EventEmitter>;
removeAllListeners: (eventType?: string | symbol | Extract<keyof EventTypes, string>) => Promise<this>;
protected deregisterAllListeners: (eventType: Extract<keyof EventTypes, string> | string | symbol) => Promise<EventEmitter | void>;
removeAllListeners: (eventType?: Extract<keyof EventTypes, string> | string | symbol) => Promise<this>;
private deleteEmitterIfNothingRegistered;
}

@@ -43,0 +44,0 @@ export declare class Reply<TOPIC extends string, TYPE extends string | void> implements Identity {

@@ -12,3 +12,3 @@ import { Base } from '../base';

* @namespace
*/
*/
export default class Clipboard extends Base {

@@ -20,3 +20,3 @@ /**

* @tutorial Clipboard.writeText
*/
*/
writeText(writeObj: WriteRequestType): Promise<void>;

@@ -28,3 +28,3 @@ /**

* @tutorial Clipboard.readText
*/
*/
readText(type?: string): Promise<string>;

@@ -36,3 +36,3 @@ /**

* @tutorial Clipboard.writeHtml
*/
*/
writeHtml(writeObj: WriteRequestType): Promise<void>;

@@ -44,3 +44,3 @@ /**

* @tutorial Clipboard.readHtml
*/
*/
readHtml(type?: string): Promise<string>;

@@ -52,3 +52,3 @@ /**

* @tutorial Clipboard.writeRtf
*/
*/
writeRtf(writeObj: WriteRequestType): Promise<void>;

@@ -60,3 +60,3 @@ /**

* @tutorial Clipboard.readRtf
*/
*/
readRtf(type?: string): Promise<string>;

@@ -68,3 +68,3 @@ /**

* @tutorial Clipboard.write
*/
*/
write(writeObj: WriteAnyRequestType): Promise<void>;

@@ -76,4 +76,4 @@ /**

* @tutorial Clipboard.getAvailableFormats
*/
*/
getAvailableFormats(type?: string): Promise<Array<string>>;
}
import { WindowEvent, BaseEventMap, ApplicationEvent } from './base';
import { WindowAlertRequestedEvent, WindowAuthRequestedEvent, WindowEndLoadEvent, PropagatedWindowEvents, WindowPerformanceReport } from './window';
import { Bounds } from '../../shapes';
import { Bounds } from '../../shapes/shapes';
import { PropagatedViewEvents } from './view';

@@ -5,0 +5,0 @@ import { ManifestInfo } from '../application/application';

@@ -16,4 +16,4 @@ import { FrameEvent } from './frame';

[name: string]: any;
'newListener': string;
'listenerRemoved': string;
newListener: string;
listenerRemoved: string;
}

@@ -8,4 +8,4 @@ import { BaseEventMap, ApplicationEvent } from './base';

export interface ChannelEvents extends BaseEventMap {
'connected': ChannelEvent<'connected'>;
'disconnected': ChannelEvent<'disconnected'>;
connected: ChannelEvent<'connected'>;
disconnected: ChannelEvent<'disconnected'>;
}

@@ -5,3 +5,3 @@ import { WebContentsEventMapping, WindowResourceLoadFailedEvent, WindowResourceResponseReceivedEvent } from './webcontents';

import { CrashedEvent } from './application';
import { Identity } from '../../main';
import { NamedIdentity } from '../../identity';
export interface ViewEventMapping<Topic = string, Type = string> extends WebContentsEventMapping {

@@ -11,3 +11,2 @@ 'attached': WindowEvent<Topic, Type>;

'destroyed': WindowEvent<Topic, Type>;
'focused': WindowEvent<Topic, Type>;
'hidden': WindowEvent<Topic, Type>;

@@ -18,17 +17,21 @@ 'hotkey': InputEvent & WindowEvent<Topic, Type>;

}
interface PropagatedViewIdentity {
viewIdentity: NamedIdentity;
}
export interface PropagatedViewEventMapping<Topic = string, Type = string> extends BaseEventMap {
'view-crashed': CrashedEvent & WindowEvent<Topic, Type>;
'view-created': CrashedEvent & WindowEvent<Topic, Type>;
'view-destroyed': WindowEvent<Topic, Type>;
'view-did-change-theme-color': WindowEvent<Topic, Type>;
'view-focused': WindowEvent<Topic, Type>;
'view-hidden': WindowEvent<Topic, Type>;
'view-hotkey': InputEvent & WindowEvent<Topic, Type>;
'view-navigation-rejected': WindowNavigationRejectedEvent<Topic, Type>;
'view-page-favicon-updated': WindowEvent<Topic, Type>;
'view-page-title-updated': WindowEvent<Topic, Type>;
'view-resource-load-failed': WindowResourceLoadFailedEvent<Topic, Type>;
'view-resource-response-received': WindowResourceResponseReceivedEvent<Topic, Type>;
'view-shown': WindowEvent<Topic, Type>;
'view-target-changed': TargetChangedEvent<Topic, Type>;
'view-blurred': WindowEvent<Topic, Type> & PropagatedViewIdentity;
'view-crashed': CrashedEvent & WindowEvent<Topic, Type> & PropagatedViewIdentity;
'view-created': CrashedEvent & WindowEvent<Topic, Type> & PropagatedViewIdentity;
'view-destroyed': WindowEvent<Topic, Type> & PropagatedViewIdentity;
'view-did-change-theme-color': WindowEvent<Topic, Type> & PropagatedViewIdentity;
'view-focused': WindowEvent<Topic, Type> & PropagatedViewIdentity;
'view-hidden': WindowEvent<Topic, Type> & PropagatedViewIdentity;
'view-hotkey': InputEvent & WindowEvent<Topic, Type> & PropagatedViewIdentity;
'view-navigation-rejected': WindowNavigationRejectedEvent<Topic, Type> & PropagatedViewIdentity;
'view-page-favicon-updated': WindowEvent<Topic, Type> & PropagatedViewIdentity;
'view-page-title-updated': WindowEvent<Topic, Type> & PropagatedViewIdentity;
'view-resource-load-failed': WindowResourceLoadFailedEvent<Topic, Type> & PropagatedViewIdentity;
'view-resource-response-received': WindowResourceResponseReceivedEvent<Topic, Type> & PropagatedViewIdentity;
'view-shown': WindowEvent<Topic, Type> & PropagatedViewIdentity;
'view-target-changed': TargetChangedEvent<Topic, Type> & PropagatedViewIdentity;
}

@@ -53,4 +56,5 @@ export declare type ViewEvents = {

export interface TargetChangedEvent<Topic, Type> extends WindowEvent<Topic, Type> {
previousTarget: Identity;
target: Identity;
previousTarget: NamedIdentity;
target: NamedIdentity;
}
export {};

@@ -29,5 +29,7 @@ import { BaseEventMap, WindowEvent } from './base';

export interface WebContentsEventMapping<Topic = string, Type = string> extends BaseEventMap {
'blurred': WindowEvent<Topic, Type>;
'certificate-error': CertificateErrorEvent<Topic, Type>;
'crashed': CrashedEvent & WindowEvent<Topic, Type>;
'did-change-theme-color': WindowEvent<Topic, Type>;
'focused': WindowEvent<Topic, Type>;
'found-in-page': WindowEvent<Topic, Type>;

@@ -34,0 +36,0 @@ 'navigation-rejected': WindowNavigationRejectedEvent<Topic, Type>;

@@ -47,12 +47,6 @@ import { CrashedEvent } from './application';

export interface PreloadScriptInfoRunning {
state: 'load-started' | // started loading preload script
'load-failed' | // preload script failed to load
'load-succeeded' | // preload script is loaded and ready to be eval'ed
'failed' | // preload script failed to eval
'succeeded';
state: 'load-started' | 'load-failed' | 'load-succeeded' | 'failed' | 'succeeded';
}
export interface PreloadScriptInfo {
state: 'load-failed' | // preload script failed to load
'failed' | // preload script failed to eval
'succeeded';
state: 'load-failed' | 'failed' | 'succeeded';
}

@@ -65,5 +59,2 @@ export interface WindowPreloadScriptsStateChangeEvent<Topic, Type> extends WindowEvent<Topic, Type> {

}
export interface WindowPreloadScriptsStateChangedEvent<Topic, Type> extends WindowEvent<Topic, Type> {
preloadScripts: (PreloadScriptInfo & any)[];
}
export interface WindowBeginBoundsChangingEvent<Topic, Type> extends WindowEvent<Topic, Type> {

@@ -114,7 +105,3 @@ height: number;

}
export interface WindowPerformanceReport<Topic, Type> extends WindowEvent<Topic, Type> {
timing: typeof window.performance.timing;
timeOrigin: typeof window.performance.timeOrigin;
navigation: typeof window.performance.navigation;
}
export declare type WindowPerformanceReport<Topic, Type> = Performance & WindowEvent<Topic, Type>;
export interface ViewDetached<Topic, Type> extends WindowEvent<Topic, Type> {

@@ -128,3 +115,2 @@ previousTarget: Identity;

'begin-user-bounds-changing': WindowBeginBoundsChangingEvent<Topic, Type>;
'blurred': WindowEvent<Topic, Type>;
'bounds-changed': WindowBoundsChange<Topic, Type>;

@@ -141,3 +127,2 @@ 'bounds-changing': WindowBoundsChange<Topic, Type>;

'external-process-started': WindowExternalProcessStartedEvent<Topic, Type>;
'focused': WindowEvent<Topic, Type>;
'group-changed': WindowGroupChanged<Topic, Type>;

@@ -144,0 +129,0 @@ 'hidden': WindowHiddenEvent<Topic, Type>;

import { _Window } from '../window/window';
import { AnchorType, Bounds } from '../../shapes';
import { AnchorType, Bounds } from '../../shapes/shapes';
import { Base, EmitterBase } from '../base';

@@ -52,3 +52,3 @@ import { ExternalWindowEvents } from '../events/externalWindow';

* @tutorial Window.close
*/
*/
close(): Promise<void>;

@@ -75,3 +75,3 @@ /**

* @tutorial Window.getBounds
*/
*/
getBounds(): Promise<Bounds>;

@@ -78,0 +78,0 @@ /**

/// <reference types="node" />
import { EventEmitter } from 'events';
import Transport from '../transport/transport';
import { EventEmitter } from 'events';
import System from './system/system';
import _WindowModule from './window/window';
import Application from './application/application';
import ApplicationModule from './application/application';
import InterApplicationBus from './interappbus/interappbus';
import _NotificationModule from './notification/notification';
import Clipbpard from './clipboard/clipboard';
import ExternalApplication from './external-application/external-application';
import ExternalWindow from './external-window/external-window';
import ExternalApplicationModule from './external-application/external-application';
import ExternalWindowModule from './external-window/external-window';
import _FrameModule from './frame/frame';

@@ -21,8 +21,8 @@ import GlobalHotkey from './global-hotkey';

Window: _WindowModule;
Application: Application;
Application: ApplicationModule;
InterApplicationBus: InterApplicationBus;
Notification: _NotificationModule;
Clipboard: Clipbpard;
ExternalApplication: ExternalApplication;
ExternalWindow: ExternalWindow;
ExternalApplication: ExternalApplicationModule;
ExternalWindow: ExternalWindowModule;
Frame: _FrameModule;

@@ -29,0 +29,0 @@ GlobalHotkey: GlobalHotkey;

import { Identity } from '../../../identity';
import Transport, { Message } from '../../../transport/transport';
import { ProviderIdentity } from '../../../shapes';
import { ProviderIdentity } from '../../../shapes/Identity';
export declare type Action = (() => any) | ((payload: any) => any) | ((payload: any, id: ProviderIdentity) => any);

@@ -5,0 +5,0 @@ export declare type Middleware = (() => any) | ((action: string) => any) | ((action: string, payload: any) => any) | ((action: string, payload: any, id: ProviderIdentity) => any);

import { ChannelBase } from './channel';
import Transport from '../../../transport/transport';
import { ProviderIdentity } from '../../../shapes';
import { ProviderIdentity } from '../../../shapes/Identity';
declare type DisconnectionListener = (providerIdentity: ProviderIdentity) => any;

@@ -13,3 +13,3 @@ interface RoutingInfo extends ProviderIdentity {

constructor(routingInfo: RoutingInfo, send: Transport['sendAction'], clientMap: Map<string, ChannelClient>);
readonly providerIdentity: ProviderIdentity;
get providerIdentity(): ProviderIdentity;
dispatch(action: string, payload?: any): Promise<any>;

@@ -16,0 +16,0 @@ onDisconnection(listener: DisconnectionListener): void;

@@ -7,3 +7,3 @@ import { ChannelClient } from './client';

import { ChannelEvents } from '../../events/channel';
import { ProviderIdentity } from '../../../shapes';
import { ProviderIdentity } from '../../../shapes/Identity';
export interface ConnectOptions {

@@ -10,0 +10,0 @@ wait?: boolean;

import { ChannelBase } from './channel';
import Transport from '../../../transport/transport';
import { Identity } from '../../../main';
import { ClientIdentity, ProviderIdentity } from '../../../shapes';
import { ClientIdentity, ProviderIdentity } from '../../../shapes/Identity';
export declare type ConnectionListener = (identity: Identity, connectionMessage?: any) => any;

@@ -6,0 +6,0 @@ export declare type DisconnectionListener = (identity: Identity) => any;

/// <reference types="node" />
import { EventEmitter } from 'events';
import { Base } from '../base';
import { Identity } from '../../identity';
import Transport, { Message } from '../../transport/transport';
import { EventEmitter } from 'events';
import { Channel } from './channel/index';

@@ -10,3 +10,3 @@ /**

* @namespace
*/
*/
export default class InterApplicationBus extends Base {

@@ -32,3 +32,3 @@ Channel: Channel;

* @tutorial InterApplicationBus.publish
*/
*/
publish(topic: string, message: any): Promise<void>;

@@ -44,3 +44,3 @@ /**

* @tutorial InterApplicationBus.send
*/
*/
send(destination: Identity, topic: string, message: any): Promise<void>;

@@ -47,0 +47,0 @@ /**

@@ -1,6 +0,6 @@

import { InputEvent } from '../../api/events/view';
import { LayoutManager } from './openfin-layout';
import { InputEvent } from '../events/view';
import LayoutManager from './openfin-layout';
import { ViewComponent } from './utils';
import { ShortcutOverride, Hotkey } from '../../shapes';
import { PlatformOptions } from './platform';
import { ShortcutOverride, Hotkey } from '../../shapes/shapes';
import { PlatformOptions } from '../../shapes/Platform';
export declare const handleViewCommand: (e: InputEvent, bv: ViewComponent, context: LayoutManager) => Promise<void>;

@@ -13,1 +13,2 @@ export declare const handleWindowCommand: (e: InputEvent, context: LayoutManager) => void;

export declare const setUpKeyboardCommands: (hotkeys: Hotkey[], appOptions: PlatformOptions) => Hotkey[];
export declare function detachView(tab: GoldenLayout.Tab, context: LayoutManager): void;

@@ -0,4 +1,4 @@

/// <reference path="./golden-layout.d.ts" />
import { Identity } from '../../identity';
import { LayoutPresetTypes } from './utils';
import "./golden-layout";
export interface InitLayoutOptions {

@@ -15,5 +15,3 @@ containerId?: string;

* @property { string } [containerId] The id attribute of the container where the window's Layout should be initialized. If not provided
* then an element with id `layout-container` is used.
* @property { LayoutConfig } [layout] The layout configuration to be initialized. If not provided then the layout included in window
* options is used.
* then an element with id `layout-container` is used. We recommend using a div element.
*/

@@ -32,2 +30,3 @@ /**

* or our {@link https://openfin.github.io/golden-prototype/config-gen Layout Config Generation Tool }.
* @property { LayoutSettings } settings Configuration for certain Layout behaviors. See the LayoutSettings interface.
*/

@@ -46,2 +45,19 @@ /**

/**
* LayoutSettings Interface
* @typedef { object } LayoutSettings Represents a potential ways to customize behavior of your Layout
* @property { boolean } hasHeaders Turns tab headers on or off.
* If false, the layout will be displayed with splitters only.
* @property { boolean } popoutWholeStack Whether the popout button will only act on the entire stack,
* as opposed to only the active tab.
* @property { boolean } reorderEnabled If true, the user can re-arrange the layout by
* dragging items by their tabs to the desired location.
* @property { boolean } showCloseIcon Whether to show the close button on stack header
* (not to be confused with close button on every tab).
* @property { boolean } showMaximiseIcon Whether to show the maximize button on stack header.
* The button will maximize the current tab to fill the entire window.
* @property { boolean } showPopoutIcon Whether to show the popout button on stack header.
* The button will create a new window with current tab as its content.
* In case `popoutWholeStack` is set to true, all tabs in the stack will be in the new window.
*/
/**
* @lends Platform#Layout

@@ -81,6 +97,6 @@ */

/**
* Initialize the window's Layout. Must be called from a custom window that has a truthy 'layout' option property (set `layout` to
* `true` in order to use this call with your own layout). If a layout is not provided in the options for this call, the `layout`
* property set upon creation of that window is used. If a containerId is not provided, this method attempts to find an element
* with the id `layout-container`.
* Initialize the window's Layout. Must be called from a custom window that has a 'layout' option set upon creation of that window.
* If a containerId is not provided, this method attempts to find an element with the id `layout-container`.
* A Layout will <a href="tutorial-Layout.DOMEvents.html">emit events locally</a> on the DOM element representing the layout-container.
* In order to capture the relevant events during Layout initiation, set up the listeners on the DOM element prior to calling `init`.
* @param { InitLayoutOptions } [options] - Layout init options.

@@ -87,0 +103,0 @@ * @return { Promise<Layout> }

@@ -1,3 +0,1 @@

/// <reference types="resize-observer-browser"/>
import { Fin, Window, ChannelClient, View } from '../../main';

@@ -8,7 +6,8 @@ import { ResizableView, ViewState } from './resizable-view';

import { ViewDetached } from '../events/window';
export declare class LayoutManager {
export default class LayoutManager {
private fin;
client: ChannelClient;
container: HTMLElement;
containerResizeObserver: typeof ResizeObserver;
containerResizeObserver: ResizeObserver;
viewsResizeObserver: ResizeObserver;
dragProxy: any;

@@ -20,2 +19,3 @@ isDragging: boolean;

resizing: boolean;
showBackgroundImages: boolean;
constructor(fin: Fin);

@@ -27,7 +27,7 @@ initManager: () => Promise<void>;

replaceLayout: (layout: GoldenLayout.Config, container: HTMLElement) => Promise<void>;
onViewDetached: (e: ViewDetached<"window", "view-detached">) => Promise<void>;
onViewDetached: (event: ViewDetached<'window', 'view-detached'>) => Promise<void>;
setupLayoutListeners: () => void;
registerViewComponent: () => void;
setupWindowListeners: () => void;
setupContainerResizeObserver: () => void;
setupWindowListeners: () => Promise<void>;
setupResizeObservers: () => void;
onStackCreated: (stack: GoldenLayout.ContentItem) => void;

@@ -37,4 +37,5 @@ onTabCreated: (tab: GoldenLayout.Tab) => void;

onCloseTabButtonClick: (tab: GoldenLayout.Tab) => Promise<void>;
setTabTitle: (tab: GoldenLayout.Tab, title: string) => Promise<void>;
setTabBody: (container: GoldenLayout.Container, message: string) => void;
onPopoutClick: (stack: GoldenLayout.ContentItem) => void;
onStackCloseClick: (stack: GoldenLayout.ContentItem) => void;
onMaximizeToggleClick: () => void;
updateButtonDisplay: () => void;

@@ -50,2 +51,4 @@ onItemCreated: (item: GoldenLayout.ContentItem) => Promise<void>;

onTabDrag: (dragListener: GoldenLayout.EventEmitter, parentTab: GoldenLayout.Tab) => Promise<void>;
setBackgroundImage: (viewComponent: ViewComponent) => Promise<void>;
setBackgroundImages: () => Promise<void>;
addView: (viewConfig: ViewState) => Promise<View>;

@@ -70,6 +73,4 @@ removeView: (viewConfig: any) => Promise<View>;

createAndAttachView: (bv: ViewComponent) => Promise<View>;
handleRenderError(component: ViewComponent, e: Error): void;
setFallbackBodyAndTitle: (viewComponent: ViewComponent) => void;
setupViewEvents: (view: View, viewComponent: ViewComponent) => void;
dispatchLayoutEvent: (action: string, payload?: {}) => Promise<void>;
}

@@ -1,3 +0,66 @@

import { OverrideCallback } from './platform';
import { Environment } from '../../environment/environment';
import { OverrideCallback } from '../../shapes/Platform';
export default function initConstructor(environment: Environment): (userOverrideFn: OverrideCallback<any>) => Promise<void>;
/**
* ApplySnapshotOptions interface
* @typedef { object } ApplySnapshotOptions
* @property { boolean } [closeExistingWindows=false] When true, applySnapshot will close existing windows,
* replacing current Platform state with the given snapshot.
* @property { boolean } [skipOutOfBoundsCheck=false] When true, applySnapshot will not check whether any windows in a
* snapshot are off-screen. By default, such windows will be repositioned to be on-screen,
* as defined by {@link PlatformProvider#positionOutOfBoundsWindows PlatformProvider.positionOutOfBoundsWindows}.
*/
/**
* Payload sent to Platform Provider when {@link Platform#applySnapshot Platform.applySnapshot} is called.
* @typedef { object } ApplySnapshotPayload
* @property { Snapshot } snapshot The snapshot to be applied.
* @property { ApplySnapshotOptions } [options] Options to customize snapshot application.
*/
/**
* CreateViewPayload interface
* @typedef { object } CreateViewPayload
* @property { View~options } opts Options for the view to be added.
* @property { Identity } [target] Window the view will be added to. If no target is provided, a new window will be created.
*/
/**
* CloseViewPayload interface
* @typedef { object } CloseViewPayload
* @property { Identity } target View to be closed.
*/
/**
* ReplaceLayoutOpts interface
* @typedef { object } ReplaceLayoutOpts
* @property { LayoutConfig } layout Layout config to be applied.
*/
/**
* ReplaceLayoutPayload interface
* @typedef { object } ReplaceLayoutPayload
* @property { ReplaceLayoutOpts } opts Object containing the layout to be applied.
* @property { Identity } target Identity of the window whose layout will be replace.
*/
/**
* SetWindowContextPayload interface
* @typedef { object } SetWindowContextPayload
* @property { any } context The requested context update.
* @property { EntityType } entityType Entity type of the target of the context update ('view' or 'window').
* @property { Identity } target Identity of the entity targeted by the call to {@link Platform#setWindowContext Platform.setWindowContext}.
*/
/**
* SetWindowContextPayload interface
* @typedef { object } SetWindowContextPayload
* @property { any } context The requested context update.
* @property { EntityType } entityType Entity type of the target of the context update ('view' or 'window').
* @property { Identity } target Identity of the entity targetted by the call to {@link Platform#setWindowContext Platform.setWindowContext}.
*/
/**
* GetWindowContextPayload interface
* @typedef { object } GetWindowContextPayload
* @property { EntityType } entityType Entity type of the target of the context update ('view' or 'window').
* @property { Identity } target Identity of the entity targeted by the call to {@link Platform#getWindowContext Platform.getWindowContext}.
*/
/**
* HostContextChangedPayload interface
* @typedef { object } HostContextChangedPayload
* @property { any } context The new context object
* @property { string } reason The reason for the update: 'updated' or 'reparented'
*/

@@ -1,2 +0,2 @@

import { View } from './../view/view';
import { View, ViewCreationOptions } from '../view/view';
import { Base, EmitterBase } from '../base';

@@ -6,6 +6,3 @@ import { Channel } from '../interappbus/channel/index';

import { Identity } from '../../identity';
import { ApplicationOption } from '../application/applicationOption';
import { WindowOption } from '../window/windowOption';
import { ViewCreationOptions } from '../view/view';
import { RvmLaunchOptions } from '../application/application';
import { RvmLaunchOptions, Application } from '../application/application';
import Transport from '../../transport/transport';

@@ -15,21 +12,3 @@ import LayoutModule from './layout';

import { _Window } from '../window/window';
export interface Snapshot {
windows: WindowOption[];
}
export interface ApplySnapshotOptions {
closeExistingWindows: boolean;
}
export interface PlatformOptions extends ApplicationOption {
defaultWindowOptions?: DefaultWindowOptions;
defaultViewOptions?: ViewCreationOptions;
disableDefaultCommands?: boolean;
}
interface DefaultWindowOptions extends WindowOption {
stylesheetUrl: string;
}
declare type PlatformProvider = any;
export declare type OverrideCallback<T extends PlatformProvider> = (arg: PlatformProvider) => T;
export interface InitPlatformOptions {
overrideCallback: OverrideCallback<any>;
}
import { PlatformOptions, ApplySnapshotOptions, Snapshot, InitPlatformOptions, PlatformWindowCreationOptions } from '../../shapes/Platform';
/**

@@ -84,9 +63,9 @@ * @lends Platform

/**
* Creates and starts a Platform and returns a wrapped and running Platform instance. The wrapped Platform methods can
* be used to launch content into the platform. Promise will reject if the platform is already running.
* @param { PlatformOptions } platformOptions
* @return {Promise.<Platform>}
* @tutorial Platform.start
* @static
*/
* Creates and starts a Platform and returns a wrapped and running Platform instance. The wrapped Platform methods can
* be used to launch content into the platform. Promise will reject if the platform is already running.
* @param { PlatformOptions } platformOptions
* @return {Promise.<Platform>}
* @tutorial Platform.start
* @static
*/
start(platformOptions: PlatformOptions): Promise<Platform>;

@@ -113,6 +92,6 @@ /**

private _channel;
Application: Application;
identity: Identity;
onWindowContextUpdate: Platform['onWindowContextUpdated'];
constructor(identity: Identity, channel: Channel);
getClient(identity?: Identity): Promise<ChannelClient>;
getClient: (identity?: Identity) => Promise<ChannelClient>;
/**

@@ -132,3 +111,3 @@ * Creates a new view and attaches it to a specified target window.

*/
createWindow(options: WindowOption): Promise<_Window & Identity>;
createWindow(options: PlatformWindowCreationOptions): Promise<_Window & Identity>;
/**

@@ -176,42 +155,35 @@ * Closes current platform, all its windows, and their views.

applySnapshot(requestedSnapshot: Snapshot | string, options?: ApplySnapshotOptions): Promise<Platform>;
launchLegacyManifest: (manifestUrl: string) => Promise<Platform>;
/**
* Retrieves a manifest by url and launches a legacy application manifest or snapshot into the platform. Returns a promise that
* resolves to the wrapped Platform.
* @param {string} [manifestUrl] - The URL of the manifest of the app to launch into the platform. If this app manifest
* @param {string} manifestUrl - The URL of the manifest of the app to launch into the platform. If this app manifest
* contains a snapshot, that will be launched into the platform. If not, the application described in startup_app options
* will be launched into the platform. The applicable startup_app options will become {@link View~options View Options}.
* @return {Promise<Platform>}
* @tutorial Platform.launchLegacyManifest
* @tutorial Platform.launchContentManifest
* @experimental
*/
launchLegacyManifest(manifestUrl?: string): Promise<Platform>;
launchContentManifest(manifestUrl: string): Promise<Platform>;
/**
* Set the context of your current window or view environment. The context will be saved in any platform snapshots.
* Set the context of a host window. The context will be available to the window itself, and to its child Views. It will be saved in any platform snapshots.
* It can be retrieved using {@link Platform#getWindowContext getWindowContext}.
* @param {any} context - A field where serializable context data can be stored to be saved in platform snapshots.
* @param {Identity} [target] - A target window or view may optionally be provided. If no target is provided, the update will be applied
* to the current window (if called from a Window) or the current host window (if called from a View).
* @return {Promise<void>}
* @tutorial Platform.setContext
* @tutorial Platform.setWindowContext
* @experimental
*/
setContext(context?: any): Promise<void>;
setWindowContext(context?: any, target?: Identity): Promise<void>;
/**
* Get the context of your current window or view environment that was previously set using {@link Platform#setContext setContext}.
* Get the context context of a host window that was previously set using {@link Platform#setWindowContext setWindowContext}.
* The context will be saved in any platform snapshots. Returns a promise that resolves to the context.
* @param {Identity} [target] - A target window or view may optionally be provided. If no target is provided, target will be
* the current window (if called from a Window) or the current host window (if called from a View).
* @return {Promise<any>}
* @tutorial Platform.getContext
* @tutorial Platform.getWindowContext
* @experimental
*/
getContext(): Promise<any>;
/**
* Set a listener to be executed when the when a View's target Window experiences a context update. Can only be set from a view that
* has wrapped it's current platform. The listener receives the new context as its first argument and the previously context as the
* second argument. If the listener returns a truthy value, the View's context will be updated with the new context as if
* {@link Platform#setContext setContext} was called. This can only be set once per javascript environment (once per View), and any
* subsequent calls to onWindowContextUpdated will error out. If the listener is successfully set, returns a promise that resolves to
* true.
* @return {Promise.<boolean>}
* @tutorial Platform.onWindowContextUpdated
* @experimental
*/
onWindowContextUpdated(listener: (newContext: any, oldContext?: any) => any): Promise<boolean>;
getWindowContext(target?: Identity): Promise<any>;
}
export {};
/// <reference types="resize-observer-browser" />
import { Fin, View } from "../../main";
import { ViewCreationOptions } from "../view/view";
import { Fin, View } from '../../main';
import { ViewCreationOptions } from '../view/view';
import { ViewComponent } from './utils';
import { Identity } from '../../shapes/Identity';
export interface ViewState extends ViewCreationOptions {

@@ -11,12 +13,8 @@ url: string;

ofView: View;
windowIdentity: Identity;
resizeObserver: ResizeObserver;
container: GoldenLayout.Container;
constructor(fin: Fin, options: ViewState);
renderIntoComponent(opts: {
componentState?: {
url: string;
};
container: any;
}): Promise<void>;
constructor(fin: Fin, { container, componentState }: ViewComponent, viewObserver: ResizeObserver);
renderIntoComponent(): Promise<void>;
createOrAttachView(): Promise<void>;
}
/// <reference types="jquery" />
import { Identity } from '../../identity';
import { ViewState } from './resizable-view';
import { Bounds } from '../../shapes';
import { Bounds } from '../../shapes/shapes';
import { View } from '../../main';
import { MonitorInfo } from '../system/monitor';
import { Snapshot } from '../../shapes/Platform';
export interface ViewComponent extends GoldenLayout.ContentItem {

@@ -18,15 +20,14 @@ componentState: ViewState;

export declare const getPresetLayoutFunction: {
'columns': (components: ViewComponent[]) => GoldenLayout.Config;
'grid': (components: ViewComponent[]) => GoldenLayout.Config;
'rows': (components: ViewComponent[]) => GoldenLayout.Config;
'tabs': (components: ViewComponent[]) => GoldenLayout.Config;
columns: (components: ViewComponent[]) => GoldenLayout.Config;
grid: (components: ViewComponent[]) => GoldenLayout.Config;
rows: (components: ViewComponent[]) => GoldenLayout.Config;
tabs: (components: ViewComponent[]) => GoldenLayout.Config;
};
export declare const generatePresetLayout: (components: ViewComponent[], type: LayoutPresetTypes) => GoldenLayout.Config;
export declare const generatePresetLayoutContent: (components: ViewComponent[], type: LayoutPresetTypes) => GoldenLayout.Config;
export declare function createComponent(componentState: {
name: string;
}): GoldenLayout.ComponentConfig;
// tslint:disable-next-line
export declare const debounce: <T extends (...args: any[]) => any>(callback: T, delay: number, resizing: boolean) => (...args: Parameters<T>) => void;
export declare const delay: (delay: number) => Promise<unknown>;
export declare const generateLayout: (componentState: any) => GoldenLayout.Config;
export declare const generateLayoutContent: (componentState: any) => GoldenLayout.Config;
export declare const getSourceIdentity: (e: JQuery.DragEventBase<HTMLElement, Identity, HTMLElement, HTMLElement>) => {

@@ -36,2 +37,3 @@ uuid: string;

};
export declare function handleRenderError(component: ViewComponent, e: Error): void;
export declare const getOutOfWindowDropBounds: (e: {

@@ -49,3 +51,6 @@ screenY: number;

};
export declare const setViewBoundsByRect: (rect: Bounds | ClientRect | DOMRect, ofView: View) => Promise<void>;
export declare function setContainerMessage(container: GoldenLayout.Container, message: string): void;
export declare function setTabTitle(tab: GoldenLayout.Tab, title: string): void;
export declare function setFallbackBodyAndTitle(viewComponent: ViewComponent): void;
export declare const setViewBoundsByRect: (rect: ClientRect | DOMRect | Bounds, ofView: View) => Promise<View>;
export declare const getComponentBounds: (bv: ViewComponent) => DOMRect;

@@ -58,1 +63,2 @@ export declare const buildFailedEventPayload: (response: string, identity: Identity) => {

export declare const promisifyViewLoadEvents: (view: View, windowIdentity: Identity) => Promise<LayoutEventPayload>;
export declare const getOutOfBoundsWindows: (snapshot: Snapshot, monitorInfo: MonitorInfo) => Promise<import("../../shapes/WindowOptions").WindowOptions[]>;
export interface RVMInfo {
action: string;
appLogDirectory: string;
path: string;
'action': string;
'appLogDirectory': string;
'path': string;
'start-time': string;
version: string;
'version': string;
'working-dir': string;
}

@@ -23,3 +23,5 @@ import { EmitterBase } from '../base';

import { SystemEvents } from '../events/system';
interface ServiceIdentifier {
import { InstalledApps } from './installedApps';
import { CertifiedAppInfo } from './certifiedAppInfo';
export interface ServiceIdentifier {
name: string;

@@ -80,8 +82,8 @@ }

/**
* CrashReporterOption interface
* @typedef { object } CrashReporterOption
* @property { boolean } diagnosticMode In diagnostic mode the crash reporter will send diagnostic logs to
* the OpenFin reporting service on runtime shutdown
* @property { boolean } isRunning check if it's running
*/
* CrashReporterOption interface
* @typedef { object } CrashReporterOption
* @property { boolean } diagnosticMode In diagnostic mode the crash reporter will send diagnostic logs to
* the OpenFin reporting service on runtime shutdown
* @property { boolean } isRunning check if it's running
*/
/**

@@ -190,7 +192,7 @@ * DipRect interface

/**
* ManifestInfo interface
* @typedef { object } ManifestInfo
* @property { string } uuid The uuid of the application
* @property { string } manifestUrl The runtime manifest URL
*/
* ManifestInfo interface
* @typedef { object } ManifestInfo
* @property { string } uuid The uuid of the application
* @property { string } manifestUrl The runtime manifest URL
*/
/**

@@ -332,12 +334,12 @@ * MonitorDetails interface

/**
* ServiceIdentifier interface
* @typedef { object } ServiceIdentifier
* @property { string } name The name of the service
*/
* ServiceIdentifier interface
* @typedef { object } ServiceIdentifier
* @property { string } name The name of the service
*/
/**
* ServiceConfiguration interface
* @typedef { object } ServiceConfiguration
* @property { object } config The service configuration
* @property { string } name The name of the service
*/
* ServiceConfiguration interface
* @typedef { object } ServiceConfiguration
* @property { object } config The service configuration
* @property { string } name The name of the service
*/
/**

@@ -406,2 +408,11 @@ * ShortCutConfig interface

/**
* CertifiedAppInfo interface
* @typedef { object } CertifiedAppInfo
* @property { boolean } isRunning true if the app is running
* @property { boolean } [isOptedIntoCertfiedApp] true if the app has opted into certification
* @property { boolean } [isCertified] true if the app is certified
* @property { boolean } [isSSLCertified] true if the app manifest's SSL certificate is valid
* @property { boolean } [isPresentInAppDirectory] true if the app is present in the OpenFin app directory
*/
/**
* An object representing the core of OpenFin Runtime. Allows the developer

@@ -602,2 +613,8 @@ * to perform system-level actions, such as accessing logs, viewing processes,

/**
* Returns information about the given app's certification status
* @return {Promise.<CertifiedAppInfo>}
* @tutorial System.isAppCertified
*/
isAppCertified(manifestUrl: string): Promise<CertifiedAppInfo>;
/**
* Returns an array of all the installed runtime versions in an object.

@@ -608,2 +625,3 @@ * @return {Promise.<string[]>}

getInstalledRuntimes(): Promise<string[]>;
getInstalledApps(): Promise<InstalledApps>;
/**

@@ -754,15 +772,15 @@ * Retrieves the contents of the log with the specified filename.

/**
* Downloads a version of the runtime.
* @param { RuntimeDownloadOptions } options - Download options.
* @param {Function} [progressListener] - called as the runtime is downloaded with progress information.
* @return {Promise.<void>}
* @tutorial System.downloadRuntime
*/
* Downloads a version of the runtime.
* @param { RuntimeDownloadOptions } options - Download options.
* @param {Function} [progressListener] - called as the runtime is downloaded with progress information.
* @return {Promise.<void>}
* @tutorial System.downloadRuntime
*/
downloadRuntime(options: RuntimeDownloadOptions, progressListener: (progress: RuntimeDownloadProgress) => void): Promise<void>;
/**
* Download preload scripts from given URLs
* @param {DownloadPreloadOption[]} scripts - URLs of preload scripts. See tutorial for more details.
* @return {Promise.Array<DownloadPreloadInfo>}
* @tutorial System.downloadPreloadScripts
*/
* Download preload scripts from given URLs
* @param {DownloadPreloadOption[]} scripts - URLs of preload scripts. See tutorial for more details.
* @return {Promise.Array<DownloadPreloadInfo>}
* @tutorial System.downloadPreloadScripts
*/
downloadPreloadScripts(scripts: Array<DownloadPreloadOption>): Promise<Array<DownloadPreloadInfo>>;

@@ -769,0 +787,0 @@ /**

@@ -8,4 +8,4 @@ import { WebContents } from '../webcontents/webcontents';

import { WindowOption, CustomRequestHeaders, Api, ContentNavigation } from '../window/windowOption';
import { ViewBounds, ContextMenuSettings, Hotkey, PreloadScript } from '../../shapes';
import { ViewBounds, ContextMenuSettings, Hotkey } from '../../shapes/shapes';
import { PreloadScript } from '../../shapes/PreloadScript';
/**

@@ -27,9 +27,9 @@ * @lends View

/**
* Asynchronously returns a View object that represents an existing view.
* @param { Identity } identity
* @return {Promise.<View>}
* @tutorial View.wrap
* @experimental
* @static
*/
* Asynchronously returns a View object that represents an existing view.
* @param { Identity } identity
* @return {Promise.<View>}
* @tutorial View.wrap
* @experimental
* @static
*/
wrap(identity: Identity): Promise<View>;

@@ -112,6 +112,2 @@ /**

*
* @property {any} [customContext=""] - _Updatable._
* A field that the user can use to attach serializable data that will be saved when {@link Platform#getSnapshot Platform.getSnapshot}
* is called. If a window or a view in a Platform is trying to update or retrieve its own context, it can use the
* {@link Platform#setContext Platform.setContext} and {@link Platform#getContext Platform.getContext} calls.
* When omitted, the default value of this property is the empty string (`""`).

@@ -168,2 +164,11 @@ * As opposed to customData this is meant for frequent updates and sharing with other contexts. [Example]{@tutorial customContext}

/**
* Gets a base64 encoded image of the view or a part of it.
* @function capturePage
* @param { CapturePageOptions } [options] Options for the capturePage call.
* @memberOf View
* @instance
* @return {Promise.<string>}
* @tutorial View.capturePage
*/
/**
* Executes Javascript on the view, restricted to contents you own or contents owned by

@@ -187,11 +192,14 @@ * applications you have created.

* @experimental
*/
*/
focus({ emitSynthFocused }?: {
emitSynthFocused: boolean;
}): Promise<void>;
/**
* Returns the zoom level of the view.
* @function getZoomLevel
* @memberOf View
* @instance
* @return {Promise.<number>}
* @tutorial View.getZoomLevel
*/
* Returns the zoom level of the view.
* @function getZoomLevel
* @memberOf View
* @instance
* @return {Promise.<number>}
* @tutorial View.getZoomLevel
*/
/**

@@ -264,121 +272,121 @@ * Sets the zoom level of the view.

/**
* Reloads the view current page
* @function reload
* @memberOf View
* @instance
* @return {Promise.<void>}
* @tutorial View.reload
*/
* Reloads the view current page
* @function reload
* @memberOf View
* @instance
* @return {Promise.<void>}
* @tutorial View.reload
*/
/**
* Prints the view's web page
* @param { PrintOptions } [options] Printer Options
* @function print
* @memberOf View
* @instance
* @return {Promise.<void>}
* @tutorial View.print
*/
* Prints the view's web page
* @param { PrintOptions } [options] Printer Options
* @function print
* @memberOf View
* @instance
* @return {Promise.<void>}
* @tutorial View.print
*/
/**
* Returns an array with all system printers
* @function getPrinters
* @memberOf View
* @instance
* @return { Promise.Array.<PrinterInfo> }
* @tutorial View.getPrinters
*/
* Returns an array with all system printers
* @function getPrinters
* @memberOf View
* @instance
* @return { Promise.Array.<PrinterInfo> }
* @tutorial View.getPrinters
*/
/**
* Shows the Chromium Developer Tools
* @function showDeveloperTools
* @memberOf View
* @instance
* @return {Promise.<void>}
* @tutorial View.showDeveloperTools
*/
* Shows the Chromium Developer Tools
* @function showDeveloperTools
* @memberOf View
* @instance
* @return {Promise.<void>}
* @tutorial View.showDeveloperTools
*/
/**
* Attaches the current view to a the given window identity.
* Identity must be the identity of a window in the same application.
* This detaches the view from its current window, and sets the view to be destroyed when its new window closes.
* @param target {Identity}
* @return {Promise.<void>}
* @tutorial View.attach
* @experimental
*/
* Attaches the current view to a the given window identity.
* Identity must be the identity of a window in the same application.
* This detaches the view from its current window, and sets the view to be destroyed when its new window closes.
* @param target {Identity}
* @return {Promise.<void>}
* @tutorial View.attach
* @experimental
*/
attach: (target: Identity) => Promise<void>;
/**
* Destroys the current view
* @return {Promise.<void>}
* @tutorial View.destroy
* @experimental
*/
* Destroys the current view
* @return {Promise.<void>}
* @tutorial View.destroy
* @experimental
*/
destroy: () => Promise<void>;
/**
* Shows the current view if it is currently hidden.
* @return {Promise.<void>}
* @tutorial View.show
* @experimental
*/
* Shows the current view if it is currently hidden.
* @return {Promise.<void>}
* @tutorial View.show
* @experimental
*/
show: () => Promise<void>;
/**
* Hides the current view if it is currently visible.
* @return {Promise.<void>}
* @tutorial View.hide
* @experimental
*/
* Hides the current view if it is currently visible.
* @return {Promise.<void>}
* @tutorial View.hide
* @experimental
*/
hide: () => Promise<void>;
/**
* Sets the bounds (top, left, width, height) of the view relative to its window.
* @param bounds {Bounds}
* @return {Promise.<void>}
* @tutorial View.setBounds
* @experimental
*/
setBounds: (bounds: Pick<import("../../shapes").Bounds, "height" | "width" | "top" | "left">) => Promise<void>;
* Sets the bounds (top, left, width, height) of the view relative to its window.
* @param bounds {Bounds}
* @return {Promise.<void>}
* @tutorial View.setBounds
* @experimental
*/
setBounds: (bounds: ViewBounds) => Promise<void>;
/**
* Gets the bounds (top, left, width, height) of the view relative to its window.
* @return {Promise.<Bounds>}
* @tutorial View.getBounds
* @experimental
*/
* Gets the bounds (top, left, width, height) of the view relative to its window.
* @return {Promise.<Bounds>}
* @tutorial View.getBounds
* @experimental
*/
getBounds: () => Promise<any>;
/**
* Gets the View's info.
* @return {Promise.<ViewInfo>}
* @tutorial View.getInfo
* @experimental
*/
* Gets the View's info.
* @return {Promise.<ViewInfo>}
* @tutorial View.getInfo
* @experimental
*/
getInfo: () => Promise<any>;
/**
* Gets the View's options.
* @return {Promise<ViewCreationOptions>}
* @tutorial View.getOptions
* @experimental
*/
* Gets the View's options.
* @return {Promise<ViewCreationOptions>}
* @tutorial View.getOptions
* @experimental
*/
getOptions: () => Promise<ViewCreationOptions>;
/**
* Gets the view's info.
* @param { Partial<ViewOptions> } options
* @return {Promise.<void>}
* @tutorial View.updateOptions
* @experimental
*/
* Gets the view's info.
* @param { Partial<ViewOptions> } options
* @return {Promise.<void>}
* @tutorial View.updateOptions
* @experimental
*/
updateOptions: (options: Partial<ViewOptions>) => Promise<any>;
/**
* Retrieves the window the view is currently attached to.
* @return {Promise.<_Window>}
* @experimental
*/
* Retrieves the window the view is currently attached to.
* @return {Promise.<_Window>}
* @experimental
*/
getCurrentWindow: () => Promise<_Window>;
/**
* Sets a custom window handler. Only works if experimental child windows are enabled for the view.
* Takes a match pattern or array of match patterns for which to call the handler.
* If multiple handlers are set that match a url, only the first set one will be called.
* This can be used to "cascade" listeners.
* Returns a function to unsubscribe this handler.
* @tutorial View.setCustomWindowHandler
* @param { string | string[] } urls Url match pattern or array of match patterns
* see (https://developer.chrome.com/extensions/match_patterns)
* @param {Function} handler function that will be called with the window options that match the url.
* @return {Function}
* @experimental
*/
* Sets a custom window handler. Only works if experimental child windows are enabled for the view.
* Takes a match pattern or array of match patterns for which to call the handler.
* If multiple handlers are set that match a url, only the first set one will be called.
* This can be used to "cascade" listeners.
* Returns a function to unsubscribe this handler.
* @tutorial View.setCustomWindowHandler
* @param { string | string[] } urls Url match pattern or array of match patterns
* see (https://developer.chrome.com/extensions/match_patterns)
* @param {Function} handler function that will be called with the window options that match the url.
* @return {Function}
* @experimental
*/
setCustomWindowHandler: (urls: string | string[], handler: (options: WindowOption) => void) => Promise<() => Promise<void>>;

@@ -385,0 +393,0 @@ }

@@ -5,6 +5,13 @@ import { EmitterBase } from '../base';

import { WebContentsEventMapping } from '../events/webcontents';
import { PrintOptions, FindInPageOptions, PrinterInfo } from '../window/window';
import { PrintOptions, FindInPageOptions, PrinterInfo, Area } from '../window/window';
declare type ImageFormat = 'bmp' | 'jpg' | 'png';
export interface CapturePageOptions {
area?: Area;
format?: ImageFormat;
quality?: number;
}
export declare class WebContents<T extends WebContentsEventMapping> extends EmitterBase<T> {
entityType: string;
constructor(wire: Transport, identity: Identity, entityType: string);
capturePage(options?: CapturePageOptions): Promise<string>;
executeJavaScript(code: string): Promise<void>;

@@ -22,4 +29,7 @@ getZoomLevel(): Promise<number>;

getPrinters(): Promise<PrinterInfo>;
focus(): Promise<void>;
focus({ emitSynthFocused }?: {
emitSynthFocused: boolean;
}): Promise<void>;
showDeveloperTools(): Promise<void>;
}
export {};

@@ -6,3 +6,3 @@ import { Base } from '../base';

import { WindowEvents } from '../events/window';
import { AnchorType, Bounds, Transition, TransitionOptions } from '../../shapes';
import { AnchorType, Bounds, Transition, TransitionOptions } from '../../shapes/shapes';
import { WindowOption } from './windowOption';

@@ -88,3 +88,3 @@ import { EntityType } from '../frame/frame';

interface Margins {
marginType?: ('default' | 'none' | 'printableArea' | 'custom');
marginType?: 'default' | 'none' | 'printableArea' | 'custom';
top?: number;

@@ -111,3 +111,3 @@ bottom?: number;

pageRanges?: Record<string, number>;
duplexMode?: ('simplex' | 'shortEdge' | 'longEdge');
duplexMode?: 'simplex' | 'shortEdge' | 'longEdge';
dpi?: Dpi;

@@ -135,3 +135,3 @@ }

* @property { number } [right] The right margin of the printed web page, in pixels.
*/
*/
/**

@@ -141,3 +141,3 @@ * @typedef { object } Dpi

* @property { number } [vertical] The vertical dpi
*/
*/
/**

@@ -160,9 +160,9 @@ * @typedef { object } PrintOptions

/**
* PrinterInfo interface
* @typedef { object } PrinterInfo
* @property { string } name Printer Name
* @property { string } description Printer Description
* @property { number } status Printer Status
* @property { boolean } isDefault Indicates that system's default printer
*/
* PrinterInfo interface
* @typedef { object } PrinterInfo
* @property { string } name Printer Name
* @property { string } description Printer Description
* @property { number } status Printer Status
* @property { boolean } isDefault Indicates that system's default printer
*/
/**

@@ -279,3 +279,3 @@ * @typedef {object} Window~options

* is called. If a window in a Platform is trying to update or retrieve its own context, it can use the
* {@link Platform#setContext Platform.setContext} and {@link Platform#getContext Platform.getContext} calls.
* {@link Platform#setWindowContext Platform.setWindowContext} and {@link Platform#getWindowContext Platform.getWindowContext} calls.
* When omitted, the default value of this property is the empty string (`""`).

@@ -378,2 +378,6 @@ * As opposed to customData this is meant for frequent updates and sharing with other contexts. [Example]{@tutorial customContext}

*
* @property {boolean} [showBackgroundImages=false] - _Updatable._
* Platforms Only. If true, will show background images in the layout when the Views are hidden.
* This occurs when the window is resizing or a tab is being dragged within the layout.
*
* @property {boolean} [showTaskbarIcon=true] - _Updatable._ _Windows_.

@@ -414,2 +418,8 @@ * A flag to show the window's icon in the taskbar.

/**
* @typedef {object} CapturePageOptions
* @property { Area } [area] The area of the window to be captured.
* @property { string } [format='png'] The format of the captured image. Can be 'png', 'jpg', or 'bmp'.
* @property { number } [quality=100] Number representing quality of JPEG image only. Between 0 - 100.
*/
/**
* @typedef { object } Area

@@ -440,3 +450,3 @@ * @property { number } height Area's height

* @property {Size} size - The Size transition
*/
*/
/**

@@ -467,3 +477,3 @@ * @typedef {object} TransitionOptions

* @property {number} opacity - This value is clamped from 0.0 to 1.0.
*/
*/
/**

@@ -571,2 +581,11 @@ * Bounds is a interface that has the properties of height,

/**
* Gets a base64 encoded image of the window or a part of it.
* @function capturePage
* @param { CapturePageOptions } [options] options for capturePage call.
* @return {Promise.<string>}
* @memberof Window
* @instance
* @tutorial Window.capturePage
*/
/**
* Executes Javascript on the window, restricted to windows you own or windows owned by

@@ -591,9 +610,9 @@ * applications you have created.

/**
* Returns the zoom level of the window.
* @function getZoomLevel
* @memberOf Window
* @instance
* @return {Promise.<number>}
* @tutorial Window.getZoomLevel
*/
* Returns the zoom level of the window.
* @function getZoomLevel
* @memberOf Window
* @instance
* @return {Promise.<number>}
* @tutorial Window.getZoomLevel
*/
/**

@@ -665,26 +684,26 @@ * Sets the zoom level of the window.

/**
* Reloads the window current page
* @function reload
* @memberOf Window
* @instance
* @return {Promise.<void>}
* @tutorial Window.reload
*/
* Reloads the window current page
* @function reload
* @memberOf Window
* @instance
* @return {Promise.<void>}
* @tutorial Window.reload
*/
/**
* Prints the window's web page
* @param { PrintOptions } [options] Printer Options
* @function print
* @memberOf Window
* @instance
* @return {Promise.<void>}
* @tutorial Window.print
*/
* Prints the window's web page
* @param { PrintOptions } [options] Printer Options
* @function print
* @memberOf Window
* @instance
* @return {Promise.<void>}
* @tutorial Window.print
*/
/**
* Returns an array with all system printers
* @function getPrinters
* @memberOf Window
* @instance
* @return { Promise.Array.<PrinterInfo> }
* @tutorial Window.getPrinters
*/
* Returns an array with all system printers
* @function getPrinters
* @memberOf Window
* @instance
* @return { Promise.Array.<PrinterInfo> }
* @tutorial Window.getPrinters
*/
createWindow(options: WindowOption): Promise<_Window>;

@@ -703,3 +722,3 @@ private windowListFromNameList;

* @tutorial Window.getBounds
*/
*/
getBounds(): Promise<Bounds>;

@@ -744,4 +763,5 @@ /**

* @tutorial Window.close
*/
*/
close(force?: boolean): Promise<void>;
focusedWebViewWasChanged(): Promise<void>;
/**

@@ -755,7 +775,7 @@ * Returns the native OS level Id.

/**
* Retrieves window's attached views.
* @experimental
* @return {Promise.Array.<View>}
* @tutorial Window.getCurrentViews
*/
* Retrieves window's attached views.
* @experimental
* @return {Promise.Array.<View>}
* @tutorial Window.getCurrentViews
*/
getCurrentViews(): Promise<Array<View>>;

@@ -821,7 +841,8 @@ disableFrame(): Promise<void>;

/**
* Gets a base64 encoded PNG snapshot of the window or just part a of it.
* ***DEPRECATED - please use Window.capturePage.***
* Gets a base64 encoded PNG image of the window or just part a of it.
* @param { Area } [area] The area of the window to be captured.
* Omitting it will capture the whole visible window.
* @return {Promise.<string>}
* @tutorial Window.getSnapshot
* @tutorial Window.capturePage
*/

@@ -828,0 +849,0 @@ getSnapshot(area?: Area): Promise<string>;

import { DownloadPreloadOption } from '../system/download-preload';
import { RGB, ContextMenuSettings, Hotkey } from '../../shapes';
import { RGB, ContextMenuSettings, Hotkey } from '../../shapes/shapes';
export interface WindowOption {

@@ -44,2 +44,3 @@ accelerator?: Accelerator;

showTaskbarIcon?: boolean;
showBackgroundImages?: boolean;
smallWindow?: boolean;

@@ -46,0 +47,0 @@ state?: string;

@@ -6,2 +6,6 @@ export interface Identity {

}
export interface NamedIdentity {
uuid: string;
name: string;
}
export interface GroupWindowIdentity extends Identity {

@@ -8,0 +12,0 @@ isExternalWindow?: boolean;

@@ -1,2 +0,2 @@

export declare function exists(path: string): Promise<Boolean>;
export declare function exists(path: string): Promise<boolean>;
export declare function unzip(file: string, dest: string): Promise<any>;

@@ -3,0 +3,0 @@ export declare function rmDir(dirPath: string, removeSelf?: boolean): Promise<void>;

@@ -10,5 +10,5 @@ /// <reference types="node" />

connect: (address: string) => Promise<any>;
send(data: any, flags?: any): Promise<any>;
shutdown(): Promise<void>;
send: (data: any, flags?: any) => Promise<any>;
shutdown: () => Promise<void>;
static READY_STATE: typeof READY_STATE;
}
import { PortDiscoveryConfig } from './wire';
import { Environment } from '../environment/environment';
export declare class PortDiscovery {
export default class PortDiscovery {
private savedConfig;

@@ -9,3 +9,3 @@ private namedPipeName;

private pipeConnection;
private timeoutTimer;
private timeoutTimer?;
private environment;

@@ -12,0 +12,0 @@ constructor(config: PortDiscoveryConfig, environment: Environment);

/// <reference types="node" />
import { EventEmitter } from 'events';
import { Wire, WireConstructor, READY_STATE, ExistingConnectConfig, ConnectConfig, InternalConnectConfig } from './wire';
import { Identity } from '../identity';
import { EventEmitter } from 'events';
import { Environment } from '../environment/environment';

@@ -22,3 +22,3 @@ import { RuntimeEvent } from '../api/events/base';

protected messageHandlers: MessageHandler[];
constructor(wireType: WireConstructor, environment: Environment);
constructor(WireType: WireConstructor, environment: Environment);
connectSync: (config: ConnectConfig) => void;

@@ -42,3 +42,3 @@ getPort: () => string;

}
export declare class Message<T> {
export interface Message<T> {
action: string;

@@ -48,7 +48,7 @@ payload: T;

}
export declare class EventMessage implements Message<RuntimeEvent> {
export interface EventMessage extends Message<RuntimeEvent> {
action: 'process-desktop-event';
payload: RuntimeEvent;
}
export declare class NotificationEventMessage implements Message<NotificationEvent> {
export interface NotificationEventMessage extends Message<NotificationEvent> {
action: 'process-notification-event';

@@ -63,9 +63,9 @@ payload: NotificationEvent;

}
export declare class Payload {
export interface Payload {
success: boolean;
data: any;
}
export declare class AuthorizationPayload {
export interface AuthorizationPayload {
token: string;
file: string;
}
import { Identity } from '../main';
import { default as Transport } from '../transport/transport';
import Transport from '../transport/transport';
import { EntityType } from '../api/frame/frame';

@@ -4,0 +4,0 @@ export declare function getInstanceByEntityType(entityType: string, wire: Transport, identity: Identity): {};

{
"name": "@types/openfin",
"version": "50.0.1",
"version": "51.0.0",
"description": "TypeScript definitions for OpenFin API",

@@ -47,4 +47,4 @@ "license": "MIT",

},
"typesPublisherContentHash": "c212c16169d1c0dd17af7c003b440efefe4ffdf1b273e27f759b57bb0eb1f3d7",
"typeScriptVersion": "3.0"
"typesPublisherContentHash": "ff2be119da8140cd0620bb94c3ea276c7bc21e706ce22d5c0ab5f3dde085d7dd",
"typeScriptVersion": "3.6"
}

@@ -11,3 +11,3 @@ # Installation

### Additional Details
* Last updated: Fri, 15 May 2020 11:31:29 GMT
* Last updated: Mon, 06 Jul 2020 23:50:40 GMT
* Dependencies: [@types/node](https://npmjs.com/package/@types/node), [@types/resize-observer-browser](https://npmjs.com/package/@types/resize-observer-browser), [@types/jquery](https://npmjs.com/package/@types/jquery), [@types/ws](https://npmjs.com/package/@types/ws)

@@ -14,0 +14,0 @@ * Global values: `GoldenLayout`, `fdc3`, `fin`

Sorry, the diff of this file is too big to display