@i2analyze/notebook-sdk 1.9.0-dev.14 → 1.9.0-dev.16

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.
@@ -365,6 +365,22 @@ export declare namespace app {
365
365
  * @i2since 1.1
366
366
  */
367
367
  setMessage(text: string): void;
368
+ /**
369
+ * Reports numeric progress and optionally yields the UI thread to keep the application responsive.
370
+ *
371
+ * @remarks
372
+ * Use this method in tight loops to show a determinate progress bar and prevent the application
373
+ * from becoming unresponsive. The returned promise should be awaited on each iteration.
374
+ *
375
+ * To yield the UI thread without showing a progress bar (when the total is not known),
376
+ * pass `0` for both `done` and `total`.
377
+ *
378
+ * @param done - The amount of work completed so far.
379
+ * @param total - The total amount of work. When greater than `0`, a determinate progress bar is shown.
380
+ * @returns A promise that resolves after optionally yielding the UI thread.
381
+ * @i2since 1.9
382
+ */
383
+ setProgress(done: number, total: number): Promise<void>;
368
384
  }
369
385
  /**
370
386
  * A common specifier for a record, for use in mutation APIs.
@@ -6589,25 +6605,28 @@ export declare namespace visual {
6589
6605
  /**
6590
6606
  * Sets the brush index for a single record.
6591
6607
  *
6592
- * @param recordId - The identifier of the record.
6608
+ * @param record - The record, or the identifier of the record.
6593
6609
  * @param index - The brush index to assign to the record.
6610
+ * @throws `Error` if the record does not exist on the chart.
6594
6611
  * @i2since 1.9
6595
6612
  */
6596
- set(recordId: records.AnalyzeRecordId, index: BrushIndex): void;
6613
+ set(record: app.RecordSpecifier, index: BrushIndex): void;
6597
6614
  /**
6598
6615
  * Sets the brush index for multiple records.
6599
6616
  *
6600
- * @param entries - An iterable of `[recordId, index]` tuples for multiple records.
6617
+ * @param entries - An iterable of `[record, index]` tuples for multiple records.
6618
+ * @throws `Error` if one or more of the records do not exist on the chart.
6601
6619
  * @i2since 1.9
6602
6620
  */
6603
- set(entries: Iterable<[records.AnalyzeRecordId, BrushIndex]>): void;
6621
+ set(entries: Iterable<[app.RecordSpecifier, BrushIndex]>): void;
6604
6622
  /**
6605
6623
  * Removes specific records from the brush set.
6606
6624
  *
6607
- * @param recordIds - An iterable of record identifiers to remove.
6625
+ * @param records - An iterable of records, or record identifiers, to remove.
6626
+ * @throws `Error` if one or more of the records do not exist on the chart.
6608
6627
  * @i2since 1.9
6609
6628
  */
6610
- remove(recordIds: Iterable<records.AnalyzeRecordId>): void;
6629
+ remove(records: Iterable<app.RecordSpecifier> | app.RecordSpecifier): void;
6611
6630
  /**
6612
6631
  * Gets the brush index for a record, or `undefined` if the record is not in the brush set.
6613
6632
  *
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@i2analyze/notebook-sdk",
3
- "version": "1.9.0-dev.14",
3
+ "version": "1.9.0-dev.16",
4
4
  "description": "i2 Notebook SDK",
5
5
  "license": "MIT",
6
6
  "publishConfig": {