highcharts 8.2.0 → 8.2.2

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 (731) hide show
  1. package/bower.json +1 -1
  2. package/es-modules/Accessibility/Accessibility.js +3 -2
  3. package/es-modules/Accessibility/AccessibilityComponent.js +7 -8
  4. package/es-modules/Accessibility/Components/ContainerComponent.js +6 -7
  5. package/es-modules/Accessibility/Components/InfoRegionsComponent.js +0 -1
  6. package/es-modules/Accessibility/Components/RangeSelectorComponent.js +4 -4
  7. package/es-modules/Accessibility/Components/SeriesComponent/ForcedMarkers.js +4 -4
  8. package/es-modules/Accessibility/Components/SeriesComponent/NewDataAnnouncer.js +3 -2
  9. package/es-modules/Accessibility/Components/SeriesComponent/SeriesDescriber.js +4 -4
  10. package/es-modules/Accessibility/Components/SeriesComponent/SeriesKeyboardNavigation.js +8 -6
  11. package/es-modules/Accessibility/Components/ZoomComponent.js +7 -6
  12. package/es-modules/Accessibility/KeyboardNavigation.js +7 -3
  13. package/es-modules/Accessibility/Options/Options.js +1 -2
  14. package/es-modules/Accessibility/Utils/ChartUtilities.js +4 -4
  15. package/es-modules/Accessibility/Utils/DOMElementProvider.js +3 -3
  16. package/es-modules/Accessibility/Utils/HTMLUtilities.js +2 -3
  17. package/es-modules/Core/Animation/AnimationUtilities.js +193 -0
  18. package/es-modules/Core/Animation/Fx.js +378 -0
  19. package/es-modules/Core/Axis/Axis.js +12 -6
  20. package/es-modules/Core/Axis/BrokenAxis.js +4 -6
  21. package/es-modules/Core/Axis/ColorAxis.js +11 -10
  22. package/es-modules/Core/Axis/GridAxis.js +113 -57
  23. package/es-modules/Core/Axis/OrdinalAxis.js +4 -5
  24. package/es-modules/Core/Axis/PlotLineOrBand.js +11 -4
  25. package/es-modules/Core/Axis/StackingAxis.js +3 -1
  26. package/es-modules/Core/Axis/TreeGridAxis.js +52 -7
  27. package/es-modules/Core/Chart/Chart.js +13 -8
  28. package/es-modules/Core/Chart/Chart3D.js +2 -1
  29. package/es-modules/Core/Chart/GanttChart.js +5 -9
  30. package/es-modules/Core/Chart/StockChart.js +6 -7
  31. package/es-modules/Core/Color/Color.js +419 -0
  32. package/es-modules/Core/Color/ColorType.js +9 -0
  33. package/es-modules/Core/Dynamics.js +54 -23
  34. package/es-modules/Core/Globals.js +1 -1
  35. package/es-modules/Core/Interaction.js +9 -6
  36. package/es-modules/Core/Legend.js +3 -1
  37. package/es-modules/Core/Navigator.js +8 -4
  38. package/es-modules/Core/Options.js +13 -11
  39. package/es-modules/Core/Pointer.js +2 -2
  40. package/es-modules/Core/Renderer/DOMElementType.js +9 -0
  41. package/es-modules/Core/Renderer/HTML/HTMLElement.js +220 -0
  42. package/es-modules/Core/Renderer/HTML/{HTML.js → HTMLRenderer.js} +8 -202
  43. package/es-modules/Core/Renderer/SVG/SVGElement.js +14 -8
  44. package/es-modules/Core/Renderer/SVG/SVGLabel.js +0 -1
  45. package/es-modules/Core/Renderer/SVG/SVGRenderer.js +2 -3
  46. package/es-modules/Core/Renderer/SVG/SVGRenderer3D.js +5 -3
  47. package/es-modules/Core/Series/BaseSeries.js +157 -0
  48. package/es-modules/Core/Series/CartesianSeries.js +5553 -0
  49. package/es-modules/Core/Series/DataLabels.js +11 -9
  50. package/es-modules/Core/Series/Point.js +5 -3
  51. package/es-modules/Core/Series/Series.js +138 -5528
  52. package/es-modules/Core/Series/Series3D.js +1 -1
  53. package/es-modules/Core/Tooltip.js +2 -1
  54. package/es-modules/Core/Utilities.js +0 -582
  55. package/es-modules/Extensions/Annotations/Annotations.js +4 -2
  56. package/es-modules/Extensions/Annotations/Mixins/ControllableMixin.js +3 -3
  57. package/es-modules/Extensions/Annotations/MockPoint.js +3 -3
  58. package/es-modules/Extensions/Annotations/NavigationBindings.js +5 -4
  59. package/es-modules/Extensions/Annotations/Popup.js +1 -2
  60. package/es-modules/Extensions/Annotations/Types/Measure.js +0 -1
  61. package/es-modules/Extensions/Boost/Boost.js +3 -3
  62. package/es-modules/Extensions/Boost/BoostAttach.js +5 -4
  63. package/es-modules/Extensions/Boost/BoostInit.js +1 -1
  64. package/es-modules/Extensions/Boost/BoostOverrides.js +1 -1
  65. package/es-modules/Extensions/Boost/BoostUtils.js +1 -1
  66. package/es-modules/Extensions/Boost/NamedColors.js +1 -1
  67. package/es-modules/Extensions/Boost/WGLRenderer.js +4 -4
  68. package/es-modules/Extensions/Boost/WGLShader.js +1 -2
  69. package/es-modules/Extensions/BoostCanvas.js +9 -6
  70. package/es-modules/Extensions/CurrentDateIndication.js +3 -7
  71. package/es-modules/Extensions/Data.js +7 -9
  72. package/es-modules/Extensions/DataGrouping.js +3 -2
  73. package/es-modules/Extensions/Debugger.js +3 -2
  74. package/es-modules/Extensions/DownloadURL.js +5 -3
  75. package/es-modules/Extensions/DragPanes.js +1 -1
  76. package/es-modules/Extensions/DraggablePoints.js +6 -5
  77. package/es-modules/Extensions/Drilldown.js +24 -10
  78. package/es-modules/Extensions/ExportData.js +1 -2
  79. package/es-modules/Extensions/Exporting.js +9 -2
  80. package/es-modules/Extensions/MarkerClusters.js +8 -5
  81. package/es-modules/Extensions/NoDataToDisplay.js +13 -13
  82. package/es-modules/Extensions/OfflineExporting.js +14 -14
  83. package/es-modules/Extensions/{Oldie.js → Oldie/Oldie.js} +15 -12
  84. package/es-modules/{Core/Axis → Extensions/Oldie}/VMLAxis3D.js +1 -1
  85. package/es-modules/Extensions/Oldie/VMLRenderer3D.js +46 -0
  86. package/es-modules/Extensions/OverlappingDataLabels.js +4 -0
  87. package/es-modules/Extensions/Pane.js +1 -1
  88. package/es-modules/Extensions/ParallelCoordinates.js +1 -1
  89. package/es-modules/Extensions/PatternFill.js +10 -7
  90. package/es-modules/Extensions/Polar.js +4 -2
  91. package/es-modules/Extensions/ScrollablePlotArea.js +3 -1
  92. package/es-modules/Extensions/SeriesLabel.js +4 -3
  93. package/es-modules/{modules/sonification/chartSonify.js → Extensions/Sonification/ChartSonify.js} +1 -1
  94. package/es-modules/{modules/sonification → Extensions/Sonification}/Earcon.js +0 -0
  95. package/es-modules/{modules/sonification → Extensions/Sonification}/Instrument.js +7 -2
  96. package/es-modules/{modules/sonification/instrumentDefinitions.js → Extensions/Sonification/InstrumentDefinitions.js} +1 -1
  97. package/es-modules/{modules/sonification/musicalFrequencies.js → Extensions/Sonification/MusicalFrequencies.js} +0 -0
  98. package/es-modules/{modules/sonification/options.js → Extensions/Sonification/Options.js} +0 -0
  99. package/es-modules/{modules/sonification/pointSonify.js → Extensions/Sonification/PointSonify.js} +1 -1
  100. package/es-modules/{modules/sonification/sonification.js → Extensions/Sonification/Sonification.js} +10 -9
  101. package/es-modules/{modules/sonification → Extensions/Sonification}/Timeline.js +1 -1
  102. package/es-modules/{modules/sonification/utilities.js → Extensions/Sonification/Utilities.js} +1 -1
  103. package/es-modules/Extensions/Stacking.js +1 -1
  104. package/es-modules/Extensions/StaticScale.js +3 -3
  105. package/es-modules/Extensions/Themes/Avocado.js +3 -4
  106. package/es-modules/Extensions/Themes/DarkUnica.js +5 -7
  107. package/es-modules/Extensions/Themes/Gray.js +3 -4
  108. package/es-modules/Extensions/Themes/HighContrastDark.js +3 -4
  109. package/es-modules/Extensions/Themes/Sunset.js +3 -4
  110. package/es-modules/Gantt/Pathfinder.js +6 -0
  111. package/es-modules/Maps/Map.js +9 -5
  112. package/es-modules/Maps/MapNavigation.js +0 -1
  113. package/es-modules/{mixins → Mixins}/CenteredSeries.js +0 -0
  114. package/es-modules/{mixins → Mixins}/ColorMapSeries.js +7 -3
  115. package/es-modules/{mixins → Mixins}/ColorSeries.js +7 -3
  116. package/es-modules/{mixins → Mixins}/DerivedSeries.js +1 -1
  117. package/es-modules/{mixins → Mixins}/DrawPoint.js +0 -0
  118. package/es-modules/{mixins → Mixins}/Geometry.js +0 -0
  119. package/es-modules/{mixins → Mixins}/GeometryCircles.js +0 -0
  120. package/es-modules/{mixins → Mixins}/IndicatorRequired.js +0 -0
  121. package/es-modules/{mixins → Mixins}/LegendSymbol.js +0 -0
  122. package/es-modules/{mixins → Mixins}/MultipleLines.js +0 -0
  123. package/es-modules/{mixins → Mixins}/Navigation.js +0 -0
  124. package/es-modules/{mixins → Mixins}/NelderMead.js +0 -0
  125. package/es-modules/{mixins → Mixins}/Nodes.js +1 -1
  126. package/es-modules/{mixins → Mixins}/OnSeries.js +1 -1
  127. package/es-modules/{mixins → Mixins}/Polygon.js +0 -0
  128. package/es-modules/{mixins → Mixins}/ReduceArray.js +0 -0
  129. package/es-modules/{mixins → Mixins}/TreeSeries.js +1 -1
  130. package/es-modules/Series/AreaRangeSeries.js +57 -21
  131. package/es-modules/Series/AreaSeries.js +38 -6
  132. package/es-modules/Series/AreaSplineRangeSeries.js +44 -7
  133. package/es-modules/Series/AreaSplineSeries.js +43 -6
  134. package/es-modules/Series/BarSeries.js +2 -5
  135. package/es-modules/Series/BellcurveSeries.js +45 -5
  136. package/es-modules/Series/BoxPlotSeries.js +7 -6
  137. package/es-modules/Series/Bubble/BubbleLegend.js +3 -3
  138. package/es-modules/Series/Bubble/BubbleSeries.js +13 -11
  139. package/es-modules/Series/BulletSeries.js +5 -5
  140. package/es-modules/Series/CandlestickSeries.js +7 -6
  141. package/es-modules/Series/Column3DSeries.js +77 -23
  142. package/es-modules/Series/ColumnPyramidSeries.js +5 -6
  143. package/es-modules/Series/ColumnRangeSeries.js +17 -16
  144. package/es-modules/Series/ColumnSeries.js +18 -14
  145. package/es-modules/Series/CylinderSeries.js +8 -11
  146. package/es-modules/Series/DependencyWheelSeries.js +11 -9
  147. package/es-modules/Series/DotplotSeries.js +3 -11
  148. package/es-modules/Series/DumbbellSeries.js +11 -7
  149. package/es-modules/Series/ErrorBarSeries.js +3 -5
  150. package/es-modules/Series/FlagsSeries.js +13 -9
  151. package/es-modules/Series/Funnel3DSeries.js +8 -12
  152. package/es-modules/Series/FunnelSeries.js +6 -6
  153. package/es-modules/Series/GanttSeries.js +11 -12
  154. package/es-modules/Series/GaugeSeries.js +6 -5
  155. package/es-modules/Series/HeatmapSeries.js +9 -7
  156. package/es-modules/Series/HistogramSeries.js +6 -5
  157. package/es-modules/Series/ItemSeries.js +5 -5
  158. package/es-modules/Series/LineSeries.js +13 -0
  159. package/es-modules/Series/LollipopSeries.js +11 -7
  160. package/es-modules/Series/MapBubbleSeries.js +4 -5
  161. package/es-modules/Series/MapLineSeries.js +4 -6
  162. package/es-modules/Series/MapPointSeries.js +6 -5
  163. package/es-modules/Series/MapSeries.js +15 -12
  164. package/es-modules/Series/Networkgraph/DraggableNodes.js +8 -6
  165. package/es-modules/Series/Networkgraph/Layouts.js +3 -1
  166. package/es-modules/Series/Networkgraph/Networkgraph.js +8 -7
  167. package/es-modules/Series/OHLCSeries.js +4 -6
  168. package/es-modules/Series/OrganizationSeries.js +7 -4
  169. package/es-modules/Series/PackedBubbleSeries.js +10 -10
  170. package/es-modules/Series/ParetoSeries.js +6 -5
  171. package/es-modules/Series/Pie3DSeries.js +3 -2
  172. package/es-modules/Series/PieSeries.js +36 -10
  173. package/es-modules/Series/PolygonSeries.js +6 -6
  174. package/es-modules/Series/Pyramid3DSeries.js +3 -5
  175. package/es-modules/Series/SankeySeries.js +13 -12
  176. package/es-modules/Series/Scatter3DSeries.js +4 -6
  177. package/es-modules/Series/ScatterSeries.js +10 -5
  178. package/es-modules/Series/SolidGaugeSeries.js +7 -7
  179. package/es-modules/Series/SplineSeries.js +5 -3
  180. package/es-modules/Series/StreamgraphSeries.js +41 -5
  181. package/es-modules/Series/SunburstSeries.js +15 -11
  182. package/es-modules/Series/TilemapSeries.js +8 -6
  183. package/es-modules/Series/TimelineSeries.js +6 -5
  184. package/es-modules/Series/TreemapSeries.js +36 -50
  185. package/es-modules/Series/VariablePieSeries.js +9 -7
  186. package/es-modules/Series/VariwideSeries.js +7 -6
  187. package/es-modules/Series/VectorSeries.js +5 -3
  188. package/es-modules/Series/VennSeries.js +20 -17
  189. package/es-modules/Series/WaterfallSeries.js +6 -4
  190. package/es-modules/Series/WindbarbSeries.js +9 -6
  191. package/es-modules/Series/WordcloudSeries.js +11 -9
  192. package/es-modules/Series/XRangeSeries.js +8 -7
  193. package/es-modules/Stock/Indicators/ABIndicator.js +7 -7
  194. package/es-modules/Stock/Indicators/ADIndicator.js +4 -3
  195. package/es-modules/Stock/Indicators/AOIndicator.js +5 -4
  196. package/es-modules/Stock/Indicators/APOIndicator.js +7 -7
  197. package/es-modules/Stock/Indicators/ATRIndicator.js +5 -5
  198. package/es-modules/Stock/Indicators/AroonIndicator.js +6 -5
  199. package/es-modules/Stock/Indicators/AroonOscillatorIndicator.js +5 -5
  200. package/es-modules/Stock/Indicators/BBIndicator.js +7 -7
  201. package/es-modules/Stock/Indicators/CCIIndicator.js +4 -3
  202. package/es-modules/Stock/Indicators/CMFIndicator.js +3 -4
  203. package/es-modules/Stock/Indicators/ChaikinIndicator.js +9 -8
  204. package/es-modules/Stock/Indicators/DEMAIndicator.js +7 -7
  205. package/es-modules/Stock/Indicators/DPOIndicator.js +4 -3
  206. package/es-modules/Stock/Indicators/EMAIndicator.js +3 -3
  207. package/es-modules/Stock/Indicators/IKHIndicator.js +22 -19
  208. package/es-modules/Stock/Indicators/KeltnerChannelsIndicator.js +10 -7
  209. package/es-modules/Stock/Indicators/MACDIndicator.js +7 -4
  210. package/es-modules/Stock/Indicators/MFIIndicator.js +4 -3
  211. package/es-modules/Stock/Indicators/MomentumIndicator.js +4 -3
  212. package/es-modules/Stock/Indicators/NATRIndicator.js +4 -6
  213. package/es-modules/Stock/Indicators/PCIndicator.js +8 -7
  214. package/es-modules/Stock/Indicators/PPOIndicator.js +7 -7
  215. package/es-modules/Stock/Indicators/PSARIndicator.js +3 -4
  216. package/es-modules/Stock/Indicators/PivotPointsIndicator.js +5 -5
  217. package/es-modules/Stock/Indicators/PriceEnvelopesIndicator.js +5 -5
  218. package/es-modules/Stock/Indicators/ROCIndicator.js +4 -3
  219. package/es-modules/Stock/Indicators/RSIIndicator.js +4 -3
  220. package/es-modules/Stock/Indicators/RegressionIndicators.js +7 -6
  221. package/es-modules/Stock/Indicators/{Indicators.js → SMAIndicator.js} +9 -6
  222. package/es-modules/Stock/Indicators/SlowStochasticIndicator.js +6 -8
  223. package/es-modules/Stock/Indicators/StochasticIndicator.js +8 -8
  224. package/es-modules/Stock/Indicators/SupertrendIndicator.js +7 -6
  225. package/es-modules/Stock/Indicators/TEMAIndicator.js +7 -7
  226. package/es-modules/Stock/Indicators/TRIXIndicator.js +7 -7
  227. package/es-modules/Stock/Indicators/TrendLineIndicator.js +4 -3
  228. package/es-modules/Stock/Indicators/VBPIndicator.js +7 -4
  229. package/es-modules/Stock/Indicators/VWAPIndicator.js +4 -3
  230. package/es-modules/Stock/Indicators/WMAIndicator.js +4 -3
  231. package/es-modules/Stock/Indicators/WilliamsRIndicator.js +6 -5
  232. package/es-modules/Stock/Indicators/ZigzagIndicator.js +5 -7
  233. package/es-modules/Stock/StockToolsBindings.js +16 -2
  234. package/es-modules/Stock/StockToolsGui.js +9 -9
  235. package/es-modules/masters/highcharts-3d.src.js +1 -2
  236. package/es-modules/masters/highcharts-gantt.src.js +1 -1
  237. package/es-modules/masters/highcharts-more.src.js +1 -1
  238. package/es-modules/masters/highcharts.src.js +3 -2
  239. package/es-modules/masters/highmaps.src.js +1 -1
  240. package/es-modules/masters/highstock.src.js +1 -1
  241. package/es-modules/masters/indicators/acceleration-bands.src.js +1 -1
  242. package/es-modules/masters/indicators/accumulation-distribution.src.js +1 -1
  243. package/es-modules/masters/indicators/ao.src.js +1 -1
  244. package/es-modules/masters/indicators/apo.src.js +1 -1
  245. package/es-modules/masters/indicators/aroon-oscillator.src.js +1 -1
  246. package/es-modules/masters/indicators/aroon.src.js +1 -1
  247. package/es-modules/masters/indicators/atr.src.js +1 -1
  248. package/es-modules/masters/indicators/bollinger-bands.src.js +1 -1
  249. package/es-modules/masters/indicators/cci.src.js +1 -1
  250. package/es-modules/masters/indicators/chaikin.src.js +1 -1
  251. package/es-modules/masters/indicators/cmf.src.js +1 -1
  252. package/es-modules/masters/indicators/dema.src.js +1 -1
  253. package/es-modules/masters/indicators/dpo.src.js +1 -1
  254. package/es-modules/masters/indicators/ema.src.js +1 -1
  255. package/es-modules/masters/indicators/ichimoku-kinko-hyo.src.js +1 -1
  256. package/es-modules/masters/indicators/indicators-all.src.js +2 -2
  257. package/es-modules/masters/indicators/indicators.src.js +2 -2
  258. package/es-modules/masters/indicators/keltner-channels.src.js +1 -1
  259. package/es-modules/masters/indicators/macd.src.js +1 -1
  260. package/es-modules/masters/indicators/mfi.src.js +1 -1
  261. package/es-modules/masters/indicators/momentum.src.js +1 -1
  262. package/es-modules/masters/indicators/natr.src.js +1 -1
  263. package/es-modules/masters/indicators/pivot-points.src.js +1 -1
  264. package/es-modules/masters/indicators/ppo.src.js +1 -1
  265. package/es-modules/masters/indicators/price-channel.src.js +1 -1
  266. package/es-modules/masters/indicators/price-envelopes.src.js +1 -1
  267. package/es-modules/masters/indicators/psar.src.js +1 -1
  268. package/es-modules/masters/indicators/regressions.src.js +1 -1
  269. package/es-modules/masters/indicators/roc.src.js +1 -1
  270. package/es-modules/masters/indicators/rsi.src.js +1 -1
  271. package/es-modules/masters/indicators/slow-stochastic.src.js +1 -1
  272. package/es-modules/masters/indicators/stochastic.src.js +1 -1
  273. package/es-modules/masters/indicators/supertrend.src.js +1 -1
  274. package/es-modules/masters/indicators/tema.src.js +1 -1
  275. package/es-modules/masters/indicators/trendline.src.js +1 -1
  276. package/es-modules/masters/indicators/trix.src.js +1 -1
  277. package/es-modules/masters/indicators/volume-by-price.src.js +1 -1
  278. package/es-modules/masters/indicators/vwap.src.js +1 -1
  279. package/es-modules/masters/indicators/williams-r.src.js +1 -1
  280. package/es-modules/masters/indicators/wma.src.js +1 -1
  281. package/es-modules/masters/indicators/zigzag.src.js +1 -1
  282. package/es-modules/masters/modules/accessibility.src.js +1 -1
  283. package/es-modules/masters/modules/annotations-advanced.src.js +1 -1
  284. package/es-modules/masters/modules/annotations.src.js +1 -1
  285. package/es-modules/masters/modules/arrow-symbols.src.js +1 -1
  286. package/es-modules/masters/modules/boost-canvas.src.js +1 -1
  287. package/es-modules/masters/modules/boost.src.js +1 -1
  288. package/es-modules/masters/modules/broken-axis.src.js +1 -1
  289. package/es-modules/masters/modules/bullet.src.js +1 -1
  290. package/es-modules/masters/modules/coloraxis.src.js +1 -1
  291. package/es-modules/masters/modules/current-date-indicator.src.js +1 -1
  292. package/es-modules/masters/modules/cylinder.src.js +1 -1
  293. package/es-modules/masters/modules/data.src.js +1 -1
  294. package/es-modules/masters/modules/datagrouping.src.js +1 -1
  295. package/es-modules/masters/modules/debugger.src.js +1 -1
  296. package/es-modules/masters/modules/dependency-wheel.src.js +1 -1
  297. package/es-modules/masters/modules/dotplot.src.js +1 -1
  298. package/es-modules/masters/modules/drag-panes.src.js +1 -1
  299. package/es-modules/masters/modules/draggable-points.src.js +1 -1
  300. package/es-modules/masters/modules/drilldown.src.js +1 -1
  301. package/es-modules/masters/modules/dumbbell.src.js +1 -1
  302. package/es-modules/masters/modules/export-data.src.js +1 -1
  303. package/es-modules/masters/modules/exporting.src.js +1 -1
  304. package/es-modules/masters/modules/full-screen.src.js +1 -1
  305. package/es-modules/masters/modules/funnel.src.js +1 -1
  306. package/es-modules/masters/modules/funnel3d.src.js +1 -1
  307. package/es-modules/masters/modules/gantt.src.js +1 -1
  308. package/es-modules/masters/modules/grid-axis.src.js +1 -1
  309. package/es-modules/masters/modules/heatmap.src.js +1 -1
  310. package/es-modules/masters/modules/histogram-bellcurve.src.js +1 -1
  311. package/es-modules/masters/modules/item-series.src.js +1 -1
  312. package/es-modules/masters/modules/lollipop.src.js +1 -1
  313. package/es-modules/masters/modules/map.src.js +1 -1
  314. package/es-modules/masters/modules/marker-clusters.src.js +1 -1
  315. package/es-modules/masters/modules/networkgraph.src.js +1 -1
  316. package/es-modules/masters/modules/no-data-to-display.src.js +1 -1
  317. package/es-modules/masters/modules/offline-exporting.src.js +1 -1
  318. package/es-modules/masters/modules/oldie-polyfills.src.js +1 -1
  319. package/es-modules/masters/modules/oldie.src.js +2 -2
  320. package/es-modules/masters/modules/organization.src.js +1 -1
  321. package/es-modules/masters/modules/overlapping-datalabels.src.js +1 -1
  322. package/es-modules/masters/modules/parallel-coordinates.src.js +1 -1
  323. package/es-modules/masters/modules/pareto.src.js +1 -1
  324. package/es-modules/masters/modules/pathfinder.src.js +1 -1
  325. package/es-modules/masters/modules/pattern-fill.src.js +1 -1
  326. package/es-modules/masters/modules/price-indicator.src.js +1 -1
  327. package/es-modules/masters/modules/pyramid3d.src.js +1 -1
  328. package/es-modules/masters/modules/sankey.src.js +1 -1
  329. package/es-modules/masters/modules/series-label.src.js +1 -1
  330. package/es-modules/masters/modules/solid-gauge.src.js +1 -1
  331. package/es-modules/masters/modules/sonification.src.js +2 -2
  332. package/es-modules/masters/modules/static-scale.src.js +1 -1
  333. package/es-modules/masters/modules/stock-tools.src.js +1 -1
  334. package/es-modules/masters/modules/stock.src.js +1 -1
  335. package/es-modules/masters/modules/streamgraph.src.js +1 -1
  336. package/es-modules/masters/modules/sunburst.src.js +1 -1
  337. package/es-modules/masters/modules/tilemap.src.js +1 -1
  338. package/es-modules/masters/modules/timeline.src.js +1 -1
  339. package/es-modules/masters/modules/treegrid.src.js +1 -1
  340. package/es-modules/masters/modules/treemap.src.js +1 -1
  341. package/es-modules/masters/modules/variable-pie.src.js +1 -1
  342. package/es-modules/masters/modules/variwide.src.js +1 -1
  343. package/es-modules/masters/modules/vector.src.js +1 -1
  344. package/es-modules/masters/modules/venn.src.js +1 -1
  345. package/es-modules/masters/modules/windbarb.src.js +1 -1
  346. package/es-modules/masters/modules/wordcloud.src.js +1 -1
  347. package/es-modules/masters/modules/xrange.src.js +1 -1
  348. package/es-modules/masters/themes/avocado.src.js +1 -1
  349. package/es-modules/masters/themes/dark-blue.src.js +1 -1
  350. package/es-modules/masters/themes/dark-green.src.js +1 -1
  351. package/es-modules/masters/themes/dark-unica.src.js +1 -1
  352. package/es-modules/masters/themes/gray.src.js +1 -1
  353. package/es-modules/masters/themes/grid-light.src.js +1 -1
  354. package/es-modules/masters/themes/grid.src.js +1 -1
  355. package/es-modules/masters/themes/high-contrast-dark.src.js +1 -1
  356. package/es-modules/masters/themes/high-contrast-light.src.js +1 -1
  357. package/es-modules/masters/themes/sand-signika.src.js +1 -1
  358. package/es-modules/masters/themes/skies.src.js +1 -1
  359. package/es-modules/masters/themes/sunset.src.js +1 -1
  360. package/highcharts-3d.js +86 -89
  361. package/highcharts-3d.js.map +1 -1
  362. package/highcharts-3d.src.js +88 -149
  363. package/highcharts-gantt.js +729 -717
  364. package/highcharts-gantt.js.map +1 -1
  365. package/highcharts-gantt.src.js +5570 -5094
  366. package/highcharts-more.js +164 -163
  367. package/highcharts-more.js.map +1 -1
  368. package/highcharts-more.src.js +182 -118
  369. package/highcharts.d.ts +89 -159
  370. package/highcharts.js +537 -530
  371. package/highcharts.js.map +1 -1
  372. package/highcharts.src.d.ts +89 -159
  373. package/highcharts.src.js +5341 -4976
  374. package/highmaps.js +635 -627
  375. package/highmaps.js.map +1 -1
  376. package/highmaps.src.js +5907 -5530
  377. package/highstock.js +696 -689
  378. package/highstock.js.map +1 -1
  379. package/highstock.src.js +5384 -5026
  380. package/indicators/acceleration-bands.js +8 -8
  381. package/indicators/acceleration-bands.js.map +1 -1
  382. package/indicators/acceleration-bands.src.js +7 -7
  383. package/indicators/accumulation-distribution.js +4 -4
  384. package/indicators/accumulation-distribution.js.map +1 -1
  385. package/indicators/accumulation-distribution.src.js +5 -5
  386. package/indicators/ao.js +5 -5
  387. package/indicators/ao.js.map +1 -1
  388. package/indicators/ao.src.js +6 -6
  389. package/indicators/apo.js +5 -5
  390. package/indicators/apo.js.map +1 -1
  391. package/indicators/apo.src.js +7 -7
  392. package/indicators/aroon-oscillator.js +8 -8
  393. package/indicators/aroon-oscillator.js.map +1 -1
  394. package/indicators/aroon-oscillator.src.js +6 -6
  395. package/indicators/aroon.js +7 -7
  396. package/indicators/aroon.js.map +1 -1
  397. package/indicators/aroon.src.js +6 -6
  398. package/indicators/atr.js +4 -4
  399. package/indicators/atr.js.map +1 -1
  400. package/indicators/atr.src.js +6 -14
  401. package/indicators/bollinger-bands.js +8 -8
  402. package/indicators/bollinger-bands.js.map +1 -1
  403. package/indicators/bollinger-bands.src.js +7 -7
  404. package/indicators/cci.js +4 -4
  405. package/indicators/cci.js.map +1 -1
  406. package/indicators/cci.src.js +5 -5
  407. package/indicators/chaikin.js +6 -6
  408. package/indicators/chaikin.js.map +1 -1
  409. package/indicators/chaikin.src.js +75 -74
  410. package/indicators/cmf.js +2 -2
  411. package/indicators/cmf.js.map +1 -1
  412. package/indicators/cmf.src.js +4 -4
  413. package/indicators/dema.js +5 -5
  414. package/indicators/dema.js.map +1 -1
  415. package/indicators/dema.src.js +7 -7
  416. package/indicators/dpo.js +4 -4
  417. package/indicators/dpo.js.map +1 -1
  418. package/indicators/dpo.src.js +5 -5
  419. package/indicators/ema.js +4 -4
  420. package/indicators/ema.js.map +1 -1
  421. package/indicators/ema.src.js +4 -5
  422. package/indicators/ichimoku-kinko-hyo.js +13 -13
  423. package/indicators/ichimoku-kinko-hyo.js.map +1 -1
  424. package/indicators/ichimoku-kinko-hyo.src.js +21 -20
  425. package/indicators/indicators-all.js +118 -118
  426. package/indicators/indicators-all.js.map +1 -1
  427. package/indicators/indicators-all.src.js +227 -230
  428. package/indicators/indicators.js +9 -9
  429. package/indicators/indicators.js.map +1 -1
  430. package/indicators/indicators.src.js +7 -7
  431. package/indicators/keltner-channels.js +8 -8
  432. package/indicators/keltner-channels.js.map +1 -1
  433. package/indicators/keltner-channels.src.js +12 -9
  434. package/indicators/macd.js +10 -10
  435. package/indicators/macd.js.map +1 -1
  436. package/indicators/macd.src.js +8 -7
  437. package/indicators/mfi.js +4 -4
  438. package/indicators/mfi.js.map +1 -1
  439. package/indicators/mfi.src.js +5 -5
  440. package/indicators/momentum.js +4 -4
  441. package/indicators/momentum.js.map +1 -1
  442. package/indicators/momentum.src.js +5 -5
  443. package/indicators/natr.js +3 -3
  444. package/indicators/natr.js.map +1 -1
  445. package/indicators/natr.src.js +5 -5
  446. package/indicators/pivot-points.js +8 -8
  447. package/indicators/pivot-points.js.map +1 -1
  448. package/indicators/pivot-points.src.js +6 -6
  449. package/indicators/ppo.js +5 -5
  450. package/indicators/ppo.js.map +1 -1
  451. package/indicators/ppo.src.js +7 -7
  452. package/indicators/price-channel.js +8 -8
  453. package/indicators/price-channel.js.map +1 -1
  454. package/indicators/price-channel.src.js +65 -65
  455. package/indicators/price-envelopes.js +7 -7
  456. package/indicators/price-envelopes.js.map +1 -1
  457. package/indicators/price-envelopes.src.js +6 -6
  458. package/indicators/psar.js +2 -2
  459. package/indicators/psar.js.map +1 -1
  460. package/indicators/psar.src.js +4 -4
  461. package/indicators/regressions.js +6 -6
  462. package/indicators/regressions.js.map +1 -1
  463. package/indicators/regressions.src.js +8 -8
  464. package/indicators/roc.js +3 -3
  465. package/indicators/roc.js.map +1 -1
  466. package/indicators/roc.src.js +5 -5
  467. package/indicators/rsi.js +4 -4
  468. package/indicators/rsi.js.map +1 -1
  469. package/indicators/rsi.src.js +5 -5
  470. package/indicators/slow-stochastic.js +5 -5
  471. package/indicators/slow-stochastic.js.map +1 -1
  472. package/indicators/slow-stochastic.src.js +6 -6
  473. package/indicators/stochastic.js +9 -9
  474. package/indicators/stochastic.js.map +1 -1
  475. package/indicators/stochastic.src.js +66 -66
  476. package/indicators/supertrend.js +9 -9
  477. package/indicators/supertrend.js.map +1 -1
  478. package/indicators/supertrend.src.js +9 -7
  479. package/indicators/tema.js +6 -6
  480. package/indicators/tema.js.map +1 -1
  481. package/indicators/tema.src.js +7 -7
  482. package/indicators/trendline.js +3 -3
  483. package/indicators/trendline.js.map +1 -1
  484. package/indicators/trendline.src.js +5 -5
  485. package/indicators/trix.js +4 -4
  486. package/indicators/trix.js.map +1 -1
  487. package/indicators/trix.src.js +7 -7
  488. package/indicators/volume-by-price.js +13 -13
  489. package/indicators/volume-by-price.js.map +1 -1
  490. package/indicators/volume-by-price.src.js +7 -8
  491. package/indicators/vwap.js +4 -4
  492. package/indicators/vwap.js.map +1 -1
  493. package/indicators/vwap.src.js +5 -5
  494. package/indicators/williams-r.js +4 -4
  495. package/indicators/williams-r.js.map +1 -1
  496. package/indicators/williams-r.src.js +6 -6
  497. package/indicators/wma.js +4 -4
  498. package/indicators/wma.js.map +1 -1
  499. package/indicators/wma.src.js +5 -5
  500. package/indicators/zigzag.js +4 -4
  501. package/indicators/zigzag.js.map +1 -1
  502. package/indicators/zigzag.src.js +6 -7
  503. package/modules/accessibility.js +148 -147
  504. package/modules/accessibility.js.map +1 -1
  505. package/modules/accessibility.src.js +104 -96
  506. package/modules/annotations-advanced.js +158 -158
  507. package/modules/annotations-advanced.js.map +1 -1
  508. package/modules/annotations-advanced.src.js +15 -14
  509. package/modules/annotations.js +105 -105
  510. package/modules/annotations.js.map +1 -1
  511. package/modules/annotations.src.js +15 -14
  512. package/modules/arrow-symbols.js +1 -1
  513. package/modules/arrow-symbols.src.js +1 -1
  514. package/modules/boost-canvas.js +15 -15
  515. package/modules/boost-canvas.js.map +1 -1
  516. package/modules/boost-canvas.src.js +16 -16
  517. package/modules/boost.d.ts +4 -0
  518. package/modules/boost.js +77 -64
  519. package/modules/boost.js.map +1 -1
  520. package/modules/boost.src.d.ts +4 -0
  521. package/modules/boost.src.js +561 -14
  522. package/modules/broken-axis.js +12 -12
  523. package/modules/broken-axis.js.map +1 -1
  524. package/modules/broken-axis.src.js +4 -5
  525. package/modules/bullet.js +6 -6
  526. package/modules/bullet.js.map +1 -1
  527. package/modules/bullet.src.js +5 -6
  528. package/modules/coloraxis.js +22 -21
  529. package/modules/coloraxis.js.map +1 -1
  530. package/modules/coloraxis.src.js +46 -41
  531. package/modules/current-date-indicator.js +4 -4
  532. package/modules/current-date-indicator.js.map +1 -1
  533. package/modules/current-date-indicator.src.js +4 -6
  534. package/modules/cylinder.js +8 -8
  535. package/modules/cylinder.js.map +1 -1
  536. package/modules/cylinder.src.js +18 -21
  537. package/modules/data.js +32 -32
  538. package/modules/data.js.map +1 -1
  539. package/modules/data.src.js +7 -11
  540. package/modules/datagrouping.js +17 -17
  541. package/modules/datagrouping.js.map +1 -1
  542. package/modules/datagrouping.src.js +3 -4
  543. package/modules/debugger.js +4 -4
  544. package/modules/debugger.js.map +1 -1
  545. package/modules/debugger.src.js +4 -4
  546. package/modules/dependency-wheel.js +8 -8
  547. package/modules/dependency-wheel.js.map +1 -1
  548. package/modules/dependency-wheel.src.js +9 -9
  549. package/modules/dotplot.js +5 -5
  550. package/modules/dotplot.js.map +1 -1
  551. package/modules/dotplot.src.js +4 -12
  552. package/modules/drag-panes.js +7 -7
  553. package/modules/drag-panes.js.map +1 -1
  554. package/modules/drag-panes.src.js +2 -2
  555. package/modules/draggable-points.js +33 -33
  556. package/modules/draggable-points.js.map +1 -1
  557. package/modules/draggable-points.src.js +6 -6
  558. package/modules/drilldown.js +23 -22
  559. package/modules/drilldown.js.map +1 -1
  560. package/modules/drilldown.src.js +21 -11
  561. package/modules/dumbbell.js +24 -20
  562. package/modules/dumbbell.js.map +1 -1
  563. package/modules/dumbbell.src.js +396 -136
  564. package/modules/export-data.js +21 -21
  565. package/modules/export-data.js.map +1 -1
  566. package/modules/export-data.src.js +8 -7
  567. package/modules/exporting.js +32 -32
  568. package/modules/exporting.js.map +1 -1
  569. package/modules/exporting.src.js +10 -3
  570. package/modules/full-screen.js +1 -1
  571. package/modules/full-screen.src.js +1 -1
  572. package/modules/funnel.js +9 -9
  573. package/modules/funnel.js.map +1 -1
  574. package/modules/funnel.src.js +6 -8
  575. package/modules/funnel3d.js +17 -17
  576. package/modules/funnel3d.js.map +1 -1
  577. package/modules/funnel3d.src.js +9 -12
  578. package/modules/gantt.js +194 -189
  579. package/modules/gantt.js.map +1 -1
  580. package/modules/gantt.src.js +232 -121
  581. package/modules/grid-axis.js +22 -19
  582. package/modules/grid-axis.js.map +1 -1
  583. package/modules/grid-axis.src.js +130 -64
  584. package/modules/heatmap.js +33 -33
  585. package/modules/heatmap.js.map +1 -1
  586. package/modules/heatmap.src.js +93 -84
  587. package/modules/histogram-bellcurve.js +10 -10
  588. package/modules/histogram-bellcurve.js.map +1 -1
  589. package/modules/histogram-bellcurve.src.js +49 -11
  590. package/modules/item-series.js +9 -9
  591. package/modules/item-series.js.map +1 -1
  592. package/modules/item-series.src.js +5 -6
  593. package/modules/lollipop.d.ts +20 -1
  594. package/modules/lollipop.js +26 -4
  595. package/modules/lollipop.js.map +1 -1
  596. package/modules/lollipop.src.d.ts +20 -1
  597. package/modules/lollipop.src.js +1431 -9
  598. package/modules/map.d.ts +1 -1
  599. package/modules/map.js +99 -99
  600. package/modules/map.js.map +1 -1
  601. package/modules/map.src.d.ts +1 -1
  602. package/modules/map.src.js +1421 -1409
  603. package/modules/marker-clusters.js +35 -35
  604. package/modules/marker-clusters.js.map +1 -1
  605. package/modules/marker-clusters.src.js +5 -5
  606. package/modules/networkgraph.js +47 -46
  607. package/modules/networkgraph.js.map +1 -1
  608. package/modules/networkgraph.src.js +18 -17
  609. package/modules/no-data-to-display.js +4 -4
  610. package/modules/no-data-to-display.js.map +1 -1
  611. package/modules/no-data-to-display.src.js +15 -12
  612. package/modules/offline-exporting.js +15 -15
  613. package/modules/offline-exporting.js.map +1 -1
  614. package/modules/offline-exporting.src.js +20 -18
  615. package/modules/oldie-polyfills.js +1 -1
  616. package/modules/oldie-polyfills.src.js +1 -1
  617. package/modules/oldie.js +52 -26
  618. package/modules/oldie.js.map +1 -1
  619. package/modules/oldie.src.js +1401 -22
  620. package/modules/organization.js +11 -11
  621. package/modules/organization.js.map +1 -1
  622. package/modules/organization.src.js +6 -5
  623. package/modules/overlapping-datalabels.js +1 -1
  624. package/modules/overlapping-datalabels.src.js +1 -1
  625. package/modules/parallel-coordinates.js +1 -1
  626. package/modules/parallel-coordinates.src.js +1 -1
  627. package/modules/pareto.js +5 -5
  628. package/modules/pareto.js.map +1 -1
  629. package/modules/pareto.src.js +5 -6
  630. package/modules/pathfinder.js +20 -20
  631. package/modules/pathfinder.js.map +1 -1
  632. package/modules/pathfinder.src.js +7 -1
  633. package/modules/pattern-fill.js +13 -13
  634. package/modules/pattern-fill.js.map +1 -1
  635. package/modules/pattern-fill.src.js +10 -10
  636. package/modules/price-indicator.js +1 -1
  637. package/modules/price-indicator.src.js +1 -1
  638. package/modules/pyramid3d.js +3 -3
  639. package/modules/pyramid3d.js.map +1 -1
  640. package/modules/pyramid3d.src.js +3 -4
  641. package/modules/sankey.js +25 -25
  642. package/modules/sankey.js.map +1 -1
  643. package/modules/sankey.src.js +15 -15
  644. package/modules/series-label.js +17 -17
  645. package/modules/series-label.js.map +1 -1
  646. package/modules/series-label.src.js +3 -3
  647. package/modules/solid-gauge.js +8 -8
  648. package/modules/solid-gauge.js.map +1 -1
  649. package/modules/solid-gauge.src.js +4 -5
  650. package/modules/sonification.js +46 -46
  651. package/modules/sonification.js.map +1 -1
  652. package/modules/sonification.src.js +21 -16
  653. package/modules/static-scale.js +4 -4
  654. package/modules/static-scale.js.map +1 -1
  655. package/modules/static-scale.src.js +3 -4
  656. package/modules/stock-tools.js +142 -141
  657. package/modules/stock-tools.js.map +1 -1
  658. package/modules/stock-tools.src.js +40 -21
  659. package/modules/stock.js +161 -161
  660. package/modules/stock.js.map +1 -1
  661. package/modules/stock.src.js +41 -48
  662. package/modules/streamgraph.js +2 -2
  663. package/modules/streamgraph.js.map +1 -1
  664. package/modules/streamgraph.src.js +41 -4
  665. package/modules/sunburst.js +51 -50
  666. package/modules/sunburst.js.map +1 -1
  667. package/modules/sunburst.src.js +134 -65
  668. package/modules/tilemap.js +14 -14
  669. package/modules/tilemap.js.map +1 -1
  670. package/modules/tilemap.src.js +9 -9
  671. package/modules/timeline.js +14 -14
  672. package/modules/timeline.js.map +1 -1
  673. package/modules/timeline.src.js +7 -8
  674. package/modules/treegrid.js +57 -52
  675. package/modules/treegrid.js.map +1 -1
  676. package/modules/treegrid.src.js +191 -77
  677. package/modules/treemap.js +35 -34
  678. package/modules/treemap.js.map +1 -1
  679. package/modules/treemap.src.js +205 -138
  680. package/modules/variable-pie.js +8 -8
  681. package/modules/variable-pie.js.map +1 -1
  682. package/modules/variable-pie.src.js +10 -9
  683. package/modules/variwide.js +8 -8
  684. package/modules/variwide.js.map +1 -1
  685. package/modules/variwide.src.js +6 -7
  686. package/modules/vector.js +6 -6
  687. package/modules/vector.js.map +1 -1
  688. package/modules/vector.src.js +6 -7
  689. package/modules/venn.js +26 -26
  690. package/modules/venn.js.map +1 -1
  691. package/modules/venn.src.js +23 -23
  692. package/modules/windbarb.js +11 -11
  693. package/modules/windbarb.js.map +1 -1
  694. package/modules/windbarb.src.js +8 -9
  695. package/modules/wordcloud.js +19 -19
  696. package/modules/wordcloud.js.map +1 -1
  697. package/modules/wordcloud.src.js +14 -14
  698. package/modules/xrange.js +12 -12
  699. package/modules/xrange.js.map +1 -1
  700. package/modules/xrange.src.js +8 -9
  701. package/package.json +1 -1
  702. package/themes/avocado.js +1 -1
  703. package/themes/avocado.js.map +1 -1
  704. package/themes/avocado.src.js +4 -4
  705. package/themes/dark-blue.js +1 -1
  706. package/themes/dark-blue.src.js +1 -1
  707. package/themes/dark-green.js +1 -1
  708. package/themes/dark-green.src.js +1 -1
  709. package/themes/dark-unica.js +1 -1
  710. package/themes/dark-unica.js.map +1 -1
  711. package/themes/dark-unica.src.js +6 -7
  712. package/themes/gray.js +1 -1
  713. package/themes/gray.js.map +1 -1
  714. package/themes/gray.src.js +4 -4
  715. package/themes/grid-light.js +1 -1
  716. package/themes/grid-light.src.js +1 -1
  717. package/themes/grid.js +1 -1
  718. package/themes/grid.src.js +1 -1
  719. package/themes/high-contrast-dark.js +1 -1
  720. package/themes/high-contrast-dark.js.map +1 -1
  721. package/themes/high-contrast-dark.src.js +4 -4
  722. package/themes/high-contrast-light.js +1 -1
  723. package/themes/high-contrast-light.src.js +1 -1
  724. package/themes/sand-signika.js +1 -1
  725. package/themes/sand-signika.src.js +1 -1
  726. package/themes/skies.js +1 -1
  727. package/themes/skies.src.js +1 -1
  728. package/themes/sunset.js +1 -1
  729. package/themes/sunset.js.map +1 -1
  730. package/themes/sunset.src.js +4 -4
  731. package/es-modules/Core/Renderer/VML/VMLRenderer3D.js +0 -37
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Highcharts JS v8.2.0 (2020-08-20)
2
+ * @license Highcharts JS v8.2.2 (2020-10-22)
3
3
  *
