@mui/x-charts 9.4.0 → 9.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (288) hide show
  1. package/BarChart/BarChart.js +1 -1
  2. package/BarChart/BarChart.mjs +1 -1
  3. package/BarChart/BarElement.js +2 -1
  4. package/BarChart/BarElement.mjs +2 -1
  5. package/BarChart/BarLabel/BarLabel.js +1 -1
  6. package/BarChart/BarLabel/BarLabel.mjs +1 -1
  7. package/BarChart/BarPlot.js +1 -1
  8. package/BarChart/BarPlot.mjs +1 -1
  9. package/CHANGELOG.md +251 -0
  10. package/ChartsAxis/ChartsAxis.js +1 -1
  11. package/ChartsAxis/ChartsAxis.mjs +1 -1
  12. package/ChartsAxisHighlight/ChartsAxisHighlight.js +1 -1
  13. package/ChartsAxisHighlight/ChartsAxisHighlight.mjs +1 -1
  14. package/ChartsAxisHighlightValue/ChartsAxisHighlightValue.js +2 -2
  15. package/ChartsAxisHighlightValue/ChartsAxisHighlightValue.mjs +2 -2
  16. package/ChartsBrushOverlay/ChartsBrushOverlay.d.mts +5 -1
  17. package/ChartsBrushOverlay/ChartsBrushOverlay.d.ts +5 -1
  18. package/ChartsBrushOverlay/ChartsBrushOverlay.js +12 -1
  19. package/ChartsBrushOverlay/ChartsBrushOverlay.mjs +14 -2
  20. package/ChartsClipPath/ChartsClipPath.js +1 -1
  21. package/ChartsClipPath/ChartsClipPath.mjs +1 -1
  22. package/ChartsContainer/ChartsContainer.js +5 -3
  23. package/ChartsContainer/ChartsContainer.mjs +5 -3
  24. package/ChartsDataProvider/ChartsDataProvider.js +5 -1
  25. package/ChartsDataProvider/ChartsDataProvider.mjs +5 -1
  26. package/ChartsGrid/ChartsGrid.js +5 -1
  27. package/ChartsGrid/ChartsGrid.mjs +5 -1
  28. package/ChartsLayerContainer/ChartsLayerContainer.js +1 -1
  29. package/ChartsLayerContainer/ChartsLayerContainer.mjs +1 -1
  30. package/ChartsLocalizationProvider/ChartsLocalizationProvider.js +1 -1
  31. package/ChartsLocalizationProvider/ChartsLocalizationProvider.mjs +1 -1
  32. package/ChartsRadialAxisHighlight/ChartsRadialAxisHighlight.js +2 -2
  33. package/ChartsRadialAxisHighlight/ChartsRadialAxisHighlight.mjs +2 -2
  34. package/ChartsRadialAxisHighlight/index.d.mts +6 -1
  35. package/ChartsRadialAxisHighlight/index.d.ts +6 -1
  36. package/ChartsRadialAxisHighlight/index.js +9 -2
  37. package/ChartsRadialAxisHighlight/index.mjs +8 -1
  38. package/ChartsRadialDataProvider/ChartsRadialDataProvider.d.mts +1 -1
  39. package/ChartsRadialDataProvider/ChartsRadialDataProvider.d.ts +1 -1
  40. package/ChartsRadialDataProvider/ChartsRadialDataProvider.js +10 -2
  41. package/ChartsRadialDataProvider/ChartsRadialDataProvider.mjs +10 -2
  42. package/ChartsRadialDataProvider/index.d.mts +5 -0
  43. package/ChartsRadialDataProvider/index.d.ts +5 -0
  44. package/ChartsRadialDataProvider/index.js +12 -1
  45. package/ChartsRadialDataProvider/index.mjs +7 -0
  46. package/ChartsRadialGrid/ChartsRadialGrid.js +5 -1
  47. package/ChartsRadialGrid/ChartsRadialGrid.mjs +5 -1
  48. package/ChartsRadialGrid/index.d.mts +6 -1
  49. package/ChartsRadialGrid/index.d.ts +6 -1
  50. package/ChartsRadialGrid/index.js +8 -2
  51. package/ChartsRadialGrid/index.mjs +8 -1
  52. package/ChartsRadiusAxis/ChartsRadiusAxis.d.mts +8 -2
  53. package/ChartsRadiusAxis/ChartsRadiusAxis.d.ts +8 -2
  54. package/ChartsRadiusAxis/ChartsRadiusAxis.js +143 -3
  55. package/ChartsRadiusAxis/ChartsRadiusAxis.mjs +144 -5
  56. package/ChartsRadiusAxis/index.d.mts +6 -1
  57. package/ChartsRadiusAxis/index.d.ts +6 -1
  58. package/ChartsRadiusAxis/index.js +10 -2
  59. package/ChartsRadiusAxis/index.mjs +7 -1
  60. package/ChartsReferenceLine/ChartsReferenceLine.js +1 -1
  61. package/ChartsReferenceLine/ChartsReferenceLine.mjs +1 -1
  62. package/ChartsRotationAxis/ChartsRotationAxis.d.mts +8 -2
  63. package/ChartsRotationAxis/ChartsRotationAxis.d.ts +8 -2
  64. package/ChartsRotationAxis/ChartsRotationAxis.js +140 -3
  65. package/ChartsRotationAxis/ChartsRotationAxis.mjs +141 -5
  66. package/ChartsRotationAxis/index.d.mts +6 -1
  67. package/ChartsRotationAxis/index.d.ts +6 -1
  68. package/ChartsRotationAxis/index.js +10 -2
  69. package/ChartsRotationAxis/index.mjs +7 -1
  70. package/ChartsSurface/ChartsSurface.js +1 -1
  71. package/ChartsSurface/ChartsSurface.mjs +1 -1
  72. package/ChartsSvgLayer/ChartsSvgLayer.js +1 -1
  73. package/ChartsSvgLayer/ChartsSvgLayer.mjs +1 -1
  74. package/ChartsText/ChartsText.js +2 -2
  75. package/ChartsText/ChartsText.mjs +2 -2
  76. package/ChartsTooltip/ChartsAxisTooltipContent.js +22 -3
  77. package/ChartsTooltip/ChartsAxisTooltipContent.mjs +22 -3
  78. package/ChartsTooltip/ChartsItemTooltipContent.js +52 -1
  79. package/ChartsTooltip/ChartsItemTooltipContent.mjs +52 -1
  80. package/ChartsTooltip/ChartsTooltip.js +13 -33
  81. package/ChartsTooltip/ChartsTooltip.mjs +13 -33
  82. package/ChartsTooltip/ChartsTooltipContainer.js +17 -30
  83. package/ChartsTooltip/ChartsTooltipContainer.mjs +17 -30
  84. package/ChartsWrapper/ChartsWrapper.js +1 -1
  85. package/ChartsWrapper/ChartsWrapper.mjs +1 -1
  86. package/ChartsXAxis/ChartsSingleXAxisTicks.js +1 -1
  87. package/ChartsXAxis/ChartsSingleXAxisTicks.mjs +1 -1
  88. package/ChartsXAxis/ChartsXAxis.js +11 -2
  89. package/ChartsXAxis/ChartsXAxis.mjs +11 -2
  90. package/ChartsYAxis/ChartsSingleYAxisTicks.js +1 -1
  91. package/ChartsYAxis/ChartsSingleYAxisTicks.mjs +1 -1
  92. package/ChartsYAxis/ChartsYAxis.js +11 -2
  93. package/ChartsYAxis/ChartsYAxis.mjs +11 -2
  94. package/ChartsYAxis/ChartsYAxisImpl.js +1 -1
  95. package/ChartsYAxis/ChartsYAxisImpl.mjs +1 -1
  96. package/Gauge/Gauge.js +1 -1
  97. package/Gauge/Gauge.mjs +1 -1
  98. package/Gauge/GaugeContainer.js +1 -1
  99. package/Gauge/GaugeContainer.mjs +1 -1
  100. package/Gauge/GaugeValueArc.js +2 -2
  101. package/Gauge/GaugeValueArc.mjs +2 -2
  102. package/Gauge/GaugeValueText.js +1 -1
  103. package/Gauge/GaugeValueText.mjs +1 -1
  104. package/LineChart/AnimatedArea.js +3 -3
  105. package/LineChart/AnimatedArea.mjs +3 -3
  106. package/LineChart/AnimatedLine.js +1 -1
  107. package/LineChart/AnimatedLine.mjs +1 -1
  108. package/LineChart/AreaElement.js +2 -2
  109. package/LineChart/AreaElement.mjs +2 -2
  110. package/LineChart/AreaPlot.js +1 -1
  111. package/LineChart/AreaPlot.mjs +1 -1
  112. package/LineChart/CircleMarkElement.js +1 -1
  113. package/LineChart/CircleMarkElement.mjs +1 -1
  114. package/LineChart/LineChart.js +1 -1
  115. package/LineChart/LineChart.mjs +1 -1
  116. package/LineChart/LineElement.js +5 -3
  117. package/LineChart/LineElement.mjs +5 -3
  118. package/LineChart/LineHighlightElement.js +1 -2
  119. package/LineChart/LineHighlightElement.mjs +1 -2
  120. package/LineChart/LineHighlightPlot.js +1 -1
  121. package/LineChart/LineHighlightPlot.mjs +1 -1
  122. package/LineChart/LinePlot.js +1 -1
  123. package/LineChart/LinePlot.mjs +1 -1
  124. package/LineChart/MarkElement.js +4 -3
  125. package/LineChart/MarkElement.mjs +4 -3
  126. package/LineChart/MarkPlot.js +2 -1
  127. package/LineChart/MarkPlot.mjs +2 -1
  128. package/PieChart/FocusedPieArc.d.mts +5 -1
  129. package/PieChart/FocusedPieArc.d.ts +5 -1
  130. package/PieChart/FocusedPieArc.js +22 -1
  131. package/PieChart/FocusedPieArc.mjs +24 -2
  132. package/PieChart/PieArc.js +1 -1
  133. package/PieChart/PieArc.mjs +1 -1
  134. package/PieChart/PieArcLabel.js +1 -1
  135. package/PieChart/PieArcLabel.mjs +1 -1
  136. package/PieChart/PieArcLabelPlot.js +7 -6
  137. package/PieChart/PieArcLabelPlot.mjs +7 -6
  138. package/PieChart/PieArcPlot.js +7 -6
  139. package/PieChart/PieArcPlot.mjs +7 -6
  140. package/PieChart/PieChart.js +1 -1
  141. package/PieChart/PieChart.mjs +1 -1
  142. package/PieChart/PiePlot.js +2 -1
  143. package/PieChart/PiePlot.mjs +2 -1
  144. package/RadarChart/RadarAxis/RadarAxis.js +5 -1
  145. package/RadarChart/RadarAxis/RadarAxis.mjs +5 -1
  146. package/RadarChart/RadarAxisHighlight/RadarAxisHighlight.js +6 -2
  147. package/RadarChart/RadarAxisHighlight/RadarAxisHighlight.mjs +6 -2
  148. package/RadarChart/RadarChart.js +1 -1
  149. package/RadarChart/RadarChart.mjs +1 -1
  150. package/RadarChart/RadarGrid/RadarGrid.js +1 -5
  151. package/RadarChart/RadarGrid/RadarGrid.mjs +1 -5
  152. package/RadarChart/RadarSeriesPlot/RadarSeriesArea.js +5 -1
  153. package/RadarChart/RadarSeriesPlot/RadarSeriesArea.mjs +5 -1
  154. package/RadarChart/RadarSeriesPlot/RadarSeriesMarks.js +5 -1
  155. package/RadarChart/RadarSeriesPlot/RadarSeriesMarks.mjs +5 -1
  156. package/RadarChart/RadarSeriesPlot/RadarSeriesPlot.js +5 -1
  157. package/RadarChart/RadarSeriesPlot/RadarSeriesPlot.mjs +5 -1
  158. package/ScatterChart/Scatter.js +1 -1
  159. package/ScatterChart/Scatter.mjs +1 -1
  160. package/ScatterChart/ScatterChart.js +12 -6
  161. package/ScatterChart/ScatterChart.mjs +12 -6
  162. package/ScatterChart/ScatterChart.plugins.d.mts +2 -1
  163. package/ScatterChart/ScatterChart.plugins.d.ts +2 -1
  164. package/ScatterChart/ScatterChart.plugins.js +2 -1
  165. package/ScatterChart/ScatterChart.plugins.mjs +2 -1
  166. package/ScatterChart/ScatterMarker.js +2 -2
  167. package/ScatterChart/ScatterMarker.mjs +2 -2
  168. package/ScatterChart/ScatterPlot.d.mts +12 -3
  169. package/ScatterChart/ScatterPlot.d.ts +12 -3
  170. package/ScatterChart/ScatterPlot.js +30 -5
  171. package/ScatterChart/ScatterPlot.mjs +30 -5
  172. package/ScatterChart/async/ScatterAsync.d.mts +9 -0
  173. package/ScatterChart/async/ScatterAsync.d.ts +9 -0
  174. package/ScatterChart/async/ScatterAsync.js +71 -0
  175. package/ScatterChart/async/ScatterAsync.mjs +67 -0
  176. package/ScatterChart/async/ScatterAsyncBatch.d.mts +24 -0
  177. package/ScatterChart/async/ScatterAsyncBatch.d.ts +24 -0
  178. package/ScatterChart/async/ScatterAsyncBatch.js +112 -0
  179. package/ScatterChart/async/ScatterAsyncBatch.mjs +106 -0
  180. package/ScatterChart/async/scatterRenderData.selectors.d.mts +38 -0
  181. package/ScatterChart/async/scatterRenderData.selectors.d.ts +38 -0
  182. package/ScatterChart/async/scatterRenderData.selectors.js +93 -0
  183. package/ScatterChart/async/scatterRenderData.selectors.mjs +87 -0
  184. package/ScatterChart/seriesConfig/getColor.js +6 -15
  185. package/ScatterChart/seriesConfig/getColor.mjs +6 -15
  186. package/SparkLineChart/SparkLineChart.js +3 -2
  187. package/SparkLineChart/SparkLineChart.mjs +3 -2
  188. package/Toolbar/Toolbar.js +1 -1
  189. package/Toolbar/Toolbar.mjs +1 -1
  190. package/Toolbar/ToolbarButton.js +1 -1
  191. package/Toolbar/ToolbarButton.mjs +1 -1
  192. package/index.d.mts +1 -1
  193. package/index.d.ts +1 -1
  194. package/index.js +1 -1
  195. package/index.mjs +1 -1
  196. package/internals/colorScale.d.mts +2 -2
  197. package/internals/colorScale.d.ts +2 -2
  198. package/internals/colorScale.js +2 -2
  199. package/internals/colorScale.mjs +2 -2
  200. package/internals/getSeriesColorFn.d.mts +5 -5
  201. package/internals/getSeriesColorFn.d.ts +5 -5
  202. package/internals/index.d.mts +3 -0
  203. package/internals/index.d.ts +3 -0
  204. package/internals/index.js +20 -0
  205. package/internals/index.mjs +3 -0
  206. package/internals/plugins/allPlugins.d.mts +4 -3
  207. package/internals/plugins/allPlugins.d.ts +4 -3
  208. package/internals/plugins/allPlugins.js +2 -1
  209. package/internals/plugins/allPlugins.mjs +2 -1
  210. package/internals/plugins/corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.selectors.d.mts +12 -3
  211. package/internals/plugins/corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.selectors.d.ts +12 -3
  212. package/internals/plugins/corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.selectors.js +10 -1
  213. package/internals/plugins/corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.selectors.mjs +10 -1
  214. package/internals/plugins/corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.d.mts +15 -1
  215. package/internals/plugins/corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.d.ts +15 -1
  216. package/internals/plugins/corePlugins/useChartInteractionListener/useChartInteractionListener.js +16 -30
  217. package/internals/plugins/corePlugins/useChartInteractionListener/useChartInteractionListener.mjs +17 -31
  218. package/internals/plugins/corePlugins/useChartInteractionListener/useChartInteractionListener.types.d.mts +8 -1
  219. package/internals/plugins/corePlugins/useChartInteractionListener/useChartInteractionListener.types.d.ts +8 -1
  220. package/internals/plugins/corePlugins/useChartSeriesConfig/types/colorProcessor.types.d.mts +1 -1
  221. package/internals/plugins/corePlugins/useChartSeriesConfig/types/colorProcessor.types.d.ts +1 -1
  222. package/internals/plugins/corePlugins/useChartSeriesConfig/types/tooltipItemPositionGetter.types.d.mts +7 -0
  223. package/internals/plugins/corePlugins/useChartSeriesConfig/types/tooltipItemPositionGetter.types.d.ts +7 -0
  224. package/internals/plugins/featurePlugins/useChartCartesianAxis/domain.d.mts +0 -8
  225. package/internals/plugins/featurePlugins/useChartCartesianAxis/domain.d.ts +0 -8
  226. package/internals/plugins/featurePlugins/useChartCartesianAxis/domain.js +1 -2
  227. package/internals/plugins/featurePlugins/useChartCartesianAxis/domain.mjs +2 -2
  228. package/internals/plugins/featurePlugins/useChartCartesianAxis/getAxisScale.js +27 -2
  229. package/internals/plugins/featurePlugins/useChartCartesianAxis/getAxisScale.mjs +27 -2
  230. package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianAxis.js +1 -3
  231. package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianAxis.mjs +1 -3
  232. package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianAxisRendering.selectors.js +1 -1
  233. package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianAxisRendering.selectors.mjs +1 -1
  234. package/internals/plugins/featurePlugins/useChartPolarAxis/computeAxisValue.js +6 -1
  235. package/internals/plugins/featurePlugins/useChartPolarAxis/computeAxisValue.mjs +6 -1
  236. package/internals/plugins/featurePlugins/useChartTooltip/useChartTooltip.selectors.js +6 -2
  237. package/internals/plugins/featurePlugins/useChartTooltip/useChartTooltip.selectors.mjs +6 -2
  238. package/internals/plugins/featurePlugins/useGeoProjection/useGeoProjection.selectors.d.mts +49 -0
  239. package/internals/plugins/featurePlugins/useGeoProjection/useGeoProjection.selectors.d.ts +49 -0
  240. package/internals/plugins/featurePlugins/useGeoProjection/useGeoProjection.selectors.js +124 -0
  241. package/internals/plugins/featurePlugins/useGeoProjection/useGeoProjection.selectors.mjs +117 -0
  242. package/internals/plugins/featurePlugins/useGeoProjection/useGeoProjection.types.d.mts +64 -0
  243. package/internals/plugins/featurePlugins/useGeoProjection/useGeoProjection.types.d.ts +64 -0
  244. package/internals/plugins/featurePlugins/useGeoProjection/useGeoProjection.types.js +5 -0
  245. package/internals/plugins/featurePlugins/useGeoProjection/useGeoProjection.types.mjs +1 -0
  246. package/internals/plugins/featurePlugins/useProgressiveRendering/index.d.mts +3 -0
  247. package/internals/plugins/featurePlugins/useProgressiveRendering/index.d.ts +3 -0
  248. package/internals/plugins/featurePlugins/useProgressiveRendering/index.js +27 -0
  249. package/internals/plugins/featurePlugins/useProgressiveRendering/index.mjs +2 -0
  250. package/internals/plugins/featurePlugins/useProgressiveRendering/useProgressiveRendering.d.mts +13 -0
  251. package/internals/plugins/featurePlugins/useProgressiveRendering/useProgressiveRendering.d.ts +13 -0
  252. package/internals/plugins/featurePlugins/useProgressiveRendering/useProgressiveRendering.js +136 -0
  253. package/internals/plugins/featurePlugins/useProgressiveRendering/useProgressiveRendering.mjs +128 -0
  254. package/internals/plugins/featurePlugins/useProgressiveRendering/useProgressiveRendering.selectors.d.mts +42 -0
  255. package/internals/plugins/featurePlugins/useProgressiveRendering/useProgressiveRendering.selectors.d.ts +42 -0
  256. package/internals/plugins/featurePlugins/useProgressiveRendering/useProgressiveRendering.selectors.js +166 -0
  257. package/internals/plugins/featurePlugins/useProgressiveRendering/useProgressiveRendering.selectors.mjs +159 -0
  258. package/internals/plugins/featurePlugins/useProgressiveRendering/useProgressiveRendering.types.d.mts +34 -0
  259. package/internals/plugins/featurePlugins/useProgressiveRendering/useProgressiveRendering.types.d.ts +34 -0
  260. package/internals/plugins/featurePlugins/useProgressiveRendering/useProgressiveRendering.types.js +5 -0
  261. package/internals/plugins/featurePlugins/useProgressiveRendering/useProgressiveRendering.types.mjs +1 -0
  262. package/internals/resolveColorProcessor.js +4 -7
  263. package/internals/resolveColorProcessor.mjs +4 -7
  264. package/internals/scales/scaleBand.js +70 -43
  265. package/internals/scales/scaleBand.mjs +71 -44
  266. package/models/axis.d.mts +20 -4
  267. package/models/axis.d.ts +20 -4
  268. package/models/colorMapping.d.mts +8 -0
  269. package/models/colorMapping.d.ts +8 -0
  270. package/models/seriesType/bar.d.mts +1 -1
  271. package/models/seriesType/bar.d.ts +1 -1
  272. package/models/seriesType/common.d.mts +4 -4
  273. package/models/seriesType/common.d.ts +4 -4
  274. package/models/seriesType/config.d.mts +3 -3
  275. package/models/seriesType/config.d.ts +3 -3
  276. package/models/seriesType/line.d.mts +1 -1
  277. package/models/seriesType/line.d.ts +1 -1
  278. package/models/seriesType/pie.d.mts +1 -1
  279. package/models/seriesType/pie.d.ts +1 -1
  280. package/models/seriesType/radar.d.mts +1 -1
  281. package/models/seriesType/radar.d.ts +1 -1
  282. package/models/seriesType/scatter.d.mts +1 -1
  283. package/models/seriesType/scatter.d.ts +1 -1
  284. package/package.json +8 -5
  285. package/hooks/useIsHydrated.d.mts +0 -4
  286. package/hooks/useIsHydrated.d.ts +0 -4
  287. package/hooks/useIsHydrated.js +0 -19
  288. package/hooks/useIsHydrated.mjs +0 -14
