@openfin/node-adapter 34.78.19 → 34.78.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/out/node-adapter-alpha.d.ts +417 -36
- package/out/node-adapter-beta.d.ts +417 -36
- package/out/node-adapter-public.d.ts +417 -36
- package/out/node-adapter.d.ts +418 -37
- package/out/node-adapter.js +56 -72
- package/package.json +1 -1
package/out/node-adapter.d.ts
CHANGED
@@ -1,9 +1,8 @@
|
|
1
1
|
/// <reference types="jquery" />
|
2
2
|
/// <reference types="node" />
|
3
3
|
|
4
|
-
import { AppIdentifier } from 'fdc3v2/dist/api/AppIdentifier';
|
5
|
-
import type { AppMetadata } from 'fdc3v1/dist/api/AppMetadata';
|
6
4
|
import { EventEmitter } from 'events';
|
5
|
+
import type * as GoldenLayout from '@openfin/golden-layout';
|
7
6
|
|
8
7
|
/**
|
9
8
|
* Enable keyboard shortcuts for devtools, zoom, reload, and reload ignoring cache.
|
@@ -138,6 +137,31 @@ declare type AppAssetRequest = {
|
|
138
137
|
alias: string;
|
139
138
|
};
|
140
139
|
|
140
|
+
declare interface AppIdentifier {
|
141
|
+
/** The unique application identifier located within a specific application directory instance. An example of an appId might be 'app@sub.root' */
|
142
|
+
readonly appId: string;
|
143
|
+
/** An optional instance identifier, indicating that this object represents a specific instance of the application described. */
|
144
|
+
readonly instanceId?: string;
|
145
|
+
}
|
146
|
+
|
147
|
+
/**
|
148
|
+
* An interface that relates an intent to apps
|
149
|
+
*/
|
150
|
+
declare interface AppIntent {
|
151
|
+
readonly intent: IntentMetadata;
|
152
|
+
readonly apps: Array<AppMetadata>;
|
153
|
+
}
|
154
|
+
|
155
|
+
/**
|
156
|
+
* An interface that relates an intent to apps
|
157
|
+
*/
|
158
|
+
declare interface AppIntent_2 {
|
159
|
+
/** Details of the intent whose relationship to resolving applications is being described. */
|
160
|
+
readonly intent: IntentMetadata_2;
|
161
|
+
/** Details of applications that can resolve the intent. */
|
162
|
+
readonly apps: Array<AppMetadata_2>;
|
163
|
+
}
|
164
|
+
|
141
165
|
/**
|
142
166
|
* An object representing an application. Allows the developer to create,
|
143
167
|
* execute, show/close an application as well as listen to {@link OpenFin.ApplicationEvents application events}.
|
@@ -1353,6 +1377,60 @@ declare type ApplySnapshotPayload = {
|
|
1353
1377
|
options?: ApplySnapshotOptions;
|
1354
1378
|
};
|
1355
1379
|
|
1380
|
+
/**
|
1381
|
+
* App definition as provided by the application directory
|
1382
|
+
*/
|
1383
|
+
declare interface AppMetadata {
|
1384
|
+
/** The unique app name that can be used with the open and raiseIntent calls. */
|
1385
|
+
readonly name: string;
|
1386
|
+
/** The unique application identifier located within a specific application directory instance. An example of an appId might be 'app@sub.root' */
|
1387
|
+
readonly appId?: string;
|
1388
|
+
/** The Version of the application. */
|
1389
|
+
readonly version?: string;
|
1390
|
+
/** A more user-friendly application title that can be used to render UI elements */
|
1391
|
+
readonly title?: string;
|
1392
|
+
/** A tooltip for the application that can be used to render UI elements */
|
1393
|
+
readonly tooltip?: string;
|
1394
|
+
/** A longer, multi-paragraph description for the application that could include markup */
|
1395
|
+
readonly description?: string;
|
1396
|
+
/** A list of icon URLs for the application that can be used to render UI elements */
|
1397
|
+
readonly icons?: Array<string>;
|
1398
|
+
/** A list of image URLs for the application that can be used to render UI elements */
|
1399
|
+
readonly images?: Array<string>;
|
1400
|
+
}
|
1401
|
+
|
1402
|
+
/**
|
1403
|
+
* Extends an `AppIdentifier`, describing an application or instance of an application, with additional descriptive metadata that is usually provided by an FDC3 App Directory that the desktop agent connects to.
|
1404
|
+
*
|
1405
|
+
* The additional information from an app directory can aid in rendering UI elements, such as a launcher menu or resolver UI. This includes a title, description, tooltip and icon and screenshot URLs.
|
1406
|
+
*
|
1407
|
+
* Note that as `AppMetadata` instances are also `AppIdentifiers` they may be passed to the `app` argument of `fdc3.open`, `fdc3.raiseIntent` etc.
|
1408
|
+
*/
|
1409
|
+
declare interface AppMetadata_2 extends AppIdentifier {
|
1410
|
+
/**
|
1411
|
+
The 'friendly' app name.
|
1412
|
+
This field was used with the `open` and `raiseIntent` calls in FDC3 <2.0, which now require an `AppIdentifier` wth `appId` set.
|
1413
|
+
Note that for display purposes the `title` field should be used, if set, in preference to this field.
|
1414
|
+
*/
|
1415
|
+
readonly name?: string;
|
1416
|
+
/** The Version of the application. */
|
1417
|
+
readonly version?: string;
|
1418
|
+
/** An optional set of, implementation specific, metadata fields that can be used to disambiguate instances, such as a window title or screen position. Must only be set if `instanceId` is set. */
|
1419
|
+
readonly instanceMetadata?: Record<string, any>;
|
1420
|
+
/** A more user-friendly application title that can be used to render UI elements */
|
1421
|
+
readonly title?: string;
|
1422
|
+
/** A tooltip for the application that can be used to render UI elements */
|
1423
|
+
readonly tooltip?: string;
|
1424
|
+
/** A longer, multi-paragraph description for the application that could include markup */
|
1425
|
+
readonly description?: string;
|
1426
|
+
/** A list of icon URLs for the application that can be used to render UI elements */
|
1427
|
+
readonly icons?: Array<Icon>;
|
1428
|
+
/** Images representing the app in common usage scenarios that can be used to render UI elements */
|
1429
|
+
readonly screenshots?: Array<Image_2>;
|
1430
|
+
/** The type of output returned for any intent specified during resolution. May express a particular context type (e.g. "fdc3.instrument"), channel (e.g. "channel") or a channel that will receive a specified type (e.g. "channel<fdc3.instrument>"). */
|
1431
|
+
readonly resultType?: string | null;
|
1432
|
+
}
|
1433
|
+
|
1356
1434
|
/**
|
1357
1435
|
* @interface
|
1358
1436
|
*/
|
@@ -2035,7 +2113,25 @@ declare class Channel extends EmitterBase<ChannelEvent> {
|
|
2035
2113
|
|
2036
2114
|
declare type Channel_2 = OpenFin.Fin['InterApplicationBus']['Channel'];
|
2037
2115
|
|
2038
|
-
declare
|
2116
|
+
declare interface Channel_3 {
|
2117
|
+
id: string;
|
2118
|
+
type: string;
|
2119
|
+
displayMetadata?: DisplayMetadata;
|
2120
|
+
broadcast(context: Context): void;
|
2121
|
+
getCurrentContext(contextType?: string): Promise<Context | null>;
|
2122
|
+
addContextListener(contextType: string | null, handler: ContextHandler): Listener & Promise<Listener>;
|
2123
|
+
}
|
2124
|
+
|
2125
|
+
declare interface Channel_4 {
|
2126
|
+
readonly id: string;
|
2127
|
+
readonly type: 'user' | 'app' | 'private';
|
2128
|
+
readonly displayMetadata?: DisplayMetadata_2;
|
2129
|
+
broadcast(context: Context_2): Promise<void>;
|
2130
|
+
getCurrentContext(contextType?: string): Promise<Context_2 | null>;
|
2131
|
+
addContextListener(contextType: string | null, handler: ContextHandler_2): Listener_2 & Promise<Listener_2>;
|
2132
|
+
}
|
2133
|
+
|
2134
|
+
declare type Channel_5 = OpenFin.Fin['InterApplicationBus']['Channel'];
|
2039
2135
|
|
2040
2136
|
declare type ChannelAction = OpenFin.ChannelAction;
|
2041
2137
|
|
@@ -3539,12 +3635,26 @@ declare type ContentNavigation = NavigationRules;
|
|
3539
3635
|
*/
|
3540
3636
|
declare type ContentRedirect = NavigationRules;
|
3541
3637
|
|
3638
|
+
declare interface Context {
|
3639
|
+
id?: { [key: string]: string };
|
3640
|
+
name?: string;
|
3641
|
+
type: string;
|
3642
|
+
}
|
3643
|
+
|
3644
|
+
declare interface Context_2 {
|
3645
|
+
id?: { [key: string]: string };
|
3646
|
+
name?: string;
|
3647
|
+
type: string;
|
3648
|
+
contextMetadata?: ContextMetadata;
|
3649
|
+
metadata?: any;
|
3650
|
+
}
|
3651
|
+
|
3542
3652
|
/**
|
3543
3653
|
* Data passed between entities and applications.
|
3544
3654
|
*
|
3545
3655
|
* @interface
|
3546
3656
|
*/
|
3547
|
-
declare type
|
3657
|
+
declare type Context_3 = {
|
3548
3658
|
/**
|
3549
3659
|
* An object containing string key-value pairs for the bulk of the data for the context. Differs between context types.
|
3550
3660
|
*/
|
@@ -3564,7 +3674,7 @@ declare type Context = {
|
|
3564
3674
|
/**
|
3565
3675
|
* @interface
|
3566
3676
|
*/
|
3567
|
-
declare type ContextForIntent<MetadataType = any> =
|
3677
|
+
declare type ContextForIntent<MetadataType = any> = Context_3 & {
|
3568
3678
|
metadata?: MetadataType;
|
3569
3679
|
};
|
3570
3680
|
|
@@ -3580,19 +3690,23 @@ declare type ContextGroupInfo = {
|
|
3580
3690
|
/**
|
3581
3691
|
* Metadata for the Context Group. Contains the group's human-readable name, color, and an image, as defined by the Interop Broker.
|
3582
3692
|
*/
|
3583
|
-
displayMetadata?:
|
3693
|
+
displayMetadata?: DisplayMetadata_3;
|
3584
3694
|
};
|
3585
3695
|
|
3586
3696
|
declare type ContextGroupStates = {
|
3587
3697
|
[key: string]: {
|
3588
|
-
[key: string]:
|
3698
|
+
[key: string]: Context_3;
|
3589
3699
|
};
|
3590
3700
|
};
|
3591
3701
|
|
3702
|
+
declare type ContextHandler = (context: Context) => void;
|
3703
|
+
|
3704
|
+
declare type ContextHandler_2 = (context: Context_2, metadata?: ContextMetadata) => void;
|
3705
|
+
|
3592
3706
|
/**
|
3593
3707
|
* Subscription function for addContextHandler.
|
3594
3708
|
*/
|
3595
|
-
declare type
|
3709
|
+
declare type ContextHandler_3 = (context: Context_3) => void;
|
3596
3710
|
|
3597
3711
|
/**
|
3598
3712
|
* Configure the context menu when right-clicking on a window.
|
@@ -3631,6 +3745,20 @@ declare type ContextMenuSettings = {
|
|
3631
3745
|
reload?: boolean;
|
3632
3746
|
};
|
3633
3747
|
|
3748
|
+
/**
|
3749
|
+
* Metadata relating to a context or intent and context received through the
|
3750
|
+
* `addContextListener` and `addIntentListener` functions.
|
3751
|
+
*
|
3752
|
+
* @experimental Introduced in FDC3 2.0 and may be refined by further changes outside the normal FDC3 versioning policy.
|
3753
|
+
*/
|
3754
|
+
declare interface ContextMetadata {
|
3755
|
+
/** Identifier for the app instance that sent the context and/or intent.
|
3756
|
+
*
|
3757
|
+
* @experimental
|
3758
|
+
*/
|
3759
|
+
readonly source: AppIdentifier;
|
3760
|
+
}
|
3761
|
+
|
3634
3762
|
/**
|
3635
3763
|
* @interface
|
3636
3764
|
*/
|
@@ -3793,6 +3921,45 @@ declare type DefaultDomainSettingsRule = {
|
|
3793
3921
|
};
|
3794
3922
|
};
|
3795
3923
|
|
3924
|
+
declare interface DesktopAgent {
|
3925
|
+
open(app: TargetApp, context?: Context): Promise<void>;
|
3926
|
+
findIntent(intent: string, context?: Context): Promise<AppIntent>;
|
3927
|
+
findIntentsByContext(context: Context): Promise<Array<AppIntent>>;
|
3928
|
+
broadcast(context: Context): void;
|
3929
|
+
raiseIntent(intent: string, context: Context, app?: TargetApp): Promise<IntentResolution>;
|
3930
|
+
raiseIntentForContext(context: Context, app?: TargetApp): Promise<IntentResolution>;
|
3931
|
+
addIntentListener(intent: string, handler: ContextHandler): Listener;
|
3932
|
+
joinChannel(channelId: string): Promise<void>;
|
3933
|
+
leaveCurrentChannel(): Promise<void>;
|
3934
|
+
getInfo(): ImplementationMetadata;
|
3935
|
+
addContextListener(contextType: string | null, handler: ContextHandler): Listener & Promise<Listener>;
|
3936
|
+
getOrCreateChannel(channelId: string): Promise<Channel_3>;
|
3937
|
+
getSystemChannels(): Promise<SystemChannel[]>;
|
3938
|
+
getCurrentChannel(): Promise<Channel_3 | null>;
|
3939
|
+
}
|
3940
|
+
|
3941
|
+
declare interface DesktopAgent_2 {
|
3942
|
+
open(app: AppIdentifier | TargetApp, context?: Context_2): Promise<AppIdentifier>;
|
3943
|
+
findIntent(intent: string, context?: Context_2, resultType?: string): Promise<AppIntent_2>;
|
3944
|
+
findIntentsByContext(context: Context_2, resultType?: string): Promise<Array<AppIntent_2>>;
|
3945
|
+
findInstances(app: AppIdentifier): Promise<Array<AppIdentifier>>;
|
3946
|
+
broadcast(context: Context_2): Promise<void>;
|
3947
|
+
raiseIntent(intent: string, context: Context_2, app?: AppIdentifier | TargetApp): Promise<IntentResolution_2>;
|
3948
|
+
raiseIntentForContext(context: Context_2, app?: AppIdentifier | TargetApp): Promise<IntentResolution_2>;
|
3949
|
+
addIntentListener(intent: string, handler: IntentHandler): Promise<Listener_2>;
|
3950
|
+
addContextListener(contextType: string | null, handler: ContextHandler_2): Promise<Listener_2>;
|
3951
|
+
getUserChannels(): Promise<Array<SystemChannel>>;
|
3952
|
+
joinUserChannel(channelId: string): Promise<void>;
|
3953
|
+
getOrCreateChannel(channelId: string): Promise<Channel_4>;
|
3954
|
+
createPrivateChannel(): Promise<PrivateChannel>;
|
3955
|
+
getCurrentChannel(): Promise<Channel_3 | null>;
|
3956
|
+
leaveCurrentChannel(): Promise<void>;
|
3957
|
+
getInfo(): Promise<ImplementationMetadata_2>;
|
3958
|
+
getAppMetadata(app: AppIdentifier): Promise<AppMetadata_2>;
|
3959
|
+
getSystemChannels(): Promise<Array<SystemChannel>>;
|
3960
|
+
joinChannel(channelId: string): Promise<void>;
|
3961
|
+
}
|
3962
|
+
|
3796
3963
|
/**
|
3797
3964
|
* Generated when the desktop icon is clicked while it's already running.
|
3798
3965
|
* @interface
|
@@ -3865,12 +4032,52 @@ declare type DisabledMovementBoundsChangingEvent = BoundsChangeEvent & {
|
|
3865
4032
|
type: 'disabled-movement-bounds-changing';
|
3866
4033
|
};
|
3867
4034
|
|
4035
|
+
/**
|
4036
|
+
* A system channel will be global enough to have a presence across many apps. This gives us some hints
|
4037
|
+
* to render them in a standard way. It is assumed it may have other properties too, but if it has these,
|
4038
|
+
* this is their meaning.
|
4039
|
+
*/
|
4040
|
+
declare interface DisplayMetadata {
|
4041
|
+
/**
|
4042
|
+
* A user-readable name for this channel, e.g: `"Red"`
|
4043
|
+
*/
|
4044
|
+
readonly name?: string;
|
4045
|
+
/**
|
4046
|
+
* The color that should be associated within this channel when displaying this channel in a UI, e.g: `0xFF0000`.
|
4047
|
+
*/
|
4048
|
+
readonly color?: string;
|
4049
|
+
/**
|
4050
|
+
* A URL of an image that can be used to display this channel
|
4051
|
+
*/
|
4052
|
+
readonly glyph?: string;
|
4053
|
+
}
|
4054
|
+
|
4055
|
+
/**
|
4056
|
+
* A system channel will be global enough to have a presence across many apps. This gives us some hints
|
4057
|
+
* to render them in a standard way. It is assumed it may have other properties too, but if it has these,
|
4058
|
+
* this is their meaning.
|
4059
|
+
*/
|
4060
|
+
declare interface DisplayMetadata_2 {
|
4061
|
+
/**
|
4062
|
+
* A user-readable name for this channel, e.g: `"Red"`
|
4063
|
+
*/
|
4064
|
+
readonly name?: string;
|
4065
|
+
/**
|
4066
|
+
* The color that should be associated within this channel when displaying this channel in a UI, e.g: `0xFF0000`.
|
4067
|
+
*/
|
4068
|
+
readonly color?: string;
|
4069
|
+
/**
|
4070
|
+
* A URL of an image that can be used to display this channel
|
4071
|
+
*/
|
4072
|
+
readonly glyph?: string;
|
4073
|
+
}
|
4074
|
+
|
3868
4075
|
/**
|
3869
4076
|
* The display data for a context group.
|
3870
4077
|
*
|
3871
4078
|
* @interface
|
3872
4079
|
*/
|
3873
|
-
declare type
|
4080
|
+
declare type DisplayMetadata_3 = {
|
3874
4081
|
/**
|
3875
4082
|
* A user-readable name for this context group, e.g: `"Red"`
|
3876
4083
|
*/
|
@@ -4490,6 +4697,13 @@ declare type FaviconUpdatedEvent = NamedEvent & {
|
|
4490
4697
|
favicons: string[];
|
4491
4698
|
};
|
4492
4699
|
|
4700
|
+
declare namespace FDC3 {
|
4701
|
+
export {
|
4702
|
+
v1,
|
4703
|
+
v2
|
4704
|
+
}
|
4705
|
+
}
|
4706
|
+
|
4493
4707
|
/**
|
4494
4708
|
* @interface
|
4495
4709
|
*/
|
@@ -4704,8 +4918,8 @@ declare type FindInPageResult = {
|
|
4704
4918
|
/**
|
4705
4919
|
* @interface
|
4706
4920
|
*/
|
4707
|
-
declare type FindIntentsByContextOptions<MetadataType =
|
4708
|
-
context:
|
4921
|
+
declare type FindIntentsByContextOptions<MetadataType = IntentMetadata_3> = {
|
4922
|
+
context: Context_3;
|
4709
4923
|
metadata?: MetadataType;
|
4710
4924
|
};
|
4711
4925
|
|
@@ -5230,6 +5444,15 @@ declare type HotkeyEvent = BaseViewEvent & {
|
|
5230
5444
|
type: 'hotkey';
|
5231
5445
|
};
|
5232
5446
|
|
5447
|
+
declare interface Icon {
|
5448
|
+
/** The icon url */
|
5449
|
+
readonly src: string;
|
5450
|
+
/** The icon dimension, formatted as `<height>x<width>`. */
|
5451
|
+
readonly size?: string;
|
5452
|
+
/** Icon media type. If not present the Desktop Agent may use the src file extension. */
|
5453
|
+
readonly type?: string;
|
5454
|
+
}
|
5455
|
+
|
5233
5456
|
declare type Identity = OpenFin.Identity;
|
5234
5457
|
|
5235
5458
|
declare type Identity_2 = OpenFin.Identity;
|
@@ -5285,6 +5508,17 @@ declare type IdleEvent = {
|
|
5285
5508
|
isIdle: boolean;
|
5286
5509
|
};
|
5287
5510
|
|
5511
|
+
declare interface Image_2 {
|
5512
|
+
/** The image url. */
|
5513
|
+
readonly src: string;
|
5514
|
+
/** The image dimension, formatted as `<height>x<width>`. */
|
5515
|
+
readonly size?: string;
|
5516
|
+
/** Image media type. If not present the Desktop Agent may use the src file extension. */
|
5517
|
+
readonly type?: string;
|
5518
|
+
/** Caption for the image. */
|
5519
|
+
readonly label?: string;
|
5520
|
+
}
|
5521
|
+
|
5288
5522
|
declare type ImageFormatOptions = {
|
5289
5523
|
format: 'dataURL' | 'png' | 'bmp';
|
5290
5524
|
} | {
|
@@ -5295,15 +5529,57 @@ declare type ImageFormatOptions = {
|
|
5295
5529
|
quality?: number;
|
5296
5530
|
};
|
5297
5531
|
|
5532
|
+
/**
|
5533
|
+
* Metadata relating to the FDC3 Desktop Agent implementation and its provider.
|
5534
|
+
*/
|
5535
|
+
declare interface ImplementationMetadata {
|
5536
|
+
/** The version number of the FDC3 specification that the implementation provides.
|
5537
|
+
* The string must be a numeric semver version, e.g. 1.2 or 1.2.1.
|
5538
|
+
*/
|
5539
|
+
readonly fdc3Version: string;
|
5540
|
+
/** The name of the provider of the FDC3 Desktop Agent Implementation (e.g. Finsemble, Glue42, OpenFin etc.). */
|
5541
|
+
readonly provider: string;
|
5542
|
+
/** The version of the provider of the FDC3 Desktop Agent Implementation (e.g. 5.3.0). */
|
5543
|
+
readonly providerVersion?: string;
|
5544
|
+
}
|
5545
|
+
|
5546
|
+
/**
|
5547
|
+
* Metadata relating to the FDC3 Desktop Agent implementation and its provider.
|
5548
|
+
*/
|
5549
|
+
declare interface ImplementationMetadata_2 {
|
5550
|
+
/** The version number of the FDC3 specification that the implementation provides.
|
5551
|
+
* The string must be a numeric semver version, e.g. 1.2 or 1.2.1.
|
5552
|
+
*/
|
5553
|
+
readonly fdc3Version: string;
|
5554
|
+
/** The name of the provider of the Desktop Agent implementation (e.g. Finsemble, Glue42, OpenFin etc.). */
|
5555
|
+
readonly provider: string;
|
5556
|
+
/** The version of the provider of the Desktop Agent implementation (e.g. 5.3.0). */
|
5557
|
+
readonly providerVersion?: string;
|
5558
|
+
/** Metadata indicating whether the Desktop Agent implements optional features of
|
5559
|
+
* the Desktop Agent API.
|
5560
|
+
*/
|
5561
|
+
readonly optionalFeatures: {
|
5562
|
+
/** Used to indicate whether the exposure of 'originating app metadata' for
|
5563
|
+
* context and intent messages is supported by the Desktop Agent. */
|
5564
|
+
readonly OriginatingAppMetadata: boolean;
|
5565
|
+
/** Used to indicate whether the optional `fdc3.joinUserChannel`,
|
5566
|
+
* `fdc3.getCurrentChannel` and `fdc3.leaveCurrentChannel` are implemented by
|
5567
|
+
* the Desktop Agent. */
|
5568
|
+
readonly UserChannelMembershipAPIs: boolean;
|
5569
|
+
};
|
5570
|
+
/** The calling application instance's own metadata, according to the Desktop Agent (MUST include at least the `appId` and `instanceId`). */
|
5571
|
+
readonly appMetadata: AppMetadata_2;
|
5572
|
+
}
|
5573
|
+
|
5298
5574
|
/**
|
5299
5575
|
* @interface
|
5300
5576
|
*/
|
5301
|
-
declare type InfoForIntentOptions<MetadataType =
|
5577
|
+
declare type InfoForIntentOptions<MetadataType = IntentMetadata_3> = {
|
5302
5578
|
/**
|
5303
5579
|
* Name of the intent to get info for.
|
5304
5580
|
*/
|
5305
5581
|
name: string;
|
5306
|
-
context?:
|
5582
|
+
context?: Context_3;
|
5307
5583
|
metadata?: MetadataType;
|
5308
5584
|
};
|
5309
5585
|
|
@@ -5376,10 +5652,16 @@ declare type InstalledApps_2 = {
|
|
5376
5652
|
[key: string]: InstallationInfo;
|
5377
5653
|
};
|
5378
5654
|
|
5655
|
+
declare interface Intent {
|
5656
|
+
name: string;
|
5657
|
+
context: Context_2;
|
5658
|
+
metadata: IntentMetadata_2;
|
5659
|
+
}
|
5660
|
+
|
5379
5661
|
/**
|
5380
5662
|
* Combination of an action and a context that is passed to an application for resolution.
|
5381
5663
|
*/
|
5382
|
-
declare type
|
5664
|
+
declare type Intent_2<MetadataType = IntentMetadata_3> = {
|
5383
5665
|
/**
|
5384
5666
|
* Name of the intent.
|
5385
5667
|
*/
|
@@ -5387,25 +5669,54 @@ declare type Intent<MetadataType = IntentMetadata> = {
|
|
5387
5669
|
/**
|
5388
5670
|
* Data associated with the intent.
|
5389
5671
|
*/
|
5390
|
-
context:
|
5672
|
+
context: Context_3;
|
5391
5673
|
metadata?: MetadataType;
|
5392
5674
|
};
|
5393
5675
|
|
5676
|
+
declare type IntentHandler = (context: Context_2, metadata?: ContextMetadata) => Promise<IntentResult> | void;
|
5677
|
+
|
5394
5678
|
/**
|
5395
5679
|
* Subscription function for registerIntentHandler.
|
5396
5680
|
*/
|
5397
|
-
declare type
|
5681
|
+
declare type IntentHandler_2 = (intent: Intent_2) => void;
|
5398
5682
|
|
5399
5683
|
/**
|
5400
|
-
*
|
5401
|
-
* @interface
|
5684
|
+
* Intent descriptor
|
5402
5685
|
*/
|
5403
|
-
declare
|
5686
|
+
declare interface IntentMetadata {
|
5687
|
+
/** The unique name of the intent that can be invoked by the raiseIntent call */
|
5688
|
+
readonly name: string;
|
5689
|
+
/** A friendly display name for the intent that should be used to render UI elements */
|
5690
|
+
readonly displayName: string;
|
5691
|
+
}
|
5692
|
+
|
5693
|
+
declare type IntentMetadata_2<TargetType = any> = {
|
5404
5694
|
target?: TargetType;
|
5405
5695
|
resultType?: string;
|
5406
5696
|
intentResolutionResultId?: string;
|
5407
5697
|
};
|
5408
5698
|
|
5699
|
+
/**
|
5700
|
+
* The type used to describe an intent within the platform.
|
5701
|
+
* @interface
|
5702
|
+
*/
|
5703
|
+
declare type IntentMetadata_3<TargetType = any> = FDC3.v2.IntentMetadata<TargetType>;
|
5704
|
+
|
5705
|
+
declare interface IntentResolution {
|
5706
|
+
source: TargetApp;
|
5707
|
+
data?: object;
|
5708
|
+
version: string;
|
5709
|
+
}
|
5710
|
+
|
5711
|
+
declare interface IntentResolution_2 {
|
5712
|
+
source: AppIdentifier;
|
5713
|
+
intent: string;
|
5714
|
+
version?: string;
|
5715
|
+
getResult(): Promise<IntentResult>;
|
5716
|
+
}
|
5717
|
+
|
5718
|
+
declare type IntentResult = Context_2 | Channel_4 | PrivateChannel;
|
5719
|
+
|
5409
5720
|
/**
|
5410
5721
|
* A messaging bus that allows for pub/sub messaging between different applications.
|
5411
5722
|
*
|
@@ -6010,23 +6321,23 @@ declare class InteropBroker extends Base {
|
|
6010
6321
|
* @param clientIdentity Identity of the Client making the request.
|
6011
6322
|
*/
|
6012
6323
|
fdc3HandleOpen({ app, context }: {
|
6013
|
-
app: TargetApp | AppIdentifier;
|
6324
|
+
app: FDC3.v1.TargetApp | FDC3.v2.AppIdentifier;
|
6014
6325
|
context: OpenFin.Context;
|
6015
|
-
}, clientIdentity: OpenFin.ClientIdentity): Promise<void | AppIdentifier>;
|
6326
|
+
}, clientIdentity: OpenFin.ClientIdentity): Promise<void | FDC3.v2.AppIdentifier>;
|
6016
6327
|
/**
|
6017
6328
|
* Responsible for resolving the fdc3.findInstances call.
|
6018
6329
|
* Must be overridden
|
6019
6330
|
* @param app AppIdentifier that was passed to fdc3.findInstances
|
6020
6331
|
* @param clientIdentity Identity of the Client making the request.
|
6021
6332
|
*/
|
6022
|
-
fdc3HandleFindInstances(app: AppIdentifier, clientIdentity: OpenFin.ClientIdentity): Promise<unknown>;
|
6333
|
+
fdc3HandleFindInstances(app: FDC3.v2.AppIdentifier, clientIdentity: OpenFin.ClientIdentity): Promise<unknown>;
|
6023
6334
|
/**
|
6024
6335
|
* Responsible for resolving the fdc3.getAppMetadata call.
|
6025
6336
|
* Must be overridden
|
6026
6337
|
* @param app AppIdentifier that was passed to fdc3.getAppMetadata
|
6027
6338
|
* @param clientIdentity Identity of the Client making the request.
|
6028
6339
|
*/
|
6029
|
-
fdc3HandleGetAppMetadata(app: AppIdentifier, clientIdentity: OpenFin.ClientIdentity): Promise<unknown>;
|
6340
|
+
fdc3HandleGetAppMetadata(app: FDC3.v2.AppIdentifier, clientIdentity: OpenFin.ClientIdentity): Promise<unknown>;
|
6030
6341
|
/**
|
6031
6342
|
* This function is called by the Interop Broker whenever a Context handler would fire.
|
6032
6343
|
* For FDC3 2.0 you would need to override this function and add the contextMetadata as
|
@@ -7900,7 +8211,21 @@ declare type LayoutRow = LayoutItemConfig & {
|
|
7900
8211
|
*/
|
7901
8212
|
declare type LegacyWinOptionsInAppOptions = Pick<WindowCreationOptions, 'accelerator' | 'alwaysOnTop' | 'api' | 'aspectRatio' | 'autoplayPolicy' | 'autoShow' | 'backgroundColor' | 'contentNavigation' | 'contextMenu' | 'cornerRounding' | 'customData' | 'customRequestHeaders' | 'defaultCentered' | 'defaultHeight' | 'defaultLeft' | 'defaultTop' | 'defaultWidth' | 'frame' | 'hideOnClose' | 'icon' | 'maxHeight' | 'maximizable' | 'maxWidth' | 'minHeight' | 'minimizable' | 'minWidth' | 'opacity' | 'preloadScripts' | 'resizable' | 'resizeRegion' | 'saveWindowState' | 'ignoreSavedWindowState' | 'shadow' | 'showTaskbarIcon' | 'smallWindow' | 'state' | 'taskbarIconGroup' | 'waitForPageLoad' | '_internalWorkspaceData'>;
|
7902
8213
|
|
7903
|
-
declare
|
8214
|
+
declare interface Listener {
|
8215
|
+
/**
|
8216
|
+
* Unsubscribe the listener object.
|
8217
|
+
*/
|
8218
|
+
unsubscribe(): void;
|
8219
|
+
}
|
8220
|
+
|
8221
|
+
declare interface Listener_2 {
|
8222
|
+
/**
|
8223
|
+
* Unsubscribe the listener object.
|
8224
|
+
*/
|
8225
|
+
unsubscribe(): void;
|
8226
|
+
}
|
8227
|
+
|
8228
|
+
declare type Listener_3<T extends {
|
7904
8229
|
type: string;
|
7905
8230
|
}> = (payload: T) => void;
|
7906
8231
|
|
@@ -8701,11 +9026,11 @@ declare namespace OpenFin {
|
|
8701
9026
|
ApplicationOptions,
|
8702
9027
|
InteropBrokerOptions,
|
8703
9028
|
ContextGroupInfo,
|
8704
|
-
DisplayMetadata,
|
9029
|
+
DisplayMetadata_3 as DisplayMetadata,
|
8705
9030
|
LegacyWinOptionsInAppOptions,
|
8706
9031
|
Snapshot,
|
8707
9032
|
ContextGroupStates,
|
8708
|
-
Context,
|
9033
|
+
Context_3 as Context,
|
8709
9034
|
MonitorInfo,
|
8710
9035
|
Point,
|
8711
9036
|
PointTopLeft,
|
@@ -8874,10 +9199,10 @@ declare namespace OpenFin {
|
|
8874
9199
|
FileDownloadBehaviorNames,
|
8875
9200
|
FileDownloadSettings,
|
8876
9201
|
DownloadRule,
|
8877
|
-
ContextHandler,
|
8878
|
-
Intent,
|
8879
|
-
IntentMetadata,
|
8880
|
-
IntentHandler,
|
9202
|
+
ContextHandler_3 as ContextHandler,
|
9203
|
+
Intent_2 as Intent,
|
9204
|
+
IntentMetadata_3 as IntentMetadata,
|
9205
|
+
IntentHandler_2 as IntentHandler,
|
8881
9206
|
ContentCreationBehaviorNames,
|
8882
9207
|
MatchPattern,
|
8883
9208
|
ContentCreationRule,
|
@@ -9036,7 +9361,7 @@ declare class Platform extends EmitterBase<OpenFin.PlatformEvent> {
|
|
9036
9361
|
/**
|
9037
9362
|
* @internal
|
9038
9363
|
*/
|
9039
|
-
constructor(identity: OpenFin.ApplicationIdentity, channel:
|
9364
|
+
constructor(identity: OpenFin.ApplicationIdentity, channel: Channel_5);
|
9040
9365
|
getClient: (identity?: OpenFin.ApplicationIdentity) => Promise<ChannelClient_2>;
|
9041
9366
|
/**
|
9042
9367
|
* Creates a new view and attaches it to a specified target window.
|
@@ -10793,6 +11118,14 @@ declare type PrintOptions = {
|
|
10793
11118
|
dpi?: Dpi;
|
10794
11119
|
};
|
10795
11120
|
|
11121
|
+
declare type PrivateChannel = Omit<Channel_4, 'addContextListener'> & {
|
11122
|
+
addContextListener(contextType: string | null, handler: ContextHandler_2): Promise<Listener_2>;
|
11123
|
+
onAddContextListener(handler: (contextType?: string) => void): Listener_2;
|
11124
|
+
onUnsubscribe(handler: (contextType?: string) => void): Listener_2;
|
11125
|
+
onDisconnect(handler: () => void): Listener_2;
|
11126
|
+
disconnect(): void;
|
11127
|
+
};
|
11128
|
+
|
10796
11129
|
/**
|
10797
11130
|
* Strategy to assign views to process affinity by domain.
|
10798
11131
|
*
|
@@ -11705,19 +12038,19 @@ declare type SessionContextGroup = {
|
|
11705
12038
|
* A SessionContextGroup instance method for setting a context in the SessionContextGroup.
|
11706
12039
|
* @param context The Context to be set.
|
11707
12040
|
*/
|
11708
|
-
setContext: (context:
|
12041
|
+
setContext: (context: Context_3) => Promise<void>;
|
11709
12042
|
/**
|
11710
12043
|
* A SessionContextGroup instance method for getting the current context of a certain type.
|
11711
12044
|
* @param type The Context Type to get. If not specified the last contextType set would get used.
|
11712
12045
|
*/
|
11713
|
-
getCurrentContext: (type?: string) => Promise<
|
12046
|
+
getCurrentContext: (type?: string) => Promise<Context_3>;
|
11714
12047
|
/**
|
11715
12048
|
* A SessionContextGroup instance method for adding a handler for context change.
|
11716
12049
|
* @param handler The callback to be invoked. Is invoked when (a) the context changes or (b) immediately after getting created if the context is already set.
|
11717
12050
|
* @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.
|
11718
12051
|
*
|
11719
12052
|
*/
|
11720
|
-
addContextHandler: (handler:
|
12053
|
+
addContextHandler: (handler: ContextHandler_3, contextType?: string) => Promise<{
|
11721
12054
|
unsubscribe: () => void;
|
11722
12055
|
}>;
|
11723
12056
|
};
|
@@ -13470,6 +13803,12 @@ declare class System extends EmitterBase<OpenFin.SystemEvent> {
|
|
13470
13803
|
setDomainSettings(domainSettings: OpenFin.DefaultDomainSettings): Promise<void>;
|
13471
13804
|
}
|
13472
13805
|
|
13806
|
+
declare type SystemChannel = Omit<Channel_3, 'addContextListener' | 'broadcast' | 'getCurrentContext'> & {
|
13807
|
+
addContextListener(): Error;
|
13808
|
+
broadcast(): Error;
|
13809
|
+
getCurrentContext(): Error;
|
13810
|
+
};
|
13811
|
+
|
13473
13812
|
/**
|
13474
13813
|
* [Union](https://www.typescriptlang.org/docs/handbook/2/everyday-types.html#union-types) containing every possible event that can be emitted by a {@link System}. Events are
|
13475
13814
|
* discriminated by {@link SystemEvent.type | their type}. Event payloads unique to `System` can be found
|
@@ -13999,13 +14338,13 @@ declare type tween = 'linear' | 'ease-in' | 'ease-out' | 'ease-in-out' | 'ease-i
|
|
13999
14338
|
declare interface TypedEventEmitter<Event extends {
|
14000
14339
|
type: string;
|
14001
14340
|
}, EmitterEventType = Event['type']> {
|
14002
|
-
on<EventType extends EmitterEventType>(event: EventType, listener:
|
14341
|
+
on<EventType extends EmitterEventType>(event: EventType, listener: Listener_3<Extract<Event, {
|
14003
14342
|
type: EventType;
|
14004
14343
|
}>>): this;
|
14005
|
-
addListener<EventType extends EmitterEventType>(event: EventType, listener:
|
14344
|
+
addListener<EventType extends EmitterEventType>(event: EventType, listener: Listener_3<Extract<Event, {
|
14006
14345
|
type: EventType;
|
14007
14346
|
}>>): this;
|
14008
|
-
removeListener<EventType extends EmitterEventType>(event: EventType, listener:
|
14347
|
+
removeListener<EventType extends EmitterEventType>(event: EventType, listener: Listener_3<Extract<Event, {
|
14009
14348
|
type: EventType;
|
14010
14349
|
}>>): this;
|
14011
14350
|
removeAllListeners<EventType extends EmitterEventType>(event?: EmitterEventType): this;
|
@@ -14076,6 +14415,48 @@ declare type UserMovementEnabledEvent = NamedEvent & {
|
|
14076
14415
|
type: 'user-movement-enabled';
|
14077
14416
|
};
|
14078
14417
|
|
14418
|
+
declare namespace v1 {
|
14419
|
+
export {
|
14420
|
+
Listener,
|
14421
|
+
AppMetadata,
|
14422
|
+
IntentMetadata,
|
14423
|
+
AppIntent,
|
14424
|
+
DisplayMetadata,
|
14425
|
+
ImplementationMetadata,
|
14426
|
+
ContextHandler,
|
14427
|
+
TargetApp,
|
14428
|
+
Context,
|
14429
|
+
IntentResolution,
|
14430
|
+
Channel_3 as Channel,
|
14431
|
+
SystemChannel,
|
14432
|
+
DesktopAgent
|
14433
|
+
}
|
14434
|
+
}
|
14435
|
+
|
14436
|
+
declare namespace v2 {
|
14437
|
+
export {
|
14438
|
+
IntentMetadata_2 as IntentMetadata,
|
14439
|
+
AppIdentifier,
|
14440
|
+
Listener_2 as Listener,
|
14441
|
+
AppIntent_2 as AppIntent,
|
14442
|
+
ImplementationMetadata_2 as ImplementationMetadata,
|
14443
|
+
ContextMetadata,
|
14444
|
+
Icon,
|
14445
|
+
Image_2 as Image,
|
14446
|
+
AppMetadata_2 as AppMetadata,
|
14447
|
+
DisplayMetadata_2 as DisplayMetadata,
|
14448
|
+
ContextHandler_2 as ContextHandler,
|
14449
|
+
IntentHandler,
|
14450
|
+
IntentResult,
|
14451
|
+
Context_2 as Context,
|
14452
|
+
Intent,
|
14453
|
+
IntentResolution_2 as IntentResolution,
|
14454
|
+
Channel_4 as Channel,
|
14455
|
+
PrivateChannel,
|
14456
|
+
DesktopAgent_2 as DesktopAgent
|
14457
|
+
}
|
14458
|
+
}
|
14459
|
+
|
14079
14460
|
declare type View = OpenFin.View;
|
14080
14461
|
|
14081
14462
|
/**
|