scichart 3.1.348 → 3.2.0-beta

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 (314) hide show
  1. package/Charting/ChartModifiers/ChartModifierBase.d.ts +15 -1
  2. package/Charting/ChartModifiers/ChartModifierBase.js +65 -7
  3. package/Charting/ChartModifiers/CursorModifier.js +13 -1
  4. package/Charting/ChartModifiers/LegendModifier.d.ts +1 -1
  5. package/Charting/ChartModifiers/LegendModifier.js +8 -6
  6. package/Charting/ChartModifiers/PinchZoomModifier.d.ts +38 -8
  7. package/Charting/ChartModifiers/PinchZoomModifier.js +103 -40
  8. package/Charting/ChartModifiers/RolloverModifier.js +10 -3
  9. package/Charting/ChartModifiers/RubberBandXyZoomModifier.d.ts +1 -1
  10. package/Charting/ChartModifiers/SeriesSelectionModifier.js +32 -24
  11. package/Charting/ChartModifiers/ZoomPanModifier.d.ts +13 -38
  12. package/Charting/ChartModifiers/ZoomPanModifier.js +54 -99
  13. package/Charting/Drawing/BaseCache.d.ts +2 -1
  14. package/Charting/Drawing/BaseCache.js +40 -7
  15. package/Charting/Drawing/RenderSurface.d.ts +1 -0
  16. package/Charting/Drawing/RenderSurface.js +5 -1
  17. package/Charting/Drawing/SolidBrushCache.d.ts +2 -1
  18. package/Charting/Drawing/SolidBrushCache.js +23 -3
  19. package/Charting/Drawing/WebGlBrush.d.ts +2 -1
  20. package/Charting/Drawing/WebGlBrush.js +22 -3
  21. package/Charting/Drawing/WebGlPen.d.ts +2 -1
  22. package/Charting/Drawing/WebGlPen.js +23 -4
  23. package/Charting/Drawing/WebGlRenderContext2D.d.ts +4 -3
  24. package/Charting/Drawing/WebGlRenderContext2D.js +26 -7
  25. package/Charting/Model/BaseDataSeries.d.ts +67 -2
  26. package/Charting/Model/BaseDataSeries.js +193 -42
  27. package/Charting/Model/BaseHeatmapDataSeries.js +1 -1
  28. package/Charting/Model/ChartData/SeriesInfo.d.ts +16 -0
  29. package/Charting/Model/ChartData/SeriesInfo.js +7 -0
  30. package/Charting/Model/ChartData/XyzSeriesInfo.d.ts +8 -0
  31. package/Charting/Model/ChartData/XyzSeriesInfo.js +36 -0
  32. package/Charting/Model/DoubleVectorProvider.d.ts +19 -0
  33. package/Charting/Model/DoubleVectorProvider.js +95 -0
  34. package/Charting/Model/HlcDataSeries.d.ts +3 -0
  35. package/Charting/Model/HlcDataSeries.js +44 -15
  36. package/Charting/Model/IDataSeries.d.ts +23 -0
  37. package/Charting/Model/NonUniformHeatmapDataSeries.js +2 -0
  38. package/Charting/Model/OhlcDataSeries.d.ts +3 -0
  39. package/Charting/Model/OhlcDataSeries.js +56 -24
  40. package/Charting/Model/PointSeries/BasePointSeriesResampled.d.ts +4 -5
  41. package/Charting/Model/PointSeries/BasePointSeriesResampled.js +29 -21
  42. package/Charting/Model/PointSeries/BasePointSeriesWrapped.d.ts +2 -0
  43. package/Charting/Model/PointSeries/BasePointSeriesWrapped.js +2 -0
  44. package/Charting/Model/PointSeries/IPointSeries.d.ts +2 -1
  45. package/Charting/Model/PointSeries/OhlcPointSeriesResampled.js +1 -1
  46. package/Charting/Model/PointSeries/XyPointSeriesWrapped.d.ts +2 -1
  47. package/Charting/Model/PointSeries/XyPointSeriesWrapped.js +2 -2
  48. package/Charting/Model/PointSeries/XyyPointSeriesResampled.js +1 -1
  49. package/Charting/Model/UniformHeatmapDataSeries.d.ts +31 -11
  50. package/Charting/Model/UniformHeatmapDataSeries.js +72 -4
  51. package/Charting/Model/XyDataSeries.d.ts +0 -8
  52. package/Charting/Model/XyDataSeries.js +21 -5
  53. package/Charting/Model/XyTextDataSeries.d.ts +2 -0
  54. package/Charting/Model/XyTextDataSeries.js +35 -4
  55. package/Charting/Model/XyyDataSeries.d.ts +2 -0
  56. package/Charting/Model/XyyDataSeries.js +35 -10
  57. package/Charting/Model/XyzDataSeries.d.ts +3 -0
  58. package/Charting/Model/XyzDataSeries.js +36 -10
  59. package/Charting/Numerics/CoordinateCalculators/CategoryCoordinateCalculator.d.ts +3 -5
  60. package/Charting/Numerics/CoordinateCalculators/CategoryCoordinateCalculator.js +5 -7
  61. package/Charting/Numerics/CoordinateCalculators/CoordinateCalculatorBase.d.ts +2 -1
  62. package/Charting/Numerics/CoordinateCalculators/CoordinateCalculatorBase.js +29 -9
  63. package/Charting/Numerics/CoordinateCalculators/FlippedCategoryCoordinateCalculator.d.ts +3 -5
  64. package/Charting/Numerics/CoordinateCalculators/FlippedCategoryCoordinateCalculator.js +5 -7
  65. package/Charting/Numerics/Resamplers/ExtremeResamplerHelper.d.ts +14 -10
  66. package/Charting/Numerics/Resamplers/ExtremeResamplerHelper.js +105 -69
  67. package/Charting/Numerics/Resamplers/ResamplingParams.d.ts +4 -2
  68. package/Charting/Numerics/Resamplers/ResamplingParams.js +12 -7
  69. package/Charting/Numerics/TickCoordinateProviders/TickCoordinatesProvider.d.ts +5 -0
  70. package/Charting/Numerics/TickCoordinateProviders/TickCoordinatesProvider.js +7 -0
  71. package/Charting/Numerics/TickProviders/NumericTickProvider.js +3 -4
  72. package/Charting/Numerics/TickProviders/TickProvider.d.ts +5 -0
  73. package/Charting/Numerics/TickProviders/TickProvider.js +7 -0
  74. package/Charting/Services/SciChartRenderer.js +15 -5
  75. package/Charting/Services/TitleRenderer.d.ts +2 -1
  76. package/Charting/Services/TitleRenderer.js +35 -14
  77. package/Charting/Visuals/Annotations/AdornerLayer.d.ts +1 -1
  78. package/Charting/Visuals/Annotations/AnnotationBase.d.ts +6 -6
  79. package/Charting/Visuals/Annotations/AnnotationBase.js +81 -61
  80. package/Charting/Visuals/Annotations/CursorTooltipSvgAnnotation.js +8 -0
  81. package/Charting/Visuals/Annotations/IAnnotation.d.ts +9 -4
  82. package/Charting/Visuals/Annotations/IAnnotation.js +6 -0
  83. package/Charting/Visuals/Annotations/LineAnnotation.js +3 -1
  84. package/Charting/Visuals/Annotations/RenderContextAnnotationBase.d.ts +5 -0
  85. package/Charting/Visuals/Annotations/RenderContextAnnotationBase.js +16 -0
  86. package/Charting/Visuals/Annotations/RolloverTooltipSvgAnnotation.js +6 -0
  87. package/Charting/Visuals/Annotations/constants.d.ts +1 -0
  88. package/Charting/Visuals/Annotations/constants.js +1 -0
  89. package/Charting/Visuals/Axis/AxisBase2D.d.ts +20 -5
  90. package/Charting/Visuals/Axis/AxisBase2D.js +46 -10
  91. package/Charting/Visuals/Axis/AxisCore.d.ts +4 -1
  92. package/Charting/Visuals/Axis/AxisCore.js +100 -54
  93. package/Charting/Visuals/Axis/AxisRenderer.d.ts +2 -1
  94. package/Charting/Visuals/Axis/AxisRenderer.js +40 -16
  95. package/Charting/Visuals/Axis/AxisTitleRenderer.d.ts +1 -0
  96. package/Charting/Visuals/Axis/AxisTitleRenderer.js +4 -0
  97. package/Charting/Visuals/Axis/CategoryAxisBase.js +4 -4
  98. package/Charting/Visuals/Axis/DeltaCalculator/DateTimeDeltaCalculator.js +14 -9
  99. package/Charting/Visuals/Axis/DeltaCalculator/DeltaCalculator.d.ts +5 -0
  100. package/Charting/Visuals/Axis/DeltaCalculator/DeltaCalculator.js +7 -0
  101. package/Charting/Visuals/Axis/LabelProvider/LabelCache.d.ts +2 -2
  102. package/Charting/Visuals/Axis/LabelProvider/LabelCache.js +8 -1
  103. package/Charting/Visuals/Axis/LabelProvider/LabelProvider.d.ts +7 -1
  104. package/Charting/Visuals/Axis/LabelProvider/LabelProvider.js +34 -8
  105. package/Charting/Visuals/Axis/LabelProvider/LabelProviderBase2D.d.ts +4 -2
  106. package/Charting/Visuals/Axis/LabelProvider/LabelProviderBase2D.js +8 -2
  107. package/Charting/Visuals/Axis/LabelProvider/PieLabelProvider.d.ts +1 -0
  108. package/Charting/Visuals/Axis/LabelProvider/PieLabelProvider.js +1 -0
  109. package/Charting/Visuals/HeatmapLegend.d.ts +3 -2
  110. package/Charting/Visuals/HeatmapLegend.js +33 -12
  111. package/Charting/Visuals/Helpers/NativeObject.d.ts +8 -5
  112. package/Charting/Visuals/Helpers/NativeObject.js +42 -21
  113. package/Charting/Visuals/Helpers/drawLabel.js +3 -1
  114. package/Charting/Visuals/I2DSurfaceOptions.d.ts +0 -15
  115. package/Charting/Visuals/Legend/SciChartLegendBase.d.ts +3 -1
  116. package/Charting/Visuals/Legend/SciChartLegendBase.js +35 -14
  117. package/Charting/Visuals/Legend/SciChartPieLegend.js +1 -1
  118. package/Charting/Visuals/PointMarkers/BasePointMarker.d.ts +13 -1
  119. package/Charting/Visuals/PointMarkers/BasePointMarker.js +72 -19
  120. package/Charting/Visuals/PointMarkers/Constants.d.ts +2 -1
  121. package/Charting/Visuals/PointMarkers/Constants.js +1 -0
  122. package/Charting/Visuals/PointMarkers/IPointMarker.d.ts +2 -0
  123. package/Charting/Visuals/RenderableSeries/Animations/SeriesAnimation.js +4 -1
  124. package/Charting/Visuals/RenderableSeries/Animations/animationHelpers.d.ts +1 -1
  125. package/Charting/Visuals/RenderableSeries/BaseBandRenderableSeries.js +8 -7
  126. package/Charting/Visuals/RenderableSeries/BaseHeatmapRenderableSeries.d.ts +1 -0
  127. package/Charting/Visuals/RenderableSeries/BaseHeatmapRenderableSeries.js +5 -0
  128. package/Charting/Visuals/RenderableSeries/BaseOhlcRenderableSeries.js +10 -9
  129. package/Charting/Visuals/RenderableSeries/BaseRenderableSeries.d.ts +2 -1
  130. package/Charting/Visuals/RenderableSeries/BaseRenderableSeries.js +101 -69
  131. package/Charting/Visuals/RenderableSeries/BaseStackedCollection.js +13 -4
  132. package/Charting/Visuals/RenderableSeries/BaseStackedRenderableSeries.js +12 -3
  133. package/Charting/Visuals/RenderableSeries/DataLabels/BaseDataLabelProvider.d.ts +2 -0
  134. package/Charting/Visuals/RenderableSeries/DataLabels/BaseDataLabelProvider.js +5 -0
  135. package/Charting/Visuals/RenderableSeries/DataLabels/DataLabelProvider.js +6 -0
  136. package/Charting/Visuals/RenderableSeries/DataLabels/DataLabelState.d.ts +1 -0
  137. package/Charting/Visuals/RenderableSeries/DataLabels/DataLabelState.js +18 -5
  138. package/Charting/Visuals/RenderableSeries/DataLabels/NonUniformHeatmapDataLabelProvider.js +0 -1
  139. package/Charting/Visuals/RenderableSeries/DataLabels/TextDataLabelProvider.js +8 -2
  140. package/Charting/Visuals/RenderableSeries/DrawingProviders/BandSeriesDrawingProvider.d.ts +1 -0
  141. package/Charting/Visuals/RenderableSeries/DrawingProviders/BandSeriesDrawingProvider.js +35 -16
  142. package/Charting/Visuals/RenderableSeries/DrawingProviders/BaseSeriesDrawingProvider.d.ts +2 -1
  143. package/Charting/Visuals/RenderableSeries/DrawingProviders/BaseSeriesDrawingProvider.js +62 -33
  144. package/Charting/Visuals/RenderableSeries/DrawingProviders/BubbleSeriesDrawingProvider.d.ts +1 -0
  145. package/Charting/Visuals/RenderableSeries/DrawingProviders/BubbleSeriesDrawingProvider.js +30 -9
  146. package/Charting/Visuals/RenderableSeries/DrawingProviders/ColumnSeriesDrawingProvider.d.ts +1 -0
  147. package/Charting/Visuals/RenderableSeries/DrawingProviders/ColumnSeriesDrawingProvider.js +37 -16
  148. package/Charting/Visuals/RenderableSeries/DrawingProviders/HeatmapHelpers.d.ts +47 -0
  149. package/Charting/Visuals/RenderableSeries/DrawingProviders/HeatmapHelpers.js +258 -0
  150. package/Charting/Visuals/RenderableSeries/DrawingProviders/LineSeriesDrawingProvider.js +26 -2
  151. package/Charting/Visuals/RenderableSeries/DrawingProviders/MountainSeriesDrawingProvider.d.ts +1 -0
  152. package/Charting/Visuals/RenderableSeries/DrawingProviders/MountainSeriesDrawingProvider.js +34 -15
  153. package/Charting/Visuals/RenderableSeries/DrawingProviders/NonUniformHeatmapDrawingProvider.js +5 -230
  154. package/Charting/Visuals/RenderableSeries/DrawingProviders/OhlcSeriesDrawingProvider.d.ts +1 -0
  155. package/Charting/Visuals/RenderableSeries/DrawingProviders/OhlcSeriesDrawingProvider.js +62 -37
  156. package/Charting/Visuals/RenderableSeries/DrawingProviders/PointMarkerDrawingProvider.js +30 -3
  157. package/Charting/Visuals/RenderableSeries/DrawingProviders/UniformHeatmapDrawingProvider.d.ts +1 -0
  158. package/Charting/Visuals/RenderableSeries/DrawingProviders/UniformHeatmapDrawingProvider.js +4 -1
  159. package/Charting/Visuals/RenderableSeries/FastBubbleRenderableSeries.d.ts +0 -2
  160. package/Charting/Visuals/RenderableSeries/FastBubbleRenderableSeries.js +0 -4
  161. package/Charting/Visuals/RenderableSeries/FastTextRenderableSeries.d.ts +3 -0
  162. package/Charting/Visuals/RenderableSeries/FastTextRenderableSeries.js +10 -0
  163. package/Charting/Visuals/RenderableSeries/HitTest/BubbleSeriesHitTestProvider.d.ts +4 -0
  164. package/Charting/Visuals/RenderableSeries/HitTest/BubbleSeriesHitTestProvider.js +7 -0
  165. package/Charting/Visuals/RenderableSeries/HitTest/HitTestInfo.d.ts +4 -0
  166. package/Charting/Visuals/RenderableSeries/HitTest/HitTestInfo.js +9 -0
  167. package/Charting/Visuals/RenderableSeries/ShaderEffect.d.ts +3 -2
  168. package/Charting/Visuals/RenderableSeries/ShaderEffect.js +29 -9
  169. package/Charting/Visuals/RenderableSeries/SplineBandRenderableSeries.js +7 -0
  170. package/Charting/Visuals/RenderableSeries/SplineLineRenderableSeries.js +7 -0
  171. package/Charting/Visuals/RenderableSeries/SplineMountainRenderableSeries.js +7 -0
  172. package/Charting/Visuals/RenderableSeries/StackedColumnCollection.js +3 -0
  173. package/Charting/Visuals/RenderableSeries/StackedMountainCollection.d.ts +0 -2
  174. package/Charting/Visuals/RenderableSeries/StackedMountainCollection.js +4 -4
  175. package/Charting/Visuals/RenderableSeries/StackedMountainRenderableSeries.d.ts +1 -0
  176. package/Charting/Visuals/RenderableSeries/StackedMountainRenderableSeries.js +8 -0
  177. package/Charting/Visuals/RenderableSeries/XyScatterRenderableSeries.d.ts +1 -2
  178. package/Charting/Visuals/RenderableSeries/XyScatterRenderableSeries.js +8 -3
  179. package/Charting/Visuals/RubberBandSvgRect/RubberBandSvgRect.d.ts +3 -1
  180. package/Charting/Visuals/RubberBandSvgRect/RubberBandSvgRect.js +30 -10
  181. package/Charting/Visuals/SciChartDefaults.d.ts +10 -0
  182. package/Charting/Visuals/SciChartDefaults.js +10 -0
  183. package/Charting/Visuals/SciChartOverview.d.ts +2 -1
  184. package/Charting/Visuals/SciChartOverview.js +28 -8
  185. package/Charting/Visuals/SciChartPieSurface/SciChartPieSurface.d.ts +10 -3
  186. package/Charting/Visuals/SciChartPieSurface/SciChartPieSurface.js +118 -60
  187. package/Charting/Visuals/SciChartSurface.d.ts +4 -36
  188. package/Charting/Visuals/SciChartSurface.js +48 -61
  189. package/Charting/Visuals/SciChartSurfaceBase.d.ts +99 -13
  190. package/Charting/Visuals/SciChartSurfaceBase.js +155 -32
  191. package/Charting/Visuals/TextureManager/CanvasTexture.d.ts +2 -1
  192. package/Charting/Visuals/TextureManager/CanvasTexture.js +37 -17
  193. package/Charting/Visuals/TextureManager/TextureManager.d.ts +2 -1
  194. package/Charting/Visuals/TextureManager/TextureManager.js +27 -7
  195. package/Charting/Visuals/createMaster.d.ts +4 -2
  196. package/Charting/Visuals/createMaster.js +92 -28
  197. package/Charting/Visuals/createSingle.d.ts +0 -2
  198. package/Charting/Visuals/createSingle.js +44 -9
  199. package/Charting/Visuals/licenseManager2D.d.ts +7 -5
  200. package/Charting/Visuals/licenseManager2D.js +105 -53
  201. package/Charting/Visuals/loader.js +3 -1
  202. package/Charting/Visuals/sciChartInitCommon.d.ts +1 -1
  203. package/Charting/Visuals/sciChartInitCommon.js +5 -1
  204. package/Charting3D/CameraController.d.ts +1 -1
  205. package/Charting3D/CameraController.js +21 -7
  206. package/Charting3D/ChartModifiers/ChartModifierBase3D.d.ts +1 -0
  207. package/Charting3D/ChartModifiers/ChartModifierBase3D.js +4 -1
  208. package/Charting3D/ChartModifiers/OrbitModifier3D.d.ts +17 -5
  209. package/Charting3D/ChartModifiers/OrbitModifier3D.js +62 -26
  210. package/Charting3D/ChartModifiers/PinchZoomModifier3D.d.ts +81 -0
  211. package/Charting3D/ChartModifiers/PinchZoomModifier3D.js +164 -0
  212. package/Charting3D/ChartModifiers/TooltipModifier3D.d.ts +87 -0
  213. package/Charting3D/ChartModifiers/TooltipModifier3D.js +391 -0
  214. package/Charting3D/I3DSurfaceOptions.d.ts +10 -0
  215. package/Charting3D/I3DSurfaceOptions.js +2 -0
  216. package/Charting3D/Model/DataSeries/BaseDataSeries3D.d.ts +2 -1
  217. package/Charting3D/Model/DataSeries/BaseDataSeries3D.js +27 -6
  218. package/Charting3D/Model/DataSeries/UniformGridDataSeries3D.d.ts +8 -0
  219. package/Charting3D/Model/DataSeries/UniformGridDataSeries3D.js +12 -0
  220. package/Charting3D/Model/DataSeries/XyzDataSeries3D.d.ts +2 -2
  221. package/Charting3D/Model/DataSeries/XyzDataSeries3D.js +1 -1
  222. package/Charting3D/Vector3.d.ts +5 -0
  223. package/Charting3D/Vector3.js +7 -0
  224. package/Charting3D/Visuals/Annotations/TooltipSvgAnnotation3D.d.ts +88 -0
  225. package/Charting3D/Visuals/Annotations/TooltipSvgAnnotation3D.js +291 -0
  226. package/Charting3D/Visuals/Axis/AxisBase3D.d.ts +21 -2
  227. package/Charting3D/Visuals/Axis/AxisBase3D.js +48 -18
  228. package/Charting3D/Visuals/Axis/AxisBase3DLabelStyle.js +2 -1
  229. package/Charting3D/Visuals/Axis/AxisCubeEntity.d.ts +0 -4
  230. package/Charting3D/Visuals/Axis/AxisCubeEntity.js +3 -6
  231. package/Charting3D/Visuals/Axis/IAxisDescriptor.d.ts +2 -2
  232. package/Charting3D/Visuals/Axis/IAxisDescriptor.js +2 -2
  233. package/Charting3D/Visuals/Primitives/BaseSceneEntity3D.d.ts +41 -30
  234. package/Charting3D/Visuals/Primitives/BaseSceneEntity3D.js +78 -26
  235. package/Charting3D/Visuals/Primitives/CrosshairLinesSceneEntity.d.ts +47 -0
  236. package/Charting3D/Visuals/Primitives/CrosshairLinesSceneEntity.js +106 -0
  237. package/Charting3D/Visuals/Primitives/EntityIdProvider.d.ts +29 -0
  238. package/Charting3D/Visuals/Primitives/EntityIdProvider.js +28 -0
  239. package/Charting3D/Visuals/Primitives/PointLine3DSceneEntity.d.ts +51 -0
  240. package/Charting3D/Visuals/Primitives/PointLine3DSceneEntity.js +188 -0
  241. package/Charting3D/Visuals/Primitives/RenderableSeriesSceneEntity.d.ts +12 -0
  242. package/Charting3D/Visuals/Primitives/RenderableSeriesSceneEntity.js +14 -0
  243. package/Charting3D/Visuals/Primitives/ScatterPointsSceneEntity.d.ts +11 -0
  244. package/Charting3D/Visuals/Primitives/ScatterPointsSceneEntity.js +18 -0
  245. package/Charting3D/Visuals/Primitives/SurfaceMeshSceneEntity.d.ts +3 -0
  246. package/Charting3D/Visuals/Primitives/SurfaceMeshSceneEntity.js +15 -0
  247. package/Charting3D/Visuals/RenderableSeries/BaseRenderableSeries3D.d.ts +16 -1
  248. package/Charting3D/Visuals/RenderableSeries/BaseRenderableSeries3D.js +64 -12
  249. package/Charting3D/Visuals/RenderableSeries/Constants.d.ts +2 -0
  250. package/Charting3D/Visuals/RenderableSeries/Constants.js +2 -0
  251. package/Charting3D/Visuals/RenderableSeries/ESeriesType.d.ts +2 -1
  252. package/Charting3D/Visuals/RenderableSeries/ESeriesType.js +1 -0
  253. package/Charting3D/Visuals/RenderableSeries/HitTestInfo3D.d.ts +37 -0
  254. package/Charting3D/Visuals/RenderableSeries/HitTestInfo3D.js +22 -0
  255. package/Charting3D/Visuals/RenderableSeries/PointLineRenderableSeries3D.d.ts +64 -0
  256. package/Charting3D/Visuals/RenderableSeries/PointLineRenderableSeries3D.js +105 -0
  257. package/Charting3D/Visuals/RenderableSeries/SeriesInfo3D.d.ts +51 -0
  258. package/Charting3D/Visuals/RenderableSeries/SeriesInfo3D.js +32 -0
  259. package/Charting3D/Visuals/RenderableSeries/SurfaceMeshSeriesInfo3D.d.ts +15 -0
  260. package/Charting3D/Visuals/RenderableSeries/SurfaceMeshSeriesInfo3D.js +112 -0
  261. package/Charting3D/Visuals/RenderableSeries/XyzSeriesInfo3D.d.ts +20 -0
  262. package/Charting3D/Visuals/RenderableSeries/XyzSeriesInfo3D.js +60 -0
  263. package/Charting3D/Visuals/RootSceneEntity.d.ts +0 -4
  264. package/Charting3D/Visuals/RootSceneEntity.js +3 -8
  265. package/Charting3D/Visuals/SciChart3DRenderer.d.ts +2 -0
  266. package/Charting3D/Visuals/SciChart3DRenderer.js +49 -0
  267. package/Charting3D/Visuals/SciChart3DSurface.d.ts +44 -3
  268. package/Charting3D/Visuals/SciChart3DSurface.js +103 -9
  269. package/Charting3D/Visuals/ViewportManager3DBase.d.ts +4 -0
  270. package/Charting3D/Visuals/ViewportManager3DBase.js +7 -1
  271. package/Charting3D/Visuals/createMaster3d.d.ts +1 -2
  272. package/Charting3D/Visuals/createMaster3d.js +76 -14
  273. package/Charting3D/Visuals/createSingle3d.js +34 -4
  274. package/Charting3D/Visuals/licenseManager3D.js +29 -25
  275. package/Core/BuildStamp.d.ts +1 -1
  276. package/Core/BuildStamp.js +2 -2
  277. package/Core/DeletableEntity.d.ts +28 -0
  278. package/Core/DeletableEntity.js +141 -0
  279. package/Core/Globals.d.ts +11 -0
  280. package/Core/Globals.js +13 -0
  281. package/Core/Guard.d.ts +6 -0
  282. package/Core/Guard.js +10 -0
  283. package/Core/Mouse/MouseManager.d.ts +23 -0
  284. package/Core/Mouse/MouseManager.js +47 -0
  285. package/Core/Telemetry.js +4 -6
  286. package/_wasm/scichart.browser.js +1 -1
  287. package/_wasm/scichart2d.data +0 -0
  288. package/_wasm/scichart2d.js +4 -294
  289. package/_wasm/scichart2d.wasm +0 -0
  290. package/_wasm/scichart3d.data +0 -0
  291. package/_wasm/scichart3d.js +4 -294
  292. package/_wasm/scichart3d.wasm +0 -0
  293. package/index.d.ts +43 -2
  294. package/index.js +89 -27
  295. package/index.min.js +1 -1
  296. package/package.json +3 -4
  297. package/types/ChartModifierType.d.ts +2 -0
  298. package/types/ChartModifierType.js +2 -0
  299. package/types/DefaultRenderLayer.d.ts +9 -8
  300. package/types/DefaultRenderLayer.js +9 -8
  301. package/types/NumberArray.d.ts +1 -0
  302. package/types/NumberArray.js +12 -1
  303. package/types/SceneEntityType.d.ts +13 -5
  304. package/types/SceneEntityType.js +13 -5
  305. package/types/TSciChart.d.ts +37 -8
  306. package/types/TSciChart3D.d.ts +126 -7
  307. package/types/licensingClasses.d.ts +2 -1
  308. package/types/licensingClasses.js +1 -0
  309. package/utils/MemoryUsageHelper.d.ts +45 -0
  310. package/utils/MemoryUsageHelper.js +171 -0
  311. package/utils/array.d.ts +8 -0
  312. package/utils/array.js +58 -1
  313. package/utils/logger.d.ts +2 -0
  314. package/utils/logger.js +11 -0