@@ -0,0 +1,38 @@
1
+ /**
2
+ * Pre-computed render data for a single scatter series.
3
+ *
4
+ * Coordinates are stored in a packed `Float64Array` (stride 3: `[x0, y0, i0,
5
+ * x1, y1, i1, ...]`, where `iN` is the original `dataIndex`). Only points that
6
+ * project inside the drawing area are kept, so the progressive renderer can
7
+ * size its batches by the number of *visible* points — when zoomed in tightly
8
+ * the wave finishes in a single tick. Batches are contiguous slices of this
9
+ * array, so a batch's data is obtained with a zero-copy `subarray` view (see
10
+ * {@link getScatterBatchView}).
11
+ */
12
+ export interface ScatterSeriesRenderData {
13
+ /** Packed projected pixel coordinates + dataIndex, stride 3. */
14
+ coords: Float64Array;
15
+ /** Number of visible points (i.e. `coords.length / 3`). */
16
+ count: number;
17
+ }
18
+ /**
19
+ * Packed projected coordinates for every scatter series, filtered to the
20
+ * drawing area. Recomputes when the processed series, axis scales, or drawing
21
+ * area change.
22
+ */
23
+ export declare const selectorScatterRenderData: (args_0: import("../../internals/plugins/corePlugins/useChartId/useChartId.types.mjs").UseChartIdState & import("../../internals/plugins/corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.mjs").UseChartSeriesConfigState<keyof import("../../internals/index.mjs").ChartsSeriesConfig> & import("../../internals/plugins/corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.mjs").UseChartExperimentalFeaturesState & import("../../internals/plugins/corePlugins/useChartDimensions/useChartDimensions.types.mjs").UseChartDimensionsState & import("../../internals/plugins/corePlugins/useChartSeries/useChartSeries.types.mjs").UseChartSeriesState<keyof import("../../internals/index.mjs").ChartsSeriesConfig> & import("../../internals/plugins/corePlugins/useChartAnimation/useChartAnimation.types.mjs").UseChartAnimationState & import("../../internals/index.mjs").UseChartInteractionListenerState & Partial<{}> & {
24
+ cacheKey: import("../../internals/index.mjs").ChartStateCacheKey;
25
+ }) => Map<string, ScatterSeriesRenderData>;
26
+ /**
27
+ * Render data for a single scatter series, or `undefined` while it is not
28
+ * available yet (processors/axes still pending).
29
+ */
30
+ export declare const selectorScatterSeriesRenderData: (args_0: import("../../internals/plugins/corePlugins/useChartId/useChartId.types.mjs").UseChartIdState & import("../../internals/plugins/corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.mjs").UseChartSeriesConfigState<keyof import("../../internals/index.mjs").ChartsSeriesConfig> & import("../../internals/plugins/corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.mjs").UseChartExperimentalFeaturesState & import("../../internals/plugins/corePlugins/useChartDimensions/useChartDimensions.types.mjs").UseChartDimensionsState & import("../../internals/plugins/corePlugins/useChartSeries/useChartSeries.types.mjs").UseChartSeriesState<keyof import("../../internals/index.mjs").ChartsSeriesConfig> & import("../../internals/plugins/corePlugins/useChartAnimation/useChartAnimation.types.mjs").UseChartAnimationState & import("../../internals/index.mjs").UseChartInteractionListenerState & Partial<{}> & {
31
+ cacheKey: import("../../internals/index.mjs").ChartStateCacheKey;
32
+ }, seriesId: string) => ScatterSeriesRenderData | undefined;
33
+ /**
34
+ * Zero-copy view of one batch's coordinates. `start`/`end` are visible-point
35
+ * indices (not original `dataIndex` values). The returned `Float64Array` shares
36
+ * the buffer with `renderData.coords`.
37
+ */
38
+ export declare function getScatterBatchView(renderData: ScatterSeriesRenderData, start: number, end: number): Float64Array;
@@ -0,0 +1,38 @@
1
+ /**
2
+ * Pre-computed render data for a single scatter series.
3
+ *
4
+ * Coordinates are stored in a packed `Float64Array` (stride 3: `[x0, y0, i0,
5
+ * x1, y1, i1, ...]`, where `iN` is the original `dataIndex`). Only points that
6
+ * project inside the drawing area are kept, so the progressive renderer can
7
+ * size its batches by the number of *visible* points — when zoomed in tightly
8
+ * the wave finishes in a single tick. Batches are contiguous slices of this
9
+ * array, so a batch's data is obtained with a zero-copy `subarray` view (see
10
+ * {@link getScatterBatchView}).
11
+ */
12
+ export interface ScatterSeriesRenderData {
13
+ /** Packed projected pixel coordinates + dataIndex, stride 3. */
14
+ coords: Float64Array;
15
+ /** Number of visible points (i.e. `coords.length / 3`). */
16
+ count: number;
17
+ }
18
+ /**
19
+ * Packed projected coordinates for every scatter series, filtered to the
20
+ * drawing area. Recomputes when the processed series, axis scales, or drawing
21
+ * area change.
22
+ */
23
+ export declare const selectorScatterRenderData: (args_0: import("../../internals/plugins/corePlugins/useChartId/useChartId.types.js").UseChartIdState & import("../../internals/plugins/corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.js").UseChartSeriesConfigState<keyof import("../../internals/index.js").ChartsSeriesConfig> & import("../../internals/plugins/corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.js").UseChartExperimentalFeaturesState & import("../../internals/plugins/corePlugins/useChartDimensions/useChartDimensions.types.js").UseChartDimensionsState & import("../../internals/plugins/corePlugins/useChartSeries/useChartSeries.types.js").UseChartSeriesState<keyof import("../../internals/index.js").ChartsSeriesConfig> & import("../../internals/plugins/corePlugins/useChartAnimation/useChartAnimation.types.js").UseChartAnimationState & import("../../internals/index.js").UseChartInteractionListenerState & Partial<{}> & {
24
+ cacheKey: import("../../internals/index.js").ChartStateCacheKey;
25
+ }) => Map<string, ScatterSeriesRenderData>;
26
+ /**
27
+ * Render data for a single scatter series, or `undefined` while it is not
28
+ * available yet (processors/axes still pending).
29
+ */
30
+ export declare const selectorScatterSeriesRenderData: (args_0: import("../../internals/plugins/corePlugins/useChartId/useChartId.types.js").UseChartIdState & import("../../internals/plugins/corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.js").UseChartSeriesConfigState<keyof import("../../internals/index.js").ChartsSeriesConfig> & import("../../internals/plugins/corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.js").UseChartExperimentalFeaturesState & import("../../internals/plugins/corePlugins/useChartDimensions/useChartDimensions.types.js").UseChartDimensionsState & import("../../internals/plugins/corePlugins/useChartSeries/useChartSeries.types.js").UseChartSeriesState<keyof import("../../internals/index.js").ChartsSeriesConfig> & import("../../internals/plugins/corePlugins/useChartAnimation/useChartAnimation.types.js").UseChartAnimationState & import("../../internals/index.js").UseChartInteractionListenerState & Partial<{}> & {
31
+ cacheKey: import("../../internals/index.js").ChartStateCacheKey;
32
+ }, seriesId: string) => ScatterSeriesRenderData | undefined;
33
+ /**
34
+ * Zero-copy view of one batch's coordinates. `start`/`end` are visible-point
35
+ * indices (not original `dataIndex` values). The returned `Float64Array` shares
36
+ * the buffer with `renderData.coords`.
37
+ */
38
+ export declare function getScatterBatchView(renderData: ScatterSeriesRenderData, start: number, end: number): Float64Array;
@@ -0,0 +1,93 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.getScatterBatchView = getScatterBatchView;
7
+ exports.selectorScatterSeriesRenderData = exports.selectorScatterRenderData = void 0;
8
+ var _store = require("@mui/x-internals/store");
9
+ var _getValueToPositionMapper = require("../../hooks/getValueToPositionMapper");
10
+ var _useChartSeries = require("../../internals/plugins/corePlugins/useChartSeries");
11
+ var _useChartDimensions = require("../../internals/plugins/corePlugins/useChartDimensions");
12
+ var _useChartCartesianAxis = require("../../internals/plugins/featurePlugins/useChartCartesianAxis");
13
+ /**
14
+ * Pre-computed render data for a single scatter series.
15
+ *
16
+ * Coordinates are stored in a packed `Float64Array` (stride 3: `[x0, y0, i0,
17
+ * x1, y1, i1, ...]`, where `iN` is the original `dataIndex`). Only points that
18
+ * project inside the drawing area are kept, so the progressive renderer can
19
+ * size its batches by the number of *visible* points — when zoomed in tightly
20
+ * the wave finishes in a single tick. Batches are contiguous slices of this
21
+ * array, so a batch's data is obtained with a zero-copy `subarray` view (see
22
+ * {@link getScatterBatchView}).
23
+ */
24
+
25
+ const EMPTY_RENDER_DATA = new Map();
26
+
27
+ /**
28
+ * Packed projected coordinates for every scatter series, filtered to the
29
+ * drawing area. Recomputes when the processed series, axis scales, or drawing
30
+ * area change.
31
+ */
32
+ const selectorScatterRenderData = exports.selectorScatterRenderData = (0, _store.createSelectorMemoized)(_useChartSeries.selectorChartSeriesProcessed, _useChartCartesianAxis.selectorChartXAxis, _useChartCartesianAxis.selectorChartYAxis, _useChartDimensions.selectorChartDrawingArea, function selectorScatterRenderData(processedSeries, xAxes, yAxes, drawingArea) {
33
+ const scatter = processedSeries.scatter;
34
+ if (scatter === undefined) {
35
+ return EMPTY_RENDER_DATA;
36
+ }
37
+ const defaultXAxisId = xAxes.axisIds[0];
38
+ const defaultYAxisId = yAxes.axisIds[0];
39
+ const result = new Map();
40
+ const xMin = drawingArea.left - 1;
41
+ const xMax = drawingArea.left + drawingArea.width;
42
+ const yMin = drawingArea.top - 1;
43
+ const yMax = drawingArea.top + drawingArea.height;
44
+ for (const seriesId of scatter.seriesOrder) {
45
+ const series = scatter.series[seriesId];
46
+ const xAxis = xAxes.axis[series.xAxisId ?? defaultXAxisId];
47
+ const yAxis = yAxes.axis[series.yAxisId ?? defaultYAxisId];
48
+ if (xAxis === undefined || yAxis === undefined) {
49
+ continue;
50
+ }
51
+ const getXPosition = (0, _getValueToPositionMapper.getValueToPositionMapper)(xAxis.scale);
52
+ const getYPosition = (0, _getValueToPositionMapper.getValueToPositionMapper)(yAxis.scale);
53
+ const data = series.data;
54
+ const n = data.length;
55
+ const packed = new Float64Array(n * 3);
56
+ let j = 0;
57
+ for (let i = 0; i < n; i += 1) {
58
+ const x = getXPosition(data[i].x);
59
+ if (!(x >= xMin && x <= xMax)) {
60
+ continue;
61
+ }
62
+ const y = getYPosition(data[i].y);
63
+ if (!(y >= yMin && y <= yMax)) {
64
+ continue;
65
+ }
66
+ packed[j] = x;
67
+ packed[j + 1] = y;
68
+ packed[j + 2] = i;
69
+ j += 3;
70
+ }
71
+ const coords = packed.slice(0, j);
72
+ result.set(seriesId, {
73
+ coords,
74
+ count: j / 3
75
+ });
76
+ }
77
+ return result;
78
+ });
79
+
80
+ /**
81
+ * Render data for a single scatter series, or `undefined` while it is not
82
+ * available yet (processors/axes still pending).
83
+ */
84
+ const selectorScatterSeriesRenderData = exports.selectorScatterSeriesRenderData = (0, _store.createSelector)(selectorScatterRenderData, (renderData, seriesId) => renderData.get(seriesId));
85
+
86
+ /**
87
+ * Zero-copy view of one batch's coordinates. `start`/`end` are visible-point
88
+ * indices (not original `dataIndex` values). The returned `Float64Array` shares
89
+ * the buffer with `renderData.coords`.
90
+ */
91
+ function getScatterBatchView(renderData, start, end) {
92
+ return renderData.coords.subarray(start * 3, end * 3);
93
+ }
@@ -0,0 +1,87 @@
1
+ import { createSelector, createSelectorMemoized } from '@mui/x-internals/store';
2
+ import { getValueToPositionMapper } from "../../hooks/getValueToPositionMapper.mjs";
3
+ import { selectorChartSeriesProcessed } from "../../internals/plugins/corePlugins/useChartSeries/index.mjs";
4
+ import { selectorChartDrawingArea } from "../../internals/plugins/corePlugins/useChartDimensions/index.mjs";
5
+ import { selectorChartXAxis, selectorChartYAxis } from "../../internals/plugins/featurePlugins/useChartCartesianAxis/index.mjs";
6
+
7
+ /**
8
+ * Pre-computed render data for a single scatter series.
9
+ *
10
+ * Coordinates are stored in a packed `Float64Array` (stride 3: `[x0, y0, i0,
11
+ * x1, y1, i1, ...]`, where `iN` is the original `dataIndex`). Only points that
12
+ * project inside the drawing area are kept, so the progressive renderer can
13
+ * size its batches by the number of *visible* points — when zoomed in tightly
14
+ * the wave finishes in a single tick. Batches are contiguous slices of this
15
+ * array, so a batch's data is obtained with a zero-copy `subarray` view (see
16
+ * {@link getScatterBatchView}).
17
+ */
18
+
19
+ const EMPTY_RENDER_DATA = new Map();
20
+
21
+ /**
22
+ * Packed projected coordinates for every scatter series, filtered to the
23
+ * drawing area. Recomputes when the processed series, axis scales, or drawing
24
+ * area change.
25
+ */
26
+ export const selectorScatterRenderData = createSelectorMemoized(selectorChartSeriesProcessed, selectorChartXAxis, selectorChartYAxis, selectorChartDrawingArea, function selectorScatterRenderData(processedSeries, xAxes, yAxes, drawingArea) {
27
+ const scatter = processedSeries.scatter;
28
+ if (scatter === undefined) {
29
+ return EMPTY_RENDER_DATA;
30
+ }
31
+ const defaultXAxisId = xAxes.axisIds[0];
32
+ const defaultYAxisId = yAxes.axisIds[0];
33
+ const result = new Map();
34
+ const xMin = drawingArea.left - 1;
35
+ const xMax = drawingArea.left + drawingArea.width;
36
+ const yMin = drawingArea.top - 1;
37
+ const yMax = drawingArea.top + drawingArea.height;
38
+ for (const seriesId of scatter.seriesOrder) {
39
+ const series = scatter.series[seriesId];
40
+ const xAxis = xAxes.axis[series.xAxisId ?? defaultXAxisId];
41
+ const yAxis = yAxes.axis[series.yAxisId ?? defaultYAxisId];
42
+ if (xAxis === undefined || yAxis === undefined) {
43
+ continue;
44
+ }
45
+ const getXPosition = getValueToPositionMapper(xAxis.scale);
46
+ const getYPosition = getValueToPositionMapper(yAxis.scale);
47
+ const data = series.data;
48
+ const n = data.length;
49
+ const packed = new Float64Array(n * 3);
50
+ let j = 0;
51
+ for (let i = 0; i < n; i += 1) {
52
+ const x = getXPosition(data[i].x);
53
+ if (!(x >= xMin && x <= xMax)) {
54
+ continue;
55
+ }
56
+ const y = getYPosition(data[i].y);
57
+ if (!(y >= yMin && y <= yMax)) {
58
+ continue;
59
+ }
60
+ packed[j] = x;
61
+ packed[j + 1] = y;
62
+ packed[j + 2] = i;
63
+ j += 3;
64
+ }
65
+ const coords = packed.slice(0, j);
66
+ result.set(seriesId, {
67
+ coords,
68
+ count: j / 3
69
+ });
70
+ }
71
+ return result;
72
+ });
73
+
74
+ /**
75
+ * Render data for a single scatter series, or `undefined` while it is not
76
+ * available yet (processors/axes still pending).
77
+ */
78
+ export const selectorScatterSeriesRenderData = createSelector(selectorScatterRenderData, (renderData, seriesId) => renderData.get(seriesId));
79
+
80
+ /**
81
+ * Zero-copy view of one batch's coordinates. `start`/`end` are visible-point
82
+ * indices (not original `dataIndex` values). The returned `Float64Array` shares
83
+ * the buffer with `renderData.coords`.
84
+ */
85
+ export function getScatterBatchView(renderData, start, end) {
86
+ return renderData.coords.subarray(start * 3, end * 3);
87
+ }
@@ -22,11 +22,8 @@ const getColor = (series, xAxis, yAxis, zAxis) => {
22
22
  }
