@amcharts/amcharts5 5.2.49 → 5.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (887) hide show
  1. package/.internal/charts/flow/Chord.js +151 -199
  2. package/.internal/charts/flow/Chord.js.map +1 -1
  3. package/.internal/charts/flow/ChordDirected.js +46 -66
  4. package/.internal/charts/flow/ChordDirected.js.map +1 -1
  5. package/.internal/charts/flow/ChordLink.js +32 -42
  6. package/.internal/charts/flow/ChordLink.js.map +1 -1
  7. package/.internal/charts/flow/ChordLinkDirected.js +17 -29
  8. package/.internal/charts/flow/ChordLinkDirected.js.map +1 -1
  9. package/.internal/charts/flow/ChordNodes.js +70 -86
  10. package/.internal/charts/flow/ChordNodes.js.map +1 -1
  11. package/.internal/charts/flow/ChordNonRibbon.js +63 -91
  12. package/.internal/charts/flow/ChordNonRibbon.js.map +1 -1
  13. package/.internal/charts/flow/Flow.js +289 -356
  14. package/.internal/charts/flow/Flow.js.map +1 -1
  15. package/.internal/charts/flow/FlowDefaultTheme.js +187 -199
  16. package/.internal/charts/flow/FlowDefaultTheme.js.map +1 -1
  17. package/.internal/charts/flow/FlowLink.js +34 -49
  18. package/.internal/charts/flow/FlowLink.js.map +1 -1
  19. package/.internal/charts/flow/FlowNode.js +17 -22
  20. package/.internal/charts/flow/FlowNode.js.map +1 -1
  21. package/.internal/charts/flow/FlowNodes.js +141 -202
  22. package/.internal/charts/flow/FlowNodes.js.map +1 -1
  23. package/.internal/charts/flow/Sankey.js +165 -203
  24. package/.internal/charts/flow/Sankey.js.map +1 -1
  25. package/.internal/charts/flow/SankeyLink.js +207 -229
  26. package/.internal/charts/flow/SankeyLink.js.map +1 -1
  27. package/.internal/charts/flow/SankeyNodes.js +70 -90
  28. package/.internal/charts/flow/SankeyNodes.js.map +1 -1
  29. package/.internal/charts/funnel/FunnelSeries.js +353 -447
  30. package/.internal/charts/funnel/FunnelSeries.js.map +1 -1
  31. package/.internal/charts/funnel/FunnelSlice.js +96 -117
  32. package/.internal/charts/funnel/FunnelSlice.js.map +1 -1
  33. package/.internal/charts/funnel/PictorialStackedSeries.js +59 -79
  34. package/.internal/charts/funnel/PictorialStackedSeries.js.map +1 -1
  35. package/.internal/charts/funnel/PyramidSeries.js +106 -122
  36. package/.internal/charts/funnel/PyramidSeries.js.map +1 -1
  37. package/.internal/charts/funnel/SlicedChart.js +17 -29
  38. package/.internal/charts/funnel/SlicedChart.js.map +1 -1
  39. package/.internal/charts/hierarchy/BreadcrumbBar.js +69 -96
  40. package/.internal/charts/hierarchy/BreadcrumbBar.js.map +1 -1
  41. package/.internal/charts/hierarchy/ForceDirected.js +255 -370
  42. package/.internal/charts/hierarchy/ForceDirected.js.map +1 -1
  43. package/.internal/charts/hierarchy/Hierarchy.js +476 -640
  44. package/.internal/charts/hierarchy/Hierarchy.js.map +1 -1
  45. package/.internal/charts/hierarchy/HierarchyDefaultTheme.js +337 -349
  46. package/.internal/charts/hierarchy/HierarchyDefaultTheme.js.map +1 -1
  47. package/.internal/charts/hierarchy/HierarchyLink.js +43 -61
  48. package/.internal/charts/hierarchy/HierarchyLink.js.map +1 -1
  49. package/.internal/charts/hierarchy/HierarchyNode.js +57 -74
  50. package/.internal/charts/hierarchy/HierarchyNode.js.map +1 -1
  51. package/.internal/charts/hierarchy/LinkedHierarchy.js +229 -323
  52. package/.internal/charts/hierarchy/LinkedHierarchy.js.map +1 -1
  53. package/.internal/charts/hierarchy/LinkedHierarchyNode.js +48 -80
  54. package/.internal/charts/hierarchy/LinkedHierarchyNode.js.map +1 -1
  55. package/.internal/charts/hierarchy/Pack.js +105 -147
  56. package/.internal/charts/hierarchy/Pack.js.map +1 -1
  57. package/.internal/charts/hierarchy/Partition.js +183 -230
  58. package/.internal/charts/hierarchy/Partition.js.map +1 -1
  59. package/.internal/charts/hierarchy/Sunburst.js +259 -323
  60. package/.internal/charts/hierarchy/Sunburst.js.map +1 -1
  61. package/.internal/charts/hierarchy/Tree.js +49 -69
  62. package/.internal/charts/hierarchy/Tree.js.map +1 -1
  63. package/.internal/charts/hierarchy/Treemap.js +168 -209
  64. package/.internal/charts/hierarchy/Treemap.js.map +1 -1
  65. package/.internal/charts/map/GraticuleSeries.js +49 -70
  66. package/.internal/charts/map/GraticuleSeries.js.map +1 -1
  67. package/.internal/charts/map/MapChart.js +587 -751
  68. package/.internal/charts/map/MapChart.js.map +1 -1
  69. package/.internal/charts/map/MapChartDefaultTheme.js +98 -110
  70. package/.internal/charts/map/MapChartDefaultTheme.js.map +1 -1
  71. package/.internal/charts/map/MapLine.js +165 -196
  72. package/.internal/charts/map/MapLine.js.map +1 -1
  73. package/.internal/charts/map/MapLineSeries.js +130 -197
  74. package/.internal/charts/map/MapLineSeries.js.map +1 -1
  75. package/.internal/charts/map/MapPointSeries.d.ts +7 -2
  76. package/.internal/charts/map/MapPointSeries.d.ts.map +1 -1
  77. package/.internal/charts/map/MapPointSeries.js +265 -342
  78. package/.internal/charts/map/MapPointSeries.js.map +1 -1
  79. package/.internal/charts/map/MapPolygon.js +86 -122
  80. package/.internal/charts/map/MapPolygon.js.map +1 -1
  81. package/.internal/charts/map/MapPolygonSeries.d.ts +6 -1
  82. package/.internal/charts/map/MapPolygonSeries.d.ts.map +1 -1
  83. package/.internal/charts/map/MapPolygonSeries.js +110 -170
  84. package/.internal/charts/map/MapPolygonSeries.js.map +1 -1
  85. package/.internal/charts/map/MapSeries.d.ts +9 -3
  86. package/.internal/charts/map/MapSeries.d.ts.map +1 -1
  87. package/.internal/charts/map/MapSeries.js +212 -303
  88. package/.internal/charts/map/MapSeries.js.map +1 -1
  89. package/.internal/charts/map/MapUtils.js +19 -19
  90. package/.internal/charts/map/MapUtils.js.map +1 -1
  91. package/.internal/charts/map/ZoomControl.js +52 -67
  92. package/.internal/charts/map/ZoomControl.js.map +1 -1
  93. package/.internal/charts/percent/PercentChart.js +23 -40
  94. package/.internal/charts/percent/PercentChart.js.map +1 -1
  95. package/.internal/charts/percent/PercentDefaultTheme.js +196 -208
  96. package/.internal/charts/percent/PercentDefaultTheme.js.map +1 -1
  97. package/.internal/charts/percent/PercentSeries.js +378 -549
  98. package/.internal/charts/percent/PercentSeries.js.map +1 -1
  99. package/.internal/charts/pie/PieChart.js +85 -110
  100. package/.internal/charts/pie/PieChart.js.map +1 -1
  101. package/.internal/charts/pie/PieSeries.js +175 -232
  102. package/.internal/charts/pie/PieSeries.js.map +1 -1
  103. package/.internal/charts/radar/AxisRendererCircular.js +219 -307
  104. package/.internal/charts/radar/AxisRendererCircular.js.map +1 -1
  105. package/.internal/charts/radar/AxisRendererRadial.js +188 -276
  106. package/.internal/charts/radar/AxisRendererRadial.js.map +1 -1
  107. package/.internal/charts/radar/ClockHand.js +89 -104
  108. package/.internal/charts/radar/ClockHand.js.map +1 -1
  109. package/.internal/charts/radar/RadarChart.js +142 -201
  110. package/.internal/charts/radar/RadarChart.js.map +1 -1
  111. package/.internal/charts/radar/RadarColumnSeries.js +118 -170
  112. package/.internal/charts/radar/RadarColumnSeries.js.map +1 -1
  113. package/.internal/charts/radar/RadarCursor.js +147 -220
  114. package/.internal/charts/radar/RadarCursor.js.map +1 -1
  115. package/.internal/charts/radar/RadarDefaultTheme.js +85 -97
  116. package/.internal/charts/radar/RadarDefaultTheme.js.map +1 -1
  117. package/.internal/charts/radar/RadarLineSeries.js +71 -113
  118. package/.internal/charts/radar/RadarLineSeries.js.map +1 -1
  119. package/.internal/charts/radar/SmoothedRadarLineSeries.js +33 -55
  120. package/.internal/charts/radar/SmoothedRadarLineSeries.js.map +1 -1
  121. package/.internal/charts/stock/PanelControls.js +49 -60
  122. package/.internal/charts/stock/PanelControls.js.map +1 -1
  123. package/.internal/charts/stock/SettingsModal.js +321 -393
  124. package/.internal/charts/stock/SettingsModal.js.map +1 -1
  125. package/.internal/charts/stock/StockChart.d.ts.map +1 -1
  126. package/.internal/charts/stock/StockChart.js +466 -568
  127. package/.internal/charts/stock/StockChart.js.map +1 -1
  128. package/.internal/charts/stock/StockChartDefaultTheme.d.ts.map +1 -1
  129. package/.internal/charts/stock/StockChartDefaultTheme.js +1162 -1162
  130. package/.internal/charts/stock/StockChartDefaultTheme.js.map +1 -1
  131. package/.internal/charts/stock/StockLegend.js +65 -91
  132. package/.internal/charts/stock/StockLegend.js.map +1 -1
  133. package/.internal/charts/stock/StockPanel.js +87 -119
  134. package/.internal/charts/stock/StockPanel.js.map +1 -1
  135. package/.internal/charts/stock/drawing/AverageSeries.d.ts.map +1 -1
  136. package/.internal/charts/stock/drawing/AverageSeries.js +48 -60
  137. package/.internal/charts/stock/drawing/AverageSeries.js.map +1 -1
  138. package/.internal/charts/stock/drawing/CalloutSeries.d.ts +7 -2
  139. package/.internal/charts/stock/drawing/CalloutSeries.d.ts.map +1 -1
  140. package/.internal/charts/stock/drawing/CalloutSeries.js +90 -95
  141. package/.internal/charts/stock/drawing/CalloutSeries.js.map +1 -1
  142. package/.internal/charts/stock/drawing/DoodleSeries.d.ts.map +1 -1
  143. package/.internal/charts/stock/drawing/DoodleSeries.js +82 -122
  144. package/.internal/charts/stock/drawing/DoodleSeries.js.map +1 -1
  145. package/.internal/charts/stock/drawing/DrawingSeries.d.ts +5 -3
  146. package/.internal/charts/stock/drawing/DrawingSeries.d.ts.map +1 -1
  147. package/.internal/charts/stock/drawing/DrawingSeries.js +519 -712
  148. package/.internal/charts/stock/drawing/DrawingSeries.js.map +1 -1
  149. package/.internal/charts/stock/drawing/EllipseSeries.d.ts +3 -0
  150. package/.internal/charts/stock/drawing/EllipseSeries.d.ts.map +1 -1
  151. package/.internal/charts/stock/drawing/EllipseSeries.js +258 -307
  152. package/.internal/charts/stock/drawing/EllipseSeries.js.map +1 -1
  153. package/.internal/charts/stock/drawing/FibonacciSeries.d.ts +2 -3
  154. package/.internal/charts/stock/drawing/FibonacciSeries.d.ts.map +1 -1
  155. package/.internal/charts/stock/drawing/FibonacciSeries.js +189 -250
  156. package/.internal/charts/stock/drawing/FibonacciSeries.js.map +1 -1
  157. package/.internal/charts/stock/drawing/FibonacciTimezoneSeries.d.ts.map +1 -1
  158. package/.internal/charts/stock/drawing/FibonacciTimezoneSeries.js +108 -103
  159. package/.internal/charts/stock/drawing/FibonacciTimezoneSeries.js.map +1 -1
  160. package/.internal/charts/stock/drawing/HorizontalLineSeries.d.ts +4 -2
  161. package/.internal/charts/stock/drawing/HorizontalLineSeries.d.ts.map +1 -1
  162. package/.internal/charts/stock/drawing/HorizontalLineSeries.js +64 -84
  163. package/.internal/charts/stock/drawing/HorizontalLineSeries.js.map +1 -1
  164. package/.internal/charts/stock/drawing/HorizontalRaySeries.d.ts +2 -1
  165. package/.internal/charts/stock/drawing/HorizontalRaySeries.d.ts.map +1 -1
  166. package/.internal/charts/stock/drawing/HorizontalRaySeries.js +57 -92
  167. package/.internal/charts/stock/drawing/HorizontalRaySeries.js.map +1 -1
  168. package/.internal/charts/stock/drawing/IconSeries.d.ts +2 -4
  169. package/.internal/charts/stock/drawing/IconSeries.d.ts.map +1 -1
  170. package/.internal/charts/stock/drawing/IconSeries.js +112 -112
  171. package/.internal/charts/stock/drawing/IconSeries.js.map +1 -1
  172. package/.internal/charts/stock/drawing/LabelSeries.d.ts +5 -2
  173. package/.internal/charts/stock/drawing/LabelSeries.d.ts.map +1 -1
  174. package/.internal/charts/stock/drawing/LabelSeries.js +151 -172
  175. package/.internal/charts/stock/drawing/LabelSeries.js.map +1 -1
  176. package/.internal/charts/stock/drawing/PolylineSeries.d.ts +1 -0
  177. package/.internal/charts/stock/drawing/PolylineSeries.d.ts.map +1 -1
  178. package/.internal/charts/stock/drawing/PolylineSeries.js +101 -122
  179. package/.internal/charts/stock/drawing/PolylineSeries.js.map +1 -1
  180. package/.internal/charts/stock/drawing/QuadrantLineSeries.d.ts.map +1 -1
  181. package/.internal/charts/stock/drawing/QuadrantLineSeries.js +115 -149
  182. package/.internal/charts/stock/drawing/QuadrantLineSeries.js.map +1 -1
  183. package/.internal/charts/stock/drawing/RectangleSeries.d.ts.map +1 -1
  184. package/.internal/charts/stock/drawing/RectangleSeries.js +117 -155
  185. package/.internal/charts/stock/drawing/RectangleSeries.js.map +1 -1
  186. package/.internal/charts/stock/drawing/RegressionSeries.d.ts.map +1 -1
  187. package/.internal/charts/stock/drawing/RegressionSeries.js +64 -82
  188. package/.internal/charts/stock/drawing/RegressionSeries.js.map +1 -1
  189. package/.internal/charts/stock/drawing/SimpleLineSeries.d.ts +6 -2
  190. package/.internal/charts/stock/drawing/SimpleLineSeries.d.ts.map +1 -1
  191. package/.internal/charts/stock/drawing/SimpleLineSeries.js +233 -303
  192. package/.internal/charts/stock/drawing/SimpleLineSeries.js.map +1 -1
  193. package/.internal/charts/stock/drawing/TrendLineSeries.d.ts.map +1 -1
  194. package/.internal/charts/stock/drawing/TrendLineSeries.js +40 -57
  195. package/.internal/charts/stock/drawing/TrendLineSeries.js.map +1 -1
  196. package/.internal/charts/stock/drawing/VerticalLineSeries.d.ts +3 -1
  197. package/.internal/charts/stock/drawing/VerticalLineSeries.d.ts.map +1 -1
  198. package/.internal/charts/stock/drawing/VerticalLineSeries.js +63 -79
  199. package/.internal/charts/stock/drawing/VerticalLineSeries.js.map +1 -1
  200. package/.internal/charts/stock/indicators/AccumulationDistribution.js +68 -88
  201. package/.internal/charts/stock/indicators/AccumulationDistribution.js.map +1 -1
  202. package/.internal/charts/stock/indicators/AccumulativeSwingIndex.js +107 -127
  203. package/.internal/charts/stock/indicators/AccumulativeSwingIndex.js.map +1 -1
  204. package/.internal/charts/stock/indicators/Aroon.js +85 -110
  205. package/.internal/charts/stock/indicators/Aroon.js.map +1 -1
  206. package/.internal/charts/stock/indicators/AwesomeOscillator.js +68 -88
  207. package/.internal/charts/stock/indicators/AwesomeOscillator.js.map +1 -1
  208. package/.internal/charts/stock/indicators/BollingerBands.js +109 -135
  209. package/.internal/charts/stock/indicators/BollingerBands.js.map +1 -1
  210. package/.internal/charts/stock/indicators/ChaikinMoneyFlow.js +77 -97
  211. package/.internal/charts/stock/indicators/ChaikinMoneyFlow.js.map +1 -1
  212. package/.internal/charts/stock/indicators/ChaikinOscillator.js +75 -95
  213. package/.internal/charts/stock/indicators/ChaikinOscillator.js.map +1 -1
  214. package/.internal/charts/stock/indicators/ChartIndicator.js +86 -102
  215. package/.internal/charts/stock/indicators/ChartIndicator.js.map +1 -1
  216. package/.internal/charts/stock/indicators/CommodityChannelIndex.js +136 -161
  217. package/.internal/charts/stock/indicators/CommodityChannelIndex.js.map +1 -1
  218. package/.internal/charts/stock/indicators/DisparityIndex.js +69 -89
  219. package/.internal/charts/stock/indicators/DisparityIndex.js.map +1 -1
  220. package/.internal/charts/stock/indicators/Indicator.d.ts +1 -2
  221. package/.internal/charts/stock/indicators/Indicator.d.ts.map +1 -1
  222. package/.internal/charts/stock/indicators/Indicator.js +286 -383
  223. package/.internal/charts/stock/indicators/Indicator.js.map +1 -1
  224. package/.internal/charts/stock/indicators/MACD.js +129 -159
  225. package/.internal/charts/stock/indicators/MACD.js.map +1 -1
  226. package/.internal/charts/stock/indicators/MedianPrice.js +56 -71
  227. package/.internal/charts/stock/indicators/MedianPrice.js.map +1 -1
  228. package/.internal/charts/stock/indicators/MovingAverage.js +95 -115
  229. package/.internal/charts/stock/indicators/MovingAverage.js.map +1 -1
  230. package/.internal/charts/stock/indicators/MovingAverageDeviation.js +93 -118
  231. package/.internal/charts/stock/indicators/MovingAverageDeviation.js.map +1 -1
  232. package/.internal/charts/stock/indicators/MovingAverageEnvelope.js +114 -144
  233. package/.internal/charts/stock/indicators/MovingAverageEnvelope.js.map +1 -1
  234. package/.internal/charts/stock/indicators/OnBalanceVolume.js +65 -85
  235. package/.internal/charts/stock/indicators/OnBalanceVolume.js.map +1 -1
  236. package/.internal/charts/stock/indicators/RelativeStrengthIndex.js +162 -187
  237. package/.internal/charts/stock/indicators/RelativeStrengthIndex.js.map +1 -1
  238. package/.internal/charts/stock/indicators/StandardDeviation.js +56 -72
  239. package/.internal/charts/stock/indicators/StandardDeviation.js.map +1 -1
  240. package/.internal/charts/stock/indicators/StochasticOscillator.js +142 -173
  241. package/.internal/charts/stock/indicators/StochasticOscillator.js.map +1 -1
  242. package/.internal/charts/stock/indicators/Trix.js +90 -120
  243. package/.internal/charts/stock/indicators/Trix.js.map +1 -1
  244. package/.internal/charts/stock/indicators/TypicalPrice.js +56 -71
  245. package/.internal/charts/stock/indicators/TypicalPrice.js.map +1 -1
  246. package/.internal/charts/stock/indicators/VWAP.js +78 -98
  247. package/.internal/charts/stock/indicators/VWAP.js.map +1 -1
  248. package/.internal/charts/stock/indicators/Volume.js +55 -75
  249. package/.internal/charts/stock/indicators/Volume.js.map +1 -1
  250. package/.internal/charts/stock/indicators/WilliamsR.js +138 -163
  251. package/.internal/charts/stock/indicators/WilliamsR.js.map +1 -1
  252. package/.internal/charts/stock/indicators/ZigZag.js +141 -161
  253. package/.internal/charts/stock/indicators/ZigZag.js.map +1 -1
  254. package/.internal/charts/stock/toolbar/ColorControl.js +78 -101
  255. package/.internal/charts/stock/toolbar/ColorControl.js.map +1 -1
  256. package/.internal/charts/stock/toolbar/ComparisonControl.js +16 -28
  257. package/.internal/charts/stock/toolbar/ComparisonControl.js.map +1 -1
  258. package/.internal/charts/stock/toolbar/DateRangeSelector.js +1157 -345
  259. package/.internal/charts/stock/toolbar/DateRangeSelector.js.map +1 -1
  260. package/.internal/charts/stock/toolbar/DrawingControl.d.ts +26 -0
  261. package/.internal/charts/stock/toolbar/DrawingControl.d.ts.map +1 -1
  262. package/.internal/charts/stock/toolbar/DrawingControl.js +754 -709
  263. package/.internal/charts/stock/toolbar/DrawingControl.js.map +1 -1
  264. package/.internal/charts/stock/toolbar/DrawingToolControl.js +80 -119
  265. package/.internal/charts/stock/toolbar/DrawingToolControl.js.map +1 -1
  266. package/.internal/charts/stock/toolbar/Dropdown.js +102 -150
  267. package/.internal/charts/stock/toolbar/Dropdown.js.map +1 -1
  268. package/.internal/charts/stock/toolbar/DropdownColors.js +92 -141
  269. package/.internal/charts/stock/toolbar/DropdownColors.js.map +1 -1
  270. package/.internal/charts/stock/toolbar/DropdownList.js +186 -249
  271. package/.internal/charts/stock/toolbar/DropdownList.js.map +1 -1
  272. package/.internal/charts/stock/toolbar/DropdownListControl.js +117 -150
  273. package/.internal/charts/stock/toolbar/DropdownListControl.js.map +1 -1
  274. package/.internal/charts/stock/toolbar/IconControl.js +81 -120
  275. package/.internal/charts/stock/toolbar/IconControl.js.map +1 -1
  276. package/.internal/charts/stock/toolbar/IndicatorControl.d.ts +23 -1
  277. package/.internal/charts/stock/toolbar/IndicatorControl.d.ts.map +1 -1
  278. package/.internal/charts/stock/toolbar/IndicatorControl.js +352 -297
  279. package/.internal/charts/stock/toolbar/IndicatorControl.js.map +1 -1
  280. package/.internal/charts/stock/toolbar/IntervalControl.js +16 -28
  281. package/.internal/charts/stock/toolbar/IntervalControl.js.map +1 -1
  282. package/.internal/charts/stock/toolbar/PeriodSelector.js +141 -189
  283. package/.internal/charts/stock/toolbar/PeriodSelector.js.map +1 -1
  284. package/.internal/charts/stock/toolbar/ResetControl.js +26 -44
  285. package/.internal/charts/stock/toolbar/ResetControl.js.map +1 -1
  286. package/.internal/charts/stock/toolbar/SeriesTypeControl.js +14 -21
  287. package/.internal/charts/stock/toolbar/SeriesTypeControl.js.map +1 -1
  288. package/.internal/charts/stock/toolbar/SettingsControl.js +97 -140
  289. package/.internal/charts/stock/toolbar/SettingsControl.js.map +1 -1
  290. package/.internal/charts/stock/toolbar/StockControl.js +114 -177
  291. package/.internal/charts/stock/toolbar/StockControl.js.map +1 -1
  292. package/.internal/charts/stock/toolbar/StockIcons.js +67 -81
  293. package/.internal/charts/stock/toolbar/StockIcons.js.map +1 -1
  294. package/.internal/charts/stock/toolbar/StockToolbar.js +63 -94
  295. package/.internal/charts/stock/toolbar/StockToolbar.js.map +1 -1
  296. package/.internal/charts/stock/toolbar/StockToolbarCSS.js +11 -11
  297. package/.internal/charts/stock/toolbar/StockToolbarCSS.js.map +1 -1
  298. package/.internal/charts/venn/Venn.js +276 -373
  299. package/.internal/charts/venn/Venn.js.map +1 -1
  300. package/.internal/charts/venn/VennDefaultTheme.js +18 -30
  301. package/.internal/charts/venn/VennDefaultTheme.js.map +1 -1
  302. package/.internal/charts/wordcloud/WordCloud.js +381 -452
  303. package/.internal/charts/wordcloud/WordCloud.js.map +1 -1
  304. package/.internal/charts/wordcloud/WordCloudDefaultTheme.js +35 -48
  305. package/.internal/charts/wordcloud/WordCloudDefaultTheme.js.map +1 -1
  306. package/.internal/charts/xy/XYChart.js +956 -1136
  307. package/.internal/charts/xy/XYChart.js.map +1 -1
  308. package/.internal/charts/xy/XYChartDefaultTheme.d.ts.map +1 -1
  309. package/.internal/charts/xy/XYChartDefaultTheme.js +597 -604
  310. package/.internal/charts/xy/XYChartDefaultTheme.js.map +1 -1
  311. package/.internal/charts/xy/XYChartScrollbar.js +78 -95
  312. package/.internal/charts/xy/XYChartScrollbar.js.map +1 -1
  313. package/.internal/charts/xy/XYCursor.d.ts.map +1 -1
  314. package/.internal/charts/xy/XYCursor.js +468 -608
  315. package/.internal/charts/xy/XYCursor.js.map +1 -1
  316. package/.internal/charts/xy/axes/Axis.d.ts +0 -2
  317. package/.internal/charts/xy/axes/Axis.d.ts.map +1 -1
  318. package/.internal/charts/xy/axes/Axis.js +509 -726
  319. package/.internal/charts/xy/axes/Axis.js.map +1 -1
  320. package/.internal/charts/xy/axes/AxisBullet.js +30 -40
  321. package/.internal/charts/xy/axes/AxisBullet.js.map +1 -1
  322. package/.internal/charts/xy/axes/AxisLabel.js +17 -22
  323. package/.internal/charts/xy/axes/AxisLabel.js.map +1 -1
  324. package/.internal/charts/xy/axes/AxisLabelRadial.js +17 -22
  325. package/.internal/charts/xy/axes/AxisLabelRadial.js.map +1 -1
  326. package/.internal/charts/xy/axes/AxisRenderer.js +186 -302
  327. package/.internal/charts/xy/axes/AxisRenderer.js.map +1 -1
  328. package/.internal/charts/xy/axes/AxisRendererX.js +308 -400
  329. package/.internal/charts/xy/axes/AxisRendererX.js.map +1 -1
  330. package/.internal/charts/xy/axes/AxisRendererY.js +319 -421
  331. package/.internal/charts/xy/axes/AxisRendererY.js.map +1 -1
  332. package/.internal/charts/xy/axes/AxisTick.js +17 -22
  333. package/.internal/charts/xy/axes/AxisTick.js.map +1 -1
  334. package/.internal/charts/xy/axes/CategoryAxis.js +312 -454
  335. package/.internal/charts/xy/axes/CategoryAxis.js.map +1 -1
  336. package/.internal/charts/xy/axes/CategoryDateAxis.js +136 -167
  337. package/.internal/charts/xy/axes/CategoryDateAxis.js.map +1 -1
  338. package/.internal/charts/xy/axes/DateAxis.js +579 -758
  339. package/.internal/charts/xy/axes/DateAxis.js.map +1 -1
  340. package/.internal/charts/xy/axes/DurationAxis.js +92 -128
  341. package/.internal/charts/xy/axes/DurationAxis.js.map +1 -1
  342. package/.internal/charts/xy/axes/GaplessDateAxis.js +207 -254
  343. package/.internal/charts/xy/axes/GaplessDateAxis.js.map +1 -1
  344. package/.internal/charts/xy/axes/Grid.js +19 -31
  345. package/.internal/charts/xy/axes/Grid.js.map +1 -1
  346. package/.internal/charts/xy/axes/ValueAxis.js +848 -1041
  347. package/.internal/charts/xy/axes/ValueAxis.js.map +1 -1
  348. package/.internal/charts/xy/series/BaseColumnSeries.js +480 -576
  349. package/.internal/charts/xy/series/BaseColumnSeries.js.map +1 -1
  350. package/.internal/charts/xy/series/Candlestick.js +27 -44
  351. package/.internal/charts/xy/series/Candlestick.js.map +1 -1
  352. package/.internal/charts/xy/series/CandlestickSeries.js +114 -140
  353. package/.internal/charts/xy/series/CandlestickSeries.js.map +1 -1
  354. package/.internal/charts/xy/series/ColumnSeries.js +33 -49
  355. package/.internal/charts/xy/series/ColumnSeries.js.map +1 -1
  356. package/.internal/charts/xy/series/LineSeries.js +447 -548
  357. package/.internal/charts/xy/series/LineSeries.js.map +1 -1
  358. package/.internal/charts/xy/series/OHLC.js +36 -48
  359. package/.internal/charts/xy/series/OHLC.js.map +1 -1
  360. package/.internal/charts/xy/series/OHLCSeries.js +32 -48
  361. package/.internal/charts/xy/series/OHLCSeries.js.map +1 -1
  362. package/.internal/charts/xy/series/SmoothedXLineSeries.js +23 -40
  363. package/.internal/charts/xy/series/SmoothedXLineSeries.js.map +1 -1
  364. package/.internal/charts/xy/series/SmoothedXYLineSeries.js +23 -40
  365. package/.internal/charts/xy/series/SmoothedXYLineSeries.js.map +1 -1
  366. package/.internal/charts/xy/series/SmoothedYLineSeries.js +23 -40
  367. package/.internal/charts/xy/series/SmoothedYLineSeries.js.map +1 -1
  368. package/.internal/charts/xy/series/StepLineSeries.js +114 -131
  369. package/.internal/charts/xy/series/StepLineSeries.js.map +1 -1
  370. package/.internal/charts/xy/series/XYSeries.d.ts +1 -1
  371. package/.internal/charts/xy/series/XYSeries.d.ts.map +1 -1
  372. package/.internal/charts/xy/series/XYSeries.js +939 -1222
  373. package/.internal/charts/xy/series/XYSeries.js.map +1 -1
  374. package/.internal/core/Classes.d.ts +11 -7
  375. package/.internal/core/Classes.d.ts.map +1 -1
  376. package/.internal/core/Classes.js.map +1 -1
  377. package/.internal/core/Registry.d.ts.map +1 -1
  378. package/.internal/core/Registry.js +6 -8
  379. package/.internal/core/Registry.js.map +1 -1
  380. package/.internal/core/Root.d.ts +20 -0
  381. package/.internal/core/Root.d.ts.map +1 -1
  382. package/.internal/core/Root.js +1006 -1241
  383. package/.internal/core/Root.js.map +1 -1
  384. package/.internal/core/Theme.js +38 -67
  385. package/.internal/core/Theme.js.map +1 -1
  386. package/.internal/core/render/Bullet.js +34 -49
  387. package/.internal/core/render/Bullet.js.map +1 -1
  388. package/.internal/core/render/Button.js +47 -64
  389. package/.internal/core/render/Button.js.map +1 -1
  390. package/.internal/core/render/Chart.js +20 -25
  391. package/.internal/core/render/Chart.js.map +1 -1
  392. package/.internal/core/render/Circle.js +24 -41
  393. package/.internal/core/render/Circle.js.map +1 -1
  394. package/.internal/core/render/Component.js +239 -384
  395. package/.internal/core/render/Component.js.map +1 -1
  396. package/.internal/core/render/Container.d.ts.map +1 -1
  397. package/.internal/core/render/Container.js +444 -548
  398. package/.internal/core/render/Container.js.map +1 -1
  399. package/.internal/core/render/Ellipse.js +24 -41
  400. package/.internal/core/render/Ellipse.js.map +1 -1
  401. package/.internal/core/render/Graphics.d.ts.map +1 -1
  402. package/.internal/core/render/Graphics.js +197 -215
  403. package/.internal/core/render/Graphics.js.map +1 -1
  404. package/.internal/core/render/GridLayout.js +102 -125
  405. package/.internal/core/render/GridLayout.js.map +1 -1
  406. package/.internal/core/render/HeatLegend.js +129 -154
  407. package/.internal/core/render/HeatLegend.js.map +1 -1
  408. package/.internal/core/render/HorizontalLayout.js +79 -91
  409. package/.internal/core/render/HorizontalLayout.js.map +1 -1
  410. package/.internal/core/render/Label.js +109 -150
  411. package/.internal/core/render/Label.js.map +1 -1
  412. package/.internal/core/render/Layout.js +14 -21
  413. package/.internal/core/render/Layout.js.map +1 -1
  414. package/.internal/core/render/Legend.js +230 -282
  415. package/.internal/core/render/Legend.js.map +1 -1
  416. package/.internal/core/render/Line.js +37 -54
  417. package/.internal/core/render/Line.js.map +1 -1
  418. package/.internal/core/render/MonotoneXTension.js +58 -85
  419. package/.internal/core/render/MonotoneXTension.js.map +1 -1
  420. package/.internal/core/render/MonotoneYTension.js +59 -88
  421. package/.internal/core/render/MonotoneYTension.js.map +1 -1
  422. package/.internal/core/render/Picture.js +92 -113
  423. package/.internal/core/render/Picture.js.map +1 -1
  424. package/.internal/core/render/PointedRectangle.js +94 -111
  425. package/.internal/core/render/PointedRectangle.js.map +1 -1
  426. package/.internal/core/render/RadialLabel.js +119 -158
  427. package/.internal/core/render/RadialLabel.js.map +1 -1
  428. package/.internal/core/render/RadialText.js +47 -62
  429. package/.internal/core/render/RadialText.js.map +1 -1
  430. package/.internal/core/render/Rectangle.js +31 -58
  431. package/.internal/core/render/Rectangle.js.map +1 -1
  432. package/.internal/core/render/RoundedRectangle.js +55 -72
  433. package/.internal/core/render/RoundedRectangle.js.map +1 -1
  434. package/.internal/core/render/Scrollbar.js +292 -349
  435. package/.internal/core/render/Scrollbar.js.map +1 -1
  436. package/.internal/core/render/SerialChart.js +64 -85
  437. package/.internal/core/render/SerialChart.js.map +1 -1
  438. package/.internal/core/render/Series.js +472 -660
  439. package/.internal/core/render/Series.js.map +1 -1
  440. package/.internal/core/render/Slice.js +83 -103
  441. package/.internal/core/render/Slice.js.map +1 -1
  442. package/.internal/core/render/Slider.js +25 -42
  443. package/.internal/core/render/Slider.js.map +1 -1
  444. package/.internal/core/render/Sprite.d.ts +17 -1
  445. package/.internal/core/render/Sprite.d.ts.map +1 -1
  446. package/.internal/core/render/Sprite.js +1307 -1777
  447. package/.internal/core/render/Sprite.js.map +1 -1
  448. package/.internal/core/render/SpriteResizer.js +157 -199
  449. package/.internal/core/render/SpriteResizer.js.map +1 -1
  450. package/.internal/core/render/Star.js +37 -54
  451. package/.internal/core/render/Star.js.map +1 -1
  452. package/.internal/core/render/Text.d.ts.map +1 -1
  453. package/.internal/core/render/Text.js +145 -182
  454. package/.internal/core/render/Text.js.map +1 -1
  455. package/.internal/core/render/Tick.js +14 -21
  456. package/.internal/core/render/Tick.js.map +1 -1
  457. package/.internal/core/render/Tooltip.d.ts +0 -1
  458. package/.internal/core/render/Tooltip.d.ts.map +1 -1
  459. package/.internal/core/render/Tooltip.js +272 -333
  460. package/.internal/core/render/Tooltip.js.map +1 -1
  461. package/.internal/core/render/Triangle.js +38 -65
  462. package/.internal/core/render/Triangle.js.map +1 -1
  463. package/.internal/core/render/VerticalLayout.js +79 -91
  464. package/.internal/core/render/VerticalLayout.js.map +1 -1
  465. package/.internal/core/render/backend/CanvasRenderer.d.ts +2 -2
  466. package/.internal/core/render/backend/CanvasRenderer.d.ts.map +1 -1
  467. package/.internal/core/render/backend/CanvasRenderer.js +2806 -3721
  468. package/.internal/core/render/backend/CanvasRenderer.js.map +1 -1
  469. package/.internal/core/render/backend/Renderer.d.ts +1 -0
  470. package/.internal/core/render/backend/Renderer.d.ts.map +1 -1
  471. package/.internal/core/render/backend/Renderer.js.map +1 -1
  472. package/.internal/core/render/gradients/Gradient.js +45 -72
  473. package/.internal/core/render/gradients/Gradient.js.map +1 -1
  474. package/.internal/core/render/gradients/LinearGradient.js +53 -65
  475. package/.internal/core/render/gradients/LinearGradient.js.map +1 -1
  476. package/.internal/core/render/gradients/RadialGradient.js +69 -81
  477. package/.internal/core/render/gradients/RadialGradient.js.map +1 -1
  478. package/.internal/core/render/patterns/CirclePattern.js +64 -81
  479. package/.internal/core/render/patterns/CirclePattern.js.map +1 -1
  480. package/.internal/core/render/patterns/LinePattern.js +49 -66
  481. package/.internal/core/render/patterns/LinePattern.js.map +1 -1
  482. package/.internal/core/render/patterns/PathPattern.js +72 -89
  483. package/.internal/core/render/patterns/PathPattern.js.map +1 -1
  484. package/.internal/core/render/patterns/Pattern.js +54 -83
  485. package/.internal/core/render/patterns/Pattern.js.map +1 -1
  486. package/.internal/core/render/patterns/PicturePattern.js +69 -90
  487. package/.internal/core/render/patterns/PicturePattern.js.map +1 -1
  488. package/.internal/core/render/patterns/RectanglePattern.js +65 -82
  489. package/.internal/core/render/patterns/RectanglePattern.js.map +1 -1
  490. package/.internal/core/util/Animation.js +102 -151
  491. package/.internal/core/util/Animation.js.map +1 -1
  492. package/.internal/core/util/Array.js +48 -49
  493. package/.internal/core/util/Array.js.map +1 -1
  494. package/.internal/core/util/AsyncPending.js +15 -15
  495. package/.internal/core/util/AsyncPending.js.map +1 -1
  496. package/.internal/core/util/Benchmark.js +37 -55
  497. package/.internal/core/util/Benchmark.js.map +1 -1
  498. package/.internal/core/util/Children.js +42 -67
  499. package/.internal/core/util/Children.js.map +1 -1
  500. package/.internal/core/util/Color.js +110 -206
  501. package/.internal/core/util/Color.js.map +1 -1
  502. package/.internal/core/util/ColorSet.js +73 -110
  503. package/.internal/core/util/ColorSet.js.map +1 -1
  504. package/.internal/core/util/Counter.js +13 -25
  505. package/.internal/core/util/Counter.js.map +1 -1
  506. package/.internal/core/util/Data.js +28 -70
  507. package/.internal/core/util/Data.js.map +1 -1
  508. package/.internal/core/util/DataParser.js +145 -178
  509. package/.internal/core/util/DataParser.js.map +1 -1
  510. package/.internal/core/util/DataProcessor.js +89 -144
  511. package/.internal/core/util/DataProcessor.js.map +1 -1
  512. package/.internal/core/util/DateFormatter.d.ts.map +1 -1
  513. package/.internal/core/util/DateFormatter.js +795 -901
  514. package/.internal/core/util/DateFormatter.js.map +1 -1
  515. package/.internal/core/util/Disposer.js +82 -159
  516. package/.internal/core/util/Disposer.js.map +1 -1
  517. package/.internal/core/util/Draw.js +27 -27
  518. package/.internal/core/util/Draw.js.map +1 -1
  519. package/.internal/core/util/DurationFormatter.js +343 -409
  520. package/.internal/core/util/DurationFormatter.js.map +1 -1
  521. package/.internal/core/util/Ease.js +6 -6
  522. package/.internal/core/util/Entity.d.ts +5 -1
  523. package/.internal/core/util/Entity.d.ts.map +1 -1
  524. package/.internal/core/util/Entity.js +869 -1442
  525. package/.internal/core/util/Entity.js.map +1 -1
  526. package/.internal/core/util/EventDispatcher.js +216 -346
  527. package/.internal/core/util/EventDispatcher.js.map +1 -1
  528. package/.internal/core/util/InterfaceColors.js +14 -21
  529. package/.internal/core/util/InterfaceColors.js.map +1 -1
  530. package/.internal/core/util/Language.js +63 -123
  531. package/.internal/core/util/Language.js.map +1 -1
  532. package/.internal/core/util/List.js +244 -441
  533. package/.internal/core/util/List.js.map +1 -1
  534. package/.internal/core/util/Math.js +35 -35
  535. package/.internal/core/util/Math.js.map +1 -1
  536. package/.internal/core/util/Matrix.js +56 -95
  537. package/.internal/core/util/Matrix.js.map +1 -1
  538. package/.internal/core/util/Modal.js +103 -147
  539. package/.internal/core/util/Modal.js.map +1 -1
  540. package/.internal/core/util/Net.js +19 -19
  541. package/.internal/core/util/Net.js.map +1 -1
  542. package/.internal/core/util/NumberFormatter.js +393 -442
  543. package/.internal/core/util/NumberFormatter.js.map +1 -1
  544. package/.internal/core/util/Object.js +4 -4
  545. package/.internal/core/util/Object.js.map +1 -1
  546. package/.internal/core/util/Order.js +5 -5
  547. package/.internal/core/util/Order.js.map +1 -1
  548. package/.internal/core/util/Percent.js +65 -90
  549. package/.internal/core/util/Percent.js.map +1 -1
  550. package/.internal/core/util/PopulateString.js +28 -28
  551. package/.internal/core/util/PopulateString.js.map +1 -1
  552. package/.internal/core/util/ResizeSensor.js +76 -116
  553. package/.internal/core/util/ResizeSensor.js.map +1 -1
  554. package/.internal/core/util/States.js +116 -188
  555. package/.internal/core/util/States.js.map +1 -1
  556. package/.internal/core/util/Template.js +203 -364
  557. package/.internal/core/util/Template.js.map +1 -1
  558. package/.internal/core/util/TextFormatter.js +148 -184
  559. package/.internal/core/util/TextFormatter.js.map +1 -1
  560. package/.internal/core/util/Throttler.js +18 -26
  561. package/.internal/core/util/Throttler.js.map +1 -1
  562. package/.internal/core/util/Time.d.ts.map +1 -1
  563. package/.internal/core/util/Time.js +61 -63
  564. package/.internal/core/util/Time.js.map +1 -1
  565. package/.internal/core/util/Timezone.js +35 -57
  566. package/.internal/core/util/Timezone.js.map +1 -1
  567. package/.internal/core/util/Type.js +12 -12
  568. package/.internal/core/util/Type.js.map +1 -1
  569. package/.internal/core/util/Utils.d.ts +17 -0
  570. package/.internal/core/util/Utils.d.ts.map +1 -1
  571. package/.internal/core/util/Utils.js +166 -182
  572. package/.internal/core/util/Utils.js.map +1 -1
  573. package/.internal/core/util/Value.js +14 -30
  574. package/.internal/core/util/Value.js.map +1 -1
  575. package/.internal/plugins/exporting/Annotator.js +139 -265
  576. package/.internal/plugins/exporting/Annotator.js.map +1 -1
  577. package/.internal/plugins/exporting/Exporting.js +1216 -1614
  578. package/.internal/plugins/exporting/Exporting.js.map +1 -1
  579. package/.internal/plugins/exporting/ExportingCSS.js +5 -5
  580. package/.internal/plugins/exporting/ExportingCSS.js.map +1 -1
  581. package/.internal/plugins/exporting/ExportingMenu.js +337 -405
  582. package/.internal/plugins/exporting/ExportingMenu.js.map +1 -1
  583. package/.internal/plugins/json/Classes-script.d.ts +16 -0
  584. package/.internal/plugins/json/Classes-script.d.ts.map +1 -1
  585. package/.internal/plugins/json/Classes-script.js +202 -194
  586. package/.internal/plugins/json/Classes-script.js.map +1 -1
  587. package/.internal/plugins/json/Classes.d.ts +16 -0
  588. package/.internal/plugins/json/Classes.d.ts.map +1 -1
  589. package/.internal/plugins/json/Classes.js +202 -194
  590. package/.internal/plugins/json/Classes.js.map +1 -1
  591. package/.internal/plugins/json/Json.d.ts +42 -2
  592. package/.internal/plugins/json/Json.d.ts.map +1 -1
  593. package/.internal/plugins/json/Json.js +391 -278
  594. package/.internal/plugins/json/Json.js.map +1 -1
  595. package/.internal/plugins/json/Serializer.d.ts +62 -0
  596. package/.internal/plugins/json/Serializer.d.ts.map +1 -0
  597. package/.internal/plugins/json/Serializer.js +137 -0
  598. package/.internal/plugins/json/Serializer.js.map +1 -0
  599. package/.internal/plugins/sliceGrouper/SliceGrouper.js +159 -202
  600. package/.internal/plugins/sliceGrouper/SliceGrouper.js.map +1 -1
  601. package/.internal/themes/AnimatedTheme.js +20 -32
  602. package/.internal/themes/AnimatedTheme.js.map +1 -1
  603. package/.internal/themes/DarkTheme.js +28 -40
  604. package/.internal/themes/DarkTheme.js.map +1 -1
  605. package/.internal/themes/DatavizTheme.js +12 -24
  606. package/.internal/themes/DatavizTheme.js.map +1 -1
  607. package/.internal/themes/DefaultTheme.d.ts.map +1 -1
  608. package/.internal/themes/DefaultTheme.js +803 -813
  609. package/.internal/themes/DefaultTheme.js.map +1 -1
  610. package/.internal/themes/FrozenTheme.js +19 -31
  611. package/.internal/themes/FrozenTheme.js.map +1 -1
  612. package/.internal/themes/KellyTheme.js +31 -43
  613. package/.internal/themes/KellyTheme.js.map +1 -1
  614. package/.internal/themes/MaterialTheme.js +28 -40
  615. package/.internal/themes/MaterialTheme.js.map +1 -1
  616. package/.internal/themes/MicrochartTheme.js +67 -79
  617. package/.internal/themes/MicrochartTheme.js.map +1 -1
  618. package/.internal/themes/MoonriseTheme.js +19 -31
  619. package/.internal/themes/MoonriseTheme.js.map +1 -1
  620. package/.internal/themes/ResponsiveTheme.js +613 -790
  621. package/.internal/themes/ResponsiveTheme.js.map +1 -1
  622. package/.internal/themes/SpiritedTheme.js +19 -31
  623. package/.internal/themes/SpiritedTheme.js.map +1 -1
  624. package/CHANGELOG.md +28 -0
  625. package/examples/javascript/flow-chord/package.json +1 -1
  626. package/examples/javascript/flow-chord-directed/package.json +1 -1
  627. package/examples/javascript/flow-chord-non-ribbon/package.json +1 -1
  628. package/examples/javascript/flow-sankey/package.json +1 -1
  629. package/examples/javascript/gauge/package.json +1 -1
  630. package/examples/javascript/gauge-bands/index.js +3 -1
  631. package/examples/javascript/gauge-bands/package.json +1 -1
  632. package/examples/javascript/hierarchy-force-directed/package.json +1 -1
  633. package/examples/javascript/hierarchy-pack/package.json +1 -1
  634. package/examples/javascript/hierarchy-partition/package.json +1 -1
  635. package/examples/javascript/hierarchy-sunburst/package.json +1 -1
  636. package/examples/javascript/hierarchy-tree/package.json +1 -1
  637. package/examples/javascript/hierarchy-treemap/package.json +1 -1
  638. package/examples/javascript/jest/package.json +1 -1
  639. package/examples/javascript/{json → json-pie}/README.md +0 -0
  640. package/examples/javascript/{json → json-pie}/index.css +0 -0
  641. package/examples/javascript/json-pie/index.html +12 -0
  642. package/examples/javascript/json-pie/index.js +77 -0
  643. package/examples/javascript/json-pie/package.json +16 -0
  644. package/examples/javascript/{json → json-pie}/webpack.config.js +0 -0
  645. package/examples/{typescript/json → javascript/json-xy}/README.md +0 -0
  646. package/examples/{typescript/json → javascript/json-xy}/index.css +0 -0
  647. package/examples/{typescript/json → javascript/json-xy}/index.html +1 -1
  648. package/examples/javascript/json-xy/index.js +203 -0
  649. package/examples/javascript/{json → json-xy}/package.json +2 -2
  650. package/examples/javascript/json-xy/webpack.config.js +38 -0
  651. package/examples/javascript/map-animating-along-lines/package.json +1 -1
  652. package/examples/javascript/map-day-and-night/package.json +1 -1
  653. package/examples/javascript/map-globe-rotate-to-country/package.json +1 -1
  654. package/examples/javascript/map-globe-with-projected-circles/package.json +1 -1
  655. package/examples/javascript/map-with-bubbles/package.json +1 -1
  656. package/examples/javascript/map-zoom-to-country/package.json +1 -1
  657. package/examples/javascript/misc-40-charts/package.json +1 -1
  658. package/examples/javascript/misc-microchart-grid/package.json +1 -1
  659. package/examples/javascript/pie-chart/package.json +1 -1
  660. package/examples/javascript/pie-donut-chart/package.json +1 -1
  661. package/examples/javascript/pie-variable-radius/package.json +1 -1
  662. package/examples/javascript/radar-column-iwatch-style/package.json +1 -1
  663. package/examples/javascript/radar-heat-map/index.js +33 -33
  664. package/examples/javascript/radar-heat-map/package.json +1 -1
  665. package/examples/javascript/radar-line/package.json +1 -1
  666. package/examples/javascript/radar-time-line/package.json +1 -1
  667. package/examples/javascript/sliced-funnel/package.json +1 -1
  668. package/examples/javascript/sliced-pictorial-stacked/package.json +1 -1
  669. package/examples/javascript/sliced-pyramid/package.json +1 -1
  670. package/examples/javascript/stock-chart/package.json +1 -1
  671. package/examples/javascript/stock-chart-comparing-stocks/package.json +1 -1
  672. package/examples/javascript/stock-chart-data-granularity/package.json +1 -1
  673. package/examples/javascript/stock-chart-data-grouping/package.json +1 -1
  674. package/examples/javascript/stock-chart-intraday/package.json +1 -1
  675. package/examples/javascript/stock-chart-live/package.json +1 -1
  676. package/examples/javascript/stock-chart-volume-separate-panel/package.json +1 -1
  677. package/examples/javascript/venn-diagram/package.json +1 -1
  678. package/examples/javascript/wordcloud-with-data/package.json +1 -1
  679. package/examples/javascript/wordcloud-with-text/package.json +1 -1
  680. package/examples/javascript/xy-100-percent-stacked-column/package.json +1 -1
  681. package/examples/javascript/xy-animated-bullet-at-the-end-of-the-series/package.json +1 -1
  682. package/examples/javascript/xy-bubble/package.json +1 -1
  683. package/examples/javascript/xy-candlestick/package.json +1 -1
  684. package/examples/javascript/xy-clustered-column/package.json +1 -1
  685. package/examples/javascript/xy-column/package.json +1 -1
  686. package/examples/javascript/xy-comparing-series-google-analytics-style/package.json +1 -1
  687. package/examples/javascript/xy-data-grouping/package.json +1 -1
  688. package/examples/javascript/xy-draggable-range/package.json +1 -1
  689. package/examples/javascript/xy-drawing-series-with-mouse-or-touch/package.json +1 -1
  690. package/examples/javascript/xy-dumbbell plot/package.json +1 -1
  691. package/examples/javascript/xy-evenly-spaced-date-axis/package.json +1 -1
  692. package/examples/javascript/xy-line/package.json +1 -1
  693. package/examples/javascript/xy-line-highlight-on-legend-hover/package.json +1 -1
  694. package/examples/javascript/xy-live-data/package.json +1 -1
  695. package/examples/javascript/xy-multiple-synced-value-axes/package.json +1 -1
  696. package/examples/javascript/xy-ohlc/package.json +1 -1
  697. package/examples/javascript/xy-real-time-data-sorting/package.json +1 -1
  698. package/examples/javascript/xy-smoothed-line/package.json +1 -1
  699. package/examples/javascript/xy-stacked-and-clustered-column/package.json +1 -1
  700. package/examples/javascript/xy-stacked-column/package.json +1 -1
  701. package/examples/javascript/xy-stacked-step/package.json +1 -1
  702. package/examples/javascript/xy-stock/package.json +1 -1
  703. package/examples/javascript/xy-stock-comparing/package.json +1 -1
  704. package/examples/typescript/flow-chord/package.json +1 -1
  705. package/examples/typescript/flow-chord/tsconfig.json +1 -1
  706. package/examples/typescript/flow-chord-directed/package.json +1 -1
  707. package/examples/typescript/flow-chord-directed/tsconfig.json +1 -1
  708. package/examples/typescript/flow-chord-non-ribbon/package.json +1 -1
  709. package/examples/typescript/flow-chord-non-ribbon/tsconfig.json +1 -1
  710. package/examples/typescript/flow-sankey/package.json +1 -1
  711. package/examples/typescript/flow-sankey/tsconfig.json +1 -1
  712. package/examples/typescript/gauge/package.json +1 -1
  713. package/examples/typescript/gauge/tsconfig.json +1 -1
  714. package/examples/typescript/gauge-bands/index.ts +3 -1
  715. package/examples/typescript/gauge-bands/package.json +1 -1
  716. package/examples/typescript/gauge-bands/tsconfig.json +1 -1
  717. package/examples/typescript/hierarchy-force-directed/package.json +1 -1
  718. package/examples/typescript/hierarchy-force-directed/tsconfig.json +1 -1
  719. package/examples/typescript/hierarchy-pack/package.json +1 -1
  720. package/examples/typescript/hierarchy-pack/tsconfig.json +1 -1
  721. package/examples/typescript/hierarchy-partition/package.json +1 -1
  722. package/examples/typescript/hierarchy-partition/tsconfig.json +1 -1
  723. package/examples/typescript/hierarchy-sunburst/package.json +1 -1
  724. package/examples/typescript/hierarchy-sunburst/tsconfig.json +1 -1
  725. package/examples/typescript/hierarchy-tree/package.json +1 -1
  726. package/examples/typescript/hierarchy-tree/tsconfig.json +1 -1
  727. package/examples/typescript/hierarchy-treemap/package.json +1 -1
  728. package/examples/typescript/hierarchy-treemap/tsconfig.json +1 -1
  729. package/examples/typescript/jest/package.json +1 -1
  730. package/examples/typescript/jest/tsconfig.json +1 -1
  731. package/examples/typescript/json-pie/README.md +6 -0
  732. package/examples/typescript/json-pie/index.css +11 -0
  733. package/examples/typescript/json-pie/index.html +12 -0
  734. package/examples/typescript/json-pie/index.ts +77 -0
  735. package/examples/typescript/json-pie/package.json +18 -0
  736. package/examples/typescript/{json → json-pie}/tsconfig.json +1 -1
  737. package/examples/typescript/{json → json-pie}/webpack.config.js +0 -0
  738. package/examples/typescript/json-xy/README.md +6 -0
  739. package/examples/typescript/json-xy/index.css +11 -0
  740. package/examples/{javascript/json → typescript/json-xy}/index.html +1 -1
  741. package/examples/typescript/json-xy/index.ts +203 -0
  742. package/examples/typescript/{json → json-xy}/package.json +2 -2
  743. package/examples/typescript/json-xy/tsconfig.json +12 -0
  744. package/examples/typescript/json-xy/webpack.config.js +45 -0
  745. package/examples/typescript/map-animating-along-lines/package.json +1 -1
  746. package/examples/typescript/map-animating-along-lines/tsconfig.json +1 -1
  747. package/examples/typescript/map-day-and-night/package.json +1 -1
  748. package/examples/typescript/map-day-and-night/tsconfig.json +1 -1
  749. package/examples/typescript/map-globe-rotate-to-country/package.json +1 -1
  750. package/examples/typescript/map-globe-rotate-to-country/tsconfig.json +1 -1
  751. package/examples/typescript/map-globe-with-projected-circles/package.json +1 -1
  752. package/examples/typescript/map-globe-with-projected-circles/tsconfig.json +1 -1
  753. package/examples/typescript/map-with-bubbles/package.json +1 -1
  754. package/examples/typescript/map-with-bubbles/tsconfig.json +1 -1
  755. package/examples/typescript/map-zoom-to-country/package.json +1 -1
  756. package/examples/typescript/map-zoom-to-country/tsconfig.json +1 -1
  757. package/examples/typescript/misc-40-charts/package.json +1 -1
  758. package/examples/typescript/misc-40-charts/tsconfig.json +1 -1
  759. package/examples/typescript/misc-microchart-grid/package.json +1 -1
  760. package/examples/typescript/misc-microchart-grid/tsconfig.json +1 -1
  761. package/examples/typescript/pie-chart/package.json +1 -1
  762. package/examples/typescript/pie-chart/tsconfig.json +1 -1
  763. package/examples/typescript/pie-donut-chart/package.json +1 -1
  764. package/examples/typescript/pie-donut-chart/tsconfig.json +1 -1
  765. package/examples/typescript/pie-variable-radius/package.json +1 -1
  766. package/examples/typescript/pie-variable-radius/tsconfig.json +1 -1
  767. package/examples/typescript/radar-column-iwatch-style/package.json +1 -1
  768. package/examples/typescript/radar-column-iwatch-style/tsconfig.json +1 -1
  769. package/examples/typescript/radar-heat-map/index.ts +33 -33
  770. package/examples/typescript/radar-heat-map/package.json +1 -1
  771. package/examples/typescript/radar-heat-map/tsconfig.json +1 -1
  772. package/examples/typescript/radar-line/package.json +1 -1
  773. package/examples/typescript/radar-line/tsconfig.json +1 -1
  774. package/examples/typescript/radar-time-line/package.json +1 -1
  775. package/examples/typescript/radar-time-line/tsconfig.json +1 -1
  776. package/examples/typescript/sliced-funnel/package.json +1 -1
  777. package/examples/typescript/sliced-funnel/tsconfig.json +1 -1
  778. package/examples/typescript/sliced-pictorial-stacked/package.json +1 -1
  779. package/examples/typescript/sliced-pictorial-stacked/tsconfig.json +1 -1
  780. package/examples/typescript/sliced-pyramid/package.json +1 -1
  781. package/examples/typescript/sliced-pyramid/tsconfig.json +1 -1
  782. package/examples/typescript/stock-chart/package.json +1 -1
  783. package/examples/typescript/stock-chart/tsconfig.json +1 -1
  784. package/examples/typescript/stock-chart-comparing-stocks/package.json +1 -1
  785. package/examples/typescript/stock-chart-comparing-stocks/tsconfig.json +1 -1
  786. package/examples/typescript/stock-chart-data-granularity/package.json +1 -1
  787. package/examples/typescript/stock-chart-data-granularity/tsconfig.json +1 -1
  788. package/examples/typescript/stock-chart-data-grouping/package.json +1 -1
  789. package/examples/typescript/stock-chart-data-grouping/tsconfig.json +1 -1
  790. package/examples/typescript/stock-chart-intraday/package.json +1 -1
  791. package/examples/typescript/stock-chart-intraday/tsconfig.json +1 -1
  792. package/examples/typescript/stock-chart-live/package.json +1 -1
  793. package/examples/typescript/stock-chart-live/tsconfig.json +1 -1
  794. package/examples/typescript/stock-chart-volume-separate-panel/package.json +1 -1
  795. package/examples/typescript/stock-chart-volume-separate-panel/tsconfig.json +1 -1
  796. package/examples/typescript/venn-diagram/package.json +1 -1
  797. package/examples/typescript/venn-diagram/tsconfig.json +1 -1
  798. package/examples/typescript/wordcloud-with-data/package.json +1 -1
  799. package/examples/typescript/wordcloud-with-data/tsconfig.json +1 -1
  800. package/examples/typescript/wordcloud-with-text/package.json +1 -1
  801. package/examples/typescript/wordcloud-with-text/tsconfig.json +1 -1
  802. package/examples/typescript/xy-100-percent-stacked-column/package.json +1 -1
  803. package/examples/typescript/xy-100-percent-stacked-column/tsconfig.json +1 -1
  804. package/examples/typescript/xy-animated-bullet-at-the-end-of-the-series/package.json +1 -1
  805. package/examples/typescript/xy-animated-bullet-at-the-end-of-the-series/tsconfig.json +1 -1
  806. package/examples/typescript/xy-bubble/package.json +1 -1
  807. package/examples/typescript/xy-bubble/tsconfig.json +1 -1
  808. package/examples/typescript/xy-candlestick/package.json +1 -1
  809. package/examples/typescript/xy-candlestick/tsconfig.json +1 -1
  810. package/examples/typescript/xy-clustered-column/package.json +1 -1
  811. package/examples/typescript/xy-clustered-column/tsconfig.json +1 -1
  812. package/examples/typescript/xy-column/package.json +1 -1
  813. package/examples/typescript/xy-column/tsconfig.json +1 -1
  814. package/examples/typescript/xy-comparing-series-google-analytics-style/package.json +1 -1
  815. package/examples/typescript/xy-comparing-series-google-analytics-style/tsconfig.json +1 -1
  816. package/examples/typescript/xy-data-grouping/package.json +1 -1
  817. package/examples/typescript/xy-data-grouping/tsconfig.json +1 -1
  818. package/examples/typescript/xy-draggable-range/package.json +1 -1
  819. package/examples/typescript/xy-draggable-range/tsconfig.json +1 -1
  820. package/examples/typescript/xy-drawing-series-with-mouse-or-touch/package.json +1 -1
  821. package/examples/typescript/xy-drawing-series-with-mouse-or-touch/tsconfig.json +1 -1
  822. package/examples/typescript/xy-dumbbell plot/package.json +1 -1
  823. package/examples/typescript/xy-dumbbell plot/tsconfig.json +1 -1
  824. package/examples/typescript/xy-evenly-spaced-date-axis/package.json +1 -1
  825. package/examples/typescript/xy-evenly-spaced-date-axis/tsconfig.json +1 -1
  826. package/examples/typescript/xy-line/package.json +1 -1
  827. package/examples/typescript/xy-line/tsconfig.json +1 -1
  828. package/examples/typescript/xy-line-highlight-on-legend-hover/package.json +1 -1
  829. package/examples/typescript/xy-line-highlight-on-legend-hover/tsconfig.json +1 -1
  830. package/examples/typescript/xy-live-data/package.json +1 -1
  831. package/examples/typescript/xy-live-data/tsconfig.json +1 -1
  832. package/examples/typescript/xy-multiple-synced-value-axes/package.json +1 -1
  833. package/examples/typescript/xy-multiple-synced-value-axes/tsconfig.json +1 -1
  834. package/examples/typescript/xy-ohlc/package.json +1 -1
  835. package/examples/typescript/xy-ohlc/tsconfig.json +1 -1
  836. package/examples/typescript/xy-real-time-data-sorting/package.json +1 -1
  837. package/examples/typescript/xy-real-time-data-sorting/tsconfig.json +1 -1
  838. package/examples/typescript/xy-smoothed-line/package.json +1 -1
  839. package/examples/typescript/xy-smoothed-line/tsconfig.json +1 -1
  840. package/examples/typescript/xy-stacked-and-clustered-column/package.json +1 -1
  841. package/examples/typescript/xy-stacked-and-clustered-column/tsconfig.json +1 -1
  842. package/examples/typescript/xy-stacked-column/package.json +1 -1
  843. package/examples/typescript/xy-stacked-column/tsconfig.json +1 -1
  844. package/examples/typescript/xy-stacked-step/package.json +1 -1
  845. package/examples/typescript/xy-stacked-step/tsconfig.json +1 -1
  846. package/examples/typescript/xy-stock/package.json +1 -1
  847. package/examples/typescript/xy-stock/tsconfig.json +1 -1
  848. package/examples/typescript/xy-stock-comparing/package.json +1 -1
  849. package/examples/typescript/xy-stock-comparing/tsconfig.json +1 -1
  850. package/locales/ar.js +1 -1
  851. package/locales/bg_BG.js +1 -1
  852. package/locales/bs_BA.js +1 -1
  853. package/locales/ca_ES.js +1 -1
  854. package/locales/cs_CZ.js +1 -1
  855. package/locales/da_DK.js +1 -1
  856. package/locales/el_GR.js +1 -1
  857. package/locales/en.js +1 -1
  858. package/locales/en_CA.js +1 -1
  859. package/locales/en_US.js +1 -1
  860. package/locales/et_EE.js +1 -1
  861. package/locales/fi_FI.js +1 -1
  862. package/locales/fr_FR.js +1 -1
  863. package/locales/he_IL.js +1 -1
  864. package/locales/hi_IN.js +1 -1
  865. package/locales/hr_HR.js +1 -1
  866. package/locales/hu_HU.js +1 -1
  867. package/locales/id_ID.js +1 -1
  868. package/locales/ja_JP.js +1 -1
  869. package/locales/ko_KR.js +1 -1
  870. package/locales/lv_LV.js +1 -1
  871. package/locales/nb_NO.js +1 -1
  872. package/locales/nl_NL.js +1 -1
  873. package/locales/pl_PL.js +1 -1
  874. package/locales/ro_RO.js +1 -1
  875. package/locales/sr_RS.js +1 -1
  876. package/locales/th_TH.js +1 -1
  877. package/locales/tr_TR.js +1 -1
  878. package/locales/vi_VN.js +1 -1
  879. package/locales/zh_Hans.js +1 -1
  880. package/locales/zh_Hant.js +1 -1
  881. package/package.json +1 -1
  882. package/plugins/json.d.ts +1 -0
  883. package/plugins/json.d.ts.map +1 -1
  884. package/plugins/json.js +1 -0
  885. package/plugins/json.js.map +1 -1
  886. package/examples/javascript/json/index.js +0 -206
  887. package/examples/typescript/json/index.ts +0 -206