@@ -1,4 +1,19 @@
1
1
  "use strict";
2
+ var __extends = (this && this.__extends) || (function () {
3
+ var extendStatics = function (d, b) {
4
+ extendStatics = Object.setPrototypeOf ||
5
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
6
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
7
+ return extendStatics(d, b);
8
+ };
9
+ return function (d, b) {
10
+ if (typeof b !== "function" && b !== null)
11
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
12
+ extendStatics(d, b);
13
+ function __() { this.constructor = d; }
14
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
15
+ };
16
+ })();
2
17
  var __assign = (this && this.__assign) || function () {
3
18
  __assign = Object.assign || function(t) {
4
19
  for (var s, i = 1, n = arguments.length; i < n; i++) {
@@ -23,19 +38,19 @@ Object.defineProperty(exports, "__esModule", { value: true });
23
38
  exports.addEventListenerToPieSegment = exports.SciChartPieSurface = exports.EPieValueMode = exports.EPieType = exports.ESizingMode = void 0;
24
39
  var chartBuilder_1 = require("../../../Builder/chartBuilder");
25
40
  var classFactory_1 = require("../../../Builder/classFactory");
26
- var createMaster3d_1 = require("../../../Charting3D/Visuals/createMaster3d");
27
41
  var app_1 = require("../../../constants/app");
28
42
  var EasingFunctions_1 = require("../../../Core/Animations/EasingFunctions");
43
+ var DeletableEntity_1 = require("../../../Core/DeletableEntity");
29
44
  var Deleter_1 = require("../../../Core/Deleter");
45
+ var Globals_1 = require("../../../Core/Globals");
30
46
  var ObservableArray_1 = require("../../../Core/ObservableArray");
31
47
  var Rect_1 = require("../../../Core/Rect");
32
48
  var BaseType_1 = require("../../../types/BaseType");
33
49
  var SciChartSurfaceType_1 = require("../../../types/SciChartSurfaceType");
50
+ var guid_1 = require("../../../utils/guid");
34
51
  var SciChartJSDarkTheme_1 = require("../../Themes/SciChartJSDarkTheme");
35
52
  var annotationHelpers_1 = require("../Annotations/annotationHelpers");
36
53
  var PieLabelProvider_1 = require("../Axis/LabelProvider/PieLabelProvider");
37
- var createMaster_1 = require("../createMaster");
38
- var createSingle_1 = require("../createSingle");
39
54
  var SciChartPieLegend_1 = require("../Legend/SciChartPieLegend");
40
55
  var sciChartInitCommon_1 = require("../sciChartInitCommon");
41
56
  var SciChartSurfaceBase_1 = require("../SciChartSurfaceBase");
@@ -81,79 +96,83 @@ var EPieValueMode;
81
96
  * It is possible to have more than one {@link SciChartPieSurface} on screen at the same time.
82
97
  * {@link SciChartPieSurface | SciChartPieSurfaces} scale to fit the parent DIV where they are hosted. Use CSS to position the DIV.
83
98
  */
84
- var SciChartPieSurface = /** @class */ (function () {
99
+ var SciChartPieSurface = /** @class */ (function (_super) {
100
+ __extends(SciChartPieSurface, _super);
85
101
  function SciChartPieSurface(canvases, options) {
86
102
  if (canvases === void 0) { canvases = {}; }
87
103
  var _this = this;
88
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
89
- this.animate = true;
104
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
105
+ _this = _super.call(this) || this;
106
+ _this.animate = true;
90
107
  /* The number of frames for the animation. Default 30. A frame will be trigged every 20ms. */
91
- this.animationFrames = 30;
92
- this.pieTypeProperty = EPieType.Pie;
93
- this.holeRadiusProperty = 0.5;
94
- this.holeRadiusSizingModeProperty = ESizingMode.Relative;
95
- this.seriesSpacingProperty = 0;
96
- this.labelRadiusProperty = 1;
97
- this.titleDivs = [];
98
- this.sweepAnimationDone = false;
99
- this.suspendUpdate = false;
100
- this.themeProviderProperty = new SciChartJSDarkTheme_1.SciChartJSDarkTheme();
101
- this.previousThemeProviderProperty = new SciChartJSDarkTheme_1.SciChartJSDarkTheme();
102
- this.deletables = [];
103
- this.valueModeProperty = EPieValueMode.Percentage;
104
- this.labelStyleProperty = {
108
+ _this.animationFrames = 30;
109
+ _this.pieTypeProperty = EPieType.Pie;
110
+ _this.holeRadiusProperty = 0.5;
111
+ _this.holeRadiusSizingModeProperty = ESizingMode.Relative;
112
+ _this.seriesSpacingProperty = 0;
113
+ _this.labelRadiusProperty = 1;
114
+ _this.titleDivs = [];
115
+ _this.sweepAnimationDone = false;
116
+ _this.suspendUpdate = false;
117
+ _this.themeProviderProperty = new SciChartJSDarkTheme_1.SciChartJSDarkTheme();
118
+ _this.previousThemeProviderProperty = new SciChartJSDarkTheme_1.SciChartJSDarkTheme();
119
+ _this.deletables = [];
120
+ _this.valueModeProperty = EPieValueMode.Percentage;
121
+ _this.labelStyleProperty = {
105
122
  fontSize: 14,
106
123
  fontFamily: "Arial",
107
124
  color: "#1e323d",
108
125
  fontWeight: "bold"
109
126
  };
110
- this.domChartRoot = canvases.domChartRoot;
111
- this.domCanvas2D = canvases.domCanvas2D;
112
- this.domSvgContainer = canvases.domSvgContainer;
113
- this.domSvgAdornerLayer = canvases.domSvgAdornerLayer;
114
- this.domDivContainer = canvases.domDivContainer;
115
- var width = this.domCanvas2D.width;
116
- var height = this.domCanvas2D.height;
117
- this.viewRect = new Rect_1.Rect(0, 0, width, height);
118
- this.resizeSubscriptionToken = sciChartInitCommon_1.default.subscribeToResize(canvases.domChartRoot, canvases.aspect, this);
119
- this.drawChart = this.drawChart.bind(this);
120
- this.deleteInternals = this.deleteInternals.bind(this);
121
- this.invalidateElement = this.invalidateElement.bind(this);
122
- this.detachPieSegment = this.detachPieSegment.bind(this);
123
- this.attachPieSegment = this.attachPieSegment.bind(this);
124
- this.pieSegments = new ObservableArray_1.ObservableArray();
125
- this.pieSegments.collectionChanged.subscribe(function (args) {
127
+ _this.id = (_a = options === null || options === void 0 ? void 0 : options.id) !== null && _a !== void 0 ? _a : (0, guid_1.generateGuid)();
128
+ _this.domChartRoot = canvases.domChartRoot;
129
+ _this.domCanvas2D = canvases.domCanvas2D;
130
+ _this.domSvgContainer = canvases.domSvgContainer;
131
+ _this.domSvgAdornerLayer = canvases.domSvgAdornerLayer;
132
+ _this.domDivContainer = canvases.domDivContainer;
133
+ var width = _this.domCanvas2D.width;
134
+ var height = _this.domCanvas2D.height;
135
+ _this.viewRect = new Rect_1.Rect(0, 0, width, height);
136
+ _this.resizeSubscriptionToken = sciChartInitCommon_1.default.subscribeToResize(canvases.domChartRoot, canvases.aspect, _this);
137
+ _this.drawChart = _this.drawChart.bind(_this);
138
+ _this.deleteInternals = _this.deleteInternals.bind(_this);
139
+ _this.invalidateElement = _this.invalidateElement.bind(_this);
140
+ _this.detachPieSegment = _this.detachPieSegment.bind(_this);
141
+ _this.attachPieSegment = _this.attachPieSegment.bind(_this);
142
+ _this.pieSegments = new ObservableArray_1.ObservableArray();
143
+ _this.pieSegments.collectionChanged.subscribe(function (args) {
126
144
  var _a, _b;
127
145
  (_a = args.getOldItems()) === null || _a === void 0 ? void 0 : _a.forEach(_this.detachPieSegment);
128
146
  (_b = args.getNewItems()) === null || _b === void 0 ? void 0 : _b.forEach(_this.attachPieSegment);
129
147
  // Do this only after all changes have been processed
130
148
  _this.invalidateElement();
131
149
  });
132
- this.applySciChartBackground(SciChartSurfaceBase_1.SciChartSurfaceBase.DEFAULT_THEME.sciChartBackground);
133
- this.legend = new SciChartPieLegend_1.SciChartPieLegend();
134
- this.legend.setRootDiv(this.domDivContainer);
135
- this.legend.setPieSegmentArray(this.pieSegments.asArray());
136
- this.legend.setInvalidateParentSurface(this.invalidateElement);
137
- this.legend.setParentSurface(this);
138
- this.heightAspect = (_a = options === null || options === void 0 ? void 0 : options.heightAspect) !== null && _a !== void 0 ? _a : 0;
139
- this.widthAspect = (_b = options === null || options === void 0 ? void 0 : options.widthAspect) !== null && _b !== void 0 ? _b : 0;
140
- this.pieTypeProperty = (_c = options === null || options === void 0 ? void 0 : options.pieType) !== null && _c !== void 0 ? _c : this.pieType;
141
- this.holeRadiusProperty = (_d = options === null || options === void 0 ? void 0 : options.holeRadius) !== null && _d !== void 0 ? _d : this.holeRadius;
142
- this.animate = (_e = options === null || options === void 0 ? void 0 : options.animate) !== null && _e !== void 0 ? _e : this.animate;
143
- this.holeRadiusSizingModeProperty = (_f = options === null || options === void 0 ? void 0 : options.holeRadiusSizingMode) !== null && _f !== void 0 ? _f : this.holeRadiusSizingModeProperty;
144
- this.seriesSpacingProperty = (_g = options === null || options === void 0 ? void 0 : options.seriesSpacing) !== null && _g !== void 0 ? _g : this.seriesSpacingProperty;
145
- this.legend.showLegend = (_h = options === null || options === void 0 ? void 0 : options.showLegend) !== null && _h !== void 0 ? _h : this.legend.showLegend;
146
- this.legend.animate = (_j = options === null || options === void 0 ? void 0 : options.animateLegend) !== null && _j !== void 0 ? _j : this.legend.animate;
147
- this.legend.showCheckboxes = (_k = options === null || options === void 0 ? void 0 : options.showLegendCheckBoxes) !== null && _k !== void 0 ? _k : this.legend.showCheckboxes;
148
- this.legend.showSeriesMarkers = (_l = options === null || options === void 0 ? void 0 : options.showLegendSeriesMarkers) !== null && _l !== void 0 ? _l : this.legend.showSeriesMarkers;
149
- this.paddingProperty = (_m = options === null || options === void 0 ? void 0 : options.padding) !== null && _m !== void 0 ? _m : this.paddingProperty;
150
+ _this.applySciChartBackground(SciChartSurfaceBase_1.SciChartSurfaceBase.DEFAULT_THEME.sciChartBackground);
151
+ _this.legend = new SciChartPieLegend_1.SciChartPieLegend();
152
+ _this.legend.setRootDiv(_this.domDivContainer);
153
+ _this.legend.setPieSegmentArray(_this.pieSegments.asArray());
154
+ _this.legend.setInvalidateParentSurface(_this.invalidateElement);
155
+ _this.legend.setParentSurface(_this);
156
+ _this.heightAspect = (_b = options === null || options === void 0 ? void 0 : options.heightAspect) !== null && _b !== void 0 ? _b : 0;
157
+ _this.widthAspect = (_c = options === null || options === void 0 ? void 0 : options.widthAspect) !== null && _c !== void 0 ? _c : 0;
158
+ _this.pieTypeProperty = (_d = options === null || options === void 0 ? void 0 : options.pieType) !== null && _d !== void 0 ? _d : _this.pieType;
159
+ _this.holeRadiusProperty = (_e = options === null || options === void 0 ? void 0 : options.holeRadius) !== null && _e !== void 0 ? _e : _this.holeRadius;
160
+ _this.animate = (_f = options === null || options === void 0 ? void 0 : options.animate) !== null && _f !== void 0 ? _f : _this.animate;
161
+ _this.holeRadiusSizingModeProperty = (_g = options === null || options === void 0 ? void 0 : options.holeRadiusSizingMode) !== null && _g !== void 0 ? _g : _this.holeRadiusSizingModeProperty;
162
+ _this.seriesSpacingProperty = (_h = options === null || options === void 0 ? void 0 : options.seriesSpacing) !== null && _h !== void 0 ? _h : _this.seriesSpacingProperty;
163
+ _this.legend.showLegend = (_j = options === null || options === void 0 ? void 0 : options.showLegend) !== null && _j !== void 0 ? _j : _this.legend.showLegend;
164
+ _this.legend.animate = (_k = options === null || options === void 0 ? void 0 : options.animateLegend) !== null && _k !== void 0 ? _k : _this.legend.animate;
165
+ _this.legend.showCheckboxes = (_l = options === null || options === void 0 ? void 0 : options.showLegendCheckBoxes) !== null && _l !== void 0 ? _l : _this.legend.showCheckboxes;
166
+ _this.legend.showSeriesMarkers = (_m = options === null || options === void 0 ? void 0 : options.showLegendSeriesMarkers) !== null && _m !== void 0 ? _m : _this.legend.showSeriesMarkers;
167
+ _this.paddingProperty = (_o = options === null || options === void 0 ? void 0 : options.padding) !== null && _o !== void 0 ? _o : _this.paddingProperty;
150
168
  if (options === null || options === void 0 ? void 0 : options.labelProvider) {
151
169
  if (!("getSegmentText" in (options === null || options === void 0 ? void 0 : options.labelProvider))) {
152
170
  options.labelProvider = (0, classFactory_1.createType)(BaseType_1.EBaseType.LabelProvider, options.labelProvider.type, undefined, options.labelProvider.options);
153
171
  }
154
172
  }
155
- this.labelProvider = (_o = options === null || options === void 0 ? void 0 : options.labelProvider) !== null && _o !== void 0 ? _o : new PieLabelProvider_1.PieLabelProvider();
156
- this.valueModeProperty = (_p = options === null || options === void 0 ? void 0 : options.valueMode) !== null && _p !== void 0 ? _p : this.valueModeProperty;
173
+ _this.labelProvider = (_p = options === null || options === void 0 ? void 0 : options.labelProvider) !== null && _p !== void 0 ? _p : new PieLabelProvider_1.PieLabelProvider();
174
+ _this.valueModeProperty = (_q = options === null || options === void 0 ? void 0 : options.valueMode) !== null && _q !== void 0 ? _q : _this.valueModeProperty;
175
+ return _this;
157
176
  }
158
177
  /**
159
178
  * Creates a {@link SciChartPieSurface} to occupy the div by element ID in your DOM.
@@ -165,17 +184,32 @@ var SciChartPieSurface = /** @class */ (function () {
165
184
  SciChartPieSurface.create = function (divElement, options) {
166
185
  var _a, _b;
167
186
  (0, chartBuilder_1.ensureRegistrations)();
168
- var canvases = sciChartInitCommon_1.default.initCanvas(divElement, (_a = options === null || options === void 0 ? void 0 : options.widthAspect) !== null && _a !== void 0 ? _a : 0, (_b = options === null || options === void 0 ? void 0 : options.heightAspect) !== null && _b !== void 0 ? _b : 0, sciChartInitCommon_1.default.ECanvasType.svg);
187
+ var canvases = sciChartInitCommon_1.default.initCanvas(divElement, (_a = options === null || options === void 0 ? void 0 : options.widthAspect) !== null && _a !== void 0 ? _a : 0, (_b = options === null || options === void 0 ? void 0 : options.heightAspect) !== null && _b !== void 0 ? _b : 0, sciChartInitCommon_1.default.ECanvasType.svg, undefined, options === null || options === void 0 ? void 0 : options.touchAction);
169
188
  return new Promise(function (resolve) {
170
- var conflictingRenderContextDestinations = __spreadArray(__spreadArray(__spreadArray([], createMaster_1.sciChartDestinations, true), createMaster3d_1.sciChartDestinations, true), createSingle_1.sciChartSingleDestinations, true).filter(function (destination) { return destination.sciChartSurface.domChartRoot.id === canvases.domChartRoot.id; });
189
+ var _a, _b, _c;
190
+ var conflictingRenderContextDestinations = __spreadArray(__spreadArray(__spreadArray(__spreadArray([], Globals_1.sciChartDestinations, true), Globals_1.sciChart3DDestinations, true), Globals_1.sciChartSingleDestinations, true), Globals_1.sciChartPieDestinations, true).filter(function (destination) { return destination.sciChartSurface.domChartRoot.id === canvases.domChartRoot.id; });
171
191
  conflictingRenderContextDestinations.forEach(function (destination) { return destination.sciChartSurface.delete(); });
172
192
  options = SciChartSurfaceBase_1.SciChartSurfaceBase.resolveOptions(options);
173
193
  var scps = new SciChartPieSurface(canvases, options);
174
194
  scps.applyTheme(options === null || options === void 0 ? void 0 : options.theme);
195
+ Globals_1.sciChartPieDestinations.push({
196
+ canvasElementId: (_a = canvases.domCanvas2D) === null || _a === void 0 ? void 0 : _a.id,
197
+ sciChartSurface: scps,
198
+ width: (_b = canvases.domCanvas2D) === null || _b === void 0 ? void 0 : _b.width,
199
+ height: (_c = canvases.domCanvas2D) === null || _c === void 0 ? void 0 : _c.height
200
+ });
201
+ scps.setDestinations(Globals_1.sciChartPieDestinations);
175
202
  // setTimeout is used to make function async like createSciChartSurface, to have a consistent API
176
203
  setTimeout(function () { return resolve(scps); }, 0);
177
204
  });
178
205
  };
206
+ Object.defineProperty(SciChartPieSurface.prototype, "isDeleted", {
207
+ get: function () {
208
+ return this.isDeletedProperty;
209
+ },
210
+ enumerable: false,
211
+ configurable: true
212
+ });
179
213
  Object.defineProperty(SciChartPieSurface.prototype, "labelProvider", {
180
214
  /**
181
215
  * Gets or sets a {@link LabelProvider} - a class which is responsible for formatting axis labels and cursor labels from numeric values
@@ -244,6 +278,20 @@ var SciChartPieSurface = /** @class */ (function () {
244
278
  enumerable: false,
245
279
  configurable: true
246
280
  });
281
+ SciChartPieSurface.prototype.setDestinations = function (destinations) {
282
+ this.destinations = destinations;
283
+ };
284
+ Object.defineProperty(SciChartPieSurface.prototype, "otherSurfaces", {
285
+ get: function () {
286
+ var _this = this;
287
+ if (!this.destinations) {
288
+ return [];
289
+ }
290
+ return this.destinations.map(function (el) { return el.sciChartSurface; }).filter(function (el2) { return el2 !== _this; });
291
+ },
292
+ enumerable: false,
293
+ configurable: true
294
+ });
247
295
  /**
248
296
  * Call invalidateElement() to trigger a redraw of the {@link SciChartPieSurface}. SciChart's rendering
249
297
  * engine will schedule a redraw a the next time the renderer is free.
@@ -269,9 +317,19 @@ var SciChartPieSurface = /** @class */ (function () {
269
317
  /**
270
318
  * @inheritDoc
271
319
  */
272
- SciChartPieSurface.prototype.delete = function (isAnimationProgress) {
320
+ SciChartPieSurface.prototype.delete = function () {
321
+ var _this = this;
322
+ var _a;
273
323
  this.deleteInternals();
324
+ this.legend = (0, Deleter_1.deleteSafe)(this.legend);
325
+ this.labelProvider = (0, Deleter_1.deleteSafe)(this.labelProvider);
274
326
  this.resizeSubscriptionToken = (0, Deleter_1.deleteSafe)(this.resizeSubscriptionToken);
327
+ // TODO probably this should be moved outside for Proxy === this comparison issue exists
328
+ var currentSurfaceIndex = (_a = this.destinations) === null || _a === void 0 ? void 0 : _a.findIndex(function (dest) { return dest.sciChartSurface.id === _this.id; });
329
+ if (currentSurfaceIndex >= 0) {
330
+ this.destinations.splice(currentSurfaceIndex, 1);
331
+ }
332
+ this.isDeletedProperty = true;
275
333
  };
276
334
  /**
277
335
  * Used Internally. Cleans up the chart internal parts, subscriptions, etc.
@@ -801,7 +859,7 @@ var SciChartPieSurface = /** @class */ (function () {
801
859
  this.domCanvas2D.style.background = htmlColor;
802
860
  };
803
861
  return SciChartPieSurface;
804
- }());
862
+ }(DeletableEntity_1.DeletableEntity));
805
863
  exports.SciChartPieSurface = SciChartPieSurface;
806
864
  /**
807
865
  * @ignore
@@ -13,14 +13,11 @@ import { TSciChart as TWasmContext } from "../../types/TSciChart";
13
13
  import { TSciChartSurfaceCanvases } from "../../types/TSciChartSurfaceCanvases";
14
14
  import { EZoomState } from "../../types/ZoomState";
15
15
  import { IChartModifierBase } from "../ChartModifiers/ChartModifierBase";
16
- import { RenderContext2D } from "../Drawing/RenderContext2D";
17
16
  import { RenderSurface } from "../Drawing/RenderSurface";
18
17
  import { WebGlRenderContext2D } from "../Drawing/WebGlRenderContext2D";
19
18
  import { LayoutManager } from "../LayoutManager/LayoutManager";
20
19
  import { IThemeProvider } from "../Themes/IThemeProvider";
21
- import { AdornerLayer } from "./Annotations/AdornerLayer";
22
20
  import { ECoordinateMode } from "./Annotations/AnnotationBase";
23
- import { IAnnotation } from "./Annotations/IAnnotation";
24
21
  import { AxisBase2D } from "./Axis/AxisBase2D";
25
22
  import { I2DSubSurfaceOptions, I2DSurfaceOptions } from "./I2DSurfaceOptions";
26
23
  import { IDataLabelLayoutManager } from "./RenderableSeries/DataLabels/DataLabelLayoutManager";
@@ -67,6 +64,7 @@ export declare class SciChartSurface extends SciChartSurfaceBase {
67
64
  * @param options Optional - Optional parameters for chart creation. See {@link I2DSurfaceOptions} for more details
68
65
  */
69
66
  static create(divElement: string | HTMLDivElement, options?: I2DSurfaceOptions): Promise<TWebAssemblyChart>;
67
+ static disposeSharedWasmContext(): void;
70
68
  /**
71
69
  * Performs a similar operation to {@link SciChartSurface.create} but uses a dedicated WebAssembly context for this chart, and draws directly to the target canvas
72
70
  * This provides better performance for a single chart, but there is a limit (16) to how many you can have on one page.
@@ -101,7 +99,7 @@ export declare class SciChartSurface extends SciChartSurfaceBase {
101
99
  static useWasmLocal(): void;
102
100
  static isSubSurface(surface: SciChartSurface): surface is SciChartSubSurface;
103
101
  private static createTest;
104
- readonly renderSurface: RenderSurface;
102
+ renderSurface: RenderSurface;
105
103
  /**
106
104
  * @summary Gets the collection of {@link IRenderableSeries} - the chart types or series on this {@link SciChartSurface}
107
105
  * @description A {@link SciChartSurface} can have zero to many {@link IRenderableSeries | RenderableSeries}.
@@ -116,32 +114,6 @@ export declare class SciChartSurface extends SciChartSurfaceBase {
116
114
  * {@link AxisCore.autoRange} or call {@link SciChartSurface.zoomExtents}
117
115
  */
118
116
  readonly renderableSeries: ObservableArray<IRenderableSeries>;
119
- /**
120
- * @summary Gets the collection of {@link IAnnotation} - annotations, markers or shapes drawn over the top of a {@link SciChartSurface}
121
- * @description A {@link SciChartSurface} can have zero to many {@link IAnnotation | Annotations}.
122
- *
123
- * The Annotations are drawn using our WebGL / WebAssembly rendering engine, but some use SVG for maximum configurability.
124
- * See derived types of {@link IAnnotation} such as {@link BoxAnnotation}, {@link LineAnnotation} etc...
125
- *
126
- * Use this collection to add and remove Annotations to the chart.
127
- * @remarks
128
- * Adding an Annotation to the chart causes it to automatically redraw. Note that annotations do not pariticpate in autoranging,
129
- * meaning a chart will zoom to fit data and chart series but not annotations
130
- */
131
- readonly annotations: ObservableArray<IAnnotation>;
132
- /**
133
- * @summary Gets the collection of {@link IAnnotation} - modifier annotations, markers or shapes drawn over the top of a {@link SciChartSurface}
134
- * @description A {@link SciChartSurface} can have zero to many {@link IAnnotation | Annotations}.
135
- *
136
- * The Annotations are drawn using our WebGL / WebAssembly rendering engine, but some use SVG for maximum configurability.
137
- * See derived types of {@link IAnnotation} such as {@link BoxAnnotation}, {@link LineAnnotation} etc...
138
- *
139
- * Use this collection to add and remove Modifier Annotations to the chart.
140
- * @remarks
141
- * Adding an Modifier Annotation to the chart causes it to automatically redraw. Note that annotations do not pariticpate in autoranging,
142
- * meaning a chart will zoom to fit data and chart series but not annotations
143
- */
144
- readonly modifierAnnotations: ObservableArray<IAnnotation>;
145
117
  /**
146
118
  * @summary Gets the collection of {@link AxisBase2D} - the X Axis on a {@link SciChartSurface}
147
119
  * @description A {@link SciChartSurface} can have one to many {@link AxisBase2D | XAxes}.
@@ -187,7 +159,6 @@ export declare class SciChartSurface extends SciChartSurfaceBase {
187
159
  /**
188
160
  * Used internally - the {@link RenderContext2D} for drawing
189
161
  */
190
- renderContext2D: RenderContext2D;
191
162
  /**
192
163
  * An event handler which notifies its subscribers when a render operation has finished. Use this
193
164
  * to time render performance, or to update elements of the chart or your UI on redraw.
@@ -201,7 +172,6 @@ export declare class SciChartSurface extends SciChartSurfaceBase {
201
172
  layersOffset: number;
202
173
  stepBetweenLayers: number;
203
174
  readonly isSubSurface: boolean;
204
- readonly adornerLayer: AdornerLayer;
205
175
  /**
206
176
  * Sets / Gets the clipping mode for SVG Annotations
207
177
  */
@@ -226,7 +196,7 @@ export declare class SciChartSurface extends SciChartSurfaceBase {
226
196
  protected chartTitleRendererProperty: IChartTitleRenderer;
227
197
  protected paddingProperty: Thickness;
228
198
  protected currentWebGlRenderContextProperty: WebGlRenderContext2D;
229
- private readonly sciChartRenderer;
199
+ private sciChartRenderer;
230
200
  private layoutManagerProperty;
231
201
  private dataLabelLayoutManagerProperty;
232
202
  private zoomStateProperty;
@@ -303,7 +273,7 @@ export declare class SciChartSurface extends SciChartSurfaceBase {
303
273
  /**
304
274
  * Gets or sets the title text style and placement for the SciChartSurface as {@link TChartTitleStyle}
305
275
  */
306
- get titleStyle(): Readonly<Required<TChartTitleStyle>>;
276
+ get titleStyle(): TChartTitleStyle;
307
277
  /**
308
278
  * Gets or sets the title text style and placement for the SciChartSurface as {@link TChartTitleStyle}
309
279
  * @remarks if updating, should be set as an object (or partial object) of type {@link TChartTitleStyle},
@@ -544,8 +514,6 @@ export declare class SciChartSurface extends SciChartSurfaceBase {
544
514
  private attachSeries;
545
515
  private detachAxis;
546
516
  private attachAxis;
547
- private detachAnnotation;
548
- private attachAnnotation;
549
517
  protected onAttachSubSurface(subSurface: SciChartSubSurface): void;
550
518
  protected onDetachSubSurface(subSurface: SciChartSubSurface): void;
551
519
  /**
@@ -86,9 +86,9 @@ var translate_1 = require("../../utils/translate");
86
86
  var ChartModifierBase_1 = require("../ChartModifiers/ChartModifierBase");
87
87
  var BatchRenderContext_1 = require("../Drawing/BatchRenderContext");
88
88
  var BrushCache_1 = require("../Drawing/BrushCache");
89
- var RenderContext2D_1 = require("../Drawing/RenderContext2D");
90
89
  var RenderSurface_1 = require("../Drawing/RenderSurface");
91
90
  var SolidBrushCache_1 = require("../Drawing/SolidBrushCache");
91
+ var WebGlRenderContext2D_1 = require("../Drawing/WebGlRenderContext2D");
92
92
  var LayoutManager_1 = require("../LayoutManager/LayoutManager");
93
93
  var SciChartRenderer_1 = require("../Services/SciChartRenderer");
94
94
  var AdornerLayer_1 = require("./Annotations/AdornerLayer");
@@ -111,6 +111,8 @@ var SciChartDefaults_1 = require("./SciChartDefaults");
111
111
  var ChartTitleRenderer_1 = require("../Services/ChartTitleRenderer");
112
112
  var TextStyle_1 = require("../../types/TextStyle");
113
113
  var TextPosition_1 = require("../../types/TextPosition");
114
+ var Globals_1 = require("../../Core/Globals");
115
+ var createMaster3d_1 = require("../../Charting3D/Visuals/createMaster3d");
114
116
  exports.sciChartConfig = {};
115
117
  /**
116
118
  * @summary The {@link SciChartSurface} is the root 2D Chart control in SciChart's High Performance Real-time
@@ -142,6 +144,10 @@ var SciChartSurface = /** @class */ (function (_super) {
142
144
  var _this = this;
143
145
  var _a, _b, _c, _d, _e;
144
146
  _this = _super.call(this, webAssemblyContext, options === null || options === void 0 ? void 0 : options.canvases) || this;
147
+ /**
148
+ * Used internally - the {@link RenderContext2D} for drawing
149
+ */
150
+ //public renderContext2D: RenderContext2D;
145
151
  /**
146
152
  * An event handler which notifies its subscribers when a render operation has finished. Use this
147
153
  * to time render performance, or to update elements of the chart or your UI on redraw.
@@ -234,9 +240,9 @@ var SciChartSurface = /** @class */ (function (_super) {
234
240
  _this.chartTitleRendererProperty = new ChartTitleRenderer_1.ChartTitleRenderer(_this.webAssemblyContext2D);
235
241
  _this.layoutManager = new LayoutManager_1.LayoutManager();
236
242
  // TODO: remove this
237
- if (_this.domCanvas2D) {
238
- _this.renderContext2D = new RenderContext2D_1.RenderContext2D(_this.domCanvas2D);
239
- }
243
+ //if (this.domCanvas2D) {
244
+ // this.renderContext2D = new RenderContext2D(this.domCanvas2D);
245
+ //}
240
246
  // Setup series
241
247
  _this.detachSeries = _this.detachSeries.bind(_this);
242
248
  _this.attachSeries = _this.attachSeries.bind(_this);
@@ -261,21 +267,6 @@ var SciChartSurface = /** @class */ (function (_super) {
261
267
  };
262
268
  _this.xAxes.collectionChanged.subscribe(function (arg) { return handler(arg, true); });
263
269
  _this.yAxes.collectionChanged.subscribe(function (arg) { return handler(arg, false); });
264
- // Setup annotations
265
- _this.detachAnnotation = _this.detachAnnotation.bind(_this);
266
- _this.attachAnnotation = _this.attachAnnotation.bind(_this);
267
- _this.annotations = new ObservableArray_1.ObservableArray();
268
- _this.modifierAnnotations = new ObservableArray_1.ObservableArray();
269
- _this.annotations.collectionChanged.subscribe(function (arg) {
270
- var _a, _b;
271
- (_a = arg.getOldItems()) === null || _a === void 0 ? void 0 : _a.forEach(function (a) { return _this.detachAnnotation(a); });
272
- (_b = arg.getNewItems()) === null || _b === void 0 ? void 0 : _b.forEach(function (a) { return _this.attachAnnotation(a); });
273
- });
274
- _this.modifierAnnotations.collectionChanged.subscribe(function (arg) {
275
- var _a, _b;
276
- (_a = arg.getOldItems()) === null || _a === void 0 ? void 0 : _a.forEach(function (a) { return _this.detachAnnotation(a); });
277
- (_b = arg.getNewItems()) === null || _b === void 0 ? void 0 : _b.forEach(function (a) { return _this.attachAnnotation(a); });
278
- });
279
270
  _this.adornerLayer = new AdornerLayer_1.AdornerLayer(_this);
280
271
  _this.solidBrushCacheViewportBorder = new SolidBrushCache_1.SolidBrushCache(webAssemblyContext);
281
272
  _this.solidBrushCacheCanvasBorder = new SolidBrushCache_1.SolidBrushCache(webAssemblyContext);
@@ -308,6 +299,13 @@ var SciChartSurface = /** @class */ (function (_super) {
308
299
  });
309
300
  }
310
301
  };
302
+ SciChartSurface.disposeSharedWasmContext = function () {
303
+ if (Globals_1.sciChart3DDestinations.length === 0 && Globals_1.sciChartDestinations.length === 0) {
304
+ (0, createMaster_1.disposeMultiChart)();
305
+ (0, createMaster3d_1.disposeMultiChart3d)();
306
+ }
307
+ _super.disposeSharedWasmContext.call(this);
308
+ };
311
309
  /**
312
310
  * Performs a similar operation to {@link SciChartSurface.create} but uses a dedicated WebAssembly context for this chart, and draws directly to the target canvas
313
311
  * This provides better performance for a single chart, but there is a limit (16) to how many you can have on one page.
@@ -675,7 +673,7 @@ var SciChartSurface = /** @class */ (function (_super) {
675
673
  */
676
674
  SciChartSurface.prototype.invalidateElement = function () {
677
675
  // When isSuspended (see suspendUpdates() function) ignore drawing
678
- if (this.isSuspended) {
676
+ if (this.isSuspended || this.isDeleted) {
679
677
  // Logger.log("SciChartSurface.isSuspended = true. Ignoring invalidateElement() call");
680
678
  return;
681
679
  }
@@ -701,6 +699,9 @@ var SciChartSurface = /** @class */ (function (_super) {
701
699
  this.preRender.raiseEvent(context);
702
700
  }
703
701
  catch (err) {
702
+ if (err === null || err === void 0 ? void 0 : err.message) {
703
+ console.error(err === null || err === void 0 ? void 0 : err.message);
704
+ }
704
705
  console.error(err);
705
706
  }
706
707
  finally {
@@ -717,51 +718,47 @@ var SciChartSurface = /** @class */ (function (_super) {
717
718
  }
718
719
  else if (this.domChartRoot) {
719
720
  console.error("Error from chart in div ".concat(this.domChartRoot.id), err);
721
+ if (typeof err !== "string" && (err === null || err === void 0 ? void 0 : err.message)) {
722
+ console.error(err === null || err === void 0 ? void 0 : err.message);
723
+ }
720
724
  }
721
725
  else {
722
726
  // Surface the error for tests
723
727
  throw err;
724
728
  }
725
729
  }
726
- this.currentWebGlRenderContextProperty = undefined;
727
730
  };
728
731
  /**
729
732
  * @inheritDoc
730
733
  */
731
734
  SciChartSurface.prototype.delete = function (clearHtml) {
732
735
  if (clearHtml === void 0) { clearHtml = true; }
733
- _super.prototype.delete.call(this);
736
+ if (this.isDeleted) {
737
+ if (process.env.NODE_ENV !== "production") {
738
+ console.warn("Trying to delete the surface with ID = \"".concat(this.id, ")\", which has already been deleted!"));
739
+ }
740
+ return;
741
+ }
734
742
  for (var _i = 0, _a = this.subChartsProperty; _i < _a.length; _i++) {
735
743
  var chart = _a[_i];
736
744
  chart.delete();
737
745
  }
738
746
  this.subChartsProperty = [];
747
+ this.layoutManagerProperty.sciChartSurface = undefined;
748
+ this.layoutManagerProperty = undefined;
739
749
  this.renderableSeries.asArray().forEach(function (rs) { return rs.delete(); });
740
750
  this.renderableSeries.clear();
741
751
  this.xAxes.asArray().forEach(function (xAxis) { return xAxis.delete(); });
742
752
  this.yAxes.asArray().forEach(function (yAxis) { return yAxis.delete(); });
743
- this.modifierAnnotations.asArray().forEach(function (annotation) { return annotation.delete(); });
744
- this.annotations.asArray().forEach(function (annotation) { return annotation.delete(); });
745
753
  this.solidBrushCacheViewportBorder = (0, Deleter_1.deleteSafe)(this.solidBrushCacheViewportBorder);
746
754
  this.solidBrushCacheCanvasBorder = (0, Deleter_1.deleteSafe)(this.solidBrushCacheCanvasBorder);
747
755
  this.watermarkProperties = (0, Deleter_1.deleteSafe)(this.watermarkProperties);
748
756
  this.watermarkPropertyPosition = (0, Deleter_1.deleteSafe)(this.watermarkPropertyPosition);
749
- this.chartModifiers.asArray().forEach(function (chm) { return chm.delete(); });
750
757
  this.chartTitleRendererProperty = (0, Deleter_1.deleteSafe)(this.chartTitleRenderer);
751
- if (clearHtml && this.domChartRoot) {
752
- var style = this.domChartRoot.style;
753
- if (style) {
754
- style.background = "";
755
- style.position = "";
756
- }
757
- if (this.domChartRoot.hasOwnProperty("replaceChildren")) {
758
- // @ts-ignore
759
- this.domChartRoot.replaceChildren();
760
- }
761
- else {
762
- this.domChartRoot.innerHTML = "";
763
- }
764
- }
758
+ this.sciChartRenderer = undefined;
759
+ this.renderSurface = undefined;
760
+ this.clearRootElement(clearHtml);
761
+ _super.prototype.delete.call(this);
765
762
  };
766
763
  /**
767
764
  * @inheritDoc
@@ -769,8 +766,6 @@ var SciChartSurface = /** @class */ (function (_super) {
769
766
  SciChartSurface.prototype.onDpiChanged = function (args) {
770
767
  var _a, _b;
771
768
  this.renderableSeries.asArray().forEach(function (rs) { return rs.onDpiChanged(args); });
772
- this.annotations.asArray().forEach(function (a) { return a.onDpiChanged(args); });
773
- this.modifierAnnotations.asArray().forEach(function (a) { return a.onDpiChanged(args); });
774
769
  this.xAxes.asArray().forEach(function (a) { return a.onDpiChanged(); });
775
770
  this.yAxes.asArray().forEach(function (a) { return a.onDpiChanged(); });
776
771
  // Force a viewport size change as size-changed may not fire when parent div has width, height
@@ -1196,7 +1191,8 @@ var SciChartSurface = /** @class */ (function (_super) {
1196
1191
  loader: this.loaderJson,
1197
1192
  drawSeriesBehindAxis: this.drawSeriesBehindAxis,
1198
1193
  disableAspect: this.disableAspect,
1199
- autoColorMode: this.autoColorMode
1194
+ autoColorMode: this.autoColorMode,
1195
+ touchAction: this.touchActionProperty
1200
1196
  };
1201
1197
  var definition = {
1202
1198
  surface: options,
@@ -1244,6 +1240,9 @@ var SciChartSurface = /** @class */ (function (_super) {
1244
1240
  if (options === null || options === void 0 ? void 0 : options.titleStyle) {
1245
1241
  this.titleStyle = options.titleStyle;
1246
1242
  }
1243
+ if (options === null || options === void 0 ? void 0 : options.touchAction) {
1244
+ this.touchActionProperty = options.touchAction;
1245
+ }
1247
1246
  };
1248
1247
  /**
1249
1248
  * @inheritDoc
@@ -1338,6 +1337,7 @@ var SciChartSurface = /** @class */ (function (_super) {
1338
1337
  else {
1339
1338
  this.doDrawingLoop();
1340
1339
  }
1340
+ this.currentWebGlRenderContextProperty = (0, Deleter_1.deleteSafe)(this.currentWebGlRenderContext);
1341
1341
  };
1342
1342
  SciChartSurface.prototype.detachSeries = function (renderableSeries) {
1343
1343
  if (renderableSeries.type === SeriesType_1.ESeriesType.StackedColumnSeries ||
@@ -1396,8 +1396,7 @@ var SciChartSurface = /** @class */ (function (_super) {
1396
1396
  this.invalidateElement();
1397
1397
  };
1398
1398
  SciChartSurface.prototype.detachAxis = function (axis) {
1399
- axis.invalidateParentCallback = undefined;
1400
- axis.parentSurface = undefined;
1399
+ axis.onDetach();
1401
1400
  this.invalidateElement();
1402
1401
  };
1403
1402
  SciChartSurface.prototype.attachAxis = function (axis, isXAxis) {
@@ -1418,21 +1417,6 @@ var SciChartSurface = /** @class */ (function (_super) {
1418
1417
  axis.invalidateParentCallback = this.invalidateElement;
1419
1418
  this.invalidateElement();
1420
1419
  };
1421
- SciChartSurface.prototype.detachAnnotation = function (annotation) {
1422
- annotation.onDetach();
1423
- annotation.invalidateParentCallback = undefined;
1424
- annotation.parentSurface = undefined;
1425
- this.invalidateElement();
1426
- };
1427
- SciChartSurface.prototype.attachAnnotation = function (annotation) {
1428
- if (annotation.invalidateParentCallback) {
1429
- throw new Error("Invalid operation in sciChartSurface.attachAnnotation, this annotation has already been attached to a SciChartSurface. Please detach it from a SciChartSurface before attaching to another");
1430
- }
1431
- annotation.parentSurface = this;
1432
- annotation.invalidateParentCallback = this.invalidateElement;
1433
- annotation.onAttach(this);
1434
- this.invalidateElement();
1435
- };
1436
1420
  SciChartSurface.prototype.onAttachSubSurface = function (subSurface) {
1437
1421
  this.chartModifiers.asArray().forEach(function (modifier) {
1438
1422
  modifier.onAttachSubSurface(subSurface);
@@ -1730,11 +1714,11 @@ var SciChartSubSurface = /** @class */ (function (_super) {
1730
1714
  SciChartSubSurface.prototype.delete = function (clearHtml) {
1731
1715
  if (clearHtml === void 0) { clearHtml = true; }
1732
1716
  // Don't ever clear html on the parent here as it kills the drawing for all subcharts.
1733
- _super.prototype.delete.call(this, false);
1734
1717
  if (clearHtml && this.domChartRoot.contains(this.domSvgContainer)) {
1735
1718
  this.domChartRoot.removeChild(this.domSvgContainer);
1736
1719
  }
1737
1720
  this.backgroundFillBrushCache = (0, Deleter_1.deleteSafe)(this.backgroundFillBrushCache);
1721
+ _super.prototype.delete.call(this, false);
1738
1722
  };
1739
1723
  SciChartSubSurface.prototype.toJSON = function (excludeData) {
1740
1724
  var _a;
@@ -1822,7 +1806,9 @@ var SciChartSubSurface = /** @class */ (function (_super) {
1822
1806
  if (alphaEnabled === void 0) { alphaEnabled = true; }
1823
1807
  this.backgroundProperty = background;
1824
1808
  if (!this.isTransparent) {
1825
- var renderContext = this.renderSurface.getRenderContext();
1809
+ // const renderContext = this.renderSurface.getRenderContext();
1810
+ // This is probably an unnecessary change, and mostly here to prevent a memory usage debug warning
1811
+ var renderContext = new WebGlRenderContext2D_1.WebGlRenderContext2D(this.webAssemblyContext2D, this.renderSurface.viewportSize, this.renderSurface.canvasId);
1826
1812
  var nativeContext = renderContext.getNativeContext();
1827
1813
  var _a = this.parentSurface.renderSurface.viewportSize, width = _a.width, height = _a.height;
1828
1814
  nativeContext.SetClipRect(this.adjustedPadding.left, this.adjustedPadding.top, width - this.adjustedPadding.right - this.adjustedPadding.left, height - this.adjustedPadding.bottom - this.adjustedPadding.top);
@@ -1840,6 +1826,7 @@ var SciChartSubSurface = /** @class */ (function (_super) {
1840
1826
  catch (error) {
1841
1827
  performanceWarnings_1.performanceWarnings.subchartBackgroundNotSimpleColor.warn();
1842
1828
  }
1829
+ renderContext.delete();
1843
1830
  }
1844
1831
  };
1845
1832
  SciChartSubSurface.prototype.updateWrapper = function (subChartPosition) {