@fluentui/react-charting 5.25.4 → 5.25.6

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 (379) hide show
  1. package/CHANGELOG.json +107 -1
  2. package/CHANGELOG.md +30 -2
  3. package/bundle-size/PolarChart.fixture.js +7 -0
  4. package/dist/react-charting.d.ts +424 -1
  5. package/dist/react-charting.js +1 -1
  6. package/dist/react-charting.min.js +1 -1
  7. package/etc/react-charting.api.md +93 -1
  8. package/lib/PolarChart.d.ts +1 -0
  9. package/lib/PolarChart.js +2 -0
  10. package/lib/PolarChart.js.map +1 -0
  11. package/lib/components/AnnotationOnlyChart/AnnotationOnlyChart.js +1 -1
  12. package/lib/components/AnnotationOnlyChart/AnnotationOnlyChart.js.map +1 -1
  13. package/lib/components/AreaChart/AreaChart.base.d.ts +0 -1
  14. package/lib/components/AreaChart/AreaChart.base.js +2 -31
  15. package/lib/components/AreaChart/AreaChart.base.js.map +1 -1
  16. package/lib/components/ChartTable/ChartTable.base.js +12 -4
  17. package/lib/components/ChartTable/ChartTable.base.js.map +1 -1
  18. package/lib/components/ChartTable/ChartTable.styles.js +3 -0
  19. package/lib/components/ChartTable/ChartTable.styles.js.map +1 -1
  20. package/lib/components/ChartTable/ChartTable.types.d.ts +11 -0
  21. package/lib/components/ChartTable/ChartTable.types.js.map +1 -1
  22. package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.js +11 -6
  23. package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.js.map +1 -1
  24. package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.styles.d.ts +1 -0
  25. package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.styles.js +17 -1
  26. package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.styles.js.map +1 -1
  27. package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.types.d.ts +5 -0
  28. package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.types.js.map +1 -1
  29. package/lib/components/CommonComponents/CartesianChart.base.d.ts +1 -1
  30. package/lib/components/CommonComponents/CartesianChart.base.js +82 -42
  31. package/lib/components/CommonComponents/CartesianChart.base.js.map +1 -1
  32. package/lib/components/CommonComponents/CartesianChart.styles.js +31 -27
  33. package/lib/components/CommonComponents/CartesianChart.styles.js.map +1 -1
  34. package/lib/components/CommonComponents/CartesianChart.types.d.ts +20 -1
  35. package/lib/components/CommonComponents/CartesianChart.types.js.map +1 -1
  36. package/lib/components/DeclarativeChart/DeclarativeChart.js +24 -28
  37. package/lib/components/DeclarativeChart/DeclarativeChart.js.map +1 -1
  38. package/lib/components/DeclarativeChart/PlotlySchemaAdapter.d.ts +3 -1
  39. package/lib/components/DeclarativeChart/PlotlySchemaAdapter.js +390 -267
  40. package/lib/components/DeclarativeChart/PlotlySchemaAdapter.js.map +1 -1
  41. package/lib/components/DonutChart/DonutChart.base.d.ts +1 -0
  42. package/lib/components/DonutChart/DonutChart.base.js +16 -4
  43. package/lib/components/DonutChart/DonutChart.base.js.map +1 -1
  44. package/lib/components/DonutChart/DonutChart.styles.js +3 -1
  45. package/lib/components/DonutChart/DonutChart.styles.js.map +1 -1
  46. package/lib/components/DonutChart/DonutChart.types.d.ts +13 -0
  47. package/lib/components/DonutChart/DonutChart.types.js.map +1 -1
  48. package/lib/components/DonutChart/Pie/Pie.js +4 -2
  49. package/lib/components/DonutChart/Pie/Pie.js.map +1 -1
  50. package/lib/components/FunnelChart/FunnelChart.base.js +14 -8
  51. package/lib/components/FunnelChart/FunnelChart.base.js.map +1 -1
  52. package/lib/components/FunnelChart/FunnelChart.styles.js +3 -0
  53. package/lib/components/FunnelChart/FunnelChart.styles.js.map +1 -1
  54. package/lib/components/FunnelChart/FunnelChart.types.d.ts +13 -0
  55. package/lib/components/FunnelChart/FunnelChart.types.js.map +1 -1
  56. package/lib/components/GaugeChart/GaugeChart.base.js +2 -2
  57. package/lib/components/GaugeChart/GaugeChart.base.js.map +1 -1
  58. package/lib/components/GaugeChart/GaugeChart.styles.js +16 -22
  59. package/lib/components/GaugeChart/GaugeChart.styles.js.map +1 -1
  60. package/lib/components/GaugeChart/GaugeChart.types.d.ts +9 -0
  61. package/lib/components/GaugeChart/GaugeChart.types.js.map +1 -1
  62. package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.d.ts +0 -1
  63. package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js +6 -18
  64. package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js.map +1 -1
  65. package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.d.ts +2 -0
  66. package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js +55 -5
  67. package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js.map +1 -1
  68. package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.styles.js +12 -1
  69. package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.styles.js.map +1 -1
  70. package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.d.ts +9 -0
  71. package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.js.map +1 -1
  72. package/lib/components/LineChart/LineChart.base.d.ts +0 -1
  73. package/lib/components/LineChart/LineChart.base.js +2 -26
  74. package/lib/components/LineChart/LineChart.base.js.map +1 -1
  75. package/lib/components/PolarChart/PolarChart.base.d.ts +3 -0
  76. package/lib/components/PolarChart/PolarChart.base.js +426 -0
  77. package/lib/components/PolarChart/PolarChart.base.js.map +1 -0
  78. package/lib/components/PolarChart/PolarChart.d.ts +7 -0
  79. package/lib/components/PolarChart/PolarChart.js +9 -0
  80. package/lib/components/PolarChart/PolarChart.js.map +1 -0
  81. package/lib/components/PolarChart/PolarChart.styles.d.ts +2 -0
  82. package/lib/components/PolarChart/PolarChart.styles.js +39 -0
  83. package/lib/components/PolarChart/PolarChart.styles.js.map +1 -0
  84. package/lib/components/PolarChart/PolarChart.types.d.ts +185 -0
  85. package/lib/components/PolarChart/PolarChart.types.js +2 -0
  86. package/lib/components/PolarChart/PolarChart.types.js.map +1 -0
  87. package/lib/components/PolarChart/PolarChart.utils.d.ts +43 -0
  88. package/lib/components/PolarChart/PolarChart.utils.js +180 -0
  89. package/lib/components/PolarChart/PolarChart.utils.js.map +1 -0
  90. package/lib/components/PolarChart/index.d.ts +2 -0
  91. package/lib/components/PolarChart/index.js +3 -0
  92. package/lib/components/PolarChart/index.js.map +1 -0
  93. package/lib/components/SankeyChart/SankeyChart.base.js +10 -3
  94. package/lib/components/SankeyChart/SankeyChart.base.js.map +1 -1
  95. package/lib/components/SankeyChart/SankeyChart.styles.js +3 -0
  96. package/lib/components/SankeyChart/SankeyChart.styles.js.map +1 -1
  97. package/lib/components/SankeyChart/SankeyChart.types.d.ts +18 -0
  98. package/lib/components/SankeyChart/SankeyChart.types.js.map +1 -1
  99. package/lib/components/ScatterChart/ScatterChart.base.js +14 -32
  100. package/lib/components/ScatterChart/ScatterChart.base.js.map +1 -1
  101. package/lib/components/ScatterChart/ScatterChart.types.d.ts +4 -0
  102. package/lib/components/ScatterChart/ScatterChart.types.js.map +1 -1
  103. package/lib/components/VerticalBarChart/VerticalBarChart.base.d.ts +0 -1
  104. package/lib/components/VerticalBarChart/VerticalBarChart.base.js +12 -80
  105. package/lib/components/VerticalBarChart/VerticalBarChart.base.js.map +1 -1
  106. package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.base.d.ts +0 -1
  107. package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js +19 -31
  108. package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js.map +1 -1
  109. package/lib/index.d.ts +2 -0
  110. package/lib/index.js +1 -0
  111. package/lib/index.js.map +1 -1
  112. package/lib/types/IDataPoint.d.ts +107 -0
  113. package/lib/types/IDataPoint.js.map +1 -1
  114. package/lib/utilities/ChartTitle.d.ts +55 -0
  115. package/lib/utilities/ChartTitle.js +45 -0
  116. package/lib/utilities/ChartTitle.js.map +1 -0
  117. package/lib/utilities/Common.styles.d.ts +51 -0
  118. package/lib/utilities/Common.styles.js +70 -1
  119. package/lib/utilities/Common.styles.js.map +1 -1
  120. package/lib/utilities/image-export-utils.js +4 -4
  121. package/lib/utilities/image-export-utils.js.map +1 -1
  122. package/lib/utilities/index.d.ts +1 -0
  123. package/lib/utilities/index.js +1 -0
  124. package/lib/utilities/index.js.map +1 -1
  125. package/lib/utilities/utilities.d.ts +32 -8
  126. package/lib/utilities/utilities.js +232 -111
  127. package/lib/utilities/utilities.js.map +1 -1
  128. package/lib-amd/PolarChart.d.ts +1 -0
  129. package/lib-amd/PolarChart.js +6 -0
  130. package/lib-amd/PolarChart.js.map +1 -0
  131. package/lib-amd/components/AnnotationOnlyChart/AnnotationOnlyChart.js +1 -1
  132. package/lib-amd/components/AnnotationOnlyChart/AnnotationOnlyChart.js.map +1 -1
  133. package/lib-amd/components/AreaChart/AreaChart.base.d.ts +0 -1
  134. package/lib-amd/components/AreaChart/AreaChart.base.js +1 -29
  135. package/lib-amd/components/AreaChart/AreaChart.base.js.map +1 -1
  136. package/lib-amd/components/ChartTable/ChartTable.base.js +12 -5
  137. package/lib-amd/components/ChartTable/ChartTable.base.js.map +1 -1
  138. package/lib-amd/components/ChartTable/ChartTable.styles.js +3 -1
  139. package/lib-amd/components/ChartTable/ChartTable.styles.js.map +1 -1
  140. package/lib-amd/components/ChartTable/ChartTable.types.d.ts +11 -0
  141. package/lib-amd/components/ChartTable/ChartTable.types.js.map +1 -1
  142. package/lib-amd/components/CommonComponents/Annotations/ChartAnnotationLayer.js +11 -6
  143. package/lib-amd/components/CommonComponents/Annotations/ChartAnnotationLayer.js.map +1 -1
  144. package/lib-amd/components/CommonComponents/Annotations/ChartAnnotationLayer.styles.d.ts +1 -0
  145. package/lib-amd/components/CommonComponents/Annotations/ChartAnnotationLayer.styles.js +17 -1
  146. package/lib-amd/components/CommonComponents/Annotations/ChartAnnotationLayer.styles.js.map +1 -1
  147. package/lib-amd/components/CommonComponents/Annotations/ChartAnnotationLayer.types.d.ts +5 -0
  148. package/lib-amd/components/CommonComponents/Annotations/ChartAnnotationLayer.types.js.map +1 -1
  149. package/lib-amd/components/CommonComponents/CartesianChart.base.d.ts +1 -1
  150. package/lib-amd/components/CommonComponents/CartesianChart.base.js +81 -41
  151. package/lib-amd/components/CommonComponents/CartesianChart.base.js.map +1 -1
  152. package/lib-amd/components/CommonComponents/CartesianChart.styles.js +30 -26
  153. package/lib-amd/components/CommonComponents/CartesianChart.styles.js.map +1 -1
  154. package/lib-amd/components/CommonComponents/CartesianChart.types.d.ts +20 -1
  155. package/lib-amd/components/CommonComponents/CartesianChart.types.js.map +1 -1
  156. package/lib-amd/components/DeclarativeChart/DeclarativeChart.js +22 -28
  157. package/lib-amd/components/DeclarativeChart/DeclarativeChart.js.map +1 -1
  158. package/lib-amd/components/DeclarativeChart/PlotlySchemaAdapter.d.ts +3 -1
  159. package/lib-amd/components/DeclarativeChart/PlotlySchemaAdapter.js +392 -269
  160. package/lib-amd/components/DeclarativeChart/PlotlySchemaAdapter.js.map +1 -1
  161. package/lib-amd/components/DonutChart/DonutChart.base.d.ts +1 -0
  162. package/lib-amd/components/DonutChart/DonutChart.base.js +15 -3
  163. package/lib-amd/components/DonutChart/DonutChart.base.js.map +1 -1
  164. package/lib-amd/components/DonutChart/DonutChart.styles.js +2 -0
  165. package/lib-amd/components/DonutChart/DonutChart.styles.js.map +1 -1
  166. package/lib-amd/components/DonutChart/DonutChart.types.d.ts +13 -0
  167. package/lib-amd/components/DonutChart/DonutChart.types.js.map +1 -1
  168. package/lib-amd/components/DonutChart/Pie/Pie.js +4 -2
  169. package/lib-amd/components/DonutChart/Pie/Pie.js.map +1 -1
  170. package/lib-amd/components/FunnelChart/FunnelChart.base.js +14 -9
  171. package/lib-amd/components/FunnelChart/FunnelChart.base.js.map +1 -1
  172. package/lib-amd/components/FunnelChart/FunnelChart.styles.js +3 -1
  173. package/lib-amd/components/FunnelChart/FunnelChart.styles.js.map +1 -1
  174. package/lib-amd/components/FunnelChart/FunnelChart.types.d.ts +13 -0
  175. package/lib-amd/components/FunnelChart/FunnelChart.types.js.map +1 -1
  176. package/lib-amd/components/GaugeChart/GaugeChart.base.js +1 -1
  177. package/lib-amd/components/GaugeChart/GaugeChart.base.js.map +1 -1
  178. package/lib-amd/components/GaugeChart/GaugeChart.styles.js +16 -23
  179. package/lib-amd/components/GaugeChart/GaugeChart.styles.js.map +1 -1
  180. package/lib-amd/components/GaugeChart/GaugeChart.types.d.ts +9 -0
  181. package/lib-amd/components/GaugeChart/GaugeChart.types.js.map +1 -1
  182. package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.d.ts +0 -1
  183. package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js +4 -16
  184. package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js.map +1 -1
  185. package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.d.ts +2 -0
  186. package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js +54 -4
  187. package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js.map +1 -1
  188. package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.styles.js +12 -2
  189. package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.styles.js.map +1 -1
  190. package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.d.ts +9 -0
  191. package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.js.map +1 -1
  192. package/lib-amd/components/LineChart/LineChart.base.d.ts +0 -1
  193. package/lib-amd/components/LineChart/LineChart.base.js +1 -25
  194. package/lib-amd/components/LineChart/LineChart.base.js.map +1 -1
  195. package/lib-amd/components/PolarChart/PolarChart.base.d.ts +3 -0
  196. package/lib-amd/components/PolarChart/PolarChart.base.js +421 -0
  197. package/lib-amd/components/PolarChart/PolarChart.base.js.map +1 -0
  198. package/lib-amd/components/PolarChart/PolarChart.d.ts +7 -0
  199. package/lib-amd/components/PolarChart/PolarChart.js +11 -0
  200. package/lib-amd/components/PolarChart/PolarChart.js.map +1 -0
  201. package/lib-amd/components/PolarChart/PolarChart.styles.d.ts +2 -0
  202. package/lib-amd/components/PolarChart/PolarChart.styles.js +43 -0
  203. package/lib-amd/components/PolarChart/PolarChart.styles.js.map +1 -0
  204. package/lib-amd/components/PolarChart/PolarChart.types.d.ts +185 -0
  205. package/lib-amd/components/PolarChart/PolarChart.types.js +5 -0
  206. package/lib-amd/components/PolarChart/PolarChart.types.js.map +1 -0
  207. package/lib-amd/components/PolarChart/PolarChart.utils.d.ts +43 -0
  208. package/lib-amd/components/PolarChart/PolarChart.utils.js +183 -0
  209. package/lib-amd/components/PolarChart/PolarChart.utils.js.map +1 -0
  210. package/lib-amd/components/PolarChart/index.d.ts +2 -0
  211. package/lib-amd/components/PolarChart/index.js +7 -0
  212. package/lib-amd/components/PolarChart/index.js.map +1 -0
  213. package/lib-amd/components/SankeyChart/SankeyChart.base.js +10 -4
  214. package/lib-amd/components/SankeyChart/SankeyChart.base.js.map +1 -1
  215. package/lib-amd/components/SankeyChart/SankeyChart.styles.js +3 -1
  216. package/lib-amd/components/SankeyChart/SankeyChart.styles.js.map +1 -1
  217. package/lib-amd/components/SankeyChart/SankeyChart.types.d.ts +18 -0
  218. package/lib-amd/components/SankeyChart/SankeyChart.types.js.map +1 -1
  219. package/lib-amd/components/ScatterChart/ScatterChart.base.js +13 -31
  220. package/lib-amd/components/ScatterChart/ScatterChart.base.js.map +1 -1
  221. package/lib-amd/components/ScatterChart/ScatterChart.types.d.ts +4 -0
  222. package/lib-amd/components/ScatterChart/ScatterChart.types.js.map +1 -1
  223. package/lib-amd/components/VerticalBarChart/VerticalBarChart.base.d.ts +0 -1
  224. package/lib-amd/components/VerticalBarChart/VerticalBarChart.base.js +12 -79
  225. package/lib-amd/components/VerticalBarChart/VerticalBarChart.base.js.map +1 -1
  226. package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.base.d.ts +0 -1
  227. package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js +19 -30
  228. package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js.map +1 -1
  229. package/lib-amd/index.d.ts +2 -0
  230. package/lib-amd/index.js +3 -2
  231. package/lib-amd/index.js.map +1 -1
  232. package/lib-amd/types/IDataPoint.d.ts +107 -0
  233. package/lib-amd/types/IDataPoint.js.map +1 -1
  234. package/lib-amd/utilities/ChartTitle.d.ts +55 -0
  235. package/lib-amd/utilities/ChartTitle.js +46 -0
  236. package/lib-amd/utilities/ChartTitle.js.map +1 -0
  237. package/lib-amd/utilities/Common.styles.d.ts +51 -0
  238. package/lib-amd/utilities/Common.styles.js +74 -2
  239. package/lib-amd/utilities/Common.styles.js.map +1 -1
  240. package/lib-amd/utilities/image-export-utils.js +3 -3
  241. package/lib-amd/utilities/image-export-utils.js.map +1 -1
  242. package/lib-amd/utilities/index.d.ts +1 -0
  243. package/lib-amd/utilities/index.js +2 -1
  244. package/lib-amd/utilities/index.js.map +1 -1
  245. package/lib-amd/utilities/utilities.d.ts +32 -8
  246. package/lib-amd/utilities/utilities.js +239 -114
  247. package/lib-amd/utilities/utilities.js.map +1 -1
  248. package/lib-commonjs/PolarChart.d.ts +1 -0
  249. package/lib-commonjs/PolarChart.js +5 -0
  250. package/lib-commonjs/PolarChart.js.map +1 -0
  251. package/lib-commonjs/components/AnnotationOnlyChart/AnnotationOnlyChart.js +1 -1
  252. package/lib-commonjs/components/AnnotationOnlyChart/AnnotationOnlyChart.js.map +1 -1
  253. package/lib-commonjs/components/AreaChart/AreaChart.base.d.ts +0 -1
  254. package/lib-commonjs/components/AreaChart/AreaChart.base.js +0 -29
  255. package/lib-commonjs/components/AreaChart/AreaChart.base.js.map +1 -1
  256. package/lib-commonjs/components/ChartTable/ChartTable.base.js +12 -4
  257. package/lib-commonjs/components/ChartTable/ChartTable.base.js.map +1 -1
  258. package/lib-commonjs/components/ChartTable/ChartTable.styles.js +3 -0
  259. package/lib-commonjs/components/ChartTable/ChartTable.styles.js.map +1 -1
  260. package/lib-commonjs/components/ChartTable/ChartTable.types.d.ts +11 -0
  261. package/lib-commonjs/components/ChartTable/ChartTable.types.js.map +1 -1
  262. package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.js +11 -6
  263. package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.js.map +1 -1
  264. package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.styles.d.ts +1 -0
  265. package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.styles.js +17 -1
  266. package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.styles.js.map +1 -1
  267. package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.types.d.ts +5 -0
  268. package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.types.js.map +1 -1
  269. package/lib-commonjs/components/CommonComponents/CartesianChart.base.d.ts +1 -1
  270. package/lib-commonjs/components/CommonComponents/CartesianChart.base.js +81 -41
  271. package/lib-commonjs/components/CommonComponents/CartesianChart.base.js.map +1 -1
  272. package/lib-commonjs/components/CommonComponents/CartesianChart.styles.js +30 -26
  273. package/lib-commonjs/components/CommonComponents/CartesianChart.styles.js.map +1 -1
  274. package/lib-commonjs/components/CommonComponents/CartesianChart.types.d.ts +20 -1
  275. package/lib-commonjs/components/CommonComponents/CartesianChart.types.js.map +1 -1
  276. package/lib-commonjs/components/DeclarativeChart/DeclarativeChart.js +23 -27
  277. package/lib-commonjs/components/DeclarativeChart/DeclarativeChart.js.map +1 -1
  278. package/lib-commonjs/components/DeclarativeChart/PlotlySchemaAdapter.d.ts +3 -1
  279. package/lib-commonjs/components/DeclarativeChart/PlotlySchemaAdapter.js +392 -269
  280. package/lib-commonjs/components/DeclarativeChart/PlotlySchemaAdapter.js.map +1 -1
  281. package/lib-commonjs/components/DonutChart/DonutChart.base.d.ts +1 -0
  282. package/lib-commonjs/components/DonutChart/DonutChart.base.js +15 -3
  283. package/lib-commonjs/components/DonutChart/DonutChart.base.js.map +1 -1
  284. package/lib-commonjs/components/DonutChart/DonutChart.styles.js +2 -0
  285. package/lib-commonjs/components/DonutChart/DonutChart.styles.js.map +1 -1
  286. package/lib-commonjs/components/DonutChart/DonutChart.types.d.ts +13 -0
  287. package/lib-commonjs/components/DonutChart/DonutChart.types.js.map +1 -1
  288. package/lib-commonjs/components/DonutChart/Pie/Pie.js +4 -2
  289. package/lib-commonjs/components/DonutChart/Pie/Pie.js.map +1 -1
  290. package/lib-commonjs/components/FunnelChart/FunnelChart.base.js +14 -8
  291. package/lib-commonjs/components/FunnelChart/FunnelChart.base.js.map +1 -1
  292. package/lib-commonjs/components/FunnelChart/FunnelChart.styles.js +3 -0
  293. package/lib-commonjs/components/FunnelChart/FunnelChart.styles.js.map +1 -1
  294. package/lib-commonjs/components/FunnelChart/FunnelChart.types.d.ts +13 -0
  295. package/lib-commonjs/components/FunnelChart/FunnelChart.types.js.map +1 -1
  296. package/lib-commonjs/components/GaugeChart/GaugeChart.base.js +1 -1
  297. package/lib-commonjs/components/GaugeChart/GaugeChart.base.js.map +1 -1
  298. package/lib-commonjs/components/GaugeChart/GaugeChart.styles.js +16 -22
  299. package/lib-commonjs/components/GaugeChart/GaugeChart.styles.js.map +1 -1
  300. package/lib-commonjs/components/GaugeChart/GaugeChart.types.d.ts +9 -0
  301. package/lib-commonjs/components/GaugeChart/GaugeChart.types.js.map +1 -1
  302. package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.d.ts +0 -1
  303. package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js +4 -16
  304. package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js.map +1 -1
  305. package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.d.ts +2 -0
  306. package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js +54 -4
  307. package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js.map +1 -1
  308. package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.styles.js +12 -1
  309. package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.styles.js.map +1 -1
  310. package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.d.ts +9 -0
  311. package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.js.map +1 -1
  312. package/lib-commonjs/components/LineChart/LineChart.base.d.ts +0 -1
  313. package/lib-commonjs/components/LineChart/LineChart.base.js +1 -25
  314. package/lib-commonjs/components/LineChart/LineChart.base.js.map +1 -1
  315. package/lib-commonjs/components/PolarChart/PolarChart.base.d.ts +3 -0
  316. package/lib-commonjs/components/PolarChart/PolarChart.base.js +429 -0
  317. package/lib-commonjs/components/PolarChart/PolarChart.base.js.map +1 -0
  318. package/lib-commonjs/components/PolarChart/PolarChart.d.ts +7 -0
  319. package/lib-commonjs/components/PolarChart/PolarChart.js +12 -0
  320. package/lib-commonjs/components/PolarChart/PolarChart.js.map +1 -0
  321. package/lib-commonjs/components/PolarChart/PolarChart.styles.d.ts +2 -0
  322. package/lib-commonjs/components/PolarChart/PolarChart.styles.js +43 -0
  323. package/lib-commonjs/components/PolarChart/PolarChart.styles.js.map +1 -0
  324. package/lib-commonjs/components/PolarChart/PolarChart.types.d.ts +185 -0
  325. package/lib-commonjs/components/PolarChart/PolarChart.types.js +3 -0
  326. package/lib-commonjs/components/PolarChart/PolarChart.types.js.map +1 -0
  327. package/lib-commonjs/components/PolarChart/PolarChart.utils.d.ts +43 -0
  328. package/lib-commonjs/components/PolarChart/PolarChart.utils.js +188 -0
  329. package/lib-commonjs/components/PolarChart/PolarChart.utils.js.map +1 -0
  330. package/lib-commonjs/components/PolarChart/index.d.ts +2 -0
  331. package/lib-commonjs/components/PolarChart/index.js +6 -0
  332. package/lib-commonjs/components/PolarChart/index.js.map +1 -0
  333. package/lib-commonjs/components/SankeyChart/SankeyChart.base.js +10 -3
  334. package/lib-commonjs/components/SankeyChart/SankeyChart.base.js.map +1 -1
  335. package/lib-commonjs/components/SankeyChart/SankeyChart.styles.js +3 -0
  336. package/lib-commonjs/components/SankeyChart/SankeyChart.styles.js.map +1 -1
  337. package/lib-commonjs/components/SankeyChart/SankeyChart.types.d.ts +18 -0
  338. package/lib-commonjs/components/SankeyChart/SankeyChart.types.js.map +1 -1
  339. package/lib-commonjs/components/ScatterChart/ScatterChart.base.js +13 -31
  340. package/lib-commonjs/components/ScatterChart/ScatterChart.base.js.map +1 -1
  341. package/lib-commonjs/components/ScatterChart/ScatterChart.types.d.ts +4 -0
  342. package/lib-commonjs/components/ScatterChart/ScatterChart.types.js.map +1 -1
  343. package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.base.d.ts +0 -1
  344. package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.base.js +11 -79
  345. package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.base.js.map +1 -1
  346. package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.base.d.ts +0 -1
  347. package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js +18 -30
  348. package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js.map +1 -1
  349. package/lib-commonjs/index.d.ts +2 -0
  350. package/lib-commonjs/index.js +3 -1
  351. package/lib-commonjs/index.js.map +1 -1
  352. package/lib-commonjs/types/IDataPoint.d.ts +107 -0
  353. package/lib-commonjs/types/IDataPoint.js.map +1 -1
  354. package/lib-commonjs/utilities/ChartTitle.d.ts +55 -0
  355. package/lib-commonjs/utilities/ChartTitle.js +49 -0
  356. package/lib-commonjs/utilities/ChartTitle.js.map +1 -0
  357. package/lib-commonjs/utilities/Common.styles.d.ts +51 -0
  358. package/lib-commonjs/utilities/Common.styles.js +74 -2
  359. package/lib-commonjs/utilities/Common.styles.js.map +1 -1
  360. package/lib-commonjs/utilities/image-export-utils.js +3 -3
  361. package/lib-commonjs/utilities/image-export-utils.js.map +1 -1
  362. package/lib-commonjs/utilities/index.d.ts +1 -0
  363. package/lib-commonjs/utilities/index.js +1 -0
  364. package/lib-commonjs/utilities/index.js.map +1 -1
  365. package/lib-commonjs/utilities/utilities.d.ts +32 -8
  366. package/lib-commonjs/utilities/utilities.js +239 -114
  367. package/lib-commonjs/utilities/utilities.js.map +1 -1
  368. package/package.json +4 -12
  369. package/project.json +0 -1
  370. package/src/components/ChartTable/ChartTable.types.ts +13 -0
  371. package/src/components/CommonComponents/Annotations/ChartAnnotationLayer.types.ts +5 -0
  372. package/src/components/CommonComponents/CartesianChart.types.ts +22 -1
  373. package/src/components/DonutChart/DonutChart.types.ts +16 -0
  374. package/src/components/FunnelChart/FunnelChart.types.ts +16 -0
  375. package/src/components/GaugeChart/GaugeChart.types.ts +11 -0
  376. package/src/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.ts +11 -0
  377. package/src/components/PolarChart/PolarChart.types.ts +232 -0
  378. package/src/components/SankeyChart/SankeyChart.types.ts +22 -0
  379. package/src/components/ScatterChart/ScatterChart.types.ts +5 -0
