@openfin/core 38.82.59 → 38.82.60

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.
@@ -102,7 +102,7 @@ declare type ApiInjection = DomainApiSettings;
102
102
  * Generated when a new Platform's API becomes responsive.
103
103
  * @interface
104
104
  */
105
- declare type ApiReadyEvent = BaseEvent & {
105
+ declare type ApiReadyEvent = BaseEvents.BaseEvent & {
106
106
  topic: 'application';
107
107
  type: 'platform-api-ready';
108
108
  };
@@ -914,7 +914,7 @@ declare namespace ApplicationEvents {
914
914
  PropagatedApplicationEvent,
915
915
  PropagatedEventType_3 as PropagatedEventType,
916
916
  PropagatedApplicationEventType,
917
- Payload_4 as Payload,
917
+ Payload_5 as Payload,
918
918
  ByType_3 as ByType
919
919
  }
920
920
  }
@@ -1710,7 +1710,7 @@ declare type BaseEvent_10 = Events.BaseEvents.BaseEvent;
1710
1710
  * A base Channel event.
1711
1711
  * @interface
1712
1712
  */
1713
- declare type BaseEvent_2 = NamedEvent & {
1713
+ declare type BaseEvent_2 = BaseEvents.NamedEvent & {
1714
1714
  channelName: string;
1715
1715
  channelId: string;
1716
1716
  };
@@ -1780,6 +1780,7 @@ declare namespace BaseEvents {
1780
1780
  NotCloseRequested,
1781
1781
  PropagatedEventType,
1782
1782
  PropagatedEvent,
1783
+ Payload_2 as Payload,
1783
1784
  EventHandler,
1784
1785
  BaseEvent,
1785
1786
  IdentityEvent,
@@ -1920,7 +1921,7 @@ declare type BrowserContentCreationRule = BaseContentCreationRule & {
1920
1921
  *
1921
1922
  * @typeParam Type String key specifying the event to extract
1922
1923
  */
1923
- declare type ByType<Type extends EventType> = Payload_2<Type>;
1924
+ declare type ByType<Type extends EventType> = Payload_3<Type>;
1924
1925
 
1925
1926
  /**
1926
1927
  * Extracts a single event type matching the given key from the Window {@link Event} union.
@@ -1929,7 +1930,7 @@ declare type ByType<Type extends EventType> = Payload_2<Type>;
1929
1930
  *
1930
1931
  * @typeParam Type String key specifying the event to extract
1931
1932
  */
1932
- declare type ByType_2<Type extends EventType_2> = Payload_3<Type>;
1933
+ declare type ByType_2<Type extends EventType_2> = Payload_4<Type>;
1933
1934
 
1934
1935
  /**
1935
1936
  * Extracts a single event type matching the given key from the Application {@link Event} union.
@@ -1938,7 +1939,7 @@ declare type ByType_2<Type extends EventType_2> = Payload_3<Type>;
1938
1939
  *
1939
1940
  * @typeParam Type String key specifying the event to extract
1940
1941
  */
1941
- declare type ByType_3<Type extends EventType_3> = Payload_4<Type>;
1942
+ declare type ByType_3<Type extends EventType_3> = Payload_5<Type>;
1942
1943
 
1943
1944
  /**
1944
1945
  * Extracts a single event type matching the given key from the ExternalApplication {@link Event} union.
@@ -1947,7 +1948,7 @@ declare type ByType_3<Type extends EventType_3> = Payload_4<Type>;
1947
1948
  *
1948
1949
  * @typeParam Type String key specifying the event to extract
1949
1950
  */
1950
- declare type ByType_4<Type extends EventType_4> = Payload_5<Type>;
1951
+ declare type ByType_4<Type extends EventType_4> = Payload_6<Type>;
1951
1952
 
1952
1953
  /**
1953
1954
  * Extracts a single event type matching the given key from the Frame {@link Event} union.
@@ -1956,7 +1957,7 @@ declare type ByType_4<Type extends EventType_4> = Payload_5<Type>;
1956
1957
  *
1957
1958
  * @typeParam Type String key specifying the event to extract
1958
1959
  */
1959
- declare type ByType_5<Type extends EventType_5> = Payload_6<Type>;
1960
+ declare type ByType_5<Type extends EventType_5> = Payload_7<Type>;
1960
1961
 
1961
1962
  /**
1962
1963
  * Extracts a single event type matching the given key from the GlobalHotkey {@link Event} union.
@@ -1965,7 +1966,7 @@ declare type ByType_5<Type extends EventType_5> = Payload_6<Type>;
1965
1966
  *
1966
1967
  * @typeParam Type String key specifying the event to extract
1967
1968
  */
1968
- declare type ByType_6<Type extends EventType_6> = Payload_7<Type>;
1969
+ declare type ByType_6<Type extends EventType_6> = Payload_8<Type>;
1969
1970
 
1970
1971
  /**
1971
1972
  * Extracts a single event type matching the given key from the Platform {@link Event} union.
@@ -1974,7 +1975,7 @@ declare type ByType_6<Type extends EventType_6> = Payload_7<Type>;
1974
1975
  *
1975
1976
  * @typeParam Type String key specifying the event to extract
1976
1977
  */
1977
- declare type ByType_7<Type extends EventType_7> = Payload_8<Type>;
1978
+ declare type ByType_7<Type extends EventType_7> = Payload_9<Type>;
1978
1979
 
1979
1980
  /**
1980
1981
  * Extracts a single event type matching the given key from the System {@link Event} union.
@@ -1983,7 +1984,7 @@ declare type ByType_7<Type extends EventType_7> = Payload_8<Type>;
1983
1984
  *
1984
1985
  * @typeParam Type String key specifying the event to extract
1985
1986
  */
1986
- declare type ByType_8<Type extends EventType_8> = Payload_9<Type>;
1987
+ declare type ByType_8<Type extends EventType_8> = Payload_10<Type>;
1987
1988
 
1988
1989
  /**
1989
1990
  * Extracts a single event type matching the given key from the Layout DOM {@link Event} union.
@@ -1992,7 +1993,7 @@ declare type ByType_8<Type extends EventType_8> = Payload_9<Type>;
1992
1993
  *
1993
1994
  * @typeParam Type String key specifying the event to extract
1994
1995
  */
1995
- declare type ByType_9<Type extends EventType_9> = Payload_10<Type>;
1996
+ declare type ByType_9<Type extends EventType_9> = Payload_11<Type>;
1996
1997
 
1997
1998
  /**
1998
1999
  * Configuration for page capture.
@@ -4808,9 +4809,7 @@ declare class EventAggregator extends EmitterMap {
4808
4809
  * @remarks Selects the correct type for the event
4809
4810
  * payload from the provided union based on the provided string literal type.
4810
4811
  */
4811
- declare type EventHandler<EmitterEvent extends BaseEvent, EventType extends string> = (payload: Extract<EmitterEvent, {
4812
- type: EventType;
4813
- }>, ...args: any[]) => void;
4812
+ declare type EventHandler<EmitterEvent extends BaseEvent, EventType extends string> = (payload: Payload_2<EmitterEvent, EventType>, ...args: any[]) => void;
4814
4813
 
4815
4814
  declare namespace Events {
4816
4815
  export {
@@ -4946,7 +4945,7 @@ declare namespace ExternalApplicationEvents {
4946
4945
  ExternalApplicationEvent,
4947
4946
  EventType_4 as EventType,
4948
4947
  ExternalApplicationEventType,
4949
- Payload_5 as Payload,
4948
+ Payload_6 as Payload,
4950
4949
  ByType_4 as ByType
4951
4950
  }
4952
4951
  }
@@ -5391,7 +5390,7 @@ declare namespace FrameEvents {
5391
5390
  FrameEvent,
5392
5391
  EventType_5 as EventType,
5393
5392
  FrameEventType,
5394
- Payload_6 as Payload,
5393
+ Payload_7 as Payload,
5395
5394
  ByType_5 as ByType
5396
5395
  }
5397
5396
  }
@@ -5631,7 +5630,7 @@ declare namespace GlobalHotkeyEvents {
5631
5630
  GlobalHotkeyEvent,
5632
5631
  EventType_6 as EventType,
5633
5632
  GlobalHotkeyEventType,
5634
- Payload_7 as Payload,
5633
+ Payload_8 as Payload,
5635
5634
  ByType_6 as ByType
5636
5635
  }
5637
5636
  }
@@ -7711,7 +7710,7 @@ declare namespace LayoutDOMEvents {
7711
7710
  LayoutStateChangedEvent,
7712
7711
  Event_12 as Event,
7713
7712
  EventType_9 as EventType,
7714
- Payload_10 as Payload,
7713
+ Payload_11 as Payload,
7715
7714
  ByType_9 as ByType
7716
7715
  }
7717
7716
  }
@@ -9372,86 +9371,110 @@ declare type Payload<Success extends boolean = boolean, Data = any> = {
9372
9371
  error?: Success extends false ? ErrorPlainObject | undefined : never;
9373
9372
  };
9374
9373
 
9374
+ /**
9375
+ * Extracts a single event type matching the given key from the System {@link Event} union.
9376
+ *
9377
+ * @see {@link ByType}
9378
+ *
9379
+ * @typeParam Type String key specifying the event to extract
9380
+ */
9381
+ declare type Payload_10<Type extends EventType_8> = BaseEvents.Payload<Event_11, Type>;
9382
+
9375
9383
  /**
9376
9384
  * Extracts a single event type matching the given key from the Layout DOM {@link Event} union.
9377
9385
  *
9378
9386
  * @typeParam Type String key specifying the event to extract
9379
9387
  */
9380
- declare type Payload_10<Type extends EventType_9> = Extract<Event_12, {
9388
+ declare type Payload_11<Type extends EventType_9> = Extract<Event_12, {
9381
9389
  type: Type;
9382
9390
  }>;
9383
9391
 
9392
+ /**
9393
+ * Extracts a single event type matching the given type key from the provided EmitterEvent union.
9394
+ *
9395
+ * @remarks Each event emitter namespace defines its own reduction of this type that fixes the Event parameter to
9396
+ * the appropriate payload union for that namespace.
9397
+ *
9398
+ * @typeParam Event Union of payloads for events on the given emitter
9399
+ * @see {@link ByType}
9400
+ *
9401
+ * @typeParam Type String key specifying the event to extract from the union
9402
+ *
9403
+ * @see {@link OpenFin.Events.ApplicationEvents.Payload}
9404
+ * @see {@link OpenFin.Events.ExternalApplicationEvents.Payload}
9405
+ * @see {@link OpenFin.Events.FrameEvents.Payload}
9406
+ * @see {@link OpenFin.Events.GlobalHotkeyEvents.Payload}
9407
+ * @see {@link OpenFin.Events.PlatformEvents.Payload}
9408
+ * @see {@link OpenFin.Events.SystemEvents.Payload}
9409
+ * @see {@link OpenFin.Events.ViewEvents.Payload}
9410
+ * @see {@link OpenFin.Events.WindowEvents.Payload}
9411
+ */
9412
+ declare type Payload_2<Event extends BaseEvent, EventType extends string> = Extract<Event, {
9413
+ type: EventType;
9414
+ }>;
9415
+
9384
9416
  /**
9385
9417
  * Extracts a single event type matching the given key from the View {@link Event} union.
9386
9418
  *
9419
+ * @see {@link ByType}
9420
+ *
9387
9421
  * @typeParam Type String key specifying the event to extract
9388
9422
  */
9389
- declare type Payload_2<Type extends EventType> = Extract<Event_4, {
9390
- type: Type;
9391
- }>;
9423
+ declare type Payload_3<Type extends EventType> = BaseEvents.Payload<Event_4, Type>;
9392
9424
 
9393
9425
  /**
9394
9426
  * Extracts a single event type matching the given key from the Window {@link Event} union.
9395
9427
  *
9428
+ * @see {@link ByType}
9429
+ *
9396
9430
  * @typeParam Type String key specifying the event to extract
9397
9431
  */
9398
- declare type Payload_3<Type extends EventType_2> = Extract<Event_6, {
9399
- type: Type;
9400
- }>;
9432
+ declare type Payload_4<Type extends EventType_2> = BaseEvents.Payload<Event_6, Type>;
9401
9433
 
9402
9434
  /**
9403
9435
  * Extracts a single event type matching the given key from the Application {@link Event} union.
9404
9436
  *
9437
+ * @see {@link ByType}
9438
+ *
9405
9439
  * @typeParam Type String key specifying the event to extract
9406
9440
  */
9407
- declare type Payload_4<Type extends EventType_3> = Extract<Event_3, {
9408
- type: Type;
9409
- }>;
9441
+ declare type Payload_5<Type extends EventType_3> = BaseEvents.Payload<Event_3, Type>;
9410
9442
 
9411
9443
  /**
9412
9444
  * Extracts a single event type matching the given key from the ExternalApplication {@link Event} union.
9413
9445
  *
9446
+ * @see {@link ByType}
9447
+ *
9414
9448
  * @typeParam Type String key specifying the event to extract
9415
9449
  */
9416
- declare type Payload_5<Type extends EventType_4> = Extract<Event_7, {
9417
- type: Type;
9418
- }>;
9450
+ declare type Payload_6<Type extends EventType_4> = BaseEvents.Payload<Event_7, Type>;
9419
9451
 
9420
9452
  /**
9421
9453
  * Extracts a single event type matching the given key from the Frame {@link Event} union.
9422
9454
  *
9455
+ * @see {@link ByType}
9456
+ *
9423
9457
  * @typeParam Type String key specifying the event to extract
9424
9458
  */
9425
- declare type Payload_6<Type extends EventType_5> = Extract<Event_8, {
9426
- type: Type;
9427
- }>;
9459
+ declare type Payload_7<Type extends EventType_5> = BaseEvents.Payload<Event_8, Type>;
9428
9460
 
9429
9461
  /**
9430
9462
  * Extracts a single event type matching the given key from the GlobalHotkey {@link Event} union.
9431
9463
  *
9464
+ * @see {@link ByType}
9465
+ *
9432
9466
  * @typeParam Type String key specifying the event to extract
9433
9467
  */
9434
- declare type Payload_7<Type extends EventType_6> = Extract<Event_9, {
9435
- type: Type;
9436
- }>;
9468
+ declare type Payload_8<Type extends EventType_6> = BaseEvents.Payload<Event_9, Type>;
9437
9469
 
9438
9470
  /**
9439
9471
  * Extracts a single event type matching the given key from the Platform {@link Event} union.
9440
9472
  *
9441
- * @typeParam Type String key specifying the event to extract
9442
- */
9443
- declare type Payload_8<Type extends EventType_7> = Extract<Event_10, {
9444
- type: Type;
9445
- }>;
9446
-
9447
- /**
9448
- * Extracts a single event type matching the given key from the System {@link Event} union.
9473
+ * @see {@link ByType}
9449
9474
  *
9450
9475
  * @typeParam Type String key specifying the event to extract
9451
9476
  */
9452
- declare type Payload_9<Type extends EventType_8> = Extract<Event_11, {
9453
- type: Type;
9454
- }>;
9477
+ declare type Payload_9<Type extends EventType_7> = BaseEvents.Payload<Event_10, Type>;
9455
9478
 
9456
9479
  /**
9457
9480
  * @interface
@@ -10146,7 +10169,7 @@ declare namespace PlatformEvents {
10146
10169
  PlatformEvent,
10147
10170
  EventType_7 as EventType,
10148
10171
  PlatformEventType,
10149
- Payload_8 as Payload,
10172
+ Payload_9 as Payload,
10150
10173
  ByType_7 as ByType
10151
10174
  }
10152
10175
  }
@@ -12437,7 +12460,7 @@ declare type Snapshot = {
12437
12460
  * _Note_ - In the case of using a custom provider, if a window has a layout property but does not call _Layout.init_ this event may not fire.
12438
12461
  * @interface
12439
12462
  */
12440
- declare type SnapshotAppliedEvent = BaseEvent & {
12463
+ declare type SnapshotAppliedEvent = BaseEvents.BaseEvent & {
12441
12464
  topic: 'application';
12442
12465
  type: 'platform-snapshot-applied';
12443
12466
  };
@@ -14042,7 +14065,7 @@ declare namespace SystemEvents {
14042
14065
  SystemEvent,
14043
14066
  EventType_8 as EventType,
14044
14067
  SystemEventType,
14045
- Payload_9 as Payload,
14068
+ Payload_10 as Payload,
14046
14069
  ByType_8 as ByType
14047
14070
  }
14048
14071
  }
@@ -15063,7 +15086,7 @@ declare namespace ViewEvents {
15063
15086
  PropagatedViewEvent,
15064
15087
  PropagatedEventType_2 as PropagatedEventType,
15065
15088
  PropagatedViewEventType,
15066
- Payload_2 as Payload,
15089
+ Payload_3 as Payload,
15067
15090
  ByType
15068
15091
  }
15069
15092
  }
@@ -17584,7 +17607,7 @@ declare namespace WindowEvents {
17584
17607
  PropagatedEvent_3 as PropagatedEvent,
17585
17608
  PropagatedWindowEvent,
17586
17609
  PropagatedWindowEventType,
17587
- Payload_3 as Payload,
17610
+ Payload_4 as Payload,
17588
17611
  ByType_2 as ByType
17589
17612
  }
17590
17613
  }
