@fluentui/react-charting 5.18.8 → 5.18.9

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 (257) hide show
  1. package/CHANGELOG.json +16 -1
  2. package/CHANGELOG.md +11 -2
  3. package/README.md +48 -80
  4. package/dist/react-charting.d.ts +277 -36
  5. package/dist/react-charting.js +1 -1
  6. package/dist/react-charting.min.js +1 -1
  7. package/docs/TechnicalDetails.md +88 -0
  8. package/etc/react-charting.api.md +41 -41
  9. package/lib/components/AreaChart/AreaChart.types.d.ts +9 -1
  10. package/lib/components/AreaChart/AreaChart.types.js.map +1 -1
  11. package/lib/components/CommonComponents/CartesianChart.d.ts +4 -0
  12. package/lib/components/CommonComponents/CartesianChart.js +4 -0
  13. package/lib/components/CommonComponents/CartesianChart.js.map +1 -1
  14. package/lib/components/CommonComponents/CartesianChart.types.d.ts +12 -0
  15. package/lib/components/CommonComponents/CartesianChart.types.js.map +1 -1
  16. package/lib/components/DonutChart/DonutChart.types.d.ts +9 -1
  17. package/lib/components/DonutChart/DonutChart.types.js.map +1 -1
  18. package/lib/components/GaugeChart/GaugeChart.types.d.ts +13 -2
  19. package/lib/components/GaugeChart/GaugeChart.types.js +3 -0
  20. package/lib/components/GaugeChart/GaugeChart.types.js.map +1 -1
  21. package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.types.d.ts +9 -1
  22. package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.types.js.map +1 -1
  23. package/lib/components/HeatMapChart/HeatMapChart.types.d.ts +9 -1
  24. package/lib/components/HeatMapChart/HeatMapChart.types.js.map +1 -1
  25. package/lib/components/HorizontalBarChart/HorizontalBarChart.types.d.ts +13 -1
  26. package/lib/components/HorizontalBarChart/HorizontalBarChart.types.js +3 -0
  27. package/lib/components/HorizontalBarChart/HorizontalBarChart.types.js.map +1 -1
  28. package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.d.ts +9 -1
  29. package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.js.map +1 -1
  30. package/lib/components/Legends/Legends.d.ts +1 -1
  31. package/lib/components/Legends/Legends.js +1 -1
  32. package/lib/components/Legends/Legends.js.map +1 -1
  33. package/lib/components/Legends/Legends.types.d.ts +14 -8
  34. package/lib/components/Legends/Legends.types.js.map +1 -1
  35. package/lib/components/LineChart/LineChart.d.ts +1 -1
  36. package/lib/components/LineChart/LineChart.js +1 -1
  37. package/lib/components/LineChart/LineChart.js.map +1 -1
  38. package/lib/components/LineChart/LineChart.types.d.ts +18 -1
  39. package/lib/components/LineChart/LineChart.types.js.map +1 -1
  40. package/lib/components/PieChart/PieChart.d.ts +1 -1
  41. package/lib/components/PieChart/PieChart.js +1 -1
  42. package/lib/components/PieChart/PieChart.js.map +1 -1
  43. package/lib/components/PieChart/PieChart.types.d.ts +9 -1
  44. package/lib/components/PieChart/PieChart.types.js.map +1 -1
  45. package/lib/components/SankeyChart/SankeyChart.d.ts +1 -1
  46. package/lib/components/SankeyChart/SankeyChart.js +1 -1
  47. package/lib/components/SankeyChart/SankeyChart.js.map +1 -1
  48. package/lib/components/SankeyChart/SankeyChart.types.d.ts +9 -1
  49. package/lib/components/SankeyChart/SankeyChart.types.js.map +1 -1
  50. package/lib/components/Sparkline/Sparkline.d.ts +1 -1
  51. package/lib/components/Sparkline/Sparkline.js +1 -1
  52. package/lib/components/Sparkline/Sparkline.js.map +1 -1
  53. package/lib/components/Sparkline/Sparkline.types.d.ts +6 -2
  54. package/lib/components/Sparkline/Sparkline.types.js.map +1 -1
  55. package/lib/components/StackedBarChart/MultiStackedBarChart.d.ts +1 -1
  56. package/lib/components/StackedBarChart/MultiStackedBarChart.js +1 -1
  57. package/lib/components/StackedBarChart/MultiStackedBarChart.js.map +1 -1
  58. package/lib/components/StackedBarChart/MultiStackedBarChart.types.d.ts +12 -1
  59. package/lib/components/StackedBarChart/MultiStackedBarChart.types.js +3 -0
  60. package/lib/components/StackedBarChart/MultiStackedBarChart.types.js.map +1 -1
  61. package/lib/components/StackedBarChart/StackedBarChart.d.ts +1 -1
  62. package/lib/components/StackedBarChart/StackedBarChart.js +1 -1
  63. package/lib/components/StackedBarChart/StackedBarChart.js.map +1 -1
  64. package/lib/components/StackedBarChart/StackedBarChart.types.d.ts +9 -1
  65. package/lib/components/StackedBarChart/StackedBarChart.types.js.map +1 -1
  66. package/lib/components/TreeChart/TreeChart.d.ts +1 -1
  67. package/lib/components/TreeChart/TreeChart.js +1 -1
  68. package/lib/components/TreeChart/TreeChart.js.map +1 -1
  69. package/lib/components/TreeChart/TreeChart.types.d.ts +18 -1
  70. package/lib/components/TreeChart/TreeChart.types.js +6 -0
  71. package/lib/components/TreeChart/TreeChart.types.js.map +1 -1
  72. package/lib/components/VerticalBarChart/VerticalBarChart.d.ts +1 -1
  73. package/lib/components/VerticalBarChart/VerticalBarChart.js +1 -1
  74. package/lib/components/VerticalBarChart/VerticalBarChart.js.map +1 -1
  75. package/lib/components/VerticalBarChart/VerticalBarChart.types.d.ts +9 -1
  76. package/lib/components/VerticalBarChart/VerticalBarChart.types.js.map +1 -1
  77. package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.d.ts +1 -1
  78. package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.js +1 -1
  79. package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.js.map +1 -1
  80. package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.types.d.ts +9 -1
  81. package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.types.js.map +1 -1
  82. package/lib/types/IDataPoint.d.ts +67 -0
  83. package/lib/types/IDataPoint.js.map +1 -1
  84. package/lib/version.js +1 -1
  85. package/lib/version.js.map +1 -1
  86. package/lib-amd/components/AreaChart/AreaChart.types.d.ts +9 -1
  87. package/lib-amd/components/AreaChart/AreaChart.types.js.map +1 -1
  88. package/lib-amd/components/CommonComponents/CartesianChart.d.ts +4 -0
  89. package/lib-amd/components/CommonComponents/CartesianChart.js +4 -0
  90. package/lib-amd/components/CommonComponents/CartesianChart.js.map +1 -1
  91. package/lib-amd/components/CommonComponents/CartesianChart.types.d.ts +12 -0
  92. package/lib-amd/components/CommonComponents/CartesianChart.types.js.map +1 -1
  93. package/lib-amd/components/DonutChart/DonutChart.types.d.ts +9 -1
  94. package/lib-amd/components/DonutChart/DonutChart.types.js.map +1 -1
  95. package/lib-amd/components/GaugeChart/GaugeChart.types.d.ts +13 -2
  96. package/lib-amd/components/GaugeChart/GaugeChart.types.js +3 -0
  97. package/lib-amd/components/GaugeChart/GaugeChart.types.js.map +1 -1
  98. package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.types.d.ts +9 -1
  99. package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.types.js.map +1 -1
  100. package/lib-amd/components/HeatMapChart/HeatMapChart.types.d.ts +9 -1
  101. package/lib-amd/components/HeatMapChart/HeatMapChart.types.js.map +1 -1
  102. package/lib-amd/components/HorizontalBarChart/HorizontalBarChart.types.d.ts +13 -1
  103. package/lib-amd/components/HorizontalBarChart/HorizontalBarChart.types.js +3 -0
  104. package/lib-amd/components/HorizontalBarChart/HorizontalBarChart.types.js.map +1 -1
  105. package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.d.ts +9 -1
  106. package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.js.map +1 -1
  107. package/lib-amd/components/Legends/Legends.d.ts +1 -1
  108. package/lib-amd/components/Legends/Legends.js +1 -1
  109. package/lib-amd/components/Legends/Legends.js.map +1 -1
  110. package/lib-amd/components/Legends/Legends.types.d.ts +14 -8
  111. package/lib-amd/components/Legends/Legends.types.js.map +1 -1
  112. package/lib-amd/components/LineChart/LineChart.d.ts +1 -1
  113. package/lib-amd/components/LineChart/LineChart.js +1 -1
  114. package/lib-amd/components/LineChart/LineChart.js.map +1 -1
  115. package/lib-amd/components/LineChart/LineChart.types.d.ts +18 -1
  116. package/lib-amd/components/LineChart/LineChart.types.js.map +1 -1
  117. package/lib-amd/components/PieChart/PieChart.d.ts +1 -1
  118. package/lib-amd/components/PieChart/PieChart.js +1 -1
  119. package/lib-amd/components/PieChart/PieChart.js.map +1 -1
  120. package/lib-amd/components/PieChart/PieChart.types.d.ts +9 -1
  121. package/lib-amd/components/PieChart/PieChart.types.js.map +1 -1
  122. package/lib-amd/components/SankeyChart/SankeyChart.d.ts +1 -1
  123. package/lib-amd/components/SankeyChart/SankeyChart.js +1 -1
  124. package/lib-amd/components/SankeyChart/SankeyChart.js.map +1 -1
  125. package/lib-amd/components/SankeyChart/SankeyChart.types.d.ts +9 -1
  126. package/lib-amd/components/SankeyChart/SankeyChart.types.js.map +1 -1
  127. package/lib-amd/components/Sparkline/Sparkline.d.ts +1 -1
  128. package/lib-amd/components/Sparkline/Sparkline.js +1 -1
  129. package/lib-amd/components/Sparkline/Sparkline.js.map +1 -1
  130. package/lib-amd/components/Sparkline/Sparkline.types.d.ts +6 -2
  131. package/lib-amd/components/Sparkline/Sparkline.types.js.map +1 -1
  132. package/lib-amd/components/StackedBarChart/MultiStackedBarChart.d.ts +1 -1
  133. package/lib-amd/components/StackedBarChart/MultiStackedBarChart.js +1 -1
  134. package/lib-amd/components/StackedBarChart/MultiStackedBarChart.js.map +1 -1
  135. package/lib-amd/components/StackedBarChart/MultiStackedBarChart.types.d.ts +12 -1
  136. package/lib-amd/components/StackedBarChart/MultiStackedBarChart.types.js +3 -0
  137. package/lib-amd/components/StackedBarChart/MultiStackedBarChart.types.js.map +1 -1
  138. package/lib-amd/components/StackedBarChart/StackedBarChart.d.ts +1 -1
  139. package/lib-amd/components/StackedBarChart/StackedBarChart.js +1 -1
  140. package/lib-amd/components/StackedBarChart/StackedBarChart.js.map +1 -1
  141. package/lib-amd/components/StackedBarChart/StackedBarChart.types.d.ts +9 -1
  142. package/lib-amd/components/StackedBarChart/StackedBarChart.types.js.map +1 -1
  143. package/lib-amd/components/TreeChart/TreeChart.d.ts +1 -1
  144. package/lib-amd/components/TreeChart/TreeChart.js +1 -1
  145. package/lib-amd/components/TreeChart/TreeChart.js.map +1 -1
  146. package/lib-amd/components/TreeChart/TreeChart.types.d.ts +18 -1
  147. package/lib-amd/components/TreeChart/TreeChart.types.js +6 -0
  148. package/lib-amd/components/TreeChart/TreeChart.types.js.map +1 -1
  149. package/lib-amd/components/VerticalBarChart/VerticalBarChart.d.ts +1 -1
  150. package/lib-amd/components/VerticalBarChart/VerticalBarChart.js +1 -1
  151. package/lib-amd/components/VerticalBarChart/VerticalBarChart.js.map +1 -1
  152. package/lib-amd/components/VerticalBarChart/VerticalBarChart.types.d.ts +9 -1
  153. package/lib-amd/components/VerticalBarChart/VerticalBarChart.types.js.map +1 -1
  154. package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.d.ts +1 -1
  155. package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.js +1 -1
  156. package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.js.map +1 -1
  157. package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.types.d.ts +9 -1
  158. package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.types.js.map +1 -1
  159. package/lib-amd/types/IDataPoint.d.ts +67 -0
  160. package/lib-amd/types/IDataPoint.js.map +1 -1
  161. package/lib-amd/version.js +1 -1
  162. package/lib-amd/version.js.map +1 -1
  163. package/lib-commonjs/components/AreaChart/AreaChart.types.d.ts +9 -1
  164. package/lib-commonjs/components/AreaChart/AreaChart.types.js.map +1 -1
  165. package/lib-commonjs/components/CommonComponents/CartesianChart.d.ts +4 -0
  166. package/lib-commonjs/components/CommonComponents/CartesianChart.js +4 -0
  167. package/lib-commonjs/components/CommonComponents/CartesianChart.js.map +1 -1
  168. package/lib-commonjs/components/CommonComponents/CartesianChart.types.d.ts +12 -0
  169. package/lib-commonjs/components/CommonComponents/CartesianChart.types.js.map +1 -1
  170. package/lib-commonjs/components/DonutChart/DonutChart.types.d.ts +9 -1
  171. package/lib-commonjs/components/DonutChart/DonutChart.types.js.map +1 -1
  172. package/lib-commonjs/components/GaugeChart/GaugeChart.types.d.ts +13 -2
  173. package/lib-commonjs/components/GaugeChart/GaugeChart.types.js +3 -0
  174. package/lib-commonjs/components/GaugeChart/GaugeChart.types.js.map +1 -1
  175. package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.types.d.ts +9 -1
  176. package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.types.js.map +1 -1
  177. package/lib-commonjs/components/HeatMapChart/HeatMapChart.types.d.ts +9 -1
  178. package/lib-commonjs/components/HeatMapChart/HeatMapChart.types.js.map +1 -1
  179. package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.types.d.ts +13 -1
  180. package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.types.js +3 -0
  181. package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.types.js.map +1 -1
  182. package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.d.ts +9 -1
  183. package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.js.map +1 -1
  184. package/lib-commonjs/components/Legends/Legends.d.ts +1 -1
  185. package/lib-commonjs/components/Legends/Legends.js +1 -1
  186. package/lib-commonjs/components/Legends/Legends.js.map +1 -1
  187. package/lib-commonjs/components/Legends/Legends.types.d.ts +14 -8
  188. package/lib-commonjs/components/Legends/Legends.types.js.map +1 -1
  189. package/lib-commonjs/components/LineChart/LineChart.d.ts +1 -1
  190. package/lib-commonjs/components/LineChart/LineChart.js +1 -1
  191. package/lib-commonjs/components/LineChart/LineChart.js.map +1 -1
  192. package/lib-commonjs/components/LineChart/LineChart.types.d.ts +18 -1
  193. package/lib-commonjs/components/LineChart/LineChart.types.js.map +1 -1
  194. package/lib-commonjs/components/PieChart/PieChart.d.ts +1 -1
  195. package/lib-commonjs/components/PieChart/PieChart.js +1 -1
  196. package/lib-commonjs/components/PieChart/PieChart.js.map +1 -1
  197. package/lib-commonjs/components/PieChart/PieChart.types.d.ts +9 -1
  198. package/lib-commonjs/components/PieChart/PieChart.types.js.map +1 -1
  199. package/lib-commonjs/components/SankeyChart/SankeyChart.d.ts +1 -1
  200. package/lib-commonjs/components/SankeyChart/SankeyChart.js +1 -1
  201. package/lib-commonjs/components/SankeyChart/SankeyChart.js.map +1 -1
  202. package/lib-commonjs/components/SankeyChart/SankeyChart.types.d.ts +9 -1
  203. package/lib-commonjs/components/SankeyChart/SankeyChart.types.js.map +1 -1
  204. package/lib-commonjs/components/Sparkline/Sparkline.d.ts +1 -1
  205. package/lib-commonjs/components/Sparkline/Sparkline.js +1 -1
  206. package/lib-commonjs/components/Sparkline/Sparkline.js.map +1 -1
  207. package/lib-commonjs/components/Sparkline/Sparkline.types.d.ts +6 -2
  208. package/lib-commonjs/components/Sparkline/Sparkline.types.js.map +1 -1
  209. package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.d.ts +1 -1
  210. package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.js +1 -1
  211. package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.js.map +1 -1
  212. package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.types.d.ts +12 -1
  213. package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.types.js +3 -0
  214. package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.types.js.map +1 -1
  215. package/lib-commonjs/components/StackedBarChart/StackedBarChart.d.ts +1 -1
  216. package/lib-commonjs/components/StackedBarChart/StackedBarChart.js +1 -1
  217. package/lib-commonjs/components/StackedBarChart/StackedBarChart.js.map +1 -1
  218. package/lib-commonjs/components/StackedBarChart/StackedBarChart.types.d.ts +9 -1
  219. package/lib-commonjs/components/StackedBarChart/StackedBarChart.types.js.map +1 -1
  220. package/lib-commonjs/components/TreeChart/TreeChart.d.ts +1 -1
  221. package/lib-commonjs/components/TreeChart/TreeChart.js +1 -1
  222. package/lib-commonjs/components/TreeChart/TreeChart.js.map +1 -1
  223. package/lib-commonjs/components/TreeChart/TreeChart.types.d.ts +18 -1
  224. package/lib-commonjs/components/TreeChart/TreeChart.types.js +6 -0
  225. package/lib-commonjs/components/TreeChart/TreeChart.types.js.map +1 -1
  226. package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.d.ts +1 -1
  227. package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.js +1 -1
  228. package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.js.map +1 -1
  229. package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.types.d.ts +9 -1
  230. package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.types.js.map +1 -1
  231. package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.d.ts +1 -1
  232. package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.js +1 -1
  233. package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.js.map +1 -1
  234. package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.types.d.ts +9 -1
  235. package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.types.js.map +1 -1
  236. package/lib-commonjs/types/IDataPoint.d.ts +67 -0
  237. package/lib-commonjs/types/IDataPoint.js.map +1 -1
  238. package/lib-commonjs/version.js +1 -1
  239. package/lib-commonjs/version.js.map +1 -1
  240. package/package.json +1 -1
  241. package/src/components/AreaChart/AreaChart.types.ts +9 -1
  242. package/src/components/CommonComponents/CartesianChart.types.ts +12 -0
  243. package/src/components/DonutChart/DonutChart.types.ts +9 -1
  244. package/src/components/GaugeChart/GaugeChart.types.ts +13 -2
  245. package/src/components/HeatMapChart/HeatMapChart.types.ts +11 -1
  246. package/src/components/HorizontalBarChart/HorizontalBarChart.types.ts +13 -1
  247. package/src/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.ts +9 -1
  248. package/src/components/Legends/Legends.types.ts +14 -8
  249. package/src/components/LineChart/LineChart.types.ts +19 -1
  250. package/src/components/PieChart/PieChart.types.ts +10 -1
  251. package/src/components/SankeyChart/SankeyChart.types.ts +9 -1
  252. package/src/components/Sparkline/Sparkline.types.ts +6 -2
  253. package/src/components/StackedBarChart/MultiStackedBarChart.types.ts +12 -1
  254. package/src/components/StackedBarChart/StackedBarChart.types.ts +9 -1
  255. package/src/components/TreeChart/TreeChart.types.ts +20 -1
  256. package/src/components/VerticalBarChart/VerticalBarChart.types.ts +9 -1
  257. package/src/components/VerticalStackedBarChart/VerticalStackedBarChart.types.ts +9 -1