@@ -6,9 +6,11 @@
6
6
 
7
7
  import { CurveFactory } from 'd3-shape';
8
8
  import { FocusZoneDirection } from '@fluentui/react-focus';
9
+ import type { Font } from '@fluentui/chart-utilities';
9
10
  import { ICalloutContentStyleProps } from '@fluentui/react/lib/Callout';
10
11
  import { ICalloutContentStyles } from '@fluentui/react/lib/Callout';
11
12
  import { ICalloutProps } from '@fluentui/react/lib/Callout';
13
+ import { ICalloutProps as ICalloutProps_2 } from '@fluentui/react';
12
14
  import { IFocusZoneProps } from '@fluentui/react-focus';
13
15
  import { IHoverCardStyleProps } from '@fluentui/react/lib/HoverCard';
14
16
  import { IHoverCardStyles } from '@fluentui/react/lib/HoverCard';
@@ -447,10 +449,14 @@ export interface ICartesianChartProps {
447
449
  tickPadding?: number;
448
450
  tickValues?: number[] | Date[] | string[];
449
451
  timeFormatLocale?: TimeLocaleDefinition;
452
+ // Warning: (ae-forgotten-export) The symbol "ITitleStyles" needs to be exported by the entry point index.d.ts
453
+ titleStyles?: ITitleStyles;
450
454
  useUTC?: boolean;
451
455
  width?: number;
452
456
  wrapXAxisLables?: boolean;
453
- xAxis?: AxisProps;
457
+ xAxis?: AxisProps & {
458
+ tickLayout?: 'default' | 'auto';
459
+ };
454
460
  xAxisAnnotation?: string;
455
461
  xAxisCategoryOrder?: AxisCategoryOrder;
456
462
  xAxisTickCount?: number;
@@ -458,6 +464,7 @@ export interface ICartesianChartProps {
458
464
  xAxistickSize?: number;
459
465
  xAxisTitle?: string;
460
466
  xMaxValue?: number;
467
+ xMinValue?: number;
461
468
  xScaleType?: AxisScaleType;
462
469
  yAxis?: AxisProps;
463
470
  yAxisAnnotation?: string;
@@ -587,6 +594,7 @@ export interface IChartProps {
587
594
 
588
595
  // @public
589
596
  export interface IChartTableProps {
597
+ chartTitle?: string;
590
598
  className?: string;
591
599
  componentRef?: IRefObject<IChart>;
592
600
  headers: {
@@ -600,6 +608,7 @@ export interface IChartTableProps {
600
608
  }[][];
601
609
  styles?: IStyleFunctionOrObject<IChartTableStyleProps, IChartTableStyles>;
602
610
  theme?: ITheme;
611
+ titleStyles?: ITitleStyles;
603
612
  width?: string | number;
604
613
  }
605
614
 
@@ -618,10 +627,14 @@ export interface IChartTableStyles {
618
627
  // (undocumented)
619
628
  chart?: IStyle;
620
629
  // (undocumented)
630
+ chartTitle?: IStyle;
631
+ // (undocumented)
621
632
  headerCell?: IStyle;
622
633
  // (undocumented)
623
634
  root?: IStyle;
624
635
  // (undocumented)
636
+ svgTooltip?: IStyle;
637
+ // (undocumented)
625
638
  table?: IStyle;
626
639
  }
627
640
 
@@ -740,6 +753,7 @@ export interface IDonutChartProps extends ICartesianChartProps {
740
753
  roundCorners?: boolean;
741
754
  showLabelsInPercent?: boolean;
742
755
  styles?: IStyleFunctionOrObject<IDonutChartStyleProps, IDonutChartStyles>;
756
+ titleStyles?: ITitleStyles;
743
757
  valueInsideDonut?: string | number;
744
758
  }
745
759
 
@@ -751,9 +765,11 @@ export interface IDonutChartStyleProps extends ICartesianChartStyleProps {
751
765
  export interface IDonutChartStyles {
752
766
  axisAnnotation?: IStyle;
753
767
  chart?: IStyle;
768
+ chartTitle?: IStyle;
754
769
  chartWrapper?: IStyle;
755
770
  legendContainer: IStyle;
756
771
  root?: IStyle;
772
+ svgTooltip?: IStyle;
757
773
  }
758
774
 
759
775
  // @public (undocumented)
@@ -789,6 +805,7 @@ export interface IFunnelChartProps {
789
805
  orientation?: 'horizontal' | 'vertical';
790
806
  styles?: IStyleFunctionOrObject<IFunnelChartStyleProps, IFunnelChartStyles>;
791
807
  theme?: ITheme;
808
+ titleStyles?: ITitleStyles;
792
809
  width?: number;
793
810
  }
794
811
 
@@ -803,10 +820,12 @@ export interface IFunnelChartStyleProps {
803
820
  // @public
804
821
  export interface IFunnelChartStyles {
805
822
  chart?: IStyle;
823
+ chartTitle?: IStyle;
806
824
  root?: IStyle;
807
825
  subComponentStyles: {
808
826
  calloutStyles: IStyleFunctionOrObject<ICalloutContentStyleProps, ICalloutContentStyles>;
809
827
  };
828
+ svgTooltip?: IStyle;
810
829
  text?: IStyle;
811
830
  }
812
831
 
@@ -871,6 +890,7 @@ export interface IGaugeChartProps {
871
890
  styles?: IStyleFunctionOrObject<IGaugeChartStyleProps, IGaugeChartStyles>;
872
891
  sublabel?: string;
873
892
  theme?: ITheme;
893
+ titleStyles?: ITitleStyles;
874
894
  variant?: GaugeChartVariant;
875
895
  width?: number;
876
896
  }
@@ -920,6 +940,7 @@ export interface IGaugeChartStyles {
920
940
  segment?: IStyle;
921
941
  shapeStyles?: IStyle;
922
942
  sublabel?: IStyle;
943
+ svgTooltip?: IStyle;
923
944
  }
924
945
 
925
946
  // @public (undocumented)
@@ -970,6 +991,7 @@ export interface IGroupedVerticalBarChartStyles extends ICartesianChartStyles {
970
991
 
971
992
  // @public (undocumented)
972
993
  export interface IGVBarChartSeriesPoint {
994
+ barLabel?: string;
973
995
  callOutAccessibilityData?: IAccessibilityProps;
974
996
  color?: string;
975
997
  data: number;
@@ -1106,6 +1128,7 @@ export interface IHorizontalBarChartStyles {
1106
1128
 
1107
1129
  // @public (undocumented)
1108
1130
  export interface IHorizontalBarChartWithAxisDataPoint {
1131
+ barLabel?: string;
1109
1132
  callOutAccessibilityData?: IAccessibilityProps;
1110
1133
  color?: string;
1111
1134
  gradient?: [string, string];
@@ -1125,6 +1148,7 @@ export interface IHorizontalBarChartWithAxisProps extends ICartesianChartProps {
1125
1148
  culture?: string;
1126
1149
  data?: IHorizontalBarChartWithAxisDataPoint[];
1127
1150
  enableGradient?: boolean;
1151
+ hideLabels?: boolean;
1128
1152
  onRenderCalloutPerDataPoint?: IRenderFunction<IHorizontalBarChartWithAxisDataPoint>;
1129
1153
  roundCorners?: boolean;
1130
1154
  styles?: IStyleFunctionOrObject<IHorizontalBarChartWithAxisStyleProps, IHorizontalBarChartWithAxisStyles>;
@@ -1139,6 +1163,7 @@ export interface IHorizontalBarChartWithAxisStyleProps extends ICartesianChartSt
1139
1163
 
1140
1164
  // @public
1141
1165
  export interface IHorizontalBarChartWithAxisStyles extends ICartesianChartStyles {
1166
+ barLabel?: IStyle;
1142
1167
  chartLabel?: IStyle;
1143
1168
  opacityChangeOnHover: IStyle;
1144
1169
  xAxisDomain?: IStyle;
@@ -1524,6 +1549,52 @@ export interface IPieChartStyles {
1524
1549
  root?: IStyle;
1525
1550
  }
1526
1551
 
1552
+ // @public
1553
+ export interface IPolarChartProps {
1554
+ angularAxis?: PolarAxisProps & {
1555
+ unit?: 'radians' | 'degrees';
1556
+ };
1557
+ calloutProps?: Partial<ICalloutProps_2>;
1558
+ chartTitle?: string;
1559
+ componentRef?: React_2.Ref<IChart>;
1560
+ culture?: string;
1561
+ // Warning: (ae-forgotten-export) The symbol "IAreaPolarSeries" needs to be exported by the entry point index.d.ts
1562
+ // Warning: (ae-forgotten-export) The symbol "ILinePolarSeries" needs to be exported by the entry point index.d.ts
1563
+ // Warning: (ae-forgotten-export) The symbol "IScatterPolarSeries" needs to be exported by the entry point index.d.ts
1564
+ data: (IAreaPolarSeries | ILinePolarSeries | IScatterPolarSeries)[];
1565
+ dateLocalizeOptions?: Intl.DateTimeFormatOptions;
1566
+ direction?: 'clockwise' | 'counterclockwise';
1567
+ height?: number;
1568
+ hideLegend?: boolean;
1569
+ hideTooltip?: boolean;
1570
+ hole?: number;
1571
+ // (undocumented)
1572
+ legendProps?: Partial<ILegendsProps>;
1573
+ margins?: IMargins;
1574
+ radialAxis?: PolarAxisProps;
1575
+ shape?: 'circle' | 'polygon';
1576
+ styles?: IStyleFunctionOrObject_2<IPolarChartStyleProps, IPolarChartStyles>;
1577
+ theme?: ITheme_2;
1578
+ useUTC?: boolean;
1579
+ width?: number;
1580
+ }
1581
+
1582
+ // @public
1583
+ export interface IPolarChartStyleProps {
1584
+ theme: ITheme_2;
1585
+ }
1586
+
1587
+ // @public
1588
+ export interface IPolarChartStyles {
1589
+ chart?: IStyle_2;
1590
+ chartWrapper?: IStyle_2;
1591
+ gridLineInner?: IStyle_2;
1592
+ gridLineOuter?: IStyle_2;
1593
+ legendContainer?: IStyle_2;
1594
+ root?: IStyle_2;
1595
+ tickLabel?: IStyle_2;
1596
+ }
1597
+
1527
1598
  // @public (undocumented)
1528
1599
  export interface IRefArrayData {
1529
1600
  // (undocumented)
@@ -1583,12 +1654,14 @@ export interface ISankeyChartProps {
1583
1654
  enableReflow?: boolean;
1584
1655
  formatNumberOptions?: Intl.NumberFormatOptions;
1585
1656
  height?: number;
1657
+ hideLegend?: boolean;
1586
1658
  parentRef?: HTMLElement | null;
1587
1659
  pathColor?: string;
1588
1660
  shouldResize?: number;
1589
1661
  strings?: ISankeyChartStrings;
1590
1662
  styles?: IStyleFunctionOrObject<ISankeyChartStyleProps, ISankeyChartStyles>;
1591
1663
  theme?: ITheme;
1664
+ titleStyles?: ITitleStyles;
1592
1665
  width?: number;
1593
1666
  }
1594
1667
 
@@ -1617,11 +1690,13 @@ export interface ISankeyChartStyleProps {
1617
1690
  export interface ISankeyChartStyles {
1618
1691
  calloutContentRoot?: IStyle;
1619
1692
  chart?: IStyle;
1693
+ chartTitle?: IStyle;
1620
1694
  chartWrapper?: IStyle;
1621
1695
  links?: IStyle;
1622
1696
  nodes?: IStyle;
1623
1697
  nodeTextContainer?: IStyle;
1624
1698
  root?: IStyle;
1699
+ svgTooltip?: IStyle;
1625
1700
  toolTip?: IStyle;
1626
1701
  }
1627
1702
 
@@ -1649,6 +1724,7 @@ export interface IScatterChartProps extends ICartesianChartProps {
1649
1724
  data: IChartProps;
1650
1725
  getCalloutDescriptionMessage?: (calloutDataProps: ICustomizedCalloutData) => string | undefined;
1651
1726
  onRenderCalloutPerDataPoint?: IRenderFunction<ICustomizedCalloutData>;
1727
+ onRenderCalloutPerStack?: IRenderFunction<ICustomizedCalloutData>;
1652
1728
  styles?: IScatterChartStyles;
1653
1729
  }
1654
1730
 
@@ -1827,6 +1903,7 @@ export interface ITreeStyles {
1827
1903
 
1828
1904
  // @public (undocumented)
1829
1905
  export interface IVerticalBarChartDataPoint {
1906
+ barLabel?: string;
1830
1907
  callOutAccessibilityData?: IAccessibilityProps;
1831
1908
  color?: string;
1832
1909
  gradient?: [string, string];
@@ -1957,6 +2034,7 @@ export interface IVerticalStackedChartProps {
1957
2034
 
1958
2035
  // @public (undocumented)
1959
2036
  export interface IVSChartDataPoint {
2037
+ barLabel?: string;
1960
2038
  callOutAccessibilityData?: IAccessibilityProps;
1961
2039
  color?: string;
1962
2040
  data: number | string;
@@ -2020,6 +2098,20 @@ export enum NodesComposition {
2020
2098
  // @public
2021
2099
  export const PieChart: React_2.FunctionComponent<IPieChartProps>;
2022
2100
 
2101
+ // @public
2102
+ export type PolarAxisProps = AxisProps & {
2103
+ tickValues?: number[] | Date[] | string[];
2104
+ tickFormat?: string;
2105
+ tickCount?: number;
2106
+ categoryOrder?: AxisCategoryOrder;
2107
+ scaleType?: AxisScaleType;
2108
+ rangeStart?: number | Date;
2109
+ rangeEnd?: number | Date;
2110
+ };
2111
+
2112
+ // @public
2113
+ export const PolarChart: React_2.FunctionComponent<IPolarChartProps>;
2114
+
2023
2115
  // @public
2024
2116
  export const ResponsiveContainer: React_2.FC<IResponsiveContainerProps>;
2025
2117
 
@@ -0,0 +1 @@
1
+ export * from './components/PolarChart/index';
@@ -0,0 +1,2 @@
1
+ export * from './components/PolarChart/index';
2
+ //# sourceMappingURL=PolarChart.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PolarChart.js","sourceRoot":"../src/","sources":["PolarChart.ts"],"names":[],"mappings":"AAAA,cAAc,+BAA+B,CAAC","sourcesContent":["export * from './components/PolarChart/index';\n"]}
@@ -152,7 +152,7 @@ export var AnnotationOnlyChart = function (props) {
152
152
  React.createElement("foreignObject", { x: 0, y: 0, width: resolvedWidth, height: svgHeight },
153
153
  React.createElement("div", { ref: contentRef, className: rootClassName, "data-chart-annotation-only": "true", "aria-label": ariaLabel },
154
154
  chartTitle && (React.createElement("span", { className: titleClassName, "aria-hidden": "true" }, chartTitle)),
155
- React.createElement("div", { className: contentClassName, role: "presentation" }, hasAnnotations ? (React.createElement(ChartAnnotationLayer, { annotations: resolvedAnnotations, context: context, theme: theme })) : null))))));
155
+ React.createElement("div", { className: contentClassName, role: "presentation" }, hasAnnotations ? (React.createElement(ChartAnnotationLayer, { annotations: resolvedAnnotations, context: context, theme: theme, hideDefaultStyles: true })) : null))))));
156
156
  };
157
157
  AnnotationOnlyChart.displayName = 'AnnotationOnlyChart';
158
158
  //# sourceMappingURL=AnnotationOnlyChart.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"AnnotationOnlyChart.js","sourceRoot":"../src/","sources":["components/AnnotationOnlyChart/AnnotationOnlyChart.tsx"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AE,SAAS,EAAE,MAAM,EAAE,EAAE,IAAI,CAAC,CAAC;YAC/F,CAAC;SACF,CAAC;QAEF,OAAO,WAAW,CAAC;IACrB,CAAC,EACD,EAAE,CACH,CAAC;IAEF,OAAO,CACL,6BAAK,GAAG,EAAE,YAAY,qCAAkC,MAAM;QAC5D,6BACE,KAAK,EAAE,aAAa,EACpB,MAAM,EAAE,SAAS,EACjB,OAAO,EAAE,cAAO,aAAa,cAAI,SAAS,CAAE,EAC5C,KAAK,EAAE,EAAE,KAAK,EAAE,KAAK,CAAC,CAAC,CAAC,UAAG,KAAK,OAAI,CAAC,CAAC,CAAC,MAAM,EAAE,MAAM,EAAE,UAAG,SAAS,OAAI,EAAE,OAAO,EAAE,OAAO,EAAE,EAC3F,IAAI,EAAE,SAAS,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,SAAS,gBACvB,SAAS;YAErB,uCAAe,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,KAAK,EAAE,aAAa,EAAE,MAAM,EAAE,SAAS;gBAChE,6BAAK,GAAG,EAAE,UAAU,EAAE,SAAS,EAAE,aAAa,gCAA6B,MAAM,gBAAa,SAAS;oBACpG,UAAU,IAAI,CACb,8BAAM,SAAS,EAAE,cAAc,iBAAc,MAAM,IAChD,UAAU,CACN,CACR;oBACD,6BAAK,SAAS,EAAE,gBAAgB,EAAE,IAAI,EAAC,cAAc,IAClD,cAAc,CAAC,CAAC,CAAC,CAChB,oBAAC,oBAAoB,IAAC,WAAW,EAAE,mBAAmB,EAAE,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,KAAK,GAAI,CAC3F,CAAC,CAAC,CAAC,IAAI,CACJ,CACF,CACQ,CACZ,CACF,CACP,CAAC;AACJ,CAAC,CAAC;AAEF,mBAAmB,CAAC,WAAW,GAAG,qBAAqB,CAAC","sourcesContent":["import * as React from 'react';\nimport { getRTL, useTheme } from '@fluentui/react';\nimport { mergeStyles } from '@fluentui/react/lib/Styling';\nimport { ChartAnnotationLayer } from '../CommonComponents/Annotations/ChartAnnotationLayer';\nimport { exportChartsAsImage } from '../../utilities/image-export-utils';\nimport type { IAnnotationOnlyChartProps } from './AnnotationOnlyChart.types';\nimport type { IChart, IImageExportOptions } from '../../types/index';\nimport type { IChartAnnotationContext } from '../CommonComponents/Annotations/ChartAnnotationLayer.types';\n\nconst DEFAULT_HEIGHT = 650;\nconst FALLBACK_WIDTH = 400;\n\nconst buildPadding = (margin: IAnnotationOnlyChartProps['margin']): string | undefined => {\n if (!margin) {\n return undefined;\n }\n\n const top = margin.t ?? 0;\n const right = margin.r ?? 0;\n const bottom = margin.b ?? 0;\n const left = margin.l ?? 0;\n\n if (top === 0 && right === 0 && bottom === 0 && left === 0) {\n return undefined;\n }\n\n return `${top}px ${right}px ${bottom}px ${left}px`;\n};\n\nexport const AnnotationOnlyChart: React.FC<IAnnotationOnlyChartProps> = props => {\n const {\n annotations,\n chartTitle,\n description,\n width,\n height,\n paperBackgroundColor,\n plotBackgroundColor,\n fontColor,\n fontFamily,\n margin,\n componentRef,\n } = props;\n\n const theme = useTheme();\n const containerRef = React.useRef<HTMLDivElement | null>(null);\n const contentRef = React.useRef<HTMLDivElement | null>(null);\n const [measuredWidth, setMeasuredWidth] = React.useState<number>(width ?? 0);\n const [contentHeight, setContentHeight] = React.useState<number>(height ?? DEFAULT_HEIGHT);\n\n React.useEffect(() => {\n if (typeof width === 'number' && width > 0) {\n setMeasuredWidth(width);\n return;\n }\n\n const node = containerRef.current;\n if (!node || typeof ResizeObserver === 'undefined') {\n const rect = node?.getBoundingClientRect();\n if (rect && rect.width > 0) {\n setMeasuredWidth(rect.width);\n } else {\n setMeasuredWidth(prev => (prev > 0 ? prev : FALLBACK_WIDTH));\n }\n return;\n }\n\n const observer = new ResizeObserver(entries => {\n const entry = entries[0];\n if (!entry) {\n return;\n }\n const newWidth = entry.contentRect.width;\n if (newWidth > 0 && Math.abs(newWidth - measuredWidth) > 0.5) {\n setMeasuredWidth(newWidth);\n }\n });\n\n const rect = node.getBoundingClientRect();\n if (rect.width > 0) {\n setMeasuredWidth(rect.width);\n }\n\n observer.observe(node);\n return () => observer.disconnect();\n }, [width, measuredWidth]);\n\n const resolvedWidth = Math.max(measuredWidth || FALLBACK_WIDTH, 1);\n const resolvedHeight = Math.max(height ?? DEFAULT_HEIGHT, 1);\n\n React.useEffect(() => {\n const node = contentRef.current;\n if (!node) {\n setContentHeight(prev => (prev > 0 ? prev : resolvedHeight));\n return;\n }\n\n if (typeof ResizeObserver === 'undefined') {\n const rect = node.getBoundingClientRect();\n setContentHeight(prev => (rect.height > 0 ? rect.height : prev > 0 ? prev : resolvedHeight));\n return;\n }\n\n const observer = new ResizeObserver(entries => {\n const entry = entries[0];\n if (!entry) {\n return;\n }\n\n const newHeight = entry.contentRect.height;\n if (newHeight > 0) {\n setContentHeight(prev => (Math.abs(prev - newHeight) > 0.5 ? newHeight : prev));\n }\n });\n\n const rect = node.getBoundingClientRect();\n setContentHeight(prev => (rect.height > 0 ? rect.height : prev > 0 ? prev : resolvedHeight));\n\n observer.observe(node);\n return () => observer.disconnect();\n }, [\n resolvedHeight,\n resolvedWidth,\n annotations,\n chartTitle,\n description,\n margin,\n plotBackgroundColor,\n paperBackgroundColor,\n fontColor,\n fontFamily,\n theme,\n ]);\n\n const svgHeight = Math.max(Math.ceil(contentHeight || 0), resolvedHeight);\n\n const context: IChartAnnotationContext = {\n plotRect: { x: 0, y: 0, width: resolvedWidth, height: resolvedHeight },\n svgRect: { width: resolvedWidth, height: resolvedHeight },\n isRtl: theme?.rtl,\n };\n\n const padding = buildPadding(margin);\n\n const rootClassName = React.useMemo(\n () =>\n mergeStyles({\n position: 'relative',\n width: width ? `${width}px` : '100%',\n minHeight: resolvedHeight,\n backgroundColor: paperBackgroundColor ?? theme.semanticColors.bodyBackground,\n color: fontColor ?? theme.semanticColors.bodyText,\n fontFamily: fontFamily ?? theme.fonts.medium.fontFamily,\n padding,\n display: 'flex',\n flexDirection: 'column',\n rowGap: '8px',\n }),\n [fontColor, fontFamily, paperBackgroundColor, padding, resolvedHeight, theme, width],\n );\n\n const contentClassName = React.useMemo(\n () =>\n mergeStyles({\n position: 'relative',\n flexGrow: 1,\n backgroundColor: plotBackgroundColor ?? 'transparent',\n borderRadius: theme.effects.roundedCorner2 ?? 4,\n boxSizing: 'border-box',\n }),\n [plotBackgroundColor, theme.effects.roundedCorner2],\n );\n\n const titleClassName = React.useMemo(\n () =>\n mergeStyles({\n textAlign: 'center',\n }),\n [],\n );\n\n const resolvedAnnotations = annotations ?? [];\n const hasAnnotations = resolvedAnnotations.length > 0;\n const ariaLabel = hasAnnotations ? description ?? chartTitle : undefined;\n\n React.useImperativeHandle(\n componentRef,\n () => {\n const chartHandle: IChart = {\n chartContainer: containerRef.current,\n toImage: (opts?: IImageExportOptions) => {\n return exportChartsAsImage([{ container: containerRef.current }], undefined, getRTL(), opts);\n },\n };\n\n return chartHandle;\n },\n [],\n );\n\n return (\n <div ref={containerRef} data-chart-annotation-container=\"true\">\n <svg\n width={resolvedWidth}\n height={svgHeight}\n viewBox={`0 0 ${resolvedWidth} ${svgHeight}`}\n style={{ width: width ? `${width}px` : '100%', height: `${svgHeight}px`, display: 'block' }}\n role={ariaLabel ? 'img' : undefined}\n aria-label={ariaLabel}\n >\n <foreignObject x={0} y={0} width={resolvedWidth} height={svgHeight}>\n <div ref={contentRef} className={rootClassName} data-chart-annotation-only=\"true\" aria-label={ariaLabel}>\n {chartTitle && (\n <span className={titleClassName} aria-hidden=\"true\">\n {chartTitle}\n </span>\n )}\n <div className={contentClassName} role=\"presentation\">\n {hasAnnotations ? (\n <ChartAnnotationLayer annotations={resolvedAnnotations} context={context} theme={theme} />\n ) : null}\n </div>\n </div>\n </foreignObject>\n </svg>\n </div>\n );\n};\n\nAnnotationOnlyChart.displayName = 'AnnotationOnlyChart';\n"]}
1
+ {"version":3,"file":"AnnotationOnlyChart.js","sourceRoot":"../src/","sources":["components/AnnotationOnlyChart/AnnotationOnly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import { mergeStyles } from '@fluentui/react/lib/Styling';\nimport { ChartAnnotationLayer } from '../CommonComponents/Annotations/ChartAnnotationLayer';\nimport { exportChartsAsImage } from '../../utilities/image-export-utils';\nimport type { IAnnotationOnlyChartProps } from './AnnotationOnlyChart.types';\nimport type { IChart, IImageExportOptions } from '../../types/index';\nimport type { IChartAnnotationContext } from '../CommonComponents/Annotations/ChartAnnotationLayer.types';\n\nconst DEFAULT_HEIGHT = 650;\nconst FALLBACK_WIDTH = 400;\n\nconst buildPadding = (margin: IAnnotationOnlyChartProps['margin']): string | undefined => {\n if (!margin) {\n return undefined;\n }\n\n const top = margin.t ?? 0;\n const right = margin.r ?? 0;\n const bottom = margin.b ?? 0;\n const left = margin.l ?? 0;\n\n if (top === 0 && right === 0 && bottom === 0 && left === 0) {\n return undefined;\n }\n\n return `${top}px ${right}px ${bottom}px ${left}px`;\n};\n\nexport const AnnotationOnlyChart: React.FC<IAnnotationOnlyChartProps> = props => {\n const {\n annotations,\n chartTitle,\n description,\n width,\n height,\n paperBackgroundColor,\n plotBackgroundColor,\n fontColor,\n fontFamily,\n margin,\n componentRef,\n } = props;\n\n const theme = useTheme();\n const containerRef = React.useRef<HTMLDivElement | null>(null);\n const contentRef = React.useRef<HTMLDivElement | null>(null);\n const [measuredWidth, setMeasuredWidth] = React.useState<number>(width ?? 0);\n const [contentHeight, setContentHeight] = React.useState<number>(height ?? DEFAULT_HEIGHT);\n\n React.useEffect(() => {\n if (typeof width === 'number' && width > 0) {\n setMeasuredWidth(width);\n return;\n }\n\n const node = containerRef.current;\n if (!node || typeof ResizeObserver === 'undefined') {\n const rect = node?.getBoundingClientRect();\n if (rect && rect.width > 0) {\n setMeasuredWidth(rect.width);\n } else {\n setMeasuredWidth(prev => (prev > 0 ? prev : FALLBACK_WIDTH));\n }\n return;\n }\n\n const observer = new ResizeObserver(entries => {\n const entry = entries[0];\n if (!entry) {\n return;\n }\n const newWidth = entry.contentRect.width;\n if (newWidth > 0 && Math.abs(newWidth - measuredWidth) > 0.5) {\n setMeasuredWidth(newWidth);\n }\n });\n\n const rect = node.getBoundingClientRect();\n if (rect.width > 0) {\n setMeasuredWidth(rect.width);\n }\n\n observer.observe(node);\n return () => observer.disconnect();\n }, [width, measuredWidth]);\n\n const resolvedWidth = Math.max(measuredWidth || FALLBACK_WIDTH, 1);\n const resolvedHeight = Math.max(height ?? DEFAULT_HEIGHT, 1);\n\n React.useEffect(() => {\n const node = contentRef.current;\n if (!node) {\n setContentHeight(prev => (prev > 0 ? prev : resolvedHeight));\n return;\n }\n\n if (typeof ResizeObserver === 'undefined') {\n const rect = node.getBoundingClientRect();\n setContentHeight(prev => (rect.height > 0 ? rect.height : prev > 0 ? prev : resolvedHeight));\n return;\n }\n\n const observer = new ResizeObserver(entries => {\n const entry = entries[0];\n if (!entry) {\n return;\n }\n\n const newHeight = entry.contentRect.height;\n if (newHeight > 0) {\n setContentHeight(prev => (Math.abs(prev - newHeight) > 0.5 ? newHeight : prev));\n }\n });\n\n const rect = node.getBoundingClientRect();\n setContentHeight(prev => (rect.height > 0 ? rect.height : prev > 0 ? prev : resolvedHeight));\n\n observer.observe(node);\n return () => observer.disconnect();\n }, [\n resolvedHeight,\n resolvedWidth,\n annotations,\n chartTitle,\n description,\n margin,\n plotBackgroundColor,\n paperBackgroundColor,\n fontColor,\n fontFamily,\n theme,\n ]);\n\n const svgHeight = Math.max(Math.ceil(contentHeight || 0), resolvedHeight);\n\n const context: IChartAnnotationContext = {\n plotRect: { x: 0, y: 0, width: resolvedWidth, height: resolvedHeight },\n svgRect: { width: resolvedWidth, height: resolvedHeight },\n isRtl: theme?.rtl,\n };\n\n const padding = buildPadding(margin);\n\n const rootClassName = React.useMemo(\n () =>\n mergeStyles({\n position: 'relative',\n width: width ? `${width}px` : '100%',\n minHeight: resolvedHeight,\n backgroundColor: paperBackgroundColor ?? theme.semanticColors.bodyBackground,\n color: fontColor ?? theme.semanticColors.bodyText,\n fontFamily: fontFamily ?? theme.fonts.medium.fontFamily,\n padding,\n display: 'flex',\n flexDirection: 'column',\n rowGap: '8px',\n }),\n [fontColor, fontFamily, paperBackgroundColor, padding, resolvedHeight, theme, width],\n );\n\n const contentClassName = React.useMemo(\n () =>\n mergeStyles({\n position: 'relative',\n flexGrow: 1,\n backgroundColor: plotBackgroundColor ?? 'transparent',\n borderRadius: theme.effects.roundedCorner2 ?? 4,\n boxSizing: 'border-box',\n }),\n [plotBackgroundColor, theme.effects.roundedCorner2],\n );\n\n const titleClassName = React.useMemo(\n () =>\n mergeStyles({\n textAlign: 'center',\n }),\n [],\n );\n\n const resolvedAnnotations = annotations ?? [];\n const hasAnnotations = resolvedAnnotations.length > 0;\n const ariaLabel = hasAnnotations ? description ?? chartTitle : undefined;\n\n React.useImperativeHandle(\n componentRef,\n () => {\n const chartHandle: IChart = {\n chartContainer: containerRef.current,\n toImage: (opts?: IImageExportOptions) => {\n return exportChartsAsImage([{ container: containerRef.current }], undefined, getRTL(), opts);\n },\n };\n\n return chartHandle;\n },\n [],\n );\n\n return (\n <div ref={containerRef} data-chart-annotation-container=\"true\">\n <svg\n width={resolvedWidth}\n height={svgHeight}\n viewBox={`0 0 ${resolvedWidth} ${svgHeight}`}\n style={{ width: width ? `${width}px` : '100%', height: `${svgHeight}px`, display: 'block' }}\n role={ariaLabel ? 'img' : undefined}\n aria-label={ariaLabel}\n >\n <foreignObject x={0} y={0} width={resolvedWidth} height={svgHeight}>\n <div ref={contentRef} className={rootClassName} data-chart-annotation-only=\"true\" aria-label={ariaLabel}>\n {chartTitle && (\n <span className={titleClassName} aria-hidden=\"true\">\n {chartTitle}\n </span>\n )}\n <div className={contentClassName} role=\"presentation\">\n {hasAnnotations ? (\n <ChartAnnotationLayer\n annotations={resolvedAnnotations}\n context={context}\n theme={theme}\n hideDefaultStyles={true}\n />\n ) : null}\n </div>\n </div>\n </foreignObject>\n </svg>\n </div>\n );\n};\n\nAnnotationOnlyChart.displayName = 'AnnotationOnlyChart';\n"]}
@@ -54,7 +54,6 @@ export declare class AreaChartBase extends React.Component<IAreaChartProps, IAre
54
54
  private _rectId;
55
55
  private _xAxisRectScale;
56
56
  private _isMultiStackChart;
57
- private _tooltipId;
58
57
  private _highlightedCircleId;
59
58
  private _enableComputationOptimization;
60
59
  private _firstRenderOptimization;
@@ -2,17 +2,15 @@ import { __assign, __extends } from "tslib";
2
2
  import * as React from 'react';
3
3
  import { max as d3Max, bisector } from 'd3-array';
4
4
  import { pointer } from 'd3-selection';
5
- import { select as d3Select } from 'd3-selection';
6
5
  import { area as d3Area, stack as d3Stack, curveMonotoneX as d3CurveBasis, line as d3Line } from 'd3-shape';
7
- import { classNamesFunction, getId, getRTL, initializeComponentRef, memoizeFunction, } from '@fluentui/react/lib/Utilities';
6
+ import { getId, getRTL, initializeComponentRef, memoizeFunction } from '@fluentui/react/lib/Utilities';
8
7
  import { CartesianChart, } from '../../index';
9
8
  import { warnDeprecations } from '@fluentui/react/lib/Utilities';
10
9
  import { formatDateToLocaleString } from '@fluentui/chart-utilities';
11
- import { calloutData, getXAxisType, ChartTypes, XAxisTypes, getTypeOfAxis, tooltipOfAxislabels, getNextColor, getColorFromToken, findNumericMinMaxOfY, createNumericYAxis, domainRangeOfNumericForAreaLineScatterCharts, domainRangeOfDateForAreaLineScatterVerticalBarCharts, createStringYAxis, getSecureProps, areArraysEqual, getCurveFactory, findCalloutPoints, } from '../../utilities/index';
10
+ import { calloutData, getXAxisType, ChartTypes, XAxisTypes, getTypeOfAxis, getNextColor, getColorFromToken, findNumericMinMaxOfY, createNumericYAxis, domainRangeOfNumericForAreaLineScatterCharts, domainRangeOfDateForAreaLineScatterVerticalBarCharts, createStringYAxis, getSecureProps, areArraysEqual, getCurveFactory, findCalloutPoints, } from '../../utilities/index';
12
11
  import { Legends } from '../Legends/index';
13
12
  import { DirectionalHint } from '@fluentui/react/lib/Callout';
14
13
  import { exportChartsAsImage } from '../../utilities/image-export-utils';
15
- var getClassNames = classNamesFunction();
16
14
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
17
15
  var bisect = bisector(function (d) { return d.x; }).left;
18
16
  var COMPONENT_NAME = 'AREA CHART';
@@ -536,32 +534,6 @@ var AreaChartBase = /** @class */ (function (_super) {
536
534
  }
537
535
  });
538
536
  graph.push(React.createElement("line", __assign({ id: _this._verticalLineId, key: _this._verticalLineId, x1: _this.state.lineXValue, y1: 0, x2: _this.state.lineXValue, y2: containerHeight, strokeWidth: 1, strokeDasharray: 5.5, stroke: lineColor, opacity: 0.5, visibility: _this.state.displayOfLine }, getSecureProps(pointLineOptions))));
539
- var classNames = getClassNames(_this.props.styles, {
540
- theme: _this.props.theme,
541
- });
542
- // Removing un wanted tooltip div from DOM, when prop not provided.
543
- if (!_this.props.showXAxisLablesTooltip) {
544
- try {
545
- document.getElementById(_this._tooltipId) && document.getElementById(_this._tooltipId).remove();
546
- // eslint-disable-next-line no-empty
547
- }
548
- catch (e) { }
549
- }
550
- // Used to display tooltip at x axis labels.
551
- if (!_this.props.wrapXAxisLables && _this.props.showXAxisLablesTooltip) {
552
- var xAxisElement = d3Select(xElement).call(xScale);
553
- try {
554
- document.getElementById(_this._tooltipId) && document.getElementById(_this._tooltipId).remove();
555
- // eslint-disable-next-line no-empty
556
- }
557
- catch (e) { }
558
- var tooltipProps = {
559
- tooltipCls: classNames.tooltip,
560
- id: _this._tooltipId,
561
- axis: xAxisElement,
562
- };
563
- xAxisElement && tooltipOfAxislabels(tooltipProps);
564
- }
565
537
  return graph;
566
538
  };
567
539
  _this._getOnClickHandler = function (points, index, pointIndex) {
@@ -718,7 +690,6 @@ var AreaChartBase = /** @class */ (function (_super) {
718
690
  _this._verticalLineId = getId('verticalLine_');
719
691
  _this._circleId = getId('circle');
720
692
  _this._rectId = getId('rectangle');
721
- _this._tooltipId = getId('AreaChartTooltipID');
722
693
  _this._enableComputationOptimization = true;
723
694
  _this._firstRenderOptimization = true;
724
695
  _this._emptyChartId = getId('_AreaChart_empty');