@@ -102,7 +102,7 @@ declare type ApiInjection = DomainApiSettings;
102
102
  * Generated when a new Platform's API becomes responsive.
103
103
  * @interface
104
104
  */
105
- declare type ApiReadyEvent = BaseEvent & {
105
+ declare type ApiReadyEvent = BaseEvents.BaseEvent & {
106
106
  topic: 'application';
107
107
  type: 'platform-api-ready';
108
108
  };
@@ -914,7 +914,7 @@ declare namespace ApplicationEvents {
914
914
  PropagatedApplicationEvent,
915
915
  PropagatedEventType_3 as PropagatedEventType,
916
916
  PropagatedApplicationEventType,
917
- Payload_4 as Payload,
917
+ Payload_5 as Payload,
918
918
  ByType_3 as ByType
919
919
  }
920
920
  }
@@ -1710,7 +1710,7 @@ declare type BaseEvent_10 = Events.BaseEvents.BaseEvent;
1710
1710
  * A base Channel event.
1711
1711
  * @interface
1712
1712
  */
1713
- declare type BaseEvent_2 = NamedEvent & {
1713
+ declare type BaseEvent_2 = BaseEvents.NamedEvent & {
1714
1714
  channelName: string;
1715
1715
  channelId: string;
1716
1716
  };
@@ -1780,6 +1780,7 @@ declare namespace BaseEvents {
1780
1780
  NotCloseRequested,
1781
1781
  PropagatedEventType,
1782
1782
  PropagatedEvent,
1783
+ Payload_2 as Payload,
1783
1784
  EventHandler,
1784
1785
  BaseEvent,
1785
1786
  IdentityEvent,
@@ -1920,7 +1921,7 @@ declare type BrowserContentCreationRule = BaseContentCreationRule & {
1920
1921
  *
1921
1922
  * @typeParam Type String key specifying the event to extract
1922
1923
  */
1923
- declare type ByType<Type extends EventType> = Payload_2<Type>;
1924
+ declare type ByType<Type extends EventType> = Payload_3<Type>;
1924
1925
 
1925
1926
  /**
1926
1927
  * Extracts a single event type matching the given key from the Window {@link Event} union.
@@ -1929,7 +1930,7 @@ declare type ByType<Type extends EventType> = Payload_2<Type>;
1929
1930
  *
1930
1931
  * @typeParam Type String key specifying the event to extract
1931
1932
  */
1932
- declare type ByType_2<Type extends EventType_2> = Payload_3<Type>;
1933
+ declare type ByType_2<Type extends EventType_2> = Payload_4<Type>;
1933
1934
 
1934
1935
  /**
1935
1936
  * Extracts a single event type matching the given key from the Application {@link Event} union.
@@ -1938,7 +1939,7 @@ declare type ByType_2<Type extends EventType_2> = Payload_3<Type>;
1938
1939
  *
1939
1940
  * @typeParam Type String key specifying the event to extract
1940
1941
  */
1941
- declare type ByType_3<Type extends EventType_3> = Payload_4<Type>;
1942
+ declare type ByType_3<Type extends EventType_3> = Payload_5<Type>;
1942
1943
 
1943
1944
  /**
1944
1945
  * Extracts a single event type matching the given key from the ExternalApplication {@link Event} union.
@@ -1947,7 +1948,7 @@ declare type ByType_3<Type extends EventType_3> = Payload_4<Type>;
1947
1948
  *
1948
1949
  * @typeParam Type String key specifying the event to extract
1949
1950
  */
1950
- declare type ByType_4<Type extends EventType_4> = Payload_5<Type>;
1951
+ declare type ByType_4<Type extends EventType_4> = Payload_6<Type>;
1951
1952
 
1952
1953
  /**
1953
1954
  * Extracts a single event type matching the given key from the Frame {@link Event} union.
@@ -1956,7 +1957,7 @@ declare type ByType_4<Type extends EventType_4> = Payload_5<Type>;
1956
1957
  *
1957
1958
  * @typeParam Type String key specifying the event to extract
1958
1959
  */
1959
- declare type ByType_5<Type extends EventType_5> = Payload_6<Type>;
1960
+ declare type ByType_5<Type extends EventType_5> = Payload_7<Type>;
1960
1961
 
1961
1962
  /**
1962
1963
  * Extracts a single event type matching the given key from the GlobalHotkey {@link Event} union.
@@ -1965,7 +1966,7 @@ declare type ByType_5<Type extends EventType_5> = Payload_6<Type>;
1965
1966
  *
1966
1967
  * @typeParam Type String key specifying the event to extract
1967
1968
  */
1968
- declare type ByType_6<Type extends EventType_6> = Payload_7<Type>;
1969
+ declare type ByType_6<Type extends EventType_6> = Payload_8<Type>;
1969
1970
 
1970
1971
  /**
1971
1972
  * Extracts a single event type matching the given key from the Platform {@link Event} union.
@@ -1974,7 +1975,7 @@ declare type ByType_6<Type extends EventType_6> = Payload_7<Type>;
1974
1975
  *
1975
1976
  * @typeParam Type String key specifying the event to extract
1976
1977
  */
1977
- declare type ByType_7<Type extends EventType_7> = Payload_8<Type>;
1978
+ declare type ByType_7<Type extends EventType_7> = Payload_9<Type>;
1978
1979
 
1979
1980
  /**
1980
1981
  * Extracts a single event type matching the given key from the System {@link Event} union.
@@ -1983,7 +1984,7 @@ declare type ByType_7<Type extends EventType_7> = Payload_8<Type>;
1983
1984
  *
1984
1985
  * @typeParam Type String key specifying the event to extract
1985
1986
  */
1986
- declare type ByType_8<Type extends EventType_8> = Payload_9<Type>;
1987
+ declare type ByType_8<Type extends EventType_8> = Payload_10<Type>;
1987
1988
 
1988
1989
  /**
1989
1990
  * Extracts a single event type matching the given key from the Layout DOM {@link Event} union.
@@ -1992,7 +1993,7 @@ declare type ByType_8<Type extends EventType_8> = Payload_9<Type>;
1992
1993
  *
1993
1994
  * @typeParam Type String key specifying the event to extract
1994
1995
  */
1995
- declare type ByType_9<Type extends EventType_9> = Payload_10<Type>;
1996
+ declare type ByType_9<Type extends EventType_9> = Payload_11<Type>;
1996
1997
 
1997
1998
  /**
1998
1999
  * Configuration for page capture.
@@ -4808,9 +4809,7 @@ declare class EventAggregator extends EmitterMap {
4808
4809
  * @remarks Selects the correct type for the event
4809
4810
  * payload from the provided union based on the provided string literal type.
4810
4811
  */
4811
- declare type EventHandler<EmitterEvent extends BaseEvent, EventType extends string> = (payload: Extract<EmitterEvent, {
4812
- type: EventType;
4813
- }>, ...args: any[]) => void;
4812
+ declare type EventHandler<EmitterEvent extends BaseEvent, EventType extends string> = (payload: Payload_2<EmitterEvent, EventType>, ...args: any[]) => void;
4814
4813
 
4815
4814
  declare namespace Events {
4816
4815
  export {
@@ -4946,7 +4945,7 @@ declare namespace ExternalApplicationEvents {
4946
4945
  ExternalApplicationEvent,
4947
4946
  EventType_4 as EventType,
4948
4947
  ExternalApplicationEventType,
4949
- Payload_5 as Payload,
4948
+ Payload_6 as Payload,
4950
4949
  ByType_4 as ByType
4951
4950
  }
4952
4951
  }
@@ -5391,7 +5390,7 @@ declare namespace FrameEvents {
5391
5390
  FrameEvent,
5392
5391
  EventType_5 as EventType,
5393
5392
  FrameEventType,
5394
- Payload_6 as Payload,
5393
+ Payload_7 as Payload,
5395
5394
  ByType_5 as ByType
5396
5395
  }
5397
5396
  }
@@ -5631,7 +5630,7 @@ declare namespace GlobalHotkeyEvents {
5631
5630
  GlobalHotkeyEvent,
5632
5631
  EventType_6 as EventType,
5633
5632
  GlobalHotkeyEventType,
5634
- Payload_7 as Payload,
5633
+ Payload_8 as Payload,
5635
5634
  ByType_6 as ByType
5636
5635
  }
5637
5636
  }
@@ -7711,7 +7710,7 @@ declare namespace LayoutDOMEvents {
7711
7710
  LayoutStateChangedEvent,
7712
7711
  Event_12 as Event,
7713
7712
  EventType_9 as EventType,
7714
- Payload_10 as Payload,
7713
+ Payload_11 as Payload,
7715
7714
  ByType_9 as ByType
7716
7715
  }
7717
7716
  }
@@ -9372,86 +9371,110 @@ declare type Payload<Success extends boolean = boolean, Data = any> = {
9372
9371
  error?: Success extends false ? ErrorPlainObject | undefined : never;
9373
9372
  };
9374
9373
 
9374
+ /**
9375
+ * Extracts a single event type matching the given key from the System {@link Event} union.
9376
+ *
9377
+ * @see {@link ByType}
9378
+ *
9379
+ * @typeParam Type String key specifying the event to extract
9380
+ */
9381
+ declare type Payload_10<Type extends EventType_8> = BaseEvents.Payload<Event_11, Type>;
9382
+
9375
9383
  /**
9376
9384
  * Extracts a single event type matching the given key from the Layout DOM {@link Event} union.
9377
9385
  *
9378
9386
  * @typeParam Type String key specifying the event to extract
9379
9387
  */
9380
- declare type Payload_10<Type extends EventType_9> = Extract<Event_12, {
9388
+ declare type Payload_11<Type extends EventType_9> = Extract<Event_12, {
9381
9389
  type: Type;
9382
9390
  }>;
9383
9391
 
9392
+ /**
9393
+ * Extracts a single event type matching the given type key from the provided EmitterEvent union.
9394
+ *
9395
+ * @remarks Each event emitter namespace defines its own reduction of this type that fixes the Event parameter to
9396
+ * the appropriate payload union for that namespace.
9397
+ *
9398
+ * @typeParam Event Union of payloads for events on the given emitter
9399
+ * @see {@link ByType}
9400
+ *
9401
+ * @typeParam Type String key specifying the event to extract from the union
9402
+ *
9403
+ * @see {@link OpenFin.Events.ApplicationEvents.Payload}
9404
+ * @see {@link OpenFin.Events.ExternalApplicationEvents.Payload}
9405
+ * @see {@link OpenFin.Events.FrameEvents.Payload}
9406
+ * @see {@link OpenFin.Events.GlobalHotkeyEvents.Payload}
9407
+ * @see {@link OpenFin.Events.PlatformEvents.Payload}
9408
+ * @see {@link OpenFin.Events.SystemEvents.Payload}
9409
+ * @see {@link OpenFin.Events.ViewEvents.Payload}
9410
+ * @see {@link OpenFin.Events.WindowEvents.Payload}
9411
+ */
9412
+ declare type Payload_2<Event extends BaseEvent, EventType extends string> = Extract<Event, {
9413
+ type: EventType;
9414
+ }>;
9415
+
9384
9416
  /**
9385
9417
  * Extracts a single event type matching the given key from the View {@link Event} union.
9386
9418
  *
9419
+ * @see {@link ByType}
9420
+ *
9387
9421
  * @typeParam Type String key specifying the event to extract
9388
9422
  */
9389
- declare type Payload_2<Type extends EventType> = Extract<Event_4, {
9390
- type: Type;
9391
- }>;
9423
+ declare type Payload_3<Type extends EventType> = BaseEvents.Payload<Event_4, Type>;
9392
9424
 
9393
9425
  /**
9394
9426
  * Extracts a single event type matching the given key from the Window {@link Event} union.
9395
9427
  *
9428
+ * @see {@link ByType}
9429
+ *
9396
9430
  * @typeParam Type String key specifying the event to extract
9397
9431
  */
9398
- declare type Payload_3<Type extends EventType_2> = Extract<Event_6, {
9399
- type: Type;
9400
- }>;
9432
+ declare type Payload_4<Type extends EventType_2> = BaseEvents.Payload<Event_6, Type>;
9401
9433
 
9402
9434
  /**
9403
9435
  * Extracts a single event type matching the given key from the Application {@link Event} union.
9404
9436
  *
9437
+ * @see {@link ByType}
9438
+ *
9405
9439
  * @typeParam Type String key specifying the event to extract
9406
9440
  */
9407
- declare type Payload_4<Type extends EventType_3> = Extract<Event_3, {
9408
- type: Type;
9409
- }>;
9441
+ declare type Payload_5<Type extends EventType_3> = BaseEvents.Payload<Event_3, Type>;
9410
9442
 
9411
9443
  /**
9412
9444
  * Extracts a single event type matching the given key from the ExternalApplication {@link Event} union.
9413
9445
  *
9446
+ * @see {@link ByType}
9447
+ *
9414
9448
  * @typeParam Type String key specifying the event to extract
9415
9449
  */
9416
- declare type Payload_5<Type extends EventType_4> = Extract<Event_7, {
9417
- type: Type;
9418
- }>;
9450
+ declare type Payload_6<Type extends EventType_4> = BaseEvents.Payload<Event_7, Type>;
9419
9451
 
9420
9452
  /**
9421
9453
  * Extracts a single event type matching the given key from the Frame {@link Event} union.
9422
9454
  *
9455
+ * @see {@link ByType}
9456
+ *
9423
9457
  * @typeParam Type String key specifying the event to extract
9424
9458
  */
9425
- declare type Payload_6<Type extends EventType_5> = Extract<Event_8, {
9426
- type: Type;
9427
- }>;
9459
+ declare type Payload_7<Type extends EventType_5> = BaseEvents.Payload<Event_8, Type>;
9428
9460
 
9429
9461
  /**
9430
9462
  * Extracts a single event type matching the given key from the GlobalHotkey {@link Event} union.
9431
9463
  *
9464
+ * @see {@link ByType}
9465
+ *
9432
9466
  * @typeParam Type String key specifying the event to extract
9433
9467
  */
9434
- declare type Payload_7<Type extends EventType_6> = Extract<Event_9, {
9435
- type: Type;
9436
- }>;
9468
+ declare type Payload_8<Type extends EventType_6> = BaseEvents.Payload<Event_9, Type>;
9437
9469
 
9438
9470
  /**
9439
9471
  * Extracts a single event type matching the given key from the Platform {@link Event} union.
9440
9472
  *
9441
- * @typeParam Type String key specifying the event to extract
9442
- */
9443
- declare type Payload_8<Type extends EventType_7> = Extract<Event_10, {
9444
- type: Type;
9445
- }>;
9446
-
9447
- /**
9448
- * Extracts a single event type matching the given key from the System {@link Event} union.
9473
+ * @see {@link ByType}
9449
9474
  *
9450
9475
  * @typeParam Type String key specifying the event to extract
9451
9476
  */
9452
- declare type Payload_9<Type extends EventType_8> = Extract<Event_11, {
9453
- type: Type;
9454
- }>;
9477
+ declare type Payload_9<Type extends EventType_7> = BaseEvents.Payload<Event_10, Type>;
9455
9478
 
9456
9479
  /**
9457
9480
  * @interface
@@ -10146,7 +10169,7 @@ declare namespace PlatformEvents {
10146
10169
  PlatformEvent,
10147
10170
  EventType_7 as EventType,
10148
10171
  PlatformEventType,
10149
- Payload_8 as Payload,
10172
+ Payload_9 as Payload,
10150
10173
  ByType_7 as ByType
10151
10174
  }
10152
10175
  }
@@ -12437,7 +12460,7 @@ declare type Snapshot = {
12437
12460
  * _Note_ - In the case of using a custom provider, if a window has a layout property but does not call _Layout.init_ this event may not fire.
12438
12461
  * @interface
12439
12462
  */
12440
- declare type SnapshotAppliedEvent = BaseEvent & {
12463
+ declare type SnapshotAppliedEvent = BaseEvents.BaseEvent & {
12441
12464
  topic: 'application';
12442
12465
  type: 'platform-snapshot-applied';
12443
12466
  };
@@ -14042,7 +14065,7 @@ declare namespace SystemEvents {
14042
14065
  SystemEvent,
14043
14066
  EventType_8 as EventType,
14044
14067
  SystemEventType,
14045
- Payload_9 as Payload,
14068
+ Payload_10 as Payload,
14046
14069
  ByType_8 as ByType
14047
14070
  }
14048
14071
  }
@@ -15063,7 +15086,7 @@ declare namespace ViewEvents {
15063
15086
  PropagatedViewEvent,
15064
15087
  PropagatedEventType_2 as PropagatedEventType,
15065
15088
  PropagatedViewEventType,
15066
- Payload_2 as Payload,
15089
+ Payload_3 as Payload,
15067
15090
  ByType
15068
15091
  }
15069
15092
  }
@@ -17584,7 +17607,7 @@ declare namespace WindowEvents {
17584
17607
  PropagatedEvent_3 as PropagatedEvent,
17585
17608
  PropagatedWindowEvent,
17586
17609
  PropagatedWindowEventType,
17587
- Payload_3 as Payload,
17610
+ Payload_4 as Payload,
17588
17611
  ByType_2 as ByType
17589
17612
  }
17590
17613
  }