@checksub_team/peaks_timeline 2.5.0-alpha.3 → 2.6.0

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@checksub_team/peaks_timeline",
3
- "version": "2.5.0-alpha.3",
3
+ "version": "2.6.0",
4
4
  "description": "JavaScript UI component for displaying audio waveforms",
5
5
  "main": "./peaks.js",
6
6
  "types": "./peaks.js.d.ts",
package/peaks.js CHANGED
@@ -21698,17 +21698,17 @@ module.exports = function (Colors, EventEmitter, SegmentHandler, SourceHandler,
21698
21698
  Peaks.prototype.getSourceGroupById = function (id) {
21699
21699
  return this.view.getSourceGroupById(id);
21700
21700
  };
21701
- Peaks.prototype.selectSourceById = function (sourceId) {
21702
- return this.view.selectSourceById(sourceId);
21701
+ Peaks.prototype.selectSourceById = function (sourceId, notify) {
21702
+ return this.view.selectSourceById(sourceId, notify);
21703
21703
  };
21704
- Peaks.prototype.selectSourcesOnLineAfter = function (lineId, time) {
21705
- return this.view.selectSourcesOnLineAfter(lineId, time);
21704
+ Peaks.prototype.selectSourcesOnLineAfter = function (lineId, time, notify) {
21705
+ return this.view.selectSourcesOnLineAfter(lineId, time, notify);
21706
21706
  };
21707
- Peaks.prototype.selectSegmentById = function (segmentId) {
21708
- return this.view.selectSegmentById(segmentId);
21707
+ Peaks.prototype.selectSegmentById = function (segmentId, notify) {
21708
+ return this.view.selectSegmentById(segmentId, notify);
21709
21709
  };
21710
- Peaks.prototype.selectSegmentsOnLineAfter = function (lineId, time) {
21711
- return this.view.selectSegmentsOnLineAfter(lineId, time);
21710
+ Peaks.prototype.selectSegmentsOnLineAfter = function (lineId, time, notify) {
21711
+ return this.view.selectSegmentsOnLineAfter(lineId, time, notify);
21712
21712
  };
21713
21713
  Peaks.prototype.deselectAll = function (notify) {
21714
21714
  return this.view.deselectAll(notify);
@@ -24318,28 +24318,28 @@ module.exports = function (MouseDragHandler, PlayheadLayer, SourcesLayer, ModeLa
24318
24318
  View.prototype.getSourceGroupById = function (sourceId) {
24319
24319
  return this._sourcesLayer.getSourceGroupById(sourceId);
24320
24320
  };
24321
- View.prototype.selectSourceById = function (sourceId) {
24321
+ View.prototype.selectSourceById = function (sourceId, notify) {
24322
24322
  const sourceGroup = this._sourcesLayer.getSourceGroupById(sourceId);
24323
24323
  if (sourceGroup) {
24324
- this._modeLayer.selectElements([sourceGroup.getSource()], true);
24324
+ this._modeLayer.selectElements([sourceGroup.getSource()], notify);
24325
24325
  }
24326
24326
  };
24327
- View.prototype.selectSourcesOnLineAfter = function (lineId, time) {
24327
+ View.prototype.selectSourcesOnLineAfter = function (lineId, time, notify) {
24328
24328
  const sources = this._sourcesLayer.getSourcesOnLineAfter(lineId, time);
24329
24329
  if (sources.length) {
24330
- this._modeLayer.selectElements(sources, true);
24330
+ this._modeLayer.selectElements(sources, notify);
24331
24331
  }
24332
24332
  };
24333
- View.prototype.selectSegmentById = function (segmentId) {
24333
+ View.prototype.selectSegmentById = function (segmentId, notify) {
24334
24334
  const segment = this._peaks.segmentHandler.getSegment(segmentId);
24335
24335
  if (segment) {
24336
- this._modeLayer.selectElements([segment], true);
24336
+ this._modeLayer.selectElements([segment], notify);
24337
24337
  }
24338
24338
  };
24339
- View.prototype.selectSegmentsOnLineAfter = function (lineId, time) {
24339
+ View.prototype.selectSegmentsOnLineAfter = function (lineId, time, notify) {
24340
24340
  const segments = this._sourcesLayer.getSegmentsOnLineAfter(lineId, time);
24341
24341
  if (segments.length) {
24342
- this._modeLayer.selectElements(segments, true);
24342
+ this._modeLayer.selectElements(segments, notify);
24343
24343
  }
24344
24344
  };
24345
24345
  View.prototype.deselectAll = function (notify) {
package/peaks.js.d.ts CHANGED
@@ -276,10 +276,10 @@ declare module 'peaks.js' {
276
276
  setSource: (options: SetSourceOptions, callback: SetSourceCallback) => void;
277
277
  destroy: () => void;
278
278
  getSelectedElements: () => object[];
279
- selectSourceById: (sourceId: string) => void;
280
- selectSourcesOnLineAfter: (lineId: string, time: number) => void;
281
- selectSegmentById: (segmentId: string) => void;
282
- selectSegmentsOnLineAfter: (lineId: string | number, time: number) => void;
279
+ selectSourceById: (sourceId: string, notify?: boolean) => void;
280
+ selectSourcesOnLineAfter: (lineId: string, time: number, notify?: boolean) => void;
281
+ selectSegmentById: (segmentId: string, notify?: boolean) => void;
282
+ selectSegmentsOnLineAfter: (lineId: string | number, time: number, notify?: boolean) => void;
283
283
  deselectAll: (notify?: boolean) => void;
284
284
  /** Player API */
285
285
  player: {
package/src/main.js CHANGED
@@ -796,9 +796,9 @@ define([
796
796
  *
797
797
  * @param {String} sourceId
798
798
  */
799
- Peaks.prototype.selectSourceById = function(sourceId) {
799
+ Peaks.prototype.selectSourceById = function(sourceId, notify) {
800
800
  return this.view
801
- .selectSourceById(sourceId);
801
+ .selectSourceById(sourceId, notify);
802
802
  };
803
803
 
804
804
  /**
@@ -807,9 +807,9 @@ define([
807
807
  * @param {String} lineId
808
808
  * @param {Number} time
809
809
  */
810
- Peaks.prototype.selectSourcesOnLineAfter = function(lineId, time) {
810
+ Peaks.prototype.selectSourcesOnLineAfter = function(lineId, time, notify) {
811
811
  return this.view
812
- .selectSourcesOnLineAfter(lineId, time);
812
+ .selectSourcesOnLineAfter(lineId, time, notify);
813
813
  };
814
814
 
815
815
  /**
@@ -817,9 +817,9 @@ define([
817
817
  *
818
818
  * @param {String} segmentId
819
819
  */
820
- Peaks.prototype.selectSegmentById = function(segmentId) {
820
+ Peaks.prototype.selectSegmentById = function(segmentId, notify) {
821
821
  return this.view
822
- .selectSegmentById(segmentId);
822
+ .selectSegmentById(segmentId, notify);
823
823
  };
824
824
 
825
825
  /**
@@ -828,9 +828,9 @@ define([
828
828
  * @param {String|Number} lineId
829
829
  * @param {Number} time
830
830
  */
831
- Peaks.prototype.selectSegmentsOnLineAfter = function(lineId, time) {
831
+ Peaks.prototype.selectSegmentsOnLineAfter = function(lineId, time, notify) {
832
832
  return this.view
833
- .selectSegmentsOnLineAfter(lineId, time);
833
+ .selectSegmentsOnLineAfter(lineId, time, notify);
834
834
  };
835
835
 
836
836
  Peaks.prototype.deselectAll = function(notify) {
package/src/view.js CHANGED
@@ -530,11 +530,11 @@ define([
530
530
  *
531
531
  * @param {String} sourceId
532
532
  */
533
- View.prototype.selectSourceById = function(sourceId) {
533
+ View.prototype.selectSourceById = function(sourceId, notify) {
534
534
  const sourceGroup = this._sourcesLayer.getSourceGroupById(sourceId);
535
535
 
536
536
  if (sourceGroup) {
537
- this._modeLayer.selectElements([sourceGroup.getSource()], true);
537
+ this._modeLayer.selectElements([sourceGroup.getSource()], notify);
538
538
  }
539
539
  };
540
540
 
@@ -544,11 +544,11 @@ define([
544
544
  * @param {String} lineId
545
545
  * @param {Number} time
546
546
  */
547
- View.prototype.selectSourcesOnLineAfter = function(lineId, time) {
547
+ View.prototype.selectSourcesOnLineAfter = function(lineId, time, notify) {
548
548
  const sources = this._sourcesLayer.getSourcesOnLineAfter(lineId, time);
549
549
 
550
550
  if (sources.length) {
551
- this._modeLayer.selectElements(sources, true);
551
+ this._modeLayer.selectElements(sources, notify);
552
552
  }
553
553
  };
554
554
 
@@ -557,11 +557,11 @@ define([
557
557
  *
558
558
  * @param {String} segmentId
559
559
  */
560
- View.prototype.selectSegmentById = function(segmentId) {
560
+ View.prototype.selectSegmentById = function(segmentId, notify) {
561
561
  const segment = this._peaks.segmentHandler.getSegment(segmentId);
562
562
 
563
563
  if (segment) {
564
- this._modeLayer.selectElements([segment], true);
564
+ this._modeLayer.selectElements([segment], notify);
565
565
  }
566
566
  };
567
567
 
@@ -571,11 +571,11 @@ define([
571
571
  * @param {String|Number} lineId
572
572
  * @param {Number} time
573
573
  */
574
- View.prototype.selectSegmentsOnLineAfter = function(lineId, time) {
574
+ View.prototype.selectSegmentsOnLineAfter = function(lineId, time, notify) {
575
575
  const segments = this._sourcesLayer.getSegmentsOnLineAfter(lineId, time);
576
576
 
577
577
  if (segments.length) {
578
- this._modeLayer.selectElements(segments, true);
578
+ this._modeLayer.selectElements(segments, notify);
579
579
  }
580
580
  };
581
581