scichart 2.1.2301 → 2.2.2351

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.
Files changed (95) hide show
  1. package/Builder/buildModifiers.d.ts +2 -1
  2. package/Charting/ChartModifiers/CursorModifier.d.ts +5 -0
  3. package/Charting/ChartModifiers/CursorModifier.js +15 -10
  4. package/Charting/ChartModifiers/LegendModifier.d.ts +31 -0
  5. package/Charting/ChartModifiers/LegendModifier.js +22 -0
  6. package/Charting/ChartModifiers/RolloverModifier.d.ts +10 -0
  7. package/Charting/ChartModifiers/RolloverModifier.js +76 -19
  8. package/Charting/LayoutManager/LayoutManager.js +6 -1
  9. package/Charting/Model/BaseHeatmapDataSeries.d.ts +1 -0
  10. package/Charting/Model/BaseHeatmapDataSeries.js +4 -1
  11. package/Charting/Model/PointSeries/BasePointSeriesWrapped.d.ts +1 -1
  12. package/Charting/Model/PointSeries/BasePointSeriesWrapped.js +2 -2
  13. package/Charting/Model/PointSeries/XyyPointSeriesWrapped.d.ts +1 -1
  14. package/Charting/Model/PointSeries/XyyPointSeriesWrapped.js +3 -3
  15. package/Charting/Visuals/Annotations/AnnotationBase.d.ts +6 -1
  16. package/Charting/Visuals/Annotations/AnnotationBase.js +23 -2
  17. package/Charting/Visuals/Annotations/CursorTooltipSvgAnnotation.d.ts +6 -0
  18. package/Charting/Visuals/Annotations/CursorTooltipSvgAnnotation.js +46 -5
  19. package/Charting/Visuals/Annotations/CustomAnnotation.d.ts +3 -1
  20. package/Charting/Visuals/Annotations/CustomAnnotation.js +14 -3
  21. package/Charting/Visuals/Annotations/HorizontalLineAnnotation.d.ts +4 -0
  22. package/Charting/Visuals/Annotations/HorizontalLineAnnotation.js +3 -2
  23. package/Charting/Visuals/Annotations/RolloverLegendSvgAnnotation.d.ts +1 -1
  24. package/Charting/Visuals/Annotations/RolloverLegendSvgAnnotation.js +13 -3
  25. package/Charting/Visuals/Annotations/RolloverTooltipSvgAnnotation.d.ts +13 -0
  26. package/Charting/Visuals/Annotations/RolloverTooltipSvgAnnotation.js +63 -14
  27. package/Charting/Visuals/Annotations/VerticalLineAnnotation.d.ts +2 -0
  28. package/Charting/Visuals/Annotations/VerticalLineAnnotation.js +3 -2
  29. package/Charting/Visuals/Annotations/constants.d.ts +2 -1
  30. package/Charting/Visuals/Annotations/constants.js +1 -0
  31. package/Charting/Visuals/Axis/AxisBase2D.d.ts +10 -0
  32. package/Charting/Visuals/Axis/AxisBase2D.js +72 -1
  33. package/Charting/Visuals/Axis/LabelProvider/PieLabelProvider.d.ts +29 -0
  34. package/Charting/Visuals/Axis/LabelProvider/PieLabelProvider.js +77 -0
  35. package/Charting/Visuals/Axis/LabelProvider/SmartDateLabelProvider.d.ts +2 -2
  36. package/Charting/Visuals/Axis/LabelProvider/SmartDateLabelProvider.js +21 -4
  37. package/Charting/Visuals/Helpers/drawLabel.d.ts +3 -3
  38. package/Charting/Visuals/Helpers/drawLabel.js +38 -18
  39. package/Charting/Visuals/I2DSurfaceOptions.d.ts +6 -0
  40. package/Charting/Visuals/Legend/SciChartLegend.d.ts +4 -0
  41. package/Charting/Visuals/Legend/SciChartLegend.js +7 -1
  42. package/Charting/Visuals/RenderableSeries/BaseRenderableSeries.d.ts +16 -7
  43. package/Charting/Visuals/RenderableSeries/BaseRenderableSeries.js +56 -9
  44. package/Charting/Visuals/RenderableSeries/BaseStackedCollection.d.ts +3 -0
  45. package/Charting/Visuals/RenderableSeries/BaseStackedCollection.js +8 -0
  46. package/Charting/Visuals/RenderableSeries/BaseStackedRenderableSeries.d.ts +17 -166
  47. package/Charting/Visuals/RenderableSeries/BaseStackedRenderableSeries.js +35 -328
  48. package/Charting/Visuals/RenderableSeries/DrawingProviders/BandSeriesDrawingProvider.d.ts +5 -2
  49. package/Charting/Visuals/RenderableSeries/DrawingProviders/BandSeriesDrawingProvider.js +5 -3
  50. package/Charting/Visuals/RenderableSeries/IBaseRenderableSeriesOptions.d.ts +8 -0
  51. package/Charting/Visuals/RenderableSeries/IRenderableSeries.d.ts +6 -0
  52. package/Charting/Visuals/RenderableSeries/SeriesVisibleChangedArgs.d.ts +6 -0
  53. package/Charting/Visuals/RenderableSeries/SeriesVisibleChangedArgs.js +11 -0
  54. package/Charting/Visuals/RenderableSeries/StackedColumnRenderableSeries.d.ts +22 -0
  55. package/Charting/Visuals/RenderableSeries/StackedColumnRenderableSeries.js +38 -1
  56. package/Charting/Visuals/RenderableSeries/StackedMountainCollection.d.ts +2 -2
  57. package/Charting/Visuals/RenderableSeries/StackedMountainCollection.js +26 -45
  58. package/Charting/Visuals/RenderableSeries/StackedMountainRenderableSeries.d.ts +77 -18
  59. package/Charting/Visuals/RenderableSeries/StackedMountainRenderableSeries.js +139 -42
  60. package/Charting/Visuals/RenderableSeries/XyScatterRenderableSeries.d.ts +5 -0
  61. package/Charting/Visuals/RenderableSeries/XyScatterRenderableSeries.js +21 -1
  62. package/Charting/Visuals/RenderableSeries/constants.d.ts +2 -0
  63. package/Charting/Visuals/RenderableSeries/constants.js +2 -0
  64. package/Charting/Visuals/SciChartPieSurface/IPieSurfaceOptions.d.ts +24 -2
  65. package/Charting/Visuals/SciChartPieSurface/PieSegment/IPieSegment.d.ts +4 -1
  66. package/Charting/Visuals/SciChartPieSurface/PieSegment/PieSegment.d.ts +13 -2
  67. package/Charting/Visuals/SciChartPieSurface/PieSegment/PieSegment.js +66 -20
  68. package/Charting/Visuals/SciChartPieSurface/PieSegment/constants.d.ts +3 -1
  69. package/Charting/Visuals/SciChartPieSurface/PieSegment/constants.js +2 -0
  70. package/Charting/Visuals/SciChartPieSurface/SciChartPieSurface.d.ts +66 -2
  71. package/Charting/Visuals/SciChartPieSurface/SciChartPieSurface.js +304 -52
  72. package/Charting/Visuals/SciChartPieSurface/constants.d.ts +6 -1
  73. package/Charting/Visuals/SciChartPieSurface/constants.js +5 -0
  74. package/Charting/Visuals/SciChartSurface.d.ts +13 -2
  75. package/Charting/Visuals/SciChartSurface.js +39 -3
  76. package/Charting/Visuals/createMaster.js +2 -2
  77. package/Charting/Visuals/createSingle.js +2 -2
  78. package/Charting/Visuals/sciChartInitCommon.d.ts +2 -2
  79. package/Charting/Visuals/sciChartInitCommon.js +13 -9
  80. package/Charting3D/Visuals/Primitives/ScatterPointsSceneEntity.js +6 -2
  81. package/Core/BuildStamp.d.ts +1 -1
  82. package/Core/BuildStamp.js +2 -2
  83. package/_wasm/scichart.browser.js +1 -1
  84. package/_wasm/scichart2d.js +1 -1
  85. package/_wasm/scichart2d.wasm +0 -0
  86. package/_wasm/scichart3d.js +95 -95
  87. package/_wasm/scichart3d.wasm +0 -0
  88. package/package.json +1 -1
  89. package/types/Color.d.ts +1 -0
  90. package/types/Color.js +1 -0
  91. package/types/LabelPlacement.d.ts +8 -0
  92. package/types/LabelPlacement.js +11 -1
  93. package/types/LabelProviderType.d.ts +5 -1
  94. package/types/LabelProviderType.js +4 -0
  95. package/types/TSciChartSurfaceCanvases.d.ts +1 -0