@@ -1,4 +1,3 @@
1
- import { __extends } from "tslib";
2
1
  import { MapChartDefaultTheme } from "./MapChartDefaultTheme";
3
2
  import { SerialChart } from "../../core/render/SerialChart";
4
3
  import { Rectangle } from "../../core/render/Rectangle";
@@ -11,197 +10,190 @@ import * as $type from "../../core/util/Type";
11
10
  import * as $mapUtils from "./MapUtils";
12
11
  import * as $object from "../../core/util/Object";
13
12
  import * as $utils from "../../core/util/Utils";
14
- var MapChart = /** @class */ (function (_super) {
15
- __extends(MapChart, _super);
16
- function MapChart() {
17
- var _this = _super !== null && _super.apply(this, arguments) || this;
18
- Object.defineProperty(_this, "_downTranslateX", {
13
+ export class MapChart extends SerialChart {
14
+ constructor() {
15
+ super(...arguments);
16
+ Object.defineProperty(this, "_downTranslateX", {
19
17
  enumerable: true,
20
18
  configurable: true,
21
19
  writable: true,
22
20
  value: void 0
23
21
  });
24
- Object.defineProperty(_this, "_downTranslateY", {
22
+ Object.defineProperty(this, "_downTranslateY", {
25
23
  enumerable: true,
26
24
  configurable: true,
27
25
  writable: true,
28
26
  value: void 0
29
27
  });
30
- Object.defineProperty(_this, "_downRotationX", {
28
+ Object.defineProperty(this, "_downRotationX", {
31
29
  enumerable: true,
32
30
  configurable: true,
33
31
  writable: true,
34
32
  value: void 0
35
33
  });
36
- Object.defineProperty(_this, "_downRotationY", {
34
+ Object.defineProperty(this, "_downRotationY", {
37
35
  enumerable: true,
38
36
  configurable: true,
39
37
  writable: true,
40
38
  value: void 0
41
39
  });
42
- Object.defineProperty(_this, "_downRotationZ", {
40
+ Object.defineProperty(this, "_downRotationZ", {
43
41
  enumerable: true,
44
42
  configurable: true,
45
43
  writable: true,
46
44
  value: void 0
47
45
  });
48
- Object.defineProperty(_this, "_pLat", {
46
+ Object.defineProperty(this, "_pLat", {
49
47
  enumerable: true,
50
48
  configurable: true,
51
49
  writable: true,
52
50
  value: 0
53
51
  });
54
- Object.defineProperty(_this, "_pLon", {
52
+ Object.defineProperty(this, "_pLon", {
55
53
  enumerable: true,
56
54
  configurable: true,
57
55
  writable: true,
58
56
  value: 0
59
57
  });
60
- Object.defineProperty(_this, "_movePoints", {
58
+ Object.defineProperty(this, "_movePoints", {
61
59
  enumerable: true,
62
60
  configurable: true,
63
61
  writable: true,
64
62
  value: {}
65
63
  });
66
- Object.defineProperty(_this, "_downZoomLevel", {
64
+ Object.defineProperty(this, "_downZoomLevel", {
67
65
  enumerable: true,
68
66
  configurable: true,
69
67
  writable: true,
70
68
  value: 1
71
69
  });
72
- Object.defineProperty(_this, "_doubleDownDistance", {
70
+ Object.defineProperty(this, "_doubleDownDistance", {
73
71
  enumerable: true,
74
72
  configurable: true,
75
73
  writable: true,
76
74
  value: 0
77
75
  });
78
- Object.defineProperty(_this, "_dirtyGeometries", {
76
+ Object.defineProperty(this, "_dirtyGeometries", {
79
77
  enumerable: true,
80
78
  configurable: true,
81
79
  writable: true,
82
80
  value: false
83
81
  });
84
- Object.defineProperty(_this, "_geometryColection", {
82
+ Object.defineProperty(this, "_geometryColection", {
85
83
  enumerable: true,
86
84
  configurable: true,
87
85
  writable: true,
88
86
  value: { type: "GeometryCollection", geometries: [] }
89
87
  });
90
- Object.defineProperty(_this, "_centerLocation", {
88
+ Object.defineProperty(this, "_centerLocation", {
91
89
  enumerable: true,
92
90
  configurable: true,
93
91
  writable: true,
94
92
  value: null
95
93
  });
96
- Object.defineProperty(_this, "_za", {
94
+ Object.defineProperty(this, "_za", {
97
95
  enumerable: true,
98
96
  configurable: true,
99
97
  writable: true,
100
98
  value: void 0
101
99
  });
102
- Object.defineProperty(_this, "_rxa", {
100
+ Object.defineProperty(this, "_rxa", {
103
101
  enumerable: true,
104
102
  configurable: true,
105
103
  writable: true,
106
104
  value: void 0
107
105
  });
108
- Object.defineProperty(_this, "_rya", {
106
+ Object.defineProperty(this, "_rya", {
109
107
  enumerable: true,
110
108
  configurable: true,
111
109
  writable: true,
112
110
  value: void 0
113
111
  });
114
- Object.defineProperty(_this, "_txa", {
112
+ Object.defineProperty(this, "_txa", {
115
113
  enumerable: true,
116
114
  configurable: true,
117
115
  writable: true,
118
116
  value: void 0
119
117
  });
120
- Object.defineProperty(_this, "_tya", {
118
+ Object.defineProperty(this, "_tya", {
121
119
  enumerable: true,
122
120
  configurable: true,
123
121
  writable: true,
124
122
  value: void 0
125
123
  });
126
- Object.defineProperty(_this, "_mapBounds", {
124
+ Object.defineProperty(this, "_mapBounds", {
127
125
  enumerable: true,
128
126
  configurable: true,
129
127
  writable: true,
130
128
  value: [[0, 0], [0, 0]]
131
129
  });
132
- Object.defineProperty(_this, "_geoCentroid", {
130
+ Object.defineProperty(this, "_geoCentroid", {
133
131
  enumerable: true,
134
132
  configurable: true,
135
133
  writable: true,
136
134
  value: { longitude: 0, latitude: 0 }
137
135
  });
138
- Object.defineProperty(_this, "_geoBounds", {
136
+ Object.defineProperty(this, "_geoBounds", {
139
137
  enumerable: true,
140
138
  configurable: true,
141
139
  writable: true,
142
140
  value: { left: 0, right: 0, top: 0, bottom: 0 }
143
141
  });
144
- Object.defineProperty(_this, "_prevGeoBounds", {
142
+ Object.defineProperty(this, "_prevGeoBounds", {
145
143
  enumerable: true,
146
144
  configurable: true,
147
145
  writable: true,
148
146
  value: { left: 0, right: 0, top: 0, bottom: 0 }
149
147
  });
150
- Object.defineProperty(_this, "_dispatchBounds", {
148
+ Object.defineProperty(this, "_dispatchBounds", {
151
149
  enumerable: true,
152
150
  configurable: true,
153
151
  writable: true,
154
152
  value: false
155
153
  });
156
- Object.defineProperty(_this, "_wheelDp", {
154
+ Object.defineProperty(this, "_wheelDp", {
157
155
  enumerable: true,
158
156
  configurable: true,
159
157
  writable: true,
160
158
  value: void 0
161
159
  });
162
- Object.defineProperty(_this, "_pw", {
160
+ Object.defineProperty(this, "_pw", {
163
161
  enumerable: true,
164
162
  configurable: true,
165
163
  writable: true,
166
164
  value: void 0
167
165
  });
168
- Object.defineProperty(_this, "_ph", {
166
+ Object.defineProperty(this, "_ph", {
169
167
  enumerable: true,
170
168
  configurable: true,
171
169
  writable: true,
172
170
  value: void 0
173
171
  });
174
- Object.defineProperty(_this, "_mapFitted", {
172
+ Object.defineProperty(this, "_mapFitted", {
175
173
  enumerable: true,
176
174
  configurable: true,
177
175
  writable: true,
178
176
  value: false
179
177
  });
180
- Object.defineProperty(_this, "_centerX", {
178
+ Object.defineProperty(this, "_centerX", {
181
179
  enumerable: true,
182
180
  configurable: true,
183
181
  writable: true,
184
182
  value: 0
185
183
  });
186
- Object.defineProperty(_this, "_centerY", {
184
+ Object.defineProperty(this, "_centerY", {
187
185
  enumerable: true,
188
186
  configurable: true,
189
187
  writable: true,
190
188
  value: 0
191
189
  });
192
- return _this;
193
190
  }
194
- Object.defineProperty(MapChart.prototype, "_makeGeoPath", {
195
- enumerable: false,
196
- configurable: true,
197
- writable: true,
198
- value: function () {
199
- var projection = this.get("projection");
200
- var path = geoPath();
201
- path.projection(projection);
202
- this.setPrivateRaw("geoPath", path);
203
- }
204
- });
191
+ _makeGeoPath() {
192
+ const projection = this.get("projection");
193
+ const path = geoPath();
194
+ path.projection(projection);
195
+ this.setPrivateRaw("geoPath", path);
196
+ }
205
197
  /**
206
198
  * Returns a geoPoint of the current zoom position.
207
199
  *
@@ -209,474 +201,396 @@ var MapChart = /** @class */ (function (_super) {
209
201
  *
210
202
  * @since 5.2.19
211
203
  */
212
- Object.defineProperty(MapChart.prototype, "geoPoint", {
213
- enumerable: false,
214
- configurable: true,
215
- writable: true,
216
- value: function () {
217
- return this.invert(this.seriesContainer.toGlobal({ x: this.width() / 2, y: this.height() / 2 }));
218
- }
219
- });
204
+ geoPoint() {
205
+ return this.invert(this.seriesContainer.toGlobal({ x: this.width() / 2, y: this.height() / 2 }));
206
+ }
220
207
  /**
221
208
  * Returns coordinates to geographical center of the map.
222
209
  */
223
- Object.defineProperty(MapChart.prototype, "geoCentroid", {
224
- enumerable: false,
225
- configurable: true,
226
- writable: true,
227
- value: function () {
228
- return this._geoCentroid;
229
- }
230
- });
210
+ geoCentroid() {
211
+ return this._geoCentroid;
212
+ }
231
213
  /**
232
214
  * Returns geographical bounds of the map.
233
215
  */
234
- Object.defineProperty(MapChart.prototype, "geoBounds", {
235
- enumerable: false,
236
- configurable: true,
237
- writable: true,
238
- value: function () {
239
- return this._geoBounds;
240
- }
241
- });
242
- Object.defineProperty(MapChart.prototype, "_handleSetWheel", {
243
- enumerable: false,
244
- configurable: true,
245
- writable: true,
246
- value: function () {
247
- var _this = this;
248
- var wheelX = this.get("wheelX");
249
- var wheelY = this.get("wheelY");
250
- var chartContainer = this.chartContainer;
251
- if (wheelX != "none" || wheelY != "none") {
252
- if (this._wheelDp) {
253
- this._wheelDp.dispose();
216
+ geoBounds() {
217
+ return this._geoBounds;
218
+ }
219
+ _handleSetWheel() {
220
+ const wheelX = this.get("wheelX");
221
+ const wheelY = this.get("wheelY");
222
+ const chartContainer = this.chartContainer;
223
+ if (wheelX != "none" || wheelY != "none") {
224
+ if (this._wheelDp) {
225
+ this._wheelDp.dispose();
226
+ }
227
+ this._wheelDp = chartContainer.events.on("wheel", (event) => {
228
+ const wheelEasing = this.get("wheelEasing");
229
+ const wheelSensitivity = this.get("wheelSensitivity", 1);
230
+ const wheelDuration = this.get("wheelDuration", 0);
231
+ const wheelEvent = event.originalEvent;
232
+ // Ignore wheel event if it is happening on a non-chart element, e.g. if
233
+ // some page element is over the chart.
234
+ if ($utils.isLocalEvent(wheelEvent, this)) {
235
+ wheelEvent.preventDefault();
254
236
  }
255
- this._wheelDp = chartContainer.events.on("wheel", function (event) {
256
- var wheelEasing = _this.get("wheelEasing");
257
- var wheelSensitivity = _this.get("wheelSensitivity", 1);
258
- var wheelDuration = _this.get("wheelDuration", 0);
259
- var wheelEvent = event.originalEvent;
260
- // Ignore wheel event if it is happening on a non-chart element, e.g. if
261
- // some page element is over the chart.
262
- if ($utils.isLocalEvent(wheelEvent, _this)) {
263
- wheelEvent.preventDefault();
264
- }
265
- else {
266
- return;
267
- }
268
- var chartContainer = _this.chartContainer;
269
- var point = chartContainer._display.toLocal(event.point);
270
- if ((wheelY == "zoom")) {
271
- _this._handleWheelZoom(wheelEvent.deltaY, point);
272
- }
273
- else if (wheelY == "rotateY") {
274
- _this._handleWheelRotateY(wheelEvent.deltaY / 5 * wheelSensitivity, wheelDuration, wheelEasing);
275
- }
276
- else if (wheelY == "rotateX") {
277
- _this._handleWheelRotateX(wheelEvent.deltaY / 5 * wheelSensitivity, wheelDuration, wheelEasing);
278
- }
279
- if ((wheelX == "zoom")) {
280
- _this._handleWheelZoom(wheelEvent.deltaX, point);
281
- }
282
- else if (wheelX == "rotateY") {
283
- _this._handleWheelRotateY(wheelEvent.deltaX / 5 * wheelSensitivity, wheelDuration, wheelEasing);
284
- }
285
- else if (wheelX == "rotateX") {
286
- _this._handleWheelRotateX(wheelEvent.deltaX / 5 * wheelSensitivity, wheelDuration, wheelEasing);
287
- }
288
- });
289
- this._disposers.push(this._wheelDp);
290
- }
291
- else {
292
- if (this._wheelDp) {
293
- this._wheelDp.dispose();
237
+ else {
238
+ return;
294
239
  }
295
- }
296
- }
297
- });
298
- Object.defineProperty(MapChart.prototype, "_prepareChildren", {
299
- enumerable: false,
300
- configurable: true,
301
- writable: true,
302
- value: function () {
303
- var _this = this;
304
- _super.prototype._prepareChildren.call(this);
305
- var projection = this.get("projection");
306
- var w = this.innerWidth();
307
- var h = this.innerHeight();
308
- if (this.isDirty("projection")) {
309
- this._makeGeoPath();
310
- this.markDirtyProjection();
311
- this._fitMap();
312
- projection.scale(this.getPrivate("mapScale") * this.get("zoomLevel", 1));
313
- if (projection.rotate) {
314
- projection.rotate([this.get("rotationX", 0), this.get("rotationY", 0), this.get("rotationZ", 0)]);
240
+ const chartContainer = this.chartContainer;
241
+ const point = chartContainer._display.toLocal(event.point);
242
+ if ((wheelY == "zoom")) {
243
+ this._handleWheelZoom(wheelEvent.deltaY, point);
315
244
  }
316
- var prev = this._prevSettings.projection;
317
- if (prev && prev != projection) {
318
- var hw = w / 2;
319
- var hh = h / 2;
320
- if (prev.invert) {
321
- var centerLocation = prev.invert([hw, hh]);
322
- if (centerLocation) {
323
- var xy = projection(centerLocation);
324
- if (xy) {
325
- var translate = projection.translate();
326
- var xx = hw - ((xy[0] - translate[0]));
327
- var yy = hh - ((xy[1] - translate[1]));
328
- projection.translate([xx, yy]);
329
- this.setRaw("translateX", xx);
330
- this.setRaw("translateY", yy);
331
- }
332
- }
333
- }
245
+ else if (wheelY == "rotateY") {
246
+ this._handleWheelRotateY(wheelEvent.deltaY / 5 * wheelSensitivity, wheelDuration, wheelEasing);
334
247
  }
248
+ else if (wheelY == "rotateX") {
249
+ this._handleWheelRotateX(wheelEvent.deltaY / 5 * wheelSensitivity, wheelDuration, wheelEasing);
250
+ }
251
+ if ((wheelX == "zoom")) {
252
+ this._handleWheelZoom(wheelEvent.deltaX, point);
253
+ }
254
+ else if (wheelX == "rotateY") {
255
+ this._handleWheelRotateY(wheelEvent.deltaX / 5 * wheelSensitivity, wheelDuration, wheelEasing);
256
+ }
257
+ else if (wheelX == "rotateX") {
258
+ this._handleWheelRotateX(wheelEvent.deltaX / 5 * wheelSensitivity, wheelDuration, wheelEasing);
259
+ }
260
+ });
261
+ this._disposers.push(this._wheelDp);
262
+ }
263
+ else {
264
+ if (this._wheelDp) {
265
+ this._wheelDp.dispose();
335
266
  }
336
- if (this.isDirty("wheelX") || this.isDirty("wheelY")) {
337
- this._handleSetWheel();
338
- }
339
- var previousGeometries = this._geometryColection.geometries;
340
- if (this._dirtyGeometries) {
341
- this._geometryColection.geometries = [];
342
- this.series.each(function (series) {
343
- $array.pushAll(_this._geometryColection.geometries, series._geometries);
344
- });
345
- this._fitMap();
346
- }
347
- if (previousGeometries.length != 0 && (w != this._pw || h != this._ph || this._dirtyGeometries)) {
348
- if (w > 0 && h > 0) {
349
- var hw = w / 2;
350
- var hh = h / 2;
351
- projection.fitSize([w, h], this._geometryColection);
352
- var newScale = projection.scale();
353
- this.setPrivateRaw("mapScale", newScale);
354
- projection.scale(newScale * this.get("zoomLevel", 1));
355
- if (this._centerLocation) {
356
- var xy = projection(this._centerLocation);
267
+ }
268
+ }
269
+ _prepareChildren() {
270
+ super._prepareChildren();
271
+ const projection = this.get("projection");
272
+ const w = this.innerWidth();
273
+ const h = this.innerHeight();
274
+ if (this.isDirty("projection")) {
275
+ this._makeGeoPath();
276
+ this.markDirtyProjection();
277
+ this._fitMap();
278
+ projection.scale(this.getPrivate("mapScale") * this.get("zoomLevel", 1));
279
+ if (projection.rotate) {
280
+ projection.rotate([this.get("rotationX", 0), this.get("rotationY", 0), this.get("rotationZ", 0)]);
281
+ }
282
+ let prev = this._prevSettings.projection;
283
+ if (prev && prev != projection) {
284
+ let hw = w / 2;
285
+ let hh = h / 2;
286
+ if (prev.invert) {
287
+ let centerLocation = prev.invert([hw, hh]);
288
+ if (centerLocation) {
289
+ let xy = projection(centerLocation);
357
290
  if (xy) {
358
- var translate = projection.translate();
359
- var xx = hw - ((xy[0] - translate[0]));
360
- var yy = hh - ((xy[1] - translate[1]));
291
+ let translate = projection.translate();
292
+ let xx = hw - ((xy[0] - translate[0]));
293
+ let yy = hh - ((xy[1] - translate[1]));
361
294
  projection.translate([xx, yy]);
362
295
  this.setRaw("translateX", xx);
363
296
  this.setRaw("translateY", yy);
364
- this._centerX = translate[0];
365
- this._centerY = translate[1];
366
297
  }
367
298
  }
368
- this.markDirtyProjection();
369
- var geoPath_1 = this.getPrivate("geoPath");
370
- this._mapBounds = geoPath_1.bounds(this._geometryColection);
371
299
  }
372
300
  }
373
- this._pw = w;
374
- this._ph = h;
375
- if (this.isDirty("zoomControl")) {
376
- var previous = this._prevSettings.zoomControl;
377
- var zoomControl = this.get("zoomControl");
378
- if (zoomControl !== previous) {
379
- this._disposeProperty("zoomControl");
380
- if (previous) {
381
- previous.dispose();
382
- }
383
- if (zoomControl) {
384
- zoomControl.setPrivate("chart", this);
385
- this.children.push(zoomControl);
301
+ }
302
+ if (this.isDirty("wheelX") || this.isDirty("wheelY")) {
303
+ this._handleSetWheel();
304
+ }
305
+ var previousGeometries = this._geometryColection.geometries;
306
+ if (this._dirtyGeometries) {
307
+ this._geometryColection.geometries = [];
308
+ this.series.each((series) => {
309
+ $array.pushAll(this._geometryColection.geometries, series._geometries);
310
+ });
311
+ this._fitMap();
312
+ }
313
+ if (previousGeometries.length != 0 && (w != this._pw || h != this._ph || this._dirtyGeometries)) {
314
+ if (w > 0 && h > 0) {
315
+ let hw = w / 2;
316
+ let hh = h / 2;
317
+ projection.fitSize([w, h], this._geometryColection);
318
+ const newScale = projection.scale();
319
+ this.setPrivateRaw("mapScale", newScale);
320
+ projection.scale(newScale * this.get("zoomLevel", 1));
321
+ if (this._centerLocation) {
322
+ let xy = projection(this._centerLocation);
323
+ if (xy) {
324
+ let translate = projection.translate();
325
+ let xx = hw - ((xy[0] - translate[0]));
326
+ let yy = hh - ((xy[1] - translate[1]));
327
+ projection.translate([xx, yy]);
328
+ this.setRaw("translateX", xx);
329
+ this.setRaw("translateY", yy);
330
+ this._centerX = translate[0];
331
+ this._centerY = translate[1];
386
332
  }
387
- this.setRaw("zoomControl", zoomControl);
388
333
  }
389
- }
390
- if (this.isDirty("zoomLevel")) {
391
- projection.scale(this.getPrivate("mapScale") * this.get("zoomLevel", 1));
392
334
  this.markDirtyProjection();
393
- this.series.each(function (series) {
394
- if (series.isType("MapPointSeries")) {
395
- if (series.get("autoScale")) {
396
- $array.each(series.dataItems, function (dataItem) {
397
- var bullets = dataItem.bullets;
398
- if (bullets) {
399
- $array.each(bullets, function (bullet) {
400
- var sprite = bullet.get("sprite");
401
- if (sprite) {
402
- sprite.set("scale", _this.get("zoomLevel"));
403
- }
404
- });
405
- }
406
- });
407
- }
408
- }
409
- });
335
+ const geoPath = this.getPrivate("geoPath");
336
+ this._mapBounds = geoPath.bounds(this._geometryColection);
410
337
  }
411
- if (this.isDirty("translateX") || this.isDirty("translateY")) {
412
- projection.translate([this.get("translateX", this.width() / 2), this.get("translateY", this.height() / 2)]);
413
- this.markDirtyProjection();
414
- }
415
- if (projection.rotate) {
416
- if (this.isDirty("rotationX") || this.isDirty("rotationY") || this.isDirty("rotationZ")) {
417
- projection.rotate([this.get("rotationX", 0), this.get("rotationY", 0), this.get("rotationZ", 0)]);
418
- this.markDirtyProjection();
338
+ }
339
+ this._pw = w;
340
+ this._ph = h;
341
+ if (this.isDirty("zoomControl")) {
342
+ const previous = this._prevSettings.zoomControl;
343
+ const zoomControl = this.get("zoomControl");
344
+ if (zoomControl !== previous) {
345
+ this._disposeProperty("zoomControl");
346
+ if (previous) {
347
+ previous.dispose();
419
348
  }
420
- }
421
- if (this.isDirty("pinchZoom") || this.get("panX") || this.get("panY")) {
422
- this._setUpTouch();
349
+ if (zoomControl) {
350
+ zoomControl.setPrivate("chart", this);
351
+ this.children.push(zoomControl);
352
+ }
353
+ this.setRaw("zoomControl", zoomControl);
423
354
  }
424
355
  }
425
- });
426
- Object.defineProperty(MapChart.prototype, "_fitMap", {
427
- enumerable: false,
428
- configurable: true,
429
- writable: true,
430
- value: function () {
431
- var projection = this.get("projection");
432
- var w = this.innerWidth();
433
- var h = this.innerHeight();
434
- if (w > 0 && h > 0) {
435
- projection.fitSize([w, h], this._geometryColection);
436
- this.setPrivateRaw("mapScale", projection.scale());
437
- var translate = projection.translate();
438
- this.setRaw("translateX", translate[0]);
439
- this.setRaw("translateY", translate[1]);
440
- this._centerX = translate[0];
441
- this._centerY = translate[1];
442
- var geoPath_2 = this.getPrivate("geoPath");
443
- this._mapBounds = geoPath_2.bounds(this._geometryColection);
444
- this._geoCentroid = $mapUtils.getGeoCentroid(this._geometryColection);
445
- var bounds = $mapUtils.getGeoBounds(this._geometryColection);
446
- this._geoBounds = bounds;
447
- if (this._geometryColection.geometries.length > 0) {
448
- bounds.left = $math.round(this._geoBounds.left, 3);
449
- bounds.right = $math.round(this._geoBounds.right, 3);
450
- bounds.top = $math.round(this._geoBounds.top, 3);
451
- bounds.bottom = $math.round(this._geoBounds.bottom, 3);
452
- var prevGeoBounds = this._prevGeoBounds;
453
- if (prevGeoBounds && !$utils.sameBounds(bounds, prevGeoBounds)) {
454
- this._dispatchBounds = true;
455
- this._prevGeoBounds = bounds;
356
+ if (this.isDirty("zoomLevel")) {
357
+ projection.scale(this.getPrivate("mapScale") * this.get("zoomLevel", 1));
358
+ this.markDirtyProjection();
359
+ this.series.each((series) => {
360
+ if (series.isType("MapPointSeries")) {
361
+ if (series.get("autoScale")) {
362
+ $array.each(series.dataItems, (dataItem) => {
363
+ const bullets = dataItem.bullets;
364
+ if (bullets) {
365
+ $array.each(bullets, (bullet) => {
366
+ const sprite = bullet.get("sprite");
367
+ if (sprite) {
368
+ sprite.set("scale", this.get("zoomLevel"));
369
+ }
370
+ });
371
+ }
372
+ });
456
373
  }
457
374
  }
458
- this._mapFitted = true;
375
+ });
376
+ }
377
+ if (this.isDirty("translateX") || this.isDirty("translateY")) {
378
+ projection.translate([this.get("translateX", this.width() / 2), this.get("translateY", this.height() / 2)]);
379
+ this.markDirtyProjection();
380
+ }
381
+ if (projection.rotate) {
382
+ if (this.isDirty("rotationX") || this.isDirty("rotationY") || this.isDirty("rotationZ")) {
383
+ projection.rotate([this.get("rotationX", 0), this.get("rotationY", 0), this.get("rotationZ", 0)]);
384
+ this.markDirtyProjection();
459
385
  }
460
386
  }
461
- });
387
+ if (this.isDirty("pinchZoom") || this.get("panX") || this.get("panY")) {
388
+ this._setUpTouch();
389
+ }
390
+ }
391
+ _fitMap() {
392
+ const projection = this.get("projection");
393
+ let w = this.innerWidth();
394
+ let h = this.innerHeight();
395
+ if (w > 0 && h > 0) {
396
+ projection.fitSize([w, h], this._geometryColection);
397
+ this.setPrivateRaw("mapScale", projection.scale());
398
+ const translate = projection.translate();
399
+ this.setRaw("translateX", translate[0]);
400
+ this.setRaw("translateY", translate[1]);
401
+ this._centerX = translate[0];
402
+ this._centerY = translate[1];
403
+ const geoPath = this.getPrivate("geoPath");
404
+ this._mapBounds = geoPath.bounds(this._geometryColection);
405
+ this._geoCentroid = $mapUtils.getGeoCentroid(this._geometryColection);
406
+ const bounds = $mapUtils.getGeoBounds(this._geometryColection);
407
+ this._geoBounds = bounds;
408
+ if (this._geometryColection.geometries.length > 0) {
409
+ bounds.left = $math.round(this._geoBounds.left, 3);
410
+ bounds.right = $math.round(this._geoBounds.right, 3);
411
+ bounds.top = $math.round(this._geoBounds.top, 3);
412
+ bounds.bottom = $math.round(this._geoBounds.bottom, 3);
413
+ const prevGeoBounds = this._prevGeoBounds;
414
+ if (prevGeoBounds && !$utils.sameBounds(bounds, prevGeoBounds)) {
415
+ this._dispatchBounds = true;
416
+ this._prevGeoBounds = bounds;
417
+ }
418
+ }
419
+ this._mapFitted = true;
420
+ }
421
+ }
462
422
  /**
463
423
  * Returns geographical coordinates for calculated or manual center of the
464
424
  * map.
465
425
  */
466
- Object.defineProperty(MapChart.prototype, "homeGeoPoint", {
467
- enumerable: false,
468
- configurable: true,
469
- writable: true,
470
- value: function () {
471
- var homeGeoPoint = this.get("homeGeoPoint");
472
- if (!homeGeoPoint) {
473
- var geoPath_3 = this.getPrivate("geoPath");
474
- var bounds = geoPath_3.bounds(this._geometryColection);
475
- var left = bounds[0][0];
476
- var top_1 = bounds[0][1];
477
- var right = bounds[1][0];
478
- var bottom = bounds[1][1];
479
- homeGeoPoint = this.invert({ x: left + (right - left) / 2, y: top_1 + (bottom - top_1) / 2 });
480
- }
481
- return homeGeoPoint;
426
+ homeGeoPoint() {
427
+ let homeGeoPoint = this.get("homeGeoPoint");
428
+ if (!homeGeoPoint) {
429
+ const geoPath = this.getPrivate("geoPath");
430
+ const bounds = geoPath.bounds(this._geometryColection);
431
+ const left = bounds[0][0];
432
+ const top = bounds[0][1];
433
+ const right = bounds[1][0];
434
+ const bottom = bounds[1][1];
435
+ homeGeoPoint = this.invert({ x: left + (right - left) / 2, y: top + (bottom - top) / 2 });
482
436
  }
483
- });
437
+ return homeGeoPoint;
438
+ }
484
439
  /**
485
440
  * Repositions the map to the "home" zoom level and center coordinates.
486
441
  *
487
442
  * @see {@link https://www.amcharts.com/docs/v5/charts/map-chart/map-pan-zoom/#Resetting_position_level} for more info
488
443
  * @param duration Animation duration in milliseconds
489
444
  */
490
- Object.defineProperty(MapChart.prototype, "goHome", {
491
- enumerable: false,
492
- configurable: true,
493
- writable: true,
494
- value: function (duration) {
495
- this.zoomToGeoPoint(this.homeGeoPoint(), this.get("homeZoomLevel", 1), true, duration);
496
- }
497
- });
498
- Object.defineProperty(MapChart.prototype, "_updateChildren", {
499
- enumerable: false,
500
- configurable: true,
501
- writable: true,
502
- value: function () {
503
- var projection = this.get("projection");
504
- if (projection.invert) {
505
- var w = this.innerWidth();
506
- var h = this.innerHeight();
507
- if (w > 0 && h > 0) {
508
- this._centerLocation = projection.invert([this.innerWidth() / 2, this.innerHeight() / 2]);
509
- }
445
+ goHome(duration) {
446
+ this.zoomToGeoPoint(this.homeGeoPoint(), this.get("homeZoomLevel", 1), true, duration);
447
+ }
448
+ _updateChildren() {
449
+ const projection = this.get("projection");
450
+ if (projection.invert) {
451
+ let w = this.innerWidth();
452
+ let h = this.innerHeight();
453
+ if (w > 0 && h > 0) {
454
+ this._centerLocation = projection.invert([this.innerWidth() / 2, this.innerHeight() / 2]);
510
455
  }
511
- _super.prototype._updateChildren.call(this);
512
456
  }
513
- });
514
- Object.defineProperty(MapChart.prototype, "_afterChanged", {
515
- enumerable: false,
516
- configurable: true,
517
- writable: true,
518
- value: function () {
519
- _super.prototype._afterChanged.call(this);
520
- if (this._dispatchBounds) {
521
- this._dispatchBounds = false;
522
- var type = "geoboundschanged";
523
- if (this.events.isEnabled(type)) {
524
- this.events.dispatch(type, { type: type, target: this });
525
- }
457
+ super._updateChildren();
458
+ }
459
+ _afterChanged() {
460
+ super._afterChanged();
461
+ if (this._dispatchBounds) {
462
+ this._dispatchBounds = false;
463
+ const type = "geoboundschanged";
464
+ if (this.events.isEnabled(type)) {
465
+ this.events.dispatch(type, { type: type, target: this });
526
466
  }
527
467
  }
528
- });
529
- Object.defineProperty(MapChart.prototype, "_setUpTouch", {
530
- enumerable: false,
531
- configurable: true,
532
- writable: true,
533
- value: function () {
534
- if (!this.chartContainer._display.cancelTouch) {
535
- this.chartContainer._display.cancelTouch = (this.get("pinchZoom") || this.get("panX") || this.get("panY")) ? true : false;
536
- }
468
+ }
469
+ _setUpTouch() {
470
+ if (!this.chartContainer._display.cancelTouch) {
471
+ this.chartContainer._display.cancelTouch = (this.get("pinchZoom") || this.get("panX") || this.get("panY")) ? true : false;
537
472
  }
538
- });
473
+ }
539
474
  /**
540
475
  * @ignore
541
476
  */
542
- Object.defineProperty(MapChart.prototype, "markDirtyGeometries", {
543
- enumerable: false,
544
- configurable: true,
545
- writable: true,
546
- value: function () {
547
- this._dirtyGeometries = true;
548
- this.markDirty();
549
- }
550
- });
477
+ markDirtyGeometries() {
478
+ this._dirtyGeometries = true;
479
+ this.markDirty();
480
+ }
551
481
  /**
552
482
  * @ignore
553
483
  */
554
- Object.defineProperty(MapChart.prototype, "markDirtyProjection", {
555
- enumerable: false,
556
- configurable: true,
557
- writable: true,
558
- value: function () {
559
- this.series.each(function (series) {
560
- series.markDirtyProjection();
561
- });
484
+ markDirtyProjection() {
485
+ this.series.each((series) => {
486
+ series.markDirtyProjection();
487
+ });
488
+ }
489
+ _afterNew() {
490
+ this._defaultThemes.push(MapChartDefaultTheme.new(this._root));
491
+ this._settings.themeTags = $utils.mergeTags(this._settings.themeTags, ["map"]);
492
+ this.children.push(this.bulletsContainer);
493
+ super._afterNew();
494
+ this._makeGeoPath();
495
+ this.chartContainer.children.push(this.seriesContainer);
496
+ if (this.get("translateX") == null) {
497
+ this.set("translateX", this.width() / 2);
562
498
  }
563
- });
564
- Object.defineProperty(MapChart.prototype, "_afterNew", {
565
- enumerable: false,
566
- configurable: true,
567
- writable: true,
568
- value: function () {
569
- var _this = this;
570
- this._defaultThemes.push(MapChartDefaultTheme.new(this._root));
571
- this._settings.themeTags = $utils.mergeTags(this._settings.themeTags, ["map"]);
572
- this.children.push(this.bulletsContainer);
573
- _super.prototype._afterNew.call(this);
574
- this._makeGeoPath();
575
- this.chartContainer.children.push(this.seriesContainer);
576
- if (this.get("translateX") == null) {
577
- this.set("translateX", this.width() / 2);
499
+ if (this.get("translateY") == null) {
500
+ this.set("translateY", this.height() / 2);
501
+ }
502
+ // Setting trasnparent background so that full body of the plot container
503
+ // is interactive
504
+ this.chartContainer.set("interactive", true);
505
+ this.chartContainer.set("interactiveChildren", false);
506
+ this.chartContainer.set("background", Rectangle.new(this._root, {
507
+ themeTags: ["map", "background"],
508
+ fill: Color.fromHex(0x000000),
509
+ fillOpacity: 0
510
+ }));
511
+ this._disposers.push(this.chartContainer.events.on("pointerdown", (event) => {
512
+ this._handleChartDown(event);
513
+ }));
514
+ this._disposers.push(this.chartContainer.events.on("globalpointerup", (event) => {
515
+ this._handleChartUp(event);
516
+ }));
517
+ this._disposers.push(this.chartContainer.events.on("globalpointermove", (event) => {
518
+ this._handleChartMove(event);
519
+ }));
520
+ let license = false;
521
+ for (let i = 0; i < registry.licenses.length; i++) {
522
+ if (registry.licenses[i].match(/^AM5M.{5,}/i)) {
523
+ license = true;
578
524
  }
579
- if (this.get("translateY") == null) {
580
- this.set("translateY", this.height() / 2);
525
+ }
526
+ if (!license) {
527
+ this._root._showBranding();
528
+ }
529
+ this._setUpTouch();
530
+ }
531
+ _handleChartDown(event) {
532
+ this._downZoomLevel = this.get("zoomLevel", 1);
533
+ let count = $object.keys(this.chartContainer._downPoints).length;
534
+ if (count == 1) {
535
+ // workaround to solve a problem when events are added to some children of chart container (rotation stops working)
536
+ const downPoint = this.chartContainer._downPoints[1];
537
+ if (downPoint && (downPoint.x == event.point.x && downPoint.y == event.point.y)) {
538
+ count = 0;
581
539
  }
582
- // Setting trasnparent background so that full body of the plot container
583
- // is interactive
584
- this.chartContainer.set("interactive", true);
585
- this.chartContainer.set("interactiveChildren", false);
586
- this.chartContainer.set("background", Rectangle.new(this._root, {
587
- themeTags: ["map", "background"],
588
- fill: Color.fromHex(0x000000),
589
- fillOpacity: 0
590
- }));
591
- this._disposers.push(this.chartContainer.events.on("pointerdown", function (event) {
592
- _this._handleChartDown(event);
593
- }));
594
- this._disposers.push(this.chartContainer.events.on("globalpointerup", function (event) {
595
- _this._handleChartUp(event);
596
- }));
597
- this._disposers.push(this.chartContainer.events.on("globalpointermove", function (event) {
598
- _this._handleChartMove(event);
599
- }));
600
- var license = false;
601
- for (var i = 0; i < registry.licenses.length; i++) {
602
- if (registry.licenses[i].match(/^AM5M.{5,}/i)) {
603
- license = true;
540
+ }
541
+ if (count > 0) {
542
+ this._downTranslateX = this.get("translateX");
543
+ this._downTranslateY = this.get("translateY");
544
+ this._downRotationX = this.get("rotationX");
545
+ this._downRotationY = this.get("rotationY");
546
+ this._downRotationZ = this.get("rotationZ");
547
+ const downId = this.chartContainer._getDownPointId();
548
+ if (downId) {
549
+ let movePoint = this._movePoints[downId];
550
+ if (movePoint) {
551
+ this.chartContainer._downPoints[downId] = movePoint;
604
552
  }
605
553
  }
606
- if (!license) {
607
- this._root._showBranding();
608
- }
609
- this._setUpTouch();
610
554
  }
611
- });
612
- Object.defineProperty(MapChart.prototype, "_handleChartDown", {
613
- enumerable: false,
614
- configurable: true,
615
- writable: true,
616
- value: function (event) {
617
- this._downZoomLevel = this.get("zoomLevel", 1);
618
- var count = $object.keys(this.chartContainer._downPoints).length;
619
- if (count == 1) {
620
- // workaround to solve a problem when events are added to some children of chart container (rotation stops working)
621
- var downPoint = this.chartContainer._downPoints[1];
622
- if (downPoint && (downPoint.x == event.point.x && downPoint.y == event.point.y)) {
623
- count = 0;
555
+ else if (count == 0) {
556
+ let bg = this.chartContainer.get("background");
557
+ if (bg) {
558
+ bg.events.enableType("click");
559
+ }
560
+ if (this.get("panX") || this.get("panY")) {
561
+ if (this._za) {
562
+ this._za.stop();
624
563
  }
625
- }
626
- if (count > 0) {
564
+ if (this._txa) {
565
+ this._txa.stop();
566
+ }
567
+ if (this._tya) {
568
+ this._tya.stop();
569
+ }
570
+ if (this._rxa) {
571
+ this._rxa.stop();
572
+ }
573
+ if (this._rya) {
574
+ this._rya.stop();
575
+ }
576
+ const downPoint = this.chartContainer._display.toLocal(event.point);
627
577
  this._downTranslateX = this.get("translateX");
628
578
  this._downTranslateY = this.get("translateY");
629
579
  this._downRotationX = this.get("rotationX");
630
580
  this._downRotationY = this.get("rotationY");
631
581
  this._downRotationZ = this.get("rotationZ");
632
- var downId = this.chartContainer._getDownPointId();
633
- if (downId) {
634
- var movePoint = this._movePoints[downId];
635
- if (movePoint) {
636
- this.chartContainer._downPoints[downId] = movePoint;
637
- }
638
- }
639
- }
640
- else if (count == 0) {
641
- var bg = this.chartContainer.get("background");
642
- if (bg) {
643
- bg.events.enableType("click");
644
- }
645
- if (this.get("panX") || this.get("panY")) {
646
- if (this._za) {
647
- this._za.stop();
648
- }
649
- if (this._txa) {
650
- this._txa.stop();
651
- }
652
- if (this._tya) {
653
- this._tya.stop();
654
- }
655
- if (this._rxa) {
656
- this._rxa.stop();
657
- }
658
- if (this._rya) {
659
- this._rya.stop();
660
- }
661
- var downPoint = this.chartContainer._display.toLocal(event.point);
662
- this._downTranslateX = this.get("translateX");
663
- this._downTranslateY = this.get("translateY");
664
- this._downRotationX = this.get("rotationX");
665
- this._downRotationY = this.get("rotationY");
666
- this._downRotationZ = this.get("rotationZ");
667
- var projection = this.get("projection");
668
- if (projection.invert) {
669
- var l0 = projection.invert([downPoint.x, downPoint.y]);
670
- var l1 = projection.invert([downPoint.x + 1, downPoint.y + 1]);
671
- if (l0 && l1) {
672
- this._pLon = Math.abs(l1[0] - l0[0]);
673
- this._pLat = Math.abs(l1[1] - l0[1]);
674
- }
582
+ let projection = this.get("projection");
583
+ if (projection.invert) {
584
+ let l0 = projection.invert([downPoint.x, downPoint.y]);
585
+ let l1 = projection.invert([downPoint.x + 1, downPoint.y + 1]);
586
+ if (l0 && l1) {
587
+ this._pLon = Math.abs(l1[0] - l0[0]);
588
+ this._pLat = Math.abs(l1[1] - l0[1]);
675
589
  }
676
590
  }
677
591
  }
678
592
  }
679
- });
593
+ }
680
594
  /**
681
595
  * Converts screen coordinates (X and Y) within chart to latitude and
682
596
  * longitude.
@@ -684,164 +598,138 @@ var MapChart = /** @class */ (function (_super) {
684
598
  * @param point Screen coordinates
685
599
  * @return Geographical coordinates
686
600
  */
687
- Object.defineProperty(MapChart.prototype, "invert", {
688
- enumerable: false,
689
- configurable: true,
690
- writable: true,
691
- value: function (point) {
692
- var projection = this.get("projection");
693
- if (projection.invert) {
694
- var ll = projection.invert([point.x, point.y]);
695
- if (ll) {
696
- return { longitude: ll[0], latitude: ll[1] };
697
- }
601
+ invert(point) {
602
+ let projection = this.get("projection");
603
+ if (projection.invert) {
604
+ const ll = projection.invert([point.x, point.y]);
605
+ if (ll) {
606
+ return { longitude: ll[0], latitude: ll[1] };
698
607
  }
699
- return { longitude: 0, latitude: 0 };
700
608
  }
701
- });
609
+ return { longitude: 0, latitude: 0 };
610
+ }
702
611
  /**
703
612
  * Converts latitude/longitude to screen coordinates (X and Y).
704
613
  *
705
614
  * @param point Geographical coordinates
706
615
  * @return Screen coordinates
707
616
  */
708
- Object.defineProperty(MapChart.prototype, "convert", {
709
- enumerable: false,
710
- configurable: true,
711
- writable: true,
712
- value: function (point) {
713
- var projection = this.get("projection");
714
- var xy = projection([point.longitude, point.latitude]);
715
- if (xy) {
716
- return { x: xy[0], y: xy[1] };
717
- }
718
- return { x: 0, y: 0 };
617
+ convert(point) {
618
+ let projection = this.get("projection");
619
+ const xy = projection([point.longitude, point.latitude]);
620
+ if (xy) {
621
+ return { x: xy[0], y: xy[1] };
719
622
  }
720
- });
721
- Object.defineProperty(MapChart.prototype, "_handleChartUp", {
722
- enumerable: false,
723
- configurable: true,
724
- writable: true,
725
- value: function (_event) {
726
- this.chartContainer._downPoints = {};
727
- }
728
- });
729
- Object.defineProperty(MapChart.prototype, "_handlePinch", {
730
- enumerable: false,
731
- configurable: true,
732
- writable: true,
733
- value: function () {
734
- var _this = this;
735
- var chartContainer = this.chartContainer;
736
- var i = 0;
737
- var downPoints = [];
738
- var movePoints = [];
739
- $object.each(chartContainer._downPoints, function (k, point) {
740
- downPoints[i] = point;
741
- var movePoint = _this._movePoints[k];
742
- if (movePoint) {
743
- movePoints[i] = movePoint;
744
- }
745
- i++;
746
- });
747
- if (downPoints.length > 1 && movePoints.length > 1) {
748
- var display = chartContainer._display;
749
- var downPoint0 = downPoints[0];
750
- var downPoint1 = downPoints[1];
751
- var movePoint0 = movePoints[0];
752
- var movePoint1 = movePoints[1];
753
- if (downPoint0 && downPoint1 && movePoint0 && movePoint1) {
754
- downPoint0 = display.toLocal(downPoint0);
755
- downPoint1 = display.toLocal(downPoint1);
756
- movePoint0 = display.toLocal(movePoint0);
757
- movePoint1 = display.toLocal(movePoint1);
758
- var initialDistance = Math.hypot(downPoint1.x - downPoint0.x, downPoint1.y - downPoint0.y);
759
- var currentDistance = Math.hypot(movePoint1.x - movePoint0.x, movePoint1.y - movePoint0.y);
760
- var level = currentDistance / initialDistance * this._downZoomLevel;
761
- level = $math.fitToRange(level, this.get("minZoomLevel", 1), this.get("maxZoomLevel", 32));
762
- var moveCenter = { x: movePoint0.x + (movePoint1.x - movePoint0.x) / 2, y: movePoint0.y + (movePoint1.y - movePoint0.y) / 2 };
763
- var downCenter = { x: downPoint0.x + (downPoint1.x - downPoint0.x) / 2, y: downPoint0.y + (downPoint1.y - downPoint0.y) / 2 };
764
- var tx = this._downTranslateX || 0;
765
- var ty = this._downTranslateY || 0;
766
- var zoomLevel = this._downZoomLevel;
767
- var xx = moveCenter.x - (-tx + downCenter.x) / zoomLevel * level;
768
- var yy = moveCenter.y - (-ty + downCenter.y) / zoomLevel * level;
769
- this.set("zoomLevel", level);
770
- this.set("translateX", xx);
771
- this.set("translateY", yy);
772
- }
623
+ return { x: 0, y: 0 };
624
+ }
625
+ _handleChartUp(_event) {
626
+ this.chartContainer._downPoints = {};
627
+ }
628
+ _handlePinch() {
629
+ const chartContainer = this.chartContainer;
630
+ let i = 0;
631
+ let downPoints = [];
632
+ let movePoints = [];
633
+ $object.each(chartContainer._downPoints, (k, point) => {
634
+ downPoints[i] = point;
635
+ let movePoint = this._movePoints[k];
636
+ if (movePoint) {
637
+ movePoints[i] = movePoint;
638
+ }
639
+ i++;
640
+ });
641
+ if (downPoints.length > 1 && movePoints.length > 1) {
642
+ const display = chartContainer._display;
643
+ let downPoint0 = downPoints[0];
644
+ let downPoint1 = downPoints[1];
645
+ let movePoint0 = movePoints[0];
646
+ let movePoint1 = movePoints[1];
647
+ if (downPoint0 && downPoint1 && movePoint0 && movePoint1) {
648
+ downPoint0 = display.toLocal(downPoint0);
649
+ downPoint1 = display.toLocal(downPoint1);
650
+ movePoint0 = display.toLocal(movePoint0);
651
+ movePoint1 = display.toLocal(movePoint1);
652
+ let initialDistance = Math.hypot(downPoint1.x - downPoint0.x, downPoint1.y - downPoint0.y);
653
+ let currentDistance = Math.hypot(movePoint1.x - movePoint0.x, movePoint1.y - movePoint0.y);
654
+ let level = currentDistance / initialDistance * this._downZoomLevel;
655
+ level = $math.fitToRange(level, this.get("minZoomLevel", 1), this.get("maxZoomLevel", 32));
656
+ let moveCenter = { x: movePoint0.x + (movePoint1.x - movePoint0.x) / 2, y: movePoint0.y + (movePoint1.y - movePoint0.y) / 2 };
657
+ let downCenter = { x: downPoint0.x + (downPoint1.x - downPoint0.x) / 2, y: downPoint0.y + (downPoint1.y - downPoint0.y) / 2 };
658
+ let tx = this._downTranslateX || 0;
659
+ let ty = this._downTranslateY || 0;
660
+ let zoomLevel = this._downZoomLevel;
661
+ let xx = moveCenter.x - (-tx + downCenter.x) / zoomLevel * level;
662
+ let yy = moveCenter.y - (-ty + downCenter.y) / zoomLevel * level;
663
+ this.set("zoomLevel", level);
664
+ this.set("translateX", xx);
665
+ this.set("translateY", yy);
773
666
  }
774
667
  }
775
- });
776
- Object.defineProperty(MapChart.prototype, "_handleChartMove", {
777
- enumerable: false,
778
- configurable: true,
779
- writable: true,
780
- value: function (event) {
781
- var chartContainer = this.chartContainer;
782
- var downPoint = chartContainer._getDownPoint();
783
- var downPointId = chartContainer._getDownPointId();
784
- var originalEvent = event.originalEvent;
785
- var pointerId = originalEvent.pointerId;
786
- if (this.get("pinchZoom")) {
787
- if (pointerId) {
788
- this._movePoints[pointerId] = event.point;
789
- if ($object.keys(chartContainer._downPoints).length > 1) {
790
- this._handlePinch();
791
- return;
792
- }
668
+ }
669
+ _handleChartMove(event) {
670
+ const chartContainer = this.chartContainer;
671
+ let downPoint = chartContainer._getDownPoint();
672
+ const downPointId = chartContainer._getDownPointId();
673
+ const originalEvent = event.originalEvent;
674
+ const pointerId = originalEvent.pointerId;
675
+ if (this.get("pinchZoom")) {
676
+ if (pointerId) {
677
+ this._movePoints[pointerId] = event.point;
678
+ if ($object.keys(chartContainer._downPoints).length > 1) {
679
+ this._handlePinch();
680
+ return;
793
681
  }
794
682
  }
795
- if (downPointId && pointerId && pointerId != downPointId) {
796
- return;
797
- }
798
- else {
799
- if (downPoint) {
800
- var panX = this.get("panX");
801
- var panY = this.get("panY");
802
- if (panX != "none" || panY != "none") {
803
- var display = chartContainer._display;
804
- var local = display.toLocal(event.point);
805
- downPoint = display.toLocal(downPoint);
806
- var x = this._downTranslateX;
807
- var y = this._downTranslateY;
808
- if (Math.hypot(downPoint.x - local.x, downPoint.y - local.y) > 5) {
809
- var bg = chartContainer.get("background");
810
- if (bg) {
811
- bg.events.disableType("click");
683
+ }
684
+ if (downPointId && pointerId && pointerId != downPointId) {
685
+ return;
686
+ }
687
+ else {
688
+ if (downPoint) {
689
+ const panX = this.get("panX");
690
+ const panY = this.get("panY");
691
+ if (panX != "none" || panY != "none") {
692
+ const display = chartContainer._display;
693
+ let local = display.toLocal(event.point);
694
+ downPoint = display.toLocal(downPoint);
695
+ let x = this._downTranslateX;
696
+ let y = this._downTranslateY;
697
+ if (Math.hypot(downPoint.x - local.x, downPoint.y - local.y) > 5) {
698
+ let bg = chartContainer.get("background");
699
+ if (bg) {
700
+ bg.events.disableType("click");
701
+ }
702
+ if ($type.isNumber(x) && $type.isNumber(y)) {
703
+ let projection = this.get("projection");
704
+ const zoomLevel = this.get("zoomLevel", 1);
705
+ const maxPanOut = this.get("maxPanOut", 0.4);
706
+ const bounds = this._mapBounds;
707
+ const w = this.width();
708
+ const h = this.height();
709
+ const ww = bounds[1][0] - bounds[0][0];
710
+ const hh = bounds[1][1] - bounds[0][1];
711
+ if (panX == "translateX") {
712
+ x += local.x - downPoint.x;
713
+ const cx = w / 2 - (w / 2 - this._centerX) * zoomLevel;
714
+ x = Math.min(x, cx + ww * maxPanOut * zoomLevel);
715
+ x = Math.max(x, cx - ww * maxPanOut * zoomLevel);
812
716
  }
813
- if ($type.isNumber(x) && $type.isNumber(y)) {
814
- var projection = this.get("projection");
815
- var zoomLevel = this.get("zoomLevel", 1);
816
- var maxPanOut = this.get("maxPanOut", 0.4);
817
- var bounds = this._mapBounds;
818
- var w = this.width();
819
- var h = this.height();
820
- var ww = bounds[1][0] - bounds[0][0];
821
- var hh = bounds[1][1] - bounds[0][1];
822
- if (panX == "translateX") {
823
- x += local.x - downPoint.x;
824
- var cx = w / 2 - (w / 2 - this._centerX) * zoomLevel;
825
- x = Math.min(x, cx + ww * maxPanOut * zoomLevel);
826
- x = Math.max(x, cx - ww * maxPanOut * zoomLevel);
827
- }
828
- if (panY == "translateY") {
829
- y += local.y - downPoint.y;
830
- var cy = h / 2 - (h / 2 - this._centerY) * zoomLevel;
831
- y = Math.min(y, cy + hh * maxPanOut * zoomLevel);
832
- y = Math.max(y, cy - hh * maxPanOut * zoomLevel);
833
- }
834
- this.set("translateX", x);
835
- this.set("translateY", y);
836
- if (projection.invert) {
837
- var downLocation = projection.invert([downPoint.x, downPoint.y]);
838
- if (location && downLocation) {
839
- if (panX == "rotateX") {
840
- this.set("rotationX", this._downRotationX - (downPoint.x - local.x) * this._pLon);
841
- }
842
- if (panY == "rotateY") {
843
- this.set("rotationY", this._downRotationY + (downPoint.y - local.y) * this._pLat);
844
- }
717
+ if (panY == "translateY") {
718
+ y += local.y - downPoint.y;
719
+ const cy = h / 2 - (h / 2 - this._centerY) * zoomLevel;
720
+ y = Math.min(y, cy + hh * maxPanOut * zoomLevel);
721
+ y = Math.max(y, cy - hh * maxPanOut * zoomLevel);
722
+ }
723
+ this.set("translateX", x);
724
+ this.set("translateY", y);
725
+ if (projection.invert) {
726
+ let downLocation = projection.invert([downPoint.x, downPoint.y]);
727
+ if (location && downLocation) {
728
+ if (panX == "rotateX") {
729
+ this.set("rotationX", this._downRotationX - (downPoint.x - local.x) * this._pLon);
730
+ }
731
+ if (panY == "rotateY") {
732
+ this.set("rotationY", this._downRotationY + (downPoint.y - local.y) * this._pLat);
845
733
  }
846
734
  }
847
735
  }
@@ -850,77 +738,57 @@ var MapChart = /** @class */ (function (_super) {
850
738
  }
851
739
  }
852
740
  }
853
- });
854
- Object.defineProperty(MapChart.prototype, "_handleWheelRotateY", {
855
- enumerable: false,
856
- configurable: true,
857
- writable: true,
858
- value: function (delta, duration, easing) {
859
- this._rya = this.animate({ key: "rotationY", to: this.get("rotationY", 0) - delta, duration: duration, easing: easing });
741
+ }
742
+ _handleWheelRotateY(delta, duration, easing) {
743
+ this._rya = this.animate({ key: "rotationY", to: this.get("rotationY", 0) - delta, duration: duration, easing: easing });
744
+ }
745
+ _handleWheelRotateX(delta, duration, easing) {
746
+ this._rxa = this.animate({ key: "rotationX", to: this.get("rotationX", 0) - delta, duration: duration, easing: easing });
747
+ }
748
+ _handleWheelZoom(delta, point) {
749
+ let step = this.get("zoomStep", 2);
750
+ let zoomLevel = this.get("zoomLevel", 1);
751
+ let newZoomLevel = zoomLevel;
752
+ if (delta > 0) {
753
+ newZoomLevel = zoomLevel / step;
860
754
  }
861
- });
862
- Object.defineProperty(MapChart.prototype, "_handleWheelRotateX", {
863
- enumerable: false,
864
- configurable: true,
865
- writable: true,
866
- value: function (delta, duration, easing) {
867
- this._rxa = this.animate({ key: "rotationX", to: this.get("rotationX", 0) - delta, duration: duration, easing: easing });
755
+ else if (delta < 0) {
756
+ newZoomLevel = zoomLevel * step;
868
757
  }
869
- });
870
- Object.defineProperty(MapChart.prototype, "_handleWheelZoom", {
871
- enumerable: false,
872
- configurable: true,
873
- writable: true,
874
- value: function (delta, point) {
875
- var step = this.get("zoomStep", 2);
876
- var zoomLevel = this.get("zoomLevel", 1);
877
- var newZoomLevel = zoomLevel;
878
- if (delta > 0) {
879
- newZoomLevel = zoomLevel / step;
880
- }
881
- else if (delta < 0) {
882
- newZoomLevel = zoomLevel * step;
883
- }
884
- if (newZoomLevel != zoomLevel) {
885
- this.zoomToPoint(point, newZoomLevel);
886
- }
758
+ if (newZoomLevel != zoomLevel) {
759
+ this.zoomToPoint(point, newZoomLevel);
887
760
  }
888
- });
761
+ }
889
762
  /**
890
763
  * Zoom the map to geographical bounds.
891
764
  *
892
765
  * @param geoBounds Bounds
893
766
  * @param duration Animation duration in milliseconds
894
767
  */
895
- Object.defineProperty(MapChart.prototype, "zoomToGeoBounds", {
896
- enumerable: false,
897
- configurable: true,
898
- writable: true,
899
- value: function (geoBounds, duration) {
900
- if (geoBounds.right < geoBounds.left) {
901
- geoBounds.right = 180;
902
- geoBounds.left = -180;
903
- }
904
- var geoPath = this.getPrivate("geoPath");
905
- var mapBounds = geoPath.bounds(this._geometryColection);
906
- var p0 = this.convert({ longitude: geoBounds.left, latitude: geoBounds.top });
907
- var p1 = this.convert({ longitude: geoBounds.right, latitude: geoBounds.bottom });
908
- if (p0.y < mapBounds[0][1]) {
909
- p0.y = mapBounds[0][1];
910
- }
911
- if (p1.y > mapBounds[1][1]) {
912
- p1.y = mapBounds[1][1];
913
- }
914
- var zl = this.get("zoomLevel", 1);
915
- var bounds = { left: p0.x, right: p1.x, top: p0.y, bottom: p1.y };
916
- var seriesContainer = this.seriesContainer;
917
- var zoomLevel = .9 * Math.min(seriesContainer.innerWidth() / (bounds.right - bounds.left) * zl, seriesContainer.innerHeight() / (bounds.bottom - bounds.top) * zl);
918
- var x = bounds.left + (bounds.right - bounds.left) / 2;
919
- var y = bounds.top + (bounds.bottom - bounds.top) / 2;
920
- var geoPoint = this.invert({ x: x, y: y });
921
- return this.zoomToGeoPoint(geoPoint, zoomLevel, true, duration);
768
+ zoomToGeoBounds(geoBounds, duration) {
769
+ if (geoBounds.right < geoBounds.left) {
770
+ geoBounds.right = 180;
771
+ geoBounds.left = -180;
772
+ }
773
+ const geoPath = this.getPrivate("geoPath");
774
+ const mapBounds = geoPath.bounds(this._geometryColection);
775
+ let p0 = this.convert({ longitude: geoBounds.left, latitude: geoBounds.top });
776
+ let p1 = this.convert({ longitude: geoBounds.right, latitude: geoBounds.bottom });
777
+ if (p0.y < mapBounds[0][1]) {
778
+ p0.y = mapBounds[0][1];
779
+ }
780
+ if (p1.y > mapBounds[1][1]) {
781
+ p1.y = mapBounds[1][1];
922
782
  }
923
- });
783
+ let zl = this.get("zoomLevel", 1);
784
+ let bounds = { left: p0.x, right: p1.x, top: p0.y, bottom: p1.y };
785
+ let seriesContainer = this.seriesContainer;
786
+ let zoomLevel = .9 * Math.min(seriesContainer.innerWidth() / (bounds.right - bounds.left) * zl, seriesContainer.innerHeight() / (bounds.bottom - bounds.top) * zl);
787
+ let x = bounds.left + (bounds.right - bounds.left) / 2;
788
+ let y = bounds.top + (bounds.bottom - bounds.top) / 2;
789
+ let geoPoint = this.invert({ x, y });
790
+ return this.zoomToGeoPoint(geoPoint, zoomLevel, true, duration);
791
+ }
924
792
  /**
925
793
  * Zooms the map to specific screen point.
926
794
  *
@@ -929,44 +797,39 @@ var MapChart = /** @class */ (function (_super) {
929
797
  * @param center Center the map
930
798
  * @param duration Duration of the animation in milliseconds
931
799
  */
932
- Object.defineProperty(MapChart.prototype, "zoomToPoint", {
933
- enumerable: false,
934
- configurable: true,
935
- writable: true,
936
- value: function (point, level, center, duration) {
937
- if (level) {
938
- level = $math.fitToRange(level, this.get("minZoomLevel", 1), this.get("maxZoomLevel", 32));
939
- }
940
- if (!$type.isNumber(duration)) {
941
- duration = this.get("animationDuration", 0);
942
- }
943
- var easing = this.get("animationEasing");
944
- var zoomLevel = this.get("zoomLevel", 1);
945
- if (this.get("centerMapOnZoomOut") && level == this.get("homeZoomLevel", 1)) {
946
- point = this.convert(this.homeGeoPoint());
947
- center = true;
948
- }
949
- var x = point.x;
950
- var y = point.y;
951
- var tx = this.get("translateX", 0);
952
- var ty = this.get("translateY", 0);
953
- var cx = x;
954
- var cy = y;
955
- if (center) {
956
- cx = this.width() / 2;
957
- cy = this.height() / 2;
958
- }
959
- var xx = cx - ((x - tx) / zoomLevel * level);
960
- var yy = cy - ((y - ty) / zoomLevel * level);
961
- this._txa = this.animate({ key: "translateX", to: xx, duration: duration, easing: easing });
962
- this._tya = this.animate({ key: "translateY", to: yy, duration: duration, easing: easing });
963
- this._za = this.animate({ key: "zoomLevel", to: level, duration: duration, easing: easing });
964
- if (zoomLevel != level) {
965
- this._root.readerAlert(this._t("Zoom level changed to %1", this._root.locale, $type.numberToString(level)));
966
- }
967
- return this._za;
800
+ zoomToPoint(point, level, center, duration) {
801
+ if (level) {
802
+ level = $math.fitToRange(level, this.get("minZoomLevel", 1), this.get("maxZoomLevel", 32));
968
803
  }
969
- });
804
+ if (!$type.isNumber(duration)) {
805
+ duration = this.get("animationDuration", 0);
806
+ }
807
+ const easing = this.get("animationEasing");
808
+ const zoomLevel = this.get("zoomLevel", 1);
809
+ if (this.get("centerMapOnZoomOut") && level == this.get("homeZoomLevel", 1)) {
810
+ point = this.convert(this.homeGeoPoint());
811
+ center = true;
812
+ }
813
+ let x = point.x;
814
+ let y = point.y;
815
+ let tx = this.get("translateX", 0);
816
+ let ty = this.get("translateY", 0);
817
+ let cx = x;
818
+ let cy = y;
819
+ if (center) {
820
+ cx = this.width() / 2;
821
+ cy = this.height() / 2;
822
+ }
823
+ let xx = cx - ((x - tx) / zoomLevel * level);
824
+ let yy = cy - ((y - ty) / zoomLevel * level);
825
+ this._txa = this.animate({ key: "translateX", to: xx, duration: duration, easing: easing });
826
+ this._tya = this.animate({ key: "translateY", to: yy, duration: duration, easing: easing });
827
+ this._za = this.animate({ key: "zoomLevel", to: level, duration: duration, easing: easing });
828
+ if (zoomLevel != level) {
829
+ this._root.readerAlert(this._t("Zoom level changed to %1", this._root.locale, $type.numberToString(level)));
830
+ }
831
+ return this._za;
832
+ }
970
833
  /**
971
834
  * Zooms the map to specific geographical point.
972
835
  *
@@ -975,78 +838,51 @@ var MapChart = /** @class */ (function (_super) {
975
838
  * @param center Center the map
976
839
  * @param duration Duration of the animation in milliseconds
977
840
  */
978
- Object.defineProperty(MapChart.prototype, "zoomToGeoPoint", {
979
- enumerable: false,
980
- configurable: true,
981
- writable: true,
982
- value: function (geoPoint, level, center, duration) {
983
- var xy = this.convert(geoPoint);
984
- if (xy) {
985
- return this.zoomToPoint(xy, level, center, duration);
986
- }
841
+ zoomToGeoPoint(geoPoint, level, center, duration) {
842
+ let xy = this.convert(geoPoint);
843
+ if (xy) {
844
+ return this.zoomToPoint(xy, level, center, duration);
987
845
  }
988
- });
846
+ }
989
847
  /**
990
848
  * Zooms the map in.
991
849
  */
992
- Object.defineProperty(MapChart.prototype, "zoomIn", {
993
- enumerable: false,
994
- configurable: true,
995
- writable: true,
996
- value: function () {
997
- return this.zoomToPoint({ x: this.width() / 2, y: this.height() / 2 }, this.get("zoomLevel", 1) * this.get("zoomStep", 2));
998
- }
999
- });
850
+ zoomIn() {
851
+ return this.zoomToPoint({ x: this.width() / 2, y: this.height() / 2 }, this.get("zoomLevel", 1) * this.get("zoomStep", 2));
852
+ }
1000
853
  /**
1001
854
  * Zooms the map out.
1002
855
  */
1003
- Object.defineProperty(MapChart.prototype, "zoomOut", {
1004
- enumerable: false,
1005
- configurable: true,
1006
- writable: true,
1007
- value: function () {
1008
- return this.zoomToPoint({ x: this.width() / 2, y: this.height() / 2 }, this.get("zoomLevel", 1) / this.get("zoomStep", 2));
1009
- }
1010
- });
1011
- Object.defineProperty(MapChart.prototype, "_clearDirty", {
1012
- enumerable: false,
1013
- configurable: true,
1014
- writable: true,
1015
- value: function () {
1016
- _super.prototype._clearDirty.call(this);
1017
- this._dirtyGeometries = false;
1018
- this._mapFitted = false;
1019
- }
1020
- });
856
+ zoomOut() {
857
+ return this.zoomToPoint({ x: this.width() / 2, y: this.height() / 2 }, this.get("zoomLevel", 1) / this.get("zoomStep", 2));
858
+ }
859
+ _clearDirty() {
860
+ super._clearDirty();
861
+ this._dirtyGeometries = false;
862
+ this._mapFitted = false;
863
+ }
1021
864
  /**
1022
865
  * Returns area of a mapPolygon in square pixels.
1023
866
  */
1024
- Object.defineProperty(MapChart.prototype, "getArea", {
1025
- enumerable: false,
1026
- configurable: true,
1027
- writable: true,
1028
- value: function (dataItem) {
1029
- var geoPath = this.getPrivate("geoPath");
1030
- var geometry = dataItem.get("geometry");
1031
- if (geometry) {
1032
- return geoPath.area(geometry);
1033
- }
1034
- return 0;
867
+ getArea(dataItem) {
868
+ const geoPath = this.getPrivate("geoPath");
869
+ const geometry = dataItem.get("geometry");
870
+ if (geometry) {
871
+ return geoPath.area(geometry);
1035
872
  }
1036
- });
1037
- Object.defineProperty(MapChart, "className", {
1038
- enumerable: true,
1039
- configurable: true,
1040
- writable: true,
1041
- value: "MapChart"
1042
- });
1043
- Object.defineProperty(MapChart, "classNames", {
1044
- enumerable: true,
1045
- configurable: true,
1046
- writable: true,
1047
- value: SerialChart.classNames.concat([MapChart.className])
1048
- });
1049
- return MapChart;
1050
- }(SerialChart));
1051
- export { MapChart };
873
+ return 0;
874
+ }
875
+ }
876
+ Object.defineProperty(MapChart, "className", {
877
+ enumerable: true,
878
+ configurable: true,
879
+ writable: true,
880
+ value: "MapChart"
881
+ });
882
+ Object.defineProperty(MapChart, "classNames", {
883
+ enumerable: true,
884
+ configurable: true,
885
+ writable: true,
886
+ value: SerialChart.classNames.concat([MapChart.className])
887
+ });
1052
888
  //# sourceMappingURL=MapChart.js.map