scichart 2.0.2144 → 2.0.2186
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Builder/buildAnnotations.js +11 -10
- package/Builder/buildAxis.js +7 -6
- package/Builder/buildDataSeries.js +3 -6
- package/Builder/buildModifiers.js +17 -16
- package/Builder/buildSeries.js +21 -20
- package/Builder/buildSurface.js +29 -27
- package/Builder/chartBuilder.d.ts +10 -162
- package/Builder/chartBuilder.js +9 -6
- package/Builder/classFactory.js +12 -6
- package/Charting/ChartModifiers/ChartModifierBase.js +1 -1
- package/Charting/ChartModifiers/ChartModifierBase2D.d.ts +1 -1
- package/Charting/ChartModifiers/ChartModifierBase2D.js +11 -6
- package/Charting/ChartModifiers/CursorModifier.d.ts +23 -3
- package/Charting/ChartModifiers/CursorModifier.js +72 -40
- package/Charting/ChartModifiers/DataPointSelectionModifier.d.ts +1 -1
- package/Charting/ChartModifiers/DataPointSelectionModifier.js +18 -16
- package/Charting/ChartModifiers/LegendModifier.d.ts +1 -1
- package/Charting/ChartModifiers/LegendModifier.js +3 -1
- package/Charting/ChartModifiers/ModifierMouseArgs.js +4 -3
- package/Charting/ChartModifiers/MouseWheelZoomModifier.d.ts +52 -2
- package/Charting/ChartModifiers/MouseWheelZoomModifier.js +105 -10
- package/Charting/ChartModifiers/OverviewRangeSelectionModifier.js +10 -8
- package/Charting/ChartModifiers/PinchZoomModifier.d.ts +1 -1
- package/Charting/ChartModifiers/PinchZoomModifier.js +4 -2
- package/Charting/ChartModifiers/RolloverModifier.d.ts +1 -1
- package/Charting/ChartModifiers/RolloverModifier.js +27 -20
- package/Charting/ChartModifiers/RubberBandXyZoomModifier.d.ts +1 -1
- package/Charting/ChartModifiers/RubberBandXyZoomModifier.js +11 -9
- package/Charting/ChartModifiers/SeriesSelectionModifier.d.ts +1 -1
- package/Charting/ChartModifiers/SeriesSelectionModifier.js +9 -7
- package/Charting/ChartModifiers/XAxisDragModifier.d.ts +1 -1
- package/Charting/ChartModifiers/XAxisDragModifier.js +12 -10
- package/Charting/ChartModifiers/YAxisDragModifier.d.ts +1 -1
- package/Charting/ChartModifiers/YAxisDragModifier.js +12 -10
- package/Charting/ChartModifiers/ZoomExtentsModifier.d.ts +17 -1
- package/Charting/ChartModifiers/ZoomExtentsModifier.js +65 -10
- package/Charting/ChartModifiers/ZoomPanModifier.d.ts +4 -2
- package/Charting/ChartModifiers/ZoomPanModifier.js +25 -21
- package/Charting/Drawing/BaseCache.js +2 -2
- package/Charting/Drawing/BrushCache.js +12 -7
- package/Charting/Drawing/PaletteCache.js +4 -2
- package/Charting/Drawing/Pen2DCache.js +14 -9
- package/Charting/Drawing/SolidBrushCache.js +2 -2
- package/Charting/Drawing/TextureCache.js +4 -2
- package/Charting/Drawing/WebGlBrush.js +1 -1
- package/Charting/Drawing/WebGlPen.js +2 -2
- package/Charting/Drawing/WebGlRenderContext2D.js +5 -5
- package/Charting/LayoutManager/AxisLayoutHelpers.js +6 -4
- package/Charting/LayoutManager/BaseAxisLayoutStrategy.js +4 -4
- package/Charting/LayoutManager/BaseCenteredAxisLayoutStrategy.d.ts +1 -1
- package/Charting/LayoutManager/BaseCenteredAxisLayoutStrategy.js +3 -1
- package/Charting/LayoutManager/BottomAlignedInnerAxisLayoutStrategy.js +6 -4
- package/Charting/LayoutManager/BottomAlignedOuterAxisLayoutStrategy.js +6 -4
- package/Charting/LayoutManager/BottomAlignedOuterHorizontallyStackedAxisLayoutStrategy.js +7 -5
- package/Charting/LayoutManager/CentralAxesLayoutManager.js +7 -3
- package/Charting/LayoutManager/LayoutManager.js +2 -2
- package/Charting/LayoutManager/LeftAlignedInnerAxisLayoutStrategy.js +6 -4
- package/Charting/LayoutManager/LeftAlignedOuterAxisLayoutStrategy.js +6 -4
- package/Charting/LayoutManager/LeftAlignedOuterVerticallyStackedAxisLayoutStrategy.js +7 -5
- package/Charting/LayoutManager/RightAlignedInnerAxisLayoutStrategy.js +6 -4
- package/Charting/LayoutManager/RightAlignedOuterAxisLayoutStrategy.js +6 -4
- package/Charting/LayoutManager/RightAlignedOuterVerticallyStackedAxisLayoutStrategy.js +7 -5
- package/Charting/LayoutManager/SynchronizedLayoutManager.js +4 -2
- package/Charting/LayoutManager/TopAlignedInnerAxisLayoutStrategy.js +6 -4
- package/Charting/LayoutManager/TopAlignedOuterAxisLayoutStrategy.js +6 -4
- package/Charting/LayoutManager/TopAlignedOuterHorizontallyStackedAxisLayoutStrategy.js +7 -5
- package/Charting/Model/BaseDataSeries.js +23 -20
- package/Charting/Model/BaseHeatmapDataSeries.js +5 -5
- package/Charting/Model/ChartData/HeatmapSeriesInfo.js +4 -2
- package/Charting/Model/ChartData/OhlcSeriesInfo.js +3 -1
- package/Charting/Model/ChartData/SeriesInfo.d.ts +1 -0
- package/Charting/Model/ChartData/SeriesInfo.js +15 -0
- package/Charting/Model/ChartData/StackedXySeriesInfo.js +3 -1
- package/Charting/Model/ChartData/XySeriesInfo.js +3 -1
- package/Charting/Model/ChartData/XyySeriesInfo.js +3 -1
- package/Charting/Model/DataPointSelectionPaletteProvider.js +2 -2
- package/Charting/Model/Filters/OhlcCustomFilter.js +7 -2
- package/Charting/Model/Filters/OhlcFilterBase.js +3 -1
- package/Charting/Model/Filters/OhlcScaleOffsetFilter.js +3 -1
- package/Charting/Model/Filters/XyCustomFilter.js +3 -1
- package/Charting/Model/Filters/XyFilterBase.js +9 -6
- package/Charting/Model/Filters/XyLinearTrendFilter.js +3 -1
- package/Charting/Model/Filters/XyMovingAverageFilter.js +3 -1
- package/Charting/Model/Filters/XyRatioFilter.js +6 -4
- package/Charting/Model/Filters/XyScaleOffsetFilter.js +3 -1
- package/Charting/Model/Filters/XyyCustomFilter.js +3 -1
- package/Charting/Model/Filters/XyyFilterBase.js +7 -5
- package/Charting/Model/Filters/XyyScaleOffsetFilter.js +3 -1
- package/Charting/Model/Filters/XyzCustomFilter.js +3 -1
- package/Charting/Model/Filters/XyzFilterBase.js +7 -5
- package/Charting/Model/Filters/XyzScaleOffsetFilter.js +3 -1
- package/Charting/Model/OhlcDataSeries.js +27 -25
- package/Charting/Model/PaletteFactory.js +3 -3
- package/Charting/Model/UniformHeatmapDataSeries.js +3 -1
- package/Charting/Model/XyDataSeries.js +9 -7
- package/Charting/Model/XyyDataSeries.js +15 -13
- package/Charting/Model/XyzDataSeries.js +15 -13
- package/Charting/Numerics/CoordinateCalculators/CategoryCoordinateCalculator.js +3 -1
- package/Charting/Numerics/CoordinateCalculators/FlippedCategoryCoordinateCalculator.js +3 -1
- package/Charting/Numerics/CoordinateCalculators/FlippedNumericCoordinateCalculator.js +3 -1
- package/Charting/Numerics/CoordinateCalculators/LogarithmicCoordinateCalculator.js +3 -1
- package/Charting/Numerics/CoordinateCalculators/NumericCoordinateCalculator.js +3 -1
- package/Charting/Numerics/TickCoordinateProviders/DefaultTickCoordinatesProvider.js +3 -1
- package/Charting/Numerics/TickProviders/LogarithmicTickProvider.js +7 -5
- package/Charting/Numerics/TickProviders/NumericTickProvider.js +4 -2
- package/Charting/Services/SciChartRenderer.d.ts +1 -0
- package/Charting/Services/SciChartRenderer.js +29 -20
- package/Charting/Services/Workers/TextureWorker.d.ts +16 -0
- package/Charting/Services/Workers/TextureWorker.js +138 -0
- package/Charting/Services/Workers/TextureWorkerSource.d.ts +1 -0
- package/Charting/Services/Workers/TextureWorkerSource.js +133 -0
- package/Charting/Themes/SciChartJSDarkTheme.js +3 -1
- package/Charting/Themes/SciChartJSDarkv2Theme.js +3 -1
- package/Charting/Themes/SciChartJSLightTheme.js +3 -1
- package/Charting/Visuals/Annotations/AnnotationBase.d.ts +1 -1
- package/Charting/Visuals/Annotations/AnnotationBase.js +71 -41
- package/Charting/Visuals/Annotations/AxisMarkerAnnotation.d.ts +28 -1
- package/Charting/Visuals/Annotations/AxisMarkerAnnotation.js +11 -9
- package/Charting/Visuals/Annotations/BoxAnnotation.d.ts +1 -1
- package/Charting/Visuals/Annotations/BoxAnnotation.js +18 -16
- package/Charting/Visuals/Annotations/CursorTooltipSvgAnnotation.d.ts +1 -1
- package/Charting/Visuals/Annotations/CursorTooltipSvgAnnotation.js +36 -14
- package/Charting/Visuals/Annotations/CustomAnnotation.d.ts +1 -1
- package/Charting/Visuals/Annotations/CustomAnnotation.js +3 -1
- package/Charting/Visuals/Annotations/HorizontalLineAnnotation.js +8 -6
- package/Charting/Visuals/Annotations/LineAnnotation.d.ts +1 -1
- package/Charting/Visuals/Annotations/LineAnnotation.js +21 -17
- package/Charting/Visuals/Annotations/OverviewCustomResizableAnnotation.js +20 -17
- package/Charting/Visuals/Annotations/RenderContextAnnotationBase.js +3 -1
- package/Charting/Visuals/Annotations/RolloverLegendSvgAnnotation.js +3 -1
- package/Charting/Visuals/Annotations/RolloverMarkerSvgAnnotation.js +4 -2
- package/Charting/Visuals/Annotations/RolloverTooltipSvgAnnotation.js +17 -15
- package/Charting/Visuals/Annotations/SvgAnnotationBase.d.ts +1 -1
- package/Charting/Visuals/Annotations/SvgAnnotationBase.js +23 -13
- package/Charting/Visuals/Annotations/TextAnnotation.d.ts +1 -1
- package/Charting/Visuals/Annotations/TextAnnotation.js +4 -2
- package/Charting/Visuals/Annotations/VerticalLineAnnotation.js +8 -6
- package/Charting/Visuals/Axis/AxisBase2D.d.ts +16 -8
- package/Charting/Visuals/Axis/AxisBase2D.js +70 -37
- package/Charting/Visuals/Axis/AxisCore.d.ts +1 -1
- package/Charting/Visuals/Axis/AxisCore.js +3 -33
- package/Charting/Visuals/Axis/AxisRenderer.d.ts +63 -0
- package/Charting/Visuals/Axis/AxisRenderer.js +92 -16
- package/Charting/Visuals/Axis/AxisTitleRenderer.js +7 -3
- package/Charting/Visuals/Axis/CategoryAxis.js +5 -2
- package/Charting/Visuals/Axis/CategoryAxisBase.js +10 -8
- package/Charting/Visuals/Axis/DeltaCalculator/CategoryDeltaCalculator.js +3 -1
- package/Charting/Visuals/Axis/DeltaCalculator/LogarithmicDeltaCalculator.js +3 -1
- package/Charting/Visuals/Axis/DeltaCalculator/NumericDeltaCalculator.js +3 -1
- package/Charting/Visuals/Axis/LabelProvider/DateLabelProvider.js +5 -3
- package/Charting/Visuals/Axis/LabelProvider/LabelCache.d.ts +41 -0
- package/Charting/Visuals/Axis/LabelProvider/LabelCache.js +164 -0
- package/Charting/Visuals/Axis/LabelProvider/LabelProvider.d.ts +1 -1
- package/Charting/Visuals/Axis/LabelProvider/LabelProviderBase2D.d.ts +57 -7
- package/Charting/Visuals/Axis/LabelProvider/LabelProviderBase2D.js +171 -74
- package/Charting/Visuals/Axis/LabelProvider/LogarithmicLabelProvider.js +5 -3
- package/Charting/Visuals/Axis/LabelProvider/NumericLabelProvider.js +5 -3
- package/Charting/Visuals/Axis/LabelProvider/SmartDateLabelProvider.js +30 -37
- package/Charting/Visuals/Axis/LabelProvider/TextLabelProvider.d.ts +5 -2
- package/Charting/Visuals/Axis/LabelProvider/TextLabelProvider.js +86 -5
- package/Charting/Visuals/Axis/LogarithmicAxis.js +10 -3
- package/Charting/Visuals/Axis/NumericAxis.js +5 -2
- package/Charting/Visuals/Axis/getAxisById.js +1 -1
- package/Charting/Visuals/Helpers/createNativeRect.js +2 -1
- package/Charting/Visuals/Helpers/createPen.js +4 -3
- package/Charting/Visuals/Helpers/createSolidBrush.js +5 -4
- package/Charting/Visuals/Helpers/drawBorder.js +6 -5
- package/Charting/Visuals/Helpers/drawLabel.js +10 -6
- package/Charting/Visuals/Legend/SciChartLegend.js +4 -2
- package/Charting/Visuals/Legend/SciChartLegendBase.js +16 -14
- package/Charting/Visuals/Legend/SciChartPieLegend.js +6 -4
- package/Charting/Visuals/PointMarkers/BasePointMarker.js +3 -3
- package/Charting/Visuals/PointMarkers/CrossPointMarker.js +3 -1
- package/Charting/Visuals/PointMarkers/EllipsePointMarker.js +3 -1
- package/Charting/Visuals/PointMarkers/SpritePointMarker.js +3 -1
- package/Charting/Visuals/PointMarkers/SquarePointMarker.js +3 -1
- package/Charting/Visuals/PointMarkers/TrianglePointMarker.js +3 -1
- package/Charting/Visuals/PointMarkers/XPointMarker.js +3 -1
- package/Charting/Visuals/RenderableSeries/Animations/BandAnimation.js +6 -4
- package/Charting/Visuals/RenderableSeries/Animations/BandAnimationStyle.js +6 -4
- package/Charting/Visuals/RenderableSeries/Animations/BaseAnimationStyle.js +1 -1
- package/Charting/Visuals/RenderableSeries/Animations/BubbleAnimation.js +3 -1
- package/Charting/Visuals/RenderableSeries/Animations/CandlestickAnimation.js +5 -3
- package/Charting/Visuals/RenderableSeries/Animations/CandlestickAnimationStyle.js +5 -3
- package/Charting/Visuals/RenderableSeries/Animations/ColumnAnimation.js +4 -2
- package/Charting/Visuals/RenderableSeries/Animations/ColumnAnimationStyle.js +4 -2
- package/Charting/Visuals/RenderableSeries/Animations/CustomPointMarkerStyle.js +3 -1
- package/Charting/Visuals/RenderableSeries/Animations/FadeAnimation.js +3 -1
- package/Charting/Visuals/RenderableSeries/Animations/LineAnimation.js +3 -1
- package/Charting/Visuals/RenderableSeries/Animations/MountainAnimation.js +4 -2
- package/Charting/Visuals/RenderableSeries/Animations/MountainAnimationStyle.js +4 -2
- package/Charting/Visuals/RenderableSeries/Animations/OhlcAnimation.js +5 -3
- package/Charting/Visuals/RenderableSeries/Animations/OhlcAnimationStyle.js +5 -3
- package/Charting/Visuals/RenderableSeries/Animations/PointMarkerStyle.js +5 -3
- package/Charting/Visuals/RenderableSeries/Animations/ScaleAnimation.d.ts +1 -1
- package/Charting/Visuals/RenderableSeries/Animations/ScaleAnimation.js +3 -1
- package/Charting/Visuals/RenderableSeries/Animations/ScatterAnimation.js +3 -1
- package/Charting/Visuals/RenderableSeries/Animations/SeriesAnimation.d.ts +1 -1
- package/Charting/Visuals/RenderableSeries/Animations/SeriesAnimation.js +3 -3
- package/Charting/Visuals/RenderableSeries/Animations/SweepAnimation.js +3 -1
- package/Charting/Visuals/RenderableSeries/Animations/WaveAnimation.d.ts +1 -1
- package/Charting/Visuals/RenderableSeries/Animations/WaveAnimation.js +3 -1
- package/Charting/Visuals/RenderableSeries/Animations/animationHelpers.js +2 -2
- package/Charting/Visuals/RenderableSeries/BaseBandRenderableSeries.js +3 -1
- package/Charting/Visuals/RenderableSeries/BaseLineRenderableSeries.js +3 -1
- package/Charting/Visuals/RenderableSeries/BaseMountainRenderableSeries.js +3 -1
- package/Charting/Visuals/RenderableSeries/BaseOhlcRenderableSeries.js +3 -1
- package/Charting/Visuals/RenderableSeries/BaseRenderableSeries.js +15 -14
- package/Charting/Visuals/RenderableSeries/BaseStackedCollection.js +7 -5
- package/Charting/Visuals/RenderableSeries/BaseStackedRenderableSeries.js +3 -3
- package/Charting/Visuals/RenderableSeries/DrawingProviders/BandSeriesDrawingProvider.js +20 -18
- package/Charting/Visuals/RenderableSeries/DrawingProviders/BaseSeriesDrawingProvider.js +12 -12
- package/Charting/Visuals/RenderableSeries/DrawingProviders/BubbleSeriesDrawingProvider.js +4 -2
- package/Charting/Visuals/RenderableSeries/DrawingProviders/ColumnSeriesDrawingProvider.js +12 -10
- package/Charting/Visuals/RenderableSeries/DrawingProviders/LineSeriesDrawingProvider.js +9 -7
- package/Charting/Visuals/RenderableSeries/DrawingProviders/MountainSeriesDrawingProvider.js +10 -8
- package/Charting/Visuals/RenderableSeries/DrawingProviders/OhlcSeriesDrawingProvider.js +20 -18
- package/Charting/Visuals/RenderableSeries/DrawingProviders/PointMarkerDrawingProvider.js +6 -4
- package/Charting/Visuals/RenderableSeries/DrawingProviders/UniformContoursDrawingProvider.js +9 -7
- package/Charting/Visuals/RenderableSeries/DrawingProviders/UniformHeatmapDrawingProvider.js +6 -4
- package/Charting/Visuals/RenderableSeries/FastBandRenderableSeries.js +3 -1
- package/Charting/Visuals/RenderableSeries/FastBubbleRenderableSeries.js +3 -1
- package/Charting/Visuals/RenderableSeries/FastCandlestickRenderableSeries.js +3 -1
- package/Charting/Visuals/RenderableSeries/FastColumnRenderableSeries.js +6 -3
- package/Charting/Visuals/RenderableSeries/FastLineRenderableSeries.js +3 -1
- package/Charting/Visuals/RenderableSeries/FastMountainRenderableSeries.js +3 -1
- package/Charting/Visuals/RenderableSeries/FastOhlcRenderableSeries.js +3 -1
- package/Charting/Visuals/RenderableSeries/GlowEffect.js +3 -1
- package/Charting/Visuals/RenderableSeries/HitTest/BandSeriesHitTestProvider.js +3 -1
- package/Charting/Visuals/RenderableSeries/HitTest/BaseHitTestProvider.js +1 -1
- package/Charting/Visuals/RenderableSeries/HitTest/BubbleSeriesHitTestProvider.js +4 -2
- package/Charting/Visuals/RenderableSeries/HitTest/ColumnSeriesHitTestProvider.js +4 -2
- package/Charting/Visuals/RenderableSeries/HitTest/LineSeriesHitTestProvider.js +8 -6
- package/Charting/Visuals/RenderableSeries/HitTest/MountainSeriesHitTestProvider.js +3 -1
- package/Charting/Visuals/RenderableSeries/HitTest/OhlcSeriesHitTestProvider.js +4 -2
- package/Charting/Visuals/RenderableSeries/HitTest/ScatterSeriesHitTestProvider.js +6 -4
- package/Charting/Visuals/RenderableSeries/HitTest/StackedColumnSeriesHitTestProvider.js +7 -5
- package/Charting/Visuals/RenderableSeries/HitTest/StackedMountainSeriesHitTestProvider.js +3 -1
- package/Charting/Visuals/RenderableSeries/HitTest/UniformHeatmapHitTestProvider.js +3 -1
- package/Charting/Visuals/RenderableSeries/HitTest/hitTestHelpers.js +12 -12
- package/Charting/Visuals/RenderableSeries/RolloverModifier/RolloverModifierRenderableSeriesProps.js +2 -2
- package/Charting/Visuals/RenderableSeries/ShaderEffect.js +4 -4
- package/Charting/Visuals/RenderableSeries/ShadowEffect.js +4 -2
- package/Charting/Visuals/RenderableSeries/SplineBandRenderableSeries.js +6 -4
- package/Charting/Visuals/RenderableSeries/SplineLineRenderableSeries.js +5 -3
- package/Charting/Visuals/RenderableSeries/SplineMountainRenderableSeries.js +5 -3
- package/Charting/Visuals/RenderableSeries/StackedColumnCollection.js +6 -4
- package/Charting/Visuals/RenderableSeries/StackedColumnRenderableSeries.js +11 -9
- package/Charting/Visuals/RenderableSeries/StackedMountainCollection.js +7 -5
- package/Charting/Visuals/RenderableSeries/StackedMountainRenderableSeries.js +11 -9
- package/Charting/Visuals/RenderableSeries/UniformContoursRenderableSeries.js +6 -4
- package/Charting/Visuals/RenderableSeries/UniformHeatmapRenderableSeries.js +5 -2
- package/Charting/Visuals/RenderableSeries/XyScatterRenderableSeries.js +3 -1
- package/Charting/Visuals/RubberBandSvgRect/RubberBandSvgRect.js +3 -3
- package/Charting/Visuals/SciChartDefaults.d.ts +11 -0
- package/Charting/Visuals/SciChartDefaults.js +18 -0
- package/Charting/Visuals/SciChartOverview.js +13 -7
- package/Charting/Visuals/SciChartPieSurface/PieSegment/PieSegment.js +1 -1
- package/Charting/Visuals/SciChartPieSurface/SciChartPieSurface.js +27 -24
- package/Charting/Visuals/SciChartSurface.js +20 -17
- package/Charting/Visuals/SciChartSurfaceBase.js +15 -11
- package/Charting/Visuals/TextureManager/CanvasTexture.js +5 -5
- package/Charting/Visuals/TextureManager/DpiHelper.js +3 -3
- package/Charting/Visuals/TextureManager/TextureManager.d.ts +1 -0
- package/Charting/Visuals/TextureManager/TextureManager.js +16 -12
- package/Charting/Visuals/createMaster.js +6 -5
- package/Charting/Visuals/createSingle.js +6 -4
- package/Charting/Visuals/licenseManager2D.js +65 -48
- package/Charting/Visuals/loader.js +1 -1
- package/Charting/Visuals/sciChartInitCommon.js +12 -12
- package/Charting3D/CameraController.js +6 -6
- package/Charting3D/ChartModifiers/ChartModifierBase3D.js +3 -1
- package/Charting3D/ChartModifiers/MouseWheelZoomModifier3D.js +3 -1
- package/Charting3D/ChartModifiers/OrbitModifier3D.js +3 -1
- package/Charting3D/ChartModifiers/ResetCamera3DModifier.d.ts +79 -0
- package/Charting3D/ChartModifiers/ResetCamera3DModifier.js +143 -0
- package/Charting3D/Model/DataSeries/BaseGridDataSeries3D.js +4 -2
- package/Charting3D/Model/DataSeries/UniformGridDataSeries3D.js +3 -1
- package/Charting3D/Model/DataSeries/XyzDataSeries3D.js +6 -4
- package/Charting3D/Vector3.js +1 -1
- package/Charting3D/Visuals/Axis/AxisBase3D.js +9 -7
- package/Charting3D/Visuals/Axis/AxisCubeEntity.js +20 -15
- package/Charting3D/Visuals/Axis/NumericAxis3D.d.ts +5 -0
- package/Charting3D/Visuals/Axis/NumericAxis3D.js +29 -1
- package/Charting3D/Visuals/DefaultViewportManager3D.js +3 -1
- package/Charting3D/Visuals/GizmoEntity.js +3 -1
- package/Charting3D/Visuals/PointMarkers/BaseMeshPointMarker3D.js +3 -1
- package/Charting3D/Visuals/PointMarkers/BaseTexturePointMarker3D.js +3 -1
- package/Charting3D/Visuals/PointMarkers/DefaultPointMarkers.js +3 -1
- package/Charting3D/Visuals/Primitives/BaseSceneEntity3D.js +2 -2
- package/Charting3D/Visuals/Primitives/RenderableSeriesSceneEntity.js +3 -1
- package/Charting3D/Visuals/Primitives/ScatterPointsSceneEntity.js +7 -5
- package/Charting3D/Visuals/Primitives/SurfaceMeshSceneEntity.js +22 -20
- package/Charting3D/Visuals/RenderableSeries/BaseRenderableSeries3D.js +3 -3
- package/Charting3D/Visuals/RenderableSeries/ScatterRenderableSeries3D.js +3 -1
- package/Charting3D/Visuals/RenderableSeries/SurfaceMesh/GradientColorPalette.js +3 -1
- package/Charting3D/Visuals/RenderableSeries/SurfaceMesh/SolidColorBrushPalette.js +5 -3
- package/Charting3D/Visuals/RenderableSeries/SurfaceMesh/SurfaceMeshRenderableSeries3D.js +3 -1
- package/Charting3D/Visuals/RootSceneEntity.js +3 -1
- package/Charting3D/Visuals/SciChart3DRenderer.d.ts +1 -0
- package/Charting3D/Visuals/SciChart3DRenderer.js +10 -2
- package/Charting3D/Visuals/SciChart3DSurface.d.ts +22 -0
- package/Charting3D/Visuals/SciChart3DSurface.js +64 -11
- package/Charting3D/Visuals/createMaster3d.js +8 -7
- package/Charting3D/Visuals/createSingle3d.js +5 -4
- package/Charting3D/Visuals/licenseManager3D.js +7 -6
- package/Core/Animations/AnimationFiniteStateMachine.js +4 -2
- package/Core/Animations/DoubleAnimator.js +1 -1
- package/Core/Animations/GenericAnimation.js +1 -1
- package/Core/Guard.js +4 -4
- package/Core/Mouse/MouseManager.js +1 -1
- package/Core/NumberRange.js +4 -4
- package/Core/Point.js +1 -1
- package/_wasm/scichart.browser.js +1 -1
- package/_wasm/scichart2d.js +1 -1
- package/_wasm/scichart2d.wasm +0 -0
- package/_wasm/scichart3d.js +95 -95
- package/_wasm/scichart3d.wasm +0 -0
- package/index.js +1 -0
- package/package.json +2 -2
- package/types/AxisAlignment.js +6 -4
- package/types/ChartModifierType.d.ts +2 -1
- package/types/ChartModifierType.js +1 -0
- package/utils/array.js +2 -1
- package/utils/calcAverage.js +4 -2
- package/utils/colorUtil.js +4 -4
- package/utils/convertColor.js +6 -4
- package/utils/convertToPixel.js +2 -1
- package/utils/date.js +26 -17
- package/utils/font.js +4 -3
- package/utils/guid.js +2 -1
- package/utils/hasAllProperties.js +2 -1
- package/utils/includedAxis.d.ts +3 -0
- package/utils/includedAxis.js +23 -0
- package/utils/math.js +6 -3
- package/utils/number.js +18 -13
- package/utils/parseColor.js +7 -5
- package/utils/pointUtil.js +24 -15
- package/utils/random.js +2 -1
- package/utils/randomPricesDataSource.js +7 -5
- package/utils/svgString.js +2 -1
- package/utils/translate.js +10 -5
- package/utils/tsrExtensions.js +4 -2
- package/utils/zeroArray2D.js +3 -2
|
@@ -40,7 +40,7 @@ var DpiHelper = /** @class */ (function () {
|
|
|
40
40
|
var lastDpiScaling = DpiHelper.PIXEL_RATIO;
|
|
41
41
|
if (lastDpiScaling !== newDpiScale) {
|
|
42
42
|
if (SciChartSurfaceBase_1.DebugForDpi) {
|
|
43
|
-
console.log("Dpi Changing, was "
|
|
43
|
+
console.log("Dpi Changing, was ".concat(lastDpiScaling, ", now ").concat(newDpiScale));
|
|
44
44
|
}
|
|
45
45
|
DpiHelper.PIXEL_RATIO = newDpiScale;
|
|
46
46
|
DpiHelper.dpiChanged.raiseEvent({ newValue: newDpiScale, oldValue: lastDpiScaling });
|
|
@@ -81,7 +81,7 @@ var DpiHelper = /** @class */ (function () {
|
|
|
81
81
|
*/
|
|
82
82
|
DpiHelper.setWidth = function (canvas, desiredWidth) {
|
|
83
83
|
if (SciChartSurfaceBase_1.DebugForDpi) {
|
|
84
|
-
console.log("setWidth "
|
|
84
|
+
console.log("setWidth ".concat(canvas.id, " backBuffer=").concat(desiredWidth * DpiHelper.PIXEL_RATIO, " display=").concat(desiredWidth));
|
|
85
85
|
}
|
|
86
86
|
// https://www.khronos.org/webgl/wiki/HandlingHighDPI
|
|
87
87
|
//
|
|
@@ -97,7 +97,7 @@ var DpiHelper = /** @class */ (function () {
|
|
|
97
97
|
*/
|
|
98
98
|
DpiHelper.setHeight = function (canvas, desiredHeight) {
|
|
99
99
|
if (SciChartSurfaceBase_1.DebugForDpi) {
|
|
100
|
-
console.log("setHeight "
|
|
100
|
+
console.log("setHeight ".concat(canvas.id, " backBuffer=").concat(desiredHeight * DpiHelper.PIXEL_RATIO, " display=").concat(desiredHeight));
|
|
101
101
|
}
|
|
102
102
|
// https://www.khronos.org/webgl/wiki/HandlingHighDPI
|
|
103
103
|
//
|
|
@@ -35,6 +35,7 @@ export declare class TextureManager implements IDeletable {
|
|
|
35
35
|
createTextureFromImage(image: HTMLImageElement, imageWidth: number, imageHeight: number): TTextureObject;
|
|
36
36
|
getTextureContext(width: number, height: number): CanvasRenderingContext2D;
|
|
37
37
|
createTextureFromCtxBuffer(textureWidth: number, textureHeight: number): TTextureObject;
|
|
38
|
+
createTextureFromImageData(imageData: ImageData, textureWidth: number, textureHeight: number): TTextureObject;
|
|
38
39
|
delete(): void;
|
|
39
40
|
private createTextureFromCtx;
|
|
40
41
|
}
|
|
@@ -56,15 +56,15 @@ var TextureManager = /** @class */ (function () {
|
|
|
56
56
|
this.ctx.fillRect(0, 0, this.canvas.width, this.canvas.height);
|
|
57
57
|
}
|
|
58
58
|
this.ctx.fillStyle = color;
|
|
59
|
-
this.ctx.font = font_1.getFontString(fontStyle, fontWeight, fontSizePx, fontFamily);
|
|
59
|
+
this.ctx.font = (0, font_1.getFontString)(fontStyle, fontWeight, fontSizePx, fontFamily);
|
|
60
60
|
var textureWidth = 0;
|
|
61
61
|
// const fontSizePt = Math.ceil(fontSizePx * PX_TO_PT);
|
|
62
|
-
var lineHeight = exports.measureTextHeight(fontSizePx);
|
|
62
|
+
var lineHeight = (0, exports.measureTextHeight)(fontSizePx);
|
|
63
63
|
var extraLineHeight = lineHeight * (lineSpacing !== null && lineSpacing !== void 0 ? lineSpacing : 1.1);
|
|
64
64
|
var textureHeight = lineHeight + padding.top + padding.bottom;
|
|
65
65
|
for (var index = 0; index < text.length; index++) {
|
|
66
66
|
var line = text[index];
|
|
67
|
-
var lineWidth = exports.measureTextWidth(this.ctx, line) + padding.left + padding.right;
|
|
67
|
+
var lineWidth = (0, exports.measureTextWidth)(this.ctx, line) + padding.left + padding.right;
|
|
68
68
|
if (lineWidth > textureWidth) {
|
|
69
69
|
textureWidth = lineWidth;
|
|
70
70
|
}
|
|
@@ -96,7 +96,7 @@ var TextureManager = /** @class */ (function () {
|
|
|
96
96
|
for (var _i = 0, text_1 = text; _i < text_1.length; _i++) {
|
|
97
97
|
var line = text_1[_i];
|
|
98
98
|
if (alignment === LabelAlignment_1.ELabelAlignment.Center || alignment === LabelAlignment_1.ELabelAlignment.Right) {
|
|
99
|
-
var lineWidth = exports.measureTextWidth(this.ctx, line);
|
|
99
|
+
var lineWidth = (0, exports.measureTextWidth)(this.ctx, line);
|
|
100
100
|
x =
|
|
101
101
|
alignment === LabelAlignment_1.ELabelAlignment.Right
|
|
102
102
|
? textureWidth - lineWidth - padding.right
|
|
@@ -118,9 +118,9 @@ var TextureManager = /** @class */ (function () {
|
|
|
118
118
|
this.ctx.globalAlpha = opacity !== null && opacity !== void 0 ? opacity : 1;
|
|
119
119
|
this.ctx.textBaseline = "top";
|
|
120
120
|
this.ctx.clearRect(0, 0, this.canvas.width, this.canvas.height);
|
|
121
|
-
this.ctx.font = font_1.getFontString(fontStyle, fontWeight, fontSizePx, fontFamily);
|
|
122
|
-
var textureWidth = exports.measureTextWidth(this.ctx, text) + 4 * padding;
|
|
123
|
-
var textureHeight = exports.measureTextHeight(fontSizePx) + 2 * padding;
|
|
121
|
+
this.ctx.font = (0, font_1.getFontString)(fontStyle, fontWeight, fontSizePx, fontFamily);
|
|
122
|
+
var textureWidth = (0, exports.measureTextWidth)(this.ctx, text) + 4 * padding;
|
|
123
|
+
var textureHeight = (0, exports.measureTextHeight)(fontSizePx) + 2 * padding;
|
|
124
124
|
var _a = calcAxisMarkerTextureParams(textureHeight, textureWidth, text, axisAlignment), angle = _a.angle, alignmentLeft = _a.alignmentLeft, alignmentTop = _a.alignmentTop, finalTextureWidth = _a.finalTextureWidth, finalTextureHeight = _a.finalTextureHeight, halfHeight = _a.halfHeight;
|
|
125
125
|
this.ctx.save();
|
|
126
126
|
this.ctx.translate((textureWidth + halfHeight) / 2, textureHeight / 2);
|
|
@@ -178,13 +178,15 @@ var TextureManager = /** @class */ (function () {
|
|
|
178
178
|
return this.ctx;
|
|
179
179
|
};
|
|
180
180
|
TextureManager.prototype.createTextureFromCtxBuffer = function (textureWidth, textureHeight) {
|
|
181
|
-
|
|
182
|
-
|
|
181
|
+
var imageData = this.ctx.getImageData(0, 0, textureWidth, textureHeight);
|
|
182
|
+
return this.createTextureFromImageData(imageData, textureWidth, textureHeight);
|
|
183
|
+
};
|
|
184
|
+
TextureManager.prototype.createTextureFromImageData = function (imageData, textureWidth, textureHeight) {
|
|
183
185
|
var textureFormat = this.webAssemblyContext.eTSRTextureFormat.TSR_TEXTUREFORMAT_A8B8G8R8;
|
|
184
186
|
var bitmapTexture = this.webAssemblyContext.SCRTCreateBitmapTexture(textureWidth, textureHeight, textureFormat);
|
|
185
187
|
var buffer;
|
|
186
188
|
try {
|
|
187
|
-
|
|
189
|
+
// const imageData = this.ctx.getImageData(0, 0, textureWidth, textureHeight);
|
|
188
190
|
var clampedCharArray = imageData.data;
|
|
189
191
|
/// because plain c functions were receiving the object pointer as null, this is the way around that...
|
|
190
192
|
this.webAssemblyContext.SCRTSetActiveTexture(bitmapTexture);
|
|
@@ -258,11 +260,13 @@ var TextureManager = /** @class */ (function () {
|
|
|
258
260
|
return TextureManager;
|
|
259
261
|
}());
|
|
260
262
|
exports.TextureManager = TextureManager;
|
|
261
|
-
|
|
262
|
-
exports.
|
|
263
|
+
var measureTextHeight = function (fontSizePx) { return fontSizePx; };
|
|
264
|
+
exports.measureTextHeight = measureTextHeight;
|
|
265
|
+
var measureTextWidth = function (ctx, text) {
|
|
263
266
|
var textMeasure = ctx.measureText(text);
|
|
264
267
|
return Math.ceil(textMeasure.width);
|
|
265
268
|
};
|
|
269
|
+
exports.measureTextWidth = measureTextWidth;
|
|
266
270
|
/** @ignore */
|
|
267
271
|
var calcAxisMarkerTextureParams = function (textureHeight, textureWidth, text, axisAlignment) {
|
|
268
272
|
var halfHeight = Math.ceil(textureHeight / 2);
|
|
@@ -56,7 +56,7 @@ var sciChartMaster = {
|
|
|
56
56
|
/** @ignore */
|
|
57
57
|
var sciChartMasterPromise;
|
|
58
58
|
/** @ignore */
|
|
59
|
-
|
|
59
|
+
var createMultichart = function (divElementId, options) { return __awaiter(void 0, void 0, void 0, function () {
|
|
60
60
|
var canvases, loader, loaderDiv, master, createChildSurface, wasmContext, sciChartSurface;
|
|
61
61
|
var _a, _b, _c;
|
|
62
62
|
return __generator(this, function (_d) {
|
|
@@ -90,6 +90,7 @@ exports.createMultichart = function (divElementId, options) { return __awaiter(v
|
|
|
90
90
|
}
|
|
91
91
|
});
|
|
92
92
|
}); };
|
|
93
|
+
exports.createMultichart = createMultichart;
|
|
93
94
|
/** @ignore */
|
|
94
95
|
var monitorWebGL = function (master) {
|
|
95
96
|
var wasmContext = sciChartMaster.wasmContext, getChildSurfaces = sciChartMaster.getChildSurfaces;
|
|
@@ -134,7 +135,7 @@ var createMaster = function () {
|
|
|
134
135
|
return sciChartSurface;
|
|
135
136
|
};
|
|
136
137
|
var addDestination = function (wasmContext, canvasElementId, sciChartSurface, width, height, chartInitObj) {
|
|
137
|
-
var newDestination = SciChartSurfaceBase_1.createChartDestination(canvasElementId);
|
|
138
|
+
var newDestination = (0, SciChartSurfaceBase_1.createChartDestination)(canvasElementId);
|
|
138
139
|
if (!newDestination) {
|
|
139
140
|
sciChartSurface.delete();
|
|
140
141
|
return;
|
|
@@ -146,8 +147,8 @@ var createMaster = function () {
|
|
|
146
147
|
};
|
|
147
148
|
return new Promise(function (resolve) {
|
|
148
149
|
// make sure canvas has event listener for context creation error
|
|
149
|
-
var canvas = SciChartSurfaceBase_1.getMasterCanvas();
|
|
150
|
-
var locateFile = SciChartSurfaceBase_1.getLocateFile(SciChartSurface_1.sciChartConfig);
|
|
150
|
+
var canvas = (0, SciChartSurfaceBase_1.getMasterCanvas)();
|
|
151
|
+
var locateFile = (0, SciChartSurfaceBase_1.getLocateFile)(SciChartSurface_1.sciChartConfig);
|
|
151
152
|
// @ts-ignore
|
|
152
153
|
new WasmModule2D({ locateFile: locateFile, noInitialRun: true }).then(function (wasmContext) {
|
|
153
154
|
var getChildSurfaces = function () { return exports.sciChartDestinations.map(function (el) { return el.sciChartSurface; }); };
|
|
@@ -198,7 +199,7 @@ var createMaster = function () {
|
|
|
198
199
|
wasmContext.SCRTSetGlobalSampleChartInterface(chartInitObj);
|
|
199
200
|
/// create an object that native side can trigger the copy to from...
|
|
200
201
|
var canvasCopyObj = wasmContext.SCRTCopyToDestinationInterface.implement({
|
|
201
|
-
CopyToDestination: SciChartSurfaceBase_1.copyToCanvas(SciChartSurfaceBase_1.SciChartSurfaceBase.domMasterCanvas)
|
|
202
|
+
CopyToDestination: (0, SciChartSurfaceBase_1.copyToCanvas)(SciChartSurfaceBase_1.SciChartSurfaceBase.domMasterCanvas)
|
|
202
203
|
});
|
|
203
204
|
wasmContext.SCRTSetGlobalCopyToDestinationInterface(canvasCopyObj);
|
|
204
205
|
wasmContext.TSRSetDrawRequestsEnabled(true);
|
|
@@ -14,7 +14,7 @@ var SciChartSurfaceBase_1 = require("./SciChartSurfaceBase");
|
|
|
14
14
|
// Global variables
|
|
15
15
|
exports.sciChartSingleDestinations = [];
|
|
16
16
|
/** @ignore */
|
|
17
|
-
|
|
17
|
+
var createSingleInternal = function (divElementId, options) {
|
|
18
18
|
return new Promise(function (resolve) {
|
|
19
19
|
var _a;
|
|
20
20
|
var canvases = sciChartInitCommon_1.default.initCanvas(divElementId, options === null || options === void 0 ? void 0 : options.widthAspect, options === null || options === void 0 ? void 0 : options.heightAspect);
|
|
@@ -23,13 +23,13 @@ exports.createSingleInternal = function (divElementId, options) {
|
|
|
23
23
|
var webGLSupport = WebGlHelper_1.WebGlHelper.getWebGlSupport();
|
|
24
24
|
// console.log("webGLSupport", webGLSupport);
|
|
25
25
|
if (webGLSupport === WebGlHelper_1.EWebGLSupport.WebGL2 || webGLSupport === WebGlHelper_1.EWebGLSupport.WebGL1) {
|
|
26
|
-
var locateFile = SciChartSurfaceBase_1.getLocateFile(SciChartSurface_1.sciChartConfig);
|
|
26
|
+
var locateFile = (0, SciChartSurfaceBase_1.getLocateFile)(SciChartSurface_1.sciChartConfig);
|
|
27
27
|
// @ts-ignore
|
|
28
28
|
new WasmModule2D({ locateFile: locateFile, noInitialRun: true }).then(function (wasmContext) {
|
|
29
29
|
loader.removeChartLoader(canvases.domDivContainer, loaderDiv);
|
|
30
30
|
// @ts-ignore
|
|
31
31
|
wasmContext.doNotCaptureKeyboard = true;
|
|
32
|
-
exports.initDrawEngineSingleChart(wasmContext, canvases, resolve, options === null || options === void 0 ? void 0 : options.theme);
|
|
32
|
+
(0, exports.initDrawEngineSingleChart)(wasmContext, canvases, resolve, options === null || options === void 0 ? void 0 : options.theme);
|
|
33
33
|
});
|
|
34
34
|
}
|
|
35
35
|
else {
|
|
@@ -37,8 +37,9 @@ exports.createSingleInternal = function (divElementId, options) {
|
|
|
37
37
|
}
|
|
38
38
|
});
|
|
39
39
|
};
|
|
40
|
+
exports.createSingleInternal = createSingleInternal;
|
|
40
41
|
/** @ignore */
|
|
41
|
-
|
|
42
|
+
var initDrawEngineSingleChart = function (wasmContext, canvases, resolve, theme) {
|
|
42
43
|
Guard_1.Guard.notNull(theme, "theme");
|
|
43
44
|
var width = canvases.domCanvas2D.width;
|
|
44
45
|
var height = canvases.domCanvas2D.height;
|
|
@@ -81,3 +82,4 @@ exports.initDrawEngineSingleChart = function (wasmContext, canvases, resolve, th
|
|
|
81
82
|
// @ts-ignore
|
|
82
83
|
wasmContext.callMain();
|
|
83
84
|
};
|
|
85
|
+
exports.initDrawEngineSingleChart = initDrawEngineSingleChart;
|
|
@@ -93,13 +93,14 @@ var fetchFromWizard = function (path) { return __awaiter(void 0, void 0, void 0,
|
|
|
93
93
|
}); };
|
|
94
94
|
var licenseDependencies = {
|
|
95
95
|
fetchFromWizard: function (url) { return fetchFromWizard(url); },
|
|
96
|
-
setCookie: function (name, val, validDays) { return cookie_1.setCookie(name, val, validDays); },
|
|
97
|
-
getCookie: function (name) { return cookie_1.getCookie(name); },
|
|
96
|
+
setCookie: function (name, val, validDays) { return (0, cookie_1.setCookie)(name, val, validDays); },
|
|
97
|
+
getCookie: function (name) { return (0, cookie_1.getCookie)(name); },
|
|
98
98
|
fetchForChallenge: function (url) { return fetch(url); },
|
|
99
99
|
updateLicenseDisplay: function (licenseInfo, sciChartSurface, is2D, applyToOther) { return updateLicenseDisplayInternal(licenseInfo, sciChartSurface, is2D, applyToOther); },
|
|
100
100
|
debug: function (message) { return console.log(message); }
|
|
101
101
|
};
|
|
102
|
-
|
|
102
|
+
var setDependencies = function (dependencies) { return (licenseDependencies = dependencies); };
|
|
103
|
+
exports.setDependencies = setDependencies;
|
|
103
104
|
var isDebug = null;
|
|
104
105
|
var debug = function (message) {
|
|
105
106
|
if (isDebug === null) {
|
|
@@ -111,24 +112,27 @@ var debug = function (message) {
|
|
|
111
112
|
};
|
|
112
113
|
// tslint:disable: no-console
|
|
113
114
|
var licenseCallback;
|
|
114
|
-
|
|
115
|
+
var setLicenseCallback = function (callback) {
|
|
115
116
|
licenseCallback = callback;
|
|
116
117
|
};
|
|
118
|
+
exports.setLicenseCallback = setLicenseCallback;
|
|
117
119
|
var runtimeLicenseKey = "";
|
|
118
120
|
var getRuntimeLicenseKey = function () { return runtimeLicenseKey; };
|
|
119
|
-
|
|
121
|
+
var setRuntimeLicenseKey = function (value) {
|
|
120
122
|
var prev = runtimeLicenseKey;
|
|
121
123
|
runtimeLicenseKey = value;
|
|
122
124
|
if (runtimeLicenseKey !== prev && runtimeLicenseKey !== "") {
|
|
123
125
|
if (licenseContext2D !== undefined) {
|
|
124
|
-
exports.applyLicense(licenseContext2D);
|
|
126
|
+
(0, exports.applyLicense)(licenseContext2D);
|
|
125
127
|
}
|
|
126
128
|
}
|
|
127
129
|
};
|
|
130
|
+
exports.setRuntimeLicenseKey = setRuntimeLicenseKey;
|
|
128
131
|
var useLicenseWizard = true;
|
|
129
|
-
|
|
132
|
+
var setUseLicenseWizard = function (value) {
|
|
130
133
|
useLicenseWizard = value;
|
|
131
134
|
};
|
|
135
|
+
exports.setUseLicenseWizard = setUseLicenseWizard;
|
|
132
136
|
var retryTime = app_1.IS_TEST_ENV ? 0.1 : 5;
|
|
133
137
|
var maxretries = app_1.IS_TEST_ENV ? 12 : 10;
|
|
134
138
|
var serverLicenseEndpoint = "api/license";
|
|
@@ -144,7 +148,8 @@ var callbacks3D = {
|
|
|
144
148
|
setNewLicense3D: function (keyCode) { return undefined; },
|
|
145
149
|
updateLicenseDisplay3D: function () { return undefined; }
|
|
146
150
|
};
|
|
147
|
-
|
|
151
|
+
var setCallbacks3D = function (callbacks) { return (callbacks3D = callbacks); };
|
|
152
|
+
exports.setCallbacks3D = setCallbacks3D;
|
|
148
153
|
var getlicenseFromWizard = function () { return __awaiter(void 0, void 0, void 0, function () {
|
|
149
154
|
var response, keyCode, _a, requiresValidation, trialExpired, err_3;
|
|
150
155
|
return __generator(this, function (_b) {
|
|
@@ -170,7 +175,7 @@ var getlicenseFromWizard = function () { return __awaiter(void 0, void 0, void 0
|
|
|
170
175
|
}
|
|
171
176
|
else if (trialExpired) {
|
|
172
177
|
checkStatus = licensingClasses_1.LicenseCheckStatus.NoLicenseInWizard;
|
|
173
|
-
debug("No valid license available in licensing wizard. Trying again in "
|
|
178
|
+
debug("No valid license available in licensing wizard. Trying again in ".concat(retryTime, " seconds"));
|
|
174
179
|
wizardTimer = setTimeout(function () { return getlicenseFromWizard(); }, retryTime * 1000);
|
|
175
180
|
}
|
|
176
181
|
else {
|
|
@@ -179,7 +184,7 @@ var getlicenseFromWizard = function () { return __awaiter(void 0, void 0, void 0
|
|
|
179
184
|
return [3 /*break*/, 4];
|
|
180
185
|
case 3:
|
|
181
186
|
checkStatus = licensingClasses_1.LicenseCheckStatus.NoLicenseInWizard;
|
|
182
|
-
debug("No license available in licensing wizard. Trying again in "
|
|
187
|
+
debug("No license available in licensing wizard. Trying again in ".concat(retryTime, " seconds"));
|
|
183
188
|
wizardTimer = setTimeout(function () { return getlicenseFromWizard(); }, retryTime * 1000);
|
|
184
189
|
_b.label = 4;
|
|
185
190
|
case 4: return [3 /*break*/, 6];
|
|
@@ -188,7 +193,7 @@ var getlicenseFromWizard = function () { return __awaiter(void 0, void 0, void 0
|
|
|
188
193
|
// Failed to connect. Retry
|
|
189
194
|
getLicenseFailCounts += 1;
|
|
190
195
|
if (getLicenseFailCounts < maxretries) {
|
|
191
|
-
debug("Could not find licensing wizard. Trying again in "
|
|
196
|
+
debug("Could not find licensing wizard. Trying again in ".concat(retryTime, " seconds"));
|
|
192
197
|
setTimeout(function () { return getlicenseFromWizard(); }, retryTime * 1000);
|
|
193
198
|
}
|
|
194
199
|
else {
|
|
@@ -200,7 +205,7 @@ var getlicenseFromWizard = function () { return __awaiter(void 0, void 0, void 0
|
|
|
200
205
|
return [3 /*break*/, 6];
|
|
201
206
|
case 6:
|
|
202
207
|
if (licenseContext2D !== undefined) {
|
|
203
|
-
exports.updateLicenseDisplay(exports.getLicenseInfo(licenseContext2D), sciChartSurface2D, true, true);
|
|
208
|
+
(0, exports.updateLicenseDisplay)((0, exports.getLicenseInfo)(licenseContext2D), sciChartSurface2D, true, true);
|
|
204
209
|
}
|
|
205
210
|
callbacks3D.updateLicenseDisplay3D();
|
|
206
211
|
return [2 /*return*/];
|
|
@@ -208,10 +213,10 @@ var getlicenseFromWizard = function () { return __awaiter(void 0, void 0, void 0
|
|
|
208
213
|
});
|
|
209
214
|
}); };
|
|
210
215
|
var setLicenseCookie = function (key, token, expirySeconds, lastValidated) {
|
|
211
|
-
var cookieVal = key
|
|
216
|
+
var cookieVal = "".concat(key, ",").concat(token, ",").concat(expirySeconds, ",").concat(lastValidated);
|
|
212
217
|
return licenseDependencies.setCookie("scLicense", cookieVal, 365);
|
|
213
218
|
};
|
|
214
|
-
|
|
219
|
+
var getLicenseCookie = function () {
|
|
215
220
|
var cookie;
|
|
216
221
|
cookie = licenseDependencies.getCookie("scLicense");
|
|
217
222
|
var parts = cookie.split(",");
|
|
@@ -226,9 +231,10 @@ exports.getLicenseCookie = function () {
|
|
|
226
231
|
else
|
|
227
232
|
return { key: parts[0], token: null, expiry: null, lastValidated: null };
|
|
228
233
|
};
|
|
234
|
+
exports.getLicenseCookie = getLicenseCookie;
|
|
229
235
|
var refreshLicense = function () {
|
|
230
|
-
cookie_1.deleteCookie("scLicense");
|
|
231
|
-
exports.applyLicense(licenseContext2D);
|
|
236
|
+
(0, cookie_1.deleteCookie)("scLicense");
|
|
237
|
+
(0, exports.applyLicense)(licenseContext2D);
|
|
232
238
|
};
|
|
233
239
|
var setChallengeResponse = function (token) {
|
|
234
240
|
var expirySeconds = -1;
|
|
@@ -253,7 +259,7 @@ var dolicenseChallenge = function () { return __awaiter(void 0, void 0, void 0,
|
|
|
253
259
|
_b.trys.push([1, 11, , 12]);
|
|
254
260
|
if (checkStatus !== licensingClasses_1.LicenseCheckStatus.ValidatingDeveloperLicense)
|
|
255
261
|
return [2 /*return*/];
|
|
256
|
-
debug("Attempting to validate license with "
|
|
262
|
+
debug("Attempting to validate license with ".concat(server));
|
|
257
263
|
challenge = void 0;
|
|
258
264
|
orderId = void 0;
|
|
259
265
|
if (licenseContext2D !== undefined) {
|
|
@@ -264,9 +270,9 @@ var dolicenseChallenge = function () { return __awaiter(void 0, void 0, void 0,
|
|
|
264
270
|
(_a = callbacks3D.getLicenseChallenge3D(), challenge = _a.challenge, orderId = _a.orderId);
|
|
265
271
|
}
|
|
266
272
|
response = void 0;
|
|
267
|
-
queryString = "orderid="
|
|
273
|
+
queryString = "orderid=".concat(orderId, "&challenge=").concat(challenge);
|
|
268
274
|
if (!isDev) return [3 /*break*/, 3];
|
|
269
|
-
url = "/validate?"
|
|
275
|
+
url = "/validate?".concat(queryString);
|
|
270
276
|
return [4 /*yield*/, licenseDependencies.fetchFromWizard(url)];
|
|
271
277
|
case 2:
|
|
272
278
|
response = _b.sent();
|
|
@@ -291,7 +297,7 @@ var dolicenseChallenge = function () { return __awaiter(void 0, void 0, void 0,
|
|
|
291
297
|
if (!token.startsWith("Error")) {
|
|
292
298
|
expirySeconds = setChallengeResponse(token);
|
|
293
299
|
if (expirySeconds > 0) {
|
|
294
|
-
key = exports.getLicenseCookie().key;
|
|
300
|
+
key = (0, exports.getLicenseCookie)().key;
|
|
295
301
|
timeNow = Math.floor(new Date().getTime() / 1000);
|
|
296
302
|
setLicenseCookie(key, token, expirySeconds, timeNow);
|
|
297
303
|
checkStatus = licensingClasses_1.LicenseCheckStatus.LicenseOK;
|
|
@@ -322,15 +328,15 @@ var dolicenseChallenge = function () { return __awaiter(void 0, void 0, void 0,
|
|
|
322
328
|
// Failed to connect. Retry
|
|
323
329
|
challengeFailCounts += 1;
|
|
324
330
|
if (challengeFailCounts < maxretries) {
|
|
325
|
-
debug("Could not find "
|
|
331
|
+
debug("Could not find ".concat(server, "/").concat(serverLicenseEndpoint, ". Trying again in ").concat(retryTime, " seconds"));
|
|
326
332
|
setTimeout(function () { return dolicenseChallenge(); }, retryTime * 1000);
|
|
327
333
|
}
|
|
328
334
|
else {
|
|
329
|
-
expiry = exports.getLicenseCookie().expiry;
|
|
335
|
+
expiry = (0, exports.getLicenseCookie)().expiry;
|
|
330
336
|
msg = isDev
|
|
331
337
|
? "Please run the license wizard, ensure your license is activated, then refresh page to retry."
|
|
332
338
|
: "Please check that the endpoint is configured correctly.";
|
|
333
|
-
console.error("Failed to connect to "
|
|
339
|
+
console.error("Failed to connect to ".concat(server, "/").concat(serverLicenseEndpoint, ". License must be revalidated before ").concat(expiry.toLocaleString(), ". ").concat(msg));
|
|
334
340
|
challengeFailCounts = 0;
|
|
335
341
|
// Only actually show failure message if token has expired
|
|
336
342
|
if (new Date() > expiry)
|
|
@@ -339,7 +345,7 @@ var dolicenseChallenge = function () { return __awaiter(void 0, void 0, void 0,
|
|
|
339
345
|
return [3 /*break*/, 12];
|
|
340
346
|
case 12:
|
|
341
347
|
if (licenseContext2D !== undefined) {
|
|
342
|
-
exports.updateLicenseDisplay(exports.getLicenseInfo(licenseContext2D), sciChartSurface2D, true, true);
|
|
348
|
+
(0, exports.updateLicenseDisplay)((0, exports.getLicenseInfo)(licenseContext2D), sciChartSurface2D, true, true);
|
|
343
349
|
}
|
|
344
350
|
callbacks3D.updateLicenseDisplay3D();
|
|
345
351
|
return [2 /*return*/];
|
|
@@ -357,12 +363,12 @@ var applyLicense2D = function (licenseContext, sciChartSurface, isSingle) {
|
|
|
357
363
|
if (isSingle || shouldApplyLicense2D) {
|
|
358
364
|
licenseContext2D = licenseContext;
|
|
359
365
|
sciChartSurface2D = sciChartSurface;
|
|
360
|
-
exports.applyLicense(licenseContext);
|
|
366
|
+
(0, exports.applyLicense)(licenseContext);
|
|
361
367
|
}
|
|
362
368
|
if (!isSingle)
|
|
363
369
|
shouldApplyLicense2D = false;
|
|
364
370
|
};
|
|
365
|
-
|
|
371
|
+
var applyLicense = function (licenseContext) {
|
|
366
372
|
debug("applyLicense running");
|
|
367
373
|
var licenseKey = "";
|
|
368
374
|
var lt = licenseContext.SCRTCredentials.GetLicenseType();
|
|
@@ -396,7 +402,7 @@ exports.applyLicense = function (licenseContext) {
|
|
|
396
402
|
}
|
|
397
403
|
}
|
|
398
404
|
// Get from cookie store
|
|
399
|
-
var licenseCookie = exports.getLicenseCookie();
|
|
405
|
+
var licenseCookie = (0, exports.getLicenseCookie)();
|
|
400
406
|
if (licenseKey === "" && licenseCookie && licenseCookie.key !== "") {
|
|
401
407
|
debug("Found license in cookie.");
|
|
402
408
|
licenseKey = licenseCookie.key;
|
|
@@ -407,7 +413,7 @@ exports.applyLicense = function (licenseContext) {
|
|
|
407
413
|
lt === licenseContext.SCRTLicenseType.LICENSE_TYPE_TRIAL ||
|
|
408
414
|
lt === licenseContext.SCRTLicenseType.LICENSE_TYPE_REQUIRES_VALIDATION)) {
|
|
409
415
|
debug("License cookie is invalid. Removing");
|
|
410
|
-
cookie_1.deleteCookie("scLicense");
|
|
416
|
+
(0, cookie_1.deleteCookie)("scLicense");
|
|
411
417
|
licenseKey = "";
|
|
412
418
|
lt = licenseContext.SCRTLicenseType.LICENSE_TYPE_NO_LICENSE;
|
|
413
419
|
}
|
|
@@ -432,7 +438,7 @@ exports.applyLicense = function (licenseContext) {
|
|
|
432
438
|
if (isRuntimeKey && isDev) {
|
|
433
439
|
// clear key
|
|
434
440
|
licenseContext.SCRTCredentials.ResetRuntimeLicense();
|
|
435
|
-
cookie_1.deleteCookie("scLicense");
|
|
441
|
+
(0, cookie_1.deleteCookie)("scLicense");
|
|
436
442
|
checkStatus = licensingClasses_1.LicenseCheckStatus.DevKeyInRuntimeKey;
|
|
437
443
|
}
|
|
438
444
|
else if (licenseCookie.expiry > new Date()) {
|
|
@@ -449,7 +455,7 @@ exports.applyLicense = function (licenseContext) {
|
|
|
449
455
|
}
|
|
450
456
|
var validationInterval = 60 * 60 * 24; // Once a day
|
|
451
457
|
var secondsSinceValidated = (new Date().getTime() - licenseCookie.lastValidated.getTime()) / 1000;
|
|
452
|
-
debug("License expires in "
|
|
458
|
+
debug("License expires in ".concat(expirySeconds - timeNow, " seconds. Last validated ").concat(secondsSinceValidated, " seconds ago"));
|
|
453
459
|
if (secondsSinceValidated > validationInterval &&
|
|
454
460
|
checkStatus !== licensingClasses_1.LicenseCheckStatus.ValidatingDeveloperLicense) {
|
|
455
461
|
checkStatus = licensingClasses_1.LicenseCheckStatus.ValidatingDeveloperLicense;
|
|
@@ -474,10 +480,11 @@ exports.applyLicense = function (licenseContext) {
|
|
|
474
480
|
}
|
|
475
481
|
}
|
|
476
482
|
if (licenseContext2D !== undefined) {
|
|
477
|
-
exports.updateLicenseDisplay(exports.getLicenseInfo(licenseContext2D), sciChartSurface2D, true, false);
|
|
483
|
+
(0, exports.updateLicenseDisplay)((0, exports.getLicenseInfo)(licenseContext2D), sciChartSurface2D, true, false);
|
|
478
484
|
}
|
|
479
485
|
callbacks3D.updateLicenseDisplay3D();
|
|
480
486
|
};
|
|
487
|
+
exports.applyLicense = applyLicense;
|
|
481
488
|
var licenseModal;
|
|
482
489
|
var openLicenseModal = function () {
|
|
483
490
|
console.error("Modal not initialized");
|
|
@@ -494,7 +501,7 @@ var setNewLicense = function (keyCode) {
|
|
|
494
501
|
trialExpired =
|
|
495
502
|
licenseContext2D.SCRTCredentials.GetLicenseType() ===
|
|
496
503
|
licenseContext2D.SCRTLicenseType.LICENSE_TYPE_TRIAL_EXPIRED;
|
|
497
|
-
exports.updateLicenseDisplay(exports.getLicenseInfo(licenseContext2D), sciChartSurface2D, true, true);
|
|
504
|
+
(0, exports.updateLicenseDisplay)((0, exports.getLicenseInfo)(licenseContext2D), sciChartSurface2D, true, true);
|
|
498
505
|
}
|
|
499
506
|
var result3D = callbacks3D.setNewLicense3D(keyCode);
|
|
500
507
|
if (result3D !== undefined) {
|
|
@@ -658,14 +665,17 @@ var convertLicenseType = function (sclt, licenseContext) {
|
|
|
658
665
|
}
|
|
659
666
|
return licenseType;
|
|
660
667
|
};
|
|
661
|
-
|
|
668
|
+
var getLicenseInfo = function (licenseContext) {
|
|
662
669
|
var sclt = licenseContext.SCRTCredentials.GetLicenseType();
|
|
663
670
|
var licenseType = convertLicenseType(sclt, licenseContext);
|
|
664
671
|
var daysRemaining = licenseContext.SCRTCredentials.GetLicenseDaysRemaining();
|
|
665
|
-
|
|
672
|
+
if (isDebug) {
|
|
673
|
+
debug(licenseContext.SCRTCredentials.Dump());
|
|
674
|
+
}
|
|
666
675
|
var error = licenseContext.SCRTCredentials.GetLicenseErrors();
|
|
667
676
|
return { licenseType: licenseType, daysRemaining: daysRemaining, error: error };
|
|
668
677
|
};
|
|
678
|
+
exports.getLicenseInfo = getLicenseInfo;
|
|
669
679
|
var licenseType2D;
|
|
670
680
|
var licenseType3D;
|
|
671
681
|
var previousCheckStatus;
|
|
@@ -692,7 +702,7 @@ var updateLicenseDisplayInternal = function (licenseInfo, sciChartSurface, is2D,
|
|
|
692
702
|
licenseType3D = licenseType;
|
|
693
703
|
// if (licenseType === LicenseType.Trial || licenseType === LicenseType.Full)
|
|
694
704
|
// checkStatus = LicenseCheckStatus.LicenseOK;
|
|
695
|
-
debug((is2D ? "2D" : "3D"
|
|
705
|
+
debug("".concat(is2D ? "2D" : "3D", " license status changed"));
|
|
696
706
|
sciChartSurface.invalidateElement();
|
|
697
707
|
sciChartSurface.otherSurfaces.map(function (s) { return s.invalidateElement(); });
|
|
698
708
|
// Update license message text
|
|
@@ -700,18 +710,18 @@ var updateLicenseDisplayInternal = function (licenseInfo, sciChartSurface, is2D,
|
|
|
700
710
|
var contactSupportLink = "<a href=\"https://www.scichart.com/contact-us/\" target=\"_blank\" style=\"color: orange\">contact support</a>";
|
|
701
711
|
if (licenseType === licensingClasses_1.LicenseType.NoLicense) {
|
|
702
712
|
premsg = "You need to have a license to use SciChart. ";
|
|
703
|
-
postMsg = "Instructions can be seen at "
|
|
713
|
+
postMsg = "Instructions can be seen at ".concat(licensingLink);
|
|
704
714
|
}
|
|
705
715
|
else if (licenseType === licensingClasses_1.LicenseType.Invalid) {
|
|
706
716
|
if (error.startsWith("License is not valid for this domain"))
|
|
707
|
-
premsg = "Sorry! Your license key is invalid for this domain</br>Please "
|
|
717
|
+
premsg = "Sorry! Your license key is invalid for this domain</br>Please ".concat(contactSupportLink, " with your OrderID if you believe this to be incorrect.");
|
|
708
718
|
else
|
|
709
|
-
premsg = "Sorry! Your license key appears to be invalid</br>Please "
|
|
710
|
-
postMsg = "Instructions can be seen at "
|
|
719
|
+
premsg = "Sorry! Your license key appears to be invalid</br>Please ".concat(contactSupportLink, " with your OrderID if you believe this to be incorrect.");
|
|
720
|
+
postMsg = "Instructions can be seen at ".concat(licensingLink);
|
|
711
721
|
}
|
|
712
722
|
else if (licenseType === licensingClasses_1.LicenseType.Invalid_Developer) {
|
|
713
723
|
premsg = "Sorry! You need a developer license to use SciChart on a domain not included in your runtime key.";
|
|
714
|
-
postMsg = "Instructions can be seen at "
|
|
724
|
+
postMsg = "Instructions can be seen at ".concat(licensingLink, "</br>\n Please ").concat(contactSupportLink, " with your OrderID if you are experiencing issues.");
|
|
715
725
|
}
|
|
716
726
|
else if (licenseType === licensingClasses_1.LicenseType.Requres_Validation) {
|
|
717
727
|
if (isDev) {
|
|
@@ -720,18 +730,22 @@ var updateLicenseDisplayInternal = function (licenseInfo, sciChartSurface, is2D,
|
|
|
720
730
|
else {
|
|
721
731
|
premsg = "This runtime key must be validated by a server side key.";
|
|
722
732
|
}
|
|
723
|
-
postMsg = "Instructions can be seen at "
|
|
733
|
+
postMsg = "Instructions can be seen at ".concat(licensingLink, "</br>\n Please ").concat(contactSupportLink, " with your OrderID if you are experiencing issues.");
|
|
724
734
|
}
|
|
725
735
|
else if (licenseType === licensingClasses_1.LicenseType.Subscription_Expired) {
|
|
726
736
|
premsg = "Sorry! Your support subscription has expired.<br>";
|
|
727
|
-
postMsg = "Please "
|
|
737
|
+
postMsg = "Please ".concat(contactSupportLink, " us if you would like to renew your subscription.");
|
|
728
738
|
}
|
|
729
|
-
else if (licenseType === licensingClasses_1.LicenseType.Trial_Expired) {
|
|
739
|
+
else if (licenseType === licensingClasses_1.LicenseType.Trial_Expired && daysRemaining < 1) {
|
|
730
740
|
premsg = "Sorry! Your trial has expired.";
|
|
731
|
-
postMsg = "Please "
|
|
741
|
+
postMsg = "Please ".concat(contactSupportLink, " if you require an extension.");
|
|
742
|
+
}
|
|
743
|
+
else if (licenseType === licensingClasses_1.LicenseType.Trial_Expired && daysRemaining > 1) {
|
|
744
|
+
premsg = "This version is too old to trial.";
|
|
745
|
+
postMsg = "Please ".concat(contactSupportLink, " if you require an extension.");
|
|
732
746
|
}
|
|
733
747
|
else if (licenseType === licensingClasses_1.LicenseType.Trial && daysRemaining <= 7) {
|
|
734
|
-
premsg = "You have "
|
|
748
|
+
premsg = "You have ".concat(daysRemaining, " day").concat(daysRemaining === 1 ? "" : "s", " remaining of the trial.");
|
|
735
749
|
}
|
|
736
750
|
else if (licenseType === licensingClasses_1.LicenseType.Full || (licenseType === licensingClasses_1.LicenseType.Trial && daysRemaining > 7)) {
|
|
737
751
|
licenseMessageDiv.style.display = "none";
|
|
@@ -768,6 +782,8 @@ var updateLicenseDisplayInternal = function (licenseInfo, sciChartSurface, is2D,
|
|
|
768
782
|
else if (checkStatus === licensingClasses_1.LicenseCheckStatus.DevKeyInRuntimeKey)
|
|
769
783
|
chartmsg = "<br><u>You have set a developer key as a runtime key, which will not work on any other machine. Click for more information</u>";
|
|
770
784
|
// tslint:disable-next-line: max-line-length
|
|
785
|
+
else if (licenseType === licensingClasses_1.LicenseType.Trial_Expired && daysRemaining > 1)
|
|
786
|
+
chartmsg = "<br><u>Please update to the latest version of SciChart. Click for more information</u>.";
|
|
771
787
|
else if (checkStatus === licensingClasses_1.LicenseCheckStatus.NoLicenseInWizard &&
|
|
772
788
|
licenseType === licensingClasses_1.LicenseType.Trial_Expired) {
|
|
773
789
|
chartmsg = "<br><u>Please activate a serial key in the Licensing Wizard, or contact sales for an extension. Click for more information</u>.";
|
|
@@ -808,10 +824,11 @@ var updateLicenseDisplayInternal = function (licenseInfo, sciChartSurface, is2D,
|
|
|
808
824
|
});
|
|
809
825
|
}
|
|
810
826
|
};
|
|
811
|
-
|
|
827
|
+
var updateLicenseDisplay = function (licenseInfo, sciChartSurface, is2D, applyToOther) { return licenseDependencies.updateLicenseDisplay(licenseInfo, sciChartSurface, is2D, applyToOther); };
|
|
828
|
+
exports.updateLicenseDisplay = updateLicenseDisplay;
|
|
812
829
|
exports.licenseManager = {
|
|
813
|
-
setRuntimeLicenseKey: function (value) { return exports.setRuntimeLicenseKey(value); },
|
|
814
|
-
setLicenseCallback: function (callback) { return exports.setLicenseCallback(callback); },
|
|
830
|
+
setRuntimeLicenseKey: function (value) { return (0, exports.setRuntimeLicenseKey)(value); },
|
|
831
|
+
setLicenseCallback: function (callback) { return (0, exports.setLicenseCallback)(callback); },
|
|
815
832
|
setServerLicenseEndpoint: function (value) { return setServerLicenseEndpoint(value); },
|
|
816
833
|
applyLicense2D: function (licenseContext, sciChartSurface, isSingle) {
|
|
817
834
|
return applyLicense2D(licenseContext, sciChartSurface, isSingle);
|
|
@@ -27,7 +27,7 @@ var DefaultSciChartLoader = /** @class */ (function () {
|
|
|
27
27
|
loaderContainerDiv.style.height = "100%";
|
|
28
28
|
loaderContainerDiv.style.width = "100%";
|
|
29
29
|
var loaderDiv = document.createElement("div");
|
|
30
|
-
var spinnerChunk = "<div><span style=\"background: "
|
|
30
|
+
var spinnerChunk = "<div><span style=\"background: ".concat(theme.loadingAnimationForeground, "\"/></div>");
|
|
31
31
|
loaderDiv.innerHTML = spinnerChunk.repeat(8);
|
|
32
32
|
loaderDiv.classList.add("scichart_loader");
|
|
33
33
|
loaderContainerDiv.appendChild(loaderDiv);
|