4
4
  * Old IE (v6, v7, v8) module for Highcharts v6+.
5
5
  *
@@ -29,7 +29,1382 @@
29
29
  obj[path] = fn.apply(null, args);
30
30
  }
31
31
  }
32
- _registerModule(_modules, 'Extensions/Oldie.js', [_modules['Core/Chart/Chart.js'], _modules['Core/Color.js'], _modules['Core/Globals.js'], _modules['Core/Pointer.js'], _modules['Core/Renderer/SVG/SVGElement.js'], _modules['Core/Renderer/SVG/SVGRenderer.js'], _modules['Core/Utilities.js']], function (Chart, Color, H, Pointer, SVGElement, SVGRenderer, U) {
32
+ _registerModule(_modules, 'Extensions/Math3D.js', [_modules['Core/Globals.js'], _modules['Core/Utilities.js']], function (H, U) {
33
+ /* *
34
+ *
35
+ * (c) 2010-2020 Torstein Honsi
36
+ *
37
+ * License: www.highcharts.com/license
38
+ *
39
+ * !!!!!!! SOURCE GETS TRANSPILED BY TYPESCRIPT. EDIT TS FILE ONLY. !!!!!!!
40
+ *
41
+ * */
42
+ var pick = U.pick;
43
+ // Mathematical Functionility
44
+ var deg2rad = H.deg2rad;
45
+ /* eslint-disable max-len */
46
+ /**
47
+ * Apply 3-D rotation
48
+ * Euler Angles (XYZ):
49
+ * cosA = cos(Alfa|Roll)
50
+ * cosB = cos(Beta|Pitch)
51
+ * cosG = cos(Gamma|Yaw)
52
+ *
53
+ * Composite rotation:
54
+ * | cosB * cosG | cosB * sinG | -sinB |
55
+ * | sinA * sinB * cosG - cosA * sinG | sinA * sinB * sinG + cosA * cosG | sinA * cosB |
56
+ * | cosA * sinB * cosG + sinA * sinG | cosA * sinB * sinG - sinA * cosG | cosA * cosB |
57
+ *
58
+ * Now, Gamma/Yaw is not used (angle=0), so we assume cosG = 1 and sinG = 0, so
59
+ * we get:
60
+ * | cosB | 0 | - sinB |
61
+ * | sinA * sinB | cosA | sinA * cosB |
62
+ * | cosA * sinB | - sinA | cosA * cosB |
63
+ *
64
+ * But in browsers, y is reversed, so we get sinA => -sinA. The general result
65
+ * is:
66
+ * | cosB | 0 | - sinB | | x | | px |
67
+ * | - sinA * sinB | cosA | - sinA * cosB | x | y | = | py |
68
+ * | cosA * sinB | sinA | cosA * cosB | | z | | pz |
69
+ *
70
+ * @private
71
+ * @function rotate3D
72
+ */
73
+ /* eslint-enable max-len */
74
+ /**
75
+ * @private
76
+ * @param {number} x
77
+ * X coordinate
78
+ * @param {number} y
79
+ * Y coordinate
80
+ * @param {number} z
81
+ * Z coordinate
82
+ * @param {Highcharts.Rotation3dObject} angles
83
+ * Rotation angles
84
+ * @return {Highcharts.Rotation3dObject}
85
+ * Rotated position
86
+ */
87
+ function rotate3D(x, y, z, angles) {
88
+ return {
89
+ x: angles.cosB * x - angles.sinB * z,
90
+ y: -angles.sinA * angles.sinB * x + angles.cosA * y -
91
+ angles.cosB * angles.sinA * z,
92
+ z: angles.cosA * angles.sinB * x + angles.sinA * y +
93
+ angles.cosA * angles.cosB * z
94
+ };
95
+ }
96
+ /**
97
+ * Perspective3D function is available in global Highcharts scope because is
98
+ * needed also outside of perspective() function (#8042).
99
+ * @private
100
+ * @function Highcharts.perspective3D
101
+ *
102
+ * @param {Highcharts.Position3dObject} coordinate
103
+ * 3D position
104
+ *
105
+ * @param {Highcharts.Position3dObject} origin
106
+ * 3D root position
107
+ *
108
+ * @param {number} distance
109
+ * Perspective distance
110
+ *
111
+ * @return {Highcharts.PositionObject}
112
+ * Perspective 3D Position
113
+ *
114
+ * @requires highcharts-3d
115
+ */
116
+ var perspective3D = H.perspective3D = function (coordinate,
117
+ origin,
118
+ distance) {
119
+ var projection = ((distance > 0) && (distance < Number.POSITIVE_INFINITY)) ?
120
+ distance / (coordinate.z + origin.z + distance) :
121
+ 1;
122
+ return {
123
+ x: coordinate.x * projection,
124
+ y: coordinate.y * projection
125
+ };
126
+ };
127
+ /**
128
+ * Transforms a given array of points according to the angles in chart.options.
129
+ *
130
+ * @private
131
+ * @function Highcharts.perspective
132
+ *
133
+ * @param {Array<Highcharts.Position3dObject>} points
134
+ * The array of points
135
+ *
136
+ * @param {Highcharts.Chart} chart
137
+ * The chart
138
+ *
139
+ * @param {boolean} [insidePlotArea]
140
+ * Whether to verifiy that the points are inside the plotArea
141
+ *
142
+ * @param {boolean} [useInvertedPersp]
143
+ * Whether to use inverted perspective in calculations
144
+ *
145
+ * @return {Array<Highcharts.Position3dObject>}
146
+ * An array of transformed points
147
+ *
148
+ * @requires highcharts-3d
149
+ */
150
+ var perspective = H.perspective = function (points,
151
+ chart,
152
+ insidePlotArea,
153
+ useInvertedPersp) {
154
+ var options3d = chart.options.chart.options3d,
155
+ /* The useInvertedPersp argument is used for
156
+ * inverted charts with already inverted elements,
157
+ * such as dataLabels or tooltip positions.
158
+ */
159
+ inverted = pick(useInvertedPersp,
160
+ insidePlotArea ? chart.inverted : false),
161
+ origin = {
162
+ x: chart.plotWidth / 2,
163
+ y: chart.plotHeight / 2,
164
+ z: options3d.depth / 2,
165
+ vd: pick(options3d.depth, 1) * pick(options3d.viewDistance, 0)
166
+ },
167
+ scale = chart.scale3d || 1,
168
+ beta = deg2rad * options3d.beta * (inverted ? -1 : 1),
169
+ alpha = deg2rad * options3d.alpha * (inverted ? -1 : 1),
170
+ angles = {
171
+ cosA: Math.cos(alpha),
172
+ cosB: Math.cos(-beta),
173
+ sinA: Math.sin(alpha),
174
+ sinB: Math.sin(-beta)
175
+ };
176
+ if (!insidePlotArea) {
177
+ origin.x += chart.plotLeft;
178
+ origin.y += chart.plotTop;
179
+ }
180
+ // Transform each point
181
+ return points.map(function (point) {
182
+ var rotated = rotate3D((inverted ? point.y : point.x) - origin.x, (inverted ? point.x : point.y) - origin.y, (point.z || 0) - origin.z,
183
+ angles),
184
+ // Apply perspective
185
+ coordinate = perspective3D(rotated,
186
+ origin,
187
+ origin.vd);
188
+ // Apply translation
189
+ coordinate.x = coordinate.x * scale + origin.x;
190
+ coordinate.y = coordinate.y * scale + origin.y;
191
+ coordinate.z = rotated.z * scale + origin.z;
192
+ return {
193
+ x: (inverted ? coordinate.y : coordinate.x),
194
+ y: (inverted ? coordinate.x : coordinate.y),
195
+ z: coordinate.z
196
+ };
197
+ });
198
+ };
199
+ /**
200
+ * Calculate a distance from camera to points - made for calculating zIndex of
201
+ * scatter points.
202
+ *
203
+ * @private
204
+ * @function Highcharts.pointCameraDistance
205
+ *
206
+ * @param {Highcharts.Dictionary<number>} coordinates
207
+ * Coordinates of the specific point
208
+ *
209
+ * @param {Highcharts.Chart} chart
210
+ * Related chart
211
+ *
212
+ * @return {number}
213
+ * Distance from camera to point
214
+ *
215
+ * @requires highcharts-3d
216
+ */
217
+ var pointCameraDistance = H.pointCameraDistance = function (coordinates,
218
+ chart) {
219
+ var options3d = chart.options.chart.options3d,
220
+ cameraPosition = {
221
+ x: chart.plotWidth / 2,
222
+ y: chart.plotHeight / 2,
223
+ z: pick(options3d.depth, 1) * pick(options3d.viewDistance, 0) +
224
+ options3d.depth
225
+ },
226
+ // Added support for objects with plotX or x coordinates.
227
+ distance = Math.sqrt(Math.pow(cameraPosition.x - pick(coordinates.plotX,
228
+ coordinates.x), 2) +
229
+ Math.pow(cameraPosition.y - pick(coordinates.plotY,
230
+ coordinates.y), 2) +
231
+ Math.pow(cameraPosition.z - pick(coordinates.plotZ,
232
+ coordinates.z), 2));
233
+ return distance;
234
+ };
235
+ /**
236
+ * Calculate area of a 2D polygon using Shoelace algorithm
237
+ * https://en.wikipedia.org/wiki/Shoelace_formula
238
+ *
239
+ * @private
240
+ * @function Highcharts.shapeArea
241
+ *
242
+ * @param {Array<Highcharts.PositionObject>} vertexes
243
+ * 2D Polygon
244
+ *
245
+ * @return {number}
246
+ * Calculated area
247
+ *
248
+ * @requires highcharts-3d
249
+ */
250
+ var shapeArea = H.shapeArea = function (vertexes) {
251
+ var area = 0,
252
+ i,
253
+ j;
254
+ for (i = 0; i < vertexes.length; i++) {
255
+ j = (i + 1) % vertexes.length;
256
+ area += vertexes[i].x * vertexes[j].y - vertexes[j].x * vertexes[i].y;
257
+ }
258
+ return area / 2;
259
+ };
260
+ /**
261
+ * Calculate area of a 3D polygon after perspective projection
262
+ *
263
+ * @private
264
+ * @function Highcharts.shapeArea3d
265
+ *
266
+ * @param {Array<Highcharts.Position3dObject>} vertexes
267
+ * 3D Polygon
268
+ *
269
+ * @param {Highcharts.Chart} chart
270
+ * Related chart
271
+ *
272
+ * @param {boolean} [insidePlotArea]
273
+ * Whether to verifiy that the points are inside the plotArea
274
+ *
275
+ * @return {number}
276
+ * Calculated area
277
+ *
278
+ * @requires highcharts-3d
279
+ */
280
+ var shapeArea3D = H.shapeArea3d = function (vertexes,
281
+ chart,
282
+ insidePlotArea) {
283
+ return shapeArea(perspective(vertexes,
284
+ chart,
285
+ insidePlotArea));
286
+ };
287
+ var mathModule = {
288
+ perspective: perspective,
289
+ perspective3D: perspective3D,
290
+ pointCameraDistance: pointCameraDistance,
291
+ shapeArea: shapeArea,
292
+ shapeArea3D: shapeArea3D
293
+ };
294
+
295
+ return mathModule;
296
+ });
297
+ _registerModule(_modules, 'Core/Renderer/SVG/SVGRenderer3D.js', [_modules['Core/Animation/AnimationUtilities.js'], _modules['Core/Color/Color.js'], _modules['Core/Globals.js'], _modules['Extensions/Math3D.js'], _modules['Core/Renderer/SVG/SVGElement.js'], _modules['Core/Renderer/SVG/SVGRenderer.js'], _modules['Core/Utilities.js']], function (A, Color, H, Math3D, SVGElement, SVGRenderer, U) {
298
+ /* *
299
+ *
300
+ * (c) 2010-2020 Torstein Honsi
301
+ *
302
+ * Extensions to the SVGRenderer class to enable 3D shapes
303
+ *
304
+ * License: www.highcharts.com/license
305
+ *
306
+ * !!!!!!! SOURCE GETS TRANSPILED BY TYPESCRIPT. EDIT TS FILE ONLY. !!!!!!!
307
+ *
308
+ * */
309
+ var animObject = A.animObject;
310
+ var color = Color.parse;
311
+ var perspective = Math3D.perspective,
312
+ shapeArea = Math3D.shapeArea;
313
+ var defined = U.defined,
314
+ extend = U.extend,
315
+ merge = U.merge,
316
+ objectEach = U.objectEach,
317
+ pick = U.pick;
318
+ var cos = Math.cos,
319
+ PI = Math.PI,
320
+ sin = Math.sin;
321
+ var charts = H.charts,
322
+ deg2rad = H.deg2rad,
323
+ // internal:
324
+ dFactor,
325
+ element3dMethods,
326
+ cuboidMethods;
327
+ /*
328
+ EXTENSION TO THE SVG-RENDERER TO ENABLE 3D SHAPES
329
+ */
330
+ // HELPER METHODS
331
+ dFactor = (4 * (Math.sqrt(2) - 1) / 3) / (PI / 2);
332
+ /* eslint-disable no-invalid-this, valid-jsdoc */
333
+ /**
334
+ * Method to construct a curved path. Can 'wrap' around more then 180 degrees.
335
+ * @private
336
+ */
337
+ function curveTo(cx, cy, rx, ry, start, end, dx, dy) {
338
+ var result = [],
339
+ arcAngle = end - start;
340
+ if ((end > start) && (end - start > Math.PI / 2 + 0.0001)) {
341
+ result = result.concat(curveTo(cx, cy, rx, ry, start, start + (Math.PI / 2), dx, dy));
342
+ result = result.concat(curveTo(cx, cy, rx, ry, start + (Math.PI / 2), end, dx, dy));
343
+ return result;
344
+ }
345
+ if ((end < start) && (start - end > Math.PI / 2 + 0.0001)) {
346
+ result = result.concat(curveTo(cx, cy, rx, ry, start, start - (Math.PI / 2), dx, dy));
347
+ result = result.concat(curveTo(cx, cy, rx, ry, start - (Math.PI / 2), end, dx, dy));
348
+ return result;
349
+ }
350
+ return [[
351
+ 'C',
352
+ cx + (rx * Math.cos(start)) -
353
+ ((rx * dFactor * arcAngle) * Math.sin(start)) + dx,
354
+ cy + (ry * Math.sin(start)) +
355
+ ((ry * dFactor * arcAngle) * Math.cos(start)) + dy,
356
+ cx + (rx * Math.cos(end)) +
357
+ ((rx * dFactor * arcAngle) * Math.sin(end)) + dx,
358
+ cy + (ry * Math.sin(end)) -
359
+ ((ry * dFactor * arcAngle) * Math.cos(end)) + dy,
360
+ cx + (rx * Math.cos(end)) + dx,
361
+ cy + (ry * Math.sin(end)) + dy
362
+ ]];
363
+ }
364
+ SVGRenderer.prototype.toLinePath = function (points, closed) {
365
+ var result = [];
366
+ // Put "L x y" for each point
367
+ points.forEach(function (point) {
368
+ result.push(['L', point.x, point.y]);
369
+ });
370
+ if (points.length) {
371
+ // Set the first element to M
372
+ result[0][0] = 'M';
373
+ // If it is a closed line, add Z
374
+ if (closed) {
375
+ result.push(['Z']);
376
+ }
377
+ }
378
+ return result;
379
+ };
380
+ SVGRenderer.prototype.toLineSegments = function (points) {
381
+ var result = [],
382
+ m = true;
383
+ points.forEach(function (point) {
384
+ result.push(m ? ['M', point.x, point.y] : ['L', point.x, point.y]);
385
+ m = !m;
386
+ });
387
+ return result;
388
+ };
389
+ // A 3-D Face is defined by it's 3D vertexes, and is only visible if it's
390
+ // vertexes are counter-clockwise (Back-face culling). It is used as a
391
+ // polyhedron Element
392
+ SVGRenderer.prototype.face3d = function (args) {
393
+ var renderer = this,
394
+ ret = this.createElement('path');
395
+ ret.vertexes = [];
396
+ ret.insidePlotArea = false;
397
+ ret.enabled = true;
398
+ ret.attr = function (hash) {
399
+ if (typeof hash === 'object' &&
400
+ (defined(hash.enabled) ||
401
+ defined(hash.vertexes) ||
402
+ defined(hash.insidePlotArea))) {
403
+ this.enabled = pick(hash.enabled, this.enabled);
404
+ this.vertexes = pick(hash.vertexes, this.vertexes);
405
+ this.insidePlotArea = pick(hash.insidePlotArea, this.insidePlotArea);
406
+ delete hash.enabled;
407
+ delete hash.vertexes;
408
+ delete hash.insidePlotArea;
409
+ var chart = charts[renderer.chartIndex],
410
+ vertexes2d = perspective(this.vertexes,
411
+ chart,
412
+ this.insidePlotArea),
413
+ path = renderer.toLinePath(vertexes2d,
414
+ true),
415
+ area = shapeArea(vertexes2d),
416
+ visibility = (this.enabled && area > 0) ? 'visible' : 'hidden';
417
+ hash.d = path;
418
+ hash.visibility = visibility;
419
+ }
420
+ return SVGElement.prototype.attr.apply(this, arguments);
421
+ };
422
+ ret.animate = function (params) {
423
+ if (typeof params === 'object' &&
424
+ (defined(params.enabled) ||
425
+ defined(params.vertexes) ||
426
+ defined(params.insidePlotArea))) {
427
+ this.enabled = pick(params.enabled, this.enabled);
428
+ this.vertexes = pick(params.vertexes, this.vertexes);
429
+ this.insidePlotArea = pick(params.insidePlotArea, this.insidePlotArea);
430
+ delete params.enabled;
431
+ delete params.vertexes;
432
+ delete params.insidePlotArea;
433
+ var chart = charts[renderer.chartIndex],
434
+ vertexes2d = perspective(this.vertexes,
435
+ chart,
436
+ this.insidePlotArea),
437
+ path = renderer.toLinePath(vertexes2d,
438
+ true),
439
+ area = shapeArea(vertexes2d),
440
+ visibility = (this.enabled && area > 0) ? 'visible' : 'hidden';
441
+ params.d = path;
442
+ this.attr('visibility', visibility);
443
+ }
444
+ return SVGElement.prototype.animate.apply(this, arguments);
445
+ };
446
+ return ret.attr(args);
447
+ };
448
+ // A Polyhedron is a handy way of defining a group of 3-D faces. It's only
449
+ // attribute is `faces`, an array of attributes of each one of it's Face3D
450
+ // instances.
451
+ SVGRenderer.prototype.polyhedron = function (args) {
452
+ var renderer = this,
453
+ result = this.g(),
454
+ destroy = result.destroy;
455
+ if (!this.styledMode) {
456
+ result.attr({
457
+ 'stroke-linejoin': 'round'
458
+ });
459
+ }
460
+ result.faces = [];
461
+ // destroy all children
462
+ result.destroy = function () {
463
+ for (var i = 0; i < result.faces.length; i++) {
464
+ result.faces[i].destroy();
465
+ }
466
+ return destroy.call(this);
467
+ };
468
+ result.attr = function (hash, val, complete, continueAnimation) {
469
+ if (typeof hash === 'object' && defined(hash.faces)) {
470
+ while (result.faces.length > hash.faces.length) {
471
+ result.faces.pop().destroy();
472
+ }
473
+ while (result.faces.length < hash.faces.length) {
474
+ result.faces.push(renderer.face3d().add(result));
475
+ }
476
+ for (var i = 0; i < hash.faces.length; i++) {
477
+ if (renderer.styledMode) {
478
+ delete hash.faces[i].fill;
479
+ }
480
+ result.faces[i].attr(hash.faces[i], null, complete, continueAnimation);
481
+ }
482
+ delete hash.faces;
483
+ }
484
+ return SVGElement.prototype.attr.apply(this, arguments);
485
+ };
486
+ result.animate = function (params, duration, complete) {
487
+ if (params && params.faces) {
488
+ while (result.faces.length > params.faces.length) {
489
+ result.faces.pop().destroy();
490
+ }
491
+ while (result.faces.length < params.faces.length) {
492
+ result.faces.push(renderer.face3d().add(result));
493
+ }
494
+ for (var i = 0; i < params.faces.length; i++) {
495
+ result.faces[i].animate(params.faces[i], duration, complete);
496
+ }
497
+ delete params.faces;
498
+ }
499
+ return SVGElement.prototype.animate.apply(this, arguments);
500
+ };
501
+ return result.attr(args);
502
+ };
503
+ // Base, abstract prototype member for 3D elements
504
+ element3dMethods = {
505
+ /**
506
+ * The init is used by base - renderer.Element
507
+ * @private
508
+ */
509
+ initArgs: function (args) {
510
+ var elem3d = this,
511
+ renderer = elem3d.renderer,
512
+ paths = renderer[elem3d.pathType + 'Path'](args),
513
+ zIndexes = paths.zIndexes;
514
+ // build parts
515
+ elem3d.parts.forEach(function (part) {
516
+ elem3d[part] = renderer.path(paths[part]).attr({
517
+ 'class': 'highcharts-3d-' + part,
518
+ zIndex: zIndexes[part] || 0
519
+ }).add(elem3d);
520
+ });
521
+ elem3d.attr({
522
+ 'stroke-linejoin': 'round',
523
+ zIndex: zIndexes.group
524
+ });
525
+ // store original destroy
526
+ elem3d.originalDestroy = elem3d.destroy;
527
+ elem3d.destroy = elem3d.destroyParts;
528
+ // Store information if any side of element was rendered by force.
529
+ elem3d.forcedSides = paths.forcedSides;
530
+ },
531
+ /**
532
+ * Single property setter that applies options to each part
533
+ * @private
534
+ */
535
+ singleSetterForParts: function (prop, val, values, verb, duration, complete) {
536
+ var elem3d = this,
537
+ newAttr = {},
538
+ optionsToApply = [null,
539
+ null, (verb || 'attr'),
540
+ duration,
541
+ complete],
542
+ hasZIndexes = values && values.zIndexes;
543
+ if (!values) {
544
+ newAttr[prop] = val;
545
+ optionsToApply[0] = newAttr;
546
+ }
547
+ else {
548
+ // It is needed to deal with the whole group zIndexing
549
+ // in case of graph rotation
550
+ if (hasZIndexes && hasZIndexes.group) {
551
+ this.attr({
552
+ zIndex: hasZIndexes.group
553
+ });
554
+ }
555
+ objectEach(values, function (partVal, part) {
556
+ newAttr[part] = {};
557
+ newAttr[part][prop] = partVal;
558
+ // include zIndexes if provided
559
+ if (hasZIndexes) {
560
+ newAttr[part].zIndex = values.zIndexes[part] || 0;
561
+ }
562
+ });
563
+ optionsToApply[1] = newAttr;
564
+ }
565
+ return elem3d.processParts.apply(elem3d, optionsToApply);
566
+ },
567
+ /**
568
+ * Calls function for each part. Used for attr, animate and destroy.
569
+ * @private
570
+ */
571
+ processParts: function (props, partsProps, verb, duration, complete) {
572
+ var elem3d = this;
573
+ elem3d.parts.forEach(function (part) {
574
+ // if different props for different parts
575
+ if (partsProps) {
576
+ props = pick(partsProps[part], false);
577
+ }
578
+ // only if something to set, but allow undefined
579
+ if (props !== false) {
580
+ elem3d[part][verb](props, duration, complete);
581
+ }
582
+ });
583
+ return elem3d;
584
+ },
585
+ /**
586
+ * Destroy all parts
587
+ * @private
588
+ */
589
+ destroyParts: function () {
590
+ this.processParts(null, null, 'destroy');
591
+ return this.originalDestroy();
592
+ }
593
+ };
594
+ // CUBOID
595
+ cuboidMethods = merge(element3dMethods, {
596
+ parts: ['front', 'top', 'side'],
597
+ pathType: 'cuboid',
598
+ attr: function (args, val, complete, continueAnimation) {
599
+ // Resolve setting attributes by string name
600
+ if (typeof args === 'string' && typeof val !== 'undefined') {
601
+ var key = args;
602
+ args = {};
603
+ args[key] = val;
604
+ }
605
+ if (args.shapeArgs || defined(args.x)) {
606
+ return this.singleSetterForParts('d', null, this.renderer[this.pathType + 'Path'](args.shapeArgs || args));
607
+ }
608
+ return SVGElement.prototype.attr.call(this, args, void 0, complete, continueAnimation);
609
+ },
610
+ animate: function (args, duration, complete) {
611
+ if (defined(args.x) && defined(args.y)) {
612
+ var paths = this.renderer[this.pathType + 'Path'](args),
613
+ forcedSides = paths.forcedSides;
614
+ this.singleSetterForParts('d', null, paths, 'animate', duration, complete);
615
+ this.attr({
616
+ zIndex: paths.zIndexes.group
617
+ });
618
+ // If sides that are forced to render changed, recalculate colors.
619
+ if (forcedSides !== this.forcedSides) {
620
+ this.forcedSides = forcedSides;
621
+ cuboidMethods.fillSetter.call(this, this.fill);
622
+ }
623
+ }
624
+ else {
625
+ SVGElement.prototype.animate.call(this, args, duration, complete);
626
+ }
627
+ return this;
628
+ },
629
+ fillSetter: function (fill) {
630
+ var elem3d = this;
631
+ elem3d.forcedSides = elem3d.forcedSides || [];
632
+ elem3d.singleSetterForParts('fill', null, {
633
+ front: fill,
634
+ // Do not change color if side was forced to render.
635
+ top: color(fill).brighten(elem3d.forcedSides.indexOf('top') >= 0 ? 0 : 0.1).get(),
636
+ side: color(fill).brighten(elem3d.forcedSides.indexOf('side') >= 0 ? 0 : -0.1).get()
637
+ });
638
+ // fill for animation getter (#6776)
639
+ elem3d.color = elem3d.fill = fill;
640
+ return elem3d;
641
+ }
642
+ });
643
+ // set them up
644
+ SVGRenderer.prototype.elements3d = {
645
+ base: element3dMethods,
646
+ cuboid: cuboidMethods
647
+ };
648
+ /**
649
+ * return result, generalization
650
+ * @private
651
+ * @requires highcharts-3d
652
+ */
653
+ SVGRenderer.prototype.element3d = function (type, shapeArgs) {
654
+ // base
655
+ var ret = this.g();
656
+ // extend
657
+ extend(ret, this.elements3d[type]);
658
+ // init
659
+ ret.initArgs(shapeArgs);
660
+ // return
661
+ return ret;
662
+ };
663
+ // generelized, so now use simply
664
+ SVGRenderer.prototype.cuboid = function (shapeArgs) {
665
+ return this.element3d('cuboid', shapeArgs);
666
+ };
667
+ // Generates a cuboid path and zIndexes
668
+ SVGRenderer.prototype.cuboidPath = function (shapeArgs) {
669
+ var x = shapeArgs.x,
670
+ y = shapeArgs.y,
671
+ z = shapeArgs.z || 0,
672
+ // For side calculation (right/left)
673
+ // there is a need for height (and other shapeArgs arguments)
674
+ // to be at least 1px
675
+ h = shapeArgs.height,
676
+ w = shapeArgs.width,
677
+ d = shapeArgs.depth,
678
+ chart = charts[this.chartIndex],
679
+ front,
680
+ back,
681
+ top,
682
+ bottom,
683
+ left,
684
+ right,
685
+ shape,
686
+ path1,
687
+ path2,
688
+ path3,
689
+ isFront,
690
+ isTop,
691
+ isRight,
692
+ options3d = chart.options.chart.options3d,
693
+ alpha = options3d.alpha,
694
+ // Priority for x axis is the biggest,
695
+ // because of x direction has biggest influence on zIndex
696
+ incrementX = 1000000,
697
+ // y axis has the smallest priority in case of our charts
698
+ // (needs to be set because of stacking)
699
+ incrementY = 10,
700
+ incrementZ = 100,
701
+ zIndex = 0,
702
+ // The 8 corners of the cube
703
+ pArr = [{
704
+ x: x,
705
+ y: y,
706
+ z: z
707
+ }, {
708
+ x: x + w,
709
+ y: y,
710
+ z: z
711
+ }, {
712
+ x: x + w,
713
+ y: y + h,
714
+ z: z
715
+ }, {
716
+ x: x,
717
+ y: y + h,
718
+ z: z
719
+ }, {
720
+ x: x,
721
+ y: y + h,
722
+ z: z + d
723
+ }, {
724
+ x: x + w,
725
+ y: y + h,
726
+ z: z + d
727
+ }, {
728
+ x: x + w,
729
+ y: y,
730
+ z: z + d
731
+ }, {
732
+ x: x,
733
+ y: y,
734
+ z: z + d
735
+ }],
736
+ forcedSides = [],
737
+ pickShape;
738
+ // apply perspective
739
+ pArr = perspective(pArr, chart, shapeArgs.insidePlotArea);
740
+ /**
741
+ * helper method to decide which side is visible
742
+ * @private
743
+ */
744
+ function mapSidePath(i) {
745
+ // Added support for 0 value in columns, where height is 0
746
+ // but the shape is rendered.
747
+ // Height is used from 1st to 6th element of pArr
748
+ if (h === 0 && i > 1 && i < 6) { // [2, 3, 4, 5]
749
+ return {
750
+ x: pArr[i].x,
751
+ // when height is 0 instead of cuboid we render plane
752
+ // so it is needed to add fake 10 height to imitate cuboid
753
+ // for side calculation
754
+ y: pArr[i].y + 10,
755
+ z: pArr[i].z
756
+ };
757
+ }
758
+ // It is needed to calculate dummy sides (front/back) for breaking
759
+ // points in case of x and depth values. If column has side,
760
+ // it means that x values of front and back side are different.
761
+ if (pArr[0].x === pArr[7].x && i >= 4) { // [4, 5, 6, 7]
762
+ return {
763
+ x: pArr[i].x + 10,
764
+ // when height is 0 instead of cuboid we render plane
765
+ // so it is needed to add fake 10 height to imitate cuboid
766
+ // for side calculation
767
+ y: pArr[i].y,
768
+ z: pArr[i].z
769
+ };
770
+ }
771
+ // Added dummy depth
772
+ if (d === 0 && i < 2 || i > 5) { // [0, 1, 6, 7]
773
+ return {
774
+ x: pArr[i].x,
775
+ // when height is 0 instead of cuboid we render plane
776
+ // so it is needed to add fake 10 height to imitate cuboid
777
+ // for side calculation
778
+ y: pArr[i].y,
779
+ z: pArr[i].z + 10
780
+ };
781
+ }
782
+ return pArr[i];
783
+ }
784
+ /**
785
+ * method creating the final side
786
+ * @private
787
+ */
788
+ function mapPath(i) {
789
+ return pArr[i];
790
+ }
791
+ /**
792
+ * First value - path with specific face
793
+ * Second value - added information about side for later calculations.
794
+ * Possible second values are 0 for path1, 1 for path2 and -1 for no path
795
+ * chosen.
796
+ * Third value - string containing information about current side
797
+ * of cuboid for forcing side rendering.
798
+ * @private
799
+ */
800
+ pickShape = function (verticesIndex1, verticesIndex2, side) {
801
+ var ret = [[], -1],
802
+ // An array of vertices for cuboid face
803
+ face1 = verticesIndex1.map(mapPath),
804
+ face2 = verticesIndex2.map(mapPath),
805
+ // dummy face is calculated the same way as standard face,
806
+ // but if cuboid height is 0 additional height is added so it is
807
+ // possible to use this vertices array for visible face calculation
808
+ dummyFace1 = verticesIndex1.map(mapSidePath),
809
+ dummyFace2 = verticesIndex2.map(mapSidePath);
810
+ if (shapeArea(face1) < 0) {
811
+ ret = [face1, 0];
812
+ }
813
+ else if (shapeArea(face2) < 0) {
814
+ ret = [face2, 1];
815
+ }
816
+ else if (side) {
817
+ forcedSides.push(side);
818
+ if (shapeArea(dummyFace1) < 0) {
819
+ ret = [face1, 0];
820
+ }
821
+ else if (shapeArea(dummyFace2) < 0) {
822
+ ret = [face2, 1];
823
+ }
824
+ else {
825
+ ret = [face1, 0]; // force side calculation.
826
+ }
827
+ }
828
+ return ret;
829
+ };
830
+ // front or back
831
+ front = [3, 2, 1, 0];
832
+ back = [7, 6, 5, 4];
833
+ shape = pickShape(front, back, 'front');
834
+ path1 = shape[0];
835
+ isFront = shape[1];
836
+ // top or bottom
837
+ top = [1, 6, 7, 0];
838
+ bottom = [4, 5, 2, 3];
839
+ shape = pickShape(top, bottom, 'top');
840
+ path2 = shape[0];
841
+ isTop = shape[1];
842
+ // side
843
+ right = [1, 2, 5, 6];
844
+ left = [0, 7, 4, 3];
845
+ shape = pickShape(right, left, 'side');
846
+ path3 = shape[0];
847
+ isRight = shape[1];
848
+ /* New block used for calculating zIndex. It is basing on X, Y and Z
849
+ position of specific columns. All zIndexes (for X, Y and Z values) are
850
+ added to the final zIndex, where every value has different priority. The
851
+ biggest priority is in X and Z directions, the lowest index is for
852
+ stacked columns (Y direction and the same X and Z positions). Big
853
+ differences between priorities is made because we need to ensure that
854
+ even for big changes in Y and Z parameters all columns will be drawn
855
+ correctly. */
856
+ if (isRight === 1) {
857
+ // It is needed to connect value with current chart width
858
+ // for big chart size.
859
+ zIndex += incrementX * (chart.plotWidth - x);
860
+ }
861
+ else if (!isRight) {
862
+ zIndex += incrementX * x;
863
+ }
864
+ zIndex += incrementY * (!isTop ||
865
+ // Numbers checked empirically
866
+ (alpha >= 0 && alpha <= 180 || alpha < 360 && alpha > 357.5) ?
867
+ chart.plotHeight - y : 10 + y);
868
+ if (isFront === 1) {
869
+ zIndex += incrementZ * (z);
870
+ }
871
+ else if (!isFront) {
872
+ zIndex += incrementZ * (1000 - z);
873
+ }
874
+ return {
875
+ front: this.toLinePath(path1, true),
876
+ top: this.toLinePath(path2, true),
877
+ side: this.toLinePath(path3, true),
878
+ zIndexes: {
879
+ group: Math.round(zIndex)
880
+ },
881
+ forcedSides: forcedSides,
882
+ // additional info about zIndexes
883
+ isFront: isFront,
884
+ isTop: isTop
885
+ }; // #4774
886
+ };
887
+ // SECTORS //
888
+ SVGRenderer.prototype.arc3d = function (attribs) {
889
+ var wrapper = this.g(), renderer = wrapper.renderer, customAttribs = ['x', 'y', 'r', 'innerR', 'start', 'end', 'depth'];
890
+ /**
891
+ * Get custom attributes. Don't mutate the original object and return an
892
+ * object with only custom attr.
893
+ * @private
894
+ */
895
+ function suckOutCustom(params) {
896
+ var hasCA = false,
897
+ ca = {},
898
+ key;
899
+ params = merge(params); // Don't mutate the original object
900
+ for (key in params) {
901
+ if (customAttribs.indexOf(key) !== -1) {
902
+ ca[key] = params[key];
903
+ delete params[key];
904
+ hasCA = true;
905
+ }
906
+ }
907
+ return hasCA ? [ca, params] : false;
908
+ }
909
+ attribs = merge(attribs);
910
+ attribs.alpha = (attribs.alpha || 0) * deg2rad;
911
+ attribs.beta = (attribs.beta || 0) * deg2rad;
912
+ // Create the different sub sections of the shape
913
+ wrapper.top = renderer.path();
914
+ wrapper.side1 = renderer.path();
915
+ wrapper.side2 = renderer.path();
916
+ wrapper.inn = renderer.path();
917
+ wrapper.out = renderer.path();
918
+ // Add all faces
919
+ wrapper.onAdd = function () {
920
+ var parent = wrapper.parentGroup,
921
+ className = wrapper.attr('class');
922
+ wrapper.top.add(wrapper);
923
+ // These faces are added outside the wrapper group because the z index
924
+ // relates to neighbour elements as well
925
+ ['out', 'inn', 'side1', 'side2'].forEach(function (face) {
926
+ wrapper[face]
927
+ .attr({
928
+ 'class': className + ' highcharts-3d-side'
929
+ })
930
+ .add(parent);
931
+ });
932
+ };
933
+ // Cascade to faces
934
+ ['addClass', 'removeClass'].forEach(function (fn) {
935
+ wrapper[fn] = function () {
936
+ var args = arguments;
937
+ ['top', 'out', 'inn', 'side1', 'side2'].forEach(function (face) {
938
+ wrapper[face][fn].apply(wrapper[face], args);
939
+ });
940
+ };
941
+ });
942
+ /**
943
+ * Compute the transformed paths and set them to the composite shapes
944
+ * @private
945
+ */
946
+ wrapper.setPaths = function (attribs) {
947
+ var paths = wrapper.renderer.arc3dPath(attribs),
948
+ zIndex = paths.zTop * 100;
949
+ wrapper.attribs = attribs;
950
+ wrapper.top.attr({ d: paths.top, zIndex: paths.zTop });
951
+ wrapper.inn.attr({ d: paths.inn, zIndex: paths.zInn });
952
+ wrapper.out.attr({ d: paths.out, zIndex: paths.zOut });
953
+ wrapper.side1.attr({ d: paths.side1, zIndex: paths.zSide1 });
954
+ wrapper.side2.attr({ d: paths.side2, zIndex: paths.zSide2 });
955
+ // show all children
956
+ wrapper.zIndex = zIndex;
957
+ wrapper.attr({ zIndex: zIndex });
958
+ // Set the radial gradient center the first time
959
+ if (attribs.center) {
960
+ wrapper.top.setRadialReference(attribs.center);
961
+ delete attribs.center;
962
+ }
963
+ };
964
+ wrapper.setPaths(attribs);
965
+ /**
966
+ * Apply the fill to the top and a darker shade to the sides
967
+ * @private
968
+ */
969
+ wrapper.fillSetter = function (value) {
970
+ var darker = color(value).brighten(-0.1).get();
971
+ this.fill = value;
972
+ this.side1.attr({ fill: darker });
973
+ this.side2.attr({ fill: darker });
974
+ this.inn.attr({ fill: darker });
975
+ this.out.attr({ fill: darker });
976
+ this.top.attr({ fill: value });
977
+ return this;
978
+ };
979
+ // Apply the same value to all. These properties cascade down to the
980
+ // children when set to the composite arc3d.
981
+ ['opacity', 'translateX', 'translateY', 'visibility'].forEach(function (setter) {
982
+ wrapper[setter + 'Setter'] = function (value, key) {
983
+ wrapper[key] = value;
984
+ ['out', 'inn', 'side1', 'side2', 'top'].forEach(function (el) {
985
+ wrapper[el].attr(key, value);
986
+ });
987
+ };
988
+ });
989
+ // Override attr to remove shape attributes and use those to set child paths
990
+ wrapper.attr = function (params) {
991
+ var ca,
992
+ paramArr;
993
+ if (typeof params === 'object') {
994
+ paramArr = suckOutCustom(params);
995
+ if (paramArr) {
996
+ ca = paramArr[0];
997
+ arguments[0] = paramArr[1];
998
+ extend(wrapper.attribs, ca);
999
+ wrapper.setPaths(wrapper.attribs);
1000
+ }
1001
+ }
1002
+ return SVGElement.prototype.attr.apply(wrapper, arguments);
1003
+ };
1004
+ // Override the animate function by sucking out custom parameters related to
1005
+ // the shapes directly, and update the shapes from the animation step.
1006
+ wrapper.animate = function (params, animation, complete) {
1007
+ var paramArr,
1008
+ from = this.attribs,
1009
+ to,
1010
+ anim,
1011
+ randomProp = 'data-' + Math.random().toString(26).substring(2, 9);
1012
+ // Attribute-line properties connected to 3D. These shouldn't have been
1013
+ // in the attribs collection in the first place.
1014
+ delete params.center;
1015
+ delete params.z;
1016
+ delete params.alpha;
1017
+ delete params.beta;
1018
+ anim = animObject(pick(animation, this.renderer.globalAnimation));
1019
+ if (anim.duration) {
1020
+ paramArr = suckOutCustom(params);
1021
+ // Params need to have a property in order for the step to run
1022
+ // (#5765, #7097, #7437)
1023
+ wrapper[randomProp] = 0;
1024
+ params[randomProp] = 1;
1025
+ wrapper[randomProp + 'Setter'] = H.noop;
1026
+ if (paramArr) {
1027
+ to = paramArr[0]; // custom attr
1028
+ anim.step = function (a, fx) {
1029
+ /**
1030
+ * @private
1031
+ */
1032
+ function interpolate(key) {
1033
+ return from[key] + (pick(to[key], from[key]) -
1034
+ from[key]) * fx.pos;
1035
+ }
1036
+ if (fx.prop === randomProp) {
1037
+ fx.elem.setPaths(merge(from, {
1038
+ x: interpolate('x'),
1039
+ y: interpolate('y'),
1040
+ r: interpolate('r'),
1041
+ innerR: interpolate('innerR'),
1042
+ start: interpolate('start'),
1043
+ end: interpolate('end'),
1044
+ depth: interpolate('depth')
1045
+ }));
1046
+ }
1047
+ };
1048
+ }
1049
+ animation = anim; // Only when duration (#5572)
1050
+ }
1051
+ return SVGElement.prototype.animate.call(this, params, animation, complete);
1052
+ };
1053
+ // destroy all children
1054
+ wrapper.destroy = function () {
1055
+ this.top.destroy();
1056
+ this.out.destroy();
1057
+ this.inn.destroy();
1058
+ this.side1.destroy();
1059
+ this.side2.destroy();
1060
+ return SVGElement.prototype.destroy.call(this);
1061
+ };
1062
+ // hide all children
1063
+ wrapper.hide = function () {
1064
+ this.top.hide();
1065
+ this.out.hide();
1066
+ this.inn.hide();
1067
+ this.side1.hide();
1068
+ this.side2.hide();
1069
+ };
1070
+ wrapper.show = function (inherit) {
1071
+ this.top.show(inherit);
1072
+ this.out.show(inherit);
1073
+ this.inn.show(inherit);
1074
+ this.side1.show(inherit);
1075
+ this.side2.show(inherit);
1076
+ };
1077
+ return wrapper;
1078
+ };
1079
+ // Generate the paths required to draw a 3D arc
1080
+ SVGRenderer.prototype.arc3dPath = function (shapeArgs) {
1081
+ var cx = shapeArgs.x, // x coordinate of the center
1082
+ cy = shapeArgs.y, // y coordinate of the center
1083
+ start = shapeArgs.start, // start angle
1084
+ end = shapeArgs.end - 0.00001, // end angle
1085
+ r = shapeArgs.r, // radius
1086
+ ir = shapeArgs.innerR || 0, // inner radius
1087
+ d = shapeArgs.depth || 0, // depth
1088
+ alpha = shapeArgs.alpha, // alpha rotation of the chart
1089
+ beta = shapeArgs.beta; // beta rotation of the chart
1090
+ // Derived Variables
1091
+ var cs = Math.cos(start), // cosinus of the start angle
1092
+ ss = Math.sin(start), // sinus of the start angle
1093
+ ce = Math.cos(end), // cosinus of the end angle
1094
+ se = Math.sin(end), // sinus of the end angle
1095
+ rx = r * Math.cos(beta), // x-radius
1096
+ ry = r * Math.cos(alpha), // y-radius
1097
+ irx = ir * Math.cos(beta), // x-radius (inner)
1098
+ iry = ir * Math.cos(alpha), // y-radius (inner)
1099
+ dx = d * Math.sin(beta), // distance between top and bottom in x
1100
+ dy = d * Math.sin(alpha); // distance between top and bottom in y
1101
+ // TOP
1102
+ var top = [
1103
+ ['M',
1104
+ cx + (rx * cs),
1105
+ cy + (ry * ss)]
1106
+ ];
1107
+ top = top.concat(curveTo(cx, cy, rx, ry, start, end, 0, 0));
1108
+ top.push([
1109
+ 'L', cx + (irx * ce), cy + (iry * se)
1110
+ ]);
1111
+ top = top.concat(curveTo(cx, cy, irx, iry, end, start, 0, 0));
1112
+ top.push(['Z']);
1113
+ // OUTSIDE
1114
+ var b = (beta > 0 ? Math.PI / 2 : 0),
1115
+ a = (alpha > 0 ? 0 : Math.PI / 2);
1116
+ var start2 = start > -b ? start : (end > -b ? -b : start),
1117
+ end2 = end < PI - a ? end : (start < PI - a ? PI - a : end),
1118
+ midEnd = 2 * PI - a;
1119
+ // When slice goes over bottom middle, need to add both, left and right
1120
+ // outer side. Additionally, when we cross right hand edge, create sharp
1121
+ // edge. Outer shape/wall:
1122
+ //
1123
+ // -------
1124
+ // / ^ \
1125
+ // 4) / / \ \ 1)
1126
+ // / / \ \
1127
+ // / / \ \
1128
+ // (c)=> ==== ==== <=(d)
1129
+ // \ \ / /
1130
+ // \ \<=(a)/ /
1131
+ // \ \ / / <=(b)
1132
+ // 3) \ v / 2)
1133
+ // -------
1134
+ //
1135
+ // (a) - inner side
1136
+ // (b) - outer side
1137
+ // (c) - left edge (sharp)
1138
+ // (d) - right edge (sharp)
1139
+ // 1..n - rendering order for startAngle = 0, when set to e.g 90, order
1140
+ // changes clockwise (1->2, 2->3, n->1) and counterclockwise for negative
1141
+ // startAngle
1142
+ var out = [
1143
+ ['M',
1144
+ cx + (rx * cos(start2)),
1145
+ cy + (ry * sin(start2))]
1146
+ ];
1147
+ out = out.concat(curveTo(cx, cy, rx, ry, start2, end2, 0, 0));
1148
+ // When shape is wide, it can cross both, (c) and (d) edges, when using
1149
+ // startAngle
1150
+ if (end > midEnd && start < midEnd) {
1151
+ // Go to outer side
1152
+ out.push([
1153
+ 'L', cx + (rx * cos(end2)) + dx, cy + (ry * sin(end2)) + dy
1154
+ ]);
1155
+ // Curve to the right edge of the slice (d)
1156
+ out = out.concat(curveTo(cx, cy, rx, ry, end2, midEnd, dx, dy));
1157
+ // Go to the inner side
1158
+ out.push([
1159
+ 'L', cx + (rx * cos(midEnd)), cy + (ry * sin(midEnd))
1160
+ ]);
1161
+ // Curve to the true end of the slice
1162
+ out = out.concat(curveTo(cx, cy, rx, ry, midEnd, end, 0, 0));
1163
+ // Go to the outer side
1164
+ out.push([
1165
+ 'L', cx + (rx * cos(end)) + dx, cy + (ry * sin(end)) + dy
1166
+ ]);
1167
+ // Go back to middle (d)
1168
+ out = out.concat(curveTo(cx, cy, rx, ry, end, midEnd, dx, dy));
1169
+ out.push([
1170
+ 'L', cx + (rx * cos(midEnd)), cy + (ry * sin(midEnd))
1171
+ ]);
1172
+ // Go back to the left edge
1173
+ out = out.concat(curveTo(cx, cy, rx, ry, midEnd, end2, 0, 0));
1174
+ // But shape can cross also only (c) edge:
1175
+ }
1176
+ else if (end > PI - a && start < PI - a) {
1177
+ // Go to outer side
1178
+ out.push([
1179
+ 'L',
1180
+ cx + (rx * Math.cos(end2)) + dx,
1181
+ cy + (ry * Math.sin(end2)) + dy
1182
+ ]);
1183
+ // Curve to the true end of the slice
1184
+ out = out.concat(curveTo(cx, cy, rx, ry, end2, end, dx, dy));
1185
+ // Go to the inner side
1186
+ out.push([
1187
+ 'L', cx + (rx * Math.cos(end)), cy + (ry * Math.sin(end))
1188
+ ]);
1189
+ // Go back to the artifical end2
1190
+ out = out.concat(curveTo(cx, cy, rx, ry, end, end2, 0, 0));
1191
+ }
1192
+ out.push([
1193
+ 'L', cx + (rx * Math.cos(end2)) + dx, cy + (ry * Math.sin(end2)) + dy
1194
+ ]);
1195
+ out = out.concat(curveTo(cx, cy, rx, ry, end2, start2, dx, dy));
1196
+ out.push(['Z']);
1197
+ // INSIDE
1198
+ var inn = [
1199
+ ['M',
1200
+ cx + (irx * cs),
1201
+ cy + (iry * ss)]
1202
+ ];
1203
+ inn = inn.concat(curveTo(cx, cy, irx, iry, start, end, 0, 0));
1204
+ inn.push([
1205
+ 'L', cx + (irx * Math.cos(end)) + dx, cy + (iry * Math.sin(end)) + dy
1206
+ ]);
1207
+ inn = inn.concat(curveTo(cx, cy, irx, iry, end, start, dx, dy));
1208
+ inn.push(['Z']);
1209
+ // SIDES
1210
+ var side1 = [
1211
+ ['M',
1212
+ cx + (rx * cs),
1213
+ cy + (ry * ss)],
1214
+ ['L',
1215
+ cx + (rx * cs) + dx,
1216
+ cy + (ry * ss) + dy],
1217
+ ['L',
1218
+ cx + (irx * cs) + dx,
1219
+ cy + (iry * ss) + dy],
1220
+ ['L',
1221
+ cx + (irx * cs),
1222
+ cy + (iry * ss)],
1223
+ ['Z']
1224
+ ];
1225
+ var side2 = [
1226
+ ['M',
1227
+ cx + (rx * ce),
1228
+ cy + (ry * se)],
1229
+ ['L',
1230
+ cx + (rx * ce) + dx,
1231
+ cy + (ry * se) + dy],
1232
+ ['L',
1233
+ cx + (irx * ce) + dx,
1234
+ cy + (iry * se) + dy],
1235
+ ['L',
1236
+ cx + (irx * ce),
1237
+ cy + (iry * se)],
1238
+ ['Z']
1239
+ ];
1240
+ // correction for changed position of vanishing point caused by alpha and
1241
+ // beta rotations
1242
+ var angleCorr = Math.atan2(dy, -dx),
1243
+ angleEnd = Math.abs(end + angleCorr),
1244
+ angleStart = Math.abs(start + angleCorr),
1245
+ angleMid = Math.abs((start + end) / 2 + angleCorr);
1246
+ /**
1247
+ * set to 0-PI range
1248
+ * @private
1249
+ */
1250
+ function toZeroPIRange(angle) {
1251
+ angle = angle % (2 * Math.PI);
1252
+ if (angle > Math.PI) {
1253
+ angle = 2 * Math.PI - angle;
1254
+ }
1255
+ return angle;
1256
+ }
1257
+ angleEnd = toZeroPIRange(angleEnd);
1258
+ angleStart = toZeroPIRange(angleStart);
1259
+ angleMid = toZeroPIRange(angleMid);
1260
+ // *1e5 is to compensate pInt in zIndexSetter
1261
+ var incPrecision = 1e5,
1262
+ a1 = angleMid * incPrecision,
1263
+ a2 = angleStart * incPrecision,
1264
+ a3 = angleEnd * incPrecision;
1265
+ return {
1266
+ top: top,
1267
+ // max angle is PI, so this is always higher
1268
+ zTop: Math.PI * incPrecision + 1,
1269
+ out: out,
1270
+ zOut: Math.max(a1, a2, a3),
1271
+ inn: inn,
1272
+ zInn: Math.max(a1, a2, a3),
1273
+ side1: side1,
1274
+ zSide1: a3 * 0.99,
1275
+ side2: side2,
1276
+ zSide2: a2 * 0.99
1277
+ };
1278
+ };
1279
+
1280
+ return SVGRenderer;
1281
+ });
1282
+ _registerModule(_modules, 'Extensions/Oldie/VMLAxis3D.js', [_modules['Core/Utilities.js']], function (U) {
1283
+ /* *
1284
+ *
1285
+ * (c) 2010-2020 Torstein Honsi
1286
+ *
1287
+ * Extension to the VML Renderer
1288
+ *
1289
+ * License: www.highcharts.com/license
1290
+ *
1291
+ * !!!!!!! SOURCE GETS TRANSPILED BY TYPESCRIPT. EDIT TS FILE ONLY. !!!!!!!
1292
+ *
1293
+ * */
1294
+ var addEvent = U.addEvent;
1295
+ /* eslint-disable valid-jsdoc */
1296
+ var VMLAxis3DAdditions = /** @class */ (function () {
1297
+ /* *
1298
+ *
1299
+ * Constructors
1300
+ *
1301
+ * */
1302
+ function VMLAxis3DAdditions(axis) {
1303
+ this.axis = axis;
1304
+ }
1305
+ return VMLAxis3DAdditions;
1306
+ }());
1307
+ var VMLAxis3D = /** @class */ (function () {
1308
+ function VMLAxis3D() {
1309
+ }
1310
+ /* *
1311
+ *
1312
+ * Static Properties
1313
+ *
1314
+ * */
1315
+ VMLAxis3D.compose = function (AxisClass) {
1316
+ AxisClass.keepProps.push('vml');
1317
+ addEvent(AxisClass, 'init', VMLAxis3D.onInit);
1318
+ addEvent(AxisClass, 'render', VMLAxis3D.onRender);
1319
+ };
1320
+ /**
1321
+ * @private
1322
+ */
1323
+ VMLAxis3D.onInit = function () {
1324
+ var axis = this;
1325
+ if (!axis.vml) {
1326
+ axis.vml = new VMLAxis3DAdditions(axis);
1327
+ }
1328
+ };
1329
+ /**
1330
+ * @private
1331
+ */
1332
+ VMLAxis3D.onRender = function () {
1333
+ var axis = this;
1334
+ var vml = axis.vml;
1335
+ // VML doesn't support a negative z-index
1336
+ if (vml.sideFrame) {
1337
+ vml.sideFrame.css({ zIndex: 0 });
1338
+ vml.sideFrame.front.attr({
1339
+ fill: vml.sideFrame.color
1340
+ });
1341
+ }
1342
+ if (vml.bottomFrame) {
1343
+ vml.bottomFrame.css({ zIndex: 1 });
1344
+ vml.bottomFrame.front.attr({
1345
+ fill: vml.bottomFrame.color
1346
+ });
1347
+ }
1348
+ if (vml.backFrame) {
1349
+ vml.backFrame.css({ zIndex: 0 });
1350
+ vml.backFrame.front.attr({
1351
+ fill: vml.backFrame.color
1352
+ });
1353
+ }
1354
+ };
1355
+ return VMLAxis3D;
1356
+ }());
1357
+
1358
+ return VMLAxis3D;
1359
+ });
1360
+ _registerModule(_modules, 'Extensions/Oldie/VMLRenderer3D.js', [_modules['Core/Axis/Axis.js'], _modules['Core/Utilities.js'], _modules['Extensions/Oldie/VMLAxis3D.js']], function (Axis, U, VMLAxis3D) {
1361
+ /* *
1362
+ *
1363
+ * (c) 2010-2020 Torstein Honsi
1364
+ *
1365
+ * Extension to the VML Renderer
1366
+ *
1367
+ * License: www.highcharts.com/license
1368
+ *
1369
+ * !!!!!!! SOURCE GETS TRANSPILED BY TYPESCRIPT. EDIT TS FILE ONLY. !!!!!!!
1370
+ *
1371
+ * */
1372
+ var setOptions = U.setOptions;
1373
+ var VMLRenderer3D = /** @class */ (function () {
1374
+ function VMLRenderer3D() {
1375
+ }
1376
+ /* *
1377
+ *
1378
+ * Static Properties
1379
+ *
1380
+ * */
1381
+ VMLRenderer3D.compose = function (vmlClass, svgClass) {
1382
+ var svgProto = svgClass.prototype;
1383
+ var vmlProto = vmlClass.prototype;
1384
+ setOptions({ animate: false });
1385
+ vmlProto.face3d = svgProto.face3d;
1386
+ vmlProto.polyhedron = svgProto.polyhedron;
1387
+ vmlProto.elements3d = svgProto.elements3d;
1388
+ vmlProto.element3d = svgProto.element3d;
1389
+ vmlProto.cuboid = svgProto.cuboid;
1390
+ vmlProto.cuboidPath = svgProto.cuboidPath;
1391
+ vmlProto.toLinePath = svgProto.toLinePath;
1392
+ vmlProto.toLineSegments = svgProto.toLineSegments;
1393
+ vmlProto.arc3d = function (shapeArgs) {
1394
+ var result = svgProto.arc3d.call(this,
1395
+ shapeArgs);
1396
+ result.css({ zIndex: result.zIndex });
1397
+ return result;
1398
+ };
1399
+ vmlProto.arc3dPath = svgProto.arc3dPath;
1400
+ VMLAxis3D.compose(Axis);
1401
+ };
1402
+ return VMLRenderer3D;
1403
+ }());
1404
+
1405
+ return VMLRenderer3D;
1406
+ });
1407
+ _registerModule(_modules, 'Extensions/Oldie/Oldie.js', [_modules['Core/Chart/Chart.js'], _modules['Core/Color/Color.js'], _modules['Core/Globals.js'], _modules['Core/Pointer.js'], _modules['Core/Renderer/SVG/SVGElement.js'], _modules['Core/Renderer/SVG/SVGRenderer3D.js'], _modules['Core/Utilities.js'], _modules['Extensions/Oldie/VMLRenderer3D.js']], function (Chart, Color, H, Pointer, SVGElement, SVGRenderer, U, VMLRenderer3D) {
33
1408
  /* *
34
1409
  *
35
1410
  * (c) 2010-2020 Torstein Honsi
@@ -63,9 +1438,9 @@
63
1438
  offset = U.offset,
64
1439
  pick = U.pick,
65
1440
  pInt = U.pInt,
1441
+ setOptions = U.setOptions,
66
1442
  uniqueKey = U.uniqueKey;
67
1443
  var VMLRenderer,
68
- VMLRendererExtension,
69
1444
  VMLElement;
70
1445
  /**
71
1446
  * Path to the pattern image required by VML browsers in order to
@@ -78,7 +1453,7 @@
78
1453
  * @apioption global.VMLRadialGradientURL
79
1454
  */
80
1455
  getOptions().global.VMLRadialGradientURL =
81
- 'http://code.highcharts.com/8.2.0/gfx/vml-radial-gradient.png';
1456
+ 'http://code.highcharts.com/8.2.2/gfx/vml-radial-gradient.png';
82
1457
  // Utilites
83
1458
  if (doc && !doc.defaultView) {
84
1459
  H.getStyle = U.getStyle = function (el, prop) {
@@ -780,23 +2155,25 @@
780
2155
  *
781
2156
  * @augments Highcharts.SVGRenderer
782
2157
  */
783
- VMLRendererExtension = {
784
- Element: VMLElement,
785
- isIE8: win.navigator.userAgent.indexOf('MSIE 8.0') > -1,
786
- /**
787
- * Initialize the VMLRenderer.
788
- *
789
- * @function Highcharts.VMLRenderer#init
790
- * @param {Highcharts.HTMLDOMElement} container
791
- * @param {number} width
792
- * @param {number} height
793
- * @return {void}
794
- */
795
- init: function (container, width, height) {
796
- var renderer = this,
797
- boxWrapper,
798
- box,
799
- css;
2158
+ var VMLRendererExtension = {
2159
+ Element: VMLElement,
2160
+ isIE8: win.navigator.userAgent.indexOf('MSIE 8.0') > -1,
2161
+ /**
2162
+ * Initialize the VMLRenderer.
2163
+ *
2164
+ * @function Highcharts.VMLRenderer#init
2165
+ * @param {Highcharts.HTMLDOMElement} container
2166
+ * @param {number} width
2167
+ * @param {number} height
2168
+ * @return {void}
2169
+ */
2170
+ init: function (container,
2171
+ width,
2172
+ height) {
2173
+ var renderer = this,
2174
+ boxWrapper,
2175
+ box,
2176
+ css;
800
2177
  // Extended SVGRenderer member
801
2178
  this.crispPolyLine = SVGRenderer.prototype.crispPolyLine;
802
2179
  renderer.alignedObjects = [];
@@ -1319,9 +2696,11 @@
1319
2696
  H.VMLRenderer = VMLRenderer = function () {
1320
2697
  this.init.apply(this, arguments);
1321
2698
  };
1322
- VMLRenderer.prototype = merge(SVGRenderer.prototype, VMLRendererExtension);
2699
+ VMLRenderer.prototype = merge(VMLRenderer.prototype, SVGRenderer.prototype, VMLRendererExtension);
1323
2700
  // general renderer
1324
2701
  H.Renderer = VMLRenderer;
2702
+ // 3D additions
2703
+ VMLRenderer3D.compose(VMLRenderer, SVGRenderer);
1325
2704
  }
1326
2705
  SVGRenderer.prototype.getSpanWidth = function (wrapper, tspan) {
1327
2706
  var renderer = this,