@@ -0,0 +1,88 @@
1
+ # Technical details
2
+
3
+ **Overview**
4
+
5
+ This document describes different chart components in detail.
6
+
7
+ This can be used as a guide to use the charts and contribute new functionalities or improvements to the library.
8
+
9
+ **Components**
10
+
11
+ The charting components are built using following building blocks.
12
+
13
+ - Cartesian Charts.
14
+
15
+ - Charts built using cartesian coordinate system (two axes - x axis perpendicular to y axis) are called cartesian charts. Majority of the chart in the library are cartesian charts. Some charts like horizontal chart, donut chart, sankey and tree charts are non cartesian charts.
16
+
17
+ - Legends.
18
+
19
+ - A legend contains a list of the variables appearing in the chart and an example of their appearance. This information allows the data from each variable to be identified in the chart.
20
+
21
+ - Hover Callouts.
22
+
23
+ - Whenever the mouse is hovered over a datapoint, a callout is shown representing the details of data for that point. For a stacked chart, the hover callout can represent the data for all the points for the same X coordinate.
24
+
25
+ - Axes.
26
+
27
+ - Our charts currently support cartesian axes. Different charts support different type of axes - numerical axis, date or time series axis, string or categorical axis. Detals about supported axes can be found in readme for each chart.
28
+
29
+ - Axes support for different charts
30
+
31
+ | Chart | Numeric Axis | Date Axis | String Axis |
32
+ | -------------------------- | ------------ | --------- | ----------- |
33
+ | Line Chart | Yes | Yes | No |
34
+ | Area Chart | Yes | Yes | No |
35
+ | Vertical Bar Chart | Yes | No | Yes |
36
+ | Vertical Stacked Bar Chart | Yes | No | Yes |
37
+ | Grouped Vertical Bar Chart | No | No | Yes |
38
+ | Heatmap Chart | Yes | Yes | Yes |
39
+ | Horizontal Bar Chart | -- | -- | -- |
40
+ | Donut Chart | -- | -- | -- |
41
+ | Sankey Chart | -- | -- | -- |
42
+ | Tree Chart | -- | -- | -- |
43
+ | Sparkline Chart | -- | -- | -- |
44
+
45
+ - Axis localization
46
+ The axes support 2 ways of localization.
47
+
48
+ 1. Javascript provided inbuilt localization for numeric and date axis. Specify the culture and dateLocalizeOptions for date axis to define target localization. Refer the [javascript localization guide](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleDateString) for usage.
49
+ 2. Custom locale definition: The consumer of the library can specify a custom locale definition as supported by d3 (like [this](https://github.com/d3/d3-time-format/blob/main/locale/en-US.json)). The date axis will use the date range and the multiformat specified in the definition to determine the correct format to show in the ticks. For example - If the date range is in days then the axis will show hourly ticks. If the date range spans across months then the axis will show months in tick labels and so on.
50
+ Specify the custom locale definition in the timeFormatLocale prop.
51
+ Refer to the Custom Locale Date Axis example in line chart for sample usage.
52
+
53
+ - Date axis formatting
54
+ The date axis can be custom formatted using the customDateTimeFormatter prop.
55
+
56
+ - Event annotations (Available in line charts).
57
+
58
+ - Data can be annotated using vertical lines representing the events of interest. See [line chart with events](https://fluentuipr.z22.web.core.windows.net/heads/master/react-charting/demo/index.html#/examples/linechart#Variants) for example.
59
+
60
+ - Typography.
61
+
62
+ - Our font classes represent the type ramp for the fluent design language. Each base class sets a default size, weight, and color.
63
+
64
+ - Colors
65
+
66
+ - The charts are designed using the accessible color palette defined for the fluent design system.
67
+ Refer [this](https://github.com/microsoft/fluentui/blob/master/packages/react-charting/docs/colors.md) guide for details about charting color palette and its usage.
68
+
69
+ - Themes
70
+
71
+ - The library supports light and dark mode out of box. In addition, consumers can define their own themese as detailed [here](https://github.com/microsoft/fluentui/wiki/Theming)
72
+
73
+ - Accessibility.
74
+
75
+ - Our charts have elaborate accessibility support. The charts are WCAG 2.1 MAS C compliant for accessibility.
76
+ Consumers can define their own aria labels for each point by setting the `xAxisCalloutAccessibilityData` and `callOutAccessibilityData` properties.
77
+
78
+ - RTL Support
79
+
80
+ - The charts support RTL languages wherever applicable.
81
+
82
+ - Component Styling
83
+
84
+ - [This article](https://github.com/microsoft/fluentui/wiki/Component-Styling) talks about the styling approach followed within charting library.
85
+
86
+ - Details about ticks.
87
+ - Tick values are applicable only for date axis. Doesn't work for string or numeric axis.
88
+ Tickcount works for numeric and date axis. Doesn't work for string (scaleBand) axis.
@@ -27,7 +27,7 @@ import { SVGProps } from 'react';
27
27
  // @public
28
28
  export const AreaChart: React_2.FunctionComponent<IAreaChartProps>;
29
29
 
30
- // @public (undocumented)
30
+ // @public
31
31
  export const CartesianChart: React_2.FunctionComponent<IModifiedCartesianChartProps>;
32
32
 
33
33
  // @public
@@ -151,11 +151,11 @@ export interface IAreaChartProps extends ICartesianChartProps {
151
151
  styles?: IStyleFunctionOrObject<ICartesianChartStyleProps, ICartesianChartStyles>;
152
152
  }
153
153
 
154
- // @public (undocumented)
154
+ // @public
155
155
  export interface IAreaChartStyleProps extends ICartesianChartStyleProps {
156
156
  }
157
157
 
158
- // @public (undocumented)
158
+ // @public
159
159
  export interface IAreaChartStyles extends ICartesianChartStyles {
160
160
  }
161
161
 
@@ -205,7 +205,7 @@ export interface IBasestate {
205
205
  }[];
206
206
  }
207
207
 
208
- // @public (undocumented)
208
+ // @public
209
209
  export interface ICartesianChartProps {
210
210
  calloutProps?: Partial<ICalloutProps>;
211
211
  // @deprecated
@@ -257,7 +257,7 @@ export interface ICartesianChartProps {
257
257
  yMinValue?: number;
258
258
  }
259
259
 
260
- // @public (undocumented)
260
+ // @public
261
261
  export interface ICartesianChartStyleProps {
262
262
  className?: string;
263
263
  color?: string;
@@ -271,7 +271,7 @@ export interface ICartesianChartStyleProps {
271
271
  width?: number;
272
272
  }
273
273
 
274
- // @public (undocumented)
274
+ // @public
275
275
  export interface ICartesianChartStyles {
276
276
  axisTitle?: IStyle;
277
277
  calloutBlockContainer?: IStyle;
@@ -439,11 +439,11 @@ export interface IDonutChartProps extends ICartesianChartProps {
439
439
  valueInsideDonut?: string | number;
440
440
  }
441
441
 
442
- // @public (undocumented)
442
+ // @public
443
443
  export interface IDonutChartStyleProps extends ICartesianChartStyleProps {
444
444
  }
445
445
 
446
- // @public (undocumented)
446
+ // @public
447
447
  export interface IDonutChartStyles {
448
448
  chart?: IStyle;
449
449
  legendContainer: IStyle;
@@ -499,7 +499,7 @@ export interface IGaugeChartSegment {
499
499
  size: number;
500
500
  }
501
501
 
502
- // @public (undocumented)
502
+ // @public
503
503
  export interface IGaugeChartStyleProps {
504
504
  chartHeight?: number;
505
505
  chartValueSize?: number;
@@ -510,7 +510,7 @@ export interface IGaugeChartStyleProps {
510
510
  toDrawShape?: boolean;
511
511
  }
512
512
 
513
- // @public (undocumented)
513
+ // @public
514
514
  export interface IGaugeChartStyles {
515
515
  calloutBlockContainer?: IStyle;
516
516
  calloutContentRoot?: IStyle;
@@ -561,11 +561,11 @@ export interface IGroupedVerticalBarChartProps extends ICartesianChartProps {
561
561
  styles?: IStyleFunctionOrObject<IGroupedVerticalBarChartStyleProps, IGroupedVerticalBarChartStyles>;
562
562
  }
563
563
 
564
- // @public (undocumented)
564
+ // @public
565
565
  export interface IGroupedVerticalBarChartStyleProps extends ICartesianChartStyleProps {
566
566
  }
567
567
 
568
- // @public (undocumented)
568
+ // @public
569
569
  export interface IGroupedVerticalBarChartStyles extends ICartesianChartStyles {
570
570
  barLabel: IStyle;
571
571
  opacityChangeOnHover: IStyle;
@@ -638,11 +638,11 @@ export interface IHeatMapChartProps extends Pick<ICartesianChartProps, Exclude<k
638
638
  yAxisStringFormatter?: (point: string) => string;
639
639
  }
640
640
 
641
- // @public (undocumented)
641
+ // @public
642
642
  export interface IHeatMapChartStyleProps extends ICartesianChartStyleProps {
643
643
  }
644
644
 
645
- // @public (undocumented)
645
+ // @public
646
646
  export interface IHeatMapChartStyles {
647
647
  // (undocumented)
648
648
  root?: IStyle;
@@ -674,7 +674,7 @@ export interface IHorizontalBarChartProps {
674
674
  width?: number;
675
675
  }
676
676
 
677
- // @public (undocumented)
677
+ // @public
678
678
  export interface IHorizontalBarChartStyleProps {
679
679
  barHeight?: number;
680
680
  className?: string;
@@ -686,7 +686,7 @@ export interface IHorizontalBarChartStyleProps {
686
686
  width: number | undefined;
687
687
  }
688
688
 
689
- // @public (undocumented)
689
+ // @public
690
690
  export interface IHorizontalBarChartStyles {
691
691
  barLabel: IStyle;
692
692
  barWrapper: IStyle;
@@ -729,12 +729,12 @@ export interface IHorizontalBarChartWithAxisProps extends ICartesianChartProps {
729
729
  yAxisPadding?: number;
730
730
  }
731
731
 
732
- // @public (undocumented)
732
+ // @public
733
733
  export interface IHorizontalBarChartWithAxisStyleProps extends ICartesianChartStyleProps {
734
734
  legendColor?: string;
735
735
  }
736
736
 
737
- // @public (undocumented)
737
+ // @public
738
738
  export interface IHorizontalBarChartWithAxisStyles extends ICartesianChartStyles {
739
739
  chartLabel?: IStyle;
740
740
  opacityChangeOnHover: IStyle;
@@ -773,7 +773,7 @@ export interface ILegendDataItem {
773
773
  legendText: string | number;
774
774
  }
775
775
 
776
- // @public
776
+ // @public (undocumented)
777
777
  export interface ILegendOverflowData {
778
778
  // (undocumented)
779
779
  overflow?: ILegend[];
@@ -781,7 +781,7 @@ export interface ILegendOverflowData {
781
781
  primary: ILegend[];
782
782
  }
783
783
 
784
- // @public (undocumented)
784
+ // @public
785
785
  export interface ILegendsProps {
786
786
  allowFocusOnLegends?: boolean;
787
787
  canSelectMultipleLegends?: boolean;
@@ -812,7 +812,7 @@ export interface ILegendsStyles {
812
812
  triangle: IStyle;
813
813
  }
814
814
 
815
- // @public (undocumented)
815
+ // @public
816
816
  export interface ILegendStyleProps {
817
817
  // (undocumented)
818
818
  borderColor?: string;
@@ -832,7 +832,7 @@ export interface ILegendStyleProps {
832
832
  theme?: ITheme;
833
833
  }
834
834
 
835
- // @public
835
+ // @public (undocumented)
836
836
  export interface ILegendSubComponentStyles {
837
837
  // (undocumented)
838
838
  hoverCardStyles: IStyleFunctionOrObject<IHoverCardStyleProps, IHoverCardStyles>;
@@ -899,11 +899,11 @@ export interface ILineChartProps extends ICartesianChartProps {
899
899
  styles?: IStyleFunctionOrObject<ILineChartStyleProps, ILineChartStyles>;
900
900
  }
901
901
 
902
- // @public (undocumented)
902
+ // @public
903
903
  export interface ILineChartStyleProps extends ICartesianChartStyleProps {
904
904
  }
905
905
 
906
- // @public (undocumented)
906
+ // @public
907
907
  export interface ILineChartStyles extends ICartesianChartStyles {
908
908
  }
909
909
 
@@ -1015,7 +1015,7 @@ export interface IMultiStackedBarChartProps {
1015
1015
  width?: number;
1016
1016
  }
1017
1017
 
1018
- // @public (undocumented)
1018
+ // @public
1019
1019
  export interface IMultiStackedBarChartStyleProps {
1020
1020
  barHeight?: number;
1021
1021
  className?: string;
@@ -1028,7 +1028,7 @@ export interface IMultiStackedBarChartStyleProps {
1028
1028
  width?: number;
1029
1029
  }
1030
1030
 
1031
- // @public (undocumented)
1031
+ // @public
1032
1032
  export interface IMultiStackedBarChartStyles {
1033
1033
  barLabel: IStyle;
1034
1034
  chart: IStyle;
@@ -1064,10 +1064,10 @@ export interface IPieChartProps {
1064
1064
  width?: number;
1065
1065
  }
1066
1066
 
1067
- // @public (undocumented)
1067
+ // @public
1068
1068
  export type IPieChartStyleProps = Required<Pick<IPieChartProps, 'theme' | 'width' | 'height'>> & Pick<IPieChartProps, 'className'>;
1069
1069
 
1070
- // @public (undocumented)
1070
+ // @public
1071
1071
  export interface IPieChartStyles {
1072
1072
  chart?: IStyle;
1073
1073
  chartTitle?: IStyle;
@@ -1105,7 +1105,7 @@ export interface ISankeyChartProps {
1105
1105
  width?: number;
1106
1106
  }
1107
1107
 
1108
- // @public (undocumented)
1108
+ // @public
1109
1109
  export interface ISankeyChartStyleProps {
1110
1110
  // (undocumented)
1111
1111
  className?: string;
@@ -1119,7 +1119,7 @@ export interface ISankeyChartStyleProps {
1119
1119
  width: number;
1120
1120
  }
1121
1121
 
1122
- // @public (undocumented)
1122
+ // @public
1123
1123
  export interface ISankeyChartStyles {
1124
1124
  calloutContentRoot?: IStyle;
1125
1125
  links?: IStyle;
@@ -1158,7 +1158,7 @@ export interface ISparklineProps {
1158
1158
  export interface ISparklineStyleProps extends ICartesianChartStyleProps {
1159
1159
  }
1160
1160
 
1161
- // @public (undocumented)
1161
+ // @public
1162
1162
  export interface ISparklineStyles {
1163
1163
  // (undocumented)
1164
1164
  inlineBlock?: IStyle;
@@ -1197,7 +1197,7 @@ export interface IStackedBarChartProps {
1197
1197
  width?: number;
1198
1198
  }
1199
1199
 
1200
- // @public (undocumented)
1200
+ // @public
1201
1201
  export interface IStackedBarChartStyleProps {
1202
1202
  barHeight?: number;
1203
1203
  benchmarkColor?: string;
@@ -1214,7 +1214,7 @@ export interface IStackedBarChartStyleProps {
1214
1214
  width?: number;
1215
1215
  }
1216
1216
 
1217
- // @public (undocumented)
1217
+ // @public
1218
1218
  export interface IStackedBarChartStyles {
1219
1219
  benchmark: IStyle;
1220
1220
  benchmarkContainer: IStyle;
@@ -1229,7 +1229,7 @@ export interface IStackedBarChartStyles {
1229
1229
  target: IStyle;
1230
1230
  }
1231
1231
 
1232
- // @public
1232
+ // @public (undocumented)
1233
1233
  export interface ITreeChartDataPoint {
1234
1234
  bodytext?: string;
1235
1235
  children?: Array<ITreeChartDataPoint>;
@@ -1253,7 +1253,7 @@ export interface ITreeDataStructure {
1253
1253
  y: number;
1254
1254
  }
1255
1255
 
1256
- // @public (undocumented)
1256
+ // @public
1257
1257
  export interface ITreeProps {
1258
1258
  className?: string;
1259
1259
  composition?: NodesComposition.long | NodesComposition.compact;
@@ -1274,13 +1274,13 @@ export interface ITreeState {
1274
1274
  _width: number;
1275
1275
  }
1276
1276
 
1277
- // @public (undocumented)
1277
+ // @public
1278
1278
  export interface ITreeStyleProps {
1279
1279
  className?: string;
1280
1280
  theme: ITheme;
1281
1281
  }
1282
1282
 
1283
- // @public (undocumented)
1283
+ // @public
1284
1284
  export interface ITreeStyles {
1285
1285
  link: IStyle;
1286
1286
  rectBodyText: IStyle;
@@ -1321,12 +1321,12 @@ export interface IVerticalBarChartProps extends ICartesianChartProps {
1321
1321
  xAxisPadding?: number;
1322
1322
  }
1323
1323
 
1324
- // @public (undocumented)
1324
+ // @public
1325
1325
  export interface IVerticalBarChartStyleProps extends ICartesianChartStyleProps {
1326
1326
  legendColor?: string;
1327
1327
  }
1328
1328
 
1329
- // @public (undocumented)
1329
+ // @public
1330
1330
  export interface IVerticalBarChartStyles extends ICartesianChartStyles {
1331
1331
  barLabel: IStyle;
1332
1332
  // @deprecated
@@ -1370,11 +1370,11 @@ export interface IVerticalStackedBarChartProps extends ICartesianChartProps {
1370
1370
  yMinValue?: undefined;
1371
1371
  }
1372
1372
 
1373
- // @public (undocumented)
1373
+ // @public
1374
1374
  export interface IVerticalStackedBarChartStyleProps extends ICartesianChartStyleProps {
1375
1375
  }
1376
1376
 
1377
- // @public (undocumented)
1377
+ // @public
1378
1378
  export interface IVerticalStackedBarChartStyles extends ICartesianChartStyles {
1379
1379
  barLabel: IStyle;
1380
1380
  // @deprecated
@@ -3,7 +3,7 @@ import { IChartProps, IRefArrayData, IBasestate, ILineChartDataPoint, ILineChart
3
3
  import { ICartesianChartStyles, ICartesianChartStyleProps, ICartesianChartProps, IChildProps } from '../CommonComponents/CartesianChart.types';
4
4
  export type { IChildProps, IRefArrayData, IBasestate, ILineChartDataPoint, ILineChartPoints, IMargins };
5
5
  /**
6
- * IAreaChartProps properties for area chart.
6
+ * Area Chart properties.
7
7
  * {@docCategory AreaChart}
8
8
  */
9
9
  export interface IAreaChartProps extends ICartesianChartProps {
@@ -40,7 +40,15 @@ export interface IAreaChartProps extends ICartesianChartProps {
40
40
  enablePerfOptimization?: boolean;
41
41
  optimizeLargeData?: boolean;
42
42
  }
43
+ /**
44
+ * Area Chart styles
45
+ * {@docCategory AreaChart}
46
+ */
43
47
  export interface IAreaChartStyles extends ICartesianChartStyles {
44
48
  }
49
+ /**
50
+ * Area Chart style properties
51
+ * {@docCategory AreaChart}
52
+ */
45
53
  export interface IAreaChartStyleProps extends ICartesianChartStyleProps {
46
54
  }
@@ -1 +1 @@
1
- {"version":3,"file":"AreaChart.types.js","sourceRoot":"../src/","sources":["components/AreaChart/AreaChart.types.ts"],"names":[],"mappings":"","sourcesContent":["import { IRenderFunction, IStyleFunctionOrObject } from '@fluentui/react/lib/Utilities';\nimport {\n IChartProps,\n IRefArrayData,\n IBasestate,\n ILineChartDataPoint,\n ILineChartPoints,\n ICustomizedCalloutData,\n IMargins,\n} from '../../types/index';\nimport {\n ICartesianChartStyles,\n ICartesianChartStyleProps,\n ICartesianChartProps,\n IChildProps,\n} from '../CommonComponents/CartesianChart.types';\n\nexport type { IChildProps, IRefArrayData, IBasestate, ILineChartDataPoint, ILineChartPoints, IMargins };\n\n/**\n * IAreaChartProps properties for area chart.\n * {@docCategory AreaChart}\n */\nexport interface IAreaChartProps extends ICartesianChartProps {\n /**\n * Data to render in the chart.\n */\n data: IChartProps;\n\n /**\n * This prop is used to draw Y axis grid lines on the chart. Default value will be false\n * @deprecated now lines are shown by default\n * no need to use this prop\n */\n showYAxisGridLines?: boolean;\n\n /**\n * Call to provide customized styling that will layer on top of the variant rules.\n */\n styles?: IStyleFunctionOrObject<ICartesianChartStyleProps, ICartesianChartStyles>;\n\n /**\n * Define a custom callout renderer for a data point\n */\n onRenderCalloutPerDataPoint?: IRenderFunction<ICustomizedCalloutData>;\n\n /**\n * Define a custom callout renderer for a stack; default is to render per data point\n */\n onRenderCalloutPerStack?: IRenderFunction<ICustomizedCalloutData>;\n\n /**\n * The prop used to define the culture to localized the numbers\n */\n culture?: string;\n\n /**\n * @default false\n * The prop used to enable the perf optimization\n */\n enablePerfOptimization?: boolean;\n\n /*\n * Optimize area chart rendering for large data set.\n */\n optimizeLargeData?: boolean;\n}\n\nexport interface IAreaChartStyles extends ICartesianChartStyles {}\n\nexport interface IAreaChartStyleProps extends ICartesianChartStyleProps {}\n"]}
1
+ {"version":3,"file":"AreaChart.types.js","sourceRoot":"../src/","sources":["components/AreaChart/AreaChart.types.ts"],"names":[],"mappings":"","sourcesContent":["import { IRenderFunction, IStyleFunctionOrObject } from '@fluentui/react/lib/Utilities';\nimport {\n IChartProps,\n IRefArrayData,\n IBasestate,\n ILineChartDataPoint,\n ILineChartPoints,\n ICustomizedCalloutData,\n IMargins,\n} from '../../types/index';\nimport {\n ICartesianChartStyles,\n ICartesianChartStyleProps,\n ICartesianChartProps,\n IChildProps,\n} from '../CommonComponents/CartesianChart.types';\n\nexport type { IChildProps, IRefArrayData, IBasestate, ILineChartDataPoint, ILineChartPoints, IMargins };\n\n/**\n * Area Chart properties.\n * {@docCategory AreaChart}\n */\nexport interface IAreaChartProps extends ICartesianChartProps {\n /**\n * Data to render in the chart.\n */\n data: IChartProps;\n\n /**\n * This prop is used to draw Y axis grid lines on the chart. Default value will be false\n * @deprecated now lines are shown by default\n * no need to use this prop\n */\n showYAxisGridLines?: boolean;\n\n /**\n * Call to provide customized styling that will layer on top of the variant rules.\n */\n styles?: IStyleFunctionOrObject<ICartesianChartStyleProps, ICartesianChartStyles>;\n\n /**\n * Define a custom callout renderer for a data point\n */\n onRenderCalloutPerDataPoint?: IRenderFunction<ICustomizedCalloutData>;\n\n /**\n * Define a custom callout renderer for a stack; default is to render per data point\n */\n onRenderCalloutPerStack?: IRenderFunction<ICustomizedCalloutData>;\n\n /**\n * The prop used to define the culture to localized the numbers\n */\n culture?: string;\n\n /**\n * @default false\n * The prop used to enable the perf optimization\n */\n enablePerfOptimization?: boolean;\n\n /*\n * Optimize area chart rendering for large data set.\n */\n optimizeLargeData?: boolean;\n}\n\n/**\n * Area Chart styles\n * {@docCategory AreaChart}\n */\nexport interface IAreaChartStyles extends ICartesianChartStyles {}\n\n/**\n * Area Chart style properties\n * {@docCategory AreaChart}\n */\nexport interface IAreaChartStyleProps extends ICartesianChartStyleProps {}\n"]}
@@ -1,3 +1,7 @@
1
1
  import * as React from 'react';
2
2
  import { IModifiedCartesianChartProps } from './CartesianChart.types';
3
+ /**
4
+ * Cartesian Chart component
5
+ * {@docCategory CartesianChart}
6
+ */
3
7
  export declare const CartesianChart: React.FunctionComponent<IModifiedCartesianChartProps>;
@@ -1,5 +1,9 @@
1
1
  import { styled } from '@fluentui/react/lib/Utilities';
2
2
  import { CartesianChartBase } from './CartesianChart.base';
3
3
  import { getStyles } from './CartesianChart.styles';
4
+ /**
5
+ * Cartesian Chart component
6
+ * {@docCategory CartesianChart}
7
+ */
4
8
  export var CartesianChart = styled(CartesianChartBase, getStyles);
5
9
  //# sourceMappingURL=CartesianChart.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"CartesianChart.js","sourceRoot":"../src/","sources":["components/CommonComponents/CartesianChart.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAE,MAAM,+BAA+B,CAAC;AAEvD,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAC3D,OAAO,EAAE,SAAS,EAAE,MAAM,yBAAyB,CAAC;AAEpD,MAAM,CAAC,IAAM,cAAc,GAA0D,MAAM,CAIzF,kBAAkB,EAAE,SAAS,CAAC,CAAC","sourcesContent":["import * as React from 'react';\nimport { styled } from '@fluentui/react/lib/Utilities';\nimport { IModifiedCartesianChartProps, ICartesianChartStyleProps, ICartesianChartStyles } from './CartesianChart.types';\nimport { CartesianChartBase } from './CartesianChart.base';\nimport { getStyles } from './CartesianChart.styles';\n\nexport const CartesianChart: React.FunctionComponent<IModifiedCartesianChartProps> = styled<\n IModifiedCartesianChartProps,\n ICartesianChartStyleProps,\n ICartesianChartStyles\n>(CartesianChartBase, getStyles);\n"]}
1
+ {"version":3,"file":"CartesianChart.js","sourceRoot":"../src/","sources":["components/CommonComponents/CartesianChart.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAE,MAAM,+BAA+B,CAAC;AAEvD,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAC3D,OAAO,EAAE,SAAS,EAAE,MAAM,yBAAyB,CAAC;AAEpD;;;GAGG;AACH,MAAM,CAAC,IAAM,cAAc,GAA0D,MAAM,CAIzF,kBAAkB,EAAE,SAAS,CAAC,CAAC","sourcesContent":["import * as React from 'react';\nimport { styled } from '@fluentui/react/lib/Utilities';\nimport { IModifiedCartesianChartProps, ICartesianChartStyleProps, ICartesianChartStyles } from './CartesianChart.types';\nimport { CartesianChartBase } from './CartesianChart.base';\nimport { getStyles } from './CartesianChart.styles';\n\n/**\n * Cartesian Chart component\n * {@docCategory CartesianChart}\n */\nexport const CartesianChart: React.FunctionComponent<IModifiedCartesianChartProps> = styled<\n IModifiedCartesianChartProps,\n ICartesianChartStyleProps,\n ICartesianChartStyles\n>(CartesianChartBase, getStyles);\n"]}
@@ -8,6 +8,10 @@ import { ILegendsProps } from '../Legends/index';
8
8
  import { IAccessibilityProps, IMargins } from '../../types/index';
9
9
  import { ChartTypes, IChartHoverCardProps, XAxisTypes, YAxisType } from '../../utilities/index';
10
10
  import * as d3TimeFormat from 'd3-time-format';
11
+ /**
12
+ * Cartesian Chart style properties
13
+ * {@docCategory CartesianChart}
14
+ */
11
15
  export interface ICartesianChartStyleProps {
12
16
  /**
13
17
  * Theme (provided through customization.)
@@ -50,6 +54,10 @@ export interface ICartesianChartStyleProps {
50
54
  */
51
55
  toDrawShape?: boolean;
52
56
  }
57
+ /**
58
+ * Cartesian Chart styles
59
+ * {@docCategory CartesianChart}
60
+ */
53
61
  export interface ICartesianChartStyles {
54
62
  /**
55
63
  * Style for the root element.
@@ -128,6 +136,10 @@ export interface ICartesianChartStyles {
128
136
  */
129
137
  chartWrapper?: IStyle;
130
138
  }
139
+ /**
140
+ * Cartesian Chart properties
141
+ * {@docCategory CartesianChart}
142
+ */
131
143
  export interface ICartesianChartProps {
132
144
  /**
133
145
  * Below height used for resizing of the chart
@@ -1 +1 @@
1
- {"version":3,"file":"CartesianChart.types.js","sourceRoot":"../src/","sources":["components/CommonComponents/CartesianChart.types.ts"],"names":[],"mappings":"","sourcesContent":["import * as React from 'react';\nimport { IStyleFunctionOrObject } from '@fluentui/react/lib/Utilities';\nimport { ITheme, IStyle } from '@fluentui/react/lib/Styling';\nimport { IOverflowSetProps } from '@fluentui/react/lib/OverflowSet';\nimport { IFocusZoneProps, FocusZoneDirection } from '@fluentui/react-focus';\nimport { ICalloutProps } from '@fluentui/react/lib/Callout';\nimport { ILegendsProps } from '../Legends/index';\nimport { IAccessibilityProps, IMargins } from '../../types/index';\nimport { ChartTypes, IChartHoverCardProps, XAxisTypes, YAxisType } from '../../utilities/index';\nimport * as d3TimeFormat from 'd3-time-format';\n\nexport interface ICartesianChartStyleProps {\n /**\n * Theme (provided through customization.)\n */\n theme: ITheme;\n\n /**\n * Additional CSS class(es) to apply to the Chart.\n */\n className?: string;\n\n /**\n * Width of the chart.\n */\n width?: number;\n\n /**\n * Height of the chart.\n */\n height?: number;\n\n /**\n * Color of the chart.\n */\n color?: string;\n\n /**\n * Link to redirect if click action for graph\n */\n href?: string;\n\n /**\n * prop to check if the chart is selected or hovered upon to determine opacity\n */\n shouldHighlight?: boolean;\n\n /**\n * prop to check if the Page is in Rtl\n */\n isRtl?: boolean;\n\n /**\n * color of the line\n */\n lineColor?: string;\n\n /**\n * boolean flag which determines if shape is drawn in callout\n */\n toDrawShape?: boolean;\n}\n\nexport interface ICartesianChartStyles {\n /**\n * Style for the root element.\n */\n root?: IStyle;\n\n /**\n * Style for the element containing the x-axis.\n */\n xAxis?: IStyle;\n\n /**\n * Style for the element containing the y-axis.\n */\n yAxis?: IStyle;\n\n /**\n * Style for legend container\n */\n legendContainer?: IStyle;\n\n /**\n * line hover box css\n */\n hover?: IStyle;\n\n /**\n * styles for callout root-content\n */\n calloutContentRoot?: IStyle;\n\n /**\n * styles for callout x-content\n */\n calloutContentX?: IStyle;\n\n /**\n * styles for callout y-content\n */\n calloutContentY?: IStyle;\n\n /**\n * styles for description message\n */\n descriptionMessage?: IStyle;\n\n /**\n * styles for callout Date time container\n */\n calloutDateTimeContainer?: IStyle;\n\n /**\n * styles for callout info container\n */\n calloutInfoContainer?: IStyle;\n\n /**\n * styles for callout block container\n */\n calloutBlockContainer?: IStyle;\n\n /**\n * styles for callout legend text\n */\n calloutlegendText?: IStyle;\n\n /**\n * styles for tooltip\n */\n tooltip?: IStyle;\n\n /**\n * styles for tooltip\n */\n axisTitle?: IStyle;\n\n /**\n * Style for the chart Title.\n */\n chartTitle?: IStyle;\n\n /**\n * Style to change the opacity of bars in dataviz when we hover on a single bar or legends\n */\n opacityChangeOnHover?: IStyle;\n\n /**\n * styles for the shape object in the callout\n */\n shapeStyles?: IStyle;\n\n /**\n * Styles for the chart wrapper div\n */\n chartWrapper?: IStyle;\n}\n\nexport interface ICartesianChartProps {\n /**\n * Below height used for resizing of the chart\n * Wrap chart in your container and send the updated height and width to these props.\n * These values decide wheather chart re render or not. Please check examples for reference\n */\n height?: number;\n\n /**\n * Below width used for resizing of the chart\n * Wrap chart in your container and send the updated height and width to these props.\n * These values decide wheather chart re render or not. Please check examples for reference\n */\n width?: number;\n\n /**\n * this prop takes its parent as a HTML element to define the width and height of the chart\n */\n parentRef?: HTMLElement | null;\n\n /**\n * Additional CSS class(es) to apply to the Chart.\n */\n className?: string;\n\n /**\n * Theme (provided through customization.)\n */\n theme?: ITheme;\n\n /**\n * Margins for the chart\n * @default `{ top: 20, bottom: 35, left: 40, right: 20 }`\n * To avoid edge cuttings to the chart, we recommend you use default values or greater then default values\n */\n margins?: IMargins;\n\n /** decides wether to show/hide legends\n * @defaultvalue false\n */\n hideLegend?: boolean;\n\n /**\n * Do not show tooltips in chart\n * @default false\n */\n hideTooltip?: boolean;\n\n /**\n * this prop takes values that you want the chart to render on x-axis\n * This is a optional parameter if not specified D3 will decide which values appear on the x-axis for you\n * Please look at https://github.com/d3/d3-scale for more information on how D3 decides what data to appear on the axis of chart\n */\n tickValues?: number[] | Date[];\n\n /**\n * the format for the data on x-axis. For date object this can be specified to your requirement. Eg: '%m/%d', '%d'\n * Please look at https://github.com/d3/d3-time-format for all the formats supported for date axis\n * Only applicable for date axis. For y-axis format use yAxisTickFormat prop.\n */\n tickFormat?: string;\n\n /**\n * Width of line stroke\n */\n strokeWidth?: number;\n\n /**\n * x Axis labels tick padding. This defines the gap between tick labels and tick lines.\n * @default 10\n */\n xAxisTickPadding?: number;\n\n /**\n * the format in for the data on y-axis. For data object this can be specified to your requirement.\n * Eg: d3.format(\".0%\")(0.123),d3.format(\"+20\")(42);\n * Please look at https://github.com/d3/d3-format for all the formats supported\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n yAxisTickFormat?: any;\n\n /**\n * Secondary y-scale options\n * By default this is not defined, meaning there will be no secondary y-scale.\n */\n secondaryYScaleOptions?: {\n /** Minimum value (0 by default) */\n yMinValue?: number;\n /** Maximum value (100 by default) */\n yMaxValue?: number;\n };\n\n /**\n * minimum data value point in y-axis\n */\n yMinValue?: number;\n\n /**\n * maximum data value point in y-axis\n */\n yMaxValue?: number;\n\n /**\n * maximum data value point in x-axis\n */\n xMaxValue?: number;\n\n /**\n * Number of ticks on the y-axis.\n * Tick count should be factor of difference between (yMinValue, yMaxValue)?\n * @default 4\n */\n yAxisTickCount?: number;\n\n /**\n * defines the number of ticks on the x-axis. Tries to match the nearest interval satisfying the count.\n * Does not work for string axis.\n * @default 6\n */\n xAxisTickCount?: number;\n\n /**\n * define the size of the tick lines on the x-axis\n * @default 10\n */\n xAxistickSize?: number;\n\n /**\n * defines the space between the tick line and the data label\n * @default 10\n */\n tickPadding?: number;\n\n /**\n * Url that the data-viz needs to redirect to upon clicking on it\n */\n href?: string;\n\n /**\n * Label to apply to the whole chart.\n * @deprecated - Use your chart label for the chart.\n */\n chartLabel?: string;\n\n /**\n * overflow props for the legends\n */\n legendsOverflowProps?: Partial<IOverflowSetProps>;\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n legendsOverflowText?: any;\n\n /**\n * focus zone props in hover card for legends\n */\n focusZonePropsForLegendsInHoverCard?: IFocusZoneProps;\n\n /**\n * Enable the legends to wrap lines if there is not enough space to show all legends on a single line\n */\n enabledLegendsWrapLines?: boolean;\n\n /*\n * props for the legends in the chart\n */\n legendProps?: Partial<ILegendsProps>;\n\n /**\n *@default false\n *Used for to elipse x axis labes and show tooltip on x axis labels\n */\n showXAxisLablesTooltip?: boolean;\n\n /**\n * @default 4\n * Used for X axis labels\n * While Giving showXAxisLablesTooltip prop, need to define after how many chars, we need to truncate the word.\n */\n noOfCharsToTruncate?: number;\n\n /**\n * @default false\n * Used to wrap x axis labels values (whole value)\n */\n wrapXAxisLables?: boolean;\n\n /**\n * @default false\n * Used to rotate x axis labels by 45 degrees\n */\n rotateXAxisLables?: boolean;\n\n /**\n * The prop used to define the date time localization options\n */\n dateLocalizeOptions?: Intl.DateTimeFormatOptions;\n\n /**\n * The prop used to define a custom locale for the date time format.\n */\n timeFormatLocale?: d3TimeFormat.TimeLocaleDefinition;\n\n /**\n * The prop used to define a custom datetime formatter for date axis.\n */\n customDateTimeFormatter?: (dateTime: Date) => string;\n\n /**\n * Call to provide customized styling that will layer on top of the variant rules.\n */\n styles?: IStyleFunctionOrObject<ICartesianChartStyleProps, ICartesianChartStyles>;\n\n /**\n * Callout customization props\n */\n calloutProps?: Partial<ICalloutProps>;\n\n /**\n * props for the svg; use this to include aria-* or other attributes on the tag\n */\n svgProps?: React.SVGProps<SVGSVGElement>;\n\n /**\n * Prop to disable shrinking of the chart beyond a certain limit and enable scrolling when the chart overflows\n * @default True for LineChart but False for other charts\n */\n enableReflow?: boolean;\n\n /**\n * Prop to set the x axis title\n * @default undefined\n * Minimum bottom margin required for x axis title is 55px\n */\n\n xAxisTitle?: string;\n\n /**\n * Prop to set the y axis title\n * @default undefined\n * Minimum left margin required for y axis title is 60px and for RTL is 40px\n * Minimum right margin required for y axis title is 40px and for RTL is 60px\n */\n yAxisTitle?: string;\n\n /**\n * Prop to set the secondary y axis title\n * @default undefined\n * If RTL is enabled, minimum left and right margins required for secondary y axis title is 60px\n */\n secondaryYAxistitle?: string;\n}\n\nexport interface IYValueHover {\n legend?: string;\n y?: number;\n color?: string;\n data?: string | number;\n shouldDrawBorderBottom?: boolean;\n yAxisCalloutData?: string | { [id: string]: number };\n index?: number;\n callOutAccessibilityData?: IAccessibilityProps;\n}\n\nexport interface IChildProps {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n xScale?: any;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n yScale?: any;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n yScaleSecondary?: any;\n containerHeight?: number;\n containerWidth?: number;\n}\n\n// Only used for Cartesian chart base\nexport interface IModifiedCartesianChartProps extends ICartesianChartProps {\n /**\n * Define the chart title\n */\n chartTitle?: string;\n\n /**\n * Only used for Area chart\n * Value used to draw y axis of that chart.\n */\n maxOfYVal?: number;\n\n /**\n * Data of the chart\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n points: any;\n\n /**\n * Define type of the chart\n */\n chartType: ChartTypes;\n\n /** X axis type */\n xAxisType: XAxisTypes;\n\n /** Y axis type */\n yAxisType?: YAxisType;\n\n /**\n * Legends of the chart.\n */\n legendBars: JSX.Element | null;\n\n /**\n * Callout props\n */\n calloutProps: Partial<ICalloutProps> & {\n isCalloutVisible: boolean;\n id: string;\n YValueHover?: IYValueHover[];\n hoverXValue?: string | number | null;\n legend?: string;\n color?: string;\n YValue?: string | number;\n XValue?: string;\n descriptionMessage?: string;\n };\n\n /**\n * Callback method used for to get margins to the chart.\n */\n getmargins?: (margins: IMargins) => void;\n\n /**\n * This is a call back method to the chart from cartesian chart.\n * params are xScale, yScale, containerHeight, containerWidth. These values were used to draw the graph.\n * It also contians an optional param xAxisElement - defines as x axis scale element.\n * This param used to enable feature word wrap of Xaxis.\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n getGraphData?: any;\n\n /**\n * Used for bar chart graphs.\n * To define width of the bar\n */\n barwidth?: number;\n\n /**\n * Used for tick styles of the x axis of the chart\n * Tick params are applicable for date axis only.\n */\n tickParams?: {\n tickValues?: number[] | Date[];\n tickFormat?: string;\n };\n\n /**\n * it's padding between bar's or lines in the graph\n */\n xAxisPadding?: number;\n\n /**\n * it's padding between bar's or lines in the graph\n */\n yAxisPadding?: number;\n\n /**\n * Children elements specific to derived chart types.\n */\n children(props: IChildProps): React.ReactNode;\n\n /**\n * To enable callout for individualbar or complete stack. Using for only Vertical stacked bar chart.\n * @default false\n * @type \\{boolean \\}\n */\n isCalloutForStack?: boolean;\n\n /** dataset values to find out domain of the String axis\n * Present using for only vertical stacked bar chart and grouped vertical bar chart\n */\n datasetForXAxisDomain?: string[];\n\n /** Own callout design */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n customizedCallout?: any;\n\n /**\n * if the data points for the y-axis is of type string, then we need to give this\n * prop to construct the y-axis\n */\n stringDatasetForYAxisDomain?: string[];\n\n /**\n * Focus zone direction to the chart\n * @default FocusZoneDirection.horizontal\n */\n focusZoneDirection?: FocusZoneDirection;\n\n /**\n * props to send into the chart hover card\n */\n chartHoverProps?: IChartHoverCardProps;\n\n /**\n * props to send to the focuszone\n */\n svgFocusZoneProps?: IFocusZoneProps;\n\n /**\n * The prop used to define the culture to localize the numbers and date\n */\n culture?: string;\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n getAxisData?: any;\n\n /**\n * Callback method used when mouse leaves the chart boundary.\n */\n onChartMouseLeave?: () => void;\n\n /** Callback method to get extra margins for domain */\n getDomainMargins?: (containerWidth: number) => IMargins;\n\n /** Padding between each bar/line-point */\n xAxisInnerPadding?: number;\n\n /** Padding before first bar/line-point and after last bar/line-point */\n xAxisOuterPadding?: number;\n\n /**\n *@default false\n *Used for to elipse y axis labes and show tooltip on x axis labels\n */\n showYAxisLablesTooltip?: boolean;\n\n /**\n *@default false\n *Used for showing complete y axis lables */\n showYAxisLables?: boolean;\n\n /**\n * @default false\n * Used to control the first render cycle Performance optimization code.\n */\n enableFirstRenderOptimization?: boolean;\n}\n"]}
1
+ {"version":3,"file":"CartesianChart.types.js","sourceRoot":"../src/","sources":["components/CommonComponents/CartesianChart.types.ts"],"names":[],"mappings":"","sourcesContent":["import * as React from 'react';\nimport { IStyleFunctionOrObject } from '@fluentui/react/lib/Utilities';\nimport { ITheme, IStyle } from '@fluentui/react/lib/Styling';\nimport { IOverflowSetProps } from '@fluentui/react/lib/OverflowSet';\nimport { IFocusZoneProps, FocusZoneDirection } from '@fluentui/react-focus';\nimport { ICalloutProps } from '@fluentui/react/lib/Callout';\nimport { ILegendsProps } from '../Legends/index';\nimport { IAccessibilityProps, IMargins } from '../../types/index';\nimport { ChartTypes, IChartHoverCardProps, XAxisTypes, YAxisType } from '../../utilities/index';\nimport * as d3TimeFormat from 'd3-time-format';\n\n/**\n * Cartesian Chart style properties\n * {@docCategory CartesianChart}\n */\nexport interface ICartesianChartStyleProps {\n /**\n * Theme (provided through customization.)\n */\n theme: ITheme;\n\n /**\n * Additional CSS class(es) to apply to the Chart.\n */\n className?: string;\n\n /**\n * Width of the chart.\n */\n width?: number;\n\n /**\n * Height of the chart.\n */\n height?: number;\n\n /**\n * Color of the chart.\n */\n color?: string;\n\n /**\n * Link to redirect if click action for graph\n */\n href?: string;\n\n /**\n * prop to check if the chart is selected or hovered upon to determine opacity\n */\n shouldHighlight?: boolean;\n\n /**\n * prop to check if the Page is in Rtl\n */\n isRtl?: boolean;\n\n /**\n * color of the line\n */\n lineColor?: string;\n\n /**\n * boolean flag which determines if shape is drawn in callout\n */\n toDrawShape?: boolean;\n}\n\n/**\n * Cartesian Chart styles\n * {@docCategory CartesianChart}\n */\nexport interface ICartesianChartStyles {\n /**\n * Style for the root element.\n */\n root?: IStyle;\n\n /**\n * Style for the element containing the x-axis.\n */\n xAxis?: IStyle;\n\n /**\n * Style for the element containing the y-axis.\n */\n yAxis?: IStyle;\n\n /**\n * Style for legend container\n */\n legendContainer?: IStyle;\n\n /**\n * line hover box css\n */\n hover?: IStyle;\n\n /**\n * styles for callout root-content\n */\n calloutContentRoot?: IStyle;\n\n /**\n * styles for callout x-content\n */\n calloutContentX?: IStyle;\n\n /**\n * styles for callout y-content\n */\n calloutContentY?: IStyle;\n\n /**\n * styles for description message\n */\n descriptionMessage?: IStyle;\n\n /**\n * styles for callout Date time container\n */\n calloutDateTimeContainer?: IStyle;\n\n /**\n * styles for callout info container\n */\n calloutInfoContainer?: IStyle;\n\n /**\n * styles for callout block container\n */\n calloutBlockContainer?: IStyle;\n\n /**\n * styles for callout legend text\n */\n calloutlegendText?: IStyle;\n\n /**\n * styles for tooltip\n */\n tooltip?: IStyle;\n\n /**\n * styles for tooltip\n */\n axisTitle?: IStyle;\n\n /**\n * Style for the chart Title.\n */\n chartTitle?: IStyle;\n\n /**\n * Style to change the opacity of bars in dataviz when we hover on a single bar or legends\n */\n opacityChangeOnHover?: IStyle;\n\n /**\n * styles for the shape object in the callout\n */\n shapeStyles?: IStyle;\n\n /**\n * Styles for the chart wrapper div\n */\n chartWrapper?: IStyle;\n}\n\n/**\n * Cartesian Chart properties\n * {@docCategory CartesianChart}\n */\nexport interface ICartesianChartProps {\n /**\n * Below height used for resizing of the chart\n * Wrap chart in your container and send the updated height and width to these props.\n * These values decide wheather chart re render or not. Please check examples for reference\n */\n height?: number;\n\n /**\n * Below width used for resizing of the chart\n * Wrap chart in your container and send the updated height and width to these props.\n * These values decide wheather chart re render or not. Please check examples for reference\n */\n width?: number;\n\n /**\n * this prop takes its parent as a HTML element to define the width and height of the chart\n */\n parentRef?: HTMLElement | null;\n\n /**\n * Additional CSS class(es) to apply to the Chart.\n */\n className?: string;\n\n /**\n * Theme (provided through customization.)\n */\n theme?: ITheme;\n\n /**\n * Margins for the chart\n * @default `{ top: 20, bottom: 35, left: 40, right: 20 }`\n * To avoid edge cuttings to the chart, we recommend you use default values or greater then default values\n */\n margins?: IMargins;\n\n /** decides wether to show/hide legends\n * @defaultvalue false\n */\n hideLegend?: boolean;\n\n /**\n * Do not show tooltips in chart\n * @default false\n */\n hideTooltip?: boolean;\n\n /**\n * this prop takes values that you want the chart to render on x-axis\n * This is a optional parameter if not specified D3 will decide which values appear on the x-axis for you\n * Please look at https://github.com/d3/d3-scale for more information on how D3 decides what data to appear on the axis of chart\n */\n tickValues?: number[] | Date[];\n\n /**\n * the format for the data on x-axis. For date object this can be specified to your requirement. Eg: '%m/%d', '%d'\n * Please look at https://github.com/d3/d3-time-format for all the formats supported for date axis\n * Only applicable for date axis. For y-axis format use yAxisTickFormat prop.\n */\n tickFormat?: string;\n\n /**\n * Width of line stroke\n */\n strokeWidth?: number;\n\n /**\n * x Axis labels tick padding. This defines the gap between tick labels and tick lines.\n * @default 10\n */\n xAxisTickPadding?: number;\n\n /**\n * the format in for the data on y-axis. For data object this can be specified to your requirement.\n * Eg: d3.format(\".0%\")(0.123),d3.format(\"+20\")(42);\n * Please look at https://github.com/d3/d3-format for all the formats supported\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n yAxisTickFormat?: any;\n\n /**\n * Secondary y-scale options\n * By default this is not defined, meaning there will be no secondary y-scale.\n */\n secondaryYScaleOptions?: {\n /** Minimum value (0 by default) */\n yMinValue?: number;\n /** Maximum value (100 by default) */\n yMaxValue?: number;\n };\n\n /**\n * minimum data value point in y-axis\n */\n yMinValue?: number;\n\n /**\n * maximum data value point in y-axis\n */\n yMaxValue?: number;\n\n /**\n * maximum data value point in x-axis\n */\n xMaxValue?: number;\n\n /**\n * Number of ticks on the y-axis.\n * Tick count should be factor of difference between (yMinValue, yMaxValue)?\n * @default 4\n */\n yAxisTickCount?: number;\n\n /**\n * defines the number of ticks on the x-axis. Tries to match the nearest interval satisfying the count.\n * Does not work for string axis.\n * @default 6\n */\n xAxisTickCount?: number;\n\n /**\n * define the size of the tick lines on the x-axis\n * @default 10\n */\n xAxistickSize?: number;\n\n /**\n * defines the space between the tick line and the data label\n * @default 10\n */\n tickPadding?: number;\n\n /**\n * Url that the data-viz needs to redirect to upon clicking on it\n */\n href?: string;\n\n /**\n * Label to apply to the whole chart.\n * @deprecated - Use your chart label for the chart.\n */\n chartLabel?: string;\n\n /**\n * overflow props for the legends\n */\n legendsOverflowProps?: Partial<IOverflowSetProps>;\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n legendsOverflowText?: any;\n\n /**\n * focus zone props in hover card for legends\n */\n focusZonePropsForLegendsInHoverCard?: IFocusZoneProps;\n\n /**\n * Enable the legends to wrap lines if there is not enough space to show all legends on a single line\n */\n enabledLegendsWrapLines?: boolean;\n\n /*\n * props for the legends in the chart\n */\n legendProps?: Partial<ILegendsProps>;\n\n /**\n *@default false\n *Used for to elipse x axis labes and show tooltip on x axis labels\n */\n showXAxisLablesTooltip?: boolean;\n\n /**\n * @default 4\n * Used for X axis labels\n * While Giving showXAxisLablesTooltip prop, need to define after how many chars, we need to truncate the word.\n */\n noOfCharsToTruncate?: number;\n\n /**\n * @default false\n * Used to wrap x axis labels values (whole value)\n */\n wrapXAxisLables?: boolean;\n\n /**\n * @default false\n * Used to rotate x axis labels by 45 degrees\n */\n rotateXAxisLables?: boolean;\n\n /**\n * The prop used to define the date time localization options\n */\n dateLocalizeOptions?: Intl.DateTimeFormatOptions;\n\n /**\n * The prop used to define a custom locale for the date time format.\n */\n timeFormatLocale?: d3TimeFormat.TimeLocaleDefinition;\n\n /**\n * The prop used to define a custom datetime formatter for date axis.\n */\n customDateTimeFormatter?: (dateTime: Date) => string;\n\n /**\n * Call to provide customized styling that will layer on top of the variant rules.\n */\n styles?: IStyleFunctionOrObject<ICartesianChartStyleProps, ICartesianChartStyles>;\n\n /**\n * Callout customization props\n */\n calloutProps?: Partial<ICalloutProps>;\n\n /**\n * props for the svg; use this to include aria-* or other attributes on the tag\n */\n svgProps?: React.SVGProps<SVGSVGElement>;\n\n /**\n * Prop to disable shrinking of the chart beyond a certain limit and enable scrolling when the chart overflows\n * @default True for LineChart but False for other charts\n */\n enableReflow?: boolean;\n\n /**\n * Prop to set the x axis title\n * @default undefined\n * Minimum bottom margin required for x axis title is 55px\n */\n\n xAxisTitle?: string;\n\n /**\n * Prop to set the y axis title\n * @default undefined\n * Minimum left margin required for y axis title is 60px and for RTL is 40px\n * Minimum right margin required for y axis title is 40px and for RTL is 60px\n */\n yAxisTitle?: string;\n\n /**\n * Prop to set the secondary y axis title\n * @default undefined\n * If RTL is enabled, minimum left and right margins required for secondary y axis title is 60px\n */\n secondaryYAxistitle?: string;\n}\n\nexport interface IYValueHover {\n legend?: string;\n y?: number;\n color?: string;\n data?: string | number;\n shouldDrawBorderBottom?: boolean;\n yAxisCalloutData?: string | { [id: string]: number };\n index?: number;\n callOutAccessibilityData?: IAccessibilityProps;\n}\n\nexport interface IChildProps {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n xScale?: any;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n yScale?: any;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n yScaleSecondary?: any;\n containerHeight?: number;\n containerWidth?: number;\n}\n\n// Only used for Cartesian chart base\nexport interface IModifiedCartesianChartProps extends ICartesianChartProps {\n /**\n * Define the chart title\n */\n chartTitle?: string;\n\n /**\n * Only used for Area chart\n * Value used to draw y axis of that chart.\n */\n maxOfYVal?: number;\n\n /**\n * Data of the chart\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n points: any;\n\n /**\n * Define type of the chart\n */\n chartType: ChartTypes;\n\n /** X axis type */\n xAxisType: XAxisTypes;\n\n /** Y axis type */\n yAxisType?: YAxisType;\n\n /**\n * Legends of the chart.\n */\n legendBars: JSX.Element | null;\n\n /**\n * Callout props\n */\n calloutProps: Partial<ICalloutProps> & {\n isCalloutVisible: boolean;\n id: string;\n YValueHover?: IYValueHover[];\n hoverXValue?: string | number | null;\n legend?: string;\n color?: string;\n YValue?: string | number;\n XValue?: string;\n descriptionMessage?: string;\n };\n\n /**\n * Callback method used for to get margins to the chart.\n */\n getmargins?: (margins: IMargins) => void;\n\n /**\n * This is a call back method to the chart from cartesian chart.\n * params are xScale, yScale, containerHeight, containerWidth. These values were used to draw the graph.\n * It also contians an optional param xAxisElement - defines as x axis scale element.\n * This param used to enable feature word wrap of Xaxis.\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n getGraphData?: any;\n\n /**\n * Used for bar chart graphs.\n * To define width of the bar\n */\n barwidth?: number;\n\n /**\n * Used for tick styles of the x axis of the chart\n * Tick params are applicable for date axis only.\n */\n tickParams?: {\n tickValues?: number[] | Date[];\n tickFormat?: string;\n };\n\n /**\n * it's padding between bar's or lines in the graph\n */\n xAxisPadding?: number;\n\n /**\n * it's padding between bar's or lines in the graph\n */\n yAxisPadding?: number;\n\n /**\n * Children elements specific to derived chart types.\n */\n children(props: IChildProps): React.ReactNode;\n\n /**\n * To enable callout for individualbar or complete stack. Using for only Vertical stacked bar chart.\n * @default false\n * @type \\{boolean \\}\n */\n isCalloutForStack?: boolean;\n\n /** dataset values to find out domain of the String axis\n * Present using for only vertical stacked bar chart and grouped vertical bar chart\n */\n datasetForXAxisDomain?: string[];\n\n /** Own callout design */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n customizedCallout?: any;\n\n /**\n * if the data points for the y-axis is of type string, then we need to give this\n * prop to construct the y-axis\n */\n stringDatasetForYAxisDomain?: string[];\n\n /**\n * Focus zone direction to the chart\n * @default FocusZoneDirection.horizontal\n */\n focusZoneDirection?: FocusZoneDirection;\n\n /**\n * props to send into the chart hover card\n */\n chartHoverProps?: IChartHoverCardProps;\n\n /**\n * props to send to the focuszone\n */\n svgFocusZoneProps?: IFocusZoneProps;\n\n /**\n * The prop used to define the culture to localize the numbers and date\n */\n culture?: string;\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n getAxisData?: any;\n\n /**\n * Callback method used when mouse leaves the chart boundary.\n */\n onChartMouseLeave?: () => void;\n\n /** Callback method to get extra margins for domain */\n getDomainMargins?: (containerWidth: number) => IMargins;\n\n /** Padding between each bar/line-point */\n xAxisInnerPadding?: number;\n\n /** Padding before first bar/line-point and after last bar/line-point */\n xAxisOuterPadding?: number;\n\n /**\n *@default false\n *Used for to elipse y axis labes and show tooltip on x axis labels\n */\n showYAxisLablesTooltip?: boolean;\n\n /**\n *@default false\n *Used for showing complete y axis lables */\n showYAxisLables?: boolean;\n\n /**\n * @default false\n * Used to control the first render cycle Performance optimization code.\n */\n enableFirstRenderOptimization?: boolean;\n}\n"]}
@@ -6,7 +6,7 @@ import { IChartProps, IChartDataPoint } from './index';
6
6
  export interface IDonutChart {
7
7
  }
8
8
  /**
9
- * IDonutChartProps for Donutchart component.
9
+ * Donut Chart properties.
10
10
  * {@docCategory DonutChart}
11
11
  */
12
12
  export interface IDonutChartProps extends ICartesianChartProps {
@@ -49,8 +49,16 @@ export interface IDonutChartProps extends ICartesianChartProps {
49
49
  */
50
50
  hideLabels?: boolean;
51
51
  }
52
+ /**
53
+ * Donut Chart style properties
54
+ * {@docCategory DonutChart}
55
+ */
52
56
  export interface IDonutChartStyleProps extends ICartesianChartStyleProps {
53
57
  }
58
+ /**
59
+ * Donut Chart styles
60
+ * {@docCategory DonutChart}
61
+ */
54
62
  export interface IDonutChartStyles {
55
63
  /**
56
64
  * Style for the root element.
@@ -1 +1 @@
1
- {"version":3,"file":"DonutChart.types.js","sourceRoot":"../src/","sources":["components/DonutChart/DonutChart.types.ts"],"names":[],"mappings":"","sourcesContent":["import { IStyle } from '@fluentui/react/lib/Styling';\nimport { IRenderFunction, IStyleFunctionOrObject } from '@fluentui/react/lib/Utilities';\nimport { ICartesianChartProps, ICartesianChartStyleProps } from '../CommonComponents/index';\nimport { ICalloutProps } from '@fluentui/react/lib/Callout';\nimport { IChartProps, IChartDataPoint } from './index';\n\nexport interface IDonutChart {}\n\n/**\n * IDonutChartProps for Donutchart component.\n * {@docCategory DonutChart}\n */\nexport interface IDonutChartProps extends ICartesianChartProps {\n /**\n * Data to render in the chart.\n */\n data?: IChartProps;\n\n /**\n * inner radius for donut size\n */\n innerRadius?: number;\n\n /**\n * Call to provide customized styling that will layer on top of the variant rules.\n */\n styles?: IStyleFunctionOrObject<IDonutChartStyleProps, IDonutChartStyles>;\n\n /**\n * props for inside donut value\n */\n valueInsideDonut?: string | number;\n\n /**\n * Define a custom callout renderer for a data point\n */\n onRenderCalloutPerDataPoint?: IRenderFunction<IChartDataPoint>;\n\n /**\n * props for the callout in the chart\n */\n calloutProps?: Partial<ICalloutProps>;\n\n /**\n * The prop used to define the culture to localized the numbers\n */\n culture?: string;\n\n /**\n * Prop to show the arc labels in percentage format\n * @default false\n */\n showLabelsInPercent?: boolean;\n\n /**\n * Prop to hide the arc labels\n * @default true\n */\n hideLabels?: boolean;\n}\n\nexport interface IDonutChartStyleProps extends ICartesianChartStyleProps {}\n\nexport interface IDonutChartStyles {\n /**\n * Style for the root element.\n */\n root?: IStyle;\n\n /**\n * Style for the chart.\n */\n chart?: IStyle;\n /**\n * Style for the legend container.\n */\n legendContainer: IStyle;\n}\n"]}
1
+ {"version":3,"file":"DonutChart.types.js","sourceRoot":"../src/","sources":["components/DonutChart/DonutChart.types.ts"],"names":[],"mappings":"","sourcesContent":["import { IStyle } from '@fluentui/react/lib/Styling';\nimport { IRenderFunction, IStyleFunctionOrObject } from '@fluentui/react/lib/Utilities';\nimport { ICartesianChartProps, ICartesianChartStyleProps } from '../CommonComponents/index';\nimport { ICalloutProps } from '@fluentui/react/lib/Callout';\nimport { IChartProps, IChartDataPoint } from './index';\n\nexport interface IDonutChart {}\n\n/**\n * Donut Chart properties.\n * {@docCategory DonutChart}\n */\nexport interface IDonutChartProps extends ICartesianChartProps {\n /**\n * Data to render in the chart.\n */\n data?: IChartProps;\n\n /**\n * inner radius for donut size\n */\n innerRadius?: number;\n\n /**\n * Call to provide customized styling that will layer on top of the variant rules.\n */\n styles?: IStyleFunctionOrObject<IDonutChartStyleProps, IDonutChartStyles>;\n\n /**\n * props for inside donut value\n */\n valueInsideDonut?: string | number;\n\n /**\n * Define a custom callout renderer for a data point\n */\n onRenderCalloutPerDataPoint?: IRenderFunction<IChartDataPoint>;\n\n /**\n * props for the callout in the chart\n */\n calloutProps?: Partial<ICalloutProps>;\n\n /**\n * The prop used to define the culture to localized the numbers\n */\n culture?: string;\n\n /**\n * Prop to show the arc labels in percentage format\n * @default false\n */\n showLabelsInPercent?: boolean;\n\n /**\n * Prop to hide the arc labels\n * @default true\n */\n hideLabels?: boolean;\n}\n\n/**\n * Donut Chart style properties\n * {@docCategory DonutChart}\n */\nexport interface IDonutChartStyleProps extends ICartesianChartStyleProps {}\n\n/**\n * Donut Chart styles\n * {@docCategory DonutChart}\n */\nexport interface IDonutChartStyles {\n /**\n * Style for the root element.\n */\n root?: IStyle;\n\n /**\n * Style for the chart.\n */\n chart?: IStyle;\n /**\n * Style for the legend container.\n */\n legendContainer: IStyle;\n}\n"]}