@openfin/core 46.100.94 → 46.100.96

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.
@@ -104,7 +104,7 @@ declare type AlertRequestedEvent = BaseEvent_5 & {
104
104
  url: string;
105
105
  };
106
106
 
107
- declare type AnalyticsOnlyCalls = 'layout-get-stack-by-view' | 'layout-add-view' | 'layout-close-view' | `layout-controller-${string}`;
107
+ declare type AnalyticsOnlyCalls = 'layout-get-stack-by-view' | 'layout-add-view' | 'layout-close-view' | 'layout-set-view-pinned' | `layout-controller-${string}`;
108
108
 
109
109
  declare type AnalyticsProtocolMap = {
110
110
  [k in AnalyticsOnlyCalls]: VoidCall;
@@ -3187,6 +3187,18 @@ declare interface ChromeBrowserActions {
3187
3187
  /**
3188
3188
  * Control behavior for Chromium policies
3189
3189
  *
3190
+ * This setting can also be specified in a Domain Setting Rule, allowing per url overrides to be defined. Please note,
3191
+ * when a domain setting is actively controlling a url's chromiumPolicies, its view/window options will be ignored, as
3192
+ * a whole: a policy the rule leaves out does not apply, even if the options set it.
3193
+ *
3194
+ * @remarks
3195
+ * - Once a policy has disabled autofill for a Window or View, autofill stays disabled until that Window or View
3196
+ * closes, even if it navigates to a url where the policy does not apply.
3197
+ * - As a window or view option, `chromiumPolicies` is fixed when the Window or View is created: it cannot be changed
3198
+ * with `updateOptions`.
3199
+ * - A Window inherits the `chromiumPolicies` of its application, including those set in `mainWindowOptions`, unless
3200
+ * it sets its own.
3201
+ *
3190
3202
  * @interface
3191
3203
  */
3192
3204
  declare type ChromiumPolicies = {
@@ -4616,7 +4628,7 @@ declare type CreateLayoutOptions = {
4616
4628
  * Custom controls are not serialized into snapshots since callbacks are not
4617
4629
  * serializable. The callback is re-invoked when tabs are recreated.
4618
4630
  *
4619
- * **NOTE**: This feature is only supported with layout engine `'v2'` (GL2) and
4631
+ * **NOTE**: This feature is only supported with layout engine `'v2'` and
4620
4632
  * `settings.tabOverflowBehavior: 'scroll'`.
4621
4633
  *
4622
4634
  * Optionally add the `lm_tab_custom_control` class to each injected control as a direct child of
@@ -5457,7 +5469,7 @@ declare type Event_11 = ExcludeRequested<WindowEvents.PropagatedEvent<'system'>>
5457
5469
  * [Union](https://www.typescriptlang.org/docs/handbook/2/everyday-types.html#union-types) containing every possible event that can be emitted by the HTMLElement Layout container.
5458
5470
  * Events are discriminated by {@link LayoutDOMEvent.type}.
5459
5471
  */
5460
- declare type Event_12 = TabCreatedEvent | TabClosedEvent | TabDroppedEvent | ContainerCreatedEvent | LayoutStateChangedEvent;
5472
+ declare type Event_12 = TabCreatedEvent | TabClosedEvent | TabDroppedEvent | ContainerCreatedEvent | LayoutStateChangedEvent | TabPinnedChangedEvent;
5461
5473
 
5462
5474
  /**
5463
5475
  * [Union](https://www.typescriptlang.org/docs/handbook/2/everyday-types.html#union-types) containing every possible event that can be emitted by a {@link Channel}. Events are
@@ -8569,6 +8581,7 @@ declare type LaunchIntoPlatformPayload = {
8569
8581
  * * layout-state-changed
8570
8582
  * * tab-closed
8571
8583
  * * tab-dropped
8584
+ * * tab-pinned-changed
8572
8585
  *
8573
8586
  * ### Layout DOM Node Events
8574
8587
  *
@@ -8643,6 +8656,21 @@ declare type LaunchIntoPlatformPayload = {
8643
8656
  * url: "http://openfin.co" // The url of the view linked to the dropped tab.
8644
8657
  * }
8645
8658
  * ```
8659
+ *
8660
+ * #### tab-pinned-changed
8661
+ * Generated when a tab is pinned or unpinned via {@link Layout#setViewPinned setViewPinned}.
8662
+ * ```js
8663
+ * // The response has the following shape in event.detail:
8664
+ * {
8665
+ * containerSelector: "container-component_A",
8666
+ * name: "component_A",
8667
+ * tabSelector: "tab-component_A",
8668
+ * topic: "openfin-DOM-event",
8669
+ * type: "tab-pinned-changed",
8670
+ * uuid: "OpenFin POC",
8671
+ * pinned: true
8672
+ * }
8673
+ * ```
8646
8674
  */
8647
8675
  declare class Layout extends Base {
8648
8676
  #private;
@@ -8833,6 +8861,27 @@ declare class Layout extends Base {
8833
8861
  * @returns A promise that resolves when the view is closed.
8834
8862
  */
8835
8863
  closeView(viewIdentity: OpenFin_2.Identity): Promise<void>;
8864
+ /**
8865
+ * Pins or unpins a view's tab. When `pinned` is true, the tab moves to the leading pinned area of
8866
+ * its stack and snapshots record it as {@link OpenFin.LayoutComponent.pinned pinned: true}. When
8867
+ * false, it moves to the start of the unpinned tabs. Emits the layout DOM `tab-pinned-changed`
8868
+ * event when the pin state changes.
8869
+ *
8870
+ * @remarks Requires layout engine `'v2'` and `settings.tabOverflowBehavior: 'scroll'`.
8871
+ * Works whether or not `settings.allowUserPinning` is set. Throws if the view does not belong to this layout.
8872
+ *
8873
+ * @param viewIdentity - The identity of the view to pin or unpin.
8874
+ * @param pinned - `true` to pin; `false` to unpin.
8875
+ *
8876
+ * @example
8877
+ * ```js
8878
+ * const layout = fin.Platform.Layout.getCurrentSync();
8879
+ * await layout.setViewPinned({ uuid: fin.me.identity.uuid, name: 'my-view' }, true);
8880
+ * await layout.setViewPinned({ uuid: fin.me.identity.uuid, name: 'my-view' }, false);
8881
+ * ```
8882
+ * @experimental
8883
+ */
8884
+ setViewPinned(viewIdentity: OpenFin_2.Identity, pinned: boolean): Promise<void>;
8836
8885
  }
8837
8886
 
8838
8887
  /**
@@ -8875,6 +8924,15 @@ declare type LayoutComponent = Omit<LayoutItemConfig, 'content' | 'type'> & {
8875
8924
  * Only a component type will have this property and it represents the view options of a given component.
8876
8925
  */
8877
8926
  componentState?: Partial<ViewCreationOptions>;
8927
+ /**
8928
+ * **Platforms only.** Pins the tab to the leading pinned area of its stack (sibling to
8929
+ * `componentState`; not a view option). Users cannot drag pinned tabs out of their stack or
8930
+ * into another window; API moves within a layout keep the pin. Unless {@link LayoutOptions.settings allowUserPinning} is true, they also
8931
+ * cannot be closed or reordered. Use {@link Layout#setViewPinned setViewPinned} to change it at runtime.
8932
+ *
8933
+ * **NOTE**: Only applies with layout engine `'v2'` and `settings.tabOverflowBehavior: 'scroll'`.
8934
+ */
8935
+ pinned?: boolean;
8878
8936
  type: 'component';
8879
8937
  };
8880
8938
 
@@ -8917,6 +8975,7 @@ declare namespace LayoutDOMEvents {
8917
8975
  TabDroppedEvent,
8918
8976
  ContainerCreatedEvent,
8919
8977
  LayoutStateChangedEvent,
8978
+ TabPinnedChangedEvent,
8920
8979
  Event_12 as Event,
8921
8980
  EventType_9 as EventType,
8922
8981
  Payload_11 as Payload,
@@ -8945,6 +9004,7 @@ declare type LayoutEntitiesController = {
8945
9004
  edge: OpenFin_2.LayoutPosition;
8946
9005
  }) => Promise<Pick<OpenFin_2.LayoutEntityDefinition, 'entityId'>[]>;
8947
9006
  setStackActiveView: (stackEntityId: string, viewIdentity: OpenFin_2.Identity) => Promise<void>;
9007
+ setViewPinned: (viewIdentity: OpenFin_2.Identity, pinned: boolean, layoutIdentity?: OpenFin_2.LayoutIdentity) => Promise<void>;
8948
9008
  };
8949
9009
 
8950
9010
  /**
@@ -9372,6 +9432,21 @@ declare type LayoutOptions = {
9372
9432
  * @defaultValue 'dropdown'
9373
9433
  */
9374
9434
  tabOverflowBehavior?: 'dropdown' | 'scroll';
9435
+ /**
9436
+ * **Platforms only.** Whether pinned tabs ({@link LayoutComponent.pinned}) are managed by the user.
9437
+ *
9438
+ * - `false`: pins are platform-locked. Pinned tabs cannot be closed or reordered, and platform UI
9439
+ * should not offer pin / unpin.
9440
+ * - `true`: pinned tabs can be closed and reordered within the pinned area, and platform UI
9441
+ * may offer pin / unpin.
9442
+ *
9443
+ * {@link Layout#setViewPinned setViewPinned} works in both modes.
9444
+ *
9445
+ * **NOTE**: Only applies with layout engine `'v2'` and `tabOverflowBehavior: 'scroll'`.
9446
+ *
9447
+ * @defaultValue false
9448
+ */
9449
+ allowUserPinning?: boolean;
9375
9450
  };
9376
9451
  /**
9377
9452
  * Content of the layout. There can only be one top-level LayoutItem in the content array.
@@ -17414,6 +17489,16 @@ declare type TabDroppedEvent = LayoutDOMEvent & {
17414
17489
  url: string;
17415
17490
  };
17416
17491
 
17492
+ /**
17493
+ * Generated when a Layout Tab Component was pinned or unpinned via {@link OpenFin.Layout.setViewPinned}.
17494
+ * The identity is the view whose tab changed.
17495
+ * @interface
17496
+ */
17497
+ declare type TabPinnedChangedEvent = LayoutDOMEvent & {
17498
+ type: 'tab-pinned-changed';
17499
+ pinned: boolean;
17500
+ };
17501
+
17417
17502
  /**
17418
17503
  * A TabStack is used to manage the state of a stack of tabs within an OpenFin Layout.
17419
17504
  */
@@ -104,7 +104,7 @@ declare type AlertRequestedEvent = BaseEvent_5 & {
104
104
  url: string;
105
105
  };
106
106
 
107
- declare type AnalyticsOnlyCalls = 'layout-get-stack-by-view' | 'layout-add-view' | 'layout-close-view' | `layout-controller-${string}`;
107
+ declare type AnalyticsOnlyCalls = 'layout-get-stack-by-view' | 'layout-add-view' | 'layout-close-view' | 'layout-set-view-pinned' | `layout-controller-${string}`;
108
108
 
109
109
  declare type AnalyticsProtocolMap = {
110
110
  [k in AnalyticsOnlyCalls]: VoidCall;
@@ -3187,6 +3187,18 @@ declare interface ChromeBrowserActions {
3187
3187
  /**
3188
3188
  * Control behavior for Chromium policies
3189
3189
  *
3190
+ * This setting can also be specified in a Domain Setting Rule, allowing per url overrides to be defined. Please note,
3191
+ * when a domain setting is actively controlling a url's chromiumPolicies, its view/window options will be ignored, as
3192
+ * a whole: a policy the rule leaves out does not apply, even if the options set it.
3193
+ *
3194
+ * @remarks
3195
+ * - Once a policy has disabled autofill for a Window or View, autofill stays disabled until that Window or View
3196
+ * closes, even if it navigates to a url where the policy does not apply.
3197
+ * - As a window or view option, `chromiumPolicies` is fixed when the Window or View is created: it cannot be changed
3198
+ * with `updateOptions`.
3199
+ * - A Window inherits the `chromiumPolicies` of its application, including those set in `mainWindowOptions`, unless
3200
+ * it sets its own.
3201
+ *
3190
3202
  * @interface
3191
3203
  */
3192
3204
  declare type ChromiumPolicies = {
@@ -4616,7 +4628,7 @@ declare type CreateLayoutOptions = {
4616
4628
  * Custom controls are not serialized into snapshots since callbacks are not
4617
4629
  * serializable. The callback is re-invoked when tabs are recreated.
4618
4630
  *
4619
- * **NOTE**: This feature is only supported with layout engine `'v2'` (GL2) and
4631
+ * **NOTE**: This feature is only supported with layout engine `'v2'` and
4620
4632
  * `settings.tabOverflowBehavior: 'scroll'`.
4621
4633
  *
4622
4634
  * Optionally add the `lm_tab_custom_control` class to each injected control as a direct child of
@@ -5457,7 +5469,7 @@ declare type Event_11 = ExcludeRequested<WindowEvents.PropagatedEvent<'system'>>
5457
5469
  * [Union](https://www.typescriptlang.org/docs/handbook/2/everyday-types.html#union-types) containing every possible event that can be emitted by the HTMLElement Layout container.
5458
5470
  * Events are discriminated by {@link LayoutDOMEvent.type}.
5459
5471
  */
5460
- declare type Event_12 = TabCreatedEvent | TabClosedEvent | TabDroppedEvent | ContainerCreatedEvent | LayoutStateChangedEvent;
5472
+ declare type Event_12 = TabCreatedEvent | TabClosedEvent | TabDroppedEvent | ContainerCreatedEvent | LayoutStateChangedEvent | TabPinnedChangedEvent;
5461
5473
 
5462
5474
  /**
5463
5475
  * [Union](https://www.typescriptlang.org/docs/handbook/2/everyday-types.html#union-types) containing every possible event that can be emitted by a {@link Channel}. Events are
@@ -8569,6 +8581,7 @@ declare type LaunchIntoPlatformPayload = {
8569
8581
  * * layout-state-changed
8570
8582
  * * tab-closed
8571
8583
  * * tab-dropped
8584
+ * * tab-pinned-changed
8572
8585
  *
8573
8586
  * ### Layout DOM Node Events
8574
8587
  *
@@ -8643,6 +8656,21 @@ declare type LaunchIntoPlatformPayload = {
8643
8656
  * url: "http://openfin.co" // The url of the view linked to the dropped tab.
8644
8657
  * }
8645
8658
  * ```
8659
+ *
8660
+ * #### tab-pinned-changed
8661
+ * Generated when a tab is pinned or unpinned via {@link Layout#setViewPinned setViewPinned}.
8662
+ * ```js
8663
+ * // The response has the following shape in event.detail:
8664
+ * {
8665
+ * containerSelector: "container-component_A",
8666
+ * name: "component_A",
8667
+ * tabSelector: "tab-component_A",
8668
+ * topic: "openfin-DOM-event",
8669
+ * type: "tab-pinned-changed",
8670
+ * uuid: "OpenFin POC",
8671
+ * pinned: true
8672
+ * }
8673
+ * ```
8646
8674
  */
8647
8675
  declare class Layout extends Base {
8648
8676
  #private;
@@ -8833,6 +8861,27 @@ declare class Layout extends Base {
8833
8861
  * @returns A promise that resolves when the view is closed.
8834
8862
  */
8835
8863
  closeView(viewIdentity: OpenFin_2.Identity): Promise<void>;
8864
+ /**
8865
+ * Pins or unpins a view's tab. When `pinned` is true, the tab moves to the leading pinned area of
8866
+ * its stack and snapshots record it as {@link OpenFin.LayoutComponent.pinned pinned: true}. When
8867
+ * false, it moves to the start of the unpinned tabs. Emits the layout DOM `tab-pinned-changed`
8868
+ * event when the pin state changes.
8869
+ *
8870
+ * @remarks Requires layout engine `'v2'` and `settings.tabOverflowBehavior: 'scroll'`.
8871
+ * Works whether or not `settings.allowUserPinning` is set. Throws if the view does not belong to this layout.
8872
+ *
8873
+ * @param viewIdentity - The identity of the view to pin or unpin.
8874
+ * @param pinned - `true` to pin; `false` to unpin.
8875
+ *
8876
+ * @example
8877
+ * ```js
8878
+ * const layout = fin.Platform.Layout.getCurrentSync();
8879
+ * await layout.setViewPinned({ uuid: fin.me.identity.uuid, name: 'my-view' }, true);
8880
+ * await layout.setViewPinned({ uuid: fin.me.identity.uuid, name: 'my-view' }, false);
8881
+ * ```
8882
+ * @experimental
8883
+ */
8884
+ setViewPinned(viewIdentity: OpenFin_2.Identity, pinned: boolean): Promise<void>;
8836
8885
  }
8837
8886
 
8838
8887
  /**
@@ -8875,6 +8924,15 @@ declare type LayoutComponent = Omit<LayoutItemConfig, 'content' | 'type'> & {
8875
8924
  * Only a component type will have this property and it represents the view options of a given component.
8876
8925
  */
8877
8926
  componentState?: Partial<ViewCreationOptions>;
8927
+ /**
8928
+ * **Platforms only.** Pins the tab to the leading pinned area of its stack (sibling to
8929
+ * `componentState`; not a view option). Users cannot drag pinned tabs out of their stack or
8930
+ * into another window; API moves within a layout keep the pin. Unless {@link LayoutOptions.settings allowUserPinning} is true, they also
8931
+ * cannot be closed or reordered. Use {@link Layout#setViewPinned setViewPinned} to change it at runtime.
8932
+ *
8933
+ * **NOTE**: Only applies with layout engine `'v2'` and `settings.tabOverflowBehavior: 'scroll'`.
8934
+ */
8935
+ pinned?: boolean;
8878
8936
  type: 'component';
8879
8937
  };
8880
8938
 
@@ -8917,6 +8975,7 @@ declare namespace LayoutDOMEvents {
8917
8975
  TabDroppedEvent,
8918
8976
  ContainerCreatedEvent,
8919
8977
  LayoutStateChangedEvent,
8978
+ TabPinnedChangedEvent,
8920
8979
  Event_12 as Event,
8921
8980
  EventType_9 as EventType,
8922
8981
  Payload_11 as Payload,
@@ -8945,6 +9004,7 @@ declare type LayoutEntitiesController = {
8945
9004
  edge: OpenFin_2.LayoutPosition;
8946
9005
  }) => Promise<Pick<OpenFin_2.LayoutEntityDefinition, 'entityId'>[]>;
8947
9006
  setStackActiveView: (stackEntityId: string, viewIdentity: OpenFin_2.Identity) => Promise<void>;
9007
+ setViewPinned: (viewIdentity: OpenFin_2.Identity, pinned: boolean, layoutIdentity?: OpenFin_2.LayoutIdentity) => Promise<void>;
8948
9008
  };
8949
9009
 
8950
9010
  /**
@@ -9372,6 +9432,21 @@ declare type LayoutOptions = {
9372
9432
  * @defaultValue 'dropdown'
9373
9433
  */
9374
9434
  tabOverflowBehavior?: 'dropdown' | 'scroll';
9435
+ /**
9436
+ * **Platforms only.** Whether pinned tabs ({@link LayoutComponent.pinned}) are managed by the user.
9437
+ *
9438
+ * - `false`: pins are platform-locked. Pinned tabs cannot be closed or reordered, and platform UI
9439
+ * should not offer pin / unpin.
9440
+ * - `true`: pinned tabs can be closed and reordered within the pinned area, and platform UI
9441
+ * may offer pin / unpin.
9442
+ *
9443
+ * {@link Layout#setViewPinned setViewPinned} works in both modes.
9444
+ *
9445
+ * **NOTE**: Only applies with layout engine `'v2'` and `tabOverflowBehavior: 'scroll'`.
9446
+ *
9447
+ * @defaultValue false
9448
+ */
9449
+ allowUserPinning?: boolean;
9375
9450
  };
9376
9451
  /**
9377
9452
  * Content of the layout. There can only be one top-level LayoutItem in the content array.
@@ -17414,6 +17489,16 @@ declare type TabDroppedEvent = LayoutDOMEvent & {
17414
17489
  url: string;
17415
17490
  };
17416
17491
 
17492
+ /**
17493
+ * Generated when a Layout Tab Component was pinned or unpinned via {@link OpenFin.Layout.setViewPinned}.
17494
+ * The identity is the view whose tab changed.
17495
+ * @interface
17496
+ */
17497
+ declare type TabPinnedChangedEvent = LayoutDOMEvent & {
17498
+ type: 'tab-pinned-changed';
17499
+ pinned: boolean;
17500
+ };
17501
+
17417
17502
  /**
17418
17503
  * A TabStack is used to manage the state of a stack of tabs within an OpenFin Layout.
17419
17504
  */
@@ -104,7 +104,7 @@ declare type AlertRequestedEvent = BaseEvent_5 & {
104
104
  url: string;
105
105
  };
106
106
 
107
- declare type AnalyticsOnlyCalls = 'layout-get-stack-by-view' | 'layout-add-view' | 'layout-close-view' | `layout-controller-${string}`;
107
+ declare type AnalyticsOnlyCalls = 'layout-get-stack-by-view' | 'layout-add-view' | 'layout-close-view' | 'layout-set-view-pinned' | `layout-controller-${string}`;
108
108
 
109
109
  declare type AnalyticsProtocolMap = {
110
110
  [k in AnalyticsOnlyCalls]: VoidCall;
@@ -3187,6 +3187,18 @@ declare interface ChromeBrowserActions {
3187
3187
  /**
3188
3188
  * Control behavior for Chromium policies
3189
3189
  *
3190
+ * This setting can also be specified in a Domain Setting Rule, allowing per url overrides to be defined. Please note,
3191
+ * when a domain setting is actively controlling a url's chromiumPolicies, its view/window options will be ignored, as
3192
+ * a whole: a policy the rule leaves out does not apply, even if the options set it.
3193
+ *
3194
+ * @remarks
3195
+ * - Once a policy has disabled autofill for a Window or View, autofill stays disabled until that Window or View
3196
+ * closes, even if it navigates to a url where the policy does not apply.
3197
+ * - As a window or view option, `chromiumPolicies` is fixed when the Window or View is created: it cannot be changed
3198
+ * with `updateOptions`.
3199
+ * - A Window inherits the `chromiumPolicies` of its application, including those set in `mainWindowOptions`, unless
3200
+ * it sets its own.
3201
+ *
3190
3202
  * @interface
3191
3203
  */
3192
3204
  declare type ChromiumPolicies = {
@@ -4616,7 +4628,7 @@ declare type CreateLayoutOptions = {
4616
4628
  * Custom controls are not serialized into snapshots since callbacks are not
4617
4629
  * serializable. The callback is re-invoked when tabs are recreated.
4618
4630
  *
4619
- * **NOTE**: This feature is only supported with layout engine `'v2'` (GL2) and
4631
+ * **NOTE**: This feature is only supported with layout engine `'v2'` and
4620
4632
  * `settings.tabOverflowBehavior: 'scroll'`.
4621
4633
  *
4622
4634
  * Optionally add the `lm_tab_custom_control` class to each injected control as a direct child of
@@ -5457,7 +5469,7 @@ declare type Event_11 = ExcludeRequested<WindowEvents.PropagatedEvent<'system'>>
5457
5469
  * [Union](https://www.typescriptlang.org/docs/handbook/2/everyday-types.html#union-types) containing every possible event that can be emitted by the HTMLElement Layout container.
5458
5470
  * Events are discriminated by {@link LayoutDOMEvent.type}.
5459
5471
  */
5460
- declare type Event_12 = TabCreatedEvent | TabClosedEvent | TabDroppedEvent | ContainerCreatedEvent | LayoutStateChangedEvent;
5472
+ declare type Event_12 = TabCreatedEvent | TabClosedEvent | TabDroppedEvent | ContainerCreatedEvent | LayoutStateChangedEvent | TabPinnedChangedEvent;
5461
5473
 
5462
5474
  /**
5463
5475
  * [Union](https://www.typescriptlang.org/docs/handbook/2/everyday-types.html#union-types) containing every possible event that can be emitted by a {@link Channel}. Events are
@@ -8569,6 +8581,7 @@ declare type LaunchIntoPlatformPayload = {
8569
8581
  * * layout-state-changed
8570
8582
  * * tab-closed
8571
8583
  * * tab-dropped
8584
+ * * tab-pinned-changed
8572
8585
  *
8573
8586
  * ### Layout DOM Node Events
8574
8587
  *
@@ -8643,6 +8656,21 @@ declare type LaunchIntoPlatformPayload = {
8643
8656
  * url: "http://openfin.co" // The url of the view linked to the dropped tab.
8644
8657
  * }
8645
8658
  * ```
8659
+ *
8660
+ * #### tab-pinned-changed
8661
+ * Generated when a tab is pinned or unpinned via {@link Layout#setViewPinned setViewPinned}.
8662
+ * ```js
8663
+ * // The response has the following shape in event.detail:
8664
+ * {
8665
+ * containerSelector: "container-component_A",
8666
+ * name: "component_A",
8667
+ * tabSelector: "tab-component_A",
8668
+ * topic: "openfin-DOM-event",
8669
+ * type: "tab-pinned-changed",
8670
+ * uuid: "OpenFin POC",
8671
+ * pinned: true
8672
+ * }
8673
+ * ```
8646
8674
  */
8647
8675
  declare class Layout extends Base {
8648
8676
  #private;
@@ -8833,6 +8861,27 @@ declare class Layout extends Base {
8833
8861
  * @returns A promise that resolves when the view is closed.
8834
8862
  */
8835
8863
  closeView(viewIdentity: OpenFin_2.Identity): Promise<void>;
8864
+ /**
8865
+ * Pins or unpins a view's tab. When `pinned` is true, the tab moves to the leading pinned area of
8866
+ * its stack and snapshots record it as {@link OpenFin.LayoutComponent.pinned pinned: true}. When
8867
+ * false, it moves to the start of the unpinned tabs. Emits the layout DOM `tab-pinned-changed`
8868
+ * event when the pin state changes.
8869
+ *
8870
+ * @remarks Requires layout engine `'v2'` and `settings.tabOverflowBehavior: 'scroll'`.
8871
+ * Works whether or not `settings.allowUserPinning` is set. Throws if the view does not belong to this layout.
8872
+ *
8873
+ * @param viewIdentity - The identity of the view to pin or unpin.
8874
+ * @param pinned - `true` to pin; `false` to unpin.
8875
+ *
8876
+ * @example
8877
+ * ```js
8878
+ * const layout = fin.Platform.Layout.getCurrentSync();
8879
+ * await layout.setViewPinned({ uuid: fin.me.identity.uuid, name: 'my-view' }, true);
8880
+ * await layout.setViewPinned({ uuid: fin.me.identity.uuid, name: 'my-view' }, false);
8881
+ * ```
8882
+ * @experimental
8883
+ */
8884
+ setViewPinned(viewIdentity: OpenFin_2.Identity, pinned: boolean): Promise<void>;
8836
8885
  }
8837
8886
 
8838
8887
  /**
@@ -8875,6 +8924,15 @@ declare type LayoutComponent = Omit<LayoutItemConfig, 'content' | 'type'> & {
8875
8924
  * Only a component type will have this property and it represents the view options of a given component.
8876
8925
  */
8877
8926
  componentState?: Partial<ViewCreationOptions>;
8927
+ /**
8928
+ * **Platforms only.** Pins the tab to the leading pinned area of its stack (sibling to
8929
+ * `componentState`; not a view option). Users cannot drag pinned tabs out of their stack or
8930
+ * into another window; API moves within a layout keep the pin. Unless {@link LayoutOptions.settings allowUserPinning} is true, they also
8931
+ * cannot be closed or reordered. Use {@link Layout#setViewPinned setViewPinned} to change it at runtime.
8932
+ *
8933
+ * **NOTE**: Only applies with layout engine `'v2'` and `settings.tabOverflowBehavior: 'scroll'`.
8934
+ */
8935
+ pinned?: boolean;
8878
8936
  type: 'component';
8879
8937
  };
8880
8938
 
@@ -8917,6 +8975,7 @@ declare namespace LayoutDOMEvents {
8917
8975
  TabDroppedEvent,
8918
8976
  ContainerCreatedEvent,
8919
8977
  LayoutStateChangedEvent,
8978
+ TabPinnedChangedEvent,
8920
8979
  Event_12 as Event,
8921
8980
  EventType_9 as EventType,
8922
8981
  Payload_11 as Payload,
@@ -8945,6 +9004,7 @@ declare type LayoutEntitiesController = {
8945
9004
  edge: OpenFin_2.LayoutPosition;
8946
9005
  }) => Promise<Pick<OpenFin_2.LayoutEntityDefinition, 'entityId'>[]>;
8947
9006
  setStackActiveView: (stackEntityId: string, viewIdentity: OpenFin_2.Identity) => Promise<void>;
9007
+ setViewPinned: (viewIdentity: OpenFin_2.Identity, pinned: boolean, layoutIdentity?: OpenFin_2.LayoutIdentity) => Promise<void>;
8948
9008
  };
8949
9009
 
8950
9010
  /**
@@ -9372,6 +9432,21 @@ declare type LayoutOptions = {
9372
9432
  * @defaultValue 'dropdown'
9373
9433
  */
9374
9434
  tabOverflowBehavior?: 'dropdown' | 'scroll';
9435
+ /**
9436
+ * **Platforms only.** Whether pinned tabs ({@link LayoutComponent.pinned}) are managed by the user.
9437
+ *
9438
+ * - `false`: pins are platform-locked. Pinned tabs cannot be closed or reordered, and platform UI
9439
+ * should not offer pin / unpin.
9440
+ * - `true`: pinned tabs can be closed and reordered within the pinned area, and platform UI
9441
+ * may offer pin / unpin.
9442
+ *
9443
+ * {@link Layout#setViewPinned setViewPinned} works in both modes.
9444
+ *
9445
+ * **NOTE**: Only applies with layout engine `'v2'` and `tabOverflowBehavior: 'scroll'`.
9446
+ *
9447
+ * @defaultValue false
9448
+ */
9449
+ allowUserPinning?: boolean;
9375
9450
  };
9376
9451
  /**
9377
9452
  * Content of the layout. There can only be one top-level LayoutItem in the content array.
@@ -17414,6 +17489,16 @@ declare type TabDroppedEvent = LayoutDOMEvent & {
17414
17489
  url: string;
17415
17490
  };
17416
17491
 
17492
+ /**
17493
+ * Generated when a Layout Tab Component was pinned or unpinned via {@link OpenFin.Layout.setViewPinned}.
17494
+ * The identity is the view whose tab changed.
17495
+ * @interface
17496
+ */
17497
+ declare type TabPinnedChangedEvent = LayoutDOMEvent & {
17498
+ type: 'tab-pinned-changed';
17499
+ pinned: boolean;
17500
+ };
17501
+
17417
17502
  /**
17418
17503
  * A TabStack is used to manage the state of a stack of tabs within an OpenFin Layout.
17419
17504
  */
package/out/stub.d.ts CHANGED
@@ -104,7 +104,7 @@ declare type AlertRequestedEvent = BaseEvent_5 & {
104
104
  url: string;
105
105
  };
106
106
 
107
- declare type AnalyticsOnlyCalls = 'layout-get-stack-by-view' | 'layout-add-view' | 'layout-close-view' | `layout-controller-${string}`;
107
+ declare type AnalyticsOnlyCalls = 'layout-get-stack-by-view' | 'layout-add-view' | 'layout-close-view' | 'layout-set-view-pinned' | `layout-controller-${string}`;
108
108
 
109
109
  declare type AnalyticsProtocolMap = {
110
110
  [k in AnalyticsOnlyCalls]: VoidCall;
@@ -3244,6 +3244,18 @@ declare interface ChromeBrowserActions {
3244
3244
  /**
3245
3245
  * Control behavior for Chromium policies
3246
3246
  *
3247
+ * This setting can also be specified in a Domain Setting Rule, allowing per url overrides to be defined. Please note,
3248
+ * when a domain setting is actively controlling a url's chromiumPolicies, its view/window options will be ignored, as
3249
+ * a whole: a policy the rule leaves out does not apply, even if the options set it.
3250
+ *
3251
+ * @remarks
3252
+ * - Once a policy has disabled autofill for a Window or View, autofill stays disabled until that Window or View
3253
+ * closes, even if it navigates to a url where the policy does not apply.
3254
+ * - As a window or view option, `chromiumPolicies` is fixed when the Window or View is created: it cannot be changed
3255
+ * with `updateOptions`.
3256
+ * - A Window inherits the `chromiumPolicies` of its application, including those set in `mainWindowOptions`, unless
3257
+ * it sets its own.
3258
+ *
3247
3259
  * @interface
3248
3260
  */
3249
3261
  declare type ChromiumPolicies = {
@@ -4723,7 +4735,7 @@ declare type CreateLayoutOptions = {
4723
4735
  * Custom controls are not serialized into snapshots since callbacks are not
4724
4736
  * serializable. The callback is re-invoked when tabs are recreated.
4725
4737
  *
4726
- * **NOTE**: This feature is only supported with layout engine `'v2'` (GL2) and
4738
+ * **NOTE**: This feature is only supported with layout engine `'v2'` and
4727
4739
  * `settings.tabOverflowBehavior: 'scroll'`.
4728
4740
  *
4729
4741
  * Optionally add the `lm_tab_custom_control` class to each injected control as a direct child of
@@ -5569,7 +5581,7 @@ declare type Event_11 = ExcludeRequested<WindowEvents.PropagatedEvent<'system'>>
5569
5581
  * [Union](https://www.typescriptlang.org/docs/handbook/2/everyday-types.html#union-types) containing every possible event that can be emitted by the HTMLElement Layout container.
5570
5582
  * Events are discriminated by {@link LayoutDOMEvent.type}.
5571
5583
  */
5572
- declare type Event_12 = TabCreatedEvent | TabClosedEvent | TabDroppedEvent | ContainerCreatedEvent | LayoutStateChangedEvent;
5584
+ declare type Event_12 = TabCreatedEvent | TabClosedEvent | TabDroppedEvent | ContainerCreatedEvent | LayoutStateChangedEvent | TabPinnedChangedEvent;
5573
5585
 
5574
5586
  /**
5575
5587
  * [Union](https://www.typescriptlang.org/docs/handbook/2/everyday-types.html#union-types) containing every possible event that can be emitted by a {@link Channel}. Events are
@@ -8740,6 +8752,7 @@ declare type LaunchIntoPlatformPayload = {
8740
8752
  * * layout-state-changed
8741
8753
  * * tab-closed
8742
8754
  * * tab-dropped
8755
+ * * tab-pinned-changed
8743
8756
  *
8744
8757
  * ### Layout DOM Node Events
8745
8758
  *
@@ -8814,6 +8827,21 @@ declare type LaunchIntoPlatformPayload = {
8814
8827
  * url: "http://openfin.co" // The url of the view linked to the dropped tab.
8815
8828
  * }
8816
8829
  * ```
8830
+ *
8831
+ * #### tab-pinned-changed
8832
+ * Generated when a tab is pinned or unpinned via {@link Layout#setViewPinned setViewPinned}.
8833
+ * ```js
8834
+ * // The response has the following shape in event.detail:
8835
+ * {
8836
+ * containerSelector: "container-component_A",
8837
+ * name: "component_A",
8838
+ * tabSelector: "tab-component_A",
8839
+ * topic: "openfin-DOM-event",
8840
+ * type: "tab-pinned-changed",
8841
+ * uuid: "OpenFin POC",
8842
+ * pinned: true
8843
+ * }
8844
+ * ```
8817
8845
  */
8818
8846
  declare class Layout extends Base {
8819
8847
  #private;
@@ -9013,6 +9041,27 @@ declare class Layout extends Base {
9013
9041
  * @returns A promise that resolves when the view is closed.
9014
9042
  */
9015
9043
  closeView(viewIdentity: OpenFin_2.Identity): Promise<void>;
9044
+ /**
9045
+ * Pins or unpins a view's tab. When `pinned` is true, the tab moves to the leading pinned area of
9046
+ * its stack and snapshots record it as {@link OpenFin.LayoutComponent.pinned pinned: true}. When
9047
+ * false, it moves to the start of the unpinned tabs. Emits the layout DOM `tab-pinned-changed`
9048
+ * event when the pin state changes.
9049
+ *
9050
+ * @remarks Requires layout engine `'v2'` and `settings.tabOverflowBehavior: 'scroll'`.
9051
+ * Works whether or not `settings.allowUserPinning` is set. Throws if the view does not belong to this layout.
9052
+ *
9053
+ * @param viewIdentity - The identity of the view to pin or unpin.
9054
+ * @param pinned - `true` to pin; `false` to unpin.
9055
+ *
9056
+ * @example
9057
+ * ```js
9058
+ * const layout = fin.Platform.Layout.getCurrentSync();
9059
+ * await layout.setViewPinned({ uuid: fin.me.identity.uuid, name: 'my-view' }, true);
9060
+ * await layout.setViewPinned({ uuid: fin.me.identity.uuid, name: 'my-view' }, false);
9061
+ * ```
9062
+ * @experimental
9063
+ */
9064
+ setViewPinned(viewIdentity: OpenFin_2.Identity, pinned: boolean): Promise<void>;
9016
9065
  }
9017
9066
 
9018
9067
  /**
@@ -9055,6 +9104,15 @@ declare type LayoutComponent = Omit<LayoutItemConfig, 'content' | 'type'> & {
9055
9104
  * Only a component type will have this property and it represents the view options of a given component.
9056
9105
  */
9057
9106
  componentState?: Partial<ViewCreationOptions>;
9107
+ /**
9108
+ * **Platforms only.** Pins the tab to the leading pinned area of its stack (sibling to
9109
+ * `componentState`; not a view option). Users cannot drag pinned tabs out of their stack or
9110
+ * into another window; API moves within a layout keep the pin. Unless {@link LayoutOptions.settings allowUserPinning} is true, they also
9111
+ * cannot be closed or reordered. Use {@link Layout#setViewPinned setViewPinned} to change it at runtime.
9112
+ *
9113
+ * **NOTE**: Only applies with layout engine `'v2'` and `settings.tabOverflowBehavior: 'scroll'`.
9114
+ */
9115
+ pinned?: boolean;
9058
9116
  type: 'component';
9059
9117
  };
9060
9118
 
@@ -9097,6 +9155,7 @@ declare namespace LayoutDOMEvents {
9097
9155
  TabDroppedEvent,
9098
9156
  ContainerCreatedEvent,
9099
9157
  LayoutStateChangedEvent,
9158
+ TabPinnedChangedEvent,
9100
9159
  Event_12 as Event,
9101
9160
  EventType_9 as EventType,
9102
9161
  Payload_11 as Payload,
@@ -9125,6 +9184,7 @@ declare type LayoutEntitiesController = {
9125
9184
  edge: OpenFin_2.LayoutPosition;
9126
9185
  }) => Promise<Pick<OpenFin_2.LayoutEntityDefinition, 'entityId'>[]>;
9127
9186
  setStackActiveView: (stackEntityId: string, viewIdentity: OpenFin_2.Identity) => Promise<void>;
9187
+ setViewPinned: (viewIdentity: OpenFin_2.Identity, pinned: boolean, layoutIdentity?: OpenFin_2.LayoutIdentity) => Promise<void>;
9128
9188
  };
9129
9189
 
9130
9190
  /**
@@ -9735,6 +9795,21 @@ declare type LayoutOptions = {
9735
9795
  * @defaultValue 'dropdown'
9736
9796
  */
9737
9797
  tabOverflowBehavior?: 'dropdown' | 'scroll';
9798
+ /**
9799
+ * **Platforms only.** Whether pinned tabs ({@link LayoutComponent.pinned}) are managed by the user.
9800
+ *
9801
+ * - `false`: pins are platform-locked. Pinned tabs cannot be closed or reordered, and platform UI
9802
+ * should not offer pin / unpin.
9803
+ * - `true`: pinned tabs can be closed and reordered within the pinned area, and platform UI
9804
+ * may offer pin / unpin.
9805
+ *
9806
+ * {@link Layout#setViewPinned setViewPinned} works in both modes.
9807
+ *
9808
+ * **NOTE**: Only applies with layout engine `'v2'` and `tabOverflowBehavior: 'scroll'`.
9809
+ *
9810
+ * @defaultValue false
9811
+ */
9812
+ allowUserPinning?: boolean;
9738
9813
  };
9739
9814
  /**
9740
9815
  * Content of the layout. There can only be one top-level LayoutItem in the content array.
@@ -17912,6 +17987,16 @@ declare type TabDroppedEvent = LayoutDOMEvent & {
17912
17987
  url: string;
17913
17988
  };
17914
17989
 
17990
+ /**
17991
+ * Generated when a Layout Tab Component was pinned or unpinned via {@link OpenFin.Layout.setViewPinned}.
17992
+ * The identity is the view whose tab changed.
17993
+ * @interface
17994
+ */
17995
+ declare type TabPinnedChangedEvent = LayoutDOMEvent & {
17996
+ type: 'tab-pinned-changed';
17997
+ pinned: boolean;
17998
+ };
17999
+
17915
18000
  /**
17916
18001
  * A TabStack is used to manage the state of a stack of tabs within an OpenFin Layout.
17917
18002
  */
package/out/stub.js CHANGED
@@ -11689,6 +11689,7 @@ var _Layout_instances, _Layout_layoutClient, _Layout_forwardLayoutAction;
11689
11689
  * * layout-state-changed
11690
11690
  * * tab-closed
11691
11691
  * * tab-dropped
11692
+ * * tab-pinned-changed
11692
11693
  *
11693
11694
  * ### Layout DOM Node Events
11694
11695
  *
@@ -11763,6 +11764,21 @@ var _Layout_instances, _Layout_layoutClient, _Layout_forwardLayoutAction;
11763
11764
  * url: "http://openfin.co" // The url of the view linked to the dropped tab.
11764
11765
  * }
11765
11766
  * ```
11767
+ *
11768
+ * #### tab-pinned-changed
11769
+ * Generated when a tab is pinned or unpinned via {@link Layout#setViewPinned setViewPinned}.
11770
+ * ```js
11771
+ * // The response has the following shape in event.detail:
11772
+ * {
11773
+ * containerSelector: "container-component_A",
11774
+ * name: "component_A",
11775
+ * tabSelector: "tab-component_A",
11776
+ * topic: "openfin-DOM-event",
11777
+ * type: "tab-pinned-changed",
11778
+ * uuid: "OpenFin POC",
11779
+ * pinned: true
11780
+ * }
11781
+ * ```
11766
11782
  */
11767
11783
  class Layout extends Base {
11768
11784
  /**
@@ -12050,6 +12066,33 @@ class Layout extends Base {
12050
12066
  });
12051
12067
  await __classPrivateFieldGet$b(this, _Layout_instances, "m", _Layout_forwardLayoutAction).call(this, 'layout-close-view', { viewIdentity });
12052
12068
  }
12069
+ /**
12070
+ * Pins or unpins a view's tab. When `pinned` is true, the tab moves to the leading pinned area of
12071
+ * its stack and snapshots record it as {@link OpenFin.LayoutComponent.pinned pinned: true}. When
12072
+ * false, it moves to the start of the unpinned tabs. Emits the layout DOM `tab-pinned-changed`
12073
+ * event when the pin state changes.
12074
+ *
12075
+ * @remarks Requires layout engine `'v2'` and `settings.tabOverflowBehavior: 'scroll'`.
12076
+ * Works whether or not `settings.allowUserPinning` is set. Throws if the view does not belong to this layout.
12077
+ *
12078
+ * @param viewIdentity - The identity of the view to pin or unpin.
12079
+ * @param pinned - `true` to pin; `false` to unpin.
12080
+ *
12081
+ * @example
12082
+ * ```js
12083
+ * const layout = fin.Platform.Layout.getCurrentSync();
12084
+ * await layout.setViewPinned({ uuid: fin.me.identity.uuid, name: 'my-view' }, true);
12085
+ * await layout.setViewPinned({ uuid: fin.me.identity.uuid, name: 'my-view' }, false);
12086
+ * ```
12087
+ * @experimental
12088
+ */
12089
+ async setViewPinned(viewIdentity, pinned) {
12090
+ this.wire.sendAction('layout-set-view-pinned').catch(() => {
12091
+ // don't expose
12092
+ });
12093
+ const client = await __classPrivateFieldGet$b(this, _Layout_layoutClient, "f").getValue();
12094
+ await client.setViewPinned(viewIdentity, pinned, 'layoutName' in this.identity ? this.identity : undefined);
12095
+ }
12053
12096
  }
12054
12097
  _Layout_layoutClient = new WeakMap(), _Layout_instances = new WeakSet(), _Layout_forwardLayoutAction =
12055
12098
  /**
package/out/stub.mjs CHANGED
@@ -11686,6 +11686,7 @@ var _Layout_instances, _Layout_layoutClient, _Layout_forwardLayoutAction;
11686
11686
  * * layout-state-changed
11687
11687
  * * tab-closed
11688
11688
  * * tab-dropped
11689
+ * * tab-pinned-changed
11689
11690
  *
11690
11691
  * ### Layout DOM Node Events
11691
11692
  *
@@ -11760,6 +11761,21 @@ var _Layout_instances, _Layout_layoutClient, _Layout_forwardLayoutAction;
11760
11761
  * url: "http://openfin.co" // The url of the view linked to the dropped tab.
11761
11762
  * }
11762
11763
  * ```
11764
+ *
11765
+ * #### tab-pinned-changed
11766
+ * Generated when a tab is pinned or unpinned via {@link Layout#setViewPinned setViewPinned}.
11767
+ * ```js
11768
+ * // The response has the following shape in event.detail:
11769
+ * {
11770
+ * containerSelector: "container-component_A",
11771
+ * name: "component_A",
11772
+ * tabSelector: "tab-component_A",
11773
+ * topic: "openfin-DOM-event",
11774
+ * type: "tab-pinned-changed",
11775
+ * uuid: "OpenFin POC",
11776
+ * pinned: true
11777
+ * }
11778
+ * ```
11763
11779
  */
11764
11780
  class Layout extends Base {
11765
11781
  /**
@@ -12047,6 +12063,33 @@ class Layout extends Base {
12047
12063
  });
12048
12064
  await __classPrivateFieldGet$b(this, _Layout_instances, "m", _Layout_forwardLayoutAction).call(this, 'layout-close-view', { viewIdentity });
12049
12065
  }
12066
+ /**
12067
+ * Pins or unpins a view's tab. When `pinned` is true, the tab moves to the leading pinned area of
12068
+ * its stack and snapshots record it as {@link OpenFin.LayoutComponent.pinned pinned: true}. When
12069
+ * false, it moves to the start of the unpinned tabs. Emits the layout DOM `tab-pinned-changed`
12070
+ * event when the pin state changes.
12071
+ *
12072
+ * @remarks Requires layout engine `'v2'` and `settings.tabOverflowBehavior: 'scroll'`.
12073
+ * Works whether or not `settings.allowUserPinning` is set. Throws if the view does not belong to this layout.
12074
+ *
12075
+ * @param viewIdentity - The identity of the view to pin or unpin.
12076
+ * @param pinned - `true` to pin; `false` to unpin.
12077
+ *
12078
+ * @example
12079
+ * ```js
12080
+ * const layout = fin.Platform.Layout.getCurrentSync();
12081
+ * await layout.setViewPinned({ uuid: fin.me.identity.uuid, name: 'my-view' }, true);
12082
+ * await layout.setViewPinned({ uuid: fin.me.identity.uuid, name: 'my-view' }, false);
12083
+ * ```
12084
+ * @experimental
12085
+ */
12086
+ async setViewPinned(viewIdentity, pinned) {
12087
+ this.wire.sendAction('layout-set-view-pinned').catch(() => {
12088
+ // don't expose
12089
+ });
12090
+ const client = await __classPrivateFieldGet$b(this, _Layout_layoutClient, "f").getValue();
12091
+ await client.setViewPinned(viewIdentity, pinned, 'layoutName' in this.identity ? this.identity : undefined);
12092
+ }
12050
12093
  }
12051
12094
  _Layout_layoutClient = new WeakMap(), _Layout_instances = new WeakSet(), _Layout_forwardLayoutAction =
12052
12095
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openfin/core",
3
- "version": "46.100.94",
3
+ "version": "46.100.96",
4
4
  "description": "The core renderer entry point of OpenFin",
5
5
  "license": "SEE LICENSE IN LICENSE.md",
6
6
  "main": "out/stub.js",