@i2analyze/notebook-sdk 1.10.0-dev.20 → 1.10.0-dev.22

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.
@@ -2640,12 +2640,16 @@ export declare namespace commands {
2640
2640
  /**
2641
2641
  * Runs when the command is executed.
2642
2642
  *
2643
- * @param payload - The payload that i2 Notebook provides to the command. As well as the base payload
2644
- * for the command type, this includes the {@link commands.ICommandInvocationContext}
2645
- * that describes where and how the command was triggered.
2643
+ * @remarks
2644
+ * For "records" and "application" commands, the single payload argument combines the base payload
2645
+ * for the command type with the {@link commands.ICommandInvocationContext} that describes where and
2646
+ * how the command was triggered. For "unscoped" commands the invocation context is the only
2647
+ * argument and is optional, so the callback can be defined and invoked with no arguments.
2648
+ * @param args - The command payload for "records" and "application" commands, or the optional
2649
+ * invocation context for "unscoped" commands, as determined by the command type.
2646
2650
  * @i2since 1.0
2647
2651
  */
2648
- onExecute(payload: CommandExecutePayloadMap[TCommandType]): void;
2652
+ onExecute(...args: TCommandType extends 'unscoped' ? [invocationContext?: CommandExecutePayloadMap['unscoped']] : [payload: CommandExecutePayloadMap[TCommandType]]): void;
2649
2653
  /**
2650
2654
  * Runs when an action derived from the command is surfaced, enabling the command to configure the action in response to events.
2651
2655
  *
@@ -5012,9 +5016,36 @@ export declare namespace data {
5012
5016
  export declare namespace dialog {
5013
5017
  /**
5014
5018
  * A size for a dialog window.
5019
+ *
5020
+ * @remarks
5021
+ * The `'xmedium'` size requires version 1.10 or later.
5015
5022
  * @i2since 1.4
5016
5023
  */
5017
- export type DialogSize = 'small' | 'medium' | 'large';
5024
+ export type DialogSize = 'small' | 'medium' | 'xmedium' | 'large';
5025
+ /**
5026
+ * Explicit dimensions for a dialog window, as CSS length strings.
5027
+ *
5028
+ * @remarks
5029
+ * Each axis is independent and is clamped to the `'large'` size (approximately the size of the
5030
+ * viewport): a larger value is reduced to it. An omitted axis uses the `'medium'` size for that
5031
+ * axis; it does not size the dialog to fit its content.
5032
+ *
5033
+ * Each value must be an unsigned number followed by one of the units `px`, `rem`, `em`, `vh`,
5034
+ * `vw`, or `%` (for example, `'600px'`, `'40rem'`, or `'75%'`).
5035
+ * @i2since 1.10
5036
+ */
5037
+ export interface IDialogDimensions {
5038
+ /**
5039
+ * Gets the width of the dialog. Omit to use the `'medium'` width. Clamped to the `'large'` size.
5040
+ * @i2since 1.10
5041
+ */
5042
+ readonly width?: string;
5043
+ /**
5044
+ * Gets the height of the dialog. Omit to use the `'medium'` height. Clamped to the `'large'` size.
5045
+ * @i2since 1.10
5046
+ */
5047
+ readonly height?: string;
5048
+ }
5018
5049
  /**
5019
5050
  * An identifier of a dialog action.
5020
5051
  * @i2since 1.4
@@ -5068,10 +5099,14 @@ export declare namespace dialog {
5068
5099
  */
5069
5100
  readonly path: string;
5070
5101
  /**
5071
- * Gets the size of the dialog.
5102
+ * Gets the size of the dialog, either as a named preset or as explicit dimensions.
5103
+ *
5104
+ * @remarks
5105
+ * Explicit {@link dialog.IDialogDimensions | dimensions} and the `'xmedium'` preset require
5106
+ * version 1.10 or later.
5072
5107
  * @i2since 1.4
5073
5108
  */
5074
- readonly size: DialogSize;
5109
+ readonly size: DialogSize | IDialogDimensions;
5075
5110
  /**
5076
5111
  * Gets the data for populating the dialog when it's first displayed.
5077
5112
  *
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@i2analyze/notebook-sdk",
3
- "version": "1.10.0-dev.20",
3
+ "version": "1.10.0-dev.22",
4
4
  "description": "i2 Notebook SDK",
5
5
  "license": "MIT",
6
6
  "publishConfig": {