23
23
  }
24
24
  const value = series.data[dataIndex];
25
- const color = value === null ? getSeriesColor({
26
- value,
27
- dataIndex
28
- }) : zColorScale(value.colorValue ?? value.z);
29
- if (color === null) {
25
+ const color = zColorScale(value.colorValue ?? value.z);
26
+ if (typeof color !== 'string') {
30
27
  return getSeriesColor({
31
28
  value,
32
29
  dataIndex
@@ -41,11 +38,8 @@ const getColor = (series, xAxis, yAxis, zAxis) => {
41
38
  return series.color;
42
39
  }
43
40
  const value = series.data[dataIndex];
44
- const color = value === null ? getSeriesColor({
45
- value,
46
- dataIndex
47
- }) : yColorScale(value.y);
48
- if (color === null) {
41
+ const color = yColorScale(value.y);
42
+ if (typeof color !== 'string') {
49
43
  return getSeriesColor({
50
44
  value,
51
45
  dataIndex
@@ -60,11 +54,8 @@ const getColor = (series, xAxis, yAxis, zAxis) => {
60
54
  return series.color;
61
55
  }
62
56
  const value = series.data[dataIndex];
63
- const color = value === null ? getSeriesColor({
64
- value,
65
- dataIndex
66
- }) : xColorScale(value.x);
67
- if (color === null) {
57
+ const color = xColorScale(value.x);
58
+ if (typeof color !== 'string') {
68
59
  return getSeriesColor({
69
60
  value,
70
61
  dataIndex
@@ -16,11 +16,8 @@ const getColor = (series, xAxis, yAxis, zAxis) => {
16
16
  }
17
17
  }
18
18
  const value = series.data[dataIndex];
19
- const color = value === null ? getSeriesColor({
20
- value,
21
- dataIndex
22
- }) : zColorScale(value.colorValue ?? value.z);
23
- if (color === null) {
19
+ const color = zColorScale(value.colorValue ?? value.z);
20
+ if (typeof color !== 'string') {
24
21
  return getSeriesColor({
25
22
  value,
26
23
  dataIndex
@@ -35,11 +32,8 @@ const getColor = (series, xAxis, yAxis, zAxis) => {
35
32
  return series.color;
36
33
  }
37
34
  const value = series.data[dataIndex];
38
- const color = value === null ? getSeriesColor({
39
- value,
40
- dataIndex
41
- }) : yColorScale(value.y);
42
- if (color === null) {
35
+ const color = yColorScale(value.y);
36
+ if (typeof color !== 'string') {
43
37
  return getSeriesColor({
44
38
  value,
45
39
  dataIndex
@@ -54,11 +48,8 @@ const getColor = (series, xAxis, yAxis, zAxis) => {
54
48
  return series.color;
55
49
  }
56
50
  const value = series.data[dataIndex];
57
- const color = value === null ? getSeriesColor({
58
- value,
59
- dataIndex
60
- }) : xColorScale(value.x);
61
- if (color === null) {
51
+ const color = xColorScale(value.x);
52
+ if (typeof color !== 'string') {
62
53
  return getSeriesColor({
63
54
  value,
64
55
  dataIndex
@@ -158,7 +158,7 @@ const SparkLineChart = exports.SparkLineChart = /*#__PURE__*/React.forwardRef(fu
158
158
  });
159
159
  });
160
160
  if (process.env.NODE_ENV !== "production") SparkLineChart.displayName = "SparkLineChart";
161
- process.env.NODE_ENV !== "production" ? SparkLineChart.propTypes = {
161
+ process.env.NODE_ENV !== "production" ? SparkLineChart.propTypes /* remove-proptypes */ = {
162
162
  // ----------------------------- Warning --------------------------------
163
163
  // | These PropTypes are generated from the TypeScript type definitions |
164
164
  // | To update them edit the TypeScript types and run "pnpm proptypes" |
@@ -255,7 +255,8 @@ process.env.NODE_ENV !== "production" ? SparkLineChart.propTypes = {
255
255
  * Options to enable features planned for the next major.
256
256
  */
257
257
  experimentalFeatures: _propTypes.default.shape({
258
- enablePositionBasedPointerInteraction: _propTypes.default.bool
258
+ enablePositionBasedPointerInteraction: _propTypes.default.bool,
259
+ progressiveRendering: _propTypes.default.bool
259
260
  }),
260
261
  /**
261
262
  * The height of the chart in px. If not defined, it takes the height of the parent element.
@@ -151,7 +151,7 @@ const SparkLineChart = /*#__PURE__*/React.forwardRef(function SparkLineChart(pro
151
151
  });
152
152
  });
153
153
  if (process.env.NODE_ENV !== "production") SparkLineChart.displayName = "SparkLineChart";
154
- process.env.NODE_ENV !== "production" ? SparkLineChart.propTypes = {
154
+ process.env.NODE_ENV !== "production" ? SparkLineChart.propTypes /* remove-proptypes */ = {
155
155
  // ----------------------------- Warning --------------------------------
156
156
  // | These PropTypes are generated from the TypeScript type definitions |
157
157
  // | To update them edit the TypeScript types and run "pnpm proptypes" |
@@ -248,7 +248,8 @@ process.env.NODE_ENV !== "production" ? SparkLineChart.propTypes = {
248
248
  * Options to enable features planned for the next major.
249
249
  */
250
250
  experimentalFeatures: PropTypes.shape({
251
- enablePositionBasedPointerInteraction: PropTypes.bool
251
+ enablePositionBasedPointerInteraction: PropTypes.bool,
252
+ progressiveRendering: PropTypes.bool
252
253
  }),
253
254
  /**
254
255
  * The height of the chart in px. If not defined, it takes the height of the parent element.
@@ -53,7 +53,7 @@ const Toolbar = exports.Toolbar = /*#__PURE__*/React.forwardRef(function Toolbar
53
53
  });
54
54
  });
55
55
  if (process.env.NODE_ENV !== "production") Toolbar.displayName = "Toolbar";
56
- process.env.NODE_ENV !== "production" ? Toolbar.propTypes = {
56
+ process.env.NODE_ENV !== "production" ? Toolbar.propTypes /* remove-proptypes */ = {
57
57
  // ----------------------------- Warning --------------------------------
58
58
  // | These PropTypes are generated from the TypeScript type definitions |
59
59
  // | To update them edit the TypeScript types and run "pnpm proptypes" |
@@ -45,7 +45,7 @@ export const Toolbar = /*#__PURE__*/React.forwardRef(function Toolbar(_ref, ref)
45
45
  });
46
46
  });
47
47
  if (process.env.NODE_ENV !== "production") Toolbar.displayName = "Toolbar";
48
- process.env.NODE_ENV !== "production" ? Toolbar.propTypes = {
48
+ process.env.NODE_ENV !== "production" ? Toolbar.propTypes /* remove-proptypes */ = {
49
49
  // ----------------------------- Warning --------------------------------
50
50
  // | These PropTypes are generated from the TypeScript type definitions |
51
51
  // | To update them edit the TypeScript types and run "pnpm proptypes" |
@@ -44,7 +44,7 @@ const ToolbarButton = exports.ToolbarButton = /*#__PURE__*/React.forwardRef(func
44
44
  });
45
45
  });
46
46
  if (process.env.NODE_ENV !== "production") ToolbarButton.displayName = "ToolbarButton";
47
- process.env.NODE_ENV !== "production" ? ToolbarButton.propTypes = {
47
+ process.env.NODE_ENV !== "production" ? ToolbarButton.propTypes /* remove-proptypes */ = {
48
48
  // ----------------------------- Warning --------------------------------
49
49
  // | These PropTypes are generated from the TypeScript type definitions |
50
50
  // | To update them edit the TypeScript types and run "pnpm proptypes" |
@@ -37,7 +37,7 @@ const ToolbarButton = /*#__PURE__*/React.forwardRef(function ToolbarButton(props
37
37
  });
38
38
  });
39
39
  if (process.env.NODE_ENV !== "production") ToolbarButton.displayName = "ToolbarButton";
40
- process.env.NODE_ENV !== "production" ? ToolbarButton.propTypes = {
40
+ process.env.NODE_ENV !== "production" ? ToolbarButton.propTypes /* remove-proptypes */ = {
41
41
  // ----------------------------- Warning --------------------------------
42
42
  // | These PropTypes are generated from the TypeScript type definitions |
43
43
  // | To update them edit the TypeScript types and run "pnpm proptypes" |
package/index.d.mts CHANGED
@@ -32,7 +32,7 @@ export * from "./ChartsRadialDataProvider/index.mjs";
32
32
  export * from "./ChartsRadialGrid/index.mjs";
33
33
  export * from "./ChartsRadialAxisHighlight/index.mjs";
34
34
  export * from "./ChartsRadiusAxis/index.mjs";
35
- export { type ChartsRotationAxisProps, Unstable_ChartsRotationAxis } from "./ChartsRotationAxis/index.mjs";
35
+ export { type ChartsRotationAxisProps, type ChartsRotationAxisSlots, type ChartsRotationAxisSlotProps, Unstable_ChartsRotationAxis } from "./ChartsRotationAxis/index.mjs";
36
36
  export * from "./Toolbar/index.mjs";
37
37
  export * from "./ChartsWrapper/index.mjs";
38
38
  export * from "./ChartsBrushOverlay/index.mjs";
package/index.d.ts CHANGED
@@ -32,7 +32,7 @@ export * from "./ChartsRadialDataProvider/index.js";
32
32
  export * from "./ChartsRadialGrid/index.js";
33
33
  export * from "./ChartsRadialAxisHighlight/index.js";
34
34
  export * from "./ChartsRadiusAxis/index.js";
35
- export { type ChartsRotationAxisProps, Unstable_ChartsRotationAxis } from "./ChartsRotationAxis/index.js";
35
+ export { type ChartsRotationAxisProps, type ChartsRotationAxisSlots, type ChartsRotationAxisSlotProps, Unstable_ChartsRotationAxis } from "./ChartsRotationAxis/index.js";
36
36
  export * from "./Toolbar/index.js";
37
37
  export * from "./ChartsWrapper/index.js";
38
38
  export * from "./ChartsBrushOverlay/index.js";
package/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-charts v9.4.0
2
+ * @mui/x-charts v9.6.0
3
3
  *
4
4
  * @license MIT
5
5
  * This source code is licensed under the MIT license found in the
package/index.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-charts v9.4.0
2
+ * @mui/x-charts v9.6.0
3
3
  *
4
4
  * @license MIT
5
5
  * This source code is licensed under the MIT license found in the
@@ -1,5 +1,5 @@
1
1
  import { type ScaleOrdinal } from '@mui/x-charts-vendor/d3-scale';
2
2
  import { type ContinuousColorConfig, type PiecewiseColorConfig, type OrdinalColorConfig } from "../models/colorMapping.mjs";
3
- export declare function getSequentialColorScale<Value extends number | Date>(config: ContinuousColorConfig<Value> | PiecewiseColorConfig<Value>): import("@mui/x-charts-vendor/d3-scale").ScaleThreshold<Value, string, never> | import("@mui/x-charts-vendor/d3-scale").ScaleSequential<string, never>;
3
+ export declare function getSequentialColorScale<Value extends number | Date>(config: ContinuousColorConfig<Value> | PiecewiseColorConfig<Value>): import("@mui/x-charts-vendor/d3-scale").ScaleSequential<string, string | null> | import("@mui/x-charts-vendor/d3-scale").ScaleThreshold<Value, string, string | null>;
4
4
  export declare function getOrdinalColorScale<Value extends number | Date | string>(config: OrdinalColorConfig<Value>): ScaleOrdinal<Value, string, null | string> | ScaleOrdinal<number, string, null | string>;
5
- export declare function getColorScale(config: ContinuousColorConfig | PiecewiseColorConfig | OrdinalColorConfig): ScaleOrdinal<string | number | Date, string, string | null> | ScaleOrdinal<number, string, string | null> | import("@mui/x-charts-vendor/d3-scale").ScaleSequential<string, never> | import("@mui/x-charts-vendor/d3-scale").ScaleThreshold<number | Date, string, never>;
5
+ export declare function getColorScale(config: ContinuousColorConfig | PiecewiseColorConfig | OrdinalColorConfig): ScaleOrdinal<string | number | Date, string, string | null> | ScaleOrdinal<number, string, string | null> | import("@mui/x-charts-vendor/d3-scale").ScaleThreshold<number | Date, string, string | null>;
@@ -1,5 +1,5 @@
1
1
  import { type ScaleOrdinal } from '@mui/x-charts-vendor/d3-scale';
2
2
  import { type ContinuousColorConfig, type PiecewiseColorConfig, type OrdinalColorConfig } from "../models/colorMapping.js";
3
- export declare function getSequentialColorScale<Value extends number | Date>(config: ContinuousColorConfig<Value> | PiecewiseColorConfig<Value>): import("@mui/x-charts-vendor/d3-scale").ScaleThreshold<Value, string, never> | import("@mui/x-charts-vendor/d3-scale").ScaleSequential<string, never>;
3
+ export declare function getSequentialColorScale<Value extends number | Date>(config: ContinuousColorConfig<Value> | PiecewiseColorConfig<Value>): import("@mui/x-charts-vendor/d3-scale").ScaleSequential<string, string | null> | import("@mui/x-charts-vendor/d3-scale").ScaleThreshold<Value, string, string | null>;
4
4
  export declare function getOrdinalColorScale<Value extends number | Date | string>(config: OrdinalColorConfig<Value>): ScaleOrdinal<Value, string, null | string> | ScaleOrdinal<number, string, null | string>;
5
- export declare function getColorScale(config: ContinuousColorConfig | PiecewiseColorConfig | OrdinalColorConfig): ScaleOrdinal<string | number | Date, string, string | null> | ScaleOrdinal<number, string, string | null> | import("@mui/x-charts-vendor/d3-scale").ScaleSequential<string, never> | import("@mui/x-charts-vendor/d3-scale").ScaleThreshold<number | Date, string, never>;
5
+ export declare function getColorScale(config: ContinuousColorConfig | PiecewiseColorConfig | OrdinalColorConfig): ScaleOrdinal<string | number | Date, string, string | null> | ScaleOrdinal<number, string, string | null> | import("@mui/x-charts-vendor/d3-scale").ScaleThreshold<number | Date, string, string | null>;
@@ -9,9 +9,9 @@ exports.getSequentialColorScale = getSequentialColorScale;
9
9
  var _d3Scale = require("@mui/x-charts-vendor/d3-scale");
10
10
  function getSequentialColorScale(config) {
11
11
  if (config.type === 'piecewise') {
12
- return (0, _d3Scale.scaleThreshold)(config.thresholds, config.colors);
12
+ return (0, _d3Scale.scaleThreshold)(config.thresholds, config.colors).unknown(config.unknownColor ?? null);
13
13
  }
14
- return (0, _d3Scale.scaleSequential)([config.min ?? 0, config.max ?? 100], config.color);
14
+ return (0, _d3Scale.scaleSequential)([config.min ?? 0, config.max ?? 100], config.color).unknown(config.unknownColor ?? null);
15
15
  }
16
16
  function getOrdinalColorScale(config) {
17
17
  if (config.values) {
@@ -1,9 +1,9 @@
1
1
  import { scaleOrdinal, scaleThreshold, scaleSequential } from '@mui/x-charts-vendor/d3-scale';
2
2
  export function getSequentialColorScale(config) {
3
3
  if (config.type === 'piecewise') {
4
- return scaleThreshold(config.thresholds, config.colors);
4
+ return scaleThreshold(config.thresholds, config.colors).unknown(config.unknownColor ?? null);
5
5
  }
6
- return scaleSequential([config.min ?? 0, config.max ?? 100], config.color);
6
+ return scaleSequential([config.min ?? 0, config.max ?? 100], config.color).unknown(config.unknownColor ?? null);
7
7
  }
8
8
  export function getOrdinalColorScale(config) {
9
9
  if (config.values) {
@@ -1,6 +1,6 @@
1
- import { type CommonSeriesType, type ColorCallbackValue } from "../models/seriesType/common.mjs";
2
- import { type ChartSeriesType } from "../models/seriesType/config.mjs";
3
- export declare function getSeriesColorFn<TValue>(series: {
4
- color: NonNullable<CommonSeriesType<TValue, ChartSeriesType>['color']>;
5
- colorGetter?: CommonSeriesType<TValue, ChartSeriesType>['colorGetter'];
1
+ import { type ColorCallbackValue, type SeriesColor } from "../models/seriesType/common.mjs";
2
+ import { type ChartSeriesType, type ChartsSeriesConfig } from "../models/seriesType/config.mjs";
3
+ export declare function getSeriesColorFn<TValue extends ChartsSeriesConfig[ChartSeriesType]['valueType']>(series: {
4
+ color: NonNullable<SeriesColor<TValue>['color']>;
5
+ colorGetter?: SeriesColor<TValue>['colorGetter'];
6
6
  }): (data: ColorCallbackValue<TValue>) => string;
@@ -1,6 +1,6 @@
1
- import { type CommonSeriesType, type ColorCallbackValue } from "../models/seriesType/common.js";
2
- import { type ChartSeriesType } from "../models/seriesType/config.js";
3
- export declare function getSeriesColorFn<TValue>(series: {
4
- color: NonNullable<CommonSeriesType<TValue, ChartSeriesType>['color']>;
5
- colorGetter?: CommonSeriesType<TValue, ChartSeriesType>['colorGetter'];
1
+ import { type ColorCallbackValue, type SeriesColor } from "../models/seriesType/common.js";
2
+ import { type ChartSeriesType, type ChartsSeriesConfig } from "../models/seriesType/config.js";
3
+ export declare function getSeriesColorFn<TValue extends ChartsSeriesConfig[ChartSeriesType]['valueType']>(series: {
4
+ color: NonNullable<SeriesColor<TValue>['color']>;
5
+ colorGetter?: SeriesColor<TValue>['colorGetter'];
6
6
  }): (data: ColorCallbackValue<TValue>) => string;
@@ -37,7 +37,10 @@ export * from "./plugins/featurePlugins/useChartVisibilityManager/index.mjs";
37
37
  export * from "./plugins/featurePlugins/useChartKeyboardNavigation/index.mjs";
38
38
  export * from "./plugins/featurePlugins/useChartClosestPoint/index.mjs";
39
39
  export * from "./plugins/featurePlugins/useChartBrush/index.mjs";
40
+ export * as useGeoProjectionSelectors from "./plugins/featurePlugins/useGeoProjection/useGeoProjection.selectors.mjs";
41
+ export * as useGeoProjectionTypes from "./plugins/featurePlugins/useGeoProjection/useGeoProjection.types.mjs";
40
42
  export * from "./plugins/featurePlugins/useChartItemClick/index.mjs";
43
+ export * from "./plugins/featurePlugins/useProgressiveRendering/index.mjs";
41
44
  export * from "./plugins/utils/selectors.mjs";
42
45
  export { getAxisTriggerTooltip as getCartesianAxisTriggerTooltip } from "./plugins/featurePlugins/useChartCartesianAxis/getAxisTriggerTooltip.mjs";
43
46
  export { getAxisIndex as getCartesianAxisIndex } from "./plugins/featurePlugins/useChartCartesianAxis/getAxisValue.mjs";
@@ -37,7 +37,10 @@ export * from "./plugins/featurePlugins/useChartVisibilityManager/index.js";
37
37
  export * from "./plugins/featurePlugins/useChartKeyboardNavigation/index.js";
38
38
  export * from "./plugins/featurePlugins/useChartClosestPoint/index.js";
39
39
  export * from "./plugins/featurePlugins/useChartBrush/index.js";
40
+ export * as useGeoProjectionSelectors from "./plugins/featurePlugins/useGeoProjection/useGeoProjection.selectors.js";
41
+ export * as useGeoProjectionTypes from "./plugins/featurePlugins/useGeoProjection/useGeoProjection.types.js";
40
42
  export * from "./plugins/featurePlugins/useChartItemClick/index.js";
43
+ export * from "./plugins/featurePlugins/useProgressiveRendering/index.js";
41
44
  export * from "./plugins/utils/selectors.js";
42
45
  export { getAxisTriggerTooltip as getCartesianAxisTriggerTooltip } from "./plugins/featurePlugins/useChartCartesianAxis/getAxisTriggerTooltip.js";
43
46
  export { getAxisIndex as getCartesianAxisIndex } from "./plugins/featurePlugins/useChartCartesianAxis/getAxisValue.js";
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
 
3
3
  var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
+ var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
4
5
  Object.defineProperty(exports, "__esModule", {
5
6
  value: true
6
7
  });
@@ -19,6 +20,8 @@ var _exportNames = {
19
20
  useRadarChartProps: true,
20
21
  useSkipAnimation: true,
21
22
  useRegisterPointerInteractions: true,
23
+ useGeoProjectionSelectors: true,
24
+ useGeoProjectionTypes: true,
22
25
  getCartesianAxisTriggerTooltip: true,
23
26
  getCartesianAxisIndex: true,
24
27
  getRotationAxisIndex: true,
@@ -162,6 +165,7 @@ Object.defineProperty(exports, "useDrawingArea", {
162
165
  return _useDrawingArea.useDrawingArea;
163
166
  }
164
167
  });
168
+ exports.useGeoProjectionTypes = exports.useGeoProjectionSelectors = void 0;
165
169
  Object.defineProperty(exports, "useInteractionItemProps", {
166
170
  enumerable: true,
167
171
  get: function () {
@@ -529,6 +533,10 @@ Object.keys(_useChartBrush).forEach(function (key) {
529
533
  }
530
534
  });
531
535
  });
536
+ var _useGeoProjectionSelectors = _interopRequireWildcard(require("./plugins/featurePlugins/useGeoProjection/useGeoProjection.selectors"));
537
+ exports.useGeoProjectionSelectors = _useGeoProjectionSelectors;
538
+ var _useGeoProjectionTypes = _interopRequireWildcard(require("./plugins/featurePlugins/useGeoProjection/useGeoProjection.types"));
539
+ exports.useGeoProjectionTypes = _useGeoProjectionTypes;
532
540
  var _useChartItemClick = require("./plugins/featurePlugins/useChartItemClick");
533
541
  Object.keys(_useChartItemClick).forEach(function (key) {
534
542
  if (key === "default" || key === "__esModule") return;
@@ -541,6 +549,18 @@ Object.keys(_useChartItemClick).forEach(function (key) {
541
549
  }
542
550
  });
543
551
  });
552
+ var _useProgressiveRendering = require("./plugins/featurePlugins/useProgressiveRendering");
553
+ Object.keys(_useProgressiveRendering).forEach(function (key) {
554
+ if (key === "default" || key === "__esModule") return;
555
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
556
+ if (key in exports && exports[key] === _useProgressiveRendering[key]) return;
557
+ Object.defineProperty(exports, key, {
558
+ enumerable: true,
559
+ get: function () {
560
+ return _useProgressiveRendering[key];
561
+ }
562
+ });
563
+ });
544
564
  var _selectors = require("./plugins/utils/selectors");
545
565
  Object.keys(_selectors).forEach(function (key) {
546
566
  if (key === "default" || key === "__esModule") return;
@@ -41,7 +41,10 @@ export * from "./plugins/featurePlugins/useChartVisibilityManager/index.mjs";
41
41
  export * from "./plugins/featurePlugins/useChartKeyboardNavigation/index.mjs";
42
42
  export * from "./plugins/featurePlugins/useChartClosestPoint/index.mjs";
43
43
  export * from "./plugins/featurePlugins/useChartBrush/index.mjs";
44
+ export * as useGeoProjectionSelectors from "./plugins/featurePlugins/useGeoProjection/useGeoProjection.selectors.mjs";
45
+ export * as useGeoProjectionTypes from "./plugins/featurePlugins/useGeoProjection/useGeoProjection.types.mjs";
44
46
  export * from "./plugins/featurePlugins/useChartItemClick/index.mjs";
47
+ export * from "./plugins/featurePlugins/useProgressiveRendering/index.mjs";
45
48
  export * from "./plugins/utils/selectors.mjs";
46
49
  export { getAxisTriggerTooltip as getCartesianAxisTriggerTooltip } from "./plugins/featurePlugins/useChartCartesianAxis/getAxisTriggerTooltip.mjs";
47
50
  export { getAxisIndex as getCartesianAxisIndex } from "./plugins/featurePlugins/useChartCartesianAxis/getAxisValue.mjs";