@@ -11,6 +11,7 @@ import { ISeriesSelectionModifierOptions } from "../Charting/ChartModifiers/Seri
11
11
  import { IXAxisDragModifierOptions } from "../Charting/ChartModifiers/XAxisDragModifier";
12
12
  import { IYAxisDragModifierOptions } from "../Charting/ChartModifiers/YAxisDragModifier";
13
13
  import { IZoomExtentsModifierOptions } from "../Charting/ChartModifiers/ZoomExtentsModifier";
14
+ import { IZoomPanModifierOptions } from "../Charting/ChartModifiers/ZoomPanModifier";
14
15
  import { EChart2DModifierType } from "../types/ChartModifierType";
15
16
  /** Definition of a 2d chart modifier, comprising a {@link EChart2DModifierType} and the relevant options */
16
17
  export declare type TModifierDefinition = {
@@ -48,7 +49,7 @@ export declare type TModifierDefinition = {
48
49
  options?: IZoomExtentsModifierOptions;
49
50
  } | {
50
51
  type: EChart2DModifierType.ZoomPan;
51
- options?: IChartModifierBaseOptions;
52
+ options?: IZoomPanModifierOptions;
52
53
  } | {
53
54
  type: EChart2DModifierType.OverviewRangeSelection;
54
55
  options?: IRangeSelectionModifierOptions;
@@ -33,6 +33,7 @@ export interface ICursorModifierOptions extends IChartModifierBaseOptions {
33
33
  tooltipLegendOffsetX?: number;
34
34
  tooltipLegendOffsetY?: number;
35
35
  tooltipDataTemplate?: TCursorTooltipDataTemplate | string;
36
+ placementDivId?: string;
36
37
  }
37
38
  /**
38
39
  * The CursorModifier provides tooltip and cursor behavior on a 2D {@link SciChartSurface}
@@ -117,6 +118,7 @@ export declare class CursorModifier extends ChartModifierBase2D implements IIncl
117
118
  private crosshairStrokeProperty;
118
119
  private tooltipDataTemplateProperty?;
119
120
  private includedSeriesMap;
121
+ private placementDivId;
120
122
  /**
121
123
  * Creates an instance of the CursorModifier
122
124
  *
@@ -194,6 +196,9 @@ export declare class CursorModifier extends ChartModifierBase2D implements IIncl
194
196
  getMousePosition(): EMousePosition;
195
197
  /** @inheritDoc */
196
198
  toJSON(): {
199
+ /**
200
+ * Gets or sets the xAxis label text color as an HTML Color code
201
+ */
197
202
  type: string;
198
203
  options: Required<Omit<IChartModifierBaseOptions, never>>;
199
204
  };
@@ -51,7 +51,7 @@ var CursorModifier = /** @class */ (function (_super) {
51
51
  * @param options Optional parameters {@link ICursorModifierOptions} used to configure the modifier
52
52
  */
53
53
  function CursorModifier(options) {
54
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t;
54
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u;
55
55
  var _this = _super.call(this, options) || this;
56
56
  _this.type = ChartModifierType_1.EChart2DModifierType.Cursor;
57
57
  _this.tooltipSvgTemplate = defaultTooltipTemplate;
@@ -135,6 +135,7 @@ var CursorModifier = /** @class */ (function (_super) {
135
135
  _this.xAxisLabelFill = (_m = options === null || options === void 0 ? void 0 : options.xAxisLabelFill) !== null && _m !== void 0 ? _m : _this.xAxisLabelFill;
136
136
  _this.yAxisLabelStroke = (_o = options === null || options === void 0 ? void 0 : options.yAxisLabelStroke) !== null && _o !== void 0 ? _o : _this.yAxisLabelStroke;
137
137
  _this.yAxisLabelFill = (_p = options === null || options === void 0 ? void 0 : options.yAxisLabelFill) !== null && _p !== void 0 ? _p : _this.yAxisLabelFill;
138
+ _this.placementDivId = (_q = options === null || options === void 0 ? void 0 : options.placementDivId) !== null && _q !== void 0 ? _q : _this.placementDivId;
138
139
  if (options === null || options === void 0 ? void 0 : options.tooltipLegendTemplate) {
139
140
  if (typeof options.tooltipLegendTemplate === "string") {
140
141
  _this.typeMap.set("tooltipLegendTemplate", options.tooltipLegendTemplate);
@@ -143,9 +144,9 @@ var CursorModifier = /** @class */ (function (_super) {
143
144
  }
144
145
  }
145
146
  _this.tooltipLegendTemplate =
146
- (_q = options === null || options === void 0 ? void 0 : options.tooltipLegendTemplate) !== null && _q !== void 0 ? _q : _this.tooltipLegendTemplate;
147
- _this.tooltipLegendOffsetX = (_r = options === null || options === void 0 ? void 0 : options.tooltipLegendOffsetX) !== null && _r !== void 0 ? _r : _this.tooltipLegendOffsetX;
148
- _this.tooltipLegendOffsetY = (_s = options === null || options === void 0 ? void 0 : options.tooltipLegendOffsetY) !== null && _s !== void 0 ? _s : _this.tooltipLegendOffsetY;
147
+ (_r = options === null || options === void 0 ? void 0 : options.tooltipLegendTemplate) !== null && _r !== void 0 ? _r : _this.tooltipLegendTemplate;
148
+ _this.tooltipLegendOffsetX = (_s = options === null || options === void 0 ? void 0 : options.tooltipLegendOffsetX) !== null && _s !== void 0 ? _s : _this.tooltipLegendOffsetX;
149
+ _this.tooltipLegendOffsetY = (_t = options === null || options === void 0 ? void 0 : options.tooltipLegendOffsetY) !== null && _t !== void 0 ? _t : _this.tooltipLegendOffsetY;
149
150
  if (options === null || options === void 0 ? void 0 : options.tooltipDataTemplate) {
150
151
  if (typeof options.tooltipDataTemplate === "string") {
151
152
  _this.typeMap.set("tooltipDataTemplate", options.tooltipDataTemplate);
@@ -154,7 +155,7 @@ var CursorModifier = /** @class */ (function (_super) {
154
155
  }
155
156
  }
156
157
  _this.tooltipDataTemplateProperty =
157
- (_t = options === null || options === void 0 ? void 0 : options.tooltipDataTemplate) !== null && _t !== void 0 ? _t : _this.tooltipDataTemplateProperty;
158
+ (_u = options === null || options === void 0 ? void 0 : options.tooltipDataTemplate) !== null && _u !== void 0 ? _u : _this.tooltipDataTemplateProperty;
158
159
  return _this;
159
160
  }
160
161
  /**
@@ -188,7 +189,8 @@ var CursorModifier = /** @class */ (function (_super) {
188
189
  tooltipLegendOffsetX: this.tooltipLegendOffsetX,
189
190
  tooltipLegendOffsetY: this.tooltipLegendOffsetY,
190
191
  xAxisId: this.xAxisId,
191
- yAxisId: this.yAxisId
192
+ yAxisId: this.yAxisId,
193
+ placementDivId: this.placementDivId
192
194
  });
193
195
  this.parentSurface.modifierAnnotations.add(this.xLineAnnotation, this.yLineAnnotation, this.tooltipAnnotation);
194
196
  };
@@ -386,6 +388,9 @@ var CursorModifier = /** @class */ (function (_super) {
386
388
  this.xLineAnnotation.isHidden = true;
387
389
  this.yLineAnnotation.isHidden = true;
388
390
  this.tooltipAnnotation.isHidden = true;
391
+ if (this.placementDivId) {
392
+ this.tooltipAnnotation.delete();
393
+ }
389
394
  return;
390
395
  }
391
396
  var translatedMousePoint = (0, translate_1.translateFromCanvasToSeriesViewRect)(this.mousePoint, this.parentSurface.seriesViewRect);
@@ -400,18 +405,18 @@ var CursorModifier = /** @class */ (function (_super) {
400
405
  this.xLineAnnotation.y1 = 0;
401
406
  this.yLineAnnotation.x1 = 0;
402
407
  if (this.isVerticalChart()) {
403
- this.xLineAnnotation.y2 = this.parentSurface.seriesViewRect.right;
408
+ this.xLineAnnotation.y2 = (0, translate_1.translateToNotScaled)(this.parentSurface.seriesViewRect.right);
404
409
  this.xLineAnnotation.x1 = y;
405
410
  this.xLineAnnotation.x2 = y;
406
- this.yLineAnnotation.x2 = this.parentSurface.seriesViewRect.bottom;
411
+ this.yLineAnnotation.x2 = (0, translate_1.translateToNotScaled)(this.parentSurface.seriesViewRect.bottom);
407
412
  this.yLineAnnotation.y1 = x;
408
413
  this.yLineAnnotation.y2 = x;
409
414
  }
410
415
  else {
411
- this.xLineAnnotation.y2 = this.parentSurface.seriesViewRect.bottom;
416
+ this.xLineAnnotation.y2 = (0, translate_1.translateToNotScaled)(this.parentSurface.seriesViewRect.bottom);
412
417
  this.xLineAnnotation.x1 = x;
413
418
  this.xLineAnnotation.x2 = x;
414
- this.yLineAnnotation.x2 = this.parentSurface.seriesViewRect.right;
419
+ this.yLineAnnotation.x2 = (0, translate_1.translateToNotScaled)(this.parentSurface.seriesViewRect.right);
415
420
  this.yLineAnnotation.y1 = y;
416
421
  this.yLineAnnotation.y2 = y;
417
422
  }
@@ -1,3 +1,4 @@
1
+ import { EventHandler } from "../../Core/EventHandler";
1
2
  import { IIncludeSeries } from "../../Core/IIncludeSeries";
2
3
  import { EChart2DModifierType } from "../../types/ChartModifierType";
3
4
  import { IThemeProvider } from "../Themes/IThemeProvider";
@@ -37,7 +38,26 @@ export interface ILegendModifierOptions extends IChartModifierBaseOptions {
37
38
  * The parent div element Id or reference, the Legend will be appended to this element
38
39
  */
39
40
  placementDivId?: string | HTMLDivElement;
41
+ /**
42
+ * Callback when a legend item checkbox is checked or unchecked (by default, this corresponds to {@link IRenderableSeries.isVisible}
43
+ * @param series
44
+ * @param isChecked
45
+ */
46
+ isCheckedChangedCallback?: (series: IRenderableSeries, isChecked: boolean) => void;
40
47
  }
48
+ /**
49
+ * Type args for the {@link LegendModifier.isCheckedChanged} callback
50
+ */
51
+ export declare type TCheckedChangedArgs = {
52
+ /**
53
+ * The series which was checked or unchecked
54
+ */
55
+ series: IRenderableSeries;
56
+ /**
57
+ * Whether the corresponding legend item is checked or not (by default, this corresponds to {@link IRenderableSeries.isVisible})
58
+ */
59
+ isChecked: boolean;
60
+ };
41
61
  /**
42
62
  * The LegendModifier provides interactive legend behavior on a 2D {@link SciChartSurface}
43
63
  * within SciChart - High Performance {@link https://www.scichart.com/javascript-chart-features | JavaScript Charts}
@@ -57,6 +77,10 @@ export declare class LegendModifier extends ChartModifierBase2D implements IIncl
57
77
  * Gets the {@link SciChartLegend} control used to render the legend
58
78
  */
59
79
  sciChartLegend: SciChartLegend;
80
+ /**
81
+ * An event handler raised when a {@link SciChartLegend} row checkbox is checked or unchecked
82
+ */
83
+ readonly isCheckedChanged: EventHandler<TCheckedChangedArgs>;
60
84
  private includedSeriesMap;
61
85
  /**
62
86
  * Creates an instance of the LegendModifier
@@ -86,6 +110,13 @@ export declare class LegendModifier extends ChartModifierBase2D implements IIncl
86
110
  };
87
111
  /** @inheritDoc */
88
112
  delete(): void;
113
+ /**
114
+ * Callback called from inner {@link SciChartLegend} when a checkbox is checked or unchecked
115
+ * @param series
116
+ * @param isChecked
117
+ * @protected
118
+ */
119
+ protected legendItemCheckedChanged(series: IRenderableSeries, isChecked: boolean): void;
89
120
  /**
90
121
  * Test if the series is included or excluded, by default it is included
91
122
  * @param series
@@ -16,6 +16,7 @@ var __extends = (this && this.__extends) || (function () {
16
16
  })();
17
17
  Object.defineProperty(exports, "__esModule", { value: true });
18
18
  exports.LegendModifier = void 0;
19
+ var EventHandler_1 = require("../../Core/EventHandler");
19
20
  var ChartModifierType_1 = require("../../types/ChartModifierType");
20
21
  var SciChartLegend_1 = require("../Visuals/Legend/SciChartLegend");
21
22
  var ChartModifierBase2D_1 = require("./ChartModifierBase2D");
@@ -42,7 +43,12 @@ var LegendModifier = /** @class */ (function (_super) {
42
43
  var _a, _b, _c, _d, _e, _f, _g;
43
44
  var _this = _super.call(this, options) || this;
44
45
  _this.type = ChartModifierType_1.EChart2DModifierType.Legend;
46
+ /**
47
+ * An event handler raised when a {@link SciChartLegend} row checkbox is checked or unchecked
48
+ */
49
+ _this.isCheckedChanged = new EventHandler_1.EventHandler();
45
50
  _this.includedSeriesMap = new Map();
51
+ _this.legendItemCheckedChanged = _this.legendItemCheckedChanged.bind(_this);
46
52
  _this.sciChartLegend = new SciChartLegend_1.SciChartLegend();
47
53
  _this.sciChartLegend.orientation = (_a = options === null || options === void 0 ? void 0 : options.orientation) !== null && _a !== void 0 ? _a : _this.sciChartLegend.orientation;
48
54
  _this.sciChartLegend.showLegend = (_b = options === null || options === void 0 ? void 0 : options.showLegend) !== null && _b !== void 0 ? _b : _this.sciChartLegend.showLegend;
@@ -51,6 +57,12 @@ var LegendModifier = /** @class */ (function (_super) {
51
57
  _this.sciChartLegend.placement = (_e = options === null || options === void 0 ? void 0 : options.placement) !== null && _e !== void 0 ? _e : _this.sciChartLegend.placement;
52
58
  _this.sciChartLegend.margin = (_f = options === null || options === void 0 ? void 0 : options.margin) !== null && _f !== void 0 ? _f : _this.sciChartLegend.margin;
53
59
  _this.sciChartLegend.placementDivId = (_g = options === null || options === void 0 ? void 0 : options.placementDivId) !== null && _g !== void 0 ? _g : _this.sciChartLegend.placementDivId;
60
+ _this.sciChartLegend.legendItemCheckedChangedCallback = _this.legendItemCheckedChanged;
61
+ if (options === null || options === void 0 ? void 0 : options.isCheckedChangedCallback) {
62
+ _this.isCheckedChanged.subscribe(function (arg) {
63
+ return options.isCheckedChangedCallback(arg.series, arg.isChecked);
64
+ });
65
+ }
54
66
  return _this;
55
67
  }
56
68
  /** @inheritDoc */
@@ -141,6 +153,16 @@ var LegendModifier = /** @class */ (function (_super) {
141
153
  _super.prototype.delete.call(this);
142
154
  this.sciChartLegend.delete();
143
155
  };
156
+ /**
157
+ * Callback called from inner {@link SciChartLegend} when a checkbox is checked or unchecked
158
+ * @param series
159
+ * @param isChecked
160
+ * @protected
161
+ */
162
+ LegendModifier.prototype.legendItemCheckedChanged = function (series, isChecked) {
163
+ var _a;
164
+ (_a = this.isCheckedChanged) === null || _a === void 0 ? void 0 : _a.raiseEvent({ series: series, isChecked: isChecked });
165
+ };
144
166
  /**
145
167
  * Test if the series is included or excluded, by default it is included
146
168
  * @param series
@@ -84,6 +84,7 @@ export interface IRolloverModifierOptions extends IChartModifierBaseOptions {
84
84
  showTooltip?: boolean;
85
85
  allowTooltipOverlapping?: boolean;
86
86
  snapToDataPoint?: boolean;
87
+ placementDivId?: string;
87
88
  }
88
89
  /**
89
90
  * The RolloverModifier provides tooltip and cursor behavior on a 2D {@link SciChartSurface}
@@ -125,6 +126,7 @@ export declare class RolloverModifier extends ChartModifierBase2D implements IIn
125
126
  private showTooltipProperty;
126
127
  private allowTooltipOverlappingProperty;
127
128
  private includedSeriesMap;
129
+ private placementDivIdProperty;
128
130
  /**
129
131
  * Creates an instance of the RolloverModifier
130
132
  * @param options Optional parameters {@link IRolloverModifierOptions} used to configure the modifier
@@ -222,6 +224,14 @@ export declare class RolloverModifier extends ChartModifierBase2D implements IIn
222
224
  */
223
225
  private testIsIncludedSeries;
224
226
  private getSeriesInfos;
227
+ /**
228
+ * Gets or sets the parent div element reference or id for the Tooltip
229
+ */
230
+ get placementDivId(): string;
231
+ /**
232
+ * Gets or sets the parent div element reference or id for the Tooltip
233
+ */
234
+ set placementDivId(value: string);
225
235
  }
226
236
  /**
227
237
  * @ignore
@@ -72,7 +72,7 @@ var RolloverModifier = /** @class */ (function (_super) {
72
72
  * @param options Optional parameters {@link IRolloverModifierOptions} used to configure the modifier
73
73
  */
74
74
  function RolloverModifier(options) {
75
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
75
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
76
76
  var _this = _super.call(this, options) || this;
77
77
  _this.type = ChartModifierType_1.EChart2DModifierType.Rollover;
78
78
  /**
@@ -94,11 +94,12 @@ var RolloverModifier = /** @class */ (function (_super) {
94
94
  _this.allowTooltipOverlappingProperty = false;
95
95
  _this.includedSeriesMap = new Map();
96
96
  _this.hitTestRenderableSeries = _this.hitTestRenderableSeries.bind(_this);
97
+ _this.placementDivIdProperty = (_a = options === null || options === void 0 ? void 0 : options.placementDivId) !== null && _a !== void 0 ? _a : _this.placementDivIdProperty;
97
98
  _this.rolloverLineAnnotation = new LineAnnotation_1.LineAnnotation({
98
99
  xCoordinateMode: AnnotationBase_1.ECoordinateMode.Pixel,
99
100
  yCoordinateMode: AnnotationBase_1.ECoordinateMode.Pixel,
100
- strokeThickness: (_a = options === null || options === void 0 ? void 0 : options.rolloverLineStrokeThickness) !== null && _a !== void 0 ? _a : 2,
101
- stroke: (_b = options === null || options === void 0 ? void 0 : options.rolloverLineStroke) !== null && _b !== void 0 ? _b : SciChartSurfaceBase_1.SciChartSurfaceBase.DEFAULT_THEME.cursorLineBrush,
101
+ strokeThickness: (_b = options === null || options === void 0 ? void 0 : options.rolloverLineStrokeThickness) !== null && _b !== void 0 ? _b : 2,
102
+ stroke: (_c = options === null || options === void 0 ? void 0 : options.rolloverLineStroke) !== null && _c !== void 0 ? _c : SciChartSurfaceBase_1.SciChartSurfaceBase.DEFAULT_THEME.cursorLineBrush,
102
103
  isHidden: true,
103
104
  xAxisId: _this.xAxisId,
104
105
  yAxisId: _this.yAxisId
@@ -111,9 +112,9 @@ var RolloverModifier = /** @class */ (function (_super) {
111
112
  }
112
113
  }
113
114
  _this.tooltipLegendTemplate =
114
- (_c = options === null || options === void 0 ? void 0 : options.tooltipLegendTemplate) !== null && _c !== void 0 ? _c : _this.tooltipLegendTemplate;
115
- _this.tooltipLegendOffsetX = (_d = options === null || options === void 0 ? void 0 : options.tooltipLegendOffsetX) !== null && _d !== void 0 ? _d : _this.tooltipLegendOffsetX;
116
- _this.tooltipLegendOffsetY = (_e = options === null || options === void 0 ? void 0 : options.tooltipLegendOffsetY) !== null && _e !== void 0 ? _e : _this.tooltipLegendOffsetY;
115
+ (_d = options === null || options === void 0 ? void 0 : options.tooltipLegendTemplate) !== null && _d !== void 0 ? _d : _this.tooltipLegendTemplate;
116
+ _this.tooltipLegendOffsetX = (_e = options === null || options === void 0 ? void 0 : options.tooltipLegendOffsetX) !== null && _e !== void 0 ? _e : _this.tooltipLegendOffsetX;
117
+ _this.tooltipLegendOffsetY = (_f = options === null || options === void 0 ? void 0 : options.tooltipLegendOffsetY) !== null && _f !== void 0 ? _f : _this.tooltipLegendOffsetY;
117
118
  if (options === null || options === void 0 ? void 0 : options.tooltipDataTemplate) {
118
119
  if (typeof options.tooltipDataTemplate === "string") {
119
120
  _this.typeMap.set("tooltipDataTemplate", options.tooltipDataTemplate);
@@ -122,9 +123,9 @@ var RolloverModifier = /** @class */ (function (_super) {
122
123
  }
123
124
  }
124
125
  _this.tooltipDataTemplateProperty =
125
- (_f = options === null || options === void 0 ? void 0 : options.tooltipDataTemplate) !== null && _f !== void 0 ? _f : _this.tooltipDataTemplateProperty;
126
- _this.showRolloverLineProperty = (_g = options === null || options === void 0 ? void 0 : options.showRolloverLine) !== null && _g !== void 0 ? _g : _this.showRolloverLineProperty;
127
- _this.showTooltipProperty = (_h = options === null || options === void 0 ? void 0 : options.showTooltip) !== null && _h !== void 0 ? _h : _this.showTooltipProperty;
126
+ (_g = options === null || options === void 0 ? void 0 : options.tooltipDataTemplate) !== null && _g !== void 0 ? _g : _this.tooltipDataTemplateProperty;
127
+ _this.showRolloverLineProperty = (_h = options === null || options === void 0 ? void 0 : options.showRolloverLine) !== null && _h !== void 0 ? _h : _this.showRolloverLineProperty;
128
+ _this.showTooltipProperty = (_j = options === null || options === void 0 ? void 0 : options.showTooltip) !== null && _j !== void 0 ? _j : _this.showTooltipProperty;
128
129
  _this.legendAnnotation = new RolloverLegendSvgAnnotation_1.RolloverLegendSvgAnnotation({
129
130
  tooltipLegendTemplate: _this.tooltipLegendTemplate,
130
131
  tooltipLegendOffsetX: _this.tooltipLegendOffsetX,
@@ -132,8 +133,8 @@ var RolloverModifier = /** @class */ (function (_super) {
132
133
  xAxisId: _this.xAxisId,
133
134
  yAxisId: _this.yAxisId
134
135
  });
135
- _this.allowTooltipOverlappingProperty = (_j = options === null || options === void 0 ? void 0 : options.allowTooltipOverlapping) !== null && _j !== void 0 ? _j : _this.allowTooltipOverlappingProperty;
136
- _this.snapToDataPoint = (_k = options === null || options === void 0 ? void 0 : options.snapToDataPoint) !== null && _k !== void 0 ? _k : _this.snapToDataPoint;
136
+ _this.allowTooltipOverlappingProperty = (_k = options === null || options === void 0 ? void 0 : options.allowTooltipOverlapping) !== null && _k !== void 0 ? _k : _this.allowTooltipOverlappingProperty;
137
+ _this.snapToDataPoint = (_l = options === null || options === void 0 ? void 0 : options.snapToDataPoint) !== null && _l !== void 0 ? _l : _this.snapToDataPoint;
137
138
  return _this;
138
139
  }
139
140
  /**
@@ -416,10 +417,13 @@ var RolloverModifier = /** @class */ (function (_super) {
416
417
  * @param rs
417
418
  */
418
419
  RolloverModifier.prototype.addSeriesAnnotationsToParentSurface = function (rs) {
419
- if (!this.parentSurface)
420
+ if (!this.parentSurface ||
421
+ rs.type === SeriesType_1.ESeriesType.StackedMountainCollection ||
422
+ rs.type === SeriesType_1.ESeriesType.StackedColumnCollection) {
420
423
  return;
424
+ }
421
425
  rs.rolloverModifierProps.rolloverModifier = this;
422
- createAnnotations(rs);
426
+ createAnnotations(rs, this.placementDivIdProperty);
423
427
  this.parentSurface.modifierAnnotations.add(rs.rolloverModifierProps.marker);
424
428
  this.parentSurface.modifierAnnotations.add(rs.rolloverModifierProps.tooltip);
425
429
  if (rs.type === SeriesType_1.ESeriesType.BandSeries) {
@@ -494,11 +498,16 @@ var RolloverModifier = /** @class */ (function (_super) {
494
498
  var _this = this;
495
499
  var rsList = this.getIncludedRenderableSeries();
496
500
  rsList.forEach(function (rs) {
501
+ rs.rolloverModifierProps.marker.suspendInvalidate();
502
+ rs.rolloverModifierProps.tooltip.suspendInvalidate();
497
503
  rs.rolloverModifierProps.marker.isHidden = true;
498
504
  rs.rolloverModifierProps.tooltip.isHidden = true;
499
505
  rs.rolloverModifierProps.tooltip.x1 = undefined;
500
506
  rs.rolloverModifierProps.tooltip.y1 = undefined;
507
+ // TODO should be more general than looking at series type
501
508
  if (rs.type === SeriesType_1.ESeriesType.BandSeries) {
509
+ rs.rolloverModifierProps1.marker.suspendInvalidate();
510
+ rs.rolloverModifierProps1.tooltip.suspendInvalidate();
502
511
  rs.rolloverModifierProps1.marker.isHidden = true;
503
512
  rs.rolloverModifierProps1.tooltip.isHidden = true;
504
513
  rs.rolloverModifierProps1.tooltip.x1 = undefined;
@@ -506,6 +515,14 @@ var RolloverModifier = /** @class */ (function (_super) {
506
515
  }
507
516
  });
508
517
  if (this.mousePosition !== EMousePosition.SeriesArea) {
518
+ rsList.forEach(function (rs) {
519
+ rs.rolloverModifierProps.marker.resumeInvalidate();
520
+ rs.rolloverModifierProps.tooltip.resumeInvalidate();
521
+ if (rs.type === SeriesType_1.ESeriesType.BandSeries) {
522
+ rs.rolloverModifierProps1.marker.resumeInvalidate();
523
+ rs.rolloverModifierProps1.tooltip.resumeInvalidate();
524
+ }
525
+ });
509
526
  return;
510
527
  }
511
528
  var tooltipArray = [];
@@ -545,10 +562,18 @@ var RolloverModifier = /** @class */ (function (_super) {
545
562
  var showTooltip = _this.showTooltip && el.seriesInfo.isHit;
546
563
  var showMarker = el.seriesInfo.isHit;
547
564
  if (el.isY1) {
548
- updateRolloverModifierProps(rs.rolloverModifierProps1, rs, el, showTooltip, showMarker);
565
+ updateRolloverModifierProps(rs.rolloverModifierProps1, rs, el, showTooltip, showMarker, _this.placementDivId);
549
566
  }
550
567
  else {
551
- updateRolloverModifierProps(rs.rolloverModifierProps, rs, el, showTooltip, showMarker);
568
+ updateRolloverModifierProps(rs.rolloverModifierProps, rs, el, showTooltip, showMarker, _this.placementDivId);
569
+ }
570
+ });
571
+ rsList.forEach(function (rs) {
572
+ rs.rolloverModifierProps.marker.resumeInvalidate();
573
+ rs.rolloverModifierProps.tooltip.resumeInvalidate();
574
+ if (rs.type === SeriesType_1.ESeriesType.BandSeries) {
575
+ rs.rolloverModifierProps1.marker.resumeInvalidate();
576
+ rs.rolloverModifierProps1.tooltip.resumeInvalidate();
552
577
  }
553
578
  });
554
579
  };
@@ -572,6 +597,30 @@ var RolloverModifier = /** @class */ (function (_super) {
572
597
  })
573
598
  .filter(function (rs) { return rs !== undefined; });
574
599
  };
600
+ Object.defineProperty(RolloverModifier.prototype, "placementDivId", {
601
+ /**
602
+ * Gets or sets the parent div element reference or id for the Tooltip
603
+ */
604
+ get: function () {
605
+ return this.placementDivIdProperty;
606
+ },
607
+ /**
608
+ * Gets or sets the parent div element reference or id for the Tooltip
609
+ */
610
+ set: function (value) {
611
+ var _this = this;
612
+ var _a;
613
+ if (this.placementDivIdProperty !== value) {
614
+ this.placementDivIdProperty = value;
615
+ (_a = this.parentSurface) === null || _a === void 0 ? void 0 : _a.renderableSeries.asArray().forEach(function (rs) {
616
+ rs.rolloverModifierProps.tooltip.placementDivId = _this.placementDivIdProperty;
617
+ rs.rolloverModifierProps1.tooltip.placementDivId = _this.placementDivIdProperty;
618
+ });
619
+ }
620
+ },
621
+ enumerable: false,
622
+ configurable: true
623
+ });
575
624
  return RolloverModifier;
576
625
  }(ChartModifierBase2D_1.ChartModifierBase2D));
577
626
  exports.RolloverModifier = RolloverModifier;
@@ -674,7 +723,7 @@ exports.calcTooltipPositions = calcTooltipPositions;
674
723
  * @description Creates MarkerAnnotation and TooltipAnnotation and assigns to rolloverSeries properties
675
724
  * @param rs RenderableSeries
676
725
  */
677
- var createAnnotations = function (rs) {
726
+ var createAnnotations = function (rs, placementDivId) {
678
727
  var _a, _b, _c, _d, _e, _f;
679
728
  if (!rs.rolloverModifierProps.marker) {
680
729
  rs.rolloverModifierProps.marker = new RolloverMarkerSvgAnnotation_1.RolloverMarkerSvgAnnotation(rs.rolloverModifierProps);
@@ -688,7 +737,8 @@ var createAnnotations = function (rs) {
688
737
  rs.rolloverModifierProps.tooltipTitle = (_b = (_a = rs.rolloverModifierProps.tooltipTitle) !== null && _a !== void 0 ? _a : rs.getDataSeriesName()) !== null && _b !== void 0 ? _b : "";
689
738
  rs.rolloverModifierProps.tooltipColor = (_c = rs.rolloverModifierProps.tooltipColor) !== null && _c !== void 0 ? _c : rs.stroke;
690
739
  rs.rolloverModifierProps.tooltip = new RolloverTooltipSvgAnnotation_1.RolloverTooltipSvgAnnotation(rs.rolloverModifierProps, {
691
- seriesType: rs.type
740
+ seriesType: rs.type,
741
+ placementDivId: placementDivId
692
742
  });
693
743
  // Rollover tooltips for multiple Y-Axes are not supported for stacked series
694
744
  if (!rs.isStacked) {
@@ -707,14 +757,16 @@ var createAnnotations = function (rs) {
707
757
  bandRs.rolloverModifierProps1.tooltipTitle =
708
758
  (_e = (_d = bandRs.rolloverModifierProps1.tooltipTitle) !== null && _d !== void 0 ? _d : bandRs.getDataSeriesName()) !== null && _e !== void 0 ? _e : "";
709
759
  bandRs.rolloverModifierProps1.tooltipColor = (_f = bandRs.rolloverModifierProps1.tooltipColor) !== null && _f !== void 0 ? _f : bandRs.strokeY1;
710
- bandRs.rolloverModifierProps1.tooltip = new RolloverTooltipSvgAnnotation_1.RolloverTooltipSvgAnnotation(bandRs.rolloverModifierProps1);
760
+ bandRs.rolloverModifierProps1.tooltip = new RolloverTooltipSvgAnnotation_1.RolloverTooltipSvgAnnotation(bandRs.rolloverModifierProps1, {
761
+ placementDivId: placementDivId
762
+ });
711
763
  bandRs.rolloverModifierProps1.tooltip.xAxisId = bandRs.xAxisId;
712
764
  bandRs.rolloverModifierProps1.tooltip.yAxisId = bandRs.yAxisId;
713
765
  }
714
766
  }
715
767
  };
716
768
  /** @ignore */
717
- var updateRolloverModifierProps = function (rolloverRSProps, rs, tooltipProps, showTooltip, showMarker) {
769
+ var updateRolloverModifierProps = function (rolloverRSProps, rs, tooltipProps, showTooltip, showMarker, placementDivId) {
718
770
  rolloverRSProps.tooltip.seriesInfo = tooltipProps.seriesInfo;
719
771
  if (tooltipProps.isY1) {
720
772
  rolloverRSProps.tooltip.seriesInfo.isFirstSeries = false;
@@ -732,4 +784,9 @@ var updateRolloverModifierProps = function (rolloverRSProps, rs, tooltipProps, s
732
784
  rolloverRSProps.tooltip.xCoordShift = tooltipProps.xCoordShift;
733
785
  rolloverRSProps.tooltip.yCoordShift = tooltipProps.yCoordShift;
734
786
  }
787
+ else {
788
+ if (placementDivId) {
789
+ rolloverRSProps.tooltip.delete();
790
+ }
791
+ }
735
792
  };
@@ -100,7 +100,12 @@ var LayoutManager = /** @class */ (function () {
100
100
  var bottomStart = topEnd + (remainingHeight < MIN_SERIES_AREA_SIZE ? MIN_SERIES_AREA_SIZE : remainingHeight);
101
101
  var bottomEnd = bottomStart + this.chartLayoutState.bottomOuterAreaSize;
102
102
  // layout center parts
103
- this.layoutChartCenter(leftEnd, topEnd, rightStart, bottomStart);
103
+ if (this.sciChartSurface.drawSeriesBehindAxis) {
104
+ this.layoutChartCenter(leftStart, topStart, rightEnd, bottomEnd);
105
+ }
106
+ else {
107
+ this.layoutChartCenter(leftEnd, topEnd, rightStart, bottomStart);
108
+ }
104
109
  // layout outer axes
105
110
  this.leftOuterAxesLayoutStrategy.layoutAxes(leftStart, topEnd, leftEnd - this.sciChartSurface.leftViewportBorder, bottomStart, this.axesGroupedByLayoutStrategy.leftOuterAxes);
106
111
  this.rightOuterAxesLayoutStrategy.layoutAxes(rightStart + this.sciChartSurface.rightViewportBorder, topEnd, rightEnd, bottomStart, this.axesGroupedByLayoutStrategy.rightOuterAxes);
@@ -91,6 +91,7 @@ export declare abstract class BaseHeatmapDataSeries implements IHeatmapSeries {
91
91
  private hasNaNsProperty;
92
92
  private lastZMin;
93
93
  private lastZMax;
94
+ private lastFillValuesOutOfRange;
94
95
  private metadataGeneratorProperty;
95
96
  private changeCountProperty;
96
97
  /**
@@ -49,6 +49,7 @@ var BaseHeatmapDataSeries = /** @class */ (function () {
49
49
  this.hasNaNsProperty = false;
50
50
  this.lastZMin = -1;
51
51
  this.lastZMax = -1;
52
+ this.lastFillValuesOutOfRange = undefined;
52
53
  this.metadataGeneratorProperty = undefined;
53
54
  this.changeCountProperty = 0;
54
55
  this.webAssemblyContext = webAssemblyContext;
@@ -409,10 +410,12 @@ var BaseHeatmapDataSeries = /** @class */ (function () {
409
410
  if (this.hasDataChangesProperty ||
410
411
  size !== this.normalizedVector.size() ||
411
412
  colorMap.minimum !== this.lastZMin ||
412
- colorMap.maximum !== this.lastZMax) {
413
+ colorMap.maximum !== this.lastZMax ||
414
+ fillValuesOutOfRange !== this.lastFillValuesOutOfRange) {
413
415
  this.recreateNormalizedVector(colorMap.minimum, colorMap.maximum, fillValuesOutOfRange);
414
416
  this.lastZMin = colorMap.minimum;
415
417
  this.lastZMax = colorMap.maximum;
418
+ this.lastFillValuesOutOfRange = fillValuesOutOfRange;
416
419
  this.hasDataChangesProperty = false;
417
420
  }
418
421
  return this.normalizedVector;
@@ -9,6 +9,6 @@ export declare class BasePointSeriesWrapped implements IPointSeries {
9
9
  readonly yValues: SCRTDoubleVector;
10
10
  protected dataSeries: IDataSeries;
11
11
  protected indexesProperty: SCRTDoubleVector;
12
- constructor(dataSeries: IDataSeries);
12
+ constructor(dataSeries: IDataSeries, yValues?: SCRTDoubleVector);
13
13
  get indexes(): SCRTDoubleVector;
14
14
  }
@@ -2,11 +2,11 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.BasePointSeriesWrapped = void 0;
4
4
  var BasePointSeriesWrapped = /** @class */ (function () {
5
- function BasePointSeriesWrapped(dataSeries) {
5
+ function BasePointSeriesWrapped(dataSeries, yValues) {
6
6
  this.dataSeries = dataSeries;
7
7
  this.count = dataSeries.count();
8
8
  this.xValues = this.dataSeries.getNativeXValues();
9
- this.yValues = this.dataSeries.getNativeYValues();
9
+ this.yValues = yValues !== null && yValues !== void 0 ? yValues : this.dataSeries.getNativeYValues();
10
10
  }
11
11
  Object.defineProperty(BasePointSeriesWrapped.prototype, "indexes", {
12
12
  get: function () {
@@ -4,5 +4,5 @@ import { BasePointSeriesWrapped } from "./BasePointSeriesWrapped";
4
4
  import { IXyyPointSeries } from "./IPointSeries";
5
5
  export declare class XyyPointSeriesWrapped extends BasePointSeriesWrapped implements IXyyPointSeries {
6
6
  readonly y1Values: SCRTDoubleVector;
7
- constructor(dataSeries: XyyDataSeries);
7
+ constructor(dataSeries: XyyDataSeries, yValues?: SCRTDoubleVector, y1Values?: SCRTDoubleVector);
8
8
  }
@@ -19,9 +19,9 @@ exports.XyyPointSeriesWrapped = void 0;
19
19
  var BasePointSeriesWrapped_1 = require("./BasePointSeriesWrapped");
20
20
  var XyyPointSeriesWrapped = /** @class */ (function (_super) {
21
21
  __extends(XyyPointSeriesWrapped, _super);
22
- function XyyPointSeriesWrapped(dataSeries) {
23
- var _this = _super.call(this, dataSeries) || this;
24
- _this.y1Values = dataSeries.getNativeY1Values();
22
+ function XyyPointSeriesWrapped(dataSeries, yValues, y1Values) {
23
+ var _this = _super.call(this, dataSeries, yValues) || this;
24
+ _this.y1Values = y1Values !== null && y1Values !== void 0 ? y1Values : dataSeries.getNativeY1Values();
25
25
  return _this;
26
26
  }
27
27
  return XyyPointSeriesWrapped;
@@ -224,10 +224,10 @@ export declare abstract class AnnotationBase implements IAnnotation, IAdornerPro
224
224
  y: number;
225
225
  };
226
226
  protected typeMap: Map<string, string>;
227
+ protected isHiddenProperty: boolean;
227
228
  private opacityProperty;
228
229
  private annotationLayerProperty;
229
230
  private isEditableProperty;
230
- protected isHiddenProperty: boolean;
231
231
  private parentSurfaceProperty;
232
232
  private x1Property;
233
233
  private x2Property;
@@ -240,6 +240,7 @@ export declare abstract class AnnotationBase implements IAnnotation, IAdornerPro
240
240
  private isSelectedProperty;
241
241
  private resizeDirectionsProperty;
242
242
  private svgAdornerRootProperty;
243
+ private invalidateState;
243
244
  /** @inheritDoc */
244
245
  get annotationLayer(): EAnnotationLayer;
245
246
  /** @inheritDoc */
@@ -325,6 +326,10 @@ export declare abstract class AnnotationBase implements IAnnotation, IAdornerPro
325
326
  * @inheritDoc
326
327
  */
327
328
  onDpiChanged(args: TDpiChangedEventArgs): void;
329
+ /** Internal use. Captures the state of isHidden,x1,y1 and prevents invalidateParent being called on change to these properties */
330
+ suspendInvalidate(): void;
331
+ /** Internal use. If isHidden,x1,y1 have change since suspendInvalidate was called, call invalidateParent */
332
+ resumeInvalidate(): void;
328
333
  toJSON(): {
329
334
  type: EAnnotationType;
330
335
  options: Required<Omit<IAnnotationBaseOptions, never>>;
@@ -70,9 +70,9 @@ var AnnotationBase = /** @class */ (function () {
70
70
  y2: 0
71
71
  };
72
72
  this.typeMap = new Map();
73
+ this.isHiddenProperty = false;
73
74
  this.annotationLayerProperty = IAnnotation_1.EAnnotationLayer.AboveChart;
74
75
  this.isEditableProperty = false;
75
- this.isHiddenProperty = false;
76
76
  this.xAxisIdProperty = AxisCore_1.AxisCore.DEFAULT_AXIS_ID;
77
77
  this.yAxisIdProperty = AxisCore_1.AxisCore.DEFAULT_AXIS_ID;
78
78
  this.xCoordinateModeProperty = ECoordinateMode.DataValue;
@@ -425,6 +425,27 @@ var AnnotationBase = /** @class */ (function () {
425
425
  * @inheritDoc
426
426
  */
427
427
  AnnotationBase.prototype.onDpiChanged = function (args) { };
428
+ /** Internal use. Captures the state of isHidden,x1,y1 and prevents invalidateParent being called on change to these properties */
429
+ AnnotationBase.prototype.suspendInvalidate = function () {
430
+ this.invalidateState = {
431
+ isHidden: this.isHidden,
432
+ x1: this.x1,
433
+ y1: this.y1
434
+ };
435
+ };
436
+ /** Internal use. If isHidden,x1,y1 have change since suspendInvalidate was called, call invalidateParent */
437
+ AnnotationBase.prototype.resumeInvalidate = function () {
438
+ if (!this.invalidateState)
439
+ return;
440
+ if (this.isHidden !== this.invalidateState.isHidden ||
441
+ this.x1 !== this.invalidateState.x1 ||
442
+ this.y1 !== this.invalidateState.y1) {
443
+ if (this.invalidateParentCallback) {
444
+ this.invalidateParentCallback();
445
+ }
446
+ }
447
+ this.invalidateState = undefined;
448
+ };
428
449
  AnnotationBase.prototype.toJSON = function () {
429
450
  var options = {
430
451
  id: this.id,
@@ -497,7 +518,7 @@ var AnnotationBase = /** @class */ (function () {
497
518
  * @param propertyName The name of the property which has changed
498
519
  */
499
520
  AnnotationBase.prototype.notifyPropertyChanged = function (propertyName) {
500
- if (this.invalidateParentCallback) {
521
+ if (this.invalidateParentCallback && !this.invalidateState) {
501
522
  this.invalidateParentCallback();
502
523
  }
503
524
  };