@mui/x-charts 8.0.0-beta.2 → 8.0.0-beta.3

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 (345) hide show
  1. package/BarChart/AnimatedBarElement.d.ts +38 -8
  2. package/BarChart/AnimatedBarElement.js +5 -5
  3. package/BarChart/BarChart.js +2 -0
  4. package/BarChart/BarClipPath.d.ts +19 -1
  5. package/BarChart/BarClipPath.js +84 -17
  6. package/BarChart/BarElement.d.ts +9 -20
  7. package/BarChart/BarElement.js +29 -26
  8. package/BarChart/BarLabel/BarLabel.d.ts +27 -854
  9. package/BarChart/BarLabel/BarLabel.js +32 -5
  10. package/BarChart/BarLabel/BarLabel.types.d.ts +2 -0
  11. package/BarChart/BarLabel/BarLabelItem.d.ts +24 -0
  12. package/BarChart/BarLabel/BarLabelItem.js +18 -6
  13. package/BarChart/BarLabel/BarLabelPlot.js +16 -46
  14. package/BarChart/BarLabel/barLabelClasses.d.ts +3 -1
  15. package/BarChart/BarLabel/barLabelClasses.js +4 -3
  16. package/BarChart/BarPlot.js +37 -61
  17. package/BarChart/barElementClasses.d.ts +21 -0
  18. package/BarChart/barElementClasses.js +29 -0
  19. package/BarChart/getRadius.d.ts +1 -1
  20. package/BarChart/index.d.ts +2 -1
  21. package/BarChart/index.js +11 -0
  22. package/BarChart/seriesConfig/index.js +3 -1
  23. package/BarChart/seriesConfig/tooltip.d.ts +2 -1
  24. package/BarChart/seriesConfig/tooltip.js +14 -1
  25. package/BarChart/types.d.ts +2 -2
  26. package/CHANGELOG.md +141 -0
  27. package/ChartContainer/ChartContainer.js +4 -0
  28. package/ChartsLabel/ChartsLabelMark.js +0 -4
  29. package/ChartsLabel/index.d.ts +1 -0
  30. package/ChartsLabel/index.js +7 -0
  31. package/ChartsLegend/continuousColorLegendClasses.d.ts +1 -1
  32. package/ChartsTooltip/ChartsAxisTooltipContent.js +47 -55
  33. package/ChartsTooltip/ChartsItemTooltipContent.js +11 -9
  34. package/ChartsTooltip/ChartsTooltip.js +2 -2
  35. package/ChartsTooltip/ChartsTooltipContainer.js +3 -8
  36. package/ChartsTooltip/ChartsTooltipTable.d.ts +3 -1
  37. package/ChartsTooltip/ChartsTooltipTable.js +24 -9
  38. package/ChartsTooltip/chartsTooltipClasses.d.ts +4 -4
  39. package/ChartsTooltip/chartsTooltipClasses.js +2 -2
  40. package/ChartsTooltip/index.d.ts +1 -0
  41. package/ChartsTooltip/index.js +12 -0
  42. package/ChartsTooltip/useAxesTooltip.d.ts +7 -0
  43. package/ChartsTooltip/useAxesTooltip.js +18 -0
  44. package/ChartsTooltip/useAxisTooltip.d.ts +24 -3
  45. package/ChartsTooltip/useAxisTooltip.js +71 -37
  46. package/ChartsTooltip/useItemTooltip.js +4 -1
  47. package/ChartsXAxis/ChartsXAxis.js +5 -2
  48. package/ChartsYAxis/ChartsYAxis.js +69 -17
  49. package/LineChart/AnimatedArea.js +5 -22
  50. package/LineChart/AnimatedLine.d.ts +1 -4
  51. package/LineChart/AnimatedLine.js +10 -25
  52. package/LineChart/AppearingMask.d.ts +5 -0
  53. package/LineChart/AppearingMask.js +25 -18
  54. package/LineChart/CircleMarkElement.js +16 -22
  55. package/LineChart/LineChart.js +2 -0
  56. package/LineChart/LineHighlightPlot.js +2 -3
  57. package/LineChart/MarkElement.js +16 -27
  58. package/LineChart/MarkPlot.js +0 -1
  59. package/LineChart/markElementClasses.d.ts +3 -0
  60. package/LineChart/markElementClasses.js +4 -3
  61. package/LineChart/seriesConfig/index.js +3 -1
  62. package/LineChart/seriesConfig/tooltip.d.ts +2 -1
  63. package/LineChart/seriesConfig/tooltip.js +8 -1
  64. package/PieChart/PieArc.d.ts +19 -11
  65. package/PieChart/PieArc.js +37 -24
  66. package/PieChart/PieArcLabel.d.ts +22 -13
  67. package/PieChart/PieArcLabel.js +52 -48
  68. package/PieChart/PieArcLabelPlot.js +16 -34
  69. package/PieChart/PieArcPlot.js +21 -34
  70. package/PieChart/seriesConfig/tooltip.js +3 -0
  71. package/ScatterChart/ScatterChart.js +2 -0
  72. package/SparkLineChart/SparkLineChart.js +2 -0
  73. package/colorPalettes/colorPalettes.js +2 -2
  74. package/constants/index.d.ts +1 -1
  75. package/constants/index.js +1 -1
  76. package/context/AnimationProvider/AnimationProvider.js +4 -6
  77. package/esm/BarChart/AnimatedBarElement.d.ts +38 -8
  78. package/esm/BarChart/AnimatedBarElement.js +5 -5
  79. package/esm/BarChart/BarChart.js +2 -0
  80. package/esm/BarChart/BarClipPath.d.ts +19 -1
  81. package/esm/BarChart/BarClipPath.js +84 -17
  82. package/esm/BarChart/BarElement.d.ts +9 -20
  83. package/esm/BarChart/BarElement.js +28 -23
  84. package/esm/BarChart/BarLabel/BarLabel.d.ts +27 -854
  85. package/esm/BarChart/BarLabel/BarLabel.js +32 -5
  86. package/esm/BarChart/BarLabel/BarLabel.types.d.ts +2 -0
  87. package/esm/BarChart/BarLabel/BarLabelItem.d.ts +24 -0
  88. package/esm/BarChart/BarLabel/BarLabelItem.js +18 -6
  89. package/esm/BarChart/BarLabel/BarLabelPlot.js +16 -46
  90. package/esm/BarChart/BarLabel/barLabelClasses.d.ts +3 -1
  91. package/esm/BarChart/BarLabel/barLabelClasses.js +4 -3
  92. package/esm/BarChart/BarPlot.js +37 -61
  93. package/esm/BarChart/barElementClasses.d.ts +21 -0
  94. package/esm/BarChart/barElementClasses.js +19 -0
  95. package/esm/BarChart/getRadius.d.ts +1 -1
  96. package/esm/BarChart/index.d.ts +2 -1
  97. package/esm/BarChart/index.js +2 -1
  98. package/esm/BarChart/seriesConfig/index.js +2 -1
  99. package/esm/BarChart/seriesConfig/tooltip.d.ts +2 -1
  100. package/esm/BarChart/seriesConfig/tooltip.js +12 -0
  101. package/esm/BarChart/types.d.ts +2 -2
  102. package/esm/ChartContainer/ChartContainer.js +4 -0
  103. package/esm/ChartsLabel/ChartsLabelMark.js +0 -4
  104. package/esm/ChartsLabel/index.d.ts +1 -0
  105. package/esm/ChartsLabel/index.js +1 -0
  106. package/esm/ChartsLegend/continuousColorLegendClasses.d.ts +1 -1
  107. package/esm/ChartsTooltip/ChartsAxisTooltipContent.js +47 -55
  108. package/esm/ChartsTooltip/ChartsItemTooltipContent.js +11 -9
  109. package/esm/ChartsTooltip/ChartsTooltip.js +2 -2
  110. package/esm/ChartsTooltip/ChartsTooltipContainer.js +4 -9
  111. package/esm/ChartsTooltip/ChartsTooltipTable.d.ts +3 -1
  112. package/esm/ChartsTooltip/ChartsTooltipTable.js +23 -9
  113. package/esm/ChartsTooltip/chartsTooltipClasses.d.ts +4 -4
  114. package/esm/ChartsTooltip/chartsTooltipClasses.js +2 -2
  115. package/esm/ChartsTooltip/index.d.ts +1 -0
  116. package/esm/ChartsTooltip/index.js +1 -0
  117. package/esm/ChartsTooltip/useAxesTooltip.d.ts +7 -0
  118. package/esm/ChartsTooltip/useAxesTooltip.js +12 -0
  119. package/esm/ChartsTooltip/useAxisTooltip.d.ts +24 -3
  120. package/esm/ChartsTooltip/useAxisTooltip.js +72 -38
  121. package/esm/ChartsTooltip/useItemTooltip.js +4 -1
  122. package/esm/ChartsXAxis/ChartsXAxis.js +5 -2
  123. package/esm/ChartsYAxis/ChartsYAxis.js +69 -17
  124. package/esm/LineChart/AnimatedArea.js +5 -22
  125. package/esm/LineChart/AnimatedLine.d.ts +1 -4
  126. package/esm/LineChart/AnimatedLine.js +9 -24
  127. package/esm/LineChart/AppearingMask.d.ts +5 -0
  128. package/esm/LineChart/AppearingMask.js +23 -18
  129. package/esm/LineChart/CircleMarkElement.js +19 -25
  130. package/esm/LineChart/LineChart.js +2 -0
  131. package/esm/LineChart/LineHighlightPlot.js +3 -4
  132. package/esm/LineChart/MarkElement.js +17 -28
  133. package/esm/LineChart/MarkPlot.js +0 -1
  134. package/esm/LineChart/markElementClasses.d.ts +3 -0
  135. package/esm/LineChart/markElementClasses.js +4 -3
  136. package/esm/LineChart/seriesConfig/index.js +2 -1
  137. package/esm/LineChart/seriesConfig/tooltip.d.ts +2 -1
  138. package/esm/LineChart/seriesConfig/tooltip.js +6 -0
  139. package/esm/PieChart/PieArc.d.ts +19 -11
  140. package/esm/PieChart/PieArc.js +36 -23
  141. package/esm/PieChart/PieArcLabel.d.ts +22 -13
  142. package/esm/PieChart/PieArcLabel.js +51 -47
  143. package/esm/PieChart/PieArcLabelPlot.js +16 -34
  144. package/esm/PieChart/PieArcPlot.js +21 -34
  145. package/esm/PieChart/seriesConfig/tooltip.js +3 -0
  146. package/esm/ScatterChart/ScatterChart.js +2 -0
  147. package/esm/SparkLineChart/SparkLineChart.js +2 -0
  148. package/esm/colorPalettes/colorPalettes.js +2 -2
  149. package/esm/constants/index.d.ts +1 -1
  150. package/esm/constants/index.js +1 -1
  151. package/esm/context/AnimationProvider/AnimationProvider.js +3 -6
  152. package/esm/hooks/animation/index.d.ts +6 -0
  153. package/esm/hooks/animation/index.js +6 -0
  154. package/esm/hooks/animation/useAnimateArea.d.ts +15 -0
  155. package/esm/hooks/animation/useAnimateArea.js +27 -0
  156. package/esm/hooks/animation/useAnimateBar.d.ts +17 -0
  157. package/esm/hooks/animation/useAnimateBar.js +56 -0
  158. package/esm/hooks/animation/useAnimateBarLabel.d.ts +19 -0
  159. package/esm/hooks/animation/useAnimateBarLabel.js +59 -0
  160. package/esm/hooks/animation/useAnimateLine.d.ts +14 -0
  161. package/esm/hooks/animation/useAnimateLine.js +26 -0
  162. package/esm/hooks/animation/useAnimatePieArc.d.ts +15 -0
  163. package/esm/hooks/animation/useAnimatePieArc.js +70 -0
  164. package/esm/hooks/animation/useAnimatePieArcLabel.d.ts +15 -0
  165. package/esm/hooks/animation/useAnimatePieArcLabel.js +72 -0
  166. package/esm/hooks/index.d.ts +2 -1
  167. package/esm/hooks/index.js +2 -1
  168. package/esm/hooks/useInteractionItemProps.js +11 -0
  169. package/esm/index.js +1 -1
  170. package/esm/internals/animation/Transition.d.ts +37 -0
  171. package/esm/internals/animation/Transition.js +83 -0
  172. package/esm/internals/animation/animation.d.ts +4 -0
  173. package/esm/internals/animation/animation.js +4 -0
  174. package/esm/internals/animation/useAnimate.d.ts +19 -0
  175. package/esm/internals/animation/useAnimate.js +74 -0
  176. package/esm/internals/plugins/featurePlugins/useChartCartesianAxis/computeAxisValue.d.ts +1 -1
  177. package/esm/internals/plugins/featurePlugins/useChartCartesianAxis/computeAxisValue.js +9 -3
  178. package/esm/internals/plugins/featurePlugins/useChartCartesianAxis/getAxisTriggerTooltip.d.ts +5 -0
  179. package/esm/internals/plugins/featurePlugins/useChartCartesianAxis/getAxisTriggerTooltip.js +21 -0
  180. package/esm/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianAxisRendering.selectors.d.ts +8 -32
  181. package/esm/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianInteraction.selectors.d.ts +9 -1
  182. package/esm/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianInteraction.selectors.js +60 -26
  183. package/esm/internals/plugins/models/seriesConfig/seriesConfig.types.d.ts +3 -1
  184. package/esm/internals/plugins/models/seriesConfig/tooltipGetter.types.d.ts +10 -4
  185. package/esm/internals/shallowEqual.d.ts +8 -0
  186. package/esm/internals/shallowEqual.js +31 -0
  187. package/esm/models/axis.d.ts +8 -0
  188. package/esm/themeAugmentation/overrides.d.ts +1 -1
  189. package/hooks/animation/index.d.ts +6 -0
  190. package/hooks/animation/index.js +71 -0
  191. package/hooks/animation/useAnimateArea.d.ts +15 -0
  192. package/hooks/animation/useAnimateArea.js +34 -0
  193. package/hooks/animation/useAnimateBar.d.ts +17 -0
  194. package/hooks/animation/useAnimateBar.js +62 -0
  195. package/hooks/animation/useAnimateBarLabel.d.ts +19 -0
  196. package/hooks/animation/useAnimateBarLabel.js +65 -0
  197. package/hooks/animation/useAnimateLine.d.ts +14 -0
  198. package/hooks/animation/useAnimateLine.js +33 -0
  199. package/hooks/animation/useAnimatePieArc.d.ts +15 -0
  200. package/hooks/animation/useAnimatePieArc.js +77 -0
  201. package/hooks/animation/useAnimatePieArcLabel.d.ts +15 -0
  202. package/hooks/animation/useAnimatePieArcLabel.js +79 -0
  203. package/hooks/index.d.ts +2 -1
  204. package/hooks/index.js +13 -1
  205. package/hooks/useInteractionItemProps.js +11 -0
  206. package/index.js +1 -1
  207. package/internals/animation/Transition.d.ts +37 -0
  208. package/internals/animation/Transition.js +89 -0
  209. package/internals/animation/animation.d.ts +4 -0
  210. package/internals/animation/animation.js +11 -0
  211. package/internals/animation/useAnimate.d.ts +19 -0
  212. package/internals/animation/useAnimate.js +80 -0
  213. package/internals/plugins/featurePlugins/useChartCartesianAxis/computeAxisValue.d.ts +1 -1
  214. package/internals/plugins/featurePlugins/useChartCartesianAxis/computeAxisValue.js +9 -3
  215. package/internals/plugins/featurePlugins/useChartCartesianAxis/getAxisTriggerTooltip.d.ts +5 -0
  216. package/internals/plugins/featurePlugins/useChartCartesianAxis/getAxisTriggerTooltip.js +28 -0
  217. package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianAxisRendering.selectors.d.ts +8 -32
  218. package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianInteraction.selectors.d.ts +9 -1
  219. package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianInteraction.selectors.js +61 -27
  220. package/internals/plugins/models/seriesConfig/seriesConfig.types.d.ts +3 -1
  221. package/internals/plugins/models/seriesConfig/tooltipGetter.types.d.ts +10 -4
  222. package/internals/shallowEqual.d.ts +8 -0
  223. package/internals/shallowEqual.js +37 -0
  224. package/models/axis.d.ts +8 -0
  225. package/modern/BarChart/AnimatedBarElement.d.ts +38 -8
  226. package/modern/BarChart/AnimatedBarElement.js +5 -5
  227. package/modern/BarChart/BarChart.js +2 -0
  228. package/modern/BarChart/BarClipPath.d.ts +19 -1
  229. package/modern/BarChart/BarClipPath.js +84 -17
  230. package/modern/BarChart/BarElement.d.ts +9 -20
  231. package/modern/BarChart/BarElement.js +28 -23
  232. package/modern/BarChart/BarLabel/BarLabel.d.ts +27 -854
  233. package/modern/BarChart/BarLabel/BarLabel.js +32 -5
  234. package/modern/BarChart/BarLabel/BarLabel.types.d.ts +2 -0
  235. package/modern/BarChart/BarLabel/BarLabelItem.d.ts +24 -0
  236. package/modern/BarChart/BarLabel/BarLabelItem.js +18 -6
  237. package/modern/BarChart/BarLabel/BarLabelPlot.js +16 -46
  238. package/modern/BarChart/BarLabel/barLabelClasses.d.ts +3 -1
  239. package/modern/BarChart/BarLabel/barLabelClasses.js +4 -3
  240. package/modern/BarChart/BarPlot.js +37 -61
  241. package/modern/BarChart/barElementClasses.d.ts +21 -0
  242. package/modern/BarChart/barElementClasses.js +19 -0
  243. package/modern/BarChart/getRadius.d.ts +1 -1
  244. package/modern/BarChart/index.d.ts +2 -1
  245. package/modern/BarChart/index.js +2 -1
  246. package/modern/BarChart/seriesConfig/index.js +2 -1
  247. package/modern/BarChart/seriesConfig/tooltip.d.ts +2 -1
  248. package/modern/BarChart/seriesConfig/tooltip.js +12 -0
  249. package/modern/BarChart/types.d.ts +2 -2
  250. package/modern/ChartContainer/ChartContainer.js +4 -0
  251. package/modern/ChartsLabel/ChartsLabelMark.js +0 -4
  252. package/modern/ChartsLabel/index.d.ts +1 -0
  253. package/modern/ChartsLabel/index.js +1 -0
  254. package/modern/ChartsLegend/continuousColorLegendClasses.d.ts +1 -1
  255. package/modern/ChartsTooltip/ChartsAxisTooltipContent.js +47 -55
  256. package/modern/ChartsTooltip/ChartsItemTooltipContent.js +11 -9
  257. package/modern/ChartsTooltip/ChartsTooltip.js +2 -2
  258. package/modern/ChartsTooltip/ChartsTooltipContainer.js +4 -9
  259. package/modern/ChartsTooltip/ChartsTooltipTable.d.ts +3 -1
  260. package/modern/ChartsTooltip/ChartsTooltipTable.js +23 -9
  261. package/modern/ChartsTooltip/chartsTooltipClasses.d.ts +4 -4
  262. package/modern/ChartsTooltip/chartsTooltipClasses.js +2 -2
  263. package/modern/ChartsTooltip/index.d.ts +1 -0
  264. package/modern/ChartsTooltip/index.js +1 -0
  265. package/modern/ChartsTooltip/useAxesTooltip.d.ts +7 -0
  266. package/modern/ChartsTooltip/useAxesTooltip.js +12 -0
  267. package/modern/ChartsTooltip/useAxisTooltip.d.ts +24 -3
  268. package/modern/ChartsTooltip/useAxisTooltip.js +72 -38
  269. package/modern/ChartsTooltip/useItemTooltip.js +4 -1
  270. package/modern/ChartsXAxis/ChartsXAxis.js +5 -2
  271. package/modern/ChartsYAxis/ChartsYAxis.js +69 -17
  272. package/modern/LineChart/AnimatedArea.js +5 -22
  273. package/modern/LineChart/AnimatedLine.d.ts +1 -4
  274. package/modern/LineChart/AnimatedLine.js +9 -24
  275. package/modern/LineChart/AppearingMask.d.ts +5 -0
  276. package/modern/LineChart/AppearingMask.js +23 -18
  277. package/modern/LineChart/CircleMarkElement.js +19 -25
  278. package/modern/LineChart/LineChart.js +2 -0
  279. package/modern/LineChart/LineHighlightPlot.js +3 -4
  280. package/modern/LineChart/MarkElement.js +17 -28
  281. package/modern/LineChart/MarkPlot.js +0 -1
  282. package/modern/LineChart/markElementClasses.d.ts +3 -0
  283. package/modern/LineChart/markElementClasses.js +4 -3
  284. package/modern/LineChart/seriesConfig/index.js +2 -1
  285. package/modern/LineChart/seriesConfig/tooltip.d.ts +2 -1
  286. package/modern/LineChart/seriesConfig/tooltip.js +6 -0
  287. package/modern/PieChart/PieArc.d.ts +19 -11
  288. package/modern/PieChart/PieArc.js +36 -23
  289. package/modern/PieChart/PieArcLabel.d.ts +22 -13
  290. package/modern/PieChart/PieArcLabel.js +51 -47
  291. package/modern/PieChart/PieArcLabelPlot.js +16 -34
  292. package/modern/PieChart/PieArcPlot.js +21 -34
  293. package/modern/PieChart/seriesConfig/tooltip.js +3 -0
  294. package/modern/ScatterChart/ScatterChart.js +2 -0
  295. package/modern/SparkLineChart/SparkLineChart.js +2 -0
  296. package/modern/colorPalettes/colorPalettes.js +2 -2
  297. package/modern/constants/index.d.ts +1 -1
  298. package/modern/constants/index.js +1 -1
  299. package/modern/context/AnimationProvider/AnimationProvider.js +3 -6
  300. package/modern/hooks/animation/index.d.ts +6 -0
  301. package/modern/hooks/animation/index.js +6 -0
  302. package/modern/hooks/animation/useAnimateArea.d.ts +15 -0
  303. package/modern/hooks/animation/useAnimateArea.js +27 -0
  304. package/modern/hooks/animation/useAnimateBar.d.ts +17 -0
  305. package/modern/hooks/animation/useAnimateBar.js +56 -0
  306. package/modern/hooks/animation/useAnimateBarLabel.d.ts +19 -0
  307. package/modern/hooks/animation/useAnimateBarLabel.js +59 -0
  308. package/modern/hooks/animation/useAnimateLine.d.ts +14 -0
  309. package/modern/hooks/animation/useAnimateLine.js +26 -0
  310. package/modern/hooks/animation/useAnimatePieArc.d.ts +15 -0
  311. package/modern/hooks/animation/useAnimatePieArc.js +70 -0
  312. package/modern/hooks/animation/useAnimatePieArcLabel.d.ts +15 -0
  313. package/modern/hooks/animation/useAnimatePieArcLabel.js +72 -0
  314. package/modern/hooks/index.d.ts +2 -1
  315. package/modern/hooks/index.js +2 -1
  316. package/modern/hooks/useInteractionItemProps.js +11 -0
  317. package/modern/index.js +1 -1
  318. package/modern/internals/animation/Transition.d.ts +37 -0
  319. package/modern/internals/animation/Transition.js +83 -0
  320. package/modern/internals/animation/animation.d.ts +4 -0
  321. package/modern/internals/animation/animation.js +4 -0
  322. package/modern/internals/animation/useAnimate.d.ts +19 -0
  323. package/modern/internals/animation/useAnimate.js +74 -0
  324. package/modern/internals/plugins/featurePlugins/useChartCartesianAxis/computeAxisValue.d.ts +1 -1
  325. package/modern/internals/plugins/featurePlugins/useChartCartesianAxis/computeAxisValue.js +9 -3
  326. package/modern/internals/plugins/featurePlugins/useChartCartesianAxis/getAxisTriggerTooltip.d.ts +5 -0
  327. package/modern/internals/plugins/featurePlugins/useChartCartesianAxis/getAxisTriggerTooltip.js +21 -0
  328. package/modern/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianAxisRendering.selectors.d.ts +8 -32
  329. package/modern/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianInteraction.selectors.d.ts +9 -1
  330. package/modern/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianInteraction.selectors.js +60 -26
  331. package/modern/internals/plugins/models/seriesConfig/seriesConfig.types.d.ts +3 -1
  332. package/modern/internals/plugins/models/seriesConfig/tooltipGetter.types.d.ts +10 -4
  333. package/modern/internals/shallowEqual.d.ts +8 -0
  334. package/modern/internals/shallowEqual.js +31 -0
  335. package/modern/models/axis.d.ts +8 -0
  336. package/modern/themeAugmentation/overrides.d.ts +1 -1
  337. package/package.json +8 -9
  338. package/themeAugmentation/overrides.d.ts +1 -1
  339. package/tsconfig.build.tsbuildinfo +1 -1
  340. package/PieChart/dataTransform/transition.d.ts +0 -4
  341. package/PieChart/dataTransform/transition.js +0 -145
  342. package/esm/PieChart/dataTransform/transition.d.ts +0 -4
  343. package/esm/PieChart/dataTransform/transition.js +0 -137
  344. package/modern/PieChart/dataTransform/transition.d.ts +0 -4
  345. package/modern/PieChart/dataTransform/transition.js +0 -137
package/CHANGELOG.md CHANGED
@@ -5,6 +5,147 @@
5
5
  All notable changes to this project will be documented in this file.
6
6
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
7
7
 
8
+ ## 8.0.0-beta.3
9
+
10
+ _Apr 3, 2025_
11
+
12
+ We'd like to offer a big thanks to the 12 contributors who made this release possible. Here are some highlights ✨:
13
+
14
+ - 🚫 Removed `react-spring` as a dependency of `@mui/x-charts`
15
+ - 📦 Data Grid list view feature is now stable
16
+ - 💫 Support title in Data Grid
17
+ - 📚 Documentation improvements
18
+ - 🐞 Bugfixes
19
+
20
+ Team members who have contributed to this release:
21
+ @bernardobelchior, @cherniavskii, @flaviendelangle, @JCQuintas, @KenanYusuf, @LukasTy, @MBilalShafi, @michelengelen, @oliviertassinari, @noraleonte, @romgrk, @alexfauquette.
22
+
23
+ <!--/ HIGHLIGHT_ABOVE_SEPARATOR /-->
24
+
25
+ ### Data Grid
26
+
27
+ #### Breaking changes
28
+
29
+ - The list view feature and its related props are now stable.
30
+
31
+ The `unstable_listColumn` prop has been renamed to `listViewColumn`.
32
+
33
+ The `GridListColDef` type has been renamed to `GridListViewColDef`.
34
+
35
+ ```diff
36
+ -const listViewColDef: GridListColDef = {
37
+ +const listViewColDef: GridListViewColDef = {
38
+ field: 'listColumn',
39
+ renderCell: ListViewCell,
40
+ };
41
+
42
+ <DataGridPro
43
+ - unstable_listView
44
+ - unstable_listColumn={listViewColDef}
45
+ + listView
46
+ + listViewColumn={listViewColDef}
47
+ />
48
+ ```
49
+
50
+ - The `useGridApiEventHandler()` hook has been renamed to `useGridEvent()`.
51
+ - The `useGridApiOptionHandler()` hook has been renamed to `useGridEventPriority()`.
52
+
53
+ #### `@mui/x-data-grid@8.0.0-beta.3`
54
+
55
+ - [DataGrid] Fix "is any of" autocomplete rendering (#17226) @KenanYusuf
56
+ - [DataGrid] Rename `useGridApiEventHandler()` to `useGridEvent()` (#17159) @romgrk
57
+ - [DataGrid] Support adding a label to the grid (#17147) @KenanYusuf
58
+ - [DataGrid] Refactor: remove material typings (#17119) @romgrk
59
+
60
+ #### `@mui/x-data-grid-pro@8.0.0-beta.3` [![pro](https://mui.com/r/x-pro-svg)](https://mui.com/r/x-pro-svg-link 'Pro plan')
61
+
62
+ Same changes as in `@mui/x-data-grid@8.0.0-beta.3`, plus:
63
+
64
+ - [DataGridPro] Make list view feature stable (#17217) @KenanYusuf
65
+ - [DataGridPro] Always refetch lazy-loading rows (#16827) @MBilalShafi
66
+
67
+ #### `@mui/x-data-grid-premium@8.0.0-beta.3` [![premium](https://mui.com/r/x-premium-svg)](https://mui.com/r/x-premium-svg-link 'Premium plan')
68
+
69
+ Same changes as in `@mui/x-data-grid-pro@8.0.0-beta.3`.
70
+
71
+ ### Date and Time Pickers
72
+
73
+ #### `@mui/x-date-pickers@8.0.0-beta.3`
74
+
75
+ - [pickers] Add new `nextOrAccept` action bar action (#17037) @flaviendelangle
76
+ - [pickers] Improve the Multi Section Digital Clock scrollbar thickness (#16774) @oliviertassinari
77
+ - [TimePicker] Align the Digital Clock scrollbar thickness (#17203) @LukasTy
78
+
79
+ #### `@mui/x-date-pickers-pro@8.0.0-beta.3` [![pro](https://mui.com/r/x-pro-svg)](https://mui.com/r/x-pro-svg-link 'Pro plan')
80
+
81
+ Same changes as in `@mui/x-date-pickers@8.0.0-beta.3`.
82
+
83
+ ### Charts
84
+
85
+ #### Breaking changes
86
+
87
+ - Removed `react-spring` as a dependency of `@mui/x-charts`.
88
+ A consequence of this change is that the props of some slots have been changed because the `SpringValue` wrapper has been removed. The affected slots and props are:
89
+
90
+ - the type of the `x`, `y`, `width` and `height` props of the `bar` slot are now `number`;
91
+ - the type of `startAngle`, `endAngle`, `innerRadius`, `outerRadius`, `arcLabelRadius`, `cornerRadius` and `paddingAngle` props of `pieArc` and `pieArcLabel` slot are now `number`.
92
+
93
+ Additionally, the `pieArc` slot now receives a `skipAnimation` prop to configure whether animations should be enabled or disabled.
94
+
95
+ - Tick labels in the y-axis of cartesian charts will now have an ellipsis applied to prevent overflow.
96
+ If your tick labels are being clipped sooner than you would like, you can increase the y-axis size by increasing its width property.
97
+
98
+ - The tooltip DOM structure is modified to improve accessibility. If you relied on it to apply some style or run tests, you might be impacted by this modification.
99
+ - The axis tooltip displays a table per axis with the axis value in a caption.
100
+ - Cells containing the series label and the color mark got merged in a th cell.
101
+
102
+ #### `@mui/x-charts@8.0.0-beta.3`
103
+
104
+ - [charts] Adjust color palettes (#17209) @noraleonte
105
+ - [charts] Allow multiple axes in the tooltip (#17058) @alexfauquette
106
+ - [charts] Improve custom legend docs (#17231) @JCQuintas
107
+ - [charts] Fix crash when item shown in tooltip is unmounted (#17169) @bernardobelchior
108
+ - [charts] Migrate some animations from `react-spring` (#16961) @bernardobelchior
109
+ - [charts] Remove `react-spring` (#17123) @bernardobelchior
110
+ - [charts] Fix y-axis tick label overflow (#16846) @bernardobelchior
111
+
112
+ #### `@mui/x-charts-pro@8.0.0-beta.3` [![pro](https://mui.com/r/x-pro-svg)](https://mui.com/r/x-pro-svg-link 'Pro plan')
113
+
114
+ Same changes as in `@mui/x-charts@8.0.0-beta.3`.
115
+
116
+ ### Tree View
117
+
118
+ #### `@mui/x-tree-view@8.0.0-beta.3`
119
+
120
+ Internal changes.
121
+
122
+ #### `@mui/x-tree-view-pro@8.0.0-beta.3` [![pro](https://mui.com/r/x-pro-svg)](https://mui.com/r/x-pro-svg-link 'Pro plan')
123
+
124
+ Same changes as in `@mui/x-tree-view@8.0.0-beta.3`.
125
+
126
+ ### `@mui/x-codemod@8.0.0-beta.3`
127
+
128
+ - [codemod] Add `listView` prop rename codemod (#17220) @MBilalShafi
129
+
130
+ ### Docs
131
+
132
+ - [docs] Add "Usage with Material UI v5/v6" guide (#17164) @cherniavskii
133
+ - [docs] Fix 301 link @oliviertassinari
134
+ - [docs] Fix redirection getting-started (#17200) @oliviertassinari
135
+ - [docs] Sync Stack Overflow docs with reality (#17198) @oliviertassinari
136
+ - [docs] Update Localization Provider JSDoc link (#17207) @LukasTy
137
+
138
+ ### Core
139
+
140
+ - [core] Cleanup `@mui` dependency versions (#17160) @LukasTy
141
+ - [core] Sync scorecards.yml across codebase @oliviertassinari
142
+ - [core] Revert upgrade to React 19.1 (#17206) @bernardobelchior
143
+ - [code-infra] Fix `test:unit` warning (#17224) @JCQuintas
144
+ - [code-infra] Fix pickers failing test after clock=fake removal (#17202) @JCQuintas
145
+ - [code-infra] Remove clock=fake from `describeValidation` (#17150) @JCQuintas
146
+ - [code-infra] Remove clock=fake from `describeValue` (#17199) @JCQuintas
147
+ - [infra] Add write permission for actions in issue status label handler (#17161) @michelengelen
148
+
8
149
  ## 8.0.0-beta.2
9
150
 
10
151
  _Mar 27, 2025_
@@ -158,6 +158,7 @@ process.env.NODE_ENV !== "production" ? ChartContainer.propTypes = {
158
158
  height: _propTypes.default.number,
159
159
  hideTooltip: _propTypes.default.bool,
160
160
  id: _propTypes.default.oneOfType([_propTypes.default.number, _propTypes.default.string]).isRequired,
161
+ ignoreTooltip: _propTypes.default.bool,
161
162
  label: _propTypes.default.string,
162
163
  labelStyle: _propTypes.default.object,
163
164
  max: _propTypes.default.oneOfType([_propTypes.default.instanceOf(Date), _propTypes.default.number]),
@@ -215,6 +216,7 @@ process.env.NODE_ENV !== "production" ? ChartContainer.propTypes = {
215
216
  height: _propTypes.default.number,
216
217
  hideTooltip: _propTypes.default.bool,
217
218
  id: _propTypes.default.oneOfType([_propTypes.default.number, _propTypes.default.string]).isRequired,
219
+ ignoreTooltip: _propTypes.default.bool,
218
220
  label: _propTypes.default.string,
219
221
  labelGap: _propTypes.default.number,
220
222
  labelStyle: _propTypes.default.object,
@@ -295,6 +297,7 @@ process.env.NODE_ENV !== "production" ? ChartContainer.propTypes = {
295
297
  height: _propTypes.default.number,
296
298
  hideTooltip: _propTypes.default.bool,
297
299
  id: _propTypes.default.oneOfType([_propTypes.default.number, _propTypes.default.string]),
300
+ ignoreTooltip: _propTypes.default.bool,
298
301
  label: _propTypes.default.string,
299
302
  labelStyle: _propTypes.default.object,
300
303
  max: _propTypes.default.oneOfType([_propTypes.default.instanceOf(Date), _propTypes.default.number]),
@@ -350,6 +353,7 @@ process.env.NODE_ENV !== "production" ? ChartContainer.propTypes = {
350
353
  fill: _propTypes.default.string,
351
354
  hideTooltip: _propTypes.default.bool,
352
355
  id: _propTypes.default.oneOfType([_propTypes.default.number, _propTypes.default.string]),
356
+ ignoreTooltip: _propTypes.default.bool,
353
357
  label: _propTypes.default.string,
354
358
  labelStyle: _propTypes.default.object,
355
359
  max: _propTypes.default.oneOfType([_propTypes.default.instanceOf(Date), _propTypes.default.number]),
@@ -24,15 +24,11 @@ const Root = (0, _styles.styled)('div', {
24
24
  })(() => {
25
25
  return {
26
26
  display: 'flex',
27
- alignItems: 'center',
28
- justifyContent: 'center',
29
- flexShrink: 0,
30
27
  width: 14,
31
28
  height: 14,
32
29
  [`&.${_labelMarkClasses.labelMarkClasses.line}`]: {
33
30
  width: 16,
34
31
  height: 'unset',
35
- display: 'flex',
36
32
  alignItems: 'center',
37
33
  [`.${_labelMarkClasses.labelMarkClasses.mask}`]: {
38
34
  height: 4,
@@ -1,4 +1,5 @@
1
1
  export type { ChartsLabelMarkProps, ChartsLabelCustomMarkProps } from './ChartsLabelMark';
2
+ export { ChartsLabelMark } from "./ChartsLabelMark.js";
2
3
  export { labelClasses } from "./labelClasses.js";
3
4
  export type { ChartsLabelClasses } from './labelClasses';
4
5
  export { labelMarkClasses } from "./labelMarkClasses.js";
@@ -3,6 +3,12 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
+ Object.defineProperty(exports, "ChartsLabelMark", {
7
+ enumerable: true,
8
+ get: function () {
9
+ return _ChartsLabelMark.ChartsLabelMark;
10
+ }
11
+ });
6
12
  Object.defineProperty(exports, "labelClasses", {
7
13
  enumerable: true,
8
14
  get: function () {
@@ -21,6 +27,7 @@ Object.defineProperty(exports, "labelMarkClasses", {
21
27
  return _labelMarkClasses.labelMarkClasses;
22
28
  }
23
29
  });
30
+ var _ChartsLabelMark = require("./ChartsLabelMark");
24
31
  var _labelClasses = require("./labelClasses");
25
32
  var _labelMarkClasses = require("./labelMarkClasses");
26
33
  var _labelGradientClasses = require("./labelGradientClasses");
@@ -22,5 +22,5 @@ export interface ContinuousColorLegendClasses {
22
22
  /** Styles applied to the series label. */
23
23
  label: string;
24
24
  }
25
- export declare const useUtilityClasses: (props: ContinuousColorLegendProps & ChartsLegendSlotExtension) => Record<"root" | "label" | "mark" | "minLabel" | "maxLabel" | "gradient", string>;
25
+ export declare const useUtilityClasses: (props: ContinuousColorLegendProps & ChartsLegendSlotExtension) => Record<"root" | "label" | "mark" | "gradient" | "minLabel" | "maxLabel", string>;
26
26
  export declare const continuousColorLegendClasses: ContinuousColorLegendClasses;
@@ -13,7 +13,7 @@ var _Typography = _interopRequireDefault(require("@mui/material/Typography"));
13
13
  var _clsx = _interopRequireDefault(require("clsx"));
14
14
  var _chartsTooltipClasses = require("./chartsTooltipClasses");
15
15
  var _ChartsTooltipTable = require("./ChartsTooltipTable");
16
- var _useAxisTooltip = require("./useAxisTooltip");
16
+ var _useAxesTooltip = require("./useAxesTooltip");
17
17
  var _hooks = require("../hooks");
18
18
  var _ChartsLabelMark = require("../ChartsLabel/ChartsLabelMark");
19
19
  var _jsxRuntime = require("react/jsx-runtime");
@@ -22,70 +22,62 @@ function ChartsAxisTooltipContent(props) {
22
22
  classes: propClasses,
23
23
  sx
24
24
  } = props;
25
- const tooltipData = (0, _useAxisTooltip.useAxisTooltip)();
25
+ const tooltipData = (0, _useAxesTooltip.useAxesTooltip)();
26
26
  const xAxis = (0, _hooks.useXAxis)();
27
27
  const yAxis = (0, _hooks.useYAxis)();
28
28
  const classes = (0, _chartsTooltipClasses.useUtilityClasses)(propClasses);
29
29
  if (tooltipData === null) {
30
30
  return null;
31
31
  }
32
- const {
33
- axisDirection,
34
- axisValue,
35
- axisFormattedValue,
36
- seriesItems
37
- } = tooltipData;
38
- const axis = axisDirection === 'x' ? xAxis : yAxis;
39
32
  return /*#__PURE__*/(0, _jsxRuntime.jsx)(_ChartsTooltipTable.ChartsTooltipPaper, {
40
33
  sx: sx,
41
34
  className: classes.paper,
42
- children: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_ChartsTooltipTable.ChartsTooltipTable, {
43
- className: classes.table,
44
- children: [axisValue != null && !axis.hideTooltip && /*#__PURE__*/(0, _jsxRuntime.jsx)("thead", {
45
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_ChartsTooltipTable.ChartsTooltipRow, {
46
- className: classes.row,
47
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_ChartsTooltipTable.ChartsTooltipCell, {
48
- colSpan: 3,
49
- className: (0, _clsx.default)(classes.cell, classes.axisValueCell),
50
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_Typography.default, {
51
- children: axisFormattedValue
52
- })
53
- })
54
- })
55
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)("tbody", {
56
- children: seriesItems.map(({
57
- seriesId,
58
- color,
59
- formattedValue,
60
- formattedLabel,
61
- markType
62
- }) => {
63
- if (formattedValue == null) {
64
- return null;
65
- }
66
- return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_ChartsTooltipTable.ChartsTooltipRow, {
67
- className: classes.row,
68
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_ChartsTooltipTable.ChartsTooltipCell, {
69
- className: (0, _clsx.default)(classes.markCell, classes.cell),
70
- children: color && /*#__PURE__*/(0, _jsxRuntime.jsx)(_ChartsLabelMark.ChartsLabelMark, {
71
- type: markType,
72
- color: color,
73
- className: classes.mark
74
- })
75
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_ChartsTooltipTable.ChartsTooltipCell, {
76
- className: (0, _clsx.default)(classes.labelCell, classes.cell),
77
- children: formattedLabel ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_Typography.default, {
78
- children: formattedLabel
79
- }) : null
80
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_ChartsTooltipTable.ChartsTooltipCell, {
81
- className: (0, _clsx.default)(classes.valueCell, classes.cell),
82
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_Typography.default, {
35
+ children: tooltipData.map(({
36
+ axisId,
37
+ axisDirection,
38
+ axisValue,
39
+ axisFormattedValue,
40
+ seriesItems
41
+ }) => {
42
+ const axis = axisDirection === 'x' ? xAxis : yAxis;
43
+ return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_ChartsTooltipTable.ChartsTooltipTable, {
44
+ className: classes.table,
45
+ children: [axisValue != null && !axis.hideTooltip && /*#__PURE__*/(0, _jsxRuntime.jsx)(_Typography.default, {
46
+ component: "caption",
47
+ children: axisFormattedValue
48
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)("tbody", {
49
+ children: seriesItems.map(({
50
+ seriesId,
51
+ color,
52
+ formattedValue,
53
+ formattedLabel,
54
+ markType
55
+ }) => {
56
+ if (formattedValue == null) {
57
+ return null;
58
+ }
59
+ return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_ChartsTooltipTable.ChartsTooltipRow, {
60
+ className: classes.row,
61
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_ChartsTooltipTable.ChartsTooltipCell, {
62
+ className: (0, _clsx.default)(classes.labelCell, classes.cell),
63
+ component: "th",
64
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
65
+ className: classes.markContainer,
66
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_ChartsLabelMark.ChartsLabelMark, {
67
+ type: markType,
68
+ color: color,
69
+ className: classes.mark
70
+ })
71
+ }), formattedLabel || null]
72
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_ChartsTooltipTable.ChartsTooltipCell, {
73
+ className: (0, _clsx.default)(classes.valueCell, classes.cell),
74
+ component: "td",
83
75
  children: formattedValue
84
- })
85
- })]
86
- }, seriesId);
87
- })
88
- })]
76
+ })]
77
+ }, seriesId);
78
+ })
79
+ })]
80
+ }, axisId);
89
81
  })
90
82
  });
91
83
  }
@@ -39,18 +39,20 @@ function ChartsItemTooltipContent(props) {
39
39
  children: /*#__PURE__*/(0, _jsxRuntime.jsx)("tbody", {
40
40
  children: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_ChartsTooltipTable.ChartsTooltipRow, {
41
41
  className: classes.row,
42
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_ChartsTooltipTable.ChartsTooltipCell, {
43
- className: (0, _clsx.default)(classes.markCell, classes.cell),
44
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_ChartsLabelMark.ChartsLabelMark, {
45
- type: markType,
46
- color: color,
47
- className: classes.mark
48
- })
49
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_ChartsTooltipTable.ChartsTooltipCell, {
42
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_ChartsTooltipTable.ChartsTooltipCell, {
50
43
  className: (0, _clsx.default)(classes.labelCell, classes.cell),
51
- children: label
44
+ component: "th",
45
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
46
+ className: classes.markContainer,
47
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_ChartsLabelMark.ChartsLabelMark, {
48
+ type: markType,
49
+ color: color,
50
+ className: classes.mark
51
+ })
52
+ }), label]
52
53
  }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_ChartsTooltipTable.ChartsTooltipCell, {
53
54
  className: (0, _clsx.default)(classes.valueCell, classes.cell),
55
+ component: "td",
54
56
  children: formattedValue
55
57
  })]
56
58
  })
@@ -65,7 +65,7 @@ process.env.NODE_ENV !== "production" ? ChartsTooltip.propTypes = {
65
65
  * The components used for each slot inside the Popper.
66
66
  * Either a string to use a HTML element or a component.
67
67
  *
68
- * @deprecated use the `slots` prop instead. This prop will be removed in v7. [How to migrate](/material-ui/migration/migrating-from-deprecated-apis/).
68
+ * @deprecated use the `slots` prop instead. This prop will be removed in a future major release. [How to migrate](/material-ui/migration/migrating-from-deprecated-apis/).
69
69
  * @default {}
70
70
  */
71
71
  components: _propTypes.default.shape({
@@ -74,7 +74,7 @@ process.env.NODE_ENV !== "production" ? ChartsTooltip.propTypes = {
74
74
  /**
75
75
  * The props used for each slot inside the Popper.
76
76
  *
77
- * @deprecated use the `slotProps` prop instead. This prop will be removed in v7. [How to migrate](/material-ui/migration/migrating-from-deprecated-apis/).
77
+ * @deprecated use the `slotProps` prop instead. This prop will be removed in a future major release. [How to migrate](/material-ui/migration/migrating-from-deprecated-apis/).
78
78
  * @default {}
79
79
  */
80
80
  componentsProps: _propTypes.default.shape({
@@ -20,7 +20,6 @@ var _useSvgRef = require("../hooks/useSvgRef");
20
20
  var _utils = require("./utils");
21
21
  var _useSelector = require("../internals/store/useSelector");
22
22
  var _useStore = require("../internals/store/useStore");
23
- var _hooks = require("../hooks");
24
23
  var _useChartInteraction = require("../internals/plugins/featurePlugins/useChartInteraction");
25
24
  var _useChartCartesianAxis = require("../internals/plugins/featurePlugins/useChartCartesianAxis");
26
25
  var _jsxRuntime = require("react/jsx-runtime");
@@ -35,7 +34,6 @@ const ChartsTooltipRoot = (0, _styles.styled)(_Popper.default, {
35
34
  pointerEvents: 'none',
36
35
  zIndex: theme.zIndex.modal
37
36
  }));
38
- const axisHasData = axis => axis?.data !== undefined && axis.data.length !== 0;
39
37
 
40
38
  /**
41
39
  * Demos:
@@ -59,16 +57,13 @@ function ChartsTooltipContainer(inProps) {
59
57
  other = (0, _objectWithoutPropertiesLoose2.default)(props, _excluded);
60
58
  const svgRef = (0, _useSvgRef.useSvgRef)();
61
59
  const pointerType = (0, _utils.usePointerType)();
62
- const xAxis = (0, _hooks.useXAxis)();
63
60
  const popperRef = React.useRef(null);
64
61
  const positionRef = (0, _useLazyRef.default)(() => ({
65
62
  x: 0,
66
63
  y: 0
67
64
  }));
68
65
  const store = (0, _useStore.useStore)();
69
- const isOpen = (0, _useSelector.useSelector)(store,
70
- // eslint-disable-next-line no-nested-ternary
71
- trigger === 'axis' ? axisHasData(xAxis) ? _useChartCartesianAxis.selectorChartsInteractionXAxisIsDefined : _useChartCartesianAxis.selectorChartsInteractionYAxisIsDefined : _useChartInteraction.selectorChartsInteractionItemIsDefined);
66
+ const isOpen = (0, _useSelector.useSelector)(store, trigger === 'axis' ? _useChartCartesianAxis.selectorChartsInteractionAxisTooltip : _useChartInteraction.selectorChartsInteractionItemIsDefined);
72
67
  const popperOpen = pointerType !== null && isOpen; // tooltipHasData;
73
68
 
74
69
  React.useEffect(() => {
@@ -162,7 +157,7 @@ process.env.NODE_ENV !== "production" ? ChartsTooltipContainer.propTypes = {
162
157
  * The components used for each slot inside the Popper.
163
158
  * Either a string to use a HTML element or a component.
164
159
  *
165
- * @deprecated use the `slots` prop instead. This prop will be removed in v7. [How to migrate](/material-ui/migration/migrating-from-deprecated-apis/).
160
+ * @deprecated use the `slots` prop instead. This prop will be removed in a future major release. [How to migrate](/material-ui/migration/migrating-from-deprecated-apis/).
166
161
  * @default {}
167
162
  */
168
163
  components: _propTypes.default.shape({
@@ -171,7 +166,7 @@ process.env.NODE_ENV !== "production" ? ChartsTooltipContainer.propTypes = {
171
166
  /**
172
167
  * The props used for each slot inside the Popper.
173
168
  *
174
- * @deprecated use the `slotProps` prop instead. This prop will be removed in v7. [How to migrate](/material-ui/migration/migrating-from-deprecated-apis/).
169
+ * @deprecated use the `slotProps` prop instead. This prop will be removed in a future major release. [How to migrate](/material-ui/migration/migrating-from-deprecated-apis/).
175
170
  * @default {}
176
171
  */
177
172
  componentsProps: _propTypes.default.shape({
@@ -13,4 +13,6 @@ export declare const ChartsTooltipRow: import("@emotion/styled").StyledComponent
13
13
  /**
14
14
  * @ignore - internal component.
15
15
  */
16
- export declare const ChartsTooltipCell: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, Pick<import("react").DetailedHTMLProps<import("react").TdHTMLAttributes<HTMLTableDataCellElement>, HTMLTableDataCellElement>, keyof import("react").ClassAttributes<HTMLTableDataCellElement> | keyof import("react").TdHTMLAttributes<HTMLTableDataCellElement>>, {}>;
16
+ export declare const ChartsTooltipCell: import("@emotion/styled").StyledComponent<Pick<import("@mui/material").TypographyOwnProps & import("@mui/material/OverridableComponent").CommonProps & Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "p" | "style" | "typography" | "zIndex" | "classes" | "border" | "boxShadow" | "fontWeight" | "alignContent" | "alignItems" | "alignSelf" | "bottom" | "boxSizing" | "color" | "columnGap" | "display" | "flexBasis" | "flexDirection" | "flexGrow" | "flexShrink" | "flexWrap" | "fontFamily" | "fontSize" | "fontStyle" | "gridAutoColumns" | "gridAutoFlow" | "gridAutoRows" | "gridTemplateAreas" | "gridTemplateColumns" | "gridTemplateRows" | "height" | "justifyContent" | "justifyItems" | "justifySelf" | "left" | "letterSpacing" | "lineHeight" | "marginBlockEnd" | "marginBlockStart" | "marginBottom" | "marginInlineEnd" | "marginInlineStart" | "marginLeft" | "marginRight" | "marginTop" | "maxHeight" | "maxWidth" | "minHeight" | "minWidth" | "order" | "paddingBlockEnd" | "paddingBlockStart" | "paddingBottom" | "paddingInlineEnd" | "paddingInlineStart" | "paddingLeft" | "paddingRight" | "paddingTop" | "position" | "right" | "rowGap" | "textAlign" | "textOverflow" | "textTransform" | "top" | "visibility" | "whiteSpace" | "width" | "borderBottom" | "borderColor" | "borderLeft" | "borderRadius" | "borderRight" | "borderTop" | "flex" | "gap" | "gridArea" | "gridColumn" | "gridRow" | "margin" | "marginBlock" | "marginInline" | "overflow" | "padding" | "paddingBlock" | "paddingInline" | "bgcolor" | "m" | "mt" | "mr" | "mb" | "ml" | "mx" | "marginX" | "my" | "marginY" | "pt" | "pr" | "pb" | "pl" | "px" | "paddingX" | "py" | "paddingY" | "displayPrint" | "className" | "children" | "sx" | "align" | "gutterBottom" | "noWrap" | "paragraph" | "variant" | "variantMapping">, "p" | "slot" | "style" | "title" | "ref" | "typography" | "zIndex" | "classes" | "border" | "boxShadow" | "fontWeight" | "alignContent" | "alignItems" | "alignSelf" | "bottom" | "boxSizing" | "color" | "columnGap" | "content" | "display" | "flexBasis" | "flexDirection" | "flexGrow" | "flexShrink" | "flexWrap" | "fontFamily" | "fontSize" | "fontStyle" | "gridAutoColumns" | "gridAutoFlow" | "gridAutoRows" | "gridTemplateAreas" | "gridTemplateColumns" | "gridTemplateRows" | "height" | "justifyContent" | "justifyItems" | "justifySelf" | "left" | "letterSpacing" | "lineHeight" | "marginBlockEnd" | "marginBlockStart" | "marginBottom" | "marginInlineEnd" | "marginInlineStart" | "marginLeft" | "marginRight" | "marginTop" | "maxHeight" | "maxWidth" | "minHeight" | "minWidth" | "order" | "paddingBlockEnd" | "paddingBlockStart" | "paddingBottom" | "paddingInlineEnd" | "paddingInlineStart" | "paddingLeft" | "paddingRight" | "paddingTop" | "position" | "right" | "rowGap" | "textAlign" | "textOverflow" | "textTransform" | "top" | "translate" | "visibility" | "whiteSpace" | "width" | "borderBottom" | "borderColor" | "borderLeft" | "borderRadius" | "borderRight" | "borderTop" | "flex" | "gap" | "gridArea" | "gridColumn" | "gridRow" | "margin" | "marginBlock" | "marginInline" | "overflow" | "padding" | "paddingBlock" | "paddingInline" | "bgcolor" | "m" | "mt" | "mr" | "mb" | "ml" | "mx" | "marginX" | "my" | "marginY" | "pt" | "pr" | "pb" | "pl" | "px" | "paddingX" | "py" | "paddingY" | "displayPrint" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "autoCapitalize" | "autoFocus" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "enterKeyHint" | "hidden" | "id" | "lang" | "nonce" | "spellCheck" | "tabIndex" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "rel" | "resource" | "rev" | "typeof" | "vocab" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "popover" | "popoverTargetAction" | "popoverTarget" | "inert" | "inputMode" | "is" | "exportparts" | "part" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-braillelabel" | "aria-brailleroledescription" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colindextext" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-description" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowindextext" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onResize" | "onResizeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerLeave" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onScrollEnd" | "onScrollEndCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onToggle" | "onBeforeToggle" | "onTransitionCancel" | "onTransitionCancelCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "onTransitionRun" | "onTransitionRunCapture" | "onTransitionStart" | "onTransitionStartCapture" | "sx" | "align" | "gutterBottom" | "noWrap" | "paragraph" | "variant" | "variantMapping"> & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme> & {
17
+ component?: React.ElementType;
18
+ }, {}, {}>;
@@ -1,10 +1,12 @@
1
1
  "use strict";
2
2
 
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
3
4
  Object.defineProperty(exports, "__esModule", {
4
5
  value: true
5
6
  });
6
7
  exports.ChartsTooltipTable = exports.ChartsTooltipRow = exports.ChartsTooltipPaper = exports.ChartsTooltipCell = void 0;
7
8
  var _styles = require("@mui/material/styles");
9
+ var _Typography = _interopRequireDefault(require("@mui/material/Typography"));
8
10
  var _chartsTooltipClasses = require("./chartsTooltipClasses");
9
11
  /**
10
12
  * @ignore - internal component.
@@ -33,8 +35,14 @@ const ChartsTooltipTable = exports.ChartsTooltipTable = (0, _styles.styled)('tab
33
35
  theme
34
36
  }) => ({
35
37
  borderSpacing: 0,
36
- '& thead td': {
37
- borderBottom: `solid ${(theme.vars || theme).palette.divider} 1px`
38
+ '& caption': {
39
+ borderBottom: `solid ${(theme.vars || theme).palette.divider} 1px`,
40
+ padding: theme.spacing(0.5, 1.5),
41
+ textAlign: 'start',
42
+ whiteSpace: 'nowrap',
43
+ '& span': {
44
+ marginRight: theme.spacing(1.5)
45
+ }
38
46
  }
39
47
  }));
40
48
 
@@ -59,20 +67,27 @@ const ChartsTooltipRow = exports.ChartsTooltipRow = (0, _styles.styled)('tr', {
59
67
  /**
60
68
  * @ignore - internal component.
61
69
  */
62
- const ChartsTooltipCell = exports.ChartsTooltipCell = (0, _styles.styled)('td', {
70
+ const ChartsTooltipCell = exports.ChartsTooltipCell = (0, _styles.styled)(_Typography.default, {
63
71
  name: 'MuiChartsTooltip',
64
- slot: 'Cell',
65
- overridesResolver: (props, styles) => styles.cell
72
+ slot: 'Cell'
66
73
  })(({
67
74
  theme
68
75
  }) => ({
69
76
  verticalAlign: 'middle',
70
77
  color: (theme.vars || theme).palette.text.secondary,
71
- [`&.${_chartsTooltipClasses.chartsTooltipClasses.labelCell}`]: {
78
+ textAlign: 'start',
79
+ [`&.${_chartsTooltipClasses.chartsTooltipClasses.cell}`]: {
72
80
  paddingLeft: theme.spacing(1),
73
- paddingRight: theme.spacing(1.5),
81
+ paddingRight: theme.spacing(1)
82
+ },
83
+ [`&.${_chartsTooltipClasses.chartsTooltipClasses.labelCell}`]: {
74
84
  fontWeight: theme.typography.fontWeightRegular
75
85
  },
86
+ [`& .${_chartsTooltipClasses.chartsTooltipClasses.markContainer}`]: {
87
+ display: 'inline-block',
88
+ width: `calc(20px + ${theme.spacing(1.5)})`,
89
+ verticalAlign: 'middle'
90
+ },
76
91
  [`&.${_chartsTooltipClasses.chartsTooltipClasses.valueCell}, &.${_chartsTooltipClasses.chartsTooltipClasses.axisValueCell}`]: {
77
92
  color: (theme.vars || theme).palette.text.primary,
78
93
  fontWeight: theme.typography.fontWeightMedium
@@ -81,10 +96,10 @@ const ChartsTooltipCell = exports.ChartsTooltipCell = (0, _styles.styled)('td',
81
96
  paddingLeft: theme.spacing(1.5),
82
97
  paddingRight: theme.spacing(1.5)
83
98
  },
84
- 'td:first-of-type&': {
99
+ 'td:first-of-type&, th:first-of-type&': {
85
100
  paddingLeft: theme.spacing(1.5)
86
101
  },
87
- 'td:last-of-type&': {
102
+ 'td:last-of-type&, th:last-of-type&': {
88
103
  paddingRight: theme.spacing(1.5)
89
104
  }
90
105
  }));
@@ -11,8 +11,8 @@ export interface ChartsTooltipClasses {
11
11
  cell: string;
12
12
  /** Styles applied to the mark element. */
13
13
  mark: string;
14
- /** Styles applied to the markCell element. */
15
- markCell: string;
14
+ /** Styles applied to the markContainer element. */
15
+ markContainer: string;
16
16
  /** Styles applied to the labelCell element. */
17
17
  labelCell: string;
18
18
  /** Styles applied to the valueCell element. */
@@ -20,7 +20,7 @@ export interface ChartsTooltipClasses {
20
20
  /** Styles applied to the axisValueCell element. Only available for axis tooltip. */
21
21
  axisValueCell: string;
22
22
  }
23
- export type ChartsTooltipClassKey = keyof Omit<ChartsTooltipClasses, 'markCell' | 'labelCell' | 'valueCell'>;
23
+ export type ChartsTooltipClassKey = keyof Omit<ChartsTooltipClasses, 'markContainer' | 'labelCell' | 'valueCell'>;
24
24
  export declare function getChartsTooltipUtilityClass(slot: string): string;
25
25
  export declare const chartsTooltipClasses: ChartsTooltipClasses;
26
- export declare const useUtilityClasses: (classes?: Partial<ChartsTooltipClasses>) => Record<"root" | "mark" | "table" | "cell" | "row" | "markCell" | "labelCell" | "valueCell" | "paper" | "axisValueCell", string>;
26
+ export declare const useUtilityClasses: (classes?: Partial<ChartsTooltipClasses>) => Record<"root" | "mark" | "table" | "cell" | "row" | "markContainer" | "labelCell" | "valueCell" | "paper" | "axisValueCell", string>;
@@ -13,7 +13,7 @@ var _composeClasses = _interopRequireDefault(require("@mui/utils/composeClasses"
13
13
  function getChartsTooltipUtilityClass(slot) {
14
14
  return (0, _generateUtilityClass.default)('MuiChartsTooltip', slot);
15
15
  }
16
- const chartsTooltipClasses = exports.chartsTooltipClasses = (0, _generateUtilityClasses.default)('MuiChartsTooltip', ['root', 'paper', 'table', 'row', 'cell', 'mark', 'markCell', 'labelCell', 'valueCell', 'axisValueCell']);
16
+ const chartsTooltipClasses = exports.chartsTooltipClasses = (0, _generateUtilityClasses.default)('MuiChartsTooltip', ['root', 'paper', 'table', 'row', 'cell', 'mark', 'markContainer', 'labelCell', 'valueCell', 'axisValueCell']);
17
17
  const useUtilityClasses = classes => {
18
18
  const slots = {
19
19
  root: ['root'],
@@ -22,7 +22,7 @@ const useUtilityClasses = classes => {
22
22
  row: ['row'],
23
23
  cell: ['cell'],
24
24
  mark: ['mark'],
25
- markCell: ['markCell'],
25
+ markContainer: ['markContainer'],
26
26
  labelCell: ['labelCell'],
27
27
  valueCell: ['valueCell'],
28
28
  axisValueCell: ['axisValueCell']
@@ -7,5 +7,6 @@ export * from "./ChartsItemTooltipContent.js";
7
7
  export * from "./ChartsTooltipTable.js";
8
8
  export * from "./useItemTooltip.js";
9
9
  export * from "./useAxisTooltip.js";
10
+ export * from "./useAxesTooltip.js";
10
11
  export { useMouseTracker } from "./utils.js";
11
12
  export * from "./ChartTooltip.types.js";
@@ -111,6 +111,18 @@ Object.keys(_useAxisTooltip).forEach(function (key) {
111
111
  }
112
112
  });
113
113
  });
114
+ var _useAxesTooltip = require("./useAxesTooltip");
115
+ Object.keys(_useAxesTooltip).forEach(function (key) {
116
+ if (key === "default" || key === "__esModule") return;
117
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
118
+ if (key in exports && exports[key] === _useAxesTooltip[key]) return;
119
+ Object.defineProperty(exports, key, {
120
+ enumerable: true,
121
+ get: function () {
122
+ return _useAxesTooltip[key];
123
+ }
124
+ });
125
+ });
114
126
  var _utils = require("./utils");
115
127
  var _ChartTooltip = require("./ChartTooltip.types");
116
128
  Object.keys(_ChartTooltip).forEach(function (key) {