@openfin/core 34.78.7 → 34.78.9
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/out/mock-alpha.d.ts +444 -47
- package/out/mock-beta.d.ts +444 -47
- package/out/mock-public.d.ts +444 -47
- package/out/mock.d.ts +446 -49
- package/out/mock.js +179 -143
- package/package.json +1 -1
package/out/mock.js
CHANGED
|
@@ -893,6 +893,9 @@ function requireFactory$3 () {
|
|
|
893
893
|
const base_1 = base;
|
|
894
894
|
const validate_1 = validate;
|
|
895
895
|
const index_1 = requireView();
|
|
896
|
+
/**
|
|
897
|
+
* Static namespace for OpenFin API methods that interact with the {@link View} class, available under `fin.View`.
|
|
898
|
+
*/
|
|
896
899
|
class ViewModule extends base_1.Base {
|
|
897
900
|
/**
|
|
898
901
|
* Creates a new View.
|
|
@@ -4378,6 +4381,9 @@ function requireFactory$2 () {
|
|
|
4378
4381
|
const base_1 = base;
|
|
4379
4382
|
const validate_1 = validate;
|
|
4380
4383
|
const Instance_1 = requireInstance$1();
|
|
4384
|
+
/**
|
|
4385
|
+
* Static namespace for OpenFin API methods that interact with the {@link Application} class, available under `fin.Application`.
|
|
4386
|
+
*/
|
|
4381
4387
|
class ApplicationModule extends base_1.Base {
|
|
4382
4388
|
/**
|
|
4383
4389
|
* Asynchronously returns an Application object that represents an existing application.
|
|
@@ -6004,11 +6010,12 @@ function requireInstance () {
|
|
|
6004
6010
|
* moveBy(580, 300).then(() => console.log('Moved')).catch(err => console.log(err));
|
|
6005
6011
|
* ```
|
|
6006
6012
|
*/
|
|
6007
|
-
moveBy(deltaLeft, deltaTop) {
|
|
6013
|
+
moveBy(deltaLeft, deltaTop, positioningOptions) {
|
|
6008
6014
|
return this.wire
|
|
6009
6015
|
.sendAction('move-window-by', {
|
|
6010
6016
|
deltaLeft,
|
|
6011
6017
|
deltaTop,
|
|
6018
|
+
positioningOptions,
|
|
6012
6019
|
...this.identity
|
|
6013
6020
|
})
|
|
6014
6021
|
.then(() => undefined);
|
|
@@ -6038,11 +6045,12 @@ function requireInstance () {
|
|
|
6038
6045
|
* moveTo(580, 300).then(() => console.log('Moved')).catch(err => console.log(err))
|
|
6039
6046
|
* ```
|
|
6040
6047
|
*/
|
|
6041
|
-
moveTo(left, top) {
|
|
6048
|
+
moveTo(left, top, positioningOptions) {
|
|
6042
6049
|
return this.wire
|
|
6043
6050
|
.sendAction('move-window', {
|
|
6044
6051
|
left,
|
|
6045
6052
|
top,
|
|
6053
|
+
positioningOptions,
|
|
6046
6054
|
...this.identity
|
|
6047
6055
|
})
|
|
6048
6056
|
.then(() => undefined);
|
|
@@ -6075,12 +6083,13 @@ function requireInstance () {
|
|
|
6075
6083
|
* resizeBy(580, 300, 'top-right').then(() => console.log('Resized')).catch(err => console.log(err));
|
|
6076
6084
|
* ```
|
|
6077
6085
|
*/
|
|
6078
|
-
resizeBy(deltaWidth, deltaHeight, anchor) {
|
|
6086
|
+
resizeBy(deltaWidth, deltaHeight, anchor, positioningOptions) {
|
|
6079
6087
|
return this.wire
|
|
6080
6088
|
.sendAction('resize-window-by', {
|
|
6081
6089
|
deltaWidth: Math.floor(deltaWidth),
|
|
6082
6090
|
deltaHeight: Math.floor(deltaHeight),
|
|
6083
6091
|
anchor,
|
|
6092
|
+
positioningOptions,
|
|
6084
6093
|
...this.identity
|
|
6085
6094
|
})
|
|
6086
6095
|
.then(() => undefined);
|
|
@@ -6113,12 +6122,13 @@ function requireInstance () {
|
|
|
6113
6122
|
* resizeTo(580, 300, 'top-left').then(() => console.log('Resized')).catch(err => console.log(err));
|
|
6114
6123
|
* ```
|
|
6115
6124
|
*/
|
|
6116
|
-
resizeTo(width, height, anchor) {
|
|
6125
|
+
resizeTo(width, height, anchor, positioningOptions) {
|
|
6117
6126
|
return this.wire
|
|
6118
6127
|
.sendAction('resize-window', {
|
|
6119
6128
|
width: Math.floor(width),
|
|
6120
6129
|
height: Math.floor(height),
|
|
6121
6130
|
anchor,
|
|
6131
|
+
positioningOptions,
|
|
6122
6132
|
...this.identity
|
|
6123
6133
|
})
|
|
6124
6134
|
.then(() => undefined);
|
|
@@ -6177,7 +6187,6 @@ function requireInstance () {
|
|
|
6177
6187
|
}
|
|
6178
6188
|
/**
|
|
6179
6189
|
* Sets the window's size and position.
|
|
6180
|
-
* @property { Bounds } bounds This is a * @type {string} name - name of the window.object that holds the propertys of
|
|
6181
6190
|
*
|
|
6182
6191
|
* @example
|
|
6183
6192
|
* ```js
|
|
@@ -6204,8 +6213,10 @@ function requireInstance () {
|
|
|
6204
6213
|
* }).then(() => console.log('Bounds set to window')).catch(err => console.log(err));
|
|
6205
6214
|
* ```
|
|
6206
6215
|
*/
|
|
6207
|
-
setBounds(bounds) {
|
|
6208
|
-
return this.wire
|
|
6216
|
+
setBounds(bounds, positioningOptions) {
|
|
6217
|
+
return this.wire
|
|
6218
|
+
.sendAction('set-window-bounds', { ...bounds, ...this.identity, positioningOptions })
|
|
6219
|
+
.then(() => undefined);
|
|
6209
6220
|
}
|
|
6210
6221
|
/**
|
|
6211
6222
|
* Shows the window if it is hidden.
|
|
@@ -6547,6 +6558,9 @@ function requireFactory$1 () {
|
|
|
6547
6558
|
const base_1 = base;
|
|
6548
6559
|
const validate_1 = validate;
|
|
6549
6560
|
const Instance_1 = requireInstance();
|
|
6561
|
+
/**
|
|
6562
|
+
* Static namespace for OpenFin API methods that interact with the {@link _Window} class, available under `fin.Window`.
|
|
6563
|
+
*/
|
|
6550
6564
|
class _WindowModule extends base_1.Base {
|
|
6551
6565
|
/**
|
|
6552
6566
|
* Asynchronously returns a Window object that represents an existing window.
|
|
@@ -8986,17 +9000,17 @@ const channelClientsByEndpointId = new Map();
|
|
|
8986
9000
|
* provider via {@link ChannelClient#dispatch dispatch} and to listen for communication
|
|
8987
9001
|
* from the provider by registering an action via {@link ChannelClient#register register}.
|
|
8988
9002
|
*
|
|
8989
|
-
* Synchronous Methods:
|
|
9003
|
+
* ### Synchronous Methods:
|
|
8990
9004
|
* * {@link ChannelClient#onDisconnection onDisconnection(listener)}
|
|
8991
9005
|
* * {@link ChannelClient#register register(action, listener)}
|
|
8992
9006
|
* * {@link ChannelClient#remove remove(action)}
|
|
8993
9007
|
*
|
|
8994
|
-
* Asynchronous Methods:
|
|
9008
|
+
* ### Asynchronous Methods:
|
|
8995
9009
|
* * {@link ChannelClient#disconnect disconnect()}
|
|
8996
9010
|
* * {@link ChannelClient#dispatch dispatch(action, payload)}
|
|
8997
9011
|
*
|
|
8998
|
-
* Middleware:
|
|
8999
|
-
*
|
|
9012
|
+
* ### Middleware:
|
|
9013
|
+
* Middleware functions receive the following arguments: (action, payload, senderId).
|
|
9000
9014
|
* The return value of the middleware function will be passed on as the payload from beforeAction, to the action listener, to afterAction
|
|
9001
9015
|
* unless it is undefined, in which case the original payload is used. Middleware can be used for side effects.
|
|
9002
9016
|
* * {@link ChannelClient#setDefaultAction setDefaultAction(middleware)}
|
|
@@ -9686,20 +9700,20 @@ const runtimeVersioning_1 = runtimeVersioning;
|
|
|
9686
9700
|
* a single client via {@link ChannelProvider#dispatch dispatch} or all clients via {@link ChannelProvider#publish publish}
|
|
9687
9701
|
* and to listen for communication from clients by registering an action via {@link ChannelProvider#register register}.
|
|
9688
9702
|
*
|
|
9689
|
-
* Synchronous Methods:
|
|
9703
|
+
* ### Synchronous Methods:
|
|
9690
9704
|
* * {@link ChannelProvider#onConnection onConnection(listener)}
|
|
9691
9705
|
* * {@link ChannelProvider#onDisconnection onDisconnection(listener)}
|
|
9692
9706
|
* * {@link ChannelProvider#publish publish(action, payload)}
|
|
9693
9707
|
* * {@link ChannelProvider#register register(action, listener)}
|
|
9694
9708
|
* * {@link ChannelProvider#remove remove(action)}
|
|
9695
9709
|
*
|
|
9696
|
-
* Asynchronous Methods:
|
|
9710
|
+
* ### Asynchronous Methods:
|
|
9697
9711
|
* * {@link ChannelProvider#destroy destroy()}
|
|
9698
9712
|
* * {@link ChannelProvider#dispatch dispatch(to, action, payload)}
|
|
9699
9713
|
* * {@link ChannelProvider#getAllClientInfo getAllClientInfo()}
|
|
9700
9714
|
*
|
|
9701
|
-
* Middleware:
|
|
9702
|
-
*
|
|
9715
|
+
* ### Middleware:
|
|
9716
|
+
* Middleware functions receive the following arguments: (action, payload, senderId).
|
|
9703
9717
|
* The return value of the middleware function will be passed on as the payload from beforeAction, to the action listener, to afterAction
|
|
9704
9718
|
* unless it is undefined, in which case the most recently defined payload is used. Middleware can be used for side effects.
|
|
9705
9719
|
* * {@link ChannelProvider#setDefaultAction setDefaultAction(middleware)}
|
|
@@ -11186,7 +11200,7 @@ const base_1$c = base;
|
|
|
11186
11200
|
/**
|
|
11187
11201
|
* An ExternalApplication object representing native language adapter connections to the runtime. Allows
|
|
11188
11202
|
* the developer to listen to {@link OpenFin.ExternalApplicationEvents external application events}.
|
|
11189
|
-
* Discovery of connections is provided by
|
|
11203
|
+
* Discovery of connections is provided by {@link System.System.getAllExternalApplications getAllExternalApplications}.</a>
|
|
11190
11204
|
*
|
|
11191
11205
|
* Processes that can be wrapped as `ExternalApplication`s include the following:
|
|
11192
11206
|
* - Processes which have connected to an OpenFin runtime via an adapter
|
|
@@ -11300,6 +11314,9 @@ Object.defineProperty(Factory$5, "__esModule", { value: true });
|
|
|
11300
11314
|
Factory$5.ExternalApplicationModule = void 0;
|
|
11301
11315
|
const base_1$b = base;
|
|
11302
11316
|
const Instance_1$4 = Instance$4;
|
|
11317
|
+
/**
|
|
11318
|
+
* Static namespace for OpenFin API methods that interact with the {@link ExternalApplication} class, available under `fin.ExternalApplication`.
|
|
11319
|
+
*/
|
|
11303
11320
|
class ExternalApplicationModule extends base_1$b.Base {
|
|
11304
11321
|
/**
|
|
11305
11322
|
* Asynchronously returns an External Application object that represents an external application.
|
|
@@ -11527,6 +11544,9 @@ Factory$4._FrameModule = void 0;
|
|
|
11527
11544
|
const base_1$9 = base;
|
|
11528
11545
|
const validate_1$2 = validate;
|
|
11529
11546
|
const Instance_1$3 = Instance$3;
|
|
11547
|
+
/**
|
|
11548
|
+
* Static namespace for OpenFin API methods that interact with the {@link _Frame} class, available under `fin.Frame`.
|
|
11549
|
+
*/
|
|
11530
11550
|
class _FrameModule extends base_1$9.Base {
|
|
11531
11551
|
/**
|
|
11532
11552
|
* Asynchronously returns a reference to the specified frame. The frame does not have to exist
|
|
@@ -11612,7 +11632,7 @@ Factory$4._FrameModule = _FrameModule;
|
|
|
11612
11632
|
* * {@link _FrameModule} contains static methods relating to the `Frame` type, accessible through `fin.Frame`.
|
|
11613
11633
|
* * {@link _Frame} describes an instance of an OpenFin Frame, e.g. as returned by `fin.Frame.getCurrent`.
|
|
11614
11634
|
*
|
|
11615
|
-
* These are separate code entities, and are documented separately.
|
|
11635
|
+
* These are separate code entities, and are documented separately. In the [previous version of the API documentation](https://cdn.openfin.co/docs/javascript/canary/index.html),
|
|
11616
11636
|
* both of these were documented on the same page.
|
|
11617
11637
|
*
|
|
11618
11638
|
* Underscore prefixing of OpenFin types that alias DOM entities will be fixed in a future version.
|
|
@@ -12655,6 +12675,138 @@ const base_1$6 = base;
|
|
|
12655
12675
|
const common_utils_1 = commonUtils;
|
|
12656
12676
|
const layout_entities_1 = layoutEntities;
|
|
12657
12677
|
const layout_constants_1 = layout_constants;
|
|
12678
|
+
/**
|
|
12679
|
+
*
|
|
12680
|
+
* Layouts give app providers the ability to embed multiple views in a single window. The Layout namespace
|
|
12681
|
+
* enables the initialization and manipulation of a window's Layout. A Layout will
|
|
12682
|
+
* emit events locally on the DOM element representing the layout-container.
|
|
12683
|
+
*
|
|
12684
|
+
*
|
|
12685
|
+
* ### Layout.DOMEvents
|
|
12686
|
+
*
|
|
12687
|
+
* When a Layout is created, it emits events onto the DOM element representing the Layout container.
|
|
12688
|
+
* This Layout container is the DOM element referenced by containerId in {@link Layout.LayoutModule#init Layout.init}.
|
|
12689
|
+
* You can use the built-in event emitter to listen to these events using [addEventListener](https://developer.mozilla.org/en-US/docs/Web/API/EventTarget/addEventListener).
|
|
12690
|
+
* The events are emitted synchronously and only in the process where the Layout exists.
|
|
12691
|
+
* Any values returned by the called listeners are ignored and will be discarded.
|
|
12692
|
+
* If the target DOM element is destroyed, any events that have been set up on that element will be destroyed.
|
|
12693
|
+
*
|
|
12694
|
+
* @remarks The built-in event emitter is not an OpenFin event emitter so it doesn't share propagation semantics.
|
|
12695
|
+
*
|
|
12696
|
+
* #### {@link https://developer.mozilla.org/en-US/docs/Web/API/EventTarget/addEventListener addEventListener(type, listener [, options]);}
|
|
12697
|
+
* Adds a listener to the end of the listeners array for the specified event.
|
|
12698
|
+
* @example
|
|
12699
|
+
* ```js
|
|
12700
|
+
* const myLayoutContainer = document.getElementById('layout-container');
|
|
12701
|
+
*
|
|
12702
|
+
* myLayoutContainer.addEventListener('tab-created', function(event) {
|
|
12703
|
+
* const { tabSelector } = event.detail;
|
|
12704
|
+
* const tabElement = document.getElementById(tabSelector);
|
|
12705
|
+
* const existingColor = tabElement.style.backgroundColor;
|
|
12706
|
+
* tabElement.style.backgroundColor = "red";
|
|
12707
|
+
* setTimeout(() => {
|
|
12708
|
+
* tabElement.style.backgroundColor = existingColor;
|
|
12709
|
+
* }, 2000);
|
|
12710
|
+
* });
|
|
12711
|
+
* ```
|
|
12712
|
+
*
|
|
12713
|
+
* #### {@link https://developer.mozilla.org/en-US/docs/Web/API/EventTarget/removeEventListener removeEventListener(type, listener [, options]);}
|
|
12714
|
+
* Adds a listener to the end of the listeners array for the specified event.
|
|
12715
|
+
* @example
|
|
12716
|
+
* ```js
|
|
12717
|
+
* const myLayoutContainer = document.getElementById('layout-container');
|
|
12718
|
+
*
|
|
12719
|
+
* const listener = function(event) {
|
|
12720
|
+
* console.log(event.detail);
|
|
12721
|
+
* console.log('container-created event fired once, removing listener');
|
|
12722
|
+
* myLayoutContainer.removeEventListener('container-created', listener);
|
|
12723
|
+
* };
|
|
12724
|
+
*
|
|
12725
|
+
* myLayoutContainer.addEventListener('container-created', listener);
|
|
12726
|
+
* ```
|
|
12727
|
+
*
|
|
12728
|
+
* ### Supported event types are:
|
|
12729
|
+
*
|
|
12730
|
+
* * tab-created
|
|
12731
|
+
* * container-created
|
|
12732
|
+
* * layout-state-changed
|
|
12733
|
+
* * tab-closed
|
|
12734
|
+
* * tab-dropped
|
|
12735
|
+
*
|
|
12736
|
+
* ### Layout DOM Node Events
|
|
12737
|
+
*
|
|
12738
|
+
* #### tab-created
|
|
12739
|
+
* Generated when a tab is created. As a user drags and drops tabs within window, new tabs are created. A single view may have multiple tabs created and destroyed during its lifetime attached to a single window.
|
|
12740
|
+
* ```js
|
|
12741
|
+
* // The response has the following shape in event.detail:
|
|
12742
|
+
* {
|
|
12743
|
+
* containerSelector: "container-component_A",
|
|
12744
|
+
* name: "component_A",
|
|
12745
|
+
* tabSelector: "tab-component_A",
|
|
12746
|
+
* topic: "openfin-DOM-event",
|
|
12747
|
+
* type: "tab-created",
|
|
12748
|
+
* uuid: "OpenFin POC"
|
|
12749
|
+
* }
|
|
12750
|
+
* ```
|
|
12751
|
+
*
|
|
12752
|
+
* #### container-created
|
|
12753
|
+
* Generated when a container is created. A single view will have only one container during its lifetime attached to a single window and the container's lifecycle is tied to the view. To discover when the container is destroyed, please listen to view-detached event.
|
|
12754
|
+
* ```js
|
|
12755
|
+
* // The response has the following shape in event.detail:
|
|
12756
|
+
* {
|
|
12757
|
+
* containerSelector: "container-component_A",
|
|
12758
|
+
* name: "component_A",
|
|
12759
|
+
* tabSelector: "tab-component_A",
|
|
12760
|
+
* topic: "openfin-DOM-event",
|
|
12761
|
+
* type: "container-created",
|
|
12762
|
+
* uuid: "OpenFin POC"
|
|
12763
|
+
* }
|
|
12764
|
+
* ```
|
|
12765
|
+
*
|
|
12766
|
+
* ### layout-state-changed
|
|
12767
|
+
* Generated when the state of the layout changes in any way, such as a view added/removed/replaced. Note that this event can fire frequently as the underlying layout can change multiple components from all kinds of changes (resizing for example). Given this, it is recommended to debounce this event and then you can use the {@link Layout#getConfig Layout.getConfig} API to retrieve the most up-to-date state.
|
|
12768
|
+
* ```js
|
|
12769
|
+
* // The response has the following shape in event.detail
|
|
12770
|
+
* {
|
|
12771
|
+
* containerSelector: "container-component_A",
|
|
12772
|
+
* name: "component_A",
|
|
12773
|
+
* tabSelector: "tab-component_A",
|
|
12774
|
+
* topic: "openfin-DOM-event",
|
|
12775
|
+
* type: "layout-state-changed",
|
|
12776
|
+
* uuid: "OpenFin POC"
|
|
12777
|
+
* }
|
|
12778
|
+
* ```
|
|
12779
|
+
*
|
|
12780
|
+
* #### tab-closed
|
|
12781
|
+
* Generated when a tab is closed.
|
|
12782
|
+
* ```js
|
|
12783
|
+
* // The response has the following shape in event.detail:
|
|
12784
|
+
* {
|
|
12785
|
+
* containerSelector: "container-component_A",
|
|
12786
|
+
* name: "component_A",
|
|
12787
|
+
* tabSelector: "tab-component_A",
|
|
12788
|
+
* topic: "openfin-DOM-event",
|
|
12789
|
+
* type: "tab-closed",
|
|
12790
|
+
* uuid: "OpenFin POC",
|
|
12791
|
+
* url: "http://openfin.co" // The url of the view that was closed.
|
|
12792
|
+
* }
|
|
12793
|
+
* ```
|
|
12794
|
+
*
|
|
12795
|
+
* #### tab-dropped
|
|
12796
|
+
* Generated when a tab is dropped.
|
|
12797
|
+
* ```js
|
|
12798
|
+
* // The response has the following shape in event.detail:
|
|
12799
|
+
* {
|
|
12800
|
+
* containerSelector: "container-component_A",
|
|
12801
|
+
* name: "component_A",
|
|
12802
|
+
* tabSelector: "tab-component_A",
|
|
12803
|
+
* topic: "openfin-DOM-event",
|
|
12804
|
+
* type: "tab-dropped",
|
|
12805
|
+
* uuid: "OpenFin POC",
|
|
12806
|
+
* url: "http://openfin.co" // The url of the view linked to the dropped tab.
|
|
12807
|
+
* }
|
|
12808
|
+
* ```
|
|
12809
|
+
*/
|
|
12658
12810
|
class Layout extends base_1$6.Base {
|
|
12659
12811
|
/**
|
|
12660
12812
|
* @internal
|
|
@@ -12882,6 +13034,9 @@ Factory$2.LayoutModule = void 0;
|
|
|
12882
13034
|
/* eslint-disable no-undef, import/prefer-default-export */
|
|
12883
13035
|
const base_1$5 = base;
|
|
12884
13036
|
const Instance_1$2 = Instance$1;
|
|
13037
|
+
/**
|
|
13038
|
+
* Static namespace for OpenFin API methods that interact with the {@link Layout} class, available under `fin.Platform.Layout`.
|
|
13039
|
+
*/
|
|
12885
13040
|
class LayoutModule extends base_1$5.Base {
|
|
12886
13041
|
constructor() {
|
|
12887
13042
|
super(...arguments);
|
|
@@ -13047,131 +13202,6 @@ _LayoutModule_layoutInitializationAttempted = new WeakMap();
|
|
|
13047
13202
|
*
|
|
13048
13203
|
* @packageDocumentation
|
|
13049
13204
|
*
|
|
13050
|
-
*
|
|
13051
|
-
* ### Layout.DOMEvents
|
|
13052
|
-
*
|
|
13053
|
-
* When a Layout is created, it emits events onto the DOM element representing the Layout container.
|
|
13054
|
-
* This Layout container is the DOM element referenced by containerId in {@link Layout.LayoutModule#init Layout.init}.
|
|
13055
|
-
* You can use the built-in event emitter to listen to these events using [addEventListener](https://developer.mozilla.org/en-US/docs/Web/API/EventTarget/addEventListener).
|
|
13056
|
-
* The events are emitted synchronously and only in the process where the Layout exists.
|
|
13057
|
-
* Any values returned by the called listeners are ignored and will be discarded.
|
|
13058
|
-
* If the target DOM element is destroyed, any events that have been set up on that element will be destroyed.
|
|
13059
|
-
*
|
|
13060
|
-
* @remarks The built-in event emitter is not an OpenFin event emitter so it doesn't share propagation semantics.
|
|
13061
|
-
*
|
|
13062
|
-
* #### {@link https://developer.mozilla.org/en-US/docs/Web/API/EventTarget/addEventListener addEventListener(type, listener [, options]);}
|
|
13063
|
-
* Adds a listener to the end of the listeners array for the specified event.
|
|
13064
|
-
* @example
|
|
13065
|
-
* ```js
|
|
13066
|
-
* const myLayoutContainer = document.getElementById('layout-container');
|
|
13067
|
-
*
|
|
13068
|
-
* myLayoutContainer.addEventListener('tab-created', function(event) {
|
|
13069
|
-
* const { tabSelector } = event.detail;
|
|
13070
|
-
* const tabElement = document.getElementById(tabSelector);
|
|
13071
|
-
* const existingColor = tabElement.style.backgroundColor;
|
|
13072
|
-
* tabElement.style.backgroundColor = "red";
|
|
13073
|
-
* setTimeout(() => {
|
|
13074
|
-
* tabElement.style.backgroundColor = existingColor;
|
|
13075
|
-
* }, 2000);
|
|
13076
|
-
* });
|
|
13077
|
-
* ```
|
|
13078
|
-
*
|
|
13079
|
-
* #### {@link https://developer.mozilla.org/en-US/docs/Web/API/EventTarget/removeEventListener removeEventListener(type, listener [, options]);}
|
|
13080
|
-
* Adds a listener to the end of the listeners array for the specified event.
|
|
13081
|
-
* @example
|
|
13082
|
-
* ```js
|
|
13083
|
-
* const myLayoutContainer = document.getElementById('layout-container');
|
|
13084
|
-
*
|
|
13085
|
-
* const listener = function(event) {
|
|
13086
|
-
* console.log(event.detail);
|
|
13087
|
-
* console.log('container-created event fired once, removing listener');
|
|
13088
|
-
* myLayoutContainer.removeEventListener('container-created', listener);
|
|
13089
|
-
* };
|
|
13090
|
-
*
|
|
13091
|
-
* myLayoutContainer.addEventListener('container-created', listener);
|
|
13092
|
-
* ```
|
|
13093
|
-
*
|
|
13094
|
-
* ### Supported event types are:
|
|
13095
|
-
*
|
|
13096
|
-
* * tab-created
|
|
13097
|
-
* * container-created
|
|
13098
|
-
* * layout-state-changed
|
|
13099
|
-
* * tab-closed
|
|
13100
|
-
* * tab-dropped
|
|
13101
|
-
*
|
|
13102
|
-
* ### Layout DOM Node Events
|
|
13103
|
-
*
|
|
13104
|
-
* #### tab-created
|
|
13105
|
-
* Generated when a tab is created. As a user drags and drops tabs within window, new tabs are created. A single view may have multiple tabs created and destroyed during its lifetime attached to a single window.
|
|
13106
|
-
* ```js
|
|
13107
|
-
* // The response has the following shape in event.detail:
|
|
13108
|
-
* {
|
|
13109
|
-
* containerSelector: "container-component_A",
|
|
13110
|
-
* name: "component_A",
|
|
13111
|
-
* tabSelector: "tab-component_A",
|
|
13112
|
-
* topic: "openfin-DOM-event",
|
|
13113
|
-
* type: "tab-created",
|
|
13114
|
-
* uuid: "OpenFin POC"
|
|
13115
|
-
* }
|
|
13116
|
-
* ```
|
|
13117
|
-
*
|
|
13118
|
-
* #### container-created
|
|
13119
|
-
* Generated when a container is created. A single view will have only one container during its lifetime attached to a single window and the container's lifecycle is tied to the view. To discover when the container is destroyed, please listen to view-detached event.
|
|
13120
|
-
* ```js
|
|
13121
|
-
* // The response has the following shape in event.detail:
|
|
13122
|
-
* {
|
|
13123
|
-
* containerSelector: "container-component_A",
|
|
13124
|
-
* name: "component_A",
|
|
13125
|
-
* tabSelector: "tab-component_A",
|
|
13126
|
-
* topic: "openfin-DOM-event",
|
|
13127
|
-
* type: "container-created",
|
|
13128
|
-
* uuid: "OpenFin POC"
|
|
13129
|
-
* }
|
|
13130
|
-
* ```
|
|
13131
|
-
*
|
|
13132
|
-
* ### layout-state-changed
|
|
13133
|
-
* Generated when the state of the layout changes in any way, such as a view added/removed/replaced. Note that this event can fire frequently as the underlying layout can change multiple components from all kinds of changes (resizing for example). Given this, it is recommended to debounce this event and then you can use the {@link Layout#getConfig Layout.getConfig} API to retrieve the most up-to-date state.
|
|
13134
|
-
* ```js
|
|
13135
|
-
* // The response has the following shape in event.detail
|
|
13136
|
-
* {
|
|
13137
|
-
* containerSelector: "container-component_A",
|
|
13138
|
-
* name: "component_A",
|
|
13139
|
-
* tabSelector: "tab-component_A",
|
|
13140
|
-
* topic: "openfin-DOM-event",
|
|
13141
|
-
* type: "layout-state-changed",
|
|
13142
|
-
* uuid: "OpenFin POC"
|
|
13143
|
-
* }
|
|
13144
|
-
* ```
|
|
13145
|
-
*
|
|
13146
|
-
* #### tab-closed
|
|
13147
|
-
* Generated when a tab is closed.
|
|
13148
|
-
* ```js
|
|
13149
|
-
* // The response has the following shape in event.detail:
|
|
13150
|
-
* {
|
|
13151
|
-
* containerSelector: "container-component_A",
|
|
13152
|
-
* name: "component_A",
|
|
13153
|
-
* tabSelector: "tab-component_A",
|
|
13154
|
-
* topic: "openfin-DOM-event",
|
|
13155
|
-
* type: "tab-closed",
|
|
13156
|
-
* uuid: "OpenFin POC",
|
|
13157
|
-
* url: "http://openfin.co" // The url of the view that was closed.
|
|
13158
|
-
* }
|
|
13159
|
-
* ```
|
|
13160
|
-
*
|
|
13161
|
-
* #### tab-dropped
|
|
13162
|
-
* Generated when a tab is dropped.
|
|
13163
|
-
* ```js
|
|
13164
|
-
* // The response has the following shape in event.detail:
|
|
13165
|
-
* {
|
|
13166
|
-
* containerSelector: "container-component_A",
|
|
13167
|
-
* name: "component_A",
|
|
13168
|
-
* tabSelector: "tab-component_A",
|
|
13169
|
-
* topic: "openfin-DOM-event",
|
|
13170
|
-
* type: "tab-dropped",
|
|
13171
|
-
* uuid: "OpenFin POC",
|
|
13172
|
-
* url: "http://openfin.co" // The url of the view linked to the dropped tab.
|
|
13173
|
-
* }
|
|
13174
|
-
* ```
|
|
13175
13205
|
*/
|
|
13176
13206
|
var __createBinding = (commonjsGlobal && commonjsGlobal.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
13177
13207
|
if (k2 === undefined) k2 = k;
|
|
@@ -13197,6 +13227,9 @@ Factory$3.PlatformModule = void 0;
|
|
|
13197
13227
|
const base_1$4 = base;
|
|
13198
13228
|
const Instance_1$1 = Instance$2;
|
|
13199
13229
|
const index_1$1 = layout;
|
|
13230
|
+
/**
|
|
13231
|
+
* Static namespace for OpenFin API methods that interact with the {@link Platform} class, available under `fin.Platform`.
|
|
13232
|
+
*/
|
|
13200
13233
|
class PlatformModule extends base_1$4.Base {
|
|
13201
13234
|
/**
|
|
13202
13235
|
* @internal
|
|
@@ -16575,6 +16608,9 @@ Factory.SnapshotSourceModule = void 0;
|
|
|
16575
16608
|
const base_1 = base;
|
|
16576
16609
|
const Instance_1 = Instance;
|
|
16577
16610
|
const utils_1 = utils;
|
|
16611
|
+
/**
|
|
16612
|
+
* Static namespace for OpenFin API methods that interact with the {@link SnapshotSource} class, available under `fin.SnapshotSource`.
|
|
16613
|
+
*/
|
|
16578
16614
|
class SnapshotSourceModule extends base_1.Base {
|
|
16579
16615
|
/**
|
|
16580
16616
|
* Initializes a SnapshotSource with the getSnapshot and applySnapshot methods defined.
|
|
@@ -16651,7 +16687,7 @@ Factory.SnapshotSourceModule = SnapshotSourceModule;
|
|
|
16651
16687
|
* Entry points for the OpenFin `SnapshotSource` API.
|
|
16652
16688
|
*
|
|
16653
16689
|
* * {@link SnapshotSourceModule} contains static methods relating to the `SnapshotSource` type, accessible through `fin.SnapshotSource`.
|
|
16654
|
-
* * {@link SnapshotSource} describes an instance of an OpenFin SnapshotSource, e.g. as returned by `fin.SnapshotSource.
|
|
16690
|
+
* * {@link SnapshotSource} describes an instance of an OpenFin SnapshotSource, e.g. as returned by `fin.SnapshotSource.wrap`.
|
|
16655
16691
|
*
|
|
16656
16692
|
* These are separate code entities, and are documented separately. In the [previous version of the API documentation](https://cdn.openfin.co/docs/javascript/canary/index.html),
|
|
16657
16693
|
* both of these were documented on the same page.
|