@openfin/node-adapter 35.78.6 → 35.78.8

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.
@@ -43,6 +43,8 @@ declare type Accelerator = {
43
43
  };
44
44
 
45
45
  /**
46
+ * Options to use when adding a view to a {@link TabStack}.
47
+ *
46
48
  * @interface
47
49
  */
48
50
  declare type AddViewOptions = CreateViewTarget & {
@@ -94,6 +96,10 @@ declare type Api = {
94
96
  sameOriginInjection?: boolean;
95
97
  enableDeprecatedSharedName?: boolean;
96
98
  };
99
+ /**
100
+ * Prevent fin API injection. If 'none', `fin` won't be available in this context.
101
+ */
102
+ fin?: InjectionType;
97
103
  };
98
104
 
99
105
  declare type ApiCall<Request, Response> = {
@@ -193,100 +199,6 @@ declare class Application extends EmitterBase<OpenFin.ApplicationEvent> {
193
199
  */
194
200
  constructor(wire: Transport, identity: OpenFin.ApplicationIdentity);
195
201
  private windowListFromIdentityList;
196
- /**
197
- * Adds a listener to the end of the listeners array for the specified event.
198
- * @param eventType - The type of the event.
199
- * @param listener - Called whenever an event of the specified type occurs.
200
- * @param options - Option to support event timestamps.
201
- *
202
- * @function addListener
203
- * @memberof Application
204
- * @instance
205
- * @tutorial Application.EventEmitter
206
- */
207
- /**
208
- * Adds a listener to the end of the listeners array for the specified event.
209
- * @param eventType - The type of the event.
210
- * @param listener - Called whenever an event of the specified type occurs.
211
- * @param options - Option to support event timestamps.
212
- *
213
- * @function on
214
- * @memberof Application
215
- * @instance
216
- * @tutorial Application.EventEmitter
217
- */
218
- /**
219
- * Adds a one time listener for the event. The listener is invoked only the first time the event is fired, after which it is removed.
220
- * @param eventType - The type of the event.
221
- * @param listener - The callback function.
222
- * @param options - Option to support event timestamps.
223
- *
224
- * @function once
225
- * @memberof Application
226
- * @instance
227
- * @tutorial Application.EventEmitter
228
- */
229
- /**
230
- * Adds a listener to the beginning of the listeners array for the specified event.
231
- * @param eventType - The type of the event.
232
- * @param listener - The callback function.
233
- * @param options - Option to support event timestamps.
234
- *
235
- * @function prependListener
236
- * @memberof Application
237
- * @instance
238
- * @tutorial Application.EventEmitter
239
- */
240
- /**
241
- * Adds a one time listener for the event. The listener is invoked only the first time the event is fired, after which it is removed.
242
- * The listener is added to the beginning of the listeners array.
243
- * @param eventType - The type of the event.
244
- * @param listener - The callback function.
245
- * @param options - Option to support event timestamps.
246
- *
247
- * @function prependOnceListener
248
- * @memberof Application
249
- * @instance
250
- * @tutorial Application.EventEmitter
251
- */
252
- /**
253
- * Remove a listener from the listener array for the specified event.
254
- * Caution: Calling this method changes the array indices in the listener array behind the listener.
255
- * @param eventType - The type of the event.
256
- * @param listener - The callback function.
257
- * @param options - Option to support event timestamps.
258
- *
259
- * @function removeListener
260
- * @memberof Application
261
- * @instance
262
- * @tutorial Application.EventEmitter
263
- */
264
- /**
265
- * Removes all listeners, or those of the specified event.
266
- * @param eventType - The type of the event.
267
- *
268
- * @function removeAllListeners
269
- * @memberof Application
270
- * @instance
271
- * @tutorial Application.EventEmitter
272
- */
273
- /**
274
- * JumpListCategory interface
275
- * @typedef { object } JumpListCategory@typedef { object } JumpListCategory
276
- * @property { string } name The display title for the category. If omitted, items in this category will be placed into the standard 'Tasks' category. There can be only one such category, and it will always be displayed at the bottom of the JumpList.
277
- * @property { JumpListItem[] } items Array of JumpListItem objects
278
- */
279
- /**
280
- * @PORTED
281
- * JumpListItem interface
282
- * @typedef { object } JumpListItem@typedef { object } JumpListItem
283
- * @property { string } type One of the following: "task" or "separator". Defaults to task.
284
- * @property { string } title The text to be displayed for the JumpList Item. Should only be set if type is "task".
285
- * @property { string } description Description of the task (displayed in a tooltip). Should only be set if type is "task".
286
- * @property { string } deepLink Deep link to a manifest, i.e: fins://path.to/manifest.json?$$param1=value1. See {@link https://developers.openfin.co/docs/deep-linking deep-linking} for more information.
287
- * @property { string } iconPath The absolute path to an icon to be displayed for the item, which can be an arbitrary resource file that contains an icon (e.g. .ico, .exe, .dll).
288
- * @property { number } iconIndex The index of the icon in the resource file. If a resource file contains multiple icons this value can be used to specify the zero-based index of the icon that should be displayed for this task. If a resource file contains only one icon, this property should be set to zero.
289
- */
290
202
  /**
291
203
  * Determines if the application is currently running.
292
204
  *
@@ -933,6 +845,7 @@ declare namespace ApplicationEvents {
933
845
  RespondingEvent,
934
846
  StartedEvent,
935
847
  ApplicationSourcedEvent,
848
+ ApplicationSourcedEventType,
936
849
  Event_3 as Event,
937
850
  ApplicationEvent,
938
851
  EventType_3 as EventType,
@@ -1305,6 +1218,11 @@ declare type ApplicationPermissions = {
1305
1218
  */
1306
1219
  declare type ApplicationSourcedEvent = ClosedEvent | ConnectedEvent_2 | CrashedEvent | InitializedEvent | ManifestChangedEvent | NotRespondingEvent | RespondingEvent | RunRequestedEvent_2 | StartedEvent | TrayIconClickedEvent | FileDownloadLocationChangedEvent;
1307
1220
 
1221
+ /**
1222
+ * Union of possible type values for an {@link ApplicationSourcedEvent}.
1223
+ */
1224
+ declare type ApplicationSourcedEventType = ApplicationSourcedEvent['type'];
1225
+
1308
1226
  declare type ApplicationState = OpenFin.ApplicationState;
1309
1227
 
1310
1228
  /**
@@ -3142,20 +3060,6 @@ declare type ClientInfo = Omit<ClientIdentity, 'isLocalEndpointId'> & {
3142
3060
  connectionUrl: string;
3143
3061
  };
3144
3062
 
3145
- /**
3146
- * @PORTED
3147
- * WriteRequestType interface
3148
- * @typedef { object } WriteRequestType@typedef { object } WriteRequestType
3149
- * @property { string } data Data to be written
3150
- * @property { string } [type] Clipboard Type
3151
- */
3152
- /**
3153
- * @PORTED
3154
- * OpenFin.WriteAnyClipboardRequest interface
3155
- * @typedef { object } OpenFin.WriteAnyClipboardRequest@typedef { object } OpenFin.WriteAnyClipboardRequest
3156
- * @property { string } data Data to be written
3157
- * @property { OpenFin.ClipboardSelectionType } [type] Clipboard Type defaults to 'clipboard', use 'selection' for linux
3158
- */
3159
3063
  /**
3160
3064
  * The Clipboard API allows reading and writing to the clipboard in multiple formats.
3161
3065
  *
@@ -3411,57 +3315,6 @@ declare type ClosingEvent = BaseEvent_5 & {
3411
3315
  */
3412
3316
  declare class ColumnOrRow extends LayoutNode {
3413
3317
  #private;
3414
- /**
3415
- * Determines if this {@link ColumnOrRow} is the top level content item in the current layout.
3416
- * @function isRoot
3417
- * @memberof ColumnOrRow
3418
- * @instance
3419
- * @tutorial ColumnOrRow.isRoot
3420
- * @returns Resolves true if this TabStack is the top level content item, or false if it is not.
3421
- */
3422
- /**
3423
- * Determines if this {@link ColumnOrRow} exists.
3424
- * @function exists
3425
- * @instance
3426
- * @memberof ColumnOrRow
3427
- * @tutorial ColumnOrRow.exists
3428
- * @returns Resolves true if the TabStack exists, or false if it has been destroyed.
3429
- */
3430
- /**
3431
- * Retrieves the parent {@link ColumnOrRow} of this {@link ColumnOrRow}, if one exists.
3432
- * @function getParent
3433
- * @instance
3434
- * @memberof ColumnOrRow
3435
- * @tutorial ColumnOrRow.getParent
3436
- * @returns Promise resolving with the {@link ColumnOrRow} that contains this item, or undefined if
3437
- * this {@link ColumnOrRow}does not exist or is the root content item.
3438
- */
3439
- /**
3440
- * Returns all the adjacent stacks that share an edge with the given {@link ColumnOrRow}.
3441
- * @function getAdjacentStacks
3442
- * @instance
3443
- * @memberof ColumnOrRow
3444
- * @param {LayoutPosition} edge - Edge to check for any adjacent stacks.
3445
- *
3446
- * @tutorial ColumnOrRow.getAdjacentStacks
3447
- */
3448
- /**
3449
- * Given a list of view creation options or references and a layout position, creates a {@link TabStack} adjacent to the given {@link ColumnOrRow}
3450
- *
3451
- * Known Issue: If the number of views to add overflows the tab-container, the added views will be set as active
3452
- * during each render, and then placed at the front of the tab-stack, while the underlying order of tabs will remain unchanged.
3453
- * This means the views you pass to createAdjacentStack() may not render in the order given by the array.
3454
- * Until fixed, this problem can be avoided only if your window is wide enough to fit creating all the views in the tabstack.
3455
- *
3456
- * @function createAdjacentStack
3457
- * @instance
3458
- * @memberof ColumnOrRow
3459
- * @param views - List of identities or view creation options of the views to include in the stack
3460
- * @param options - Creation options.
3461
- * @returns The created TabStack
3462
- * @tutorial ColumnOrRow.createAdjacentStack
3463
- * @experimental
3464
- */
3465
3318
  /**
3466
3319
  * @internal
3467
3320
  */
@@ -3586,6 +3439,10 @@ declare type ConstructorOverride<T> = (Base: Constructor<T>) => Constructor<T>;
3586
3439
  * @interface
3587
3440
  */
3588
3441
  declare type ConstViewOptions = {
3442
+ /**
3443
+ * Configurations for API injection.
3444
+ */
3445
+ api: Api;
3589
3446
  /**
3590
3447
  * The name of the view.
3591
3448
  */
@@ -3734,7 +3591,7 @@ declare type ConstWindowOptions = {
3734
3591
  /**
3735
3592
  * @defaultValue true
3736
3593
  *
3737
- * Toggling off would keep the Window alive even if all its Views were closed.
3594
+ * Setting this to false would keep the Window alive even if all its Views were closed.
3738
3595
  * This is meant for advanced users and should be used with caution.
3739
3596
  * Limitations - Once a Layout has been emptied out of all views it's not usable anymore, and certain API calls will fail.
3740
3597
  * Use `layout.replace` to create a fresh Layout instance in case you want to populate it with Views again.
@@ -3744,7 +3601,8 @@ declare type ConstWindowOptions = {
3744
3601
  /**
3745
3602
  * @defaultValue 'all'
3746
3603
  *
3747
- * Determines which views prevent close if `closeOnLastViewRemoved` is set to true. Defaults to `all`. You may want to switch this to `layout` if using View closeBehavior: 'hide'.
3604
+ * When `closeOnLastViewRemoved` is set to true, determines which views prevent closing the window.
3605
+ + * Defaults to `all`. You may want to switch this to `layout` if using View closeBehavior: 'hide'.
3748
3606
  * **NOTE:** - This option is ignored in non-Platforms apps.
3749
3607
  */
3750
3608
  viewsPreventingClose: 'all' | 'layout';
@@ -4551,7 +4409,7 @@ declare type CreateViewPayload = {
4551
4409
  /**
4552
4410
  * @interface
4553
4411
  */
4554
- declare type CreateViewTarget = LayoutIdentity & {
4412
+ declare type CreateViewTarget = (Identity_5 | LayoutIdentity) & {
4555
4413
  /**
4556
4414
  * If specified, view creation will not attach to a window and caller must
4557
4415
  * insert the view into the layout explicitly
@@ -4691,6 +4549,14 @@ declare type DestroyedEvent = BaseEvent_4 & {
4691
4549
  type: 'destroyed';
4692
4550
  };
4693
4551
 
4552
+ /**
4553
+ * @interface
4554
+ */
4555
+ declare type DeviceInfo = {
4556
+ vendorId: string | number;
4557
+ productId: string | number;
4558
+ };
4559
+
4694
4560
  /**
4695
4561
  * Generated when a page's theme color changes. This is usually due to encountering a meta tag.
4696
4562
  * @interface
@@ -4932,7 +4798,7 @@ declare type DownloadShelfOptions = {
4932
4798
  */
4933
4799
  size?: number;
4934
4800
  /**
4935
- * Color of the border, either a string name or a hex code. Defaults to chromium theme
4801
+ * Color of the border. Must be a 6-character hex code prefixed by #. Defaults to chromium theme
4936
4802
  * if absent.
4937
4803
  */
4938
4804
  color?: string;
@@ -5156,9 +5022,10 @@ declare type EntityTypeHelpers<T extends EntityType_2> = T extends 'view' ? {
5156
5022
  } : never;
5157
5023
 
5158
5024
  declare interface Environment {
5159
- initLayout(fin: OpenFin.Fin<OpenFin.EntityType>, wire: Transport, options: OpenFin.InitLayoutOptions): Promise<OpenFin.LayoutManager<OpenFin.LayoutSnapshot>>;
5025
+ initLayoutManager(fin: OpenFin.Fin<OpenFin.EntityType>, wire: Transport, options: OpenFin.InitLayoutOptions): Promise<OpenFin.LayoutManager<OpenFin.LayoutSnapshot>>;
5160
5026
  createLayout(layoutManager: OpenFin.LayoutManager<OpenFin.LayoutSnapshot>, options: OpenFin.CreateLayoutOptions): Promise<void>;
5161
5027
  destroyLayout(layoutManager: OpenFin.LayoutManager<OpenFin.LayoutSnapshot>, layoutIdentity: OpenFin.LayoutIdentity): Promise<void>;
5028
+ resolveLayout(layoutManager: OpenFin.LayoutManager<OpenFin.LayoutSnapshot>, layoutIdentity: OpenFin.LayoutIdentity): Promise<any>;
5162
5029
  initPlatform(fin: OpenFin.Fin<OpenFin.EntityType>, ...args: Parameters<OpenFin.Fin['Platform']['init']>): ReturnType<OpenFin.Fin['Platform']['init']>;
5163
5030
  observeBounds(element: Element, onChange: (bounds: DOMRect) => Promise<void> | void): () => void;
5164
5031
  writeToken(path: string, token: string): Promise<string>;
@@ -5380,7 +5247,7 @@ declare type EventType_7 = Event_10['type'];
5380
5247
  /**
5381
5248
  * Union of possible `type` values for a {@link SystemEvent}.
5382
5249
  */
5383
- declare type EventType_8 = SystemEvent['type'];
5250
+ declare type EventType_8 = Event_11['type'];
5384
5251
 
5385
5252
  /**
5386
5253
  * @internal
@@ -5433,83 +5300,6 @@ declare class ExternalApplication extends EmitterBase<OpenFin.ExternalApplicatio
5433
5300
  * @internal
5434
5301
  */
5435
5302
  constructor(wire: Transport, identity: OpenFin.ApplicationIdentity);
5436
- /**
5437
- * Adds a listener to the end of the listeners array for the specified event.
5438
- * @param eventType - The type of the event.
5439
- * @param listener - Called whenever an event of the specified type occurs.
5440
- * @param options - Option to support event timestamps.
5441
- *
5442
- * @function addListener
5443
- * @memberof ExternalApplication
5444
- * @instance
5445
- * @tutorial ExternalApplication.EventEmitter
5446
- */
5447
- /**
5448
- * Adds a listener to the end of the listeners array for the specified event.
5449
- * @param eventType - The type of the event.
5450
- * @param listener - Called whenever an event of the specified type occurs.
5451
- * @param options - Option to support event timestamps.
5452
- *
5453
- * @function on
5454
- * @memberof ExternalApplication
5455
- * @instance
5456
- * @tutorial ExternalApplication.EventEmitter
5457
- */
5458
- /**
5459
- * Adds a one time listener for the event. The listener is invoked only the first time the event is fired, after which it is removed.
5460
- * @param eventType - The type of the event.
5461
- * @param listener - The callback function.
5462
- * @param options - Option to support event timestamps.
5463
- *
5464
- * @function once
5465
- * @memberof ExternalApplication
5466
- * @instance
5467
- * @tutorial ExternalApplication.EventEmitter
5468
- */
5469
- /**
5470
- * Adds a listener to the beginning of the listeners array for the specified event.
5471
- * @param eventType - The type of the event.
5472
- * @param listener - The callback function.
5473
- * @param options - Option to support event timestamps.
5474
- *
5475
- * @function prependListener
5476
- * @memberof ExternalApplication
5477
- * @instance
5478
- * @tutorial ExternalApplication.EventEmitter
5479
- */
5480
- /**
5481
- * Adds a one time listener for the event. The listener is invoked only the first time the event is fired, after which it is removed.
5482
- * The listener is added to the beginning of the listeners array.
5483
- * @param eventType - The type of the event.
5484
- * @param listener - The callback function.
5485
- * @param options - Option to support event timestamps.
5486
- *
5487
- * @function prependOnceListener
5488
- * @memberof ExternalApplication
5489
- * @instance
5490
- * @tutorial ExternalApplication.EventEmitter
5491
- */
5492
- /**
5493
- * Remove a listener from the listener array for the specified event.
5494
- * Caution: Calling this method changes the array indices in the listener array behind the listener.
5495
- * @param eventType - The type of the event.
5496
- * @param listener - The callback function.
5497
- * @param options - Option to support event timestamps.
5498
- *
5499
- * @function removeListener
5500
- * @memberof ExternalApplication
5501
- * @instance
5502
- * @tutorial ExternalApplication.EventEmitter
5503
- */
5504
- /**
5505
- * Removes all listeners, or those of the specified event.
5506
- * @param eventType - The type of the event.
5507
- *
5508
- * @function removeAllListeners
5509
- * @memberof ExternalApplication
5510
- * @instance
5511
- * @tutorial ExternalApplication.EventEmitter
5512
- */
5513
5303
  /**
5514
5304
  * Retrieves information about the external application.
5515
5305
  *
@@ -5954,83 +5744,6 @@ declare class _Frame extends EmitterBase<OpenFin.FrameEvent> {
5954
5744
  * @internal
5955
5745
  */
5956
5746
  constructor(wire: Transport, identity: OpenFin.Identity);
5957
- /**
5958
- * Adds the listener function to the end of the listeners array for the specified event type.
5959
- * @param eventType - The type of the event.
5960
- * @param listener - Called whenever an event of the specified type occurs.
5961
- * @param options - Option to support event timestamps.
5962
- *
5963
- * @function addListener
5964
- * @memberof Frame
5965
- * @instance
5966
- * @tutorial Frame.EventEmitter
5967
- */
5968
- /**
5969
- * Adds a listener to the end of the listeners array for the specified event.
5970
- * @param eventType - The type of the event.
5971
- * @param listener - Called whenever an event of the specified type occurs.
5972
- * @param options - Option to support event timestamps.
5973
- *
5974
- * @function on
5975
- * @memberof Frame
5976
- * @instance
5977
- * @tutorial Frame.EventEmitter
5978
- */
5979
- /**
5980
- * Adds a one time listener for the event. The listener is invoked only the first time the event is fired, after which it is removed.
5981
- * @param eventType - The type of the event.
5982
- * @param listener - The callback function.
5983
- * @param options - Option to support event timestamps.
5984
- *
5985
- * @function once
5986
- * @memberof Frame
5987
- * @instance
5988
- * @tutorial Frame.EventEmitter
5989
- */
5990
- /**
5991
- * Adds a listener to the beginning of the listeners array for the specified event.
5992
- * @param eventType - The type of the event.
5993
- * @param listener - The callback function.
5994
- * @param options - Option to support event timestamps.
5995
- *
5996
- * @function prependListener
5997
- * @memberof Frame
5998
- * @instance
5999
- * @tutorial Frame.EventEmitter
6000
- */
6001
- /**
6002
- * Adds a one time listener for the event. The listener is invoked only the first time the event is fired, after which it is removed.
6003
- * The listener is added to the beginning of the listeners array.
6004
- * @param eventType - The type of the event.
6005
- * @param listener - The callback function.
6006
- * @param options - Option to support event timestamps.
6007
- *
6008
- * @function prependOnceListener
6009
- * @memberof Frame
6010
- * @instance
6011
- * @tutorial Frame.EventEmitter
6012
- */
6013
- /**
6014
- * Remove a listener from the listener array for the specified event.
6015
- * Caution: Calling this method changes the array indices in the listener array behind the listener.
6016
- * @param eventType - The type of the event.
6017
- * @param listener - The callback function.
6018
- * @param options - Option to support event timestamps.
6019
- *
6020
- * @function removeListener
6021
- * @memberof Frame
6022
- * @instance
6023
- * @tutorial Frame.EventEmitter
6024
- */
6025
- /**
6026
- * Removes all listeners, or those of the specified event.
6027
- * @param eventType - The type of the event.
6028
- *
6029
- * @function removeAllListeners
6030
- * @memberof Frame
6031
- * @instance
6032
- * @tutorial Frame.EventEmitter
6033
- */
6034
5747
  /**
6035
5748
  * Returns a frame info object for the represented frame.
6036
5749
  *
@@ -6955,6 +6668,8 @@ declare type InitPlatformOptions = {
6955
6668
  interopOverride?: OverrideCallback<InteropBroker> | ConstructorOverride<InteropBroker>[];
6956
6669
  };
6957
6670
 
6671
+ declare type InjectionType = 'none' | 'global';
6672
+
6958
6673
  /**
6959
6674
  * Generated when the value of the element changes.
6960
6675
  * @interface
@@ -7314,56 +7029,6 @@ declare class InteropBroker extends Base {
7314
7029
  static createClosedConstructor(...args: ConstructorParameters<typeof InteropBroker>): {
7315
7030
  new (): InteropBroker;
7316
7031
  };
7317
- /**
7318
- * @REMOVED
7319
- * SetContextOptions interface
7320
- * @typedef { object } SetContextOptions@typedef { object } SetContextOptions
7321
- * @property { Context } {context} - New context to set.
7322
- */
7323
- /**
7324
- * @REMOVED
7325
- * GetContextOptions interface
7326
- * @typedef { object } GetContextOptions@typedef { object } GetContextOptions
7327
- * @property { string } [contextType] - Context Type
7328
- */
7329
- /**
7330
- * @REMOVED
7331
- * JoinContextGroupOptions interface
7332
- * @typedef { object } JoinContextGroupOptions@typedef { object } JoinContextGroupOptions
7333
- * @property { string } contextGroupId - Id of the context group.
7334
- * @property { Identity | ClientIdentity } [target] - Identity of the entity you wish to join to a context group.
7335
- */
7336
- /**
7337
- * @REMOVED
7338
- * AddClientToContextGroupOptions interface
7339
- * @typedef { object } AddClientToContextGroupOptions@typedef { object } AddClientToContextGroupOptions
7340
- * @property { string } contextGroupId - Name of the context group.
7341
- */
7342
- /**
7343
- * @REMOVED
7344
- * RemoveFromContextGroupOptions interface
7345
- * @typedef { object } RemoveFromContextGroupOptions@typedef { object } RemoveFromContextGroupOptions
7346
- * @property { Identity | ClientIdentity } target - Identity of the entity you wish to join to a context group.
7347
- */
7348
- /**
7349
- * @REMOVED
7350
- * GetInfoForContextGroupOptions interface
7351
- * @typedef { object } GetInfoForContextGroupOptions@typedef { object } GetInfoForContextGroupOptions
7352
- * @property { string } contextGroupId - Name of the context group to get info for.
7353
- */
7354
- /**
7355
- * @REMOVED
7356
- * GetAllClientsInContextGroupOptions interface
7357
- * @typedef { object } GetAllClientsInContextGroupOptions@typedef { object } GetAllClientsInContextGroupOptions
7358
- * @property { string } contextGroupId - Name of the context group to get info for.
7359
- */
7360
- /**
7361
- * @PORTED
7362
- * InfoForIntentOptions interface
7363
- * @typedef { object } InfoForIntentOptions@typedef { object } InfoForIntentOptions
7364
- * @property { string } name Name of the intent to get info for.
7365
- * @property { Context } [context] Optional context.
7366
- */
7367
7032
  /**
7368
7033
  * Sets a context for the context group of the incoming current entity.
7369
7034
  * @param setContextOptions - New context to set.
@@ -7607,7 +7272,7 @@ declare class InteropBroker extends Base {
7607
7272
  * // }
7608
7273
  * ```
7609
7274
  *
7610
- * More information on the IntentResolution type can be found in the [FDC3 documentation](https://fdc3.finos.org/docs/api/ref/IntentResolution).
7275
+ * More information on the IntentResolution type can be found in the [FDC3 documentation](https://fdc3.finos.org/docs/api/ref/Metadata#intentresolution).
7611
7276
  *
7612
7277
  * @param contextForIntent Data passed between entities and applications.
7613
7278
  * @param clientIdentity Identity of the Client making the request.
@@ -7863,95 +7528,6 @@ declare type InteropBrokerOptions = {
7863
7528
  logging?: InteropLoggingOptions;
7864
7529
  };
7865
7530
 
7866
- /**
7867
- * @PORTED
7868
- * @typedef { object } Intent
7869
- * @summary The combination of an action and a context that is passed to an application for resolution.
7870
- * @property { string } name Name of the intent.
7871
- * @property { Context } context Data associated with the intent
7872
- */
7873
- /**
7874
- * @REMOVED
7875
- * @typedef { object } Subscription
7876
- * @summary Object returned when subscribing a handler.
7877
- * @property { function } unsubscribe Function to unsubscribe the handler.
7878
- */
7879
- /**
7880
- * @typedef { function } ContextHandler
7881
- * @summary Subscription function for addContextHandler.
7882
- */
7883
- /**
7884
- * @typedef { function } IntentHandler
7885
- * @summary Subscription function for registerIntentHandler
7886
- */
7887
- /**
7888
- * @PORTED
7889
- * @typedef { object } ClientIdentity
7890
- * @summary The Identity for a Channel Client. Includes endpointId to differentiate between different connections for an entity.
7891
- * @property {string} uuid GUID of an application.
7892
- * @property {string} name Name of an entity in an application.
7893
- * @property {string} endpointId Unique differentiator for different Channel connections for an entity.
7894
- */
7895
- /**
7896
- * @PORTED
7897
- * @typedef { object } ContextGroupInfo
7898
- * @summary Information for a Context Group. Contains metadata for displaying the group properly.
7899
- * @property {string} id Name of the context group
7900
- * @property {DisplayMetadata} displayMetadata Metadata for the Context Group. Contains the group's human-readable name, color, and an image, as defined by the Interop Broker.
7901
- */
7902
- /**
7903
- * @PORTED
7904
- * @typedef { object } DisplayMetadata
7905
- * @summary The display data for a Context Group.
7906
- * @property {string} name A user-readable name for this context group, e.g: `"Red"`
7907
- * @property {string} [color] The color that should be associated within this context group when displaying this context group in a UI, e.g: `0xFF0000`.
7908
- * @property {string} [glyph] A URL of an image that can be used to display this context group
7909
- */
7910
- /**
7911
- * @PORTED
7912
- * @typedef { object } Context
7913
- * @summary Data passed between entities and applications.
7914
- * @property {object} [id] An object containing string key-value pairs for the bulk of the data for the context. Differs between context types.
7915
- * @property {string} [name] User-readable name for the incoming context.
7916
- * @property {string} type Conserved type for the context (e.g. `instrument` or `country`)
7917
- */
7918
- /**
7919
- * @REMOVED
7920
- * @typedef { object } ContextForIntent
7921
- * @summary Data passed between entities and applications, including an optional metadata.
7922
- * @property {object} [id] An object containing string key-value pairs for the bulk of the data for the context. Differs between context types.
7923
- * @property {string} [name] User-readable name for the incoming context.
7924
- * @property {string} type Conserved type for the context (e.g. `instrument` or `country`)
7925
- * @property {any} [metadata]
7926
- */
7927
- /**
7928
- * @REMOVED
7929
- * @typedef { object } SessionContextGroup
7930
- * @summary An instance of a SessionContextGroup
7931
- * @property {string} id The SessionContextGroup's id.
7932
- * @property {setContext} setContext Sets a context of a certain type
7933
- * @property {getCurrentContext} getCurrentContext Gets the currently set context of a certain type
7934
- * @property {addContextHandler} addContextHandler Adds a handler for context change.
7935
- */
7936
- /**
7937
- * @typedef {function} setContext
7938
- * @summary A SessionContextGroup instance method for setting a context in the SessionContextGroup.
7939
- * @param context The Context to be set.
7940
- *
7941
- */
7942
- /**
7943
- * @typedef {function} getCurrentContext
7944
- * @summary A SessionContextGroup instance method for getting the current context of a certain type.
7945
- * @param contextType The Context Type to get. If not specified the last contextType set would get used.
7946
- *
7947
- */
7948
- /**
7949
- * @typedef {function} addContextHandler
7950
- * @summary A SessionContextGroup instance method for adding a handler for context change.
7951
- * @param contextHandler The callback to be invoked. Is invoked when (a) the context changes or (b) immediately after getting created if the context is already set.
7952
- * @param contextType The context type this handler should listen to. If not specified, a global handler for all context types will get created. Only one global handler is allowed per SessionContextGroup.
7953
- *
7954
- */
7955
7531
  /**
7956
7532
  * {@link https://developers.openfin.co/of-docs/docs/enable-color-linking}
7957
7533
  *
@@ -8390,13 +7966,6 @@ declare type InteropLoggingActions = 'beforeAction' | 'afterAction';
8390
7966
  */
8391
7967
  declare type InteropLoggingOptions = Record<InteropLoggingActions, InteropActionLoggingOption>;
8392
7968
 
8393
- /**
8394
- * @PORTED
8395
- * @typedef { object } InteropConfig
8396
- * @summary Information relevant to the Interop Broker.
8397
- * @property {string} [currentContextGroup] Context Group for the client. (green, yellow, red, etc.)
8398
- * @property {string} [providerId] When provided, automatically connects the client to the specified provider uuid
8399
- */
8400
7969
  /**
8401
7970
  * Manages creation of Interop Brokers and Interop Clients. These APIs are called under-the-hood in Platforms.
8402
7971
  *
@@ -8789,7 +8358,7 @@ declare class Layout extends Base {
8789
8358
  * @internal
8790
8359
  */
8791
8360
  init: (options?: OpenFin.InitLayoutOptions) => Promise<Layout>;
8792
- identity: OpenFin.LayoutIdentity;
8361
+ identity: OpenFin.Identity | OpenFin.LayoutIdentity;
8793
8362
  private platform;
8794
8363
  wire: Transport;
8795
8364
  /**
@@ -9008,45 +8577,24 @@ declare type LayoutEntityTypes = Exclude<GoldenLayout.ItemType, 'component' | 'r
9008
8577
  */
9009
8578
  declare type LayoutIdentity = Identity_5 & {
9010
8579
  /**
9011
- * The name of the layout an action should be targeted to. When not provided,
9012
- * OpenFin attempts to resolve the instance via visibility checks.
8580
+ * The name of the layout in a given window.
9013
8581
  */
9014
- layoutName?: string;
8582
+ layoutName: string;
9015
8583
  };
9016
8584
 
9017
8585
  /**
9018
- * Generated when a window and all of its layout's views have either finished or failed navigation.
8586
+ * Generated when the window is created, and all of its layout's views have either finished or failed
8587
+ * navigation, once per layout. Does not emit for any layouts added via Layout.create() call.
9019
8588
  * @interface
9020
8589
  */
9021
8590
  declare type LayoutInitializedEvent = BaseEvent_5 & {
9022
8591
  type: 'layout-initialized';
8592
+ layoutIdentity: OpenFin.LayoutIdentity;
9023
8593
  ofViews: (OpenFin.Identity & {
9024
8594
  entityType: 'view';
9025
8595
  })[];
9026
8596
  };
9027
8597
 
9028
- /**
9029
- * @interface @experimental @internal
9030
- *
9031
- * **NOTE**: Internal use only. This type is reserved for Workspace Browser implementation.
9032
- *
9033
- * Responsible for handling all layout management and renderering
9034
- */
9035
- declare type LayoutInstance = {
9036
- identity: LayoutIdentity;
9037
- getFrameSnapshot: () => Promise<LayoutOptions>;
9038
- addView: (payload: AddViewOptions) => Promise<View_2>;
9039
- closeView: (viewIdentity: Identity_5) => Promise<void>;
9040
- removeView: (viewConfig: Identity_5 | ViewState) => Promise<View_2>;
9041
- replaceView: (payload: ReplaceViewOptions) => Promise<View_2>;
9042
- getViews: () => LayoutComponent[];
9043
- getCurrentViews: () => Identity_5[];
9044
- startReplaceLayout: (payload: ReplaceLayoutOptions) => Promise<void>;
9045
- applyPreset: (payload: PresetLayoutOptions_2) => void;
9046
- isVisible: () => boolean;
9047
- destroy: () => Promise<void>;
9048
- };
9049
-
9050
8598
  /**
9051
8599
  * Represents the arrangement of Views within a Platform window's Layout. We do not recommend trying
9052
8600
  * to build Layouts or LayoutItems by hand and instead use calls such as {@link Platform#getSnapshot getSnapshot}.
@@ -9074,7 +8622,7 @@ declare type LayoutItemConfig = {
9074
8622
  *
9075
8623
  * **NOTE**: Internal use only. This type is reserved for Workspace Browser implementation.
9076
8624
  *
9077
- * Responsible for aggergating all layout snapshots and storing LayoutInstances
8625
+ * Responsible for aggregating all layout snapshots and storing layout instances
9078
8626
  */
9079
8627
  declare interface LayoutManager<T extends LayoutSnapshot> {
9080
8628
  /**
@@ -9098,16 +8646,6 @@ declare interface LayoutManager<T extends LayoutSnapshot> {
9098
8646
  * @throws if Object.keys(snapshot).length > 1
9099
8647
  */
9100
8648
  applyLayoutSnapshot(snapshot: T): Promise<void>;
9101
- /**
9102
- * Called at the start of layout initialization. Adds a new LayoutInstance if the snapshot
9103
- * contains a single layout.
9104
- *
9105
- * Throws if the snapshot contains more than 1 layout, it is expected that the user handles calling
9106
- * fin.Platform.Layout.create() once for each layout to properly connect it to their UI state.
9107
- *
9108
- * @param snapshot
9109
- * @throws if Object.keys(snapshot).length > 1
9110
- */
9111
8649
  /**
9112
8650
  * @experimental
9113
8651
  *
@@ -9128,31 +8666,49 @@ declare interface LayoutManager<T extends LayoutSnapshot> {
9128
8666
  /**
9129
8667
  * @experimental
9130
8668
  *
9131
- * @param layoutIdentity
9132
- * @returns
8669
+ * A hook provided to the consumer for controlling how OpenFin routes Layout API calls. Override
8670
+ * this method to control the target layout for Layout API calls.
8671
+ *
8672
+ * Example use case: You have hidden all the layouts and are showing a dialog that will
8673
+ * execute an API call (ex: Layout.replace()) - override this method and save the
8674
+ * "last visible" layout identity and return it.
8675
+ *
8676
+ * By default, OpenFin will use a series of checks to determine which Layout the API
8677
+ * call must route to in this order of precedence:
8678
+ * - try to resolve the layout from the layoutIdentity, throws if missing
8679
+ * - if there is only 1 layout, resolves that one
8680
+ * - enumerates all layouts checks visibility via element offsetTop/Left + window.innerHeight/Width
8681
+ * - returns undefined
8682
+ *
8683
+ * @param identity
8684
+ * @returns LayoutIdentity | undefined
9133
8685
  */
9134
- resolveLayout(layoutIdentity?: LayoutIdentity): Promise<LayoutInstance>;
8686
+ resolveLayoutIdentity(identity?: Identity_5 | LayoutIdentity): LayoutIdentity | undefined;
9135
8687
  /**
9136
8688
  * @experimental
9137
8689
  *
9138
- * Returns a LayoutInstance if one exists with the name layoutIdentity.layoutName.
9139
- * Throws if it does not exist.
9140
- * @param layoutName
9141
- * @returns
8690
+ * A hook provided to the consumer when it's time to remove a layout. Use this hook to
8691
+ * update your local state and remove the layout for the given LayoutIdentity. Note that
8692
+ * this hook does not call `fin.Platform.Layout.destroy()` for you, instead it is to
8693
+ * signify to your application it's time to destroy this layout.
8694
+ *
8695
+ * Note that if the Window Option {@link WindowOptions.closeOnLastViewRemoved} is true, and the last View in this layout is closed, this hook will be called before the window closes.
8696
+ *
8697
+ * @param LayoutIdentity
9142
8698
  */
9143
- getLayoutByName(layoutName: string): LayoutInstance;
8699
+ removeLayout({ layoutName }: LayoutIdentity): Promise<void>;
9144
8700
  /**
9145
8701
  * @experimental
9146
8702
  */
9147
- getLayouts(): Record<string, LayoutInstance>;
8703
+ getLayoutIdentityForView(viewIdentity: Identity_5): LayoutIdentity;
9148
8704
  /**
9149
8705
  * @experimental
9150
8706
  */
9151
- getLayoutIdentityForView(viewIdentity: Identity_5): LayoutIdentity;
8707
+ isLayoutVisible({ layoutName }: LayoutIdentity): boolean;
9152
8708
  /**
9153
8709
  * @experimental
9154
8710
  */
9155
- isLayoutVisible({ layoutName }: LayoutIdentity): boolean;
8711
+ size(): number;
9156
8712
  }
9157
8713
 
9158
8714
  /**
@@ -9199,7 +8755,7 @@ declare class LayoutModule extends Base {
9199
8755
  * const layoutConfig = await layout.getConfig();
9200
8756
  * ```
9201
8757
  */
9202
- wrap(identity: OpenFin.LayoutIdentity): Promise<OpenFin.Layout>;
8758
+ wrap(identity: OpenFin.Identity | OpenFin.LayoutIdentity): Promise<OpenFin.Layout>;
9203
8759
  /**
9204
8760
  * Synchronously returns a Layout object that represents a Window's layout.
9205
8761
  *
@@ -9219,7 +8775,7 @@ declare class LayoutModule extends Base {
9219
8775
  * const layoutConfig = await layout.getConfig();
9220
8776
  * ```
9221
8777
  */
9222
- wrapSync(identity: OpenFin.LayoutIdentity): OpenFin.Layout;
8778
+ wrapSync(identity: OpenFin.Identity | OpenFin.LayoutIdentity): OpenFin.Layout;
9223
8779
  /**
9224
8780
  * Asynchronously returns a Layout object that represents a Window's layout.
9225
8781
  *
@@ -9391,6 +8947,15 @@ declare abstract class LayoutNode {
9391
8947
  /**
9392
8948
  * Creates a new TabStack adjacent to the given TabStack or ColumnOrRow. Inputs can be new views to create, or existing views.
9393
8949
  *
8950
+ * Known Issue: If the number of views to add overflows the tab-container, the added views will be set as active
8951
+ * during each render, and then placed at the front of the tab-stack, while the underlying order of tabs will remain unchanged.
8952
+ * This means the views you pass to createAdjacentStack() may not render in the order given by the array.
8953
+ * Until fixed, this problem can be avoided only if your window is wide enough to fit creating all the views in the tabstack.
8954
+ *
8955
+ * @param views The views that will populate the new TabStack.
8956
+ * @param options Additional options that control new TabStack creation.
8957
+ * @returns The newly-created TabStack.
8958
+ *
9394
8959
  * @example
9395
8960
  * ```js
9396
8961
  * if (!fin.me.isView) {
@@ -9425,12 +8990,15 @@ declare abstract class LayoutNode {
9425
8990
  * console.log(`A new TabStack created to the right has ${newStack.length} views in it`);
9426
8991
  *
9427
8992
  * ```
8993
+ * @experimental
9428
8994
  */
9429
8995
  createAdjacentStack: (views: OpenFin.PlatformViewCreationOptions[], options: {
9430
8996
  position?: OpenFin.LayoutPosition;
9431
8997
  }) => Promise<TabStack>;
9432
8998
  /**
9433
- * Retrieves the adjacent TabStacks of the given TabStack or ColumnOrRow
8999
+ * Retrieves the adjacent TabStacks of the given TabStack or ColumnOrRow.
9000
+ *
9001
+ * @param edge Edge whose adjacent TabStacks will be returned.
9434
9002
  *
9435
9003
  * @example
9436
9004
  * ```js
@@ -9450,6 +9018,7 @@ declare abstract class LayoutNode {
9450
9018
  * console.log(`The entity has ${rightStacks.length} stacks to the right, and ${leftStacks.length} stacks to the left`);
9451
9019
  *
9452
9020
  * ```
9021
+ * @experimental
9453
9022
  */
9454
9023
  getAdjacentStacks: (edge: OpenFin.LayoutPosition) => Promise<TabStack[]>;
9455
9024
  }
@@ -9473,7 +9042,7 @@ declare type LayoutOptions = {
9473
9042
  * @defaultValue false
9474
9043
  *
9475
9044
  * Limits the area to which tabs can be dragged.
9476
- * If true, stack headers are the only areas where tabs can be dropped.
9045
+ * If true, the layout container is the only area where tabs can be dropped.
9477
9046
  */
9478
9047
  constrainDragToContainer?: boolean;
9479
9048
  /**
@@ -9544,6 +9113,9 @@ declare type LayoutOptions = {
9544
9113
  };
9545
9114
  };
9546
9115
 
9116
+ /**
9117
+ * Represents the position of an item in a layout relative to another.
9118
+ */
9547
9119
  declare type LayoutPosition = 'top' | 'bottom' | 'left' | 'right';
9548
9120
 
9549
9121
  /**
@@ -9552,11 +9124,12 @@ declare type LayoutPosition = 'top' | 'bottom' | 'left' | 'right';
9552
9124
  declare type LayoutPresetType = 'columns' | 'grid' | 'rows' | 'tabs';
9553
9125
 
9554
9126
  /**
9555
- * Generated when a window and all of its layout's views have been created and can receive API calls.
9127
+ * Generated when the layout and all of the its views have been created and can receive API calls.
9556
9128
  * @interface
9557
9129
  */
9558
9130
  declare type LayoutReadyEvent = BaseEvent_5 & {
9559
9131
  type: 'layout-ready';
9132
+ layoutIdentity: OpenFin.LayoutIdentity;
9560
9133
  views: (OpenFin.Identity & {
9561
9134
  success: boolean;
9562
9135
  })[];
@@ -10269,7 +9842,7 @@ declare type MutableWindowOptions = {
10269
9842
  * Used by Workspace to store custom data. Overwriting or modifying this field may impact the functionality of Workspace
10270
9843
  */
10271
9844
  _internalWorkspaceData: any;
10272
- workspacePlatform: WorkspacePlatformOptions;
9845
+ workspacePlatform: unknown;
10273
9846
  };
10274
9847
 
10275
9848
  declare type NackHandler = (payloadOrMessage: RuntimeErrorPayload | string) => void;
@@ -10355,7 +9928,7 @@ declare type NotCloseRequested<EventType extends string> = Exclude<EventType, 'c
10355
9928
  *
10356
9929
  * Ensures that an event type key doesn't include any `-requested` events. Distributes over unions.
10357
9930
  */
10358
- declare type NotRequested<EventType extends String> = EventType extends `${infer U}-requested` ? never : EventType;
9931
+ declare type NotRequested<EventType extends String> = EventType extends `${string}-requested` ? never : EventType;
10359
9932
 
10360
9933
  /**
10361
9934
  * Generated when an application is not responding.
@@ -10467,6 +10040,7 @@ declare namespace OpenFin {
10467
10040
  ResizeRegion,
10468
10041
  Accelerator,
10469
10042
  Api,
10043
+ InjectionType,
10470
10044
  NavigationRules,
10471
10045
  ContentNavigation,
10472
10046
  ContentRedirect,
@@ -10512,6 +10086,7 @@ declare namespace OpenFin {
10512
10086
  WebPermission,
10513
10087
  VerboseWebPermission,
10514
10088
  OpenExternalPermission,
10089
+ DeviceInfo,
10515
10090
  Permissions_2 as Permissions,
10516
10091
  PlatformWindowCreationOptions,
10517
10092
  PlatformWindowOptions,
@@ -10669,7 +10244,6 @@ declare namespace OpenFin {
10669
10244
  InitLayoutOptions,
10670
10245
  LayoutManagerConstructor,
10671
10246
  LayoutManagerOverride,
10672
- LayoutInstance,
10673
10247
  LayoutManager,
10674
10248
  CreateLayoutOptions,
10675
10249
  PresetLayoutOptions_2 as PresetLayoutOptions,
@@ -10861,6 +10435,7 @@ declare type Permissions_2 = {
10861
10435
  Application?: Partial<ApplicationPermissions>;
10862
10436
  System?: Partial<SystemPermissions>;
10863
10437
  webAPIs?: WebPermission[];
10438
+ devices?: DeviceInfo[];
10864
10439
  };
10865
10440
 
10866
10441
  declare type PermissionState_2 = 'granted' | 'denied' | 'unavailable';
@@ -11816,21 +11391,16 @@ declare interface PlatformProvider {
11816
11391
  */
11817
11392
  getInitialLayoutSnapshot(payload: undefined, callerIdentity: OpenFin.Identity): Promise<OpenFin.LayoutSnapshot | undefined>;
11818
11393
  /**
11819
- * @experimental @internal
11820
- *
11821
- * **NOTE**: Internal use only. This method is reserved for Workspace Browser implementation.
11822
- *
11823
- * Calls platform.createView for every view in the given layout. Returns an array of promises
11824
- * one promise for each view create call
11394
+ * @experimental
11825
11395
  *
11826
- * @param payload
11396
+ * This API is called during the {@link PlatformProvider.getSnapshot()} call.
11397
+ * Gets the current state of a particular window and its views and returns an object that
11398
+ * can be added to the {@link OpenFin.Snapshot.windows} property. Override this function if
11399
+ * you wish to mutate each window snapshot during the {@link PlatformProvider.getSnapshot()} call
11400
+ * @param identity
11827
11401
  * @param callerIdentity
11828
- * @returns an array of promises
11829
11402
  */
11830
- createViewsForLayout(payload: {
11831
- layout: GoldenLayout.Config;
11832
- target?: OpenFin.Identity;
11833
- }, callerIdentity: OpenFin.Identity): Promise<OpenFin.View>[];
11403
+ getWindowSnapshot(identity: OpenFin.Identity, callerIdentity: OpenFin.Identity): Promise<OpenFin.WindowCreationOptions>;
11834
11404
  /**
11835
11405
  * **NOTE**: Internal use only. It is not recommended to manage the state of individual views.
11836
11406
  * 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.
@@ -13294,7 +12864,7 @@ declare type ReplaceLayoutPayload = {
13294
12864
  /**
13295
12865
  * Identity of the window whose layout will be replaced.
13296
12866
  */
13297
- target: LayoutIdentity;
12867
+ target: Identity_5 | LayoutIdentity;
13298
12868
  };
13299
12869
 
13300
12870
  /**
@@ -14131,83 +13701,6 @@ declare class System extends EmitterBase<OpenFin.SystemEvent> {
14131
13701
  */
14132
13702
  constructor(wire: Transport);
14133
13703
  private sendExternalProcessRequest;
14134
- /**
14135
- * Adds a listener to the end of the listeners array for the specified event.
14136
- * @param eventType - The type of the event.
14137
- * @param listener - Called whenever an event of the specified type occurs.
14138
- * @param options - Option to support event timestamps.
14139
- *
14140
- * @function addListener
14141
- * @memberof System
14142
- * @instance
14143
- * @tutorial System.EventEmitter
14144
- */
14145
- /**
14146
- * Adds a listener to the end of the listeners array for the specified event.
14147
- * @param eventType - The type of the event.
14148
- * @param listener - Called whenever an event of the specified type occurs.
14149
- * @param options - Option to support event timestamps.
14150
- *
14151
- * @function on
14152
- * @memberof System
14153
- * @instance
14154
- * @tutorial System.EventEmitter
14155
- */
14156
- /**
14157
- * Adds a one time listener for the event. The listener is invoked only the first time the event is fired, after which it is removed.
14158
- * @param eventType - The type of the event.
14159
- * @param listener - The callback function.
14160
- * @param options - Option to support event timestamps.
14161
- *
14162
- * @function once
14163
- * @memberof System
14164
- * @instance
14165
- * @tutorial System.EventEmitter
14166
- */
14167
- /**
14168
- * Adds a listener to the beginning of the listeners array for the specified event.
14169
- * @param eventType - The type of the event.
14170
- * @param listener - The callback function.
14171
- * @param options - Option to support event timestamps.
14172
- *
14173
- * @function prependListener
14174
- * @memberof System
14175
- * @instance
14176
- * @tutorial System.EventEmitter
14177
- */
14178
- /**
14179
- * Adds a one time listener for the event. The listener is invoked only the first time the event is fired, after which it is removed.
14180
- * The listener is added to the beginning of the listeners array.
14181
- * @param eventType - The type of the event.
14182
- * @param listener - The callback function.
14183
- * @param options - Option to support event timestamps.
14184
- *
14185
- * @function prependOnceListener
14186
- * @memberof System
14187
- * @instance
14188
- * @tutorial System.EventEmitter
14189
- */
14190
- /**
14191
- * Remove a listener from the listener array for the specified event.
14192
- * Caution: Calling this method changes the array indices in the listener array behind the listener.
14193
- * @param eventType - The type of the event.
14194
- * @param listener - The callback function.
14195
- * @param options - Option to support event timestamps.
14196
- *
14197
- * @function removeListener
14198
- * @memberof System
14199
- * @instance
14200
- * @tutorial System.EventEmitter
14201
- */
14202
- /**
14203
- * Removes all listeners, or those of the specified event.
14204
- * @param eventType - The type of the event.
14205
- *
14206
- * @function removeAllListeners
14207
- * @memberof System
14208
- * @instance
14209
- * @tutorial System.EventEmitter
14210
- */
14211
13704
  /**
14212
13705
  * Returns the version of the runtime. The version contains the major, minor,
14213
13706
  * build and revision numbers.
@@ -15797,77 +15290,13 @@ declare interface TabDragListener extends EventEmitter_2 {
15797
15290
  contentItem: ContentItem;
15798
15291
  }
15799
15292
 
15800
- /**
15801
- * @typedef {string} LayoutPosition
15802
- * @summary Represents the position of an item in a layout relative to another. Possible values are 'top', 'bottom', 'left' and 'right'.
15803
- */
15804
- /**
15805
- * @typedef {object} StackCreationOptions
15806
- * @summary Stack creation options.
15807
- * @property {LayoutPosition} [position] - The position to create the new {@link TabStack} in, relative to the given adjacent {@link TabStack}. Defaults to 'right'.
15808
- */
15809
- /**
15810
- * @typedef {object} TabStack~AddViewOptions
15811
- * @summary Options to use when adding a view to a {@link TabStack}
15812
- * @property {number} [index] - Insertion index when adding the view. Defaults to 0.
15813
- */
15814
15293
  /**
15815
15294
  * A TabStack is used to manage the state of a stack of tabs within an OpenFin Layout.
15816
15295
  */
15817
15296
  declare class TabStack extends LayoutNode {
15818
15297
  #private;
15819
- /**
15820
- * Determines if this {@link TabStack} is the top level content item in the current layout.
15821
- * @function isRoot
15822
- * @memberof TabStack
15823
- * @instance
15824
- * @tutorial TabStack.isRoot
15825
- * @returns Resolves true if this TabStack is the top level content item, or false if it is not.
15826
- */
15827
- /**
15828
- * Determines if this {@link TabStack} exists.
15829
- * @function exists
15830
- * @instance
15831
- * @memberof TabStack
15832
- * @tutorial TabStack.exists
15833
- * @returns Resolves true if this is the TabStack exists, or false if it has been destroyed.
15834
- */
15835
- /**
15836
- * Retrieves the parent {@link ColumnOrRow} of this {@link TabStack}, if one exists.
15837
- * @function getParent
15838
- * @instance
15839
- * @memberof TabStack
15840
- * @tutorial TabStack.getParent
15841
- * @returns is the root content item or does not exist.
15842
- */
15843
- /**
15844
- * Returns all the adjacent stacks that share an edge with the given {@link TabStack}.
15845
- * @function getAdjacentStacks
15846
- * @instance
15847
- * @memberof TabStack
15848
- * @param {LayoutPosition} edge - Edge to check for any adjacent stacks.
15849
- *
15850
- * @tutorial TabStack.getAdjacentStacks
15851
- */
15852
- /**
15853
- * Given a list of view creation options or references and a layout position, creates a {@link TabStack} adjacent to the current {@link TabStack}
15854
- *
15855
- * Known Issue: If the number of views to add overflows the tab-container, the added views will be set as active
15856
- * during each render, and then placed at the front of the tab-stack, while the underlying order of tabs will remain unchanged.
15857
- * This means the views you pass to createAdjacentStack() may not render in the order given by the array.
15858
- * Until fixed, this problem can be avoided only if your window is wide enough to fit creating all the views in the tabstack.
15859
- *
15860
- * @function createAdjacentStack
15861
- * @instance
15862
- * @memberof TabStack
15863
- * @param views - List of identities or view creation options of the views to include in the stack
15864
- * @param options - Creation options.
15865
- * @returns The created TabStack.
15866
- * @tutorial TabStack.createAdjacentStack
15867
- * @experimental
15868
- */
15869
- /** @internal */
15870
- constructor(client: LayoutEntitiesClient, entityId: string);
15298
+ /** @internal */
15299
+ constructor(client: LayoutEntitiesClient, entityId: string);
15871
15300
  /**
15872
15301
  * Type of the content item. Always stack, but useful for distinguishing between a {@link TabStack} and {@link ColumnOrRow}.
15873
15302
  */
@@ -16306,169 +15735,6 @@ declare type VerboseWebPermission = {
16306
15735
 
16307
15736
  declare type View = OpenFin.View;
16308
15737
 
16309
- /**
16310
- * @PORTED
16311
- * @typedef {object} View~options
16312
- * @summary View creation options.
16313
- * @desc This is the options object required by {@link View.create View.create}.
16314
- *
16315
- * Note that `name` and `target` are the only required properties — albeit the `url` property is usually provided as well
16316
- * (defaults to `"about:blank"` when omitted).
16317
- *
16318
- * @property {object} [experimental]
16319
- * Configurations for API injection.
16320
- *
16321
- * @property {boolean} [experimental.childWindows] Configure if the runtime should enable child windows for views.
16322
- *
16323
- * @property {object} [accelerator]
16324
- * Enable keyboard shortcuts for devtools, zoom, reload, and reload ignoring cache.
16325
- *
16326
- * @property {boolean} [accelerator.devtools=false]
16327
- * If `true`, enables the devtools keyboard shortcut:<br>
16328
- * `Ctrl` + `Shift` + `I` _(Toggles Devtools)_
16329
- *
16330
- * @property {boolean} [accelerator.reload=false]
16331
- * If `true`, enables the reload keyboard shortcuts:<br>
16332
- * `Ctrl` + `R` _(Windows)_<br>
16333
- * `F5` _(Windows)_<br>
16334
- * `Command` + `R` _(Mac)_
16335
- *
16336
- * @property {boolean} [accelerator.reloadIgnoringCache=false]
16337
- * If `true`, enables the reload-from-source keyboard shortcuts:<br>
16338
- * `Ctrl` + `Shift` + `R` _(Windows)_<br>
16339
- * `Shift` + `F5` _(Windows)_<br>
16340
- * `Command` + `Shift` + `R` _(Mac)_
16341
- *
16342
- * @property {boolean} [accelerator.zoom=false]
16343
- * If `true`, enables the zoom keyboard shortcuts:<br>
16344
- * `Ctrl` + `+` _(Zoom In)_<br>
16345
- * `Ctrl` + `Shift` + `+` _(Zoom In)_<br>
16346
- * `Ctrl` + `NumPad+` _(Zoom In)_<br>
16347
- * `Ctrl` + `-` _(Zoom Out)_<br>
16348
- * `Ctrl` + `Shift` + `-` _(Zoom Out)_<br>
16349
- * `Ctrl` + `NumPad-` _(Zoom Out)_<br>
16350
- * `Ctrl` + `Scroll` _(Zoom In & Out)_<br>
16351
- * `Ctrl` + `0` _(Restore to 100%)_
16352
- *
16353
- * @property {object} [api]
16354
- * Configurations for API injection.
16355
- *
16356
- * @property {object} [api.iframe] Configure if the the API should be injected into iframes based on domain.
16357
- *
16358
- * @property {boolean} [api.iframe.crossOriginInjection=false] Controls if the `fin` API object is present for cross origin iframes.
16359
- * @property {boolean} [api.iframe.sameOriginInjection=true] Controls if the `fin` API object is present for same origin iframes.
16360
- *
16361
- * @property {string} [autoplayPolicy="no-user-gesture-required"]
16362
- * Autoplay policy to apply to content in the window, can be
16363
- * `no-user-gesture-required`, `user-gesture-required`,
16364
- * `document-user-activation-required`. Defaults to `no-user-gesture-required`.
16365
- *
16366
- * @property {object} [autoResize] AutoResize options
16367
- *
16368
- * @property {object} [bounds] initial bounds given relative to the window.
16369
- *
16370
- * @property {string} [backgroundColor="#FFF"] - _Updatable._
16371
- * The view’s _backfill_ color as a hexadecimal value. Not to be confused with the content background color
16372
- * (`document.body.style.backgroundColor`),
16373
- * this color briefly fills a view’s (a) content area before its content is loaded as well as (b) newly exposed
16374
- * areas when growing a window. Setting
16375
- * this value to the anticipated content background color can help improve user experience.
16376
- * Default is white.
16377
- *
16378
- * @property {object} [contentNavigation]
16379
- * Restrict navigation to URLs that match an allowed pattern.
16380
- * In the lack of an allowlist, navigation to URLs that match a denied pattern would be prohibited.
16381
- * See [here](https://developer.chrome.com/extensions/match_patterns) for more details.
16382
- * @property {string[]} [contentNavigation.allowlist=[]] List of allowed URLs.
16383
- * @property {string[]} [contentNavigation.denylist=[]] List of denied URLs.
16384
- *
16385
- * @property {object} [contentRedirect]
16386
- * Restrict redirects to URLs that match an allowed pattern.
16387
- * In the lack of an allowlist, redirects to URLs that match a denied pattern would be prohibited.
16388
- * See [here](https://developer.chrome.com/extensions/match_patterns) for more details.
16389
- * @property {string[]} [contentRedirect.allowlist=[]] List of allowed URLs.
16390
- * @property {string[]} [contentRedirect.denylist=[]] List of denied URLs.
16391
- *
16392
- * @property {object} [contextMenuSettings] - _Updatable._
16393
- * Deprecated - superseded by {@link contextMenuOptions}, which offers a larger feature-set and cleaner syntax.
16394
- * Configure the context menu when right-clicking on a view.
16395
- * @property {boolean} [contextMenuSettings.enable=true] Should the context menu display on right click.
16396
- * @property {boolean} [contextMenuSettings.devtools=true] Should the context menu contain a button for opening devtools.
16397
- * @property {boolean} [contextMenuSettings.reload=true] Should the context menu contain a button for reloading the page.
16398
- *
16399
- * @property {object} [contextMenuOptions] - _Updatable._
16400
- * Configure the context menu when right-clicking on a view. Supported menu items:
16401
- * 'separator'
16402
- * 'cut'
16403
- * 'copy'
16404
- * 'copyImage',
16405
- * 'paste'
16406
- * 'spellCheck'
16407
- * 'inspect'
16408
- * 'reload'
16409
- * 'navigateForward'
16410
- * 'navigateBack'
16411
- * 'print'
16412
- * @property {boolean} [contextMenuOptions.enabled = true] Should the context menu display on right click.
16413
- * @property {string[]} [contextMenuOptions.template=[]] List of context menu items to display on right-click.
16414
- *
16415
- * @property {any} [customData=""] - _Updatable._
16416
- * A field that the user can attach serializable data to be ferried around with the view options.
16417
- * _When omitted, the default value of this property is the empty string (`""`)._
16418
- *
16419
- * @property {any} [customContext=""] - _Updatable._
16420
- * A field that the user can use to attach serializable data that will be saved when {@link Platform#getSnapshot Platform.getSnapshot}
16421
- * is called.
16422
- * When omitted, the default value of this property is the empty string (`""`).
16423
- * As opposed to customData, this is meant for frequent updates and sharing with other contexts. [Example]{@tutorial customContext}
16424
- *
16425
- * @property {object[]} [hotkeys=[]] - _Updatable._
16426
- * Defines the list of hotkeys that will be emitted as a `hotkey` event on the view. For usage example see [example]{@tutorial hotkeys}.
16427
- * Within Platform, OpenFin also implements a set of pre-defined actions called
16428
- * [keyboard commands]{@link https://developers.openfin.co/docs/platform-api#section-5-3-using-keyboard-commands}
16429
- * that can be assigned to a specific hotkey in the platform manifest.
16430
- * @property {string} hotkeys.keys The key combination of the hotkey, i.e. "Ctrl+T"
16431
- * @property {boolean} [hotkeys.preventDefault=false] preventDefault will prevent the page keydown/keyup events from being emitted.
16432
- *
16433
- * @property {boolean} [isClosable=true] **Platforms Only.** If false, the view will be persistent and can't be closed through
16434
- * either UI or `Platform.closeView`. Note that the view will still be closed if the host window is closed or
16435
- * if the view isn't part of the new layout when running `Layout.replace`.
16436
- *
16437
- * @property {string} name
16438
- * The name of the view.
16439
- *
16440
- * @property {boolean} [detachOnClose=false] - _Updatable._
16441
- * Platforms Only. If true, will hide and detach the View from the window for later use instead of closing,
16442
- * allowing the state of the View to be saved and the View to be immediately shown in a new Layout.
16443
- *
16444
- * @property {string} [manifestUrl] **Platforms Only.** Url to a manifest that contains View Options. Properties other than manifestUrl can still be used
16445
- * but the properties in the manifest will take precedence if there is any collision.
16446
- *
16447
- * @property {preloadScript[]} [preloadScripts] - _Inheritable_
16448
- * A list of scripts that are eval'ed before other scripts in the page. When omitted, _inherits_
16449
- * from the parent application.
16450
- *
16451
- * @property {boolean} [preventDragOut=false] **Platforms Only.** If true, the tab of the view can't be dragged out of its host window.
16452
- *
16453
- * @property {string} [processAffinity=<application uuid>]
16454
- * A string to attempt to group renderers together. Will only be used if pages are on the same origin.
16455
- *
16456
- * @property {boolean} [spellCheck=false]
16457
- * Enable spell check in input text fields for the view.
16458
- *
16459
- * @property {Identity} [target]
16460
- * The identity of the window this view should be attached to.
16461
- *
16462
- * @property {string} [url="about:blank"]
16463
- * The URL of the view.
16464
- *
16465
- * @property {string} [uuid=<application uuid>]
16466
- * The `uuid` of the application, unique within the set of all `Application`s running in OpenFin Runtime.
16467
- * If omitted, defaults to the `uuid` of the application spawning the view.
16468
- * If given, must match the `uuid` of the application spawning the view.
16469
- * In other words, the application's `uuid` is the only acceptable value, but is the default, so there's
16470
- * really no need to provide it.
16471
- */
16472
15738
  /**
16473
15739
  * A View can be used to embed additional web content into a Window.
16474
15740
  * It is like a child window, except it is positioned relative to its owning window.
@@ -16984,7 +16250,7 @@ declare type ViewCreationOrReference = OpenFin.Identity | OpenFin.PlatformViewCr
16984
16250
  */
16985
16251
  declare type ViewDetachedEvent = BaseEvent_5 & {
16986
16252
  type: 'view-detached';
16987
- target: OpenFin.Identity;
16253
+ target: OpenFin.Identity | null;
16988
16254
  previousTarget: OpenFin.Identity;
16989
16255
  viewIdentity: OpenFin.Identity;
16990
16256
  };
@@ -18220,7 +17486,7 @@ declare namespace WebContentsEvents {
18220
17486
  * `clipboard-read`: Request access to read from the clipboard.<br>
18221
17487
  * `clipboard-sanitized-write`: Request access to write to the clipboard.
18222
17488
  */
18223
- declare type WebPermission = 'audio' | 'video' | 'geolocation' | 'notifications' | 'midiSysex' | 'pointerLock' | 'fullscreen' | 'openExternal' | 'clipboard-read' | 'clipboard-sanitized-write' | OpenExternalPermission;
17489
+ declare type WebPermission = 'audio' | 'video' | 'geolocation' | 'notifications' | 'midiSysex' | 'pointerLock' | 'fullscreen' | 'openExternal' | 'clipboard-read' | 'clipboard-sanitized-write' | 'hid' | 'usb' | OpenExternalPermission;
18224
17490
 
18225
17491
  /**
18226
17492
  * Object representing headers and their values, where the
@@ -18298,476 +17564,6 @@ declare type WillResizeEvent = WillMoveOrResizeEvent & {
18298
17564
  type: 'will-resize';
18299
17565
  };
18300
17566
 
18301
- /**
18302
- * @PORTED
18303
- * @typedef { object } Margins@typedef { object } Margins
18304
- * @property { string } [marginType]
18305
- * Can be `default`, `none`, `printableArea`, or `custom`. If `custom` is chosen,
18306
- * you will also need to specify `top`, `bottom`, `left`, and `right`.
18307
- *
18308
- * @property { number } [top] The top margin of the printed web page, in pixels.
18309
- * @property { number } [bottom] The bottom margin of the printed web page, in pixels.
18310
- * @property { number } [left] The left margin of the printed web page, in pixels.
18311
- * @property { number } [right] The right margin of the printed web page, in pixels.
18312
- */
18313
- /**
18314
- * @PORTED
18315
- * @typedef { object } Dpi@typedef { object } Dpi
18316
- * @property { number } [horizontal] The horizontal dpi
18317
- * @property { number } [vertical] The vertical dpi
18318
- */
18319
- /**
18320
- * @PORTED
18321
- * @typedef { object } PrintOptions@typedef { object } PrintOptions
18322
- * @property { boolean } [silent=false] Don't ask user for print settings.
18323
- * @property { boolean } [printBackground=false] Prints the background color and image of the web page.
18324
- * @property { string } [deviceName=''] Set the printer device name to use.
18325
- * @property { boolean } [color=true] Set whether the printed web page will be in color or grayscale.
18326
- * @property { Margins } [margins] Set margins for the printed web page
18327
- * @property { boolean } [landscape=false] Whether the web page should be printed in landscape mode.
18328
- * @property { number } [scaleFactor] The scale factor of the web page.
18329
- * @property { number } [pagesPerSheet] The number of pages to print per page sheet.
18330
- * @property { boolean } [collate] Whether the web page should be collated.
18331
- * @property { number } [copies] The number of copies of the web page to print.
18332
- * @property { Record<string, number> } [pageRanges] The page range to print. Should have two keys: from and to.
18333
- * @property { string } [duplexMode] Set the duplex mode of the printed web page. Can be simplex, shortEdge, or longEdge.
18334
- * @property { Dpi } [dpi] Set dpi for the printed web page
18335
- */
18336
- /**
18337
- * @REMOVED
18338
- * PrinterInfo interface
18339
- * @typedef { object } PrinterInfo@typedef { object } PrinterInfo
18340
- * @property { string } name Printer Name
18341
- * @property { string } description Printer Description
18342
- * @property { number } status Printer Status
18343
- * @property { boolean } isDefault Indicates that system's default printer
18344
- */
18345
- /**
18346
- * @REMOVED
18347
- * SharedWorkerInfo interface
18348
- * @typedef { object } SharedWorkerInfo@typedef { object } SharedWorkerInfo
18349
- * @property { string } id The unique id of the shared worker.
18350
- * @property { string } url The url of the shared worker.
18351
- */
18352
- /**
18353
- * @PORTED
18354
- * ContentCreationRule interface
18355
- * @typedef { object } ContentCreationRule@typedef { object } ContentCreationRule
18356
- * @property { string } behavior 'view' | 'window' | 'browser' | 'block'
18357
- * @property { string[] } match List of [match patterns](https://developer.chrome.com/extensions/match_patterns).
18358
- * @property { object } options Window creation options or View creation options.
18359
- */
18360
- /**
18361
- * @PORTED
18362
- * @typedef {object} Window~options
18363
- * @summary Window creation options.
18364
- * @desc This is the options object required by {@link Window.create Window.create}.
18365
- *
18366
- * Note that `name` is the only required property — albeit the `url` property is usually provided as well
18367
- * (defaults to `"about:blank"` when omitted).
18368
- *
18369
- * _This jsdoc typedef mirrors the `WindowOptions` TypeScript interface in `@types/openfin`._
18370
- *
18371
- * @property {object} [accelerator]
18372
- * Enable keyboard shortcuts for devtools, zoom, reload, and reload ignoring cache.
18373
- *
18374
- * @property {boolean} [accelerator.devtools=false]
18375
- * If `true`, enables the devtools keyboard shortcut:<br>
18376
- * `Ctrl` + `Shift` + `I` _(Toggles Devtools)_
18377
- *
18378
- * @property {boolean} [accelerator.reload=false]
18379
- * If `true`, enables the reload keyboard shortcuts:<br>
18380
- * `Ctrl` + `R` _(Windows)_<br>
18381
- * `F5` _(Windows)_<br>
18382
- * `Command` + `R` _(Mac)_
18383
- *
18384
- * @property {boolean} [accelerator.reloadIgnoringCache=false]
18385
- * If `true`, enables the reload-from-source keyboard shortcuts:<br>
18386
- * `Ctrl` + `Shift` + `R` _(Windows)_<br>
18387
- * `Shift` + `F5` _(Windows)_<br>
18388
- * `Command` + `Shift` + `R` _(Mac)_
18389
- *
18390
- * @property {boolean} [accelerator.zoom=false]
18391
- * NOTE: It is not recommended to set this value to true for Windows in Platforms as that may lead to unexpected visual shifts in layout.
18392
- * If `true`, enables the zoom keyboard shortcuts:<br>
18393
- * `Ctrl` + `+` _(Zoom In)_<br>
18394
- * `Ctrl` + `Shift` + `+` _(Zoom In)_<br>
18395
- * `Ctrl` + `NumPad+` _(Zoom In)_<br>
18396
- * `Ctrl` + `-` _(Zoom Out)_<br>
18397
- * `Ctrl` + `Shift` + `-` _(Zoom Out)_<br>
18398
- * `Ctrl` + `NumPad-` _(Zoom Out)_<br>
18399
- * `Ctrl` + `Scroll` _(Zoom In & Out)_<br>
18400
- * `Ctrl` + `0` _(Restore to 100%)_
18401
- *
18402
- * @property {object} [alphaMask] - _Experimental._ _Updatable._
18403
- * <br>
18404
- * alphaMask turns anything of matching RGB value transparent.
18405
- * <br>
18406
- * Caveats:
18407
- * * Runtime flags --disable-gpu and --allow-unsafe-compositing are required. Note: Unclear behavior on remote Desktop support
18408
- * * User cannot click-through transparent regions
18409
- * * Not supported on Mac
18410
- * * Windows Aero must be enabled
18411
- * * Won't make visual sense on Pixel-pushed environments such as Citrix
18412
- * * Not supported on rounded corner windows
18413
- * @property {number} [alphaMask.red=-1] 0-255
18414
- * @property {number} [alphaMask.green=-1] 0-255
18415
- * @property {number} [alphaMask.blue=-1] 0-255
18416
- *
18417
- * @property {boolean} [alwaysOnTop=false] - _Updatable._
18418
- * A flag to always position the window at the top of the window stack.
18419
- *
18420
- * @property {object} [api]
18421
- * Configurations for API injection.
18422
- *
18423
- * @property {object} [api.iframe] Configure if the the API should be injected into iframes based on domain.
18424
- *
18425
- * @property {boolean} [api.iframe.crossOriginInjection=false] Controls if the `fin` API object is present for cross origin iframes.
18426
- * @property {boolean} [api.iframe.sameOriginInjection=true] Controls if the `fin` API object is present for same origin iframes.
18427
- *
18428
- * @property {string} [applicationIcon = ""] - _Deprecated_ - use `icon` instead.
18429
- *
18430
- * @property {number} [aspectRatio=0] - _Updatable._
18431
- * The aspect ratio of width to height to enforce for the window. If this value is equal to or less than zero,
18432
- * an aspect ratio will not be enforced.
18433
- *
18434
- * @property {string} [autoplayPolicy="no-user-gesture-required"]
18435
- * Autoplay policy to apply to content in the window, can be
18436
- * `no-user-gesture-required`, `user-gesture-required`,
18437
- * `document-user-activation-required`. Defaults to `no-user-gesture-required`.
18438
- *
18439
- * @property {boolean} [autoShow=true]
18440
- * A flag to automatically show the window when it is created.
18441
- *
18442
- * @property {string} [backgroundColor="#FFF"]
18443
- * The window’s _backfill_ color as a hexadecimal value. Not to be confused with the content background color
18444
- * (`document.body.style.backgroundColor`),
18445
- * this color briefly fills a window’s (a) content area before its content is loaded as well as (b) newly exposed
18446
- * areas when growing a window. Setting
18447
- * this value to the anticipated content background color can help improve user experience.
18448
- * Default is white.
18449
- *
18450
- * @property {object} [contentCreation]
18451
- * Apply rules that determine how user interaction (`window.open` and links) creates content.
18452
- * @property {ContentCreationRule[]} [contentCreation.rules = []] List of content creation rules.
18453
- *
18454
- * @property {object} [contentNavigation]
18455
- * Restrict navigation to URLs that match an allowed pattern.
18456
- * In the lack of an allowlist, navigation to URLs that match a denied pattern would be prohibited.
18457
- * See [here](https://developer.chrome.com/extensions/match_patterns) for more details.
18458
- * @property {string[]} [contentNavigation.allowlist=[]] List of allowed URLs.
18459
- * @property {string[]} [contentNavigation.denylist=[]] List of denied URLs.
18460
- *
18461
- * @property {object} [contentRedirect]
18462
- * Restrict redirects to URLs that match an allowed pattern.
18463
- * In the lack of an allowlist, redirects to URLs that match a denied pattern would be prohibited.
18464
- * See [here](https://developer.chrome.com/extensions/match_patterns) for more details.
18465
- * @property {string[]} [contentRedirect.allowlist=[]] List of allowed URLs.
18466
- * @property {string[]} [contentRedirect.denylist=[]] List of denied URLs.
18467
- *
18468
- * @property {boolean} [contextMenu=true] - _Updatable._
18469
- * A flag to show the context menu when right-clicking on a window.
18470
- * Gives access to the devtools for the window.
18471
- *
18472
- * @property {object} [contextMenuSettings] - _Updatable._
18473
- * Deprecated - superseded by {@link contextMenuOptions}, which offers a larger feature-set and cleaner syntax.
18474
- * Configure the context menu when right-clicking on a window.
18475
- * @property {boolean} [contextMenuSettings.enable=true] Should the context menu display on right click.
18476
- * @property {boolean} [contextMenuSettings.devtools=true] Should the context menu contain a button for opening devtools.
18477
- * @property {boolean} [contextMenuSettings.reload=true] Should the context menu contain a button for reloading the page.
18478
- *
18479
- * @property {object} [contextMenuOptions] - _Updatable._
18480
- * Configure the context menu when right-clicking on a window. Supported menu items:
18481
- * 'separator'
18482
- * 'cut'
18483
- * 'copy'
18484
- * 'paste'
18485
- * 'spellCheck'
18486
- * 'inspect'
18487
- * 'reload'
18488
- * 'navigateForward'
18489
- * 'navigateBack'
18490
- * 'print'
18491
- * @property {boolean} [contextMenuOptions.enabled = true] Should the context menu display on right click.
18492
- * @property {string[]} [contextMenuSettings.template=[]] List of context menu items to display on right-click.
18493
- *
18494
- * @property {object} [cornerRounding] - _Updatable._
18495
- * Defines and applies rounded corners for a frameless window. **NOTE:** On macOS corner is not ellipse but circle rounded by the
18496
- * average of _height_ and _width_.
18497
- * @property {number} [cornerRounding.height=0] The height in pixels.
18498
- * @property {number} [cornerRounding.width=0] The width in pixels.
18499
- *
18500
- * @property {any} [customContext=""] - _Updatable. Inheritable._
18501
- * A field that the user can use to attach serializable data that will be saved when {@link Platform#getSnapshot Platform.getSnapshot}
18502
- * is called. If a window in a Platform is trying to update or retrieve its own context, it can use the
18503
- * {@link Platform#setWindowContext Platform.setWindowContext} and {@link Platform#getWindowContext Platform.getWindowContext} calls.
18504
- * _When omitted, _inherits_ from the parent application._
18505
- * As opposed to customData, this is meant for frequent updates and sharing with other contexts. [Example]{@tutorial customContext}
18506
- *
18507
- * @property {any} [customData=""] - _Updatable. Inheritable._
18508
- * A field that the user can attach serializable data to be ferried around with the window options.
18509
- * _When omitted, _inherits_ from the parent application._
18510
- *
18511
- * @property {object[]} [customRequestHeaders]
18512
- * Defines list of custom headers for requests sent by the window.
18513
- * @property {string[]} [customRequestHeaders.urlPatterns=[]] The URL patterns for which the headers will be applied
18514
- * @property {object[]} [customRequestHeaders.headers=[]] Objects representing headers and their values,
18515
- * where the object key is the name of header and value at key is the value of the header
18516
- *
18517
- * @property {boolean} [closeOnLastViewRemoved=true] - _Experimental._ _Updatable._
18518
- * Toggling off would keep the Window alive even if all its Views were closed.
18519
- * This is meant for advanced users and should be used with caution.
18520
- * Limitations - Once a Layout has been emptied out of all views it's not usable anymore, and certain API calls will fail.
18521
- * Use `layout.replace` to create a fresh Layout instance in case you want to populate it with Views again.
18522
- * ** note ** - This option is ignored in non-Platforms apps.
18523
- *
18524
- * @property {boolean} [defaultCentered=false]
18525
- * Centers the window in the primary monitor. This option overrides `defaultLeft` and `defaultTop`. When `saveWindowState` is `true`,
18526
- * this value will be ignored for subsequent launches in favor of the cached value. **NOTE:** On macOS _defaultCenter_ is
18527
- * somewhat above center vertically.
18528
- *
18529
- * @property {number} [defaultHeight=500]
18530
- * The default height of the window. When `saveWindowState` is `true`, this value will be ignored for subsequent launches
18531
- * in favor of the cached value.
18532
- *
18533
- * @property {number} [defaultLeft=100]
18534
- * The default left position of the window. When `saveWindowState` is `true`, this value will be ignored for subsequent
18535
- * launches in favor of the cached value.
18536
- *
18537
- * @property {number} [defaultTop=100]
18538
- * The default top position of the window. When `saveWindowState` is `true`, this value will be ignored for subsequent
18539
- * launches in favor of the cached value.
18540
- *
18541
- * @property {number} [defaultWidth=800]
18542
- * The default width of the window. When `saveWindowState` is `true`, this value will be ignored for subsequent
18543
- * launches in favor of the cached value.
18544
- *
18545
- * @property {boolean} [includeInSnapshots=true] - _Updatable._
18546
- * When true, the window will be be included in snapshots returned by Platform.getSnapshot(). Turning this off may be desirable when dealing with
18547
- * inherently temporary windows whose state shouldn't be preserved, such as modals, menus, or popups.
18548
- *
18549
- * @property {boolean} [frame=true] - _Updatable._
18550
- * A flag to show the frame.
18551
- *
18552
- * @hidden-property {boolean} [hideOnClose=false] - A flag to allow a window to be hidden when the close button is clicked.
18553
- *
18554
- * @property {object[]} [hotkeys=[]] - _Updatable._
18555
- * Defines the list of hotkeys that will be emitted as a `hotkey` event on the window. For usage example see [example]{@tutorial hotkeys}.
18556
- * Within Platform, OpenFin also implements a set of pre-defined actions called
18557
- * [keyboard commands]{@link https://developers.openfin.co/docs/platform-api#section-5-3-using-keyboard-commands}
18558
- * that can be assigned to a specific hotkey in the platform manifest.
18559
- * @property {string} hotkeys.keys The key combination of the hotkey, i.e. "Ctrl+T"
18560
- * @property {boolean} [hotkeys.preventDefault=false] Whether or not to prevent default key handling before emitting the event
18561
- *
18562
- * @property {string} [icon] - _Updatable. Inheritable._
18563
- * A URL for the icon to be shown in the window title bar and the taskbar.
18564
- * When omitted, inherits from the parent application._
18565
- * note: Window OS caches taskbar icons, therefore an icon change might only be visible after the cache is removed or the uuid is changed.
18566
- *
18567
- * @property {number} [maxHeight=-1] - _Updatable._
18568
- * The maximum height of a window. Will default to the OS defined value if set to -1.
18569
- *
18570
- * @property {boolean} [maximizable=true] - _Updatable._
18571
- * A flag that lets the window be maximized.
18572
- *
18573
- * @property {number} [maxWidth=-1] - _Updatable._
18574
- * The maximum width of a window. Will default to the OS defined value if set to -1.
18575
- *
18576
- * @property {number} [minHeight=0] - _Updatable._
18577
- * The minimum height of a window.
18578
- *
18579
- * @property {boolean} [minimizable=true] - _Updatable._
18580
- * A flag that lets the window be minimized.
18581
- *
18582
- * @property {number} [minWidth=0] - _Updatable._
18583
- * The minimum width of a window.
18584
- *
18585
- * @property {Identity} [modalParentIdentity]
18586
- * Parent identity of a modal window. It will create a modal child window when this option is set.
18587
- *
18588
- * @property {string} name
18589
- * The name of the window.
18590
- *
18591
- * @property {number} [opacity=1.0] - _Updatable._
18592
- * A flag that specifies how transparent the window will be.
18593
- * Changing opacity doesn't work on Windows 7 without Aero so setting this value will have no effect there.
18594
- * This value is clamped between `0.0` and `1.0`.
18595
- * * In software composition mode, the runtime flag --allow-unsafe-compositing is required.
18596
- *
18597
- * @property {preloadScript[]} [preloadScripts] - _Inheritable_
18598
- * A list of scripts that are eval'ed before other scripts in the page. When omitted, _inherits_
18599
- * from the parent application.
18600
- *
18601
- * @property {string} [processAffinity]
18602
- * A string to attempt to group renderers together. Will only be used if pages are on the same origin.
18603
- *
18604
- * @property {boolean} [resizable=true] - _Updatable._
18605
- * A flag to allow the user to resize the window.
18606
- *
18607
- * @property {object} [resizeRegion] - _Updatable._
18608
- * Defines a region in pixels that will respond to user mouse interaction for resizing a frameless window.
18609
- * @property {number} [resizeRegion.bottomRightCorner=9]
18610
- * The size in pixels of an additional square resizable region located at the bottom right corner of a frameless window.
18611
- * @property {number} [resizeRegion.size=7]
18612
- * The size in pixels.
18613
- * @property {object} [resizeRegion.sides={top:true,right:true,bottom:true,left:true}]
18614
- * Sides that a window can be resized from.
18615
- *
18616
- * @property {boolean} [saveWindowState=true]
18617
- * A flag to cache the location of the window.
18618
- * ** note ** - This option is ignored in Platforms as it would cause inconsistent {@link Platform#applySnapshot applySnapshot} behavior.
18619
- *
18620
- * @property {boolean} [ignoreSavedWindowState]
18621
- * A flag to ignore previously cached state of the window. It defaults the opposite value of `saveWindowState` to maintain backwards compatibility.
18622
- *
18623
- * @property {boolean} [shadow=false]
18624
- * A flag to display a shadow on frameless windows.
18625
- * `shadow` and `cornerRounding` are mutually exclusive.
18626
- * On Windows 7, Aero theme is required.
18627
- *
18628
- * @property {boolean} [showBackgroundImages=false] - _Updatable._
18629
- * Platforms Only. If true, will show background images in the layout when the Views are hidden.
18630
- * This occurs when the window is resizing or a tab is being dragged within the layout.
18631
- *
18632
- * @property {boolean} [showTaskbarIcon=true] - _Updatable._ _Windows_.
18633
- * A flag to show the window's icon in the taskbar.
18634
- *
18635
- * @property {boolean} [smallWindow=false]
18636
- * A flag to specify a frameless window that can be be created and resized to less than 41x36 px (width x height).
18637
- * _Note: Caveats of small windows are no Aero Snap and drag to/from maximize._
18638
- * _Windows 10: Requires `maximizable` to be false. Resizing with the mouse is only possible down to 38x39 px._
18639
- *
18640
- * @property {boolean} [spellCheck=false]
18641
- * Enable spell check in input text fields for the window.
18642
- *
18643
- * @property {string} [state="normal"]
18644
- * The visible state of the window on creation.
18645
- * One of:
18646
- * * `"maximized"`
18647
- * * `"minimized"`
18648
- * * `"normal"`
18649
- *
18650
- * @property {string} [taskbarIcon=string] - Deprecated - use `icon` instead._Windows_.
18651
- *
18652
- * @property {string} [taskbarIconGroup=<application uuid>] - _Windows_.
18653
- * Specify a taskbar group for the window.
18654
- * _If omitted, defaults to app's uuid (`fin.Application.getCurrentSync().identity.uuid`)._
18655
- *
18656
- * @property {string} [url="about:blank"]
18657
- * The URL of the window.
18658
- *
18659
- * @property {string} [uuid=<application uuid>]
18660
- * The `uuid` of the application, unique within the set of all `Application`s running in OpenFin Runtime.
18661
- * If omitted, defaults to the `uuid` of the application spawning the window.
18662
- * If given, must match the `uuid` of the application spawning the window.
18663
- * In other words, the application's `uuid` is the only acceptable value, but is the default, so there's
18664
- * really no need to provide it.
18665
- *
18666
- * @property {boolean} [waitForPageLoad=false]
18667
- * When set to `true`, the window will not appear until the `window` object's `load` event fires.
18668
- * When set to `false`, the window will appear immediately without waiting for content to be loaded.
18669
- *
18670
- * @property {ViewVisibility} [viewVisibility]
18671
- * _Platform Windows Only_. Controls behavior for showing views when they are being resized by the user.
18672
- */
18673
- /**
18674
- * @PORTED
18675
- * @typedef {Object} ViewVisibility@typedef {Object} ViewVisibility _Platform Windows Only_. Controls behavior for showing views when they are being resized by the user.
18676
- * @property {ShowViewsOnWindowResize} [showViewsOnWindowResize] Enables views to be shown when a Platform Window is being resized by the user.
18677
- * @property {ShowViewsOnSplitterDrag} [showViewsOnSplitterDrag] Allows views to be shown when they are resized by the user dragging the splitter between layout stacks.
18678
- * @property {ShowViewsOnTabDrag} [showViewsOnTabDrag] _Supported on Windows Operating Systems only_. Allows views to be shown when the user is dragging a tab around a layout.
18679
- */
18680
- /**
18681
- * @PORTED
18682
- * @typedef {Object} ShowViewsOnWindowResize@typedef {Object} ShowViewsOnWindowResize _Platform Windows Only_. Enables views to be shown when a Platform Window is being resized by the user.
18683
- * @property {boolean} [enabled=false] Enables or disables showing Views when a Platform Window is being resized.
18684
- * @property {number} [paintIntervalMs=0] Number of miliseconds to wait between view repaints.
18685
- */
18686
- /**
18687
- * @REMOVED
18688
- * @typedef {Object} ShowViewsOnSplitterDrag@typedef {Object} ShowViewsOnSplitterDrag _Platform Windows Only_. Allows views to be shown when they are resized by the user dragging the splitter between layout stacks.
18689
- * @property {boolean} [enabled=false] Enables or disables showing views when the layout splitter is being dragged.
18690
- */
18691
- /**
18692
- * @REMOVED
18693
- * @typedef {Object} ShowViewsOnTabDrag@typedef {Object} ShowViewsOnTabDrag _Platform Windows Only_. Allows views to be shown when the user is manipulating the layout by repositioning a tab.
18694
- * @property {boolean} [enabled=false] Enables or disables showing views when a tab is being dragged.
18695
- */
18696
- /**
18697
- * @PORTED
18698
- * @typedef {object} CapturePageOptions@typedef {object} CapturePageOptions
18699
- * @property { Area } [area] The area of the window to be captured.
18700
- * @property { string } [format='png'] The format of the captured image. Can be 'png', 'jpg', or 'bmp'.
18701
- * @property { number } [quality=100] Number representing quality of JPEG image only. Between 0 - 100.
18702
- */
18703
- /**
18704
- * @PORTED
18705
- * @typedef { object } Area@typedef { object } Area
18706
- * @property { number } height Area's height
18707
- * @property { number } width Area's width
18708
- * @property { number } x X coordinate of area's starting point
18709
- * @property { number } y Y coordinate of area's starting point
18710
- */
18711
- /**
18712
- * @PORTED
18713
- * @typedef {object} FindInPageOptions@typedef {object} FindInPageOptions
18714
- * @property {boolean} [forward=true] Whether to search forward or backward.
18715
- * @property {boolean} [findNext=false] Whether to begin a new text finding session. Should be true for first requests, and false for subsequent requests. Defaults to false.
18716
- * @property {boolean} [matchCase=false] Whether search should be case-sensitive.
18717
- * @property {boolean} [wordStart=false] Whether to look only at the start of words.
18718
- * @property {boolean} [medialCapitalAsWordStart=false]
18719
- * When combined with wordStart, accepts a match in the middle of a word if the match begins with an uppercase letter followed by a<br>
18720
- * lowercase or non-letter. Accepts several other intra-word matches.
18721
- */
18722
- /**
18723
- * @REMOVED
18724
- * @typedef {object} Transition@typedef {object} Transition
18725
- * @property {Opacity} opacity - The Opacity transition
18726
- * @property {Position} position - The Position transition
18727
- * @property {Size} size - The Size transition
18728
- */
18729
- /**
18730
- * @PORTED
18731
- * @typedef {object} TransitionOptions@typedef {object} TransitionOptions
18732
- * @property {boolean} interrupt - This option interrupts the current animation. When false it pushes
18733
- this animation onto the end of the animation queue.
18734
- * @property {boolean} relative - Treat 'opacity' as absolute or as a delta. Defaults to false.
18735
- */
18736
- /**
18737
- * @PORTED
18738
- * @typedef {object} Size@typedef {object} Size
18739
- * @property {number} duration - The total time in milliseconds this transition should take.
18740
- * @property {boolean} relative - Treat 'opacity' as absolute or as a delta. Defaults to false.
18741
- * @property {number} width - Optional if height is present. Defaults to the window's current width.
18742
- * @property {number} height - Optional if width is present. Defaults to the window's current height.
18743
- */
18744
- /**
18745
- * @PORTED
18746
- * @typedef {object} Position@typedef {object} Position
18747
- * @property {number} duration - The total time in milliseconds this transition should take.
18748
- * @property {boolean} relative - Treat 'opacity' as absolute or as a delta. Defaults to false.
18749
- * @property {number} left - Defaults to the window's current left position in virtual screen coordinates.
18750
- * @property {number} top - Defaults to the window's current top position in virtual screen coordinates.
18751
- */
18752
- /**
18753
- * @PORTED
18754
- * @typedef {object} Opacity@typedef {object} Opacity
18755
- * @property {number} duration - The total time in milliseconds this transition should take.
18756
- * @property {boolean} relative - Treat 'opacity' as absolute or as a delta. Defaults to false.
18757
- * @property {number} opacity - This value is clamped from 0.0 to 1.0.
18758
- */
18759
- /**
18760
- * @REMOVED
18761
- * Bounds is a interface that has the properties of height,
18762
- * width, left, top which are all numbers
18763
- * @typedef { object } Bounds@typedef { object } Bounds
18764
- * @property { number } height Get the application height bound
18765
- * @property { number } width Get the application width bound
18766
- * @property { number } top Get the application top bound
18767
- * @property { number } left Get the application left bound
18768
- * @property { number } right Get the application right bound
18769
- * @property { number } bottom Get the application bottom bound
18770
- */
18771
17567
  /**
18772
17568
  * A basic window that wraps a native HTML window. Provides more fine-grained
18773
17569
  * control over the window state such as the ability to minimize, maximize, restore, etc.
@@ -18780,83 +17576,6 @@ declare class _Window extends WebContents<OpenFin.WindowEvent> {
18780
17576
  * @internal
18781
17577
  */
18782
17578
  constructor(wire: Transport, identity: OpenFin.Identity);
18783
- /**
18784
- * Adds a listener to the end of the listeners array for the specified event.
18785
- * @param eventType - The type of the event.
18786
- * @param listener - Called whenever an event of the specified type occurs.
18787
- * @param options - Option to support event timestamps.
18788
- *
18789
- * @function addListener
18790
- * @memberof Window
18791
- * @instance
18792
- * @tutorial Window.EventEmitter
18793
- */
18794
- /**
18795
- * Adds a listener to the end of the listeners array for the specified event.
18796
- * @param eventType - The type of the event.
18797
- * @param listener - Called whenever an event of the specified type occurs.
18798
- * @param options - Option to support event timestamps.
18799
- *
18800
- * @function on
18801
- * @memberof Window
18802
- * @instance
18803
- * @tutorial Window.EventEmitter
18804
- */
18805
- /**
18806
- * Adds a one time listener for the event. The listener is invoked only the first time the event is fired, after which it is removed.
18807
- * @param eventType - The type of the event.
18808
- * @param listener - The callback function.
18809
- * @param options - Option to support event timestamps.
18810
- *
18811
- * @function once
18812
- * @memberof Window
18813
- * @instance
18814
- * @tutorial Window.EventEmitter
18815
- */
18816
- /**
18817
- * Adds a listener to the beginning of the listeners array for the specified event.
18818
- * @param eventType - The type of the event.
18819
- * @param listener - The callback function.
18820
- * @param options - Option to support event timestamps.
18821
- *
18822
- * @function prependListener
18823
- * @memberof Window
18824
- * @instance
18825
- * @tutorial Window.EventEmitter
18826
- */
18827
- /**
18828
- * Adds a one time listener for the event. The listener is invoked only the first time the event is fired, after which it is removed.
18829
- * The listener is added to the beginning of the listeners array.
18830
- * @param eventType - The type of the event.
18831
- * @param listener - The callback function.
18832
- * @param options - Option to support event timestamps.
18833
- *
18834
- * @function prependOnceListener
18835
- * @memberof Window
18836
- * @instance
18837
- * @tutorial Window.EventEmitter
18838
- */
18839
- /**
18840
- * Remove a listener from the listener array for the specified event.
18841
- * Caution: Calling this method changes the array indices in the listener array behind the listener.
18842
- * @param eventType - The type of the event.
18843
- * @param listener - The callback function.
18844
- * @param options - Option to support event timestamps.
18845
- *
18846
- * @function removeListener
18847
- * @memberof Window
18848
- * @instance
18849
- * @tutorial Window.EventEmitter
18850
- */
18851
- /**
18852
- * Removes all listeners, or those of the specified event.
18853
- * @param eventType - The type of the event.
18854
- *
18855
- * @function removeAllListeners
18856
- * @memberof Window
18857
- * @instance
18858
- * @tutorial Window.EventEmitter
18859
- */
18860
17579
  /**
18861
17580
  * create a new window
18862
17581
  * @internal
@@ -19637,10 +18356,9 @@ declare class _Window extends WebContents<OpenFin.WindowEvent> {
19637
18356
  show(force?: boolean): Promise<void>;
19638
18357
  /**
19639
18358
  * Shows the window if it is hidden at the specified location.
19640
- * If the toggle parameter is set to true, the window will
19641
- * alternate between showing and hiding.
19642
- * @param left The left position of the window
19643
- * @param top The right position of the window
18359
+ *
18360
+ * @param left The left position of the window in pixels
18361
+ * @param top The top position of the window in pixels
19644
18362
  * @param force Show will be prevented from closing when force is false and
19645
18363
  * ‘show-requested’ has been subscribed to for application’s main window
19646
18364
  *
@@ -19702,28 +18420,6 @@ declare class _Window extends WebContents<OpenFin.WindowEvent> {
19702
18420
  * ```
19703
18421
  */
19704
18422
  authenticate(userName: string, password: string): Promise<void>;
19705
- /**
19706
- * @typedef {object} ShowPopupMenuOptions@typedef {object} ShowPopupMenuOptions
19707
- * @property {Array<MenuItemTemplate>} template - An array describing the menu to show.
19708
- * @property {number} [x] - The window x coordinate where to show the menu. Defaults to mouse position. If using must also use `y`.
19709
- * @property {number} [y] - The window y coordinate where to show the menu. Defaults to mouse position. If using must also use `x`
19710
- */
19711
- /**
19712
- * @typedef {object} MenuItemTemplate@typedef {object} MenuItemTemplate
19713
- * @property {*} data - Data to be returned if the user selects the element. Must be serializable. Large objects can have a performance impact.
19714
- * @property {'normal' | 'separator' | 'submenu' | 'checkbox'} [type] - Defaults to 'normal' unless a 'submenu' key exists
19715
- * @property {string} [label] - The text to show on the menu item. Should be left undefined for `type: 'separator'`
19716
- * @property {boolean} [enabled] - If false, the menu item will be greyed out and unclickable.
19717
- * @property {boolean} [visible] - If false, the menu item will be entirely hidden.
19718
- * @property {boolean} [checked] - Should only be specified for `checkbox` type menu items.
19719
- * @property {string} [icon] - Image Data URI with image dimensions inferred from the encoded string
19720
- * @property {Array<MenuItemTemplate>} [submenu] Should be specified for `submenu` type menu items. If `submenu` is specified, the `type: 'submenu'` can be omitted.
19721
- */
19722
- /**
19723
- * @typedef {object} MenuResult@typedef {object} MenuResult
19724
- * @property {'clicked' | 'closed'} result - Whether the user clicked on a menu item or the menu was closed (user clicked elsewhere).
19725
- * @property {* | undefined} [data] - The data property of the menu item clicked by the user. Only defined if result was `clicked`.
19726
- */
19727
18423
  /**
19728
18424
  * Shows a menu on the window.
19729
18425
  *
@@ -19820,590 +18516,565 @@ declare class _Window extends WebContents<OpenFin.WindowEvent> {
19820
18516
  */
19821
18517
  closePopupMenu(): Promise<void>;
19822
18518
  /**
19823
- * @PORTED
19824
- * @typedef {object} PopupOptions@typedef {object} PopupOptions
19825
- * @property {string} [name] - If a window with this `name` exists, it will be shown as a popup. Otherwise, a new window with this `name` will be created. If this `name` is undefined, `initialOptions.name` will be used. If this `name` and `intialOptions.name` are both undefined, a `name` will be generated.
19826
- * @property {string} [url] - Navigates to this `url` if showing an existing window as a popup, otherwise the newly created window will load this `url`.
19827
- * @property {Window~options} [initialOptions] - Window creation options when using `showPopupWindow` to create a new window.
19828
- * @property {Window~options} [additionalOptions] - Updatable window options applied to new and existing windows when shown as popups.
19829
- * @property {function} [onPopupResult] - Executed when this window's popup calls `dispatchPopupResult`. Note: if this is defined, `showPopupWindow` will not return a `PopupResult`.
19830
- * @property {function} [onPopupReady] - Executed when the popup window is shown. Provides the popup window to the provided function, and allows for easy access the popup window for additional behavior customization.
19831
- * @property {number} [height] - Height of the popup window (takes priority over `intialOptions` size properties).
19832
- * @property {number} [width] - Width of the popup window (takes priority over `intialOptions` size properties).
19833
- * @property {number} [x] - Left position where the popup window will be shown (relative to the window calling `showPopupWindow`).
19834
- * @property {number} [y] - Top position where the popup window will be shown (relative to the window calling `showPopupWindow`).
19835
- * @property {'modal' | 'hide' | 'close'} [blurBehavior] - Determines what happens if the popup window is blurred. 'modal' restricts resizing and positioning in the caller, 'hide' hides the popup window on blur and 'close' closes the popup window on blur.
19836
- * @property {'none' | 'hide' | 'close'} [resultDispatchBehavior] - Determines what happens when the popup window calls `dispatchPopupResult`. 'none' will do nothing, 'hide' hides the popup window on `dispatchPopupResult` and 'close' closes the popup window on `dispatchPopupResult`.
19837
- * @property {boolean} [focus] - Determines if the popup window should or should not be focused when it is shown.
19838
- * @property {boolean} [hideOnClose] - Hide the popup window instead of closing whenever `close` is called on it. Note: if this is `true` and `blurBehavior` and/or `resultDispatchBehavior` are set to `close`, the window will be hidden.
19839
- */
19840
- /**
19841
- * @PORTED
19842
- * @typedef {object} PopupResult@typedef {object} PopupResult
19843
- * @property {Identity} identity - `name` and `uuid` of the popup window that called dispatched this result.
19844
- * @property {'clicked' | 'dismissed'} result - Result of the user interaction with the popup window.
19845
- * @property {* | undefined} [data] - Data passed to `dispatchPopupResult`.
19846
- */
19847
- /**
19848
- * Dispatch a result to the caller of `showPopupWindow`.
19849
- *
19850
- * @remarks If this window isn't currently being shown as a popup, this call will silently fail.
19851
- * @param data Serializable data to send to the caller window.
19852
- *
19853
- * @example
19854
- * ```js
19855
- * await fin.me.dispatchPopupResult({
19856
- * foo: 'bar'
19857
- * });
19858
- * ```
19859
- */
19860
- dispatchPopupResult(data: any): Promise<void>;
19861
- /**
19862
- * Prints the contents of the window.
19863
- *
19864
- * @param options Configuration for the print task.
19865
- * @remarks When `silent` is set to `true`, the API will pick the system's default printer if deviceName is empty
19866
- * and the default settings for printing.
19867
- *
19868
- * Use the CSS style `page-break-before: always;` to force print to a new page.
19869
- *
19870
- * @example
19871
- * ```js
19872
- * const win = fin.Window.getCurrentSync();
19873
- *
19874
- * win.print({ silent: false, deviceName: 'system-printer-name' }).then(() => {
19875
- * console.log('print call has been sent to the system');
19876
- * });
19877
- * ```
19878
- *
19879
- * If a window has embedded views, those views will not print by default. To print a window's contents including embedded views,
19880
- * use the `content` option:
19881
- *
19882
- * ```js
19883
- * const win = fin.Window.getCurrentSync();
19884
- *
19885
- * // Print embedded views
19886
- * win.print({ content: 'views' });
19887
- *
19888
- * // Print screenshot of current window
19889
- * win.print({ content: 'screenshot' })
19890
- * ```
19891
- *
19892
- * When `content` is set to `views`, the embedded views in the platform window will be concatenated and printed as
19893
- * individual pages. If `includeSelf` is set to `true`, the platform window itself will be printed as the first
19894
- * page - be aware that this page will *not* include the embedded views - it will only include the contents of
19895
- * the platform window itself (e.g. tab stacks), with blank spaces where the view contents would be embedded.
19896
- *
19897
- * Due to a known issue, view contents that are not visible at the time `print` is called will not appear when
19898
- * printing `contents: views`. This includes views that are obscured behind other active UI elements.
19899
- *
19900
- * To print the views embedded in their page context, set `content` to `screenshot`.
19901
- */
19902
- print(options?: OpenFin.WindowPrintOptions): Promise<void>;
19903
- }
19904
-
19905
- /**
19906
- * Generated when an alert is fired and suppressed due to the customWindowAlert flag being true.
19907
- * @interface
19908
- */
19909
- declare type WindowAlertRequestedEvent = BaseEvent_3 & {
19910
- type: 'window-alert-requested';
19911
- };
19912
-
19913
- /**
19914
- * Returned from getBounds call. bottom and right are never used for setting.
19915
- * @interface
19916
- */
19917
- declare type WindowBounds = Bounds & {
19918
- bottom: number;
19919
- right: number;
19920
- };
19921
-
19922
- /**
19923
- * @deprecated Renamed to {@link ClosedEvent}.
19924
- */
19925
- declare type WindowClosedEvent = ClosedEvent_2;
19926
-
19927
- /**
19928
- * @deprecated Renamed to {@link CloseRequestedEvent}.
19929
- */
19930
- declare type WindowCloseRequestedEvent = CloseRequestedEvent;
19931
-
19932
- /**
19933
- * @deprecated Renamed to {@link ClosingEvent}.
19934
- */
19935
- declare type WindowClosingEvent = ClosingEvent;
19936
-
19937
- /**
19938
- * A rule prescribing content creation in a {@link OpenFin.Window}.
19939
- *
19940
- * @interface
19941
- */
19942
- declare type WindowContentCreationRule = BaseContentCreationRule & {
19943
- /**
19944
- * Behavior to use when opening matched content.
19945
- */
19946
- behavior: 'window';
19947
- /**
19948
- * Options for newly-created window.
19949
- */
19950
- options?: Partial<WindowOptions>;
19951
- };
19952
-
19953
- /**
19954
- * Generated when a child window is created.
19955
- * @interface
19956
- */
19957
- declare type WindowCreatedEvent = BaseEvent_3 & {
19958
- type: 'window-created';
19959
- };
19960
-
19961
- /**
19962
- * Options required to create a new window with {@link Window._WindowModule.create Window.create}.
19963
- *
19964
- * Note that `name` is the only required property — albeit the `url` property is usually provided as well
19965
- * (defaults to `"about:blank"` when omitted).
19966
- * @interface
19967
- */
19968
- declare type WindowCreationOptions = Partial<WindowOptions> & {
19969
- name: string;
19970
- };
19971
-
19972
- declare type WindowCreationReason = 'tearout' | 'create-view-without-target' | 'api-call' | 'app-creation' | 'restore' | 'apply-snapshot';
19973
-
19974
- /**
19975
- * @interface
19976
- */
19977
- declare type WindowDetail = {
19978
- /**
19979
- * The bottom-most coordinate of the window.
19980
- */
19981
- bottom: number;
19982
- /**
19983
- * The height of the window.
19984
- */
19985
- height: number;
19986
- isShowing: boolean;
19987
- /**
19988
- * The left-most coordinate of the window.
19989
- */
19990
- left: number;
19991
- /**
19992
- * The name of the window.
19993
- */
19994
- name: string;
19995
- /**
19996
- * The right-most coordinate of the window.
19997
- */
19998
- right: number;
19999
- state: string;
20000
- /**
20001
- * The top-most coordinate of the window.
20002
- */
20003
- top: number;
20004
- /**
20005
- * The width of the window.
20006
- */
20007
- width: number;
20008
- };
20009
-
20010
- /**
20011
- * Generated when a child window ends loading.
20012
- * @interface
20013
- */
20014
- declare type WindowEndLoadEvent = BaseEvent_3 & {
20015
- type: 'window-end-load';
20016
- };
20017
-
20018
- /**
20019
- * @deprecated, Renamed to {@link Event}.
20020
- */
20021
- declare type WindowEvent = Event_6;
20022
-
20023
- declare type WindowEvent_2 = Events.WindowEvents.WindowEvent;
20024
-
20025
- declare namespace WindowEvents {
20026
- export {
20027
- BaseEvent_5 as BaseEvent,
20028
- BaseWindowEvent,
20029
- ViewAttachedEvent,
20030
- ViewDetachedEvent,
20031
- WindowViewEvent,
20032
- AlertRequestedEvent,
20033
- AuthRequestedEvent,
20034
- EndLoadEvent,
20035
- WillRedirectEvent,
20036
- ReloadedEvent,
20037
- OptionsChangedEvent,
20038
- WindowOptionsChangedEvent_2 as WindowOptionsChangedEvent,
20039
- ExternalProcessExitedEvent,
20040
- ExternalProcessStartedEvent,
20041
- HiddenEvent_2 as HiddenEvent,
20042
- WindowHiddenEvent,
20043
- PreloadScriptInfoRunning,
20044
- PreloadScriptInfo,
20045
- PreloadScriptsStateChangeEvent,
20046
- UserBoundsChangeEvent,
20047
- BoundsChangeEvent,
20048
- WillMoveOrResizeEvent,
20049
- PerformanceReportEvent,
20050
- InputEvent_2 as InputEvent,
20051
- LayoutInitializedEvent,
20052
- LayoutReadyEvent,
20053
- BeginUserBoundsChangingEvent,
20054
- BoundsChangedEvent,
20055
- BoundsChangingEvent,
20056
- CloseRequestedEvent,
20057
- WindowCloseRequestedEvent,
20058
- ContextChangedEvent,
20059
- ClosedEvent_2 as ClosedEvent,
20060
- WindowClosedEvent,
20061
- ClosingEvent,
20062
- WindowClosingEvent,
20063
- DisabledMovementBoundsChangedEvent,
20064
- DisabledMovementBoundsChangingEvent,
20065
- EmbeddedEvent,
20066
- EndUserBoundsChangingEvent,
20067
- HotkeyEvent_2 as HotkeyEvent,
20068
- WindowHotkeyEvent,
20069
- InitializedEvent_2 as InitializedEvent,
20070
- WindowInitializedEvent,
20071
- MaximizedEvent,
20072
- MinimizedEvent,
20073
- PreloadScriptsStateChangedEvent,
20074
- PreloadScriptsStateChangingEvent,
20075
- RestoredEvent,
20076
- WindowRestoredEvent,
20077
- ShowRequestedEvent,
20078
- WindowShowRequestedEvent,
20079
- ShownEvent_2 as ShownEvent,
20080
- WindowShownEvent,
20081
- UserMovementEnabledEvent,
20082
- UserMovementDisabledEvent,
20083
- WillMoveEvent,
20084
- WillResizeEvent,
20085
- NonPropagatedWindowEvent,
20086
- ShowAllDownloadsEvent,
20087
- DownloadShelfVisibilityChangedEvent,
20088
- WindowSourcedEvent,
20089
- WillPropagateWindowEvent,
20090
- Event_6 as Event,
20091
- WindowEvent,
20092
- EventType_2 as EventType,
20093
- WindowEventType,
20094
- PropagatedEvent_3 as PropagatedEvent,
20095
- PropagatedWindowEvent,
20096
- PropagatedWindowEventType,
20097
- Payload_3 as Payload,
20098
- ByType_2 as ByType
20099
- }
20100
- }
20101
-
20102
- /**
20103
- * @deprecated Renamed to {@link EventType}.
20104
- */
20105
- declare type WindowEventType = WindowEvent['type'];
20106
-
20107
- /**
20108
- * @deprecated Renamed to {@link HiddenEvent}.
20109
- */
20110
- declare type WindowHiddenEvent = HiddenEvent_2;
20111
-
20112
- /**
20113
- * @deprecated Renamed to {@link HotkeyEvent}.
20114
- */
20115
- declare type WindowHotkeyEvent = HotkeyEvent_2;
20116
-
20117
- /**
20118
- * @interface
20119
- */
20120
- declare type WindowInfo = {
20121
- canNavigateBack: boolean;
20122
- canNavigateForward: boolean;
20123
- preloadScripts: Array<any>;
20124
- title: string;
20125
- url: string;
20126
- };
20127
-
20128
- /**
20129
- * @deprecated Renamed to {@link InitializedEvent}.
20130
- */
20131
- declare type WindowInitializedEvent = InitializedEvent_2;
20132
-
20133
- /**
20134
- * Static namespace for OpenFin API methods that interact with the {@link _Window} class, available under `fin.Window`.
20135
- */
20136
- declare class _WindowModule extends Base {
20137
- /**
20138
- * Asynchronously returns a Window object that represents an existing window.
20139
- *
20140
- * @example
20141
- * ```js
20142
- * async function createWin() {
20143
- * const app = await fin.Application.start({
20144
- * name: 'myApp',
20145
- * uuid: 'app-1',
20146
- * url: 'https://cdn.openfin.co/docs/javascript/stable/tutorial-Window.wrap.html',
20147
- * autoShow: true
20148
- * });
20149
- * return await app.getWindow();
20150
- * }
20151
- * createWin().then(() => fin.Window.wrap({ uuid: 'app-1', name: 'myApp' }))
20152
- * .then(win => console.log('wrapped window'))
20153
- * .catch(err => console.log(err));
20154
- * ```
20155
- */
20156
- wrap(identity: OpenFin.Identity): Promise<OpenFin.Window>;
20157
- /**
20158
- * Synchronously returns a Window object that represents an existing window.
20159
- *
20160
- * @example
20161
- * ```js
20162
- * async function createWin() {
20163
- * const app = await fin.Application.start({
20164
- * name: 'myApp',
20165
- * uuid: 'app-1',
20166
- * url: 'https://cdn.openfin.co/docs/javascript/stable/tutorial-Window.wrapSync.html',
20167
- * autoShow: true
20168
- * });
20169
- * return await app.getWindow();
20170
- * }
20171
- * await createWin();
20172
- * let win = fin.Window.wrapSync({ uuid: 'app-1', name: 'myApp' });
20173
- * ```
20174
- */
20175
- wrapSync(identity: OpenFin.Identity): OpenFin.Window;
20176
- /**
20177
- * Creates a new Window.
20178
- * @param options - Window creation options
20179
- *
20180
- * @example
20181
- * ```js
20182
- * async function createWindow() {
20183
- * const winOption = {
20184
- * name:'child',
20185
- * defaultWidth: 300,
20186
- * defaultHeight: 300,
20187
- * url: 'https://cdn.openfin.co/docs/javascript/stable/tutorial-Window.create.html',
20188
- * frame: true,
20189
- * autoShow: true
20190
- * };
20191
- * return await fin.Window.create(winOption);
20192
- * }
20193
- *
20194
- * createWindow().then(() => console.log('Window is created')).catch(err => console.log(err));
20195
- * ```
20196
- */
20197
- create(options: OpenFin.WindowCreationOptions): Promise<OpenFin.Window>;
20198
- /**
20199
- * Asynchronously returns a Window object that represents the current window
20200
- *
20201
- * @example
20202
- * ```js
20203
- * fin.Window.getCurrent()
20204
- * .then(wnd => console.log('current window'))
20205
- * .catch(err => console.log(err));
20206
- *
20207
- * ```
20208
- */
20209
- getCurrent(): Promise<OpenFin.Window>;
20210
- /**
20211
- * Synchronously returns a Window object that represents the current window
20212
- *
20213
- * @example
20214
- * ```js
20215
- * const wnd = fin.Window.getCurrentSync();
20216
- * const info = await wnd.getInfo();
20217
- * console.log(info);
20218
- *
20219
- * ```
20220
- */
20221
- getCurrentSync(): OpenFin.Window;
20222
- }
20223
-
20224
- /**
20225
- * Generated when a child window is not responding.
20226
- * @interface
20227
- */
20228
- declare type WindowNotRespondingEvent = BaseEvent_3 & {
20229
- type: 'window-not-responding';
20230
- };
20231
-
20232
- /**
20233
- * @interface
20234
- */
20235
- declare type WindowOptionDiff = {
20236
- [key in keyof WindowOptions]: {
20237
- oldVal: WindowOptions[key];
20238
- newVal: WindowOptions[key];
20239
- };
20240
- };
20241
-
20242
- /**
20243
- * @interface
20244
- */
20245
- declare type WindowOptions = MutableWindowOptions & ConstWindowOptions;
20246
-
20247
- declare type WindowOptionsChangedEvent = OpenFin.WindowEvents.WindowOptionsChangedEvent;
20248
-
20249
- /**
20250
- * @deprecated Renamed to {@link OptionsChangedEvent}.
20251
- */
20252
- declare type WindowOptionsChangedEvent_2 = OptionsChangedEvent;
20253
-
20254
- declare type WindowPrintOptions = PrintOptions | ScreenshotPrintOptions | WindowViewsPrintOptions;
20255
-
20256
- /**
20257
- * Generated when a child window is responding.
20258
- * @interface
20259
- */
20260
- declare type WindowRespondingEvent = BaseEvent_3 & {
20261
- type: 'window-responding';
20262
- };
20263
-
20264
- /**
20265
- * @deprecated Renamed to {@link RestoredEvent}.
20266
- */
20267
- declare type WindowRestoredEvent = RestoredEvent;
20268
-
20269
- /**
20270
- * @deprecated Renamed to {@link ShownEvent}.
20271
- */
20272
- declare type WindowShownEvent = ShownEvent_2;
20273
-
20274
- /**
20275
- * @deprecated Renamed to {@link ShowRequestedEvent}.
20276
- */
20277
- declare type WindowShowRequestedEvent = ShowRequestedEvent;
20278
-
20279
- /**
20280
- * A union of all events that emit natively on the `Window` topic, i.e. excluding those that propagate
20281
- * from {@link OpenFin.ViewEvents}.
20282
- */
20283
- declare type WindowSourcedEvent = WebContentsEvents.Event<'window'> | WindowViewEvent | AuthRequestedEvent | BeginUserBoundsChangingEvent | BoundsChangedEvent | BoundsChangingEvent | ContextChangedEvent | CloseRequestedEvent | ClosedEvent_2 | ClosingEvent | DisabledMovementBoundsChangedEvent | DisabledMovementBoundsChangingEvent | EmbeddedEvent | EndUserBoundsChangingEvent | ExternalProcessExitedEvent | ExternalProcessStartedEvent | HiddenEvent_2 | HotkeyEvent_2 | InitializedEvent_2 | LayoutInitializedEvent | LayoutReadyEvent | MaximizedEvent | MinimizedEvent | OptionsChangedEvent | PerformanceReportEvent | PreloadScriptsStateChangedEvent | PreloadScriptsStateChangingEvent | ReloadedEvent | RestoredEvent | ShowRequestedEvent | ShownEvent_2 | UserMovementDisabledEvent | UserMovementEnabledEvent | WillMoveEvent | WillRedirectEvent | WillResizeEvent | ShowAllDownloadsEvent | DownloadShelfVisibilityChangedEvent;
20284
-
20285
- /**
20286
- * Generated when a child window starts loading.
20287
- * @interface
20288
- */
20289
- declare type WindowStartLoadEvent = BaseEvent_3 & {
20290
- type: 'window-start-load';
20291
- };
20292
-
20293
- /**
20294
- * Visibility state of a window.
20295
- */
20296
- declare type WindowState = 'maximized' | 'minimized' | 'normal';
20297
-
20298
- /**
20299
- * A view-related event that fires natively on the `Window` topic. This means that these events *do* propagate
20300
- * to the `Application` level, with the name pattern `window-view-eventname`.
20301
- */
20302
- declare type WindowViewEvent = {
20303
- viewIdentity: OpenFin.Identity;
20304
- } & (ViewAttachedEvent | ViewDetachedEvent);
20305
-
20306
- /**
20307
- * @interface
20308
- */
20309
- declare type WindowViewsPrintOptions = {
20310
- content: 'views';
20311
- includeSelf?: boolean;
20312
- };
20313
-
20314
- declare type Wire = EventEmitter & {
20315
- connect(messageReciever: MessageReceiver): Promise<any>;
20316
- connectSync(): any;
20317
- send(data: any): Promise<any>;
20318
- shutdown(): Promise<void>;
20319
- getPort(): string;
20320
- };
20321
-
20322
- declare type WireConstructor = {
20323
- new (onmessage: (data: any) => void): Wire;
20324
- };
20325
-
20326
- /**
20327
- * @internal
20328
- */
20329
- declare type WithId<T extends AppVersionEventType> = `${T}.${string}`;
20330
-
20331
- declare interface WithInterop {
20332
- interop: InteropClient;
20333
- }
20334
-
20335
- /**
20336
- * @internal
20337
- */
20338
- declare type WithoutId<T extends string> = T extends WithId<infer U> ? U : never;
20339
-
20340
- declare type WithPositioningOptions<T extends {} = {}> = T & {
20341
- positioningOptions?: OpenFin.PositioningOptions;
20342
- };
20343
-
20344
- /**
20345
- * @internal
20346
- * @interface
20347
- */
20348
- declare type WorkspacePlatformOptions = {
20349
- /** Leaving this as any for now until we figure out what the shape should look like in Workspace */
20350
- [key: string]: any;
20351
- };
20352
-
20353
- /**
20354
- * A generic request to write any supported data to the clipboard.
20355
- * @interface
20356
- */
20357
- declare type WriteAnyClipboardRequest = BaseClipboardRequest & {
20358
- /**
20359
- * Data to be written
20360
- */
20361
- data: {
20362
- text?: string;
20363
- html?: string;
20364
- rtf?: string;
20365
- } & Partial<Pick<WriteImageClipboardRequest, 'image'>>;
20366
- };
20367
-
20368
- /**
20369
- * @deprecated - instead use WriteAnyClipboardRequest
20370
- *
20371
- * A generic request to write any supported data to the clipboard.
20372
- *
20373
- * @interface
20374
- */
20375
- declare type WriteAnyRequestType = WriteAnyClipboardRequest;
20376
-
20377
- /**
20378
- * A request to write data to the clipboard.
20379
- * @interface
20380
- */
20381
- declare type WriteClipboardRequest = BaseClipboardRequest & {
20382
- /**
20383
- * Data to write to the clipboard.
20384
- */
20385
- data: string;
20386
- };
20387
-
20388
- /**
20389
- * @interface
20390
- */
20391
- declare type WriteImageClipboardRequest = BaseClipboardRequest & {
20392
- /**
20393
- * Can be either a base64 string, or a DataURL string. If using DataURL, the
20394
- * supported formats are `data:image/png[;base64],` and `data:image/jpeg[;base64],`.
20395
- * Using other image/<format> DataURLs will throw an Error.
20396
- */
20397
- image: string;
20398
- };
20399
-
20400
- /**
20401
- * @deprecated - instead use OpenFin.WriteClipboardRequest
20402
- *
20403
- * A request to write data to the clipboard.
20404
- *
20405
- * @interface
20406
- */
20407
- declare type WriteRequestType = WriteClipboardRequest;
20408
-
20409
- export { }
18519
+ * Dispatch a result to the caller of `showPopupWindow`.
18520
+ *
18521
+ * @remarks If this window isn't currently being shown as a popup, this call will silently fail.
18522
+ * @param data Serializable data to send to the caller window.
18523
+ *
18524
+ * @example
18525
+ * ```js
18526
+ * await fin.me.dispatchPopupResult({
18527
+ * foo: 'bar'
18528
+ * });
18529
+ * ```
18530
+ */
18531
+ dispatchPopupResult(data: any): Promise<void>;
18532
+ /**
18533
+ * Prints the contents of the window.
18534
+ *
18535
+ * @param options Configuration for the print task.
18536
+ * @remarks When `silent` is set to `true`, the API will pick the system's default printer if deviceName is empty
18537
+ * and the default settings for printing.
18538
+ *
18539
+ * Use the CSS style `page-break-before: always;` to force print to a new page.
18540
+ *
18541
+ * @example
18542
+ * ```js
18543
+ * const win = fin.Window.getCurrentSync();
18544
+ *
18545
+ * win.print({ silent: false, deviceName: 'system-printer-name' }).then(() => {
18546
+ * console.log('print call has been sent to the system');
18547
+ * });
18548
+ * ```
18549
+ *
18550
+ * If a window has embedded views, those views will not print by default. To print a window's contents including embedded views,
18551
+ * use the `content` option:
18552
+ *
18553
+ * ```js
18554
+ * const win = fin.Window.getCurrentSync();
18555
+ *
18556
+ * // Print embedded views
18557
+ * win.print({ content: 'views' });
18558
+ *
18559
+ * // Print screenshot of current window
18560
+ * win.print({ content: 'screenshot' })
18561
+ * ```
18562
+ *
18563
+ * When `content` is set to `views`, the embedded views in the platform window will be concatenated and printed as
18564
+ * individual pages. If `includeSelf` is set to `true`, the platform window itself will be printed as the first
18565
+ * page - be aware that this page will *not* include the embedded views - it will only include the contents of
18566
+ * the platform window itself (e.g. tab stacks), with blank spaces where the view contents would be embedded.
18567
+ *
18568
+ * Due to a known issue, view contents that are not visible at the time `print` is called will not appear when
18569
+ * printing `contents: views`. This includes views that are obscured behind other active UI elements.
18570
+ *
18571
+ * To print the views embedded in their page context, set `content` to `screenshot`.
18572
+ */
18573
+ print(options?: OpenFin.WindowPrintOptions): Promise<void>;
18574
+ }
18575
+
18576
+ /**
18577
+ * Generated when an alert is fired and suppressed due to the customWindowAlert flag being true.
18578
+ * @interface
18579
+ */
18580
+ declare type WindowAlertRequestedEvent = BaseEvent_3 & {
18581
+ type: 'window-alert-requested';
18582
+ };
18583
+
18584
+ /**
18585
+ * Returned from getBounds call. bottom and right are never used for setting.
18586
+ * @interface
18587
+ */
18588
+ declare type WindowBounds = Bounds & {
18589
+ bottom: number;
18590
+ right: number;
18591
+ };
18592
+
18593
+ /**
18594
+ * @deprecated Renamed to {@link ClosedEvent}.
18595
+ */
18596
+ declare type WindowClosedEvent = ClosedEvent_2;
18597
+
18598
+ /**
18599
+ * @deprecated Renamed to {@link CloseRequestedEvent}.
18600
+ */
18601
+ declare type WindowCloseRequestedEvent = CloseRequestedEvent;
18602
+
18603
+ /**
18604
+ * @deprecated Renamed to {@link ClosingEvent}.
18605
+ */
18606
+ declare type WindowClosingEvent = ClosingEvent;
18607
+
18608
+ /**
18609
+ * A rule prescribing content creation in a {@link OpenFin.Window}.
18610
+ *
18611
+ * @interface
18612
+ */
18613
+ declare type WindowContentCreationRule = BaseContentCreationRule & {
18614
+ /**
18615
+ * Behavior to use when opening matched content.
18616
+ */
18617
+ behavior: 'window';
18618
+ /**
18619
+ * Options for newly-created window.
18620
+ */
18621
+ options?: Partial<WindowOptions>;
18622
+ };
18623
+
18624
+ /**
18625
+ * Generated when a child window is created.
18626
+ * @interface
18627
+ */
18628
+ declare type WindowCreatedEvent = BaseEvent_3 & {
18629
+ type: 'window-created';
18630
+ };
18631
+
18632
+ /**
18633
+ * Options required to create a new window with {@link Window._WindowModule.create Window.create}.
18634
+ *
18635
+ * Note that `name` is the only required property — albeit the `url` property is usually provided as well
18636
+ * (defaults to `"about:blank"` when omitted).
18637
+ * @interface
18638
+ */
18639
+ declare type WindowCreationOptions = Partial<WindowOptions> & {
18640
+ name: string;
18641
+ };
18642
+
18643
+ declare type WindowCreationReason = 'tearout' | 'create-view-without-target' | 'api-call' | 'app-creation' | 'restore' | 'apply-snapshot';
18644
+
18645
+ /**
18646
+ * @interface
18647
+ */
18648
+ declare type WindowDetail = {
18649
+ /**
18650
+ * The bottom-most coordinate of the window.
18651
+ */
18652
+ bottom: number;
18653
+ /**
18654
+ * The height of the window.
18655
+ */
18656
+ height: number;
18657
+ isShowing: boolean;
18658
+ /**
18659
+ * The left-most coordinate of the window.
18660
+ */
18661
+ left: number;
18662
+ /**
18663
+ * The name of the window.
18664
+ */
18665
+ name: string;
18666
+ /**
18667
+ * The right-most coordinate of the window.
18668
+ */
18669
+ right: number;
18670
+ state: string;
18671
+ /**
18672
+ * The top-most coordinate of the window.
18673
+ */
18674
+ top: number;
18675
+ /**
18676
+ * The width of the window.
18677
+ */
18678
+ width: number;
18679
+ };
18680
+
18681
+ /**
18682
+ * Generated when a child window ends loading.
18683
+ * @interface
18684
+ */
18685
+ declare type WindowEndLoadEvent = BaseEvent_3 & {
18686
+ type: 'window-end-load';
18687
+ };
18688
+
18689
+ /**
18690
+ * @deprecated, Renamed to {@link Event}.
18691
+ */
18692
+ declare type WindowEvent = Event_6;
18693
+
18694
+ declare type WindowEvent_2 = Events.WindowEvents.WindowEvent;
18695
+
18696
+ declare namespace WindowEvents {
18697
+ export {
18698
+ BaseEvent_5 as BaseEvent,
18699
+ BaseWindowEvent,
18700
+ ViewAttachedEvent,
18701
+ ViewDetachedEvent,
18702
+ WindowViewEvent,
18703
+ AlertRequestedEvent,
18704
+ AuthRequestedEvent,
18705
+ EndLoadEvent,
18706
+ WillRedirectEvent,
18707
+ ReloadedEvent,
18708
+ OptionsChangedEvent,
18709
+ WindowOptionsChangedEvent_2 as WindowOptionsChangedEvent,
18710
+ ExternalProcessExitedEvent,
18711
+ ExternalProcessStartedEvent,
18712
+ HiddenEvent_2 as HiddenEvent,
18713
+ WindowHiddenEvent,
18714
+ PreloadScriptInfoRunning,
18715
+ PreloadScriptInfo,
18716
+ PreloadScriptsStateChangeEvent,
18717
+ UserBoundsChangeEvent,
18718
+ BoundsChangeEvent,
18719
+ WillMoveOrResizeEvent,
18720
+ PerformanceReportEvent,
18721
+ InputEvent_2 as InputEvent,
18722
+ LayoutInitializedEvent,
18723
+ LayoutReadyEvent,
18724
+ BeginUserBoundsChangingEvent,
18725
+ BoundsChangedEvent,
18726
+ BoundsChangingEvent,
18727
+ CloseRequestedEvent,
18728
+ WindowCloseRequestedEvent,
18729
+ ContextChangedEvent,
18730
+ ClosedEvent_2 as ClosedEvent,
18731
+ WindowClosedEvent,
18732
+ ClosingEvent,
18733
+ WindowClosingEvent,
18734
+ DisabledMovementBoundsChangedEvent,
18735
+ DisabledMovementBoundsChangingEvent,
18736
+ EmbeddedEvent,
18737
+ EndUserBoundsChangingEvent,
18738
+ HotkeyEvent_2 as HotkeyEvent,
18739
+ WindowHotkeyEvent,
18740
+ InitializedEvent_2 as InitializedEvent,
18741
+ WindowInitializedEvent,
18742
+ MaximizedEvent,
18743
+ MinimizedEvent,
18744
+ PreloadScriptsStateChangedEvent,
18745
+ PreloadScriptsStateChangingEvent,
18746
+ RestoredEvent,
18747
+ WindowRestoredEvent,
18748
+ ShowRequestedEvent,
18749
+ WindowShowRequestedEvent,
18750
+ ShownEvent_2 as ShownEvent,
18751
+ WindowShownEvent,
18752
+ UserMovementEnabledEvent,
18753
+ UserMovementDisabledEvent,
18754
+ WillMoveEvent,
18755
+ WillResizeEvent,
18756
+ NonPropagatedWindowEvent,
18757
+ ShowAllDownloadsEvent,
18758
+ DownloadShelfVisibilityChangedEvent,
18759
+ WindowSourcedEvent,
18760
+ WillPropagateWindowEvent,
18761
+ Event_6 as Event,
18762
+ WindowEvent,
18763
+ EventType_2 as EventType,
18764
+ WindowEventType,
18765
+ PropagatedEvent_3 as PropagatedEvent,
18766
+ PropagatedWindowEvent,
18767
+ PropagatedWindowEventType,
18768
+ Payload_3 as Payload,
18769
+ ByType_2 as ByType
18770
+ }
18771
+ }
18772
+
18773
+ /**
18774
+ * @deprecated Renamed to {@link EventType}.
18775
+ */
18776
+ declare type WindowEventType = WindowEvent['type'];
18777
+
18778
+ /**
18779
+ * @deprecated Renamed to {@link HiddenEvent}.
18780
+ */
18781
+ declare type WindowHiddenEvent = HiddenEvent_2;
18782
+
18783
+ /**
18784
+ * @deprecated Renamed to {@link HotkeyEvent}.
18785
+ */
18786
+ declare type WindowHotkeyEvent = HotkeyEvent_2;
18787
+
18788
+ /**
18789
+ * @interface
18790
+ */
18791
+ declare type WindowInfo = {
18792
+ canNavigateBack: boolean;
18793
+ canNavigateForward: boolean;
18794
+ preloadScripts: Array<any>;
18795
+ title: string;
18796
+ url: string;
18797
+ };
18798
+
18799
+ /**
18800
+ * @deprecated Renamed to {@link InitializedEvent}.
18801
+ */
18802
+ declare type WindowInitializedEvent = InitializedEvent_2;
18803
+
18804
+ /**
18805
+ * Static namespace for OpenFin API methods that interact with the {@link _Window} class, available under `fin.Window`.
18806
+ */
18807
+ declare class _WindowModule extends Base {
18808
+ /**
18809
+ * Asynchronously returns a Window object that represents an existing window.
18810
+ *
18811
+ * @example
18812
+ * ```js
18813
+ * async function createWin() {
18814
+ * const app = await fin.Application.start({
18815
+ * name: 'myApp',
18816
+ * uuid: 'app-1',
18817
+ * url: 'https://cdn.openfin.co/docs/javascript/stable/tutorial-Window.wrap.html',
18818
+ * autoShow: true
18819
+ * });
18820
+ * return await app.getWindow();
18821
+ * }
18822
+ * createWin().then(() => fin.Window.wrap({ uuid: 'app-1', name: 'myApp' }))
18823
+ * .then(win => console.log('wrapped window'))
18824
+ * .catch(err => console.log(err));
18825
+ * ```
18826
+ */
18827
+ wrap(identity: OpenFin.Identity): Promise<OpenFin.Window>;
18828
+ /**
18829
+ * Synchronously returns a Window object that represents an existing window.
18830
+ *
18831
+ * @example
18832
+ * ```js
18833
+ * async function createWin() {
18834
+ * const app = await fin.Application.start({
18835
+ * name: 'myApp',
18836
+ * uuid: 'app-1',
18837
+ * url: 'https://cdn.openfin.co/docs/javascript/stable/tutorial-Window.wrapSync.html',
18838
+ * autoShow: true
18839
+ * });
18840
+ * return await app.getWindow();
18841
+ * }
18842
+ * await createWin();
18843
+ * let win = fin.Window.wrapSync({ uuid: 'app-1', name: 'myApp' });
18844
+ * ```
18845
+ */
18846
+ wrapSync(identity: OpenFin.Identity): OpenFin.Window;
18847
+ /**
18848
+ * Creates a new Window.
18849
+ * @param options - Window creation options
18850
+ *
18851
+ * @example
18852
+ * ```js
18853
+ * async function createWindow() {
18854
+ * const winOption = {
18855
+ * name:'child',
18856
+ * defaultWidth: 300,
18857
+ * defaultHeight: 300,
18858
+ * url: 'https://cdn.openfin.co/docs/javascript/stable/tutorial-Window.create.html',
18859
+ * frame: true,
18860
+ * autoShow: true
18861
+ * };
18862
+ * return await fin.Window.create(winOption);
18863
+ * }
18864
+ *
18865
+ * createWindow().then(() => console.log('Window is created')).catch(err => console.log(err));
18866
+ * ```
18867
+ */
18868
+ create(options: OpenFin.WindowCreationOptions): Promise<OpenFin.Window>;
18869
+ /**
18870
+ * Asynchronously returns a Window object that represents the current window
18871
+ *
18872
+ * @example
18873
+ * ```js
18874
+ * fin.Window.getCurrent()
18875
+ * .then(wnd => console.log('current window'))
18876
+ * .catch(err => console.log(err));
18877
+ *
18878
+ * ```
18879
+ */
18880
+ getCurrent(): Promise<OpenFin.Window>;
18881
+ /**
18882
+ * Synchronously returns a Window object that represents the current window
18883
+ *
18884
+ * @example
18885
+ * ```js
18886
+ * const wnd = fin.Window.getCurrentSync();
18887
+ * const info = await wnd.getInfo();
18888
+ * console.log(info);
18889
+ *
18890
+ * ```
18891
+ */
18892
+ getCurrentSync(): OpenFin.Window;
18893
+ }
18894
+
18895
+ /**
18896
+ * Generated when a child window is not responding.
18897
+ * @interface
18898
+ */
18899
+ declare type WindowNotRespondingEvent = BaseEvent_3 & {
18900
+ type: 'window-not-responding';
18901
+ };
18902
+
18903
+ /**
18904
+ * @interface
18905
+ */
18906
+ declare type WindowOptionDiff = {
18907
+ [key in keyof WindowOptions]: {
18908
+ oldVal: WindowOptions[key];
18909
+ newVal: WindowOptions[key];
18910
+ };
18911
+ };
18912
+
18913
+ /**
18914
+ * @interface
18915
+ */
18916
+ declare type WindowOptions = MutableWindowOptions & ConstWindowOptions;
18917
+
18918
+ declare type WindowOptionsChangedEvent = OpenFin.WindowEvents.WindowOptionsChangedEvent;
18919
+
18920
+ /**
18921
+ * @deprecated Renamed to {@link OptionsChangedEvent}.
18922
+ */
18923
+ declare type WindowOptionsChangedEvent_2 = OptionsChangedEvent;
18924
+
18925
+ declare type WindowPrintOptions = PrintOptions | ScreenshotPrintOptions | WindowViewsPrintOptions;
18926
+
18927
+ /**
18928
+ * Generated when a child window is responding.
18929
+ * @interface
18930
+ */
18931
+ declare type WindowRespondingEvent = BaseEvent_3 & {
18932
+ type: 'window-responding';
18933
+ };
18934
+
18935
+ /**
18936
+ * @deprecated Renamed to {@link RestoredEvent}.
18937
+ */
18938
+ declare type WindowRestoredEvent = RestoredEvent;
18939
+
18940
+ /**
18941
+ * @deprecated Renamed to {@link ShownEvent}.
18942
+ */
18943
+ declare type WindowShownEvent = ShownEvent_2;
18944
+
18945
+ /**
18946
+ * @deprecated Renamed to {@link ShowRequestedEvent}.
18947
+ */
18948
+ declare type WindowShowRequestedEvent = ShowRequestedEvent;
18949
+
18950
+ /**
18951
+ * A union of all events that emit natively on the `Window` topic, i.e. excluding those that propagate
18952
+ * from {@link OpenFin.ViewEvents}.
18953
+ */
18954
+ declare type WindowSourcedEvent = WebContentsEvents.Event<'window'> | WindowViewEvent | AuthRequestedEvent | BeginUserBoundsChangingEvent | BoundsChangedEvent | BoundsChangingEvent | ContextChangedEvent | CloseRequestedEvent | ClosedEvent_2 | ClosingEvent | DisabledMovementBoundsChangedEvent | DisabledMovementBoundsChangingEvent | EmbeddedEvent | EndUserBoundsChangingEvent | ExternalProcessExitedEvent | ExternalProcessStartedEvent | HiddenEvent_2 | HotkeyEvent_2 | InitializedEvent_2 | LayoutInitializedEvent | LayoutReadyEvent | MaximizedEvent | MinimizedEvent | OptionsChangedEvent | PerformanceReportEvent | PreloadScriptsStateChangedEvent | PreloadScriptsStateChangingEvent | ReloadedEvent | RestoredEvent | ShowRequestedEvent | ShownEvent_2 | UserMovementDisabledEvent | UserMovementEnabledEvent | WillMoveEvent | WillRedirectEvent | WillResizeEvent | ShowAllDownloadsEvent | DownloadShelfVisibilityChangedEvent;
18955
+
18956
+ /**
18957
+ * Generated when a child window starts loading.
18958
+ * @interface
18959
+ */
18960
+ declare type WindowStartLoadEvent = BaseEvent_3 & {
18961
+ type: 'window-start-load';
18962
+ };
18963
+
18964
+ /**
18965
+ * Visibility state of a window.
18966
+ */
18967
+ declare type WindowState = 'maximized' | 'minimized' | 'normal';
18968
+
18969
+ /**
18970
+ * A view-related event that fires natively on the `Window` topic. This means that these events *do* propagate
18971
+ * to the `Application` level, with the name pattern `window-view-eventname`.
18972
+ */
18973
+ declare type WindowViewEvent = {
18974
+ viewIdentity: OpenFin.Identity;
18975
+ } & (ViewAttachedEvent | ViewDetachedEvent);
18976
+
18977
+ /**
18978
+ * @interface
18979
+ */
18980
+ declare type WindowViewsPrintOptions = {
18981
+ content: 'views';
18982
+ includeSelf?: boolean;
18983
+ };
18984
+
18985
+ declare type Wire = EventEmitter & {
18986
+ connect(messageReciever: MessageReceiver): Promise<any>;
18987
+ connectSync(): any;
18988
+ send(data: any): Promise<any>;
18989
+ shutdown(): Promise<void>;
18990
+ getPort(): string;
18991
+ };
18992
+
18993
+ declare type WireConstructor = {
18994
+ new (onmessage: (data: any) => void): Wire;
18995
+ };
18996
+
18997
+ /**
18998
+ * @internal
18999
+ */
19000
+ declare type WithId<T extends AppVersionEventType> = `${T}.${string}`;
19001
+
19002
+ declare interface WithInterop {
19003
+ interop: InteropClient;
19004
+ }
19005
+
19006
+ /**
19007
+ * @internal
19008
+ */
19009
+ declare type WithoutId<T extends string> = T extends WithId<infer U> ? U : never;
19010
+
19011
+ declare type WithPositioningOptions<T extends {} = {}> = T & {
19012
+ positioningOptions?: OpenFin.PositioningOptions;
19013
+ };
19014
+
19015
+ /**
19016
+ * @internal
19017
+ * @interface
19018
+ */
19019
+ declare type WorkspacePlatformOptions = {
19020
+ /** Leaving this as any for now until we figure out what the shape should look like in Workspace */
19021
+ [key: string]: any;
19022
+ };
19023
+
19024
+ /**
19025
+ * A generic request to write any supported data to the clipboard.
19026
+ * @interface
19027
+ */
19028
+ declare type WriteAnyClipboardRequest = BaseClipboardRequest & {
19029
+ /**
19030
+ * Data to be written
19031
+ */
19032
+ data: {
19033
+ text?: string;
19034
+ html?: string;
19035
+ rtf?: string;
19036
+ } & Partial<Pick<WriteImageClipboardRequest, 'image'>>;
19037
+ };
19038
+
19039
+ /**
19040
+ * @deprecated - instead use WriteAnyClipboardRequest
19041
+ *
19042
+ * A generic request to write any supported data to the clipboard.
19043
+ *
19044
+ * @interface
19045
+ */
19046
+ declare type WriteAnyRequestType = WriteAnyClipboardRequest;
19047
+
19048
+ /**
19049
+ * A request to write data to the clipboard.
19050
+ * @interface
19051
+ */
19052
+ declare type WriteClipboardRequest = BaseClipboardRequest & {
19053
+ /**
19054
+ * Data to write to the clipboard.
19055
+ */
19056
+ data: string;
19057
+ };
19058
+
19059
+ /**
19060
+ * @interface
19061
+ */
19062
+ declare type WriteImageClipboardRequest = BaseClipboardRequest & {
19063
+ /**
19064
+ * Can be either a base64 string, or a DataURL string. If using DataURL, the
19065
+ * supported formats are `data:image/png[;base64],` and `data:image/jpeg[;base64],`.
19066
+ * Using other image/<format> DataURLs will throw an Error.
19067
+ */
19068
+ image: string;
19069
+ };
19070
+
19071
+ /**
19072
+ * @deprecated - instead use OpenFin.WriteClipboardRequest
19073
+ *
19074
+ * A request to write data to the clipboard.
19075
+ *
19076
+ * @interface
19077
+ */
19078
+ declare type WriteRequestType = WriteClipboardRequest;
19079
+
19080
+ export { }