@fluentui/react-charting 5.16.33 → 5.16.35

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 (492) hide show
  1. package/CHANGELOG.json +85 -1
  2. package/CHANGELOG.md +29 -2
  3. package/dist/react-charting.js +1 -1
  4. package/dist/react-charting.min.js +1 -1
  5. package/lib/components/AreaChart/AreaChart.base.js +13 -13
  6. package/lib/components/AreaChart/AreaChart.base.js.map +1 -1
  7. package/lib/components/CommonComponents/CartesianChart.base.d.ts +1 -0
  8. package/lib/components/CommonComponents/CartesianChart.base.js +44 -13
  9. package/lib/components/CommonComponents/CartesianChart.base.js.map +1 -1
  10. package/lib/components/CommonComponents/CartesianChart.styles.js +2 -2
  11. package/lib/components/CommonComponents/CartesianChart.styles.js.map +1 -1
  12. package/lib/components/CommonComponents/CartesianChart.types.d.ts +11 -0
  13. package/lib/components/CommonComponents/CartesianChart.types.js.map +1 -1
  14. package/lib/components/DonutChart/Arc/Arc.js +1 -1
  15. package/lib/components/DonutChart/Arc/Arc.js.map +1 -1
  16. package/lib/components/DonutChart/DonutChart.base.js +1 -1
  17. package/lib/components/DonutChart/DonutChart.base.js.map +1 -1
  18. package/lib/components/DonutChart/DonutChart.styles.js +1 -1
  19. package/lib/components/DonutChart/DonutChart.styles.js.map +1 -1
  20. package/lib/components/DonutChart/Pie/Pie.js +1 -1
  21. package/lib/components/DonutChart/Pie/Pie.js.map +1 -1
  22. package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js +4 -4
  23. package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js.map +1 -1
  24. package/lib/components/HeatMapChart/HeatMapChart.base.js +13 -13
  25. package/lib/components/HeatMapChart/HeatMapChart.base.js.map +1 -1
  26. package/lib/components/HorizontalBarChart/HorizontalBarChart.base.js +5 -5
  27. package/lib/components/HorizontalBarChart/HorizontalBarChart.base.js.map +1 -1
  28. package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js +6 -6
  29. package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js.map +1 -1
  30. package/lib/components/Legends/Legends.base.js +4 -4
  31. package/lib/components/Legends/Legends.base.js.map +1 -1
  32. package/lib/components/Legends/Legends.styles.js +3 -3
  33. package/lib/components/Legends/Legends.styles.js.map +1 -1
  34. package/lib/components/Legends/shape.js +10 -10
  35. package/lib/components/Legends/shape.js.map +1 -1
  36. package/lib/components/LineChart/LineChart.base.js +41 -41
  37. package/lib/components/LineChart/LineChart.base.js.map +1 -1
  38. package/lib/components/PieChart/Arc/Arc.js +1 -1
  39. package/lib/components/PieChart/Arc/Arc.js.map +1 -1
  40. package/lib/components/PieChart/Pie/Pie.js +2 -2
  41. package/lib/components/PieChart/Pie/Pie.js.map +1 -1
  42. package/lib/components/SankeyChart/SankeyChart.base.js +6 -6
  43. package/lib/components/SankeyChart/SankeyChart.base.js.map +1 -1
  44. package/lib/components/Sparkline/Sparkline.base.js +1 -1
  45. package/lib/components/Sparkline/Sparkline.base.js.map +1 -1
  46. package/lib/components/StackedBarChart/MultiStackedBarChart.base.js +4 -4
  47. package/lib/components/StackedBarChart/MultiStackedBarChart.base.js.map +1 -1
  48. package/lib/components/StackedBarChart/StackedBarChart.base.js +1 -1
  49. package/lib/components/StackedBarChart/StackedBarChart.base.js.map +1 -1
  50. package/lib/components/StackedBarChart/StackedBarChart.styles.js +2 -2
  51. package/lib/components/StackedBarChart/StackedBarChart.styles.js.map +1 -1
  52. package/lib/components/TreeChart/TreeChart.base.js +8 -8
  53. package/lib/components/TreeChart/TreeChart.base.js.map +1 -1
  54. package/lib/components/VerticalBarChart/VerticalBarChart.base.js +21 -12
  55. package/lib/components/VerticalBarChart/VerticalBarChart.base.js.map +1 -1
  56. package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js +23 -22
  57. package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js.map +1 -1
  58. package/lib/types/IDataPoint.d.ts +10 -0
  59. package/lib/types/IDataPoint.js.map +1 -1
  60. package/lib/utilities/ChartHoverCard/ChartHoverCard.styles.js +2 -2
  61. package/lib/utilities/ChartHoverCard/ChartHoverCard.styles.js.map +1 -1
  62. package/lib/utilities/utilities.d.ts +2 -2
  63. package/lib/utilities/utilities.js +16 -14
  64. package/lib/utilities/utilities.js.map +1 -1
  65. package/lib/version.js +1 -1
  66. package/lib/version.js.map +1 -1
  67. package/lib-amd/AreaChart.js +1 -1
  68. package/lib-amd/AreaChart.js.map +1 -1
  69. package/lib-amd/CartesianChart.js +1 -1
  70. package/lib-amd/CartesianChart.js.map +1 -1
  71. package/lib-amd/DonutChart.js +1 -1
  72. package/lib-amd/DonutChart.js.map +1 -1
  73. package/lib-amd/GroupedVerticalBarChart.js +1 -1
  74. package/lib-amd/GroupedVerticalBarChart.js.map +1 -1
  75. package/lib-amd/HeatMapChart.js +1 -1
  76. package/lib-amd/HeatMapChart.js.map +1 -1
  77. package/lib-amd/HorizontalBarChart.js +1 -1
  78. package/lib-amd/HorizontalBarChart.js.map +1 -1
  79. package/lib-amd/HorizontalBarChartWithAxis.js +1 -1
  80. package/lib-amd/HorizontalBarChartWithAxis.js.map +1 -1
  81. package/lib-amd/Legends.js +1 -1
  82. package/lib-amd/Legends.js.map +1 -1
  83. package/lib-amd/LineChart.js +1 -1
  84. package/lib-amd/LineChart.js.map +1 -1
  85. package/lib-amd/PieChart.js +1 -1
  86. package/lib-amd/PieChart.js.map +1 -1
  87. package/lib-amd/SankeyChart.js +1 -1
  88. package/lib-amd/SankeyChart.js.map +1 -1
  89. package/lib-amd/Sparkline.js +1 -1
  90. package/lib-amd/Sparkline.js.map +1 -1
  91. package/lib-amd/StackedBarChart.js +1 -1
  92. package/lib-amd/StackedBarChart.js.map +1 -1
  93. package/lib-amd/TreeChart.js +1 -1
  94. package/lib-amd/TreeChart.js.map +1 -1
  95. package/lib-amd/VerticalBarChart.js +1 -1
  96. package/lib-amd/VerticalBarChart.js.map +1 -1
  97. package/lib-amd/VerticalStackedBarChart.js +1 -1
  98. package/lib-amd/VerticalStackedBarChart.js.map +1 -1
  99. package/lib-amd/components/AreaChart/AreaChart.base.js +42 -42
  100. package/lib-amd/components/AreaChart/AreaChart.base.js.map +1 -1
  101. package/lib-amd/components/AreaChart/AreaChart.js +1 -1
  102. package/lib-amd/components/AreaChart/AreaChart.js.map +1 -1
  103. package/lib-amd/components/AreaChart/AreaChart.styles.js +1 -1
  104. package/lib-amd/components/AreaChart/AreaChart.styles.js.map +1 -1
  105. package/lib-amd/components/AreaChart/index.js +2 -2
  106. package/lib-amd/components/AreaChart/index.js.map +1 -1
  107. package/lib-amd/components/CommonComponents/CartesianChart.base.d.ts +1 -0
  108. package/lib-amd/components/CommonComponents/CartesianChart.base.js +73 -42
  109. package/lib-amd/components/CommonComponents/CartesianChart.base.js.map +1 -1
  110. package/lib-amd/components/CommonComponents/CartesianChart.js +1 -1
  111. package/lib-amd/components/CommonComponents/CartesianChart.js.map +1 -1
  112. package/lib-amd/components/CommonComponents/CartesianChart.styles.js +6 -6
  113. package/lib-amd/components/CommonComponents/CartesianChart.styles.js.map +1 -1
  114. package/lib-amd/components/CommonComponents/CartesianChart.types.d.ts +11 -0
  115. package/lib-amd/components/CommonComponents/CartesianChart.types.js.map +1 -1
  116. package/lib-amd/components/CommonComponents/index.js +2 -2
  117. package/lib-amd/components/CommonComponents/index.js.map +1 -1
  118. package/lib-amd/components/DonutChart/Arc/Arc.js +6 -6
  119. package/lib-amd/components/DonutChart/Arc/Arc.js.map +1 -1
  120. package/lib-amd/components/DonutChart/Arc/index.js +2 -2
  121. package/lib-amd/components/DonutChart/Arc/index.js.map +1 -1
  122. package/lib-amd/components/DonutChart/DonutChart.base.js +10 -10
  123. package/lib-amd/components/DonutChart/DonutChart.base.js.map +1 -1
  124. package/lib-amd/components/DonutChart/DonutChart.js +1 -1
  125. package/lib-amd/components/DonutChart/DonutChart.js.map +1 -1
  126. package/lib-amd/components/DonutChart/DonutChart.styles.js +1 -1
  127. package/lib-amd/components/DonutChart/DonutChart.styles.js.map +1 -1
  128. package/lib-amd/components/DonutChart/Pie/Pie.js +4 -4
  129. package/lib-amd/components/DonutChart/Pie/Pie.js.map +1 -1
  130. package/lib-amd/components/DonutChart/Pie/index.js +2 -2
  131. package/lib-amd/components/DonutChart/Pie/index.js.map +1 -1
  132. package/lib-amd/components/DonutChart/index.js +3 -3
  133. package/lib-amd/components/DonutChart/index.js.map +1 -1
  134. package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js +23 -23
  135. package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js.map +1 -1
  136. package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.js +1 -1
  137. package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.js.map +1 -1
  138. package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.styles.js +1 -1
  139. package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.styles.js.map +1 -1
  140. package/lib-amd/components/GroupedVerticalBarChart/index.js +2 -2
  141. package/lib-amd/components/GroupedVerticalBarChart/index.js.map +1 -1
  142. package/lib-amd/components/HeatMapChart/HeatMapChart.base.js +25 -25
  143. package/lib-amd/components/HeatMapChart/HeatMapChart.base.js.map +1 -1
  144. package/lib-amd/components/HeatMapChart/HeatMapChart.js +1 -1
  145. package/lib-amd/components/HeatMapChart/HeatMapChart.js.map +1 -1
  146. package/lib-amd/components/HeatMapChart/index.js +2 -2
  147. package/lib-amd/components/HeatMapChart/index.js.map +1 -1
  148. package/lib-amd/components/HorizontalBarChart/HorizontalBarChart.base.js +17 -17
  149. package/lib-amd/components/HorizontalBarChart/HorizontalBarChart.base.js.map +1 -1
  150. package/lib-amd/components/HorizontalBarChart/HorizontalBarChart.js +1 -1
  151. package/lib-amd/components/HorizontalBarChart/HorizontalBarChart.js.map +1 -1
  152. package/lib-amd/components/HorizontalBarChart/HorizontalBarChart.styles.js +2 -2
  153. package/lib-amd/components/HorizontalBarChart/HorizontalBarChart.styles.js.map +1 -1
  154. package/lib-amd/components/HorizontalBarChart/index.js +3 -3
  155. package/lib-amd/components/HorizontalBarChart/index.js.map +1 -1
  156. package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js +36 -36
  157. package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js.map +1 -1
  158. package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.js +1 -1
  159. package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.js.map +1 -1
  160. package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.styles.js +1 -1
  161. package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.styles.js.map +1 -1
  162. package/lib-amd/components/HorizontalBarChartWithAxis/index.js +2 -2
  163. package/lib-amd/components/HorizontalBarChartWithAxis/index.js.map +1 -1
  164. package/lib-amd/components/Legends/Legends.base.js +16 -16
  165. package/lib-amd/components/Legends/Legends.base.js.map +1 -1
  166. package/lib-amd/components/Legends/Legends.js +1 -1
  167. package/lib-amd/components/Legends/Legends.js.map +1 -1
  168. package/lib-amd/components/Legends/Legends.styles.js +8 -8
  169. package/lib-amd/components/Legends/Legends.styles.js.map +1 -1
  170. package/lib-amd/components/Legends/index.js +3 -3
  171. package/lib-amd/components/Legends/index.js.map +1 -1
  172. package/lib-amd/components/Legends/shape.js +11 -11
  173. package/lib-amd/components/Legends/shape.js.map +1 -1
  174. package/lib-amd/components/LineChart/LineChart.base.js +78 -78
  175. package/lib-amd/components/LineChart/LineChart.base.js.map +1 -1
  176. package/lib-amd/components/LineChart/LineChart.js +1 -1
  177. package/lib-amd/components/LineChart/LineChart.js.map +1 -1
  178. package/lib-amd/components/LineChart/LineChart.styles.js +1 -1
  179. package/lib-amd/components/LineChart/LineChart.styles.js.map +1 -1
  180. package/lib-amd/components/LineChart/eventAnnotation/EventAnnotation.js +3 -3
  181. package/lib-amd/components/LineChart/eventAnnotation/EventAnnotation.js.map +1 -1
  182. package/lib-amd/components/LineChart/eventAnnotation/Textbox.js +3 -3
  183. package/lib-amd/components/LineChart/eventAnnotation/Textbox.js.map +1 -1
  184. package/lib-amd/components/LineChart/index.js +3 -3
  185. package/lib-amd/components/LineChart/index.js.map +1 -1
  186. package/lib-amd/components/PieChart/Arc/Arc.js +5 -5
  187. package/lib-amd/components/PieChart/Arc/Arc.js.map +1 -1
  188. package/lib-amd/components/PieChart/Arc/index.js +2 -2
  189. package/lib-amd/components/PieChart/Arc/index.js.map +1 -1
  190. package/lib-amd/components/PieChart/Pie/Pie.js +3 -3
  191. package/lib-amd/components/PieChart/Pie/Pie.js.map +1 -1
  192. package/lib-amd/components/PieChart/Pie/index.js +2 -2
  193. package/lib-amd/components/PieChart/Pie/index.js.map +1 -1
  194. package/lib-amd/components/PieChart/PieChart.base.js +2 -2
  195. package/lib-amd/components/PieChart/PieChart.base.js.map +1 -1
  196. package/lib-amd/components/PieChart/PieChart.js +1 -1
  197. package/lib-amd/components/PieChart/PieChart.js.map +1 -1
  198. package/lib-amd/components/PieChart/PieChart.styles.js +1 -1
  199. package/lib-amd/components/PieChart/PieChart.styles.js.map +1 -1
  200. package/lib-amd/components/PieChart/index.js +2 -2
  201. package/lib-amd/components/PieChart/index.js.map +1 -1
  202. package/lib-amd/components/SankeyChart/SankeyChart.base.js +27 -27
  203. package/lib-amd/components/SankeyChart/SankeyChart.base.js.map +1 -1
  204. package/lib-amd/components/SankeyChart/SankeyChart.js +1 -1
  205. package/lib-amd/components/SankeyChart/SankeyChart.js.map +1 -1
  206. package/lib-amd/components/SankeyChart/SankeyChart.styles.js +1 -1
  207. package/lib-amd/components/SankeyChart/SankeyChart.styles.js.map +1 -1
  208. package/lib-amd/components/SankeyChart/index.js +2 -2
  209. package/lib-amd/components/SankeyChart/index.js.map +1 -1
  210. package/lib-amd/components/Sparkline/Sparkline.base.js +9 -9
  211. package/lib-amd/components/Sparkline/Sparkline.base.js.map +1 -1
  212. package/lib-amd/components/Sparkline/Sparkline.js +1 -1
  213. package/lib-amd/components/Sparkline/Sparkline.js.map +1 -1
  214. package/lib-amd/components/Sparkline/Sparkline.styles.js +1 -1
  215. package/lib-amd/components/Sparkline/Sparkline.styles.js.map +1 -1
  216. package/lib-amd/components/Sparkline/index.js +2 -2
  217. package/lib-amd/components/Sparkline/index.js.map +1 -1
  218. package/lib-amd/components/StackedBarChart/MultiStackedBarChart.base.js +15 -15
  219. package/lib-amd/components/StackedBarChart/MultiStackedBarChart.base.js.map +1 -1
  220. package/lib-amd/components/StackedBarChart/MultiStackedBarChart.js +1 -1
  221. package/lib-amd/components/StackedBarChart/MultiStackedBarChart.js.map +1 -1
  222. package/lib-amd/components/StackedBarChart/MultiStackedBarChart.styles.js +1 -1
  223. package/lib-amd/components/StackedBarChart/MultiStackedBarChart.styles.js.map +1 -1
  224. package/lib-amd/components/StackedBarChart/StackedBarChart.base.js +11 -11
  225. package/lib-amd/components/StackedBarChart/StackedBarChart.base.js.map +1 -1
  226. package/lib-amd/components/StackedBarChart/StackedBarChart.js +1 -1
  227. package/lib-amd/components/StackedBarChart/StackedBarChart.js.map +1 -1
  228. package/lib-amd/components/StackedBarChart/StackedBarChart.styles.js +3 -3
  229. package/lib-amd/components/StackedBarChart/StackedBarChart.styles.js.map +1 -1
  230. package/lib-amd/components/StackedBarChart/index.js +5 -5
  231. package/lib-amd/components/StackedBarChart/index.js.map +1 -1
  232. package/lib-amd/components/TreeChart/TreeChart.base.js +20 -20
  233. package/lib-amd/components/TreeChart/TreeChart.base.js.map +1 -1
  234. package/lib-amd/components/TreeChart/TreeChart.js +1 -1
  235. package/lib-amd/components/TreeChart/TreeChart.js.map +1 -1
  236. package/lib-amd/components/TreeChart/TreeChart.styles.js +4 -4
  237. package/lib-amd/components/TreeChart/TreeChart.styles.js.map +1 -1
  238. package/lib-amd/components/TreeChart/index.js +2 -2
  239. package/lib-amd/components/TreeChart/index.js.map +1 -1
  240. package/lib-amd/components/VerticalBarChart/VerticalBarChart.base.js +47 -38
  241. package/lib-amd/components/VerticalBarChart/VerticalBarChart.base.js.map +1 -1
  242. package/lib-amd/components/VerticalBarChart/VerticalBarChart.js +1 -1
  243. package/lib-amd/components/VerticalBarChart/VerticalBarChart.js.map +1 -1
  244. package/lib-amd/components/VerticalBarChart/VerticalBarChart.styles.js +1 -1
  245. package/lib-amd/components/VerticalBarChart/VerticalBarChart.styles.js.map +1 -1
  246. package/lib-amd/components/VerticalBarChart/index.js +2 -2
  247. package/lib-amd/components/VerticalBarChart/index.js.map +1 -1
  248. package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js +42 -41
  249. package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js.map +1 -1
  250. package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.js +1 -1
  251. package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.js.map +1 -1
  252. package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.styles.js +1 -1
  253. package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.styles.js.map +1 -1
  254. package/lib-amd/components/VerticalStackedBarChart/index.js +2 -2
  255. package/lib-amd/components/VerticalStackedBarChart/index.js.map +1 -1
  256. package/lib-amd/index.js +19 -19
  257. package/lib-amd/index.js.map +1 -1
  258. package/lib-amd/types/IDataPoint.d.ts +10 -0
  259. package/lib-amd/types/IDataPoint.js.map +1 -1
  260. package/lib-amd/types/index.js +2 -2
  261. package/lib-amd/types/index.js.map +1 -1
  262. package/lib-amd/utilities/ChartHoverCard/ChartHoverCard.base.js +6 -6
  263. package/lib-amd/utilities/ChartHoverCard/ChartHoverCard.base.js.map +1 -1
  264. package/lib-amd/utilities/ChartHoverCard/ChartHoverCard.js +1 -1
  265. package/lib-amd/utilities/ChartHoverCard/ChartHoverCard.js.map +1 -1
  266. package/lib-amd/utilities/ChartHoverCard/ChartHoverCard.styles.js +2 -2
  267. package/lib-amd/utilities/ChartHoverCard/ChartHoverCard.styles.js.map +1 -1
  268. package/lib-amd/utilities/ChartHoverCard/index.js +3 -3
  269. package/lib-amd/utilities/ChartHoverCard/index.js.map +1 -1
  270. package/lib-amd/utilities/FocusableTooltipText.js +3 -3
  271. package/lib-amd/utilities/FocusableTooltipText.js.map +1 -1
  272. package/lib-amd/utilities/index.js +3 -3
  273. package/lib-amd/utilities/index.js.map +1 -1
  274. package/lib-amd/utilities/utilities.d.ts +2 -2
  275. package/lib-amd/utilities/utilities.js +82 -80
  276. package/lib-amd/utilities/utilities.js.map +1 -1
  277. package/lib-amd/version.js +1 -1
  278. package/lib-amd/version.js.map +1 -1
  279. package/lib-commonjs/AreaChart.js +1 -1
  280. package/lib-commonjs/AreaChart.js.map +1 -1
  281. package/lib-commonjs/CartesianChart.js +1 -1
  282. package/lib-commonjs/CartesianChart.js.map +1 -1
  283. package/lib-commonjs/DonutChart.js +1 -1
  284. package/lib-commonjs/DonutChart.js.map +1 -1
  285. package/lib-commonjs/GroupedVerticalBarChart.js +1 -1
  286. package/lib-commonjs/GroupedVerticalBarChart.js.map +1 -1
  287. package/lib-commonjs/HeatMapChart.js +1 -1
  288. package/lib-commonjs/HeatMapChart.js.map +1 -1
  289. package/lib-commonjs/HorizontalBarChart.js +1 -1
  290. package/lib-commonjs/HorizontalBarChart.js.map +1 -1
  291. package/lib-commonjs/HorizontalBarChartWithAxis.js +1 -1
  292. package/lib-commonjs/HorizontalBarChartWithAxis.js.map +1 -1
  293. package/lib-commonjs/Legends.js +1 -1
  294. package/lib-commonjs/Legends.js.map +1 -1
  295. package/lib-commonjs/LineChart.js +1 -1
  296. package/lib-commonjs/LineChart.js.map +1 -1
  297. package/lib-commonjs/PieChart.js +1 -1
  298. package/lib-commonjs/PieChart.js.map +1 -1
  299. package/lib-commonjs/SankeyChart.js +1 -1
  300. package/lib-commonjs/SankeyChart.js.map +1 -1
  301. package/lib-commonjs/Sparkline.js +1 -1
  302. package/lib-commonjs/Sparkline.js.map +1 -1
  303. package/lib-commonjs/StackedBarChart.js +1 -1
  304. package/lib-commonjs/StackedBarChart.js.map +1 -1
  305. package/lib-commonjs/TreeChart.js +1 -1
  306. package/lib-commonjs/TreeChart.js.map +1 -1
  307. package/lib-commonjs/VerticalBarChart.js +1 -1
  308. package/lib-commonjs/VerticalBarChart.js.map +1 -1
  309. package/lib-commonjs/VerticalStackedBarChart.js +1 -1
  310. package/lib-commonjs/VerticalStackedBarChart.js.map +1 -1
  311. package/lib-commonjs/components/AreaChart/AreaChart.base.js +42 -42
  312. package/lib-commonjs/components/AreaChart/AreaChart.base.js.map +1 -1
  313. package/lib-commonjs/components/AreaChart/AreaChart.js +1 -1
  314. package/lib-commonjs/components/AreaChart/AreaChart.js.map +1 -1
  315. package/lib-commonjs/components/AreaChart/AreaChart.styles.js +1 -1
  316. package/lib-commonjs/components/AreaChart/AreaChart.styles.js.map +1 -1
  317. package/lib-commonjs/components/AreaChart/index.js +2 -2
  318. package/lib-commonjs/components/AreaChart/index.js.map +1 -1
  319. package/lib-commonjs/components/CommonComponents/CartesianChart.base.d.ts +1 -0
  320. package/lib-commonjs/components/CommonComponents/CartesianChart.base.js +73 -42
  321. package/lib-commonjs/components/CommonComponents/CartesianChart.base.js.map +1 -1
  322. package/lib-commonjs/components/CommonComponents/CartesianChart.js +1 -1
  323. package/lib-commonjs/components/CommonComponents/CartesianChart.js.map +1 -1
  324. package/lib-commonjs/components/CommonComponents/CartesianChart.styles.js +6 -6
  325. package/lib-commonjs/components/CommonComponents/CartesianChart.styles.js.map +1 -1
  326. package/lib-commonjs/components/CommonComponents/CartesianChart.types.d.ts +11 -0
  327. package/lib-commonjs/components/CommonComponents/CartesianChart.types.js.map +1 -1
  328. package/lib-commonjs/components/CommonComponents/index.js +2 -2
  329. package/lib-commonjs/components/CommonComponents/index.js.map +1 -1
  330. package/lib-commonjs/components/DonutChart/Arc/Arc.js +6 -6
  331. package/lib-commonjs/components/DonutChart/Arc/Arc.js.map +1 -1
  332. package/lib-commonjs/components/DonutChart/Arc/index.js +2 -2
  333. package/lib-commonjs/components/DonutChart/Arc/index.js.map +1 -1
  334. package/lib-commonjs/components/DonutChart/DonutChart.base.js +10 -10
  335. package/lib-commonjs/components/DonutChart/DonutChart.base.js.map +1 -1
  336. package/lib-commonjs/components/DonutChart/DonutChart.js +1 -1
  337. package/lib-commonjs/components/DonutChart/DonutChart.js.map +1 -1
  338. package/lib-commonjs/components/DonutChart/DonutChart.styles.js +1 -1
  339. package/lib-commonjs/components/DonutChart/DonutChart.styles.js.map +1 -1
  340. package/lib-commonjs/components/DonutChart/Pie/Pie.js +4 -4
  341. package/lib-commonjs/components/DonutChart/Pie/Pie.js.map +1 -1
  342. package/lib-commonjs/components/DonutChart/Pie/index.js +2 -2
  343. package/lib-commonjs/components/DonutChart/Pie/index.js.map +1 -1
  344. package/lib-commonjs/components/DonutChart/index.js +3 -3
  345. package/lib-commonjs/components/DonutChart/index.js.map +1 -1
  346. package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js +23 -23
  347. package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js.map +1 -1
  348. package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.js +1 -1
  349. package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.js.map +1 -1
  350. package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.styles.js +1 -1
  351. package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.styles.js.map +1 -1
  352. package/lib-commonjs/components/GroupedVerticalBarChart/index.js +2 -2
  353. package/lib-commonjs/components/GroupedVerticalBarChart/index.js.map +1 -1
  354. package/lib-commonjs/components/HeatMapChart/HeatMapChart.base.js +25 -25
  355. package/lib-commonjs/components/HeatMapChart/HeatMapChart.base.js.map +1 -1
  356. package/lib-commonjs/components/HeatMapChart/HeatMapChart.js +1 -1
  357. package/lib-commonjs/components/HeatMapChart/HeatMapChart.js.map +1 -1
  358. package/lib-commonjs/components/HeatMapChart/index.js +2 -2
  359. package/lib-commonjs/components/HeatMapChart/index.js.map +1 -1
  360. package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.base.js +17 -17
  361. package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.base.js.map +1 -1
  362. package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.js +1 -1
  363. package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.js.map +1 -1
  364. package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.styles.js +2 -2
  365. package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.styles.js.map +1 -1
  366. package/lib-commonjs/components/HorizontalBarChart/index.js +3 -3
  367. package/lib-commonjs/components/HorizontalBarChart/index.js.map +1 -1
  368. package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js +36 -36
  369. package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js.map +1 -1
  370. package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.js +1 -1
  371. package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.js.map +1 -1
  372. package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.styles.js +1 -1
  373. package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.styles.js.map +1 -1
  374. package/lib-commonjs/components/HorizontalBarChartWithAxis/index.js +2 -2
  375. package/lib-commonjs/components/HorizontalBarChartWithAxis/index.js.map +1 -1
  376. package/lib-commonjs/components/Legends/Legends.base.js +16 -16
  377. package/lib-commonjs/components/Legends/Legends.base.js.map +1 -1
  378. package/lib-commonjs/components/Legends/Legends.js +1 -1
  379. package/lib-commonjs/components/Legends/Legends.js.map +1 -1
  380. package/lib-commonjs/components/Legends/Legends.styles.js +8 -8
  381. package/lib-commonjs/components/Legends/Legends.styles.js.map +1 -1
  382. package/lib-commonjs/components/Legends/index.js +3 -3
  383. package/lib-commonjs/components/Legends/index.js.map +1 -1
  384. package/lib-commonjs/components/Legends/shape.js +11 -11
  385. package/lib-commonjs/components/Legends/shape.js.map +1 -1
  386. package/lib-commonjs/components/LineChart/LineChart.base.js +78 -78
  387. package/lib-commonjs/components/LineChart/LineChart.base.js.map +1 -1
  388. package/lib-commonjs/components/LineChart/LineChart.js +1 -1
  389. package/lib-commonjs/components/LineChart/LineChart.js.map +1 -1
  390. package/lib-commonjs/components/LineChart/LineChart.styles.js +1 -1
  391. package/lib-commonjs/components/LineChart/LineChart.styles.js.map +1 -1
  392. package/lib-commonjs/components/LineChart/eventAnnotation/EventAnnotation.js +3 -3
  393. package/lib-commonjs/components/LineChart/eventAnnotation/EventAnnotation.js.map +1 -1
  394. package/lib-commonjs/components/LineChart/eventAnnotation/Textbox.js +3 -3
  395. package/lib-commonjs/components/LineChart/eventAnnotation/Textbox.js.map +1 -1
  396. package/lib-commonjs/components/LineChart/index.js +3 -3
  397. package/lib-commonjs/components/LineChart/index.js.map +1 -1
  398. package/lib-commonjs/components/PieChart/Arc/Arc.js +5 -5
  399. package/lib-commonjs/components/PieChart/Arc/Arc.js.map +1 -1
  400. package/lib-commonjs/components/PieChart/Arc/index.js +2 -2
  401. package/lib-commonjs/components/PieChart/Arc/index.js.map +1 -1
  402. package/lib-commonjs/components/PieChart/Pie/Pie.js +3 -3
  403. package/lib-commonjs/components/PieChart/Pie/Pie.js.map +1 -1
  404. package/lib-commonjs/components/PieChart/Pie/index.js +2 -2
  405. package/lib-commonjs/components/PieChart/Pie/index.js.map +1 -1
  406. package/lib-commonjs/components/PieChart/PieChart.base.js +2 -2
  407. package/lib-commonjs/components/PieChart/PieChart.base.js.map +1 -1
  408. package/lib-commonjs/components/PieChart/PieChart.js +1 -1
  409. package/lib-commonjs/components/PieChart/PieChart.js.map +1 -1
  410. package/lib-commonjs/components/PieChart/PieChart.styles.js +1 -1
  411. package/lib-commonjs/components/PieChart/PieChart.styles.js.map +1 -1
  412. package/lib-commonjs/components/PieChart/index.js +2 -2
  413. package/lib-commonjs/components/PieChart/index.js.map +1 -1
  414. package/lib-commonjs/components/SankeyChart/SankeyChart.base.js +27 -27
  415. package/lib-commonjs/components/SankeyChart/SankeyChart.base.js.map +1 -1
  416. package/lib-commonjs/components/SankeyChart/SankeyChart.js +1 -1
  417. package/lib-commonjs/components/SankeyChart/SankeyChart.js.map +1 -1
  418. package/lib-commonjs/components/SankeyChart/SankeyChart.styles.js +1 -1
  419. package/lib-commonjs/components/SankeyChart/SankeyChart.styles.js.map +1 -1
  420. package/lib-commonjs/components/SankeyChart/index.js +2 -2
  421. package/lib-commonjs/components/SankeyChart/index.js.map +1 -1
  422. package/lib-commonjs/components/Sparkline/Sparkline.base.js +9 -9
  423. package/lib-commonjs/components/Sparkline/Sparkline.base.js.map +1 -1
  424. package/lib-commonjs/components/Sparkline/Sparkline.js +1 -1
  425. package/lib-commonjs/components/Sparkline/Sparkline.js.map +1 -1
  426. package/lib-commonjs/components/Sparkline/Sparkline.styles.js +1 -1
  427. package/lib-commonjs/components/Sparkline/Sparkline.styles.js.map +1 -1
  428. package/lib-commonjs/components/Sparkline/index.js +2 -2
  429. package/lib-commonjs/components/Sparkline/index.js.map +1 -1
  430. package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.base.js +15 -15
  431. package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.base.js.map +1 -1
  432. package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.js +1 -1
  433. package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.js.map +1 -1
  434. package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.styles.js +1 -1
  435. package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.styles.js.map +1 -1
  436. package/lib-commonjs/components/StackedBarChart/StackedBarChart.base.js +11 -11
  437. package/lib-commonjs/components/StackedBarChart/StackedBarChart.base.js.map +1 -1
  438. package/lib-commonjs/components/StackedBarChart/StackedBarChart.js +1 -1
  439. package/lib-commonjs/components/StackedBarChart/StackedBarChart.js.map +1 -1
  440. package/lib-commonjs/components/StackedBarChart/StackedBarChart.styles.js +3 -3
  441. package/lib-commonjs/components/StackedBarChart/StackedBarChart.styles.js.map +1 -1
  442. package/lib-commonjs/components/StackedBarChart/index.js +5 -5
  443. package/lib-commonjs/components/StackedBarChart/index.js.map +1 -1
  444. package/lib-commonjs/components/TreeChart/TreeChart.base.js +20 -20
  445. package/lib-commonjs/components/TreeChart/TreeChart.base.js.map +1 -1
  446. package/lib-commonjs/components/TreeChart/TreeChart.js +1 -1
  447. package/lib-commonjs/components/TreeChart/TreeChart.js.map +1 -1
  448. package/lib-commonjs/components/TreeChart/TreeChart.styles.js +4 -4
  449. package/lib-commonjs/components/TreeChart/TreeChart.styles.js.map +1 -1
  450. package/lib-commonjs/components/TreeChart/index.js +2 -2
  451. package/lib-commonjs/components/TreeChart/index.js.map +1 -1
  452. package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.base.js +47 -38
  453. package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.base.js.map +1 -1
  454. package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.js +1 -1
  455. package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.js.map +1 -1
  456. package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.styles.js +1 -1
  457. package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.styles.js.map +1 -1
  458. package/lib-commonjs/components/VerticalBarChart/index.js +2 -2
  459. package/lib-commonjs/components/VerticalBarChart/index.js.map +1 -1
  460. package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js +42 -41
  461. package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js.map +1 -1
  462. package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.js +1 -1
  463. package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.js.map +1 -1
  464. package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.styles.js +1 -1
  465. package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.styles.js.map +1 -1
  466. package/lib-commonjs/components/VerticalStackedBarChart/index.js +2 -2
  467. package/lib-commonjs/components/VerticalStackedBarChart/index.js.map +1 -1
  468. package/lib-commonjs/index.js +19 -19
  469. package/lib-commonjs/index.js.map +1 -1
  470. package/lib-commonjs/types/IDataPoint.d.ts +10 -0
  471. package/lib-commonjs/types/IDataPoint.js.map +1 -1
  472. package/lib-commonjs/types/index.js +2 -2
  473. package/lib-commonjs/types/index.js.map +1 -1
  474. package/lib-commonjs/utilities/ChartHoverCard/ChartHoverCard.base.js +6 -6
  475. package/lib-commonjs/utilities/ChartHoverCard/ChartHoverCard.base.js.map +1 -1
  476. package/lib-commonjs/utilities/ChartHoverCard/ChartHoverCard.js +1 -1
  477. package/lib-commonjs/utilities/ChartHoverCard/ChartHoverCard.js.map +1 -1
  478. package/lib-commonjs/utilities/ChartHoverCard/ChartHoverCard.styles.js +2 -2
  479. package/lib-commonjs/utilities/ChartHoverCard/ChartHoverCard.styles.js.map +1 -1
  480. package/lib-commonjs/utilities/ChartHoverCard/index.js +3 -3
  481. package/lib-commonjs/utilities/ChartHoverCard/index.js.map +1 -1
  482. package/lib-commonjs/utilities/FocusableTooltipText.js +3 -3
  483. package/lib-commonjs/utilities/FocusableTooltipText.js.map +1 -1
  484. package/lib-commonjs/utilities/index.js +3 -3
  485. package/lib-commonjs/utilities/index.js.map +1 -1
  486. package/lib-commonjs/utilities/utilities.d.ts +2 -2
  487. package/lib-commonjs/utilities/utilities.js +82 -80
  488. package/lib-commonjs/utilities/utilities.js.map +1 -1
  489. package/lib-commonjs/version.js +1 -1
  490. package/lib-commonjs/version.js.map +1 -1
  491. package/package.json +7 -7
  492. package/src/components/CommonComponents/CartesianChart.types.ts +13 -0
@@ -2,9 +2,9 @@ define(["require", "exports", "tslib", "../../index", "d3-scale", "@fluentui/rea
2
2
  "use strict";
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  exports.HeatMapChartBase = void 0;
5
- var getClassNames = Utilities_1.classNamesFunction();
5
+ var getClassNames = (0, Utilities_1.classNamesFunction)();
6
6
  var HeatMapChartBase = /** @class */ (function (_super) {
7
- tslib_1.__extends(HeatMapChartBase, _super);
7
+ (0, tslib_1.__extends)(HeatMapChartBase, _super);
8
8
  function HeatMapChartBase(props) {
9
9
  var _this = _super.call(this, props) || this;
10
10
  /**
@@ -36,7 +36,7 @@ define(["require", "exports", "tslib", "../../index", "d3-scale", "@fluentui/rea
36
36
  target: _this._rectRefArray[id].refElement,
37
37
  /** Show the callout if highlighted rectangle is focused and Hide it if unhighlighted rectangle is focused */
38
38
  isCalloutVisible: _this.state.selectedLegend === '' || _this.state.selectedLegend === data.legend,
39
- calloutYValue: "" + data.rectText,
39
+ calloutYValue: "".concat(data.rectText),
40
40
  calloutTextColor: _this._colorScale(data.value),
41
41
  calloutLegend: data.legend,
42
42
  ratio: data.ratio || null,
@@ -53,7 +53,7 @@ define(["require", "exports", "tslib", "../../index", "d3-scale", "@fluentui/rea
53
53
  target: _this._rectRefArray[id].refElement,
54
54
  /** Show the callout if highlighted rectangle is hovered and Hide it if unhighlighted rectangle is hovered */
55
55
  isCalloutVisible: _this.state.selectedLegend === '' || _this.state.selectedLegend === data.legend,
56
- calloutYValue: "" + data.rectText,
56
+ calloutYValue: "".concat(data.rectText),
57
57
  calloutTextColor: _this._colorScale(data.value),
58
58
  calloutLegend: data.legend,
59
59
  ratio: data.ratio || null,
@@ -90,12 +90,12 @@ define(["require", "exports", "tslib", "../../index", "d3-scale", "@fluentui/rea
90
90
  * data point such as x, y , value, rectText property of the rectangle
91
91
  */
92
92
  _this._dataSet[yAxisDataPoint].forEach(function (dataPointObject, index2) {
93
- var id = "" + index1 + index2;
94
- var rectElement = (React.createElement("g", { key: id, role: "img", "aria-label": _this._getAriaLabel(dataPointObject), "data-is-focusable": true, fillOpacity: _this._getOpacity(dataPointObject.legend), transform: "translate(" + _this._xAxisScale(dataPointObject.x) + ", " + _this._yAxisScale(dataPointObject.y) + ")", ref: function (gElement) {
93
+ var id = "".concat(index1).concat(index2);
94
+ var rectElement = (React.createElement("g", { key: id, role: "img", "aria-label": _this._getAriaLabel(dataPointObject), "data-is-focusable": true, fillOpacity: _this._getOpacity(dataPointObject.legend), transform: "translate(".concat(_this._xAxisScale(dataPointObject.x), ", ").concat(_this._yAxisScale(dataPointObject.y), ")"), ref: function (gElement) {
95
95
  _this._rectRefCallback(gElement, id, dataPointObject);
96
96
  }, onFocus: _this._onRectFocus.bind(_this, id, dataPointObject), onBlur: _this._onRectBlurOrMouseOut, onMouseOver: _this._onRectMouseOver.bind(_this, id, dataPointObject), onMouseOut: _this._onRectBlurOrMouseOut },
97
97
  React.createElement("rect", { fill: _this._colorScale(dataPointObject.value), width: _this._xAxisScale.bandwidth(), height: _this._yAxisScale.bandwidth(), onClick: dataPointObject.onClick }),
98
- React.createElement("text", { dominantBaseline: 'middle', textAnchor: 'middle', className: _this._classNames.text, transform: "translate(" + _this._xAxisScale.bandwidth() / 2 + ", " + _this._yAxisScale.bandwidth() / 2 + ")" }, utilities_1.convertToLocaleString(dataPointObject.rectText, _this.props.culture))));
98
+ React.createElement("text", { dominantBaseline: 'middle', textAnchor: 'middle', className: _this._classNames.text, transform: "translate(".concat(_this._xAxisScale.bandwidth() / 2, ", ").concat(_this._yAxisScale.bandwidth() / 2, ")") }, (0, utilities_1.convertToLocaleString)(dataPointObject.rectText, _this.props.culture))));
99
99
  rectangles.push(rectElement);
100
100
  });
101
101
  });
@@ -164,23 +164,23 @@ define(["require", "exports", "tslib", "../../index", "d3-scale", "@fluentui/rea
164
164
  };
165
165
  legends.push(legend);
166
166
  });
167
- return React.createElement(index_2.Legends, tslib_1.__assign({}, legendProps, { legends: legends }));
167
+ return React.createElement(index_2.Legends, (0, tslib_1.__assign)({}, legendProps, { legends: legends }));
168
168
  };
169
169
  _this._getColorScale = function () {
170
170
  var _a = _this.props, domainValuesForColorScale = _a.domainValuesForColorScale, rangeValuesForColorScale = _a.rangeValuesForColorScale;
171
- return d3_scale_1.scaleLinear()
171
+ return (0, d3_scale_1.scaleLinear)()
172
172
  .domain(domainValuesForColorScale)
173
173
  .range(rangeValuesForColorScale);
174
174
  };
175
175
  _this._getXIndex = function (value) {
176
176
  if (_this._xAxisType === utilities_1.XAxisTypes.DateAxis) {
177
- return "" + value.getTime();
177
+ return "".concat(value.getTime());
178
178
  }
179
179
  else if (_this._xAxisType === utilities_1.XAxisTypes.StringAxis) {
180
180
  return value;
181
181
  }
182
182
  else if (_this._xAxisType === utilities_1.XAxisTypes.NumericAxis) {
183
- return "" + value;
183
+ return "".concat(value);
184
184
  }
185
185
  else {
186
186
  return '';
@@ -188,13 +188,13 @@ define(["require", "exports", "tslib", "../../index", "d3-scale", "@fluentui/rea
188
188
  };
189
189
  _this._getYIndex = function (value) {
190
190
  if (_this._yAxisType === utilities_1.YAxisType.DateAxis) {
191
- return "" + value.getTime();
191
+ return "".concat(value.getTime());
192
192
  }
193
193
  else if (_this._yAxisType === utilities_1.YAxisType.StringAxis) {
194
194
  return value;
195
195
  }
196
196
  else if (_this._yAxisType === utilities_1.YAxisType.NumericAxis) {
197
- return "" + value;
197
+ return "".concat(value);
198
198
  }
199
199
  else {
200
200
  return '';
@@ -223,7 +223,7 @@ define(["require", "exports", "tslib", "../../index", "d3-scale", "@fluentui/rea
223
223
  */
224
224
  data.forEach(function (item) {
225
225
  item.data.forEach(function (point) {
226
- flattenData.push(tslib_1.__assign(tslib_1.__assign({}, point), { legend: item.legend }));
226
+ flattenData.push((0, tslib_1.__assign)((0, tslib_1.__assign)({}, point), { legend: item.legend }));
227
227
  });
228
228
  });
229
229
  var yPoints = {};
@@ -243,7 +243,7 @@ define(["require", "exports", "tslib", "../../index", "d3-scale", "@fluentui/rea
243
243
  * array are noting but x data points associated to the property y
244
244
  */
245
245
  if (yPoints[posY]) {
246
- yPoints[posY] = tslib_1.__spreadArray(tslib_1.__spreadArray([], yPoints[posY]), [item]);
246
+ yPoints[posY] = (0, tslib_1.__spreadArray)((0, tslib_1.__spreadArray)([], yPoints[posY], true), [item], false);
247
247
  }
248
248
  else {
249
249
  yPoints[posY] = [item];
@@ -305,7 +305,7 @@ define(["require", "exports", "tslib", "../../index", "d3-scale", "@fluentui/rea
305
305
  yPoints[_this._getStringFormattedDate(yPoint, yAxisDateFormatString)] = yPoints[yPoint];
306
306
  }
307
307
  else if (_this._yAxisType === utilities_1.YAxisType.NumericAxis) {
308
- yPoints["" + _this._getStringFormattedNumber(yPoint, yAxisNumberFormatString)] = yPoints[yPoint];
308
+ yPoints["".concat(_this._getStringFormattedNumber(yPoint, yAxisNumberFormatString))] = yPoints[yPoint];
309
309
  }
310
310
  else {
311
311
  yPoints[_this._getFormattedLabelForYAxisDataPoint(yPoint)] = yPoints[yPoint];
@@ -395,7 +395,7 @@ define(["require", "exports", "tslib", "../../index", "d3-scale", "@fluentui/rea
395
395
  return d3TimeFormat.timeFormat(formatString || '%b/%d')(date);
396
396
  };
397
397
  _this._getStringFormattedNumber = function (point, formatString) {
398
- return d3_format_1.format(formatString || '.2~s')(+point);
398
+ return (0, d3_format_1.format)(formatString || '.2~s')(+point);
399
399
  };
400
400
  _this._getFormattedLabelForXAxisDataPoint = function (point) {
401
401
  var xAxisStringFormatter = _this.props.xAxisStringFormatter;
@@ -431,14 +431,14 @@ define(["require", "exports", "tslib", "../../index", "d3-scale", "@fluentui/rea
431
431
  var xValue = point.x;
432
432
  var yValue = point.y;
433
433
  var legend = point.legend;
434
- var zValue = point.ratio ? point.ratio[0] + "/" + point.ratio[1] : point.rectText || point.value;
434
+ var zValue = point.ratio ? "".concat(point.ratio[0], "/").concat(point.ratio[1]) : point.rectText || point.value;
435
435
  var description = point.descriptionMessage;
436
436
  return (((_a = point.callOutAccessibilityData) === null || _a === void 0 ? void 0 : _a.ariaLabel) ||
437
- xValue + ", " + yValue + ". " + legend + ", " + zValue + "." + (description ? " " + description + "." : ''));
437
+ "".concat(xValue, ", ").concat(yValue, ". ").concat(legend, ", ").concat(zValue, ".") + (description ? " ".concat(description, ".") : ''));
438
438
  };
439
439
  var _a = _this._getXandY(), x = _a.x, y = _a.y;
440
- _this._xAxisType = utilities_1.getTypeOfAxis(x, true);
441
- _this._yAxisType = utilities_1.getTypeOfAxis(y, false);
440
+ _this._xAxisType = (0, utilities_1.getTypeOfAxis)(x, true);
441
+ _this._yAxisType = (0, utilities_1.getTypeOfAxis)(y, false);
442
442
  /**
443
443
  * below funciton creates a new data set from the prop
444
444
  * @data and also finds all the unique x-axis datapoints
@@ -446,7 +446,7 @@ define(["require", "exports", "tslib", "../../index", "d3-scale", "@fluentui/rea
446
446
  * we store this in a memoized function, because we want to calulate
447
447
  * this set whenever props changes.
448
448
  */
449
- _this._createSet = Utilities_1.memoizeFunction(function (data, xDate, xNum, yDate, yNum) { return _this._createNewDataSet(data, xDate, xNum, yDate, yNum); });
449
+ _this._createSet = (0, Utilities_1.memoizeFunction)(function (data, xDate, xNum, yDate, yNum) { return _this._createNewDataSet(data, xDate, xNum, yDate, yNum); });
450
450
  _this.state = {
451
451
  selectedLegend: '',
452
452
  activeLegend: '',
@@ -470,11 +470,11 @@ define(["require", "exports", "tslib", "../../index", "d3-scale", "@fluentui/rea
470
470
  this._stringYAxisDataPoints = yAxisPoints;
471
471
  this._stringXAxisDataPoints = xAxisPoints;
472
472
  this._classNames = getClassNames(this.props.styles, { theme: this.props.theme });
473
- var calloutProps = tslib_1.__assign(tslib_1.__assign(tslib_1.__assign(tslib_1.__assign({ isBeakVisible: false, gapSpace: 8 }, this.props.calloutProps), { isCalloutVisible: this.state.isCalloutVisible, id: this.state.calloutId, YValue: this.state.calloutYValue, legend: this.state.calloutLegend, color: this.state.calloutTextColor, target: this.state.target, styles: this._classNames.subComponentStyles.calloutStyles, directionalHint: Callout_1.DirectionalHint.topAutoEdge, onDismiss: this._closeCallout }), utilities_1.getAccessibleDataObject(this.state.callOutAccessibilityData, 'text', false)), { preventDismissOnLostFocus: true });
474
- var chartHoverProps = tslib_1.__assign(tslib_1.__assign({}, (this.state.ratio && {
473
+ var calloutProps = (0, tslib_1.__assign)((0, tslib_1.__assign)((0, tslib_1.__assign)((0, tslib_1.__assign)({ isBeakVisible: false, gapSpace: 8 }, this.props.calloutProps), { isCalloutVisible: this.state.isCalloutVisible, id: this.state.calloutId, YValue: this.state.calloutYValue, legend: this.state.calloutLegend, color: this.state.calloutTextColor, target: this.state.target, styles: this._classNames.subComponentStyles.calloutStyles, directionalHint: Callout_1.DirectionalHint.topAutoEdge, onDismiss: this._closeCallout }), (0, utilities_1.getAccessibleDataObject)(this.state.callOutAccessibilityData, 'text', false)), { preventDismissOnLostFocus: true });
474
+ var chartHoverProps = (0, tslib_1.__assign)((0, tslib_1.__assign)({}, (this.state.ratio && {
475
475
  ratio: this.state.ratio,
476
476
  })), { descriptionMessage: this.state.descriptionMessage });
477
- return (React.createElement(index_1.CartesianChart, tslib_1.__assign({}, this.props, { points: data, chartType: utilities_1.ChartTypes.HeatMapChart, xAxisType: utilities_1.XAxisTypes.StringAxis, yAxisType: utilities_1.YAxisType.StringAxis, calloutProps: calloutProps, chartHoverProps: chartHoverProps, styles: this._classNames.subComponentStyles.cartesianStyles, datasetForXAxisDomain: this._stringXAxisDataPoints, stringDatasetForYAxisDomain: this._stringYAxisDataPoints, xAxisTickCount: this._stringXAxisDataPoints.length, xAxistickSize: 0, xAxisPadding: 0.02, yAxisPadding: 0.02, svgFocusZoneProps: {
477
+ return (React.createElement(index_1.CartesianChart, (0, tslib_1.__assign)({}, this.props, { points: data, chartType: utilities_1.ChartTypes.HeatMapChart, xAxisType: utilities_1.XAxisTypes.StringAxis, yAxisType: utilities_1.YAxisType.StringAxis, calloutProps: calloutProps, chartHoverProps: chartHoverProps, styles: this._classNames.subComponentStyles.cartesianStyles, datasetForXAxisDomain: this._stringXAxisDataPoints, stringDatasetForYAxisDomain: this._stringYAxisDataPoints, xAxisTickCount: this._stringXAxisDataPoints.length, xAxistickSize: 0, xAxisPadding: 0.02, yAxisPadding: 0.02, svgFocusZoneProps: {
478
478
  direction: react_focus_1.FocusZoneDirection.bidirectional,
479
479
  }, legendBars: this._createLegendBars(), onChartMouseLeave: this._handleChartMouseLeave,
480
480
  /* eslint-disable react/jsx-no-bind */
@@ -1 +1 @@
1
- {"version":3,"file":"HeatMapChart.base.js","sourceRoot":"../src/","sources":["components/HeatMapChart/HeatMapChart.base.tsx"],"names":[],"mappings":";;;;IAyFA,IAAM,aAAa,GAAG,8BAAkB,EAAgD,CAAC;IACzF;QAAsC,4CAAuD;QA0B3F,0BAAmB,KAAyB;YAA5C,YACE,kBAAM,KAAK,CAAC,SAgCb;YAzCD;;;eAGG;YACK,mBAAa,GAAgC,EAAE,CAAC;YA2GhD,eAAS,GAAG;gBAClB,IAAI,CAAC,GAA2B,EAAE,CAAC;gBACnC,IAAI,CAAC,GAA2B,EAAE,CAAC;gBACnC,KAAI,CAAC,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,UAAC,IAAuB;oBAC9C,IAAI,IAAI,CAAC,IAAI,IAAI,IAAI,CAAC,IAAI,CAAC,MAAM,GAAG,CAAC,EAAE;wBACrC,CAAC,GAAG,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;wBACnB,CAAC,GAAG,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;wBACnB,OAAO,EAAE,CAAC,GAAA,EAAE,CAAC,GAAA,EAAE,CAAC;qBACjB;gBACH,CAAC,CAAC,CAAC;gBACH,OAAO,EAAE,CAAC,GAAA,EAAE,CAAC,GAAA,EAAE,CAAC;YAClB,CAAC,CAAC;YAEM,iBAAW,GAAG,UAAC,WAAmB;gBACxC,IAAM,OAAO,GAAG,KAAI,CAAC,kBAAkB,CAAC,WAAW,CAAC,IAAI,KAAI,CAAC,oBAAoB,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,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BAC5C,EACD,UAAU,EAAE,IAAI,CAAC,iBAAiB,EAAE,EACpC,iBAAiB,EAAE,IAAI,CAAC,sBAAsB;gBAC9C,sCAAsC;gBACtC,kDAAkD;gBAClD,QAAQ,EAAE,UAAC,KAAkB;oBAC3B,KAAI,CAAC,WAAW,GAAG,KAAK,CAAC,MAAM,CAAC;oBAChC,KAAI,CAAC,WAAW,GAAG,KAAK,CAAC,MAAM,CAAC;oBAChC,OAAO,KAAI,CAAC,iBAAiB,EAAE,CAAC;gBAClC,CAAC,IACD,CACH,CAAC;QACJ,CAAC;QAqdH,uBAAC;IAAD,CAAC,AAplBD,CAAsC,KAAK,CAAC,SAAS,GAolBpD;IAplBY,4CAAgB","sourcesContent":["import {\n IAccessibilityProps,\n CartesianChart,\n IChildProps,\n IModifiedCartesianChartProps,\n IHeatMapChartData,\n IHeatMapChartDataPoint,\n} from '../../index';\nimport { scaleLinear as d3ScaleLinear } from 'd3-scale';\nimport { classNamesFunction, memoizeFunction } from '@fluentui/react/lib/Utilities';\nimport { FocusZoneDirection } from '@fluentui/react-focus';\nimport { DirectionalHint } from '@fluentui/react/lib/Callout';\nimport { IProcessedStyleSet } from '@fluentui/react/lib/Styling';\nimport * as React from 'react';\nimport { IHeatMapChartProps, IHeatMapChartStyleProps, IHeatMapChartStyles } from './HeatMapChart.types';\nimport { ILegend, Legends } from '../Legends/index';\nimport {\n ChartTypes,\n convertToLocaleString,\n getAccessibleDataObject,\n XAxisTypes,\n YAxisType,\n getTypeOfAxis,\n} from '../../utilities/utilities';\nimport { Target } from '@fluentui/react';\nimport { format as d3Format } from 'd3-format';\nimport * as d3TimeFormat from 'd3-time-format';\n\ntype DataSet = {\n dataSet: RectanglesGraphData;\n yAxisPoints: string[];\n xAxisPoints: string[];\n};\ntype FlattenData = IHeatMapChartDataPoint & {\n legend: string;\n};\ninterface IRectRef {\n data: FlattenData;\n refElement: SVGGElement;\n}\ntype RectanglesGraphData = { [key: string]: FlattenData[] };\nexport interface IHeatMapChartState {\n /**\n * contains the selected legend string\n */\n selectedLegend: string;\n /**\n * contains the hovered legend string\n */\n activeLegend: string;\n /**\n * determines wethere to show or hide the callout\n * @default false\n */\n isCalloutVisible: boolean;\n /**\n * y value to be shown in callout\n */\n calloutYValue: string;\n /**\n * legend title to be shown in callout\n */\n calloutLegend: string;\n /**\n * color of the text in the callout\n */\n calloutTextColor: string;\n /**\n * The target that the Callout should try to position itself based on\n */\n target: Target;\n /**\n * ratio to show in the callout\n */\n ratio: [number, number] | null;\n\n /**\n * description message to show in the callout\n */\n descriptionMessage: string;\n /**\n * id to give to callout for accesiblity purpose\n */\n calloutId: string;\n /**\n * Accessibility data for callout\n */\n callOutAccessibilityData?: IAccessibilityProps;\n}\nconst getClassNames = classNamesFunction<IHeatMapChartStyleProps, IHeatMapChartStyles>();\nexport class HeatMapChartBase extends React.Component<IHeatMapChartProps, IHeatMapChartState> {\n private _classNames: IProcessedStyleSet<IHeatMapChartStyles>;\n private _stringXAxisDataPoints: string[];\n private _stringYAxisDataPoints: string[];\n private _createSet: (\n data: IHeatMapChartData[],\n xDate: string | undefined,\n xNum: string | undefined,\n yDate: string | undefined,\n yNum: string | undefined,\n ) => DataSet;\n private _dataSet: RectanglesGraphData;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n private _colorScale: any;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n private _xAxisScale: any;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n private _yAxisScale: any;\n /**\n * This array contains ref for all the rectangles\n * drawn inside the chard\n */\n private _rectRefArray: { [key: string]: IRectRef } = {};\n private _xAxisType: XAxisTypes;\n private _yAxisType: YAxisType;\n private _calloutAnchorPoint: FlattenData | null;\n public constructor(props: IHeatMapChartProps) {\n super(props);\n const { x, y } = this._getXandY();\n this._xAxisType = getTypeOfAxis(x, true) as XAxisTypes;\n this._yAxisType = getTypeOfAxis(y, false) as YAxisType;\n /**\n * below funciton creates a new data set from the prop\n * @data and also finds all the unique x-axis datapoints\n * and y-axis datapoints(which will render in the axis in graph)\n * we store this in a memoized function, because we want to calulate\n * this set whenever props changes.\n */\n this._createSet = memoizeFunction(\n (\n data: IHeatMapChartData[],\n xDate: string | undefined,\n xNum: string | undefined,\n yDate: string | undefined,\n yNum: string | undefined,\n ): DataSet => this._createNewDataSet(data, xDate, xNum, yDate, yNum),\n );\n this.state = {\n selectedLegend: '',\n activeLegend: '',\n isCalloutVisible: false,\n target: null,\n calloutLegend: '',\n calloutTextColor: '',\n calloutYValue: '',\n ratio: null,\n descriptionMessage: '',\n calloutId: '',\n };\n }\n public render(): React.ReactNode {\n const { data, xAxisDateFormatString, xAxisNumberFormatString, yAxisDateFormatString, yAxisNumberFormatString } =\n this.props;\n this._colorScale = this._getColorScale();\n const { dataSet, xAxisPoints, yAxisPoints } = this._createSet(\n data,\n xAxisDateFormatString,\n xAxisNumberFormatString,\n yAxisDateFormatString,\n yAxisNumberFormatString,\n );\n this._dataSet = dataSet;\n this._stringYAxisDataPoints = yAxisPoints;\n this._stringXAxisDataPoints = xAxisPoints;\n this._classNames = getClassNames(this.props.styles!, { theme: this.props.theme! });\n const calloutProps: IModifiedCartesianChartProps['calloutProps'] = {\n isBeakVisible: false,\n gapSpace: 8,\n ...this.props.calloutProps,\n isCalloutVisible: this.state.isCalloutVisible,\n id: this.state.calloutId,\n YValue: this.state.calloutYValue,\n legend: this.state.calloutLegend,\n color: this.state.calloutTextColor,\n target: this.state.target,\n styles: this._classNames.subComponentStyles.calloutStyles,\n directionalHint: DirectionalHint.topAutoEdge,\n onDismiss: this._closeCallout,\n ...getAccessibleDataObject(this.state.callOutAccessibilityData, 'text', false),\n preventDismissOnLostFocus: true,\n };\n const chartHoverProps: IModifiedCartesianChartProps['chartHoverProps'] = {\n ...(this.state.ratio && {\n ratio: this.state.ratio,\n }),\n descriptionMessage: this.state.descriptionMessage,\n };\n return (\n <CartesianChart\n {...this.props}\n points={data}\n chartType={ChartTypes.HeatMapChart}\n xAxisType={XAxisTypes.StringAxis}\n yAxisType={YAxisType.StringAxis}\n calloutProps={calloutProps}\n chartHoverProps={chartHoverProps}\n styles={this._classNames.subComponentStyles!.cartesianStyles}\n datasetForXAxisDomain={this._stringXAxisDataPoints}\n stringDatasetForYAxisDomain={this._stringYAxisDataPoints}\n xAxisTickCount={this._stringXAxisDataPoints.length}\n xAxistickSize={0}\n xAxisPadding={0.02}\n yAxisPadding={0.02}\n svgFocusZoneProps={{\n direction: FocusZoneDirection.bidirectional,\n }}\n legendBars={this._createLegendBars()}\n onChartMouseLeave={this._handleChartMouseLeave}\n /* eslint-disable react/jsx-no-bind */\n // eslint-disable-next-line react/no-children-prop\n children={(props: IChildProps) => {\n this._xAxisScale = props.xScale;\n this._yAxisScale = props.yScale;\n return this._createRectangles();\n }}\n />\n );\n }\n\n private _getXandY = (): { x: string | Date | number; y: string | Date | number } => {\n let x: string | Date | number = '';\n let y: string | Date | number = '';\n this.props.data.forEach((item: IHeatMapChartData) => {\n if (item.data && item.data.length > 0) {\n x = item.data[0].x;\n y = item.data[0].y;\n return { x, y };\n }\n });\n return { x, y };\n };\n\n private _getOpacity = (legendTitle: string): string => {\n const opacity = this._legendHighlighted(legendTitle) || this._noLegendHighlighted() ? '1' : '0.1';\n return opacity;\n };\n\n private _rectRefCallback = (rectElement: SVGGElement, index: number | string, dataPointObject: FlattenData): void => {\n this._rectRefArray[index] = { data: dataPointObject, refElement: rectElement };\n };\n\n private _onRectFocus = (id: string, data: FlattenData): void => {\n this.setState({\n target: this._rectRefArray[id].refElement,\n /** Show the callout if highlighted rectangle is focused and Hide it if unhighlighted rectangle is focused */\n isCalloutVisible: this.state.selectedLegend === '' || this.state.selectedLegend === data.legend,\n calloutYValue: `${data.rectText}`,\n calloutTextColor: this._colorScale(data.value),\n calloutLegend: data.legend,\n ratio: data.ratio || null,\n descriptionMessage: data.descriptionMessage || '',\n calloutId: id,\n callOutAccessibilityData: data.callOutAccessibilityData,\n });\n };\n\n private _onRectMouseOver = (id: string, data: FlattenData, mouseEvent: React.MouseEvent<SVGGElement>): void => {\n mouseEvent.persist();\n if (this._calloutAnchorPoint !== data) {\n this._calloutAnchorPoint = data;\n this.setState({\n target: this._rectRefArray[id].refElement,\n /** Show the callout if highlighted rectangle is hovered and Hide it if unhighlighted rectangle is hovered */\n isCalloutVisible: this.state.selectedLegend === '' || this.state.selectedLegend === data.legend,\n calloutYValue: `${data.rectText}`,\n calloutTextColor: this._colorScale(data.value),\n calloutLegend: data.legend,\n ratio: data.ratio || null,\n descriptionMessage: data.descriptionMessage || '',\n calloutId: id,\n callOutAccessibilityData: data.callOutAccessibilityData,\n });\n }\n };\n\n private _onRectBlurOrMouseOut = (): void => {\n /**/\n };\n\n private _handleChartMouseLeave = (): void => {\n this._calloutAnchorPoint = null;\n this.setState({\n isCalloutVisible: false,\n });\n };\n\n /**\n * This is the function which is responsible for\n * drawing the rectangle in the graph and also\n * attaching dom events to that rectangles\n */\n private _createRectangles = (): React.ReactNode => {\n const rectangles: JSX.Element[] = [];\n const yAxisDataPoints = this._stringYAxisDataPoints.slice().reverse();\n /**\n * yAxisDataPoint is noting but the DataPoint\n * which will be rendered on the y-axis\n */\n yAxisDataPoints.forEach((yAxisDataPoint: string, index1: number) => {\n /**\n * dataPointObject is an object where it contains information on single\n * data point such as x, y , value, rectText property of the rectangle\n */\n this._dataSet[yAxisDataPoint].forEach((dataPointObject: FlattenData, index2: number) => {\n const id = `${index1}${index2}`;\n const rectElement: JSX.Element = (\n <g\n key={id}\n role=\"img\"\n aria-label={this._getAriaLabel(dataPointObject)}\n data-is-focusable={true}\n fillOpacity={this._getOpacity(dataPointObject.legend)}\n transform={`translate(${this._xAxisScale(dataPointObject.x)}, ${this._yAxisScale(dataPointObject.y)})`}\n ref={(gElement: SVGGElement) => {\n this._rectRefCallback(gElement, id, dataPointObject);\n }}\n onFocus={this._onRectFocus.bind(this, id, dataPointObject)}\n onBlur={this._onRectBlurOrMouseOut}\n onMouseOver={this._onRectMouseOver.bind(this, id, dataPointObject)}\n onMouseOut={this._onRectBlurOrMouseOut}\n >\n <rect\n fill={this._colorScale(dataPointObject.value)}\n width={this._xAxisScale.bandwidth()}\n height={this._yAxisScale.bandwidth()}\n onClick={dataPointObject.onClick}\n />\n <text\n dominantBaseline={'middle'}\n textAnchor={'middle'}\n className={this._classNames.text}\n transform={`translate(${this._xAxisScale.bandwidth() / 2}, ${this._yAxisScale.bandwidth() / 2})`}\n >\n {convertToLocaleString(dataPointObject.rectText, this.props.culture)}\n </text>\n </g>\n );\n rectangles.push(rectElement);\n });\n });\n return rectangles;\n };\n /**\n * when the legend is hovered we need to highlight\n * all the rectangles which fall under that category\n * and un-highlight the rest of them\n * @param legendTitle\n */\n private _onLegendHover = (legendTitle: string): void => {\n this.setState({\n activeLegend: legendTitle,\n });\n };\n\n /**\n * when the mouse is out from the legend , we need\n * to show the graph in initial mode.\n */\n private _onLegendLeave = (): void => {\n this.setState({\n activeLegend: '',\n });\n };\n /**\n * @param legendTitle\n * when the legend is clicked we need to highlight\n * all the rectangles which fall under that category\n * and un highlight the rest of them\n */\n private _onLegendClick = (legendTitle: string): void => {\n /**\n * check if the legend is already selceted,\n * if yes, un-select the legend, else\n * set the selected legend state to legendTitle\n */\n if (this.state.selectedLegend === legendTitle) {\n this.setState({\n selectedLegend: '',\n });\n } else {\n this.setState({\n selectedLegend: legendTitle,\n });\n }\n };\n private _createLegendBars = (): JSX.Element => {\n const { data, legendProps } = this.props;\n const legends: ILegend[] = [];\n data.forEach((item: IHeatMapChartData) => {\n const legend: ILegend = {\n title: item.legend,\n color: this._colorScale(item.value),\n action: () => {\n this._onLegendClick(item.legend);\n },\n hoverAction: () => {\n this._handleChartMouseLeave();\n this._onLegendHover(item.legend);\n },\n onMouseOutAction: () => {\n this._onLegendLeave();\n },\n };\n legends.push(legend);\n });\n return <Legends {...legendProps} legends={legends} />;\n };\n\n private _getColorScale = () => {\n const { domainValuesForColorScale, rangeValuesForColorScale } = this.props;\n return d3ScaleLinear()\n .domain(domainValuesForColorScale)\n .range(rangeValuesForColorScale as unknown as number[]);\n };\n\n private _getXIndex = (value: string | Date | number): string => {\n if (this._xAxisType === XAxisTypes.DateAxis) {\n return `${(value as Date).getTime()}`;\n } else if (this._xAxisType === XAxisTypes.StringAxis) {\n return value as string;\n } else if (this._xAxisType === XAxisTypes.NumericAxis) {\n return `${value}`;\n } else {\n return '';\n }\n };\n private _getYIndex = (value: string | Date | number): string => {\n if (this._yAxisType === YAxisType.DateAxis) {\n return `${(value as Date).getTime()}`;\n } else if (this._yAxisType === YAxisType.StringAxis) {\n return value as string;\n } else if (this._yAxisType === YAxisType.NumericAxis) {\n return `${value}`;\n } else {\n return '';\n }\n };\n\n /**\n * This will create a new data set based on the prop\n * @data\n * We will be using This data set to contsruct our rectangles\n * in the chart, we use this data set becuase, when we loop in this\n * data and build the heat map, it will support accessibility as\n * specified in the figma\n */\n\n private _createNewDataSet = (\n data: IHeatMapChartData[],\n xAxisDateFormatString: string | undefined,\n xAxisNumberFormatString: string | undefined,\n yAxisDateFormatString: string | undefined,\n yAxisNumberFormatString: string | undefined,\n ): DataSet => {\n /**\n * please do not destructure any of the props here,\n * instead send them as parameter to this functions so that\n * this functions get called whenever the prop changes\n */\n const flattenData: FlattenData[] = [];\n /**\n * below for each loop will store all the datapoints in the one array.\n * basically it will flatten the nestesd array (data prop) into single array\n * of object. where each object contains x, y, rectText , value and legend propety of single\n * data point.\n */\n data.forEach((item: IHeatMapChartData) => {\n item.data.forEach((point: IHeatMapChartDataPoint) => {\n flattenData.push({ ...point, legend: item.legend });\n });\n });\n const yPoints: RectanglesGraphData = {};\n const uniqueYPoints: { [key: string]: '1' } = {};\n const uniqueXPoints: { [key: string]: '1' } = {};\n flattenData.forEach((item: FlattenData) => {\n const posX = this._getXIndex(item.x);\n const posY = this._getYIndex(item.y);\n\n uniqueXPoints[posX] = '1';\n uniqueYPoints[posY] = '1';\n /** we will check if the property(posY) is already there in object, if Yes,\n * then we will append the item in the Array related to the pos, if not\n * then we will simply append the item in the new Array and\n * assign that array to the property (posY) in the Object\n * and finally we will get the array of Objects associated to each\n * property (which is nothing but y data point) and object in the\n * array are noting but x data points associated to the property y\n */\n if (yPoints[posY]) {\n yPoints[posY] = [...yPoints[posY], item];\n } else {\n yPoints[posY] = [item];\n }\n });\n /**\n * we will now sort(ascending) the array's of y data point based on the x value\n * sorting is important to achive the accessibility order of the\n * rectangles and then format the x and y datapoints respectively\n */\n Object.keys(yPoints).forEach((item: string) => {\n yPoints[item]\n .sort((a: IHeatMapChartDataPoint, b: IHeatMapChartDataPoint) => {\n if (this._xAxisType === XAxisTypes.StringAxis) {\n return (a.x as string).toLowerCase() > (b.x as string).toLowerCase() ? 1 : -1;\n } else if (this._xAxisType === XAxisTypes.DateAxis) {\n return (a.x as Date).getTime() - (b.x as Date).getTime();\n } else if (this._xAxisType === XAxisTypes.NumericAxis) {\n return +(a.x as string) > +(b.x as string) ? 1 : -1;\n } else {\n return a.x > b.x ? 1 : -1;\n }\n })\n .forEach((datapoint: IHeatMapChartDataPoint) => {\n if (this._xAxisType === XAxisTypes.DateAxis) {\n datapoint.x = this._getStringFormattedDate(datapoint.x as string, xAxisDateFormatString);\n }\n if (this._xAxisType === XAxisTypes.NumericAxis) {\n datapoint.x = this._getStringFormattedNumber(datapoint.x as string, xAxisNumberFormatString);\n }\n if (this._xAxisType === XAxisTypes.StringAxis) {\n datapoint.x = this._getFormattedLabelForXAxisDataPoint(datapoint.x as string);\n }\n if (this._yAxisType === YAxisType.DateAxis) {\n datapoint.y = this._getStringFormattedDate(datapoint.y as string, yAxisDateFormatString);\n }\n if (this._yAxisType === YAxisType.NumericAxis) {\n datapoint.y = this._getStringFormattedNumber(datapoint.y as string, yAxisNumberFormatString);\n }\n if (this._yAxisType === YAxisType.StringAxis) {\n datapoint.y = this._getFormattedLabelForYAxisDataPoint(datapoint.y as string);\n }\n });\n });\n /**\n * if y-axis data points are of type date or number or if we have string formatter,\n * then we need to change data points to their respective string\n * format, becuase in the private variable this._stringYAxisDatapoints, points will be stored in\n * string format. and in here `yPoint` are not so we need to change, so that\n * function `this._createRectangles` should work perfetcly while looping, and if we don't change\n * then `this._createRectangles` will fail while looping, causing the error\n * Cannot read property 'forEach' of undefined\n */\n\n Object.keys(yPoints).forEach((yPoint: string) => {\n if (this._yAxisType === YAxisType.DateAxis) {\n yPoints[this._getStringFormattedDate(yPoint, yAxisDateFormatString)] = yPoints[yPoint];\n } else if (this._yAxisType === YAxisType.NumericAxis) {\n yPoints[`${this._getStringFormattedNumber(yPoint, yAxisNumberFormatString)}`] = yPoints[yPoint];\n } else {\n yPoints[this._getFormattedLabelForYAxisDataPoint(yPoint)] = yPoints[yPoint];\n }\n });\n /**\n * assigning new data set\n */\n const dataSet = yPoints;\n /**\n * These are the Y axis data points which will get rendered in the\n * Y axis in graph\n */\n const yAxisPoints = this._getYAxisDataPoints(uniqueYPoints);\n /**\n * These are the x axis data points which will get rendered in the\n * x axis in the graph\n */\n\n const xAxisPoints = this._getXAxisDataPoints(uniqueXPoints);\n return {\n dataSet,\n yAxisPoints,\n xAxisPoints,\n };\n };\n\n /**\n * This function will return the final sorted and formatted x-axis points\n * which will be rendered on the x-axis\n * @param points\n * @returns x-axis points\n */\n private _getXAxisDataPoints = (points: { [key: string]: '1' }): string[] => {\n let xAxisPoints: string[] = [];\n const unFormattedXAxisDataPoints = Object.keys(points).sort((a: string, b: string) => {\n if (this._xAxisType === XAxisTypes.DateAxis || this._xAxisType === XAxisTypes.NumericAxis) {\n return +a - +b;\n } else {\n return a.toLowerCase() > b.toLowerCase() ? 1 : -1;\n }\n });\n xAxisPoints = unFormattedXAxisDataPoints.map((xPoint: string) => {\n if (this._xAxisType === XAxisTypes.DateAxis) {\n return this._getStringFormattedDate(xPoint, this.props.xAxisDateFormatString);\n } else if (this._xAxisType === XAxisTypes.NumericAxis) {\n return this._getStringFormattedNumber(xPoint, this.props.xAxisNumberFormatString);\n } else {\n return this._getFormattedLabelForXAxisDataPoint(xPoint);\n }\n });\n\n return xAxisPoints;\n };\n /**\n * This function will return the final sorted and formatted y-axis points\n * which will be rendered on the y-axis\n * @param points\n * @returns yaxis points\n */\n private _getYAxisDataPoints = (points: { [key: string]: '1' }): string[] => {\n let yAxisPoints: string[] = [];\n const unFormattedYAxisDataPoints = Object.keys(points).sort((a: string, b: string) => {\n if (this._yAxisType === YAxisType.DateAxis || this._yAxisType === YAxisType.NumericAxis) {\n return +a - +b;\n } else {\n return a.toLowerCase() > b.toLowerCase() ? 1 : -1;\n }\n });\n yAxisPoints = unFormattedYAxisDataPoints.map((yPoint: string) => {\n if (this._yAxisType === YAxisType.DateAxis) {\n return this._getStringFormattedDate(yPoint, this.props.yAxisDateFormatString);\n } else if (this._yAxisType === YAxisType.NumericAxis) {\n return this._getStringFormattedNumber(yPoint, this.props.yAxisNumberFormatString);\n } else {\n return this._getFormattedLabelForYAxisDataPoint(yPoint);\n }\n });\n\n return yAxisPoints;\n };\n\n private _getStringFormattedDate = (point: string, formatString?: string): string => {\n const date = new Date();\n date.setTime(+point);\n return d3TimeFormat.timeFormat(formatString || '%b/%d')(date);\n };\n\n private _getStringFormattedNumber = (point: string, formatString?: string): string => {\n return d3Format(formatString || '.2~s')(+point);\n };\n\n private _getFormattedLabelForXAxisDataPoint = (point: string): string => {\n const { xAxisStringFormatter } = this.props;\n return xAxisStringFormatter ? xAxisStringFormatter(point) : point;\n };\n\n private _getFormattedLabelForYAxisDataPoint = (point: string): string => {\n const { yAxisStringFormatter } = this.props;\n return yAxisStringFormatter ? yAxisStringFormatter(point) : point;\n };\n\n private _closeCallout = () => {\n this.setState({\n isCalloutVisible: false,\n });\n };\n\n /**\n * This function checks if the given legend is highlighted or not.\n * A legend can be highlighted in 2 ways:\n * 1. selection: if the user clicks on it\n * 2. hovering: if there is no selected legend and the user hovers over it\n */\n private _legendHighlighted = (legendTitle: string) => {\n return (\n this.state.selectedLegend === legendTitle ||\n (this.state.selectedLegend === '' && this.state.activeLegend === legendTitle)\n );\n };\n\n /**\n * This function checks if none of the legends is selected or hovered.\n */\n private _noLegendHighlighted = () => {\n return this.state.selectedLegend === '' && this.state.activeLegend === '';\n };\n\n private _getAriaLabel = (point: FlattenData): string => {\n const xValue = point.x;\n const yValue = point.y;\n const legend = point.legend;\n const zValue = point.ratio ? `${point.ratio[0]}/${point.ratio[1]}` : point.rectText || point.value;\n const description = point.descriptionMessage;\n return (\n point.callOutAccessibilityData?.ariaLabel ||\n `${xValue}, ${yValue}. ${legend}, ${zValue}.` + (description ? ` ${description}.` : '')\n );\n };\n}\n"]}
1
+ {"version":3,"file":"HeatMapChart.base.js","sourceRoot":"../src/","sources":["components/HeatMapChart/HeatMapChart.base.tsx"],"names":[],"mappings":";;;;IAyFA,IAAM,aAAa,GAAG,IAAA,8BAAkB,GAAgD,CAAC;IACzF;QAAsC,iDAAuD;QA0B3F,0BAAmB,KAAyB;YAA5C,YACE,kBAAM,KAAK,CAAC,SAgCb;YAzCD;;;eAGG;YACK,mBAAa,GAAgC,EAAE,CAAC;YA2GhD,eAAS,GAAG;gBAClB,IAAI,CAAC,GAA2B,EAAE,CAAC;gBACnC,IAAI,CAAC,GAA2B,EAAE,CAAC;gBACnC,KAAI,CAAC,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,UAAC,IAAuB;oBAC9C,IAAI,IAAI,CAAC,IAAI,IAAI,IAAI,CAAC,IAAI,CAAC,MAAM,GAAG,CAAC,EAAE;wBACrC,CAAC,GAAG,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;wBACnB,CAAC,GAAG,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;wBACnB,OAAO,EAAE,CAAC,GAAA,EAAE,CAAC,GAAA,EAAE,CAAC;qBACjB;gBACH,CAAC,CAAC,CAAC;gBACH,OAAO,EAAE,CAAC,GAAA,EAAE,CAAC,GAAA,EAAE,CAAC;YAClB,CAAC,CAAC;YAEM,iBAAW,GAAG,UAAC,WAAmB;gBACxC,IAAM,OAAO,GAAG,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2BAA2B,EAAE,IAAI,CAAC,sBAAsB,EACxD,cAAc,EAAE,IAAI,CAAC,sBAAsB,CAAC,MAAM,EAClD,aAAa,EAAE,CAAC,EAChB,YAAY,EAAE,IAAI,EAClB,YAAY,EAAE,IAAI,EAClB,iBAAiB,EAAE;oBACjB,SAAS,EAAE,gCAAkB,CAAC,aAAa;iBAC5C,EACD,UAAU,EAAE,IAAI,CAAC,iBAAiB,EAAE,EACpC,iBAAiB,EAAE,IAAI,CAAC,sBAAsB;gBAC9C,sCAAsC;gBACtC,kDAAkD;gBAClD,QAAQ,EAAE,UAAC,KAAkB;oBAC3B,KAAI,CAAC,WAAW,GAAG,KAAK,CAAC,MAAM,CAAC;oBAChC,KAAI,CAAC,WAAW,GAAG,KAAK,CAAC,MAAM,CAAC;oBAChC,OAAO,KAAI,CAAC,iBAAiB,EAAE,CAAC;gBAClC,CAAC,IACD,CACH,CAAC;QACJ,CAAC;QAqdH,uBAAC;IAAD,CAAC,AAplBD,CAAsC,KAAK,CAAC,SAAS,GAolBpD;IAplBY,4CAAgB","sourcesContent":["import {\n IAccessibilityProps,\n CartesianChart,\n IChildProps,\n IModifiedCartesianChartProps,\n IHeatMapChartData,\n IHeatMapChartDataPoint,\n} from '../../index';\nimport { scaleLinear as d3ScaleLinear } from 'd3-scale';\nimport { classNamesFunction, memoizeFunction } from '@fluentui/react/lib/Utilities';\nimport { FocusZoneDirection } from '@fluentui/react-focus';\nimport { DirectionalHint } from '@fluentui/react/lib/Callout';\nimport { IProcessedStyleSet } from '@fluentui/react/lib/Styling';\nimport * as React from 'react';\nimport { IHeatMapChartProps, IHeatMapChartStyleProps, IHeatMapChartStyles } from './HeatMapChart.types';\nimport { ILegend, Legends } from '../Legends/index';\nimport {\n ChartTypes,\n convertToLocaleString,\n getAccessibleDataObject,\n XAxisTypes,\n YAxisType,\n getTypeOfAxis,\n} from '../../utilities/utilities';\nimport { Target } from '@fluentui/react';\nimport { format as d3Format } from 'd3-format';\nimport * as d3TimeFormat from 'd3-time-format';\n\ntype DataSet = {\n dataSet: RectanglesGraphData;\n yAxisPoints: string[];\n xAxisPoints: string[];\n};\ntype FlattenData = IHeatMapChartDataPoint & {\n legend: string;\n};\ninterface IRectRef {\n data: FlattenData;\n refElement: SVGGElement;\n}\ntype RectanglesGraphData = { [key: string]: FlattenData[] };\nexport interface IHeatMapChartState {\n /**\n * contains the selected legend string\n */\n selectedLegend: string;\n /**\n * contains the hovered legend string\n */\n activeLegend: string;\n /**\n * determines wethere to show or hide the callout\n * @default false\n */\n isCalloutVisible: boolean;\n /**\n * y value to be shown in callout\n */\n calloutYValue: string;\n /**\n * legend title to be shown in callout\n */\n calloutLegend: string;\n /**\n * color of the text in the callout\n */\n calloutTextColor: string;\n /**\n * The target that the Callout should try to position itself based on\n */\n target: Target;\n /**\n * ratio to show in the callout\n */\n ratio: [number, number] | null;\n\n /**\n * description message to show in the callout\n */\n descriptionMessage: string;\n /**\n * id to give to callout for accesiblity purpose\n */\n calloutId: string;\n /**\n * Accessibility data for callout\n */\n callOutAccessibilityData?: IAccessibilityProps;\n}\nconst getClassNames = classNamesFunction<IHeatMapChartStyleProps, IHeatMapChartStyles>();\nexport class HeatMapChartBase extends React.Component<IHeatMapChartProps, IHeatMapChartState> {\n private _classNames: IProcessedStyleSet<IHeatMapChartStyles>;\n private _stringXAxisDataPoints: string[];\n private _stringYAxisDataPoints: string[];\n private _createSet: (\n data: IHeatMapChartData[],\n xDate: string | undefined,\n xNum: string | undefined,\n yDate: string | undefined,\n yNum: string | undefined,\n ) => DataSet;\n private _dataSet: RectanglesGraphData;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n private _colorScale: any;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n private _xAxisScale: any;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n private _yAxisScale: any;\n /**\n * This array contains ref for all the rectangles\n * drawn inside the chard\n */\n private _rectRefArray: { [key: string]: IRectRef } = {};\n private _xAxisType: XAxisTypes;\n private _yAxisType: YAxisType;\n private _calloutAnchorPoint: FlattenData | null;\n public constructor(props: IHeatMapChartProps) {\n super(props);\n const { x, y } = this._getXandY();\n this._xAxisType = getTypeOfAxis(x, true) as XAxisTypes;\n this._yAxisType = getTypeOfAxis(y, false) as YAxisType;\n /**\n * below funciton creates a new data set from the prop\n * @data and also finds all the unique x-axis datapoints\n * and y-axis datapoints(which will render in the axis in graph)\n * we store this in a memoized function, because we want to calulate\n * this set whenever props changes.\n */\n this._createSet = memoizeFunction(\n (\n data: IHeatMapChartData[],\n xDate: string | undefined,\n xNum: string | undefined,\n yDate: string | undefined,\n yNum: string | undefined,\n ): DataSet => this._createNewDataSet(data, xDate, xNum, yDate, yNum),\n );\n this.state = {\n selectedLegend: '',\n activeLegend: '',\n isCalloutVisible: false,\n target: null,\n calloutLegend: '',\n calloutTextColor: '',\n calloutYValue: '',\n ratio: null,\n descriptionMessage: '',\n calloutId: '',\n };\n }\n public render(): React.ReactNode {\n const { data, xAxisDateFormatString, xAxisNumberFormatString, yAxisDateFormatString, yAxisNumberFormatString } =\n this.props;\n this._colorScale = this._getColorScale();\n const { dataSet, xAxisPoints, yAxisPoints } = this._createSet(\n data,\n xAxisDateFormatString,\n xAxisNumberFormatString,\n yAxisDateFormatString,\n yAxisNumberFormatString,\n );\n this._dataSet = dataSet;\n this._stringYAxisDataPoints = yAxisPoints;\n this._stringXAxisDataPoints = xAxisPoints;\n this._classNames = getClassNames(this.props.styles!, { theme: this.props.theme! });\n const calloutProps: IModifiedCartesianChartProps['calloutProps'] = {\n isBeakVisible: false,\n gapSpace: 8,\n ...this.props.calloutProps,\n isCalloutVisible: this.state.isCalloutVisible,\n id: this.state.calloutId,\n YValue: this.state.calloutYValue,\n legend: this.state.calloutLegend,\n color: this.state.calloutTextColor,\n target: this.state.target,\n styles: this._classNames.subComponentStyles.calloutStyles,\n directionalHint: DirectionalHint.topAutoEdge,\n onDismiss: this._closeCallout,\n ...getAccessibleDataObject(this.state.callOutAccessibilityData, 'text', false),\n preventDismissOnLostFocus: true,\n };\n const chartHoverProps: IModifiedCartesianChartProps['chartHoverProps'] = {\n ...(this.state.ratio && {\n ratio: this.state.ratio,\n }),\n descriptionMessage: this.state.descriptionMessage,\n };\n return (\n <CartesianChart\n {...this.props}\n points={data}\n chartType={ChartTypes.HeatMapChart}\n xAxisType={XAxisTypes.StringAxis}\n yAxisType={YAxisType.StringAxis}\n calloutProps={calloutProps}\n chartHoverProps={chartHoverProps}\n styles={this._classNames.subComponentStyles!.cartesianStyles}\n datasetForXAxisDomain={this._stringXAxisDataPoints}\n stringDatasetForYAxisDomain={this._stringYAxisDataPoints}\n xAxisTickCount={this._stringXAxisDataPoints.length}\n xAxistickSize={0}\n xAxisPadding={0.02}\n yAxisPadding={0.02}\n svgFocusZoneProps={{\n direction: FocusZoneDirection.bidirectional,\n }}\n legendBars={this._createLegendBars()}\n onChartMouseLeave={this._handleChartMouseLeave}\n /* eslint-disable react/jsx-no-bind */\n // eslint-disable-next-line react/no-children-prop\n children={(props: IChildProps) => {\n this._xAxisScale = props.xScale;\n this._yAxisScale = props.yScale;\n return this._createRectangles();\n }}\n />\n );\n }\n\n private _getXandY = (): { x: string | Date | number; y: string | Date | number } => {\n let x: string | Date | number = '';\n let y: string | Date | number = '';\n this.props.data.forEach((item: IHeatMapChartData) => {\n if (item.data && item.data.length > 0) {\n x = item.data[0].x;\n y = item.data[0].y;\n return { x, y };\n }\n });\n return { x, y };\n };\n\n private _getOpacity = (legendTitle: string): string => {\n const opacity = this._legendHighlighted(legendTitle) || this._noLegendHighlighted() ? '1' : '0.1';\n return opacity;\n };\n\n private _rectRefCallback = (rectElement: SVGGElement, index: number | string, dataPointObject: FlattenData): void => {\n this._rectRefArray[index] = { data: dataPointObject, refElement: rectElement };\n };\n\n private _onRectFocus = (id: string, data: FlattenData): void => {\n this.setState({\n target: this._rectRefArray[id].refElement,\n /** Show the callout if highlighted rectangle is focused and Hide it if unhighlighted rectangle is focused */\n isCalloutVisible: this.state.selectedLegend === '' || this.state.selectedLegend === data.legend,\n calloutYValue: `${data.rectText}`,\n calloutTextColor: this._colorScale(data.value),\n calloutLegend: data.legend,\n ratio: data.ratio || null,\n descriptionMessage: data.descriptionMessage || '',\n calloutId: id,\n callOutAccessibilityData: data.callOutAccessibilityData,\n });\n };\n\n private _onRectMouseOver = (id: string, data: FlattenData, mouseEvent: React.MouseEvent<SVGGElement>): void => {\n mouseEvent.persist();\n if (this._calloutAnchorPoint !== data) {\n this._calloutAnchorPoint = data;\n this.setState({\n target: this._rectRefArray[id].refElement,\n /** Show the callout if highlighted rectangle is hovered and Hide it if unhighlighted rectangle is hovered */\n isCalloutVisible: this.state.selectedLegend === '' || this.state.selectedLegend === data.legend,\n calloutYValue: `${data.rectText}`,\n calloutTextColor: this._colorScale(data.value),\n calloutLegend: data.legend,\n ratio: data.ratio || null,\n descriptionMessage: data.descriptionMessage || '',\n calloutId: id,\n callOutAccessibilityData: data.callOutAccessibilityData,\n });\n }\n };\n\n private _onRectBlurOrMouseOut = (): void => {\n /**/\n };\n\n private _handleChartMouseLeave = (): void => {\n this._calloutAnchorPoint = null;\n this.setState({\n isCalloutVisible: false,\n });\n };\n\n /**\n * This is the function which is responsible for\n * drawing the rectangle in the graph and also\n * attaching dom events to that rectangles\n */\n private _createRectangles = (): React.ReactNode => {\n const rectangles: JSX.Element[] = [];\n const yAxisDataPoints = this._stringYAxisDataPoints.slice().reverse();\n /**\n * yAxisDataPoint is noting but the DataPoint\n * which will be rendered on the y-axis\n */\n yAxisDataPoints.forEach((yAxisDataPoint: string, index1: number) => {\n /**\n * dataPointObject is an object where it contains information on single\n * data point such as x, y , value, rectText property of the rectangle\n */\n this._dataSet[yAxisDataPoint].forEach((dataPointObject: FlattenData, index2: number) => {\n const id = `${index1}${index2}`;\n const rectElement: JSX.Element = (\n <g\n key={id}\n role=\"img\"\n aria-label={this._getAriaLabel(dataPointObject)}\n data-is-focusable={true}\n fillOpacity={this._getOpacity(dataPointObject.legend)}\n transform={`translate(${this._xAxisScale(dataPointObject.x)}, ${this._yAxisScale(dataPointObject.y)})`}\n ref={(gElement: SVGGElement) => {\n this._rectRefCallback(gElement, id, dataPointObject);\n }}\n onFocus={this._onRectFocus.bind(this, id, dataPointObject)}\n onBlur={this._onRectBlurOrMouseOut}\n onMouseOver={this._onRectMouseOver.bind(this, id, dataPointObject)}\n onMouseOut={this._onRectBlurOrMouseOut}\n >\n <rect\n fill={this._colorScale(dataPointObject.value)}\n width={this._xAxisScale.bandwidth()}\n height={this._yAxisScale.bandwidth()}\n onClick={dataPointObject.onClick}\n />\n <text\n dominantBaseline={'middle'}\n textAnchor={'middle'}\n className={this._classNames.text}\n transform={`translate(${this._xAxisScale.bandwidth() / 2}, ${this._yAxisScale.bandwidth() / 2})`}\n >\n {convertToLocaleString(dataPointObject.rectText, this.props.culture)}\n </text>\n </g>\n );\n rectangles.push(rectElement);\n });\n });\n return rectangles;\n };\n /**\n * when the legend is hovered we need to highlight\n * all the rectangles which fall under that category\n * and un-highlight the rest of them\n * @param legendTitle\n */\n private _onLegendHover = (legendTitle: string): void => {\n this.setState({\n activeLegend: legendTitle,\n });\n };\n\n /**\n * when the mouse is out from the legend , we need\n * to show the graph in initial mode.\n */\n private _onLegendLeave = (): void => {\n this.setState({\n activeLegend: '',\n });\n };\n /**\n * @param legendTitle\n * when the legend is clicked we need to highlight\n * all the rectangles which fall under that category\n * and un highlight the rest of them\n */\n private _onLegendClick = (legendTitle: string): void => {\n /**\n * check if the legend is already selceted,\n * if yes, un-select the legend, else\n * set the selected legend state to legendTitle\n */\n if (this.state.selectedLegend === legendTitle) {\n this.setState({\n selectedLegend: '',\n });\n } else {\n this.setState({\n selectedLegend: legendTitle,\n });\n }\n };\n private _createLegendBars = (): JSX.Element => {\n const { data, legendProps } = this.props;\n const legends: ILegend[] = [];\n data.forEach((item: IHeatMapChartData) => {\n const legend: ILegend = {\n title: item.legend,\n color: this._colorScale(item.value),\n action: () => {\n this._onLegendClick(item.legend);\n },\n hoverAction: () => {\n this._handleChartMouseLeave();\n this._onLegendHover(item.legend);\n },\n onMouseOutAction: () => {\n this._onLegendLeave();\n },\n };\n legends.push(legend);\n });\n return <Legends {...legendProps} legends={legends} />;\n };\n\n private _getColorScale = () => {\n const { domainValuesForColorScale, rangeValuesForColorScale } = this.props;\n return d3ScaleLinear()\n .domain(domainValuesForColorScale)\n .range(rangeValuesForColorScale as unknown as number[]);\n };\n\n private _getXIndex = (value: string | Date | number): string => {\n if (this._xAxisType === XAxisTypes.DateAxis) {\n return `${(value as Date).getTime()}`;\n } else if (this._xAxisType === XAxisTypes.StringAxis) {\n return value as string;\n } else if (this._xAxisType === XAxisTypes.NumericAxis) {\n return `${value}`;\n } else {\n return '';\n }\n };\n private _getYIndex = (value: string | Date | number): string => {\n if (this._yAxisType === YAxisType.DateAxis) {\n return `${(value as Date).getTime()}`;\n } else if (this._yAxisType === YAxisType.StringAxis) {\n return value as string;\n } else if (this._yAxisType === YAxisType.NumericAxis) {\n return `${value}`;\n } else {\n return '';\n }\n };\n\n /**\n * This will create a new data set based on the prop\n * @data\n * We will be using This data set to contsruct our rectangles\n * in the chart, we use this data set becuase, when we loop in this\n * data and build the heat map, it will support accessibility as\n * specified in the figma\n */\n\n private _createNewDataSet = (\n data: IHeatMapChartData[],\n xAxisDateFormatString: string | undefined,\n xAxisNumberFormatString: string | undefined,\n yAxisDateFormatString: string | undefined,\n yAxisNumberFormatString: string | undefined,\n ): DataSet => {\n /**\n * please do not destructure any of the props here,\n * instead send them as parameter to this functions so that\n * this functions get called whenever the prop changes\n */\n const flattenData: FlattenData[] = [];\n /**\n * below for each loop will store all the datapoints in the one array.\n * basically it will flatten the nestesd array (data prop) into single array\n * of object. where each object contains x, y, rectText , value and legend propety of single\n * data point.\n */\n data.forEach((item: IHeatMapChartData) => {\n item.data.forEach((point: IHeatMapChartDataPoint) => {\n flattenData.push({ ...point, legend: item.legend });\n });\n });\n const yPoints: RectanglesGraphData = {};\n const uniqueYPoints: { [key: string]: '1' } = {};\n const uniqueXPoints: { [key: string]: '1' } = {};\n flattenData.forEach((item: FlattenData) => {\n const posX = this._getXIndex(item.x);\n const posY = this._getYIndex(item.y);\n\n uniqueXPoints[posX] = '1';\n uniqueYPoints[posY] = '1';\n /** we will check if the property(posY) is already there in object, if Yes,\n * then we will append the item in the Array related to the pos, if not\n * then we will simply append the item in the new Array and\n * assign that array to the property (posY) in the Object\n * and finally we will get the array of Objects associated to each\n * property (which is nothing but y data point) and object in the\n * array are noting but x data points associated to the property y\n */\n if (yPoints[posY]) {\n yPoints[posY] = [...yPoints[posY], item];\n } else {\n yPoints[posY] = [item];\n }\n });\n /**\n * we will now sort(ascending) the array's of y data point based on the x value\n * sorting is important to achive the accessibility order of the\n * rectangles and then format the x and y datapoints respectively\n */\n Object.keys(yPoints).forEach((item: string) => {\n yPoints[item]\n .sort((a: IHeatMapChartDataPoint, b: IHeatMapChartDataPoint) => {\n if (this._xAxisType === XAxisTypes.StringAxis) {\n return (a.x as string).toLowerCase() > (b.x as string).toLowerCase() ? 1 : -1;\n } else if (this._xAxisType === XAxisTypes.DateAxis) {\n return (a.x as Date).getTime() - (b.x as Date).getTime();\n } else if (this._xAxisType === XAxisTypes.NumericAxis) {\n return +(a.x as string) > +(b.x as string) ? 1 : -1;\n } else {\n return a.x > b.x ? 1 : -1;\n }\n })\n .forEach((datapoint: IHeatMapChartDataPoint) => {\n if (this._xAxisType === XAxisTypes.DateAxis) {\n datapoint.x = this._getStringFormattedDate(datapoint.x as string, xAxisDateFormatString);\n }\n if (this._xAxisType === XAxisTypes.NumericAxis) {\n datapoint.x = this._getStringFormattedNumber(datapoint.x as string, xAxisNumberFormatString);\n }\n if (this._xAxisType === XAxisTypes.StringAxis) {\n datapoint.x = this._getFormattedLabelForXAxisDataPoint(datapoint.x as string);\n }\n if (this._yAxisType === YAxisType.DateAxis) {\n datapoint.y = this._getStringFormattedDate(datapoint.y as string, yAxisDateFormatString);\n }\n if (this._yAxisType === YAxisType.NumericAxis) {\n datapoint.y = this._getStringFormattedNumber(datapoint.y as string, yAxisNumberFormatString);\n }\n if (this._yAxisType === YAxisType.StringAxis) {\n datapoint.y = this._getFormattedLabelForYAxisDataPoint(datapoint.y as string);\n }\n });\n });\n /**\n * if y-axis data points are of type date or number or if we have string formatter,\n * then we need to change data points to their respective string\n * format, becuase in the private variable this._stringYAxisDatapoints, points will be stored in\n * string format. and in here `yPoint` are not so we need to change, so that\n * function `this._createRectangles` should work perfetcly while looping, and if we don't change\n * then `this._createRectangles` will fail while looping, causing the error\n * Cannot read property 'forEach' of undefined\n */\n\n Object.keys(yPoints).forEach((yPoint: string) => {\n if (this._yAxisType === YAxisType.DateAxis) {\n yPoints[this._getStringFormattedDate(yPoint, yAxisDateFormatString)] = yPoints[yPoint];\n } else if (this._yAxisType === YAxisType.NumericAxis) {\n yPoints[`${this._getStringFormattedNumber(yPoint, yAxisNumberFormatString)}`] = yPoints[yPoint];\n } else {\n yPoints[this._getFormattedLabelForYAxisDataPoint(yPoint)] = yPoints[yPoint];\n }\n });\n /**\n * assigning new data set\n */\n const dataSet = yPoints;\n /**\n * These are the Y axis data points which will get rendered in the\n * Y axis in graph\n */\n const yAxisPoints = this._getYAxisDataPoints(uniqueYPoints);\n /**\n * These are the x axis data points which will get rendered in the\n * x axis in the graph\n */\n\n const xAxisPoints = this._getXAxisDataPoints(uniqueXPoints);\n return {\n dataSet,\n yAxisPoints,\n xAxisPoints,\n };\n };\n\n /**\n * This function will return the final sorted and formatted x-axis points\n * which will be rendered on the x-axis\n * @param points\n * @returns x-axis points\n */\n private _getXAxisDataPoints = (points: { [key: string]: '1' }): string[] => {\n let xAxisPoints: string[] = [];\n const unFormattedXAxisDataPoints = Object.keys(points).sort((a: string, b: string) => {\n if (this._xAxisType === XAxisTypes.DateAxis || this._xAxisType === XAxisTypes.NumericAxis) {\n return +a - +b;\n } else {\n return a.toLowerCase() > b.toLowerCase() ? 1 : -1;\n }\n });\n xAxisPoints = unFormattedXAxisDataPoints.map((xPoint: string) => {\n if (this._xAxisType === XAxisTypes.DateAxis) {\n return this._getStringFormattedDate(xPoint, this.props.xAxisDateFormatString);\n } else if (this._xAxisType === XAxisTypes.NumericAxis) {\n return this._getStringFormattedNumber(xPoint, this.props.xAxisNumberFormatString);\n } else {\n return this._getFormattedLabelForXAxisDataPoint(xPoint);\n }\n });\n\n return xAxisPoints;\n };\n /**\n * This function will return the final sorted and formatted y-axis points\n * which will be rendered on the y-axis\n * @param points\n * @returns yaxis points\n */\n private _getYAxisDataPoints = (points: { [key: string]: '1' }): string[] => {\n let yAxisPoints: string[] = [];\n const unFormattedYAxisDataPoints = Object.keys(points).sort((a: string, b: string) => {\n if (this._yAxisType === YAxisType.DateAxis || this._yAxisType === YAxisType.NumericAxis) {\n return +a - +b;\n } else {\n return a.toLowerCase() > b.toLowerCase() ? 1 : -1;\n }\n });\n yAxisPoints = unFormattedYAxisDataPoints.map((yPoint: string) => {\n if (this._yAxisType === YAxisType.DateAxis) {\n return this._getStringFormattedDate(yPoint, this.props.yAxisDateFormatString);\n } else if (this._yAxisType === YAxisType.NumericAxis) {\n return this._getStringFormattedNumber(yPoint, this.props.yAxisNumberFormatString);\n } else {\n return this._getFormattedLabelForYAxisDataPoint(yPoint);\n }\n });\n\n return yAxisPoints;\n };\n\n private _getStringFormattedDate = (point: string, formatString?: string): string => {\n const date = new Date();\n date.setTime(+point);\n return d3TimeFormat.timeFormat(formatString || '%b/%d')(date);\n };\n\n private _getStringFormattedNumber = (point: string, formatString?: string): string => {\n return d3Format(formatString || '.2~s')(+point);\n };\n\n private _getFormattedLabelForXAxisDataPoint = (point: string): string => {\n const { xAxisStringFormatter } = this.props;\n return xAxisStringFormatter ? xAxisStringFormatter(point) : point;\n };\n\n private _getFormattedLabelForYAxisDataPoint = (point: string): string => {\n const { yAxisStringFormatter } = this.props;\n return yAxisStringFormatter ? yAxisStringFormatter(point) : point;\n };\n\n private _closeCallout = () => {\n this.setState({\n isCalloutVisible: false,\n });\n };\n\n /**\n * This function checks if the given legend is highlighted or not.\n * A legend can be highlighted in 2 ways:\n * 1. selection: if the user clicks on it\n * 2. hovering: if there is no selected legend and the user hovers over it\n */\n private _legendHighlighted = (legendTitle: string) => {\n return (\n this.state.selectedLegend === legendTitle ||\n (this.state.selectedLegend === '' && this.state.activeLegend === legendTitle)\n );\n };\n\n /**\n * This function checks if none of the legends is selected or hovered.\n */\n private _noLegendHighlighted = () => {\n return this.state.selectedLegend === '' && this.state.activeLegend === '';\n };\n\n private _getAriaLabel = (point: FlattenData): string => {\n const xValue = point.x;\n const yValue = point.y;\n const legend = point.legend;\n const zValue = point.ratio ? `${point.ratio[0]}/${point.ratio[1]}` : point.rectText || point.value;\n const description = point.descriptionMessage;\n return (\n point.callOutAccessibilityData?.ariaLabel ||\n `${xValue}, ${yValue}. ${legend}, ${zValue}.` + (description ? ` ${description}.` : '')\n );\n };\n}\n"]}
@@ -2,6 +2,6 @@ define(["require", "exports", "@fluentui/react/lib/Utilities", "./HeatMapChart.s
2
2
  "use strict";
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  exports.HeatMapChart = void 0;
5
- exports.HeatMapChart = Utilities_1.styled(HeatMapChart_base_1.HeatMapChartBase, HeatMapChart_styles_1.getHeatMapChartStyles);
5
+ exports.HeatMapChart = (0, Utilities_1.styled)(HeatMapChart_base_1.HeatMapChartBase, HeatMapChart_styles_1.getHeatMapChartStyles);
6
6
  });
7
7
  //# sourceMappingURL=HeatMapChart.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"HeatMapChart.js","sourceRoot":"../src/","sources":["components/HeatMapChart/HeatMapChart.ts"],"names":[],"mappings":";;;;IAMa,QAAA,YAAY,GAAgD,kBAAM,CAI7E,oCAAgB,EAAE,2CAAqB,CAAC,CAAC","sourcesContent":["import * as React from 'react';\nimport { styled } from '@fluentui/react/lib/Utilities';\nimport { IHeatMapChartProps, IHeatMapChartStyleProps, IHeatMapChartStyles } from './HeatMapChart.types';\nimport { getHeatMapChartStyles } from './HeatMapChart.styles';\nimport { HeatMapChartBase } from './HeatMapChart.base';\n\nexport const HeatMapChart: React.FunctionComponent<IHeatMapChartProps> = styled<\n IHeatMapChartProps,\n IHeatMapChartStyleProps,\n IHeatMapChartStyles\n>(HeatMapChartBase, getHeatMapChartStyles);\n"]}
1
+ {"version":3,"file":"HeatMapChart.js","sourceRoot":"../src/","sources":["components/HeatMapChart/HeatMapChart.ts"],"names":[],"mappings":";;;;IAMa,QAAA,YAAY,GAAgD,IAAA,kBAAM,EAI7E,oCAAgB,EAAE,2CAAqB,CAAC,CAAC","sourcesContent":["import * as React from 'react';\nimport { styled } from '@fluentui/react/lib/Utilities';\nimport { IHeatMapChartProps, IHeatMapChartStyleProps, IHeatMapChartStyles } from './HeatMapChart.types';\nimport { getHeatMapChartStyles } from './HeatMapChart.styles';\nimport { HeatMapChartBase } from './HeatMapChart.base';\n\nexport const HeatMapChart: React.FunctionComponent<IHeatMapChartProps> = styled<\n IHeatMapChartProps,\n IHeatMapChartStyleProps,\n IHeatMapChartStyles\n>(HeatMapChartBase, getHeatMapChartStyles);\n"]}
@@ -1,7 +1,7 @@
1
1
  define(["require", "exports", "tslib", "./HeatMapChart", "./HeatMapChart.types"], function (require, exports, tslib_1, HeatMapChart_1, HeatMapChart_types_1) {
2
2
  "use strict";
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
- tslib_1.__exportStar(HeatMapChart_1, exports);
5
- tslib_1.__exportStar(HeatMapChart_types_1, exports);
4
+ (0, tslib_1.__exportStar)(HeatMapChart_1, exports);
5
+ (0, tslib_1.__exportStar)(HeatMapChart_types_1, exports);
6
6
  });
7
7
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"../src/","sources":["components/HeatMapChart/index.ts"],"names":[],"mappings":";;;IAAA,8CAA+B;IAC/B,oDAAqC","sourcesContent":["export * from './HeatMapChart';\nexport * from './HeatMapChart.types';\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"../src/","sources":["components/HeatMapChart/index.ts"],"names":[],"mappings":";;;IAAA,mDAA+B;IAC/B,yDAAqC","sourcesContent":["export * from './HeatMapChart';\nexport * from './HeatMapChart.types';\n"]}
@@ -2,12 +2,12 @@ define(["require", "exports", "tslib", "react", "@fluentui/react/lib/Utilities",
2
2
  "use strict";
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  exports.HorizontalBarChartBase = void 0;
5
- var getClassNames = Utilities_1.classNamesFunction();
5
+ var getClassNames = (0, Utilities_1.classNamesFunction)();
6
6
  var HorizontalBarChartBase = /** @class */ (function (_super) {
7
- tslib_1.__extends(HorizontalBarChartBase, _super);
7
+ (0, tslib_1.__extends)(HorizontalBarChartBase, _super);
8
8
  function HorizontalBarChartBase(props) {
9
9
  var _this = _super.call(this, props) || this;
10
- _this._isRTL = Utilities_1.getRTL();
10
+ _this._isRTL = (0, Utilities_1.getRTL)();
11
11
  _this._handleChartMouseLeave = function () {
12
12
  _this._calloutAnchorPoint = null;
13
13
  if (_this.state.isCalloutVisible) {
@@ -44,8 +44,8 @@ define(["require", "exports", "tslib", "react", "@fluentui/react/lib/Utilities",
44
44
  var _a;
45
45
  var legend = point.xAxisCalloutData || point.legend;
46
46
  var yValue = point.yAxisCalloutData ||
47
- (point.horizontalBarChartdata ? point.horizontalBarChartdata.x + "/" + point.horizontalBarChartdata.y : 0);
48
- return ((_a = point.callOutAccessibilityData) === null || _a === void 0 ? void 0 : _a.ariaLabel) || (legend ? legend + ", " : '') + (yValue + ".");
47
+ (point.horizontalBarChartdata ? "".concat(point.horizontalBarChartdata.x, "/").concat(point.horizontalBarChartdata.y) : 0);
48
+ return ((_a = point.callOutAccessibilityData) === null || _a === void 0 ? void 0 : _a.ariaLabel) || (legend ? "".concat(legend, ", ") : '') + "".concat(yValue, ".");
49
49
  };
50
50
  _this.state = {
51
51
  isCalloutVisible: false,
@@ -61,7 +61,7 @@ define(["require", "exports", "tslib", "react", "@fluentui/react/lib/Utilities",
61
61
  _this._refArray = [];
62
62
  _this._uniqLineText = '_HorizontalLine_' + Math.random().toString(36).substring(7);
63
63
  _this._hoverOff = _this._hoverOff.bind(_this);
64
- _this._calloutId = Utilities_1.getId('callout');
64
+ _this._calloutId = (0, Utilities_1.getId)('callout');
65
65
  return _this;
66
66
  }
67
67
  HorizontalBarChartBase.prototype.render = function () {
@@ -116,7 +116,7 @@ define(["require", "exports", "tslib", "react", "@fluentui/react/lib/Utilities",
116
116
  }
117
117
  } }, bars))))));
118
118
  }),
119
- React.createElement(Callout_1.Callout, tslib_1.__assign({ target: this.state.refSelected, coverTarget: true, isBeakVisible: false, gapSpace: 30, hidden: !(!this.props.hideTooltip && this.state.isCalloutVisible), directionalHint: Callout_1.DirectionalHint.topAutoEdge, id: this._calloutId, onDismiss: this._closeCallout, preventDismissOnLostFocus: true }, this.props.calloutProps, index_2.getAccessibleDataObject(this.state.callOutAccessibilityData)),
119
+ React.createElement(Callout_1.Callout, (0, tslib_1.__assign)({ target: this.state.refSelected, coverTarget: true, isBeakVisible: false, gapSpace: 30, hidden: !(!this.props.hideTooltip && this.state.isCalloutVisible), directionalHint: Callout_1.DirectionalHint.topAutoEdge, id: this._calloutId, onDismiss: this._closeCallout, preventDismissOnLostFocus: true }, this.props.calloutProps, (0, index_2.getAccessibleDataObject)(this.state.callOutAccessibilityData)),
120
120
  React.createElement(React.Fragment, null, this.props.onRenderCalloutPerHorizontalBar ? (this.props.onRenderCalloutPerHorizontalBar(this.state.barCalloutProps)) : (React.createElement(index_2.ChartHoverCard, { Legend: this.state.xCalloutValue ? this.state.xCalloutValue : this.state.legend, YValue: this.state.yCalloutValue ? this.state.yCalloutValue : this.state.hoverValue, color: this.state.lineColor, culture: this.props.culture }))))));
121
121
  };
122
122
  HorizontalBarChartBase.prototype._refCallback = function (element, legendTitle) {
@@ -124,7 +124,7 @@ define(["require", "exports", "tslib", "react", "@fluentui/react/lib/Utilities",
124
124
  };
125
125
  HorizontalBarChartBase.prototype._hoverOn = function (hoverValue, point) {
126
126
  if ((!this.state.isCalloutVisible || this.state.legend !== point.legend) && this._calloutAnchorPoint !== point) {
127
- var currentHoveredElement = Utilities_1.find(this._refArray, function (currentElement) { return currentElement.index === point.legend; });
127
+ var currentHoveredElement = (0, Utilities_1.find)(this._refArray, function (currentElement) { return currentElement.index === point.legend; });
128
128
  this._calloutAnchorPoint = point;
129
129
  this.setState({
130
130
  isCalloutVisible: true,
@@ -148,17 +148,17 @@ define(["require", "exports", "tslib", "react", "@fluentui/react/lib/Utilities",
148
148
  var chartData = data.chartData[0];
149
149
  var x = chartData.horizontalBarChartdata.x;
150
150
  var y = chartData.horizontalBarChartdata.y;
151
- var accessibilityData = index_2.getAccessibleDataObject(data.chartDataAccessibilityData, 'text', false);
151
+ var accessibilityData = (0, index_2.getAccessibleDataObject)(data.chartDataAccessibilityData, 'text', false);
152
152
  switch (chartDataMode) {
153
153
  case 'default':
154
- return (React.createElement("div", tslib_1.__assign({ className: this._classNames.chartTitleRight }, accessibilityData), index_2.convertToLocaleString(x, culture)));
154
+ return (React.createElement("div", (0, tslib_1.__assign)({ className: this._classNames.chartTitleRight }, accessibilityData), (0, index_2.convertToLocaleString)(x, culture)));
155
155
  case 'fraction':
156
- return (React.createElement("div", tslib_1.__assign({}, accessibilityData),
157
- React.createElement("span", { className: this._classNames.chartTitleRight }, index_2.convertToLocaleString(x, culture)),
158
- React.createElement("span", { className: this._classNames.chartDataTextDenominator }, ' / ' + index_2.convertToLocaleString(y, culture))));
156
+ return (React.createElement("div", (0, tslib_1.__assign)({}, accessibilityData),
157
+ React.createElement("span", { className: this._classNames.chartTitleRight }, (0, index_2.convertToLocaleString)(x, culture)),
158
+ React.createElement("span", { className: this._classNames.chartDataTextDenominator }, ' / ' + (0, index_2.convertToLocaleString)(y, culture))));
159
159
  case 'percentage':
160
- var dataRatioPercentage = index_2.convertToLocaleString(Math.round((x / y) * 100), culture) + "%";
161
- return (React.createElement("div", tslib_1.__assign({ className: this._classNames.chartTitleRight }, accessibilityData), dataRatioPercentage));
160
+ var dataRatioPercentage = "".concat((0, index_2.convertToLocaleString)(Math.round((x / y) * 100), culture), "%");
161
+ return (React.createElement("div", (0, tslib_1.__assign)({ className: this._classNames.chartTitleRight }, accessibilityData), dataRatioPercentage));
162
162
  }
163
163
  };
164
164
  HorizontalBarChartBase.prototype._createBenchmark = function (data) {
@@ -220,9 +220,9 @@ define(["require", "exports", "tslib", "react", "@fluentui/react/lib/Utilities",
220
220
  return React.createElement("text", { key: index });
221
221
  }
222
222
  var barValue = data.chartData[0].horizontalBarChartdata.x;
223
- return (React.createElement("text", { key: index, x: (_this._isRTL ? 100 - startingPoint[index] : startingPoint[index]) + "%", y: _this._barHeight / 2, dominantBaseline: "central", transform: "translate(" + (_this._isRTL ? -4 : 4) + ")", className: _this._classNames.barLabel, "aria-hidden": true }, d3_format_1.formatPrefix(barValue < 1000 ? '.2~' : '.1', barValue)(barValue)));
223
+ return (React.createElement("text", { key: index, x: "".concat(_this._isRTL ? 100 - startingPoint[index] : startingPoint[index], "%"), y: _this._barHeight / 2, dominantBaseline: "central", transform: "translate(".concat(_this._isRTL ? -4 : 4, ")"), className: _this._classNames.barLabel, "aria-hidden": true }, (0, d3_format_1.formatPrefix)(barValue < 1000 ? '.2~' : '.1', barValue)(barValue)));
224
224
  }
225
- return (React.createElement("rect", { key: index, x: (_this._isRTL ? 100 - startingPoint[index] - value : startingPoint[index]) + "%", y: 0, "data-is-focusable": point.legend !== '' ? true : false, width: value + '%', height: _this._barHeight, fill: color, onMouseOver: point.legend !== '' ? _this._hoverOn.bind(_this, xValue, point) : undefined, onFocus: point.legend !== '' ? _this._hoverOn.bind(_this, xValue, point) : undefined, role: "img", "aria-label": _this._getAriaLabel(point), onBlur: _this._hoverOff, onMouseLeave: _this._hoverOff, className: _this._classNames.barWrapper }));
225
+ return (React.createElement("rect", { key: index, x: "".concat(_this._isRTL ? 100 - startingPoint[index] - value : startingPoint[index], "%"), y: 0, "data-is-focusable": point.legend !== '' ? true : false, width: value + '%', height: _this._barHeight, fill: color, onMouseOver: point.legend !== '' ? _this._hoverOn.bind(_this, xValue, point) : undefined, onFocus: point.legend !== '' ? _this._hoverOn.bind(_this, xValue, point) : undefined, role: "img", "aria-label": _this._getAriaLabel(point), onBlur: _this._hoverOff, onMouseLeave: _this._hoverOff, className: _this._classNames.barWrapper }));
226
226
  });
227
227
  return bars;
228
228
  };