@mui/x-charts 9.13.0 → 9.15.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.
- package/BarChart/AnimatedBarElement.mjs +2 -2
- package/BarChart/BarChart.mjs +1 -1
- package/BarChart/BarElement.mjs +2 -2
- package/BarChart/BarLabel/BarLabel.mjs +2 -2
- package/BarChart/BarLabel/BarLabelItem.mjs +2 -2
- package/BarChart/BarLabel/BarLabelPlot.mjs +2 -2
- package/BarChart/BarPlot.mjs +2 -2
- package/BarChart/BatchBarPlot/BarGroup.mjs +2 -2
- package/BarChart/FocusedBar.mjs +1 -1
- package/BarChart/IndividualBarPlot.mjs +2 -2
- package/BarChart/checkBarChartScaleErrors.js +1 -1
- package/BarChart/checkBarChartScaleErrors.mjs +2 -2
- package/BarChart/seriesConfig/bar/getSeriesWithDefaultValues.mjs +1 -1
- package/BarChart/seriesConfig/bar/seriesProcessor.mjs +1 -1
- package/BarChart/seriesConfig/bar/tooltipPosition.js +1 -1
- package/BarChart/seriesConfig/bar/tooltipPosition.mjs +1 -1
- package/BarChart/useBarChartProps.mjs +2 -2
- package/BarChart/useBarPlotData.mjs +1 -1
- package/CHANGELOG.md +325 -0
- package/ChartsAxisHighlight/ChartsAxisHighlightPath.mjs +1 -1
- package/ChartsAxisHighlightValue/ChartsAxisHighlightValue.mjs +1 -1
- package/ChartsAxisHighlightValue/ChartsAxisHighlightValueItem.mjs +1 -1
- package/ChartsBrushOverlay/ChartsBrushOverlay.mjs +1 -1
- package/ChartsClipPath/ChartsClipPath.mjs +1 -1
- package/ChartsContainer/ChartsContainer.mjs +1 -1
- package/ChartsContainer/useChartsContainerProps.mjs +2 -2
- package/ChartsDataProvider/ChartsDataProvider.mjs +1 -1
- package/ChartsDataProvider/useChartsDataProviderProps.mjs +2 -2
- package/ChartsGrid/ChartsGrid.mjs +2 -2
- package/ChartsLabel/ChartsLabel.mjs +2 -2
- package/ChartsLabel/ChartsLabelGradient.mjs +2 -2
- package/ChartsLabel/ChartsLabelMark.mjs +2 -2
- package/ChartsLayerContainer/ChartsLayerContainer.js +1 -1
- package/ChartsLayerContainer/ChartsLayerContainer.mjs +4 -4
- package/ChartsLegend/ChartsLegend.mjs +2 -2
- package/ChartsLegend/ContinuousColorLegend.mjs +2 -2
- package/ChartsLegend/PiecewiseColorLegend.mjs +2 -2
- package/ChartsLocalizationProvider/ChartsLocalizationProvider.mjs +2 -2
- package/ChartsOverlay/ChartsLoadingOverlay.mjs +1 -1
- package/ChartsOverlay/ChartsNoDataOverlay.mjs +1 -1
- package/ChartsOverlay/ChartsOverlay.mjs +1 -1
- package/ChartsOverlay/common.mjs +1 -1
- package/ChartsRadialAxisHighlight/ChartsRadialAxisHighlightPath.mjs +1 -1
- package/ChartsRadialDataProvider/ChartsRadialDataProvider.mjs +1 -1
- package/ChartsRadialDataProvider/useChartsRadialDataProviderProps.mjs +2 -2
- package/ChartsRadialGrid/ChartsRadialGrid.mjs +2 -2
- package/ChartsRadiusAxis/ChartsRadiusAxis.mjs +1 -1
- package/ChartsReferenceLine/ChartsReferenceLine.mjs +1 -1
- package/ChartsReferenceLine/ChartsXReferenceLine.js +1 -1
- package/ChartsReferenceLine/ChartsXReferenceLine.mjs +3 -3
- package/ChartsReferenceLine/ChartsYReferenceLine.js +1 -1
- package/ChartsReferenceLine/ChartsYReferenceLine.mjs +3 -3
- package/ChartsReferenceLine/common.mjs +1 -1
- package/ChartsRotationAxis/ChartsRotationAxis.mjs +1 -1
- package/ChartsSurface/ChartsSurface.mjs +2 -2
- package/ChartsSvgLayer/ChartsSvgLayer.mjs +2 -2
- package/ChartsText/ChartsText.mjs +2 -2
- package/ChartsTooltip/ChartsTooltip.mjs +2 -2
- package/ChartsTooltip/ChartsTooltipContainer.js +2 -2
- package/ChartsTooltip/ChartsTooltipContainer.mjs +5 -5
- package/ChartsWrapper/ChartsWrapper.mjs +2 -2
- package/ChartsXAxis/ChartsGroupedXAxisTicks.mjs +1 -1
- package/ChartsXAxis/ChartsSingleXAxisTicks.mjs +1 -1
- package/ChartsXAxis/ChartsXAxis.mjs +1 -1
- package/ChartsXAxis/ChartsXAxisImpl.js +2 -1
- package/ChartsXAxis/ChartsXAxisImpl.mjs +4 -3
- package/ChartsXAxis/useAxisTicksProps.d.mts +17 -17
- package/ChartsXAxis/useAxisTicksProps.d.ts +17 -17
- package/ChartsXAxis/useAxisTicksProps.js +2 -1
- package/ChartsXAxis/useAxisTicksProps.mjs +4 -3
- package/ChartsYAxis/ChartsGroupedYAxisTicks.mjs +1 -1
- package/ChartsYAxis/ChartsSingleYAxisTicks.mjs +1 -1
- package/ChartsYAxis/ChartsYAxis.mjs +1 -1
- package/ChartsYAxis/ChartsYAxisImpl.js +2 -1
- package/ChartsYAxis/ChartsYAxisImpl.mjs +4 -3
- package/ChartsYAxis/useAxisTicksProps.d.mts +17 -17
- package/ChartsYAxis/useAxisTicksProps.d.ts +17 -17
- package/ChartsYAxis/useAxisTicksProps.js +2 -1
- package/ChartsYAxis/useAxisTicksProps.mjs +4 -3
- package/Gauge/Gauge.mjs +2 -2
- package/Gauge/GaugeContainer.mjs +2 -2
- package/Gauge/GaugeReferenceArc.mjs +2 -2
- package/Gauge/GaugeValueArc.mjs +2 -2
- package/Gauge/GaugeValueText.mjs +2 -2
- package/LineChart/AnimatedArea.mjs +2 -2
- package/LineChart/AnimatedLine.mjs +2 -2
- package/LineChart/AreaElement.mjs +2 -2
- package/LineChart/AreaPlot.mjs +2 -2
- package/LineChart/CircleMarkElement.mjs +2 -2
- package/LineChart/LineChart.mjs +1 -1
- package/LineChart/LineElement.mjs +2 -2
- package/LineChart/LineHighlightElement.d.mts +3 -3
- package/LineChart/LineHighlightElement.d.ts +3 -3
- package/LineChart/LineHighlightElement.js +2 -2
- package/LineChart/LineHighlightElement.mjs +4 -4
- package/LineChart/LineHighlightPlot.mjs +2 -2
- package/LineChart/LinePlot.mjs +2 -2
- package/LineChart/MarkElement.mjs +2 -2
- package/LineChart/MarkPlot.mjs +2 -2
- package/LineChart/seriesConfig/getSeriesWithDefaultValues.mjs +1 -1
- package/LineChart/seriesConfig/tooltipPosition.js +1 -1
- package/LineChart/seriesConfig/tooltipPosition.mjs +1 -1
- package/LineChart/useLineChartProps.mjs +2 -2
- package/LineChart/useLinePlotData.js +1 -1
- package/LineChart/useLinePlotData.mjs +2 -2
- package/PieChart/FocusedPieArc.mjs +2 -2
- package/PieChart/PieArc.mjs +2 -2
- package/PieChart/PieArcLabel.mjs +2 -2
- package/PieChart/PieArcLabelPlot.mjs +2 -2
- package/PieChart/PieArcPlot.mjs +2 -2
- package/PieChart/PieChart.mjs +2 -2
- package/PieChart/dataTransform/getModifiedArcProperties.mjs +1 -1
- package/PieChart/dataTransform/useTransformData.mjs +1 -1
- package/PieChart/seriesConfig/getSeriesWithDefaultValues.mjs +1 -1
- package/PieChart/seriesConfig/seriesProcessor.mjs +1 -1
- package/PieChart/seriesConfig/tooltip.mjs +1 -1
- package/PieChart/seriesConfig/tooltipPosition.js +1 -1
- package/PieChart/seriesConfig/tooltipPosition.mjs +1 -1
- package/RadarChart/FocusedRadarMark.mjs +1 -1
- package/RadarChart/RadarAxis/RadarAxis.mjs +1 -1
- package/RadarChart/RadarAxis/RadarAxis.utils.d.mts +1 -1
- package/RadarChart/RadarAxis/RadarAxis.utils.d.ts +1 -1
- package/RadarChart/RadarAxis/useRadarAxis.js +1 -1
- package/RadarChart/RadarAxis/useRadarAxis.mjs +1 -1
- package/RadarChart/RadarAxisHighlight/RadarAxisHighlight.mjs +1 -1
- package/RadarChart/RadarChart.mjs +1 -1
- package/RadarChart/RadarDataProvider/RadarDataProvider.mjs +2 -2
- package/RadarChart/RadarMetricLabels/RadarMetricLabels.js +2 -1
- package/RadarChart/RadarMetricLabels/RadarMetricLabels.mjs +3 -2
- package/RadarChart/RadarSeriesPlot/RadarSeriesArea.mjs +2 -2
- package/RadarChart/RadarSeriesPlot/RadarSeriesMarks.mjs +2 -2
- package/RadarChart/RadarSeriesPlot/RadarSeriesPlot.mjs +1 -1
- package/RadarChart/RadarSeriesPlot/useRadarSeriesData.mjs +1 -1
- package/RadarChart/seriesConfig/getSeriesWithDefaultValues.mjs +1 -1
- package/RadarChart/seriesConfig/seriesProcessor.mjs +1 -1
- package/RadarChart/seriesConfig/tooltipPosition.js +1 -1
- package/RadarChart/seriesConfig/tooltipPosition.mjs +1 -1
- package/RadarChart/useRadarChartProps.mjs +1 -1
- package/ScatterChart/FocusedScatterMark.mjs +2 -2
- package/ScatterChart/HighlightedScatterMark.mjs +2 -2
- package/ScatterChart/Scatter.mjs +2 -2
- package/ScatterChart/ScatterChart.mjs +1 -1
- package/ScatterChart/ScatterMarker.mjs +2 -2
- package/ScatterChart/ScatterPlot.mjs +1 -1
- package/ScatterChart/async/ScatterAsyncBatch.mjs +2 -2
- package/ScatterChart/async/scatterRenderData.selectors.js +1 -1
- package/ScatterChart/async/scatterRenderData.selectors.mjs +1 -1
- package/ScatterChart/seriesConfig/getSeriesWithDefaultValues.mjs +1 -1
- package/ScatterChart/seriesConfig/seriesProcessor.mjs +1 -1
- package/ScatterChart/seriesConfig/tooltipPosition.js +1 -1
- package/ScatterChart/seriesConfig/tooltipPosition.mjs +1 -1
- package/ScatterChart/useScatterChartProps.mjs +2 -2
- package/SparkLineChart/SparkLineChart.js +21 -21
- package/SparkLineChart/SparkLineChart.mjs +23 -23
- package/Toolbar/Toolbar.mjs +2 -2
- package/Toolbar/ToolbarButton.mjs +2 -2
- package/context/ChartsProvider/ChartsProvider.types.d.mts +1 -1
- package/context/ChartsProvider/ChartsProvider.types.d.ts +1 -1
- package/context/ChartsSlotsContext.mjs +1 -1
- package/hooks/animation/useAnimate.mjs +1 -1
- package/hooks/useAxisCoordinates.mjs +1 -1
- package/hooks/useAxisTicks.mjs +1 -1
- package/hooks/useIsItemFocusedGetter.js +1 -1
- package/hooks/useIsItemFocusedGetter.mjs +1 -1
- package/index.js +1 -1
- package/index.mjs +1 -1
- package/internals/Flatbush.js +9 -0
- package/internals/Flatbush.mjs +9 -0
- package/internals/commonNextFocusItem.d.mts +46 -0
- package/internals/commonNextFocusItem.d.ts +46 -0
- package/internals/commonNextFocusItem.js +241 -0
- package/internals/commonNextFocusItem.mjs +235 -0
- package/internals/components/AxisSharedComponents.mjs +1 -1
- package/internals/components/ChartsAccessibilityProxy/ChartsAccessibilityProxy.js +31 -8
- package/internals/components/ChartsAccessibilityProxy/ChartsAccessibilityProxy.mjs +32 -9
- package/internals/components/ChartsAccessibilityProxy/useZoomAnnouncement.d.mts +9 -0
- package/internals/components/ChartsAccessibilityProxy/useZoomAnnouncement.d.ts +9 -0
- package/internals/components/ChartsAccessibilityProxy/useZoomAnnouncement.js +67 -0
- package/internals/components/ChartsAccessibilityProxy/useZoomAnnouncement.mjs +62 -0
- package/internals/components/ChartsAxesGradients/ChartsContinuousGradientObjectBound.mjs +1 -1
- package/internals/consumeSlots.mjs +2 -2
- package/internals/consumeThemeProps.js +1 -2
- package/internals/consumeThemeProps.mjs +1 -1
- package/internals/createCommonKeyboardFocusHandler.js +16 -0
- package/internals/createCommonKeyboardFocusHandler.mjs +17 -1
- package/internals/defaultizeMargin.mjs +1 -1
- package/internals/geometry.js +1 -1
- package/internals/geometry.mjs +1 -1
- package/internals/getGroupingConfig.mjs +1 -1
- package/internals/getInlineTypographyStyle.d.mts +9 -0
- package/internals/getInlineTypographyStyle.d.ts +9 -0
- package/internals/getInlineTypographyStyle.js +22 -0
- package/internals/getInlineTypographyStyle.mjs +16 -0
- package/internals/getLineLikeTooltip.mjs +1 -1
- package/internals/getWordsByLines.mjs +1 -1
- package/internals/material/index.mjs +1 -1
- package/internals/plugins/corePlugins/useChartAnimation/useChartAnimation.mjs +1 -1
- package/internals/plugins/corePlugins/useChartAnimation/useChartAnimation.selectors.js +1 -1
- package/internals/plugins/corePlugins/useChartAnimation/useChartAnimation.selectors.mjs +1 -1
- package/internals/plugins/corePlugins/useChartDimensions/useChartDimensions.mjs +1 -1
- package/internals/plugins/corePlugins/useChartDimensions/useChartDimensions.selectors.js +1 -1
- package/internals/plugins/corePlugins/useChartDimensions/useChartDimensions.selectors.mjs +1 -1
- package/internals/plugins/corePlugins/useChartId/useChartId.mjs +1 -1
- package/internals/plugins/corePlugins/useChartId/useChartId.selectors.js +1 -1
- package/internals/plugins/corePlugins/useChartId/useChartId.selectors.mjs +1 -1
- package/internals/plugins/corePlugins/useChartSeries/useChartSeries.mjs +1 -1
- package/internals/plugins/corePlugins/useChartSeries/useChartSeries.selectors.js +1 -1
- package/internals/plugins/corePlugins/useChartSeries/useChartSeries.selectors.mjs +1 -1
- package/internals/plugins/corePlugins/useChartSeries/useChartSeriesLayout.selectors.js +1 -1
- package/internals/plugins/corePlugins/useChartSeries/useChartSeriesLayout.selectors.mjs +1 -1
- package/internals/plugins/corePlugins/useChartSeriesConfig/useChartSeriesConfig.mjs +1 -1
- package/internals/plugins/corePlugins/useChartSeriesConfig/useChartSeriesConfig.selectors.js +1 -1
- package/internals/plugins/corePlugins/useChartSeriesConfig/useChartSeriesConfig.selectors.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartBrush/useChartBrush.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartBrush/useChartBrush.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartBrush/useChartBrush.selectors.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/computeAxisAutoSize.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/computeAxisValue.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/defaultizeAxis.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/defaultizeZoom.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/sampling.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/sampling.selectors.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartAxisAutoSize.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartAxisAutoSize.selectors.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartAxisDomains.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartAxisDomains.selectors.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartAxisExtrema.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartAxisExtrema.selectors.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartAxisSize.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartAxisSize.selectors.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianAxis.js +3 -3
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianAxis.mjs +4 -4
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianAxisPosition.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianAxisPosition.selectors.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianAxisPreview.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianAxisPreview.selectors.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianAxisRendering.selectors.d.mts +10 -10
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianAxisRendering.selectors.d.ts +10 -10
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianAxisRendering.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianAxisRendering.selectors.mjs +2 -2
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianHighlight.selectors.d.mts +10 -10
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianHighlight.selectors.d.ts +10 -10
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianHighlight.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianHighlight.selectors.mjs +2 -2
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianInteraction.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianInteraction.selectors.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianTooltip.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartCartesianAxis/useChartCartesianTooltip.selectors.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartClosestPoint/useChartClosestPoint.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartClosestPoint/useChartClosestPoint.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartClosestPoint/useChartClosestPoint.selectors.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartHighlight/useChartHighlight.js +1 -1
- package/internals/plugins/featurePlugins/useChartHighlight/useChartHighlight.mjs +2 -2
- package/internals/plugins/featurePlugins/useChartHighlight/useChartHighlight.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartHighlight/useChartHighlight.selectors.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartInteraction/useChartInteraction.js +1 -1
- package/internals/plugins/featurePlugins/useChartInteraction/useChartInteraction.mjs +2 -2
- package/internals/plugins/featurePlugins/useChartInteraction/useChartInteraction.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartInteraction/useChartInteraction.selectors.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartKeyboardNavigation/useChartKeyboardNavigation.js +23 -9
- package/internals/plugins/featurePlugins/useChartKeyboardNavigation/useChartKeyboardNavigation.mjs +24 -10
- package/internals/plugins/featurePlugins/useChartKeyboardNavigation/useChartKeyboardNavigation.selectors.d.mts +3 -0
- package/internals/plugins/featurePlugins/useChartKeyboardNavigation/useChartKeyboardNavigation.selectors.d.ts +3 -0
- package/internals/plugins/featurePlugins/useChartKeyboardNavigation/useChartKeyboardNavigation.selectors.js +4 -3
- package/internals/plugins/featurePlugins/useChartKeyboardNavigation/useChartKeyboardNavigation.selectors.mjs +3 -2
- package/internals/plugins/featurePlugins/useChartKeyboardNavigation/useChartKeyboardNavigation.types.d.mts +12 -0
- package/internals/plugins/featurePlugins/useChartKeyboardNavigation/useChartKeyboardNavigation.types.d.ts +12 -0
- package/internals/plugins/featurePlugins/useChartPolarAxis/computeAxisValue.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartPolarAxis/defaultizeAxis.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartPolarAxis/useChartPolarAxis.js +1 -1
- package/internals/plugins/featurePlugins/useChartPolarAxis/useChartPolarAxis.mjs +3 -3
- package/internals/plugins/featurePlugins/useChartPolarAxis/useChartPolarAxis.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartPolarAxis/useChartPolarAxis.selectors.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartPolarAxis/useChartPolarInteraction.selectors.d.mts +3 -3
- package/internals/plugins/featurePlugins/useChartPolarAxis/useChartPolarInteraction.selectors.d.ts +3 -3
- package/internals/plugins/featurePlugins/useChartPolarAxis/useChartPolarInteraction.selectors.js +3 -3
- package/internals/plugins/featurePlugins/useChartPolarAxis/useChartPolarInteraction.selectors.mjs +3 -3
- package/internals/plugins/featurePlugins/useChartTooltip/useChartTooltip.js +1 -1
- package/internals/plugins/featurePlugins/useChartTooltip/useChartTooltip.mjs +2 -2
- package/internals/plugins/featurePlugins/useChartTooltip/useChartTooltip.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartTooltip/useChartTooltip.selectors.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartVisibilityManager/useChartVisibilityManager.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartVisibilityManager/useChartVisibilityManager.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartVisibilityManager/useChartVisibilityManager.selectors.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartZAxis/useChartZAxis.mjs +1 -1
- package/internals/plugins/featurePlugins/useChartZAxis/useChartZAxis.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useChartZAxis/useChartZAxis.selectors.mjs +1 -1
- package/internals/plugins/featurePlugins/useProgressiveRendering/useProgressiveRendering.mjs +1 -1
- package/internals/plugins/featurePlugins/useProgressiveRendering/useProgressiveRendering.selectors.js +1 -1
- package/internals/plugins/featurePlugins/useProgressiveRendering/useProgressiveRendering.selectors.mjs +1 -1
- package/internals/plugins/models/plugin.d.mts +1 -1
- package/internals/plugins/models/plugin.d.ts +1 -1
- package/internals/plugins/utils/useLazySelectorEffect.d.mts +1 -1
- package/internals/plugins/utils/useLazySelectorEffect.d.ts +1 -1
- package/internals/processLineLikeSeries.mjs +1 -1
- package/internals/seriesSelectorOfType.js +2 -2
- package/internals/seriesSelectorOfType.mjs +2 -2
- package/internals/store/extractPluginParamsFromProps.mjs +1 -1
- package/internals/store/useCharts.d.mts +1 -1
- package/internals/store/useCharts.d.ts +1 -1
- package/internals/store/useCharts.js +1 -1
- package/internals/store/useCharts.mjs +1 -1
- package/internals/store/useStore.d.mts +1 -1
- package/internals/store/useStore.d.ts +1 -1
- package/internals/ts-generic.d.mts +1 -1
- package/internals/ts-generic.d.ts +1 -1
- package/locales/elGR.d.mts +6 -1
- package/locales/elGR.d.ts +6 -1
- package/locales/elGR.js +8 -0
- package/locales/elGR.mjs +8 -0
- package/locales/enUS.d.mts +6 -1
- package/locales/enUS.d.ts +6 -1
- package/locales/enUS.js +8 -0
- package/locales/enUS.mjs +8 -0
- package/locales/frFR.d.mts +6 -1
- package/locales/frFR.d.ts +6 -1
- package/locales/frFR.js +8 -0
- package/locales/frFR.mjs +8 -0
- package/locales/nbNO.d.mts +6 -1
- package/locales/nbNO.d.ts +6 -1
- package/locales/nbNO.js +8 -0
- package/locales/nbNO.mjs +8 -0
- package/locales/ptBR.d.mts +6 -1
- package/locales/ptBR.d.ts +6 -1
- package/locales/ptBR.js +8 -0
- package/locales/ptBR.mjs +8 -0
- package/locales/ptPT.d.mts +6 -1
- package/locales/ptPT.d.ts +6 -1
- package/locales/ptPT.js +8 -0
- package/locales/ptPT.mjs +8 -0
- package/locales/svSE.d.mts +6 -1
- package/locales/svSE.d.ts +6 -1
- package/locales/svSE.js +8 -0
- package/locales/svSE.mjs +8 -0
- package/locales/utils/chartsLocaleTextApi.d.mts +15 -1
- package/locales/utils/chartsLocaleTextApi.d.ts +15 -1
- package/locales/utils/getChartsLocalization.d.mts +6 -1
- package/locales/utils/getChartsLocalization.d.ts +6 -1
- package/locales/utils/getChartsLocalization.mjs +1 -1
- package/package.json +9 -8
- package/tests/web-components.js +1 -0
- package/tests/web-components.mjs +1 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
|
|
3
|
-
import _extends from "@babel/runtime/helpers/
|
|
3
|
+
import _extends from "@babel/runtime/helpers/extends";
|
|
4
4
|
import * as React from 'react';
|
|
5
5
|
import useEnhancedEffect from '@mui/utils/useEnhancedEffect';
|
|
6
6
|
import useEventCallback from '@mui/utils/useEventCallback';
|
package/internals/plugins/featurePlugins/useChartClosestPoint/useChartClosestPoint.selectors.js
CHANGED
|
@@ -4,6 +4,6 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.selectorChartsIsVoronoiEnabled = void 0;
|
|
7
|
-
var _store = require("@
|
|
7
|
+
var _store = require("@base-ui/utils/store");
|
|
8
8
|
const selectVoronoi = state => state.voronoi;
|
|
9
9
|
const selectorChartsIsVoronoiEnabled = exports.selectorChartsIsVoronoiEnabled = (0, _store.createSelector)(selectVoronoi, voronoi => voronoi?.isVoronoiEnabled);
|
package/internals/plugins/featurePlugins/useChartClosestPoint/useChartClosestPoint.selectors.mjs
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { createSelector } from '@
|
|
1
|
+
import { createSelector } from '@base-ui/utils/store';
|
|
2
2
|
const selectVoronoi = state => state.voronoi;
|
|
3
3
|
export const selectorChartsIsVoronoiEnabled = createSelector(selectVoronoi, voronoi => voronoi?.isVoronoiEnabled);
|
|
@@ -10,7 +10,7 @@ var _warning = require("@mui/x-internals/warning");
|
|
|
10
10
|
var _useAssertModelConsistency = require("@mui/x-internals/useAssertModelConsistency");
|
|
11
11
|
var _useEventCallback = _interopRequireDefault(require("@mui/utils/useEventCallback"));
|
|
12
12
|
var _useEnhancedEffect = _interopRequireDefault(require("@mui/utils/useEnhancedEffect"));
|
|
13
|
-
var _fastObjectShallowCompare = require("@
|
|
13
|
+
var _fastObjectShallowCompare = require("@base-ui/utils/fastObjectShallowCompare");
|
|
14
14
|
var _useChartSeries = require("../../corePlugins/useChartSeries/useChartSeries");
|
|
15
15
|
var _cleanIdentifier = require("../../corePlugins/useChartSeriesConfig/utils/cleanIdentifier");
|
|
16
16
|
const useChartHighlight = ({
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/
|
|
1
|
+
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import { warnOnce } from '@mui/x-internals/warning';
|
|
3
3
|
import { useAssertModelConsistency } from '@mui/x-internals/useAssertModelConsistency';
|
|
4
4
|
import useEventCallback from '@mui/utils/useEventCallback';
|
|
5
5
|
import useEnhancedEffect from '@mui/utils/useEnhancedEffect';
|
|
6
|
-
import { fastObjectShallowCompare } from '@
|
|
6
|
+
import { fastObjectShallowCompare } from '@base-ui/utils/fastObjectShallowCompare';
|
|
7
7
|
import { createIdentifierWithType } from "../../corePlugins/useChartSeries/useChartSeries.mjs";
|
|
8
8
|
import { cleanIdentifier } from "../../corePlugins/useChartSeriesConfig/utils/cleanIdentifier.mjs";
|
|
9
9
|
export const useChartHighlight = ({
|
|
@@ -7,7 +7,7 @@ exports.selectorChartsHighlightScopePerSeriesId = exports.selectorChartsHighligh
|
|
|
7
7
|
exports.selectorChartsHighlightState = selectorChartsHighlightState;
|
|
8
8
|
exports.selectorChartsHighlightStateCallback = selectorChartsHighlightStateCallback;
|
|
9
9
|
exports.selectorChartsHighlightedItem = void 0;
|
|
10
|
-
var _store = require("@
|
|
10
|
+
var _store = require("@base-ui/utils/store");
|
|
11
11
|
var _highlightStates = require("./highlightStates");
|
|
12
12
|
var _useChartKeyboardNavigation = require("../useChartKeyboardNavigation");
|
|
13
13
|
var _useChartSeries = require("../../corePlugins/useChartSeries/useChartSeries.selectors");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { createSelector, createSelectorMemoized } from '@
|
|
1
|
+
import { createSelector, createSelectorMemoized } from '@base-ui/utils/store';
|
|
2
2
|
import { getSeriesHighlightedDataIndex, getSeriesUnfadedDataIndex, isSeriesFaded, isSeriesHighlighted } from "./highlightStates.mjs";
|
|
3
3
|
import { selectorChartsKeyboardItem } from "../useChartKeyboardNavigation/index.mjs";
|
|
4
4
|
import { selectorChartSeriesProcessed } from "../../corePlugins/useChartSeries/useChartSeries.selectors.mjs";
|
|
@@ -7,7 +7,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
exports.useChartInteraction = void 0;
|
|
8
8
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
9
9
|
var _useEventCallback = _interopRequireDefault(require("@mui/utils/useEventCallback"));
|
|
10
|
-
var _fastObjectShallowCompare = require("@
|
|
10
|
+
var _fastObjectShallowCompare = require("@base-ui/utils/fastObjectShallowCompare");
|
|
11
11
|
const useChartInteraction = ({
|
|
12
12
|
store
|
|
13
13
|
}) => {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/
|
|
1
|
+
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import useEventCallback from '@mui/utils/useEventCallback';
|
|
3
|
-
import { fastObjectShallowCompare } from '@
|
|
3
|
+
import { fastObjectShallowCompare } from '@base-ui/utils/fastObjectShallowCompare';
|
|
4
4
|
export const useChartInteraction = ({
|
|
5
5
|
store
|
|
6
6
|
}) => {
|
package/internals/plugins/featurePlugins/useChartInteraction/useChartInteraction.selectors.js
CHANGED
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.selectorChartsPointerType = exports.selectorChartsLastInteraction = exports.selectorChartsInteractionPointerY = exports.selectorChartsInteractionPointerX = exports.selectorChartsInteractionPointer = exports.selectorChartsInteractionIsInitialized = void 0;
|
|
7
|
-
var _store = require("@
|
|
7
|
+
var _store = require("@base-ui/utils/store");
|
|
8
8
|
const selectInteraction = state => state.interaction;
|
|
9
9
|
const selectorChartsInteractionIsInitialized = exports.selectorChartsInteractionIsInitialized = (0, _store.createSelector)(selectInteraction, interaction => interaction !== undefined);
|
|
10
10
|
const selectorChartsInteractionPointer = exports.selectorChartsInteractionPointer = (0, _store.createSelector)(selectInteraction, interaction => interaction?.pointer ?? null);
|
package/internals/plugins/featurePlugins/useChartInteraction/useChartInteraction.selectors.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { createSelector } from '@
|
|
1
|
+
import { createSelector } from '@base-ui/utils/store';
|
|
2
2
|
const selectInteraction = state => state.interaction;
|
|
3
3
|
export const selectorChartsInteractionIsInitialized = createSelector(selectInteraction, interaction => interaction !== undefined);
|
|
4
4
|
export const selectorChartsInteractionPointer = createSelector(selectInteraction, interaction => interaction?.pointer ?? null);
|
package/internals/plugins/featurePlugins/useChartKeyboardNavigation/useChartKeyboardNavigation.js
CHANGED
|
@@ -11,7 +11,7 @@ var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends")
|
|
|
11
11
|
var React = _interopRequireWildcard(require("react"));
|
|
12
12
|
var _useEnhancedEffect = _interopRequireDefault(require("@mui/utils/useEnhancedEffect"));
|
|
13
13
|
var _useEventCallback = _interopRequireDefault(require("@mui/utils/useEventCallback"));
|
|
14
|
-
var _fastObjectShallowCompare = require("@
|
|
14
|
+
var _fastObjectShallowCompare = require("@base-ui/utils/fastObjectShallowCompare");
|
|
15
15
|
var _useChartSeries = require("../../corePlugins/useChartSeries/useChartSeries.selectors");
|
|
16
16
|
var _useChartSeriesConfig = require("../../corePlugins/useChartSeriesConfig");
|
|
17
17
|
var _cleanIdentifier = require("../../corePlugins/useChartSeriesConfig/utils/cleanIdentifier");
|
|
@@ -192,6 +192,11 @@ const useChartKeyboardNavigation = ({
|
|
|
192
192
|
});
|
|
193
193
|
const activationRegistrationsRef = React.useRef(new Map());
|
|
194
194
|
const nextRegistrationIdRef = React.useRef(0);
|
|
195
|
+
const announceZoomChange = React.useCallback(() => {
|
|
196
|
+
store.set('keyboardNavigation', (0, _extends2.default)({}, store.state.keyboardNavigation, {
|
|
197
|
+
zoomAnnouncement: store.state.keyboardNavigation.zoomAnnouncement + 1
|
|
198
|
+
}));
|
|
199
|
+
}, [store]);
|
|
195
200
|
const registerItemActivationHandler = React.useCallback((scope, handler) => {
|
|
196
201
|
const registrationId = nextRegistrationIdRef.current;
|
|
197
202
|
nextRegistrationIdRef.current += 1;
|
|
@@ -219,10 +224,13 @@ const useChartKeyboardNavigation = ({
|
|
|
219
224
|
if (root && next !== null && root.contains(next)) {
|
|
220
225
|
return;
|
|
221
226
|
}
|
|
222
|
-
|
|
223
|
-
|
|
227
|
+
const keyboardNavigation = store.state.keyboardNavigation;
|
|
228
|
+
if (keyboardNavigation.isFocused || keyboardNavigation.zoomAnnouncement > 0) {
|
|
229
|
+
store.set('keyboardNavigation', (0, _extends2.default)({}, keyboardNavigation, {
|
|
224
230
|
isFocused: false,
|
|
225
|
-
isFocusVisible: false
|
|
231
|
+
isFocusVisible: false,
|
|
232
|
+
// The visible range is only announced while the user operates the chart.
|
|
233
|
+
zoomAnnouncement: 0
|
|
226
234
|
}));
|
|
227
235
|
}
|
|
228
236
|
}
|
|
@@ -268,9 +276,10 @@ const useChartKeyboardNavigation = ({
|
|
|
268
276
|
handler(event, focusedItem);
|
|
269
277
|
}
|
|
270
278
|
function keyboardHandler(event) {
|
|
271
|
-
// Item navigation only uses unmodified keys
|
|
279
|
+
// Item navigation only uses unmodified keys, except `ControlOrMeta` + `Home`/`End`.
|
|
272
280
|
// Modified ones are left to the browser, and to chart interactions such as keyboard zoom and pan.
|
|
273
|
-
|
|
281
|
+
const isCtrlHomeEnd = (event.ctrlKey || event.metaKey) && (event.key === 'Home' || event.key === 'End');
|
|
282
|
+
if (event.altKey || event.shiftKey || (event.ctrlKey || event.metaKey) && !isCtrlHomeEnd) {
|
|
274
283
|
return;
|
|
275
284
|
}
|
|
276
285
|
let newFocusedItem = store.state.keyboardNavigation.item;
|
|
@@ -286,6 +295,10 @@ const useChartKeyboardNavigation = ({
|
|
|
286
295
|
if (!calculateFocusedItem) {
|
|
287
296
|
return;
|
|
288
297
|
}
|
|
298
|
+
|
|
299
|
+
// The chart handles this key, so it should never also scroll the page, even when the focus
|
|
300
|
+
// does not move because it already is at a boundary.
|
|
301
|
+
event.preventDefault();
|
|
289
302
|
newFocusedItem = calculateFocusedItem(newFocusedItem, store.state);
|
|
290
303
|
const keyboardNavigation = store.state.keyboardNavigation;
|
|
291
304
|
// The item does not move at the edges of a series that does not cycle, but the key was still
|
|
@@ -293,7 +306,6 @@ const useChartKeyboardNavigation = ({
|
|
|
293
306
|
if (newFocusedItem === keyboardNavigation.item && keyboardNavigation.isFocusVisible) {
|
|
294
307
|
return;
|
|
295
308
|
}
|
|
296
|
-
event.preventDefault();
|
|
297
309
|
updateFocus(newFocusedItem, true);
|
|
298
310
|
}
|
|
299
311
|
element.addEventListener('keydown', activationHandler);
|
|
@@ -345,7 +357,8 @@ const useChartKeyboardNavigation = ({
|
|
|
345
357
|
return {
|
|
346
358
|
instance: {
|
|
347
359
|
focusItem,
|
|
348
|
-
registerItemActivationHandler
|
|
360
|
+
registerItemActivationHandler,
|
|
361
|
+
announceZoomChange
|
|
349
362
|
}
|
|
350
363
|
};
|
|
351
364
|
};
|
|
@@ -355,7 +368,8 @@ useChartKeyboardNavigation.getInitialState = params => ({
|
|
|
355
368
|
item: null,
|
|
356
369
|
isFocused: false,
|
|
357
370
|
isFocusVisible: false,
|
|
358
|
-
enabled: !params.disableKeyboardNavigation
|
|
371
|
+
enabled: !params.disableKeyboardNavigation,
|
|
372
|
+
zoomAnnouncement: 0
|
|
359
373
|
}
|
|
360
374
|
});
|
|
361
375
|
useChartKeyboardNavigation.params = {
|
package/internals/plugins/featurePlugins/useChartKeyboardNavigation/useChartKeyboardNavigation.mjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
|
|
3
|
-
import _extends from "@babel/runtime/helpers/
|
|
3
|
+
import _extends from "@babel/runtime/helpers/extends";
|
|
4
4
|
import * as React from 'react';
|
|
5
5
|
import useEnhancedEffect from '@mui/utils/useEnhancedEffect';
|
|
6
6
|
import useEventCallback from '@mui/utils/useEventCallback';
|
|
7
|
-
import { fastObjectShallowCompare } from '@
|
|
7
|
+
import { fastObjectShallowCompare } from '@base-ui/utils/fastObjectShallowCompare';
|
|
8
8
|
import { selectorChartDefaultizedSeries } from "../../corePlugins/useChartSeries/useChartSeries.selectors.mjs";
|
|
9
9
|
import { selectorChartSeriesConfig } from "../../corePlugins/useChartSeriesConfig/index.mjs";
|
|
10
10
|
import { cleanIdentifier } from "../../corePlugins/useChartSeriesConfig/utils/cleanIdentifier.mjs";
|
|
@@ -186,6 +186,11 @@ export const useChartKeyboardNavigation = ({
|
|
|
186
186
|
});
|
|
187
187
|
const activationRegistrationsRef = React.useRef(new Map());
|
|
188
188
|
const nextRegistrationIdRef = React.useRef(0);
|
|
189
|
+
const announceZoomChange = React.useCallback(() => {
|
|
190
|
+
store.set('keyboardNavigation', _extends({}, store.state.keyboardNavigation, {
|
|
191
|
+
zoomAnnouncement: store.state.keyboardNavigation.zoomAnnouncement + 1
|
|
192
|
+
}));
|
|
193
|
+
}, [store]);
|
|
189
194
|
const registerItemActivationHandler = React.useCallback((scope, handler) => {
|
|
190
195
|
const registrationId = nextRegistrationIdRef.current;
|
|
191
196
|
nextRegistrationIdRef.current += 1;
|
|
@@ -213,10 +218,13 @@ export const useChartKeyboardNavigation = ({
|
|
|
213
218
|
if (root && next !== null && root.contains(next)) {
|
|
214
219
|
return;
|
|
215
220
|
}
|
|
216
|
-
|
|
217
|
-
|
|
221
|
+
const keyboardNavigation = store.state.keyboardNavigation;
|
|
222
|
+
if (keyboardNavigation.isFocused || keyboardNavigation.zoomAnnouncement > 0) {
|
|
223
|
+
store.set('keyboardNavigation', _extends({}, keyboardNavigation, {
|
|
218
224
|
isFocused: false,
|
|
219
|
-
isFocusVisible: false
|
|
225
|
+
isFocusVisible: false,
|
|
226
|
+
// The visible range is only announced while the user operates the chart.
|
|
227
|
+
zoomAnnouncement: 0
|
|
220
228
|
}));
|
|
221
229
|
}
|
|
222
230
|
}
|
|
@@ -262,9 +270,10 @@ export const useChartKeyboardNavigation = ({
|
|
|
262
270
|
handler(event, focusedItem);
|
|
263
271
|
}
|
|
264
272
|
function keyboardHandler(event) {
|
|
265
|
-
// Item navigation only uses unmodified keys
|
|
273
|
+
// Item navigation only uses unmodified keys, except `ControlOrMeta` + `Home`/`End`.
|
|
266
274
|
// Modified ones are left to the browser, and to chart interactions such as keyboard zoom and pan.
|
|
267
|
-
|
|
275
|
+
const isCtrlHomeEnd = (event.ctrlKey || event.metaKey) && (event.key === 'Home' || event.key === 'End');
|
|
276
|
+
if (event.altKey || event.shiftKey || (event.ctrlKey || event.metaKey) && !isCtrlHomeEnd) {
|
|
268
277
|
return;
|
|
269
278
|
}
|
|
270
279
|
let newFocusedItem = store.state.keyboardNavigation.item;
|
|
@@ -280,6 +289,10 @@ export const useChartKeyboardNavigation = ({
|
|
|
280
289
|
if (!calculateFocusedItem) {
|
|
281
290
|
return;
|
|
282
291
|
}
|
|
292
|
+
|
|
293
|
+
// The chart handles this key, so it should never also scroll the page, even when the focus
|
|
294
|
+
// does not move because it already is at a boundary.
|
|
295
|
+
event.preventDefault();
|
|
283
296
|
newFocusedItem = calculateFocusedItem(newFocusedItem, store.state);
|
|
284
297
|
const keyboardNavigation = store.state.keyboardNavigation;
|
|
285
298
|
// The item does not move at the edges of a series that does not cycle, but the key was still
|
|
@@ -287,7 +300,6 @@ export const useChartKeyboardNavigation = ({
|
|
|
287
300
|
if (newFocusedItem === keyboardNavigation.item && keyboardNavigation.isFocusVisible) {
|
|
288
301
|
return;
|
|
289
302
|
}
|
|
290
|
-
event.preventDefault();
|
|
291
303
|
updateFocus(newFocusedItem, true);
|
|
292
304
|
}
|
|
293
305
|
element.addEventListener('keydown', activationHandler);
|
|
@@ -339,7 +351,8 @@ export const useChartKeyboardNavigation = ({
|
|
|
339
351
|
return {
|
|
340
352
|
instance: {
|
|
341
353
|
focusItem,
|
|
342
|
-
registerItemActivationHandler
|
|
354
|
+
registerItemActivationHandler,
|
|
355
|
+
announceZoomChange
|
|
343
356
|
}
|
|
344
357
|
};
|
|
345
358
|
};
|
|
@@ -348,7 +361,8 @@ useChartKeyboardNavigation.getInitialState = params => ({
|
|
|
348
361
|
item: null,
|
|
349
362
|
isFocused: false,
|
|
350
363
|
isFocusVisible: false,
|
|
351
|
-
enabled: !params.disableKeyboardNavigation
|
|
364
|
+
enabled: !params.disableKeyboardNavigation,
|
|
365
|
+
zoomAnnouncement: 0
|
|
352
366
|
}
|
|
353
367
|
});
|
|
354
368
|
useChartKeyboardNavigation.params = {
|
|
@@ -20,6 +20,9 @@ export declare const selectorChartsFocusedItem: (args_0: import("../../corePlugi
|
|
|
20
20
|
export declare const selectorChartsFocusedOrToFocusedItem: (args_0: import("../../corePlugins/useChartId/useChartId.types.mjs").UseChartIdState & import("../../corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.mjs").UseChartSeriesConfigState<keyof import("../../../index.mjs").ChartsSeriesConfig> & import("../../corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.mjs").UseChartExperimentalFeaturesState & import("../../corePlugins/useChartDimensions/useChartDimensions.types.mjs").UseChartDimensionsState & import("../../corePlugins/useChartSeries/useChartSeries.types.mjs").UseChartSeriesState<keyof import("../../../index.mjs").ChartsSeriesConfig> & import("../../corePlugins/useChartAnimation/useChartAnimation.types.mjs").UseChartAnimationState & import("../../../index.mjs").UseChartInteractionListenerState & Partial<import("./useChartKeyboardNavigation.types.mjs").UseChartKeyboardNavigationState> & {
|
|
21
21
|
cacheKey: import("../../models/index.mjs").ChartStateCacheKey;
|
|
22
22
|
}) => FocusedItemIdentifier<keyof import("../../../index.mjs").ChartsSeriesConfig> | null;
|
|
23
|
+
export declare const selectorChartsZoomAnnouncement: (args_0: import("../../corePlugins/useChartId/useChartId.types.mjs").UseChartIdState & import("../../corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.mjs").UseChartSeriesConfigState<keyof import("../../../index.mjs").ChartsSeriesConfig> & import("../../corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.mjs").UseChartExperimentalFeaturesState & import("../../corePlugins/useChartDimensions/useChartDimensions.types.mjs").UseChartDimensionsState & import("../../corePlugins/useChartSeries/useChartSeries.types.mjs").UseChartSeriesState<keyof import("../../../index.mjs").ChartsSeriesConfig> & import("../../corePlugins/useChartAnimation/useChartAnimation.types.mjs").UseChartAnimationState & import("../../../index.mjs").UseChartInteractionListenerState & Partial<import("./useChartKeyboardNavigation.types.mjs").UseChartKeyboardNavigationState> & {
|
|
24
|
+
cacheKey: import("../../models/index.mjs").ChartStateCacheKey;
|
|
25
|
+
}) => number;
|
|
23
26
|
export declare const selectorChartsIsKeyboardNavigationEnabled: (args_0: import("../../corePlugins/useChartId/useChartId.types.mjs").UseChartIdState & import("../../corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.mjs").UseChartSeriesConfigState<keyof import("../../../index.mjs").ChartsSeriesConfig> & import("../../corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.mjs").UseChartExperimentalFeaturesState & import("../../corePlugins/useChartDimensions/useChartDimensions.types.mjs").UseChartDimensionsState & import("../../corePlugins/useChartSeries/useChartSeries.types.mjs").UseChartSeriesState<keyof import("../../../index.mjs").ChartsSeriesConfig> & import("../../corePlugins/useChartAnimation/useChartAnimation.types.mjs").UseChartAnimationState & import("../../../index.mjs").UseChartInteractionListenerState & Partial<import("./useChartKeyboardNavigation.types.mjs").UseChartKeyboardNavigationState> & {
|
|
24
27
|
cacheKey: import("../../models/index.mjs").ChartStateCacheKey;
|
|
25
28
|
}) => boolean;
|
|
@@ -20,6 +20,9 @@ export declare const selectorChartsFocusedItem: (args_0: import("../../corePlugi
|
|
|
20
20
|
export declare const selectorChartsFocusedOrToFocusedItem: (args_0: import("../../corePlugins/useChartId/useChartId.types.js").UseChartIdState & import("../../corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.js").UseChartSeriesConfigState<keyof import("../../../index.js").ChartsSeriesConfig> & import("../../corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.js").UseChartExperimentalFeaturesState & import("../../corePlugins/useChartDimensions/useChartDimensions.types.js").UseChartDimensionsState & import("../../corePlugins/useChartSeries/useChartSeries.types.js").UseChartSeriesState<keyof import("../../../index.js").ChartsSeriesConfig> & import("../../corePlugins/useChartAnimation/useChartAnimation.types.js").UseChartAnimationState & import("../../../index.js").UseChartInteractionListenerState & Partial<import("./useChartKeyboardNavigation.types.js").UseChartKeyboardNavigationState> & {
|
|
21
21
|
cacheKey: import("../../models/index.js").ChartStateCacheKey;
|
|
22
22
|
}) => FocusedItemIdentifier<keyof import("../../../index.js").ChartsSeriesConfig> | null;
|
|
23
|
+
export declare const selectorChartsZoomAnnouncement: (args_0: import("../../corePlugins/useChartId/useChartId.types.js").UseChartIdState & import("../../corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.js").UseChartSeriesConfigState<keyof import("../../../index.js").ChartsSeriesConfig> & import("../../corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.js").UseChartExperimentalFeaturesState & import("../../corePlugins/useChartDimensions/useChartDimensions.types.js").UseChartDimensionsState & import("../../corePlugins/useChartSeries/useChartSeries.types.js").UseChartSeriesState<keyof import("../../../index.js").ChartsSeriesConfig> & import("../../corePlugins/useChartAnimation/useChartAnimation.types.js").UseChartAnimationState & import("../../../index.js").UseChartInteractionListenerState & Partial<import("./useChartKeyboardNavigation.types.js").UseChartKeyboardNavigationState> & {
|
|
24
|
+
cacheKey: import("../../models/index.js").ChartStateCacheKey;
|
|
25
|
+
}) => number;
|
|
23
26
|
export declare const selectorChartsIsKeyboardNavigationEnabled: (args_0: import("../../corePlugins/useChartId/useChartId.types.js").UseChartIdState & import("../../corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.js").UseChartSeriesConfigState<keyof import("../../../index.js").ChartsSeriesConfig> & import("../../corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.js").UseChartExperimentalFeaturesState & import("../../corePlugins/useChartDimensions/useChartDimensions.types.js").UseChartDimensionsState & import("../../corePlugins/useChartSeries/useChartSeries.types.js").UseChartSeriesState<keyof import("../../../index.js").ChartsSeriesConfig> & import("../../corePlugins/useChartAnimation/useChartAnimation.types.js").UseChartAnimationState & import("../../../index.js").UseChartInteractionListenerState & Partial<import("./useChartKeyboardNavigation.types.js").UseChartKeyboardNavigationState> & {
|
|
24
27
|
cacheKey: import("../../models/index.js").ChartStateCacheKey;
|
|
25
28
|
}) => boolean;
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.selectorChartsKeyboardYAxisIndex = exports.selectorChartsKeyboardXAxisIndex = exports.selectorChartsKeyboardItem = exports.selectorChartsItemIsFocused = exports.selectorChartsIsKeyboardNavigationEnabled = exports.selectorChartsIsKeyboardActivationEnabled = exports.selectorChartsIsFocusVisible = exports.selectorChartsHasFocusedItem = exports.selectorChartsFocusedOrToFocusedItem = exports.selectorChartsFocusedItem = void 0;
|
|
7
|
-
var _store = require("@
|
|
8
|
-
var _fastObjectShallowCompare = require("@
|
|
6
|
+
exports.selectorChartsZoomAnnouncement = exports.selectorChartsKeyboardYAxisIndex = exports.selectorChartsKeyboardXAxisIndex = exports.selectorChartsKeyboardItem = exports.selectorChartsItemIsFocused = exports.selectorChartsIsKeyboardNavigationEnabled = exports.selectorChartsIsKeyboardActivationEnabled = exports.selectorChartsIsFocusVisible = exports.selectorChartsHasFocusedItem = exports.selectorChartsFocusedOrToFocusedItem = exports.selectorChartsFocusedItem = void 0;
|
|
7
|
+
var _store = require("@base-ui/utils/store");
|
|
8
|
+
var _fastObjectShallowCompare = require("@base-ui/utils/fastObjectShallowCompare");
|
|
9
9
|
var _useChartSeries = require("../../corePlugins/useChartSeries");
|
|
10
10
|
var _useChartCartesianAxisRendering = require("../useChartCartesianAxis/useChartCartesianAxisRendering.selectors");
|
|
11
11
|
const selectKeyboardNavigation = state => state.keyboardNavigation;
|
|
@@ -26,6 +26,7 @@ const selectorChartsFocusedItem = exports.selectorChartsFocusedItem = (0, _store
|
|
|
26
26
|
* - will be focused when user focuses the chart
|
|
27
27
|
*/
|
|
28
28
|
const selectorChartsFocusedOrToFocusedItem = exports.selectorChartsFocusedOrToFocusedItem = (0, _store.createSelector)(selectKeyboardNavigation, keyboardNavigationState => keyboardNavigationState?.item ?? null);
|
|
29
|
+
const selectorChartsZoomAnnouncement = exports.selectorChartsZoomAnnouncement = (0, _store.createSelector)(selectKeyboardNavigation, keyboardNavigationState => keyboardNavigationState?.zoomAnnouncement ?? 0);
|
|
29
30
|
const selectorChartsIsKeyboardNavigationEnabled = exports.selectorChartsIsKeyboardNavigationEnabled = (0, _store.createSelector)(selectKeyboardNavigation, keyboardNavigationState => !!keyboardNavigationState?.enabled);
|
|
30
31
|
const selectKeyboardActivationFeature = state => state.experimentalFeatures?.keyboardActivation;
|
|
31
32
|
const selectorChartsIsKeyboardActivationEnabled = exports.selectorChartsIsKeyboardActivationEnabled = (0, _store.createSelector)(selectKeyboardNavigation, selectKeyboardActivationFeature, (keyboardNavigationState, keyboardActivation) => keyboardActivation === true && !!keyboardNavigationState?.enabled);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { createSelector, createSelectorMemoized } from '@
|
|
2
|
-
import { fastObjectShallowCompare } from '@
|
|
1
|
+
import { createSelector, createSelectorMemoized } from '@base-ui/utils/store';
|
|
2
|
+
import { fastObjectShallowCompare } from '@base-ui/utils/fastObjectShallowCompare';
|
|
3
3
|
import { selectorChartSeriesProcessed } from "../../corePlugins/useChartSeries/index.mjs";
|
|
4
4
|
import { selectorChartXAxis, selectorChartYAxis } from "../useChartCartesianAxis/useChartCartesianAxisRendering.selectors.mjs";
|
|
5
5
|
const selectKeyboardNavigation = state => state.keyboardNavigation;
|
|
@@ -20,6 +20,7 @@ export const selectorChartsFocusedItem = createSelector(selectKeyboardNavigation
|
|
|
20
20
|
* - will be focused when user focuses the chart
|
|
21
21
|
*/
|
|
22
22
|
export const selectorChartsFocusedOrToFocusedItem = createSelector(selectKeyboardNavigation, keyboardNavigationState => keyboardNavigationState?.item ?? null);
|
|
23
|
+
export const selectorChartsZoomAnnouncement = createSelector(selectKeyboardNavigation, keyboardNavigationState => keyboardNavigationState?.zoomAnnouncement ?? 0);
|
|
23
24
|
export const selectorChartsIsKeyboardNavigationEnabled = createSelector(selectKeyboardNavigation, keyboardNavigationState => !!keyboardNavigationState?.enabled);
|
|
24
25
|
const selectKeyboardActivationFeature = state => state.experimentalFeatures?.keyboardActivation;
|
|
25
26
|
export const selectorChartsIsKeyboardActivationEnabled = createSelector(selectKeyboardNavigation, selectKeyboardActivationFeature, (keyboardNavigationState, keyboardActivation) => keyboardActivation === true && !!keyboardNavigationState?.enabled);
|
|
@@ -58,6 +58,12 @@ export interface UseChartKeyboardNavigationInstance {
|
|
|
58
58
|
* @returns {() => void} A cleanup function unregistering the handler.
|
|
59
59
|
*/
|
|
60
60
|
registerItemActivationHandler: (scope: ItemActivationScope, handler: ItemActivationHandler) => () => void;
|
|
61
|
+
/**
|
|
62
|
+
* Asks for the visible zoom range to be announced to screen readers.
|
|
63
|
+
* Called by the plugin owning keyboard zoom and pan, on each change the user makes with the keys.
|
|
64
|
+
* @returns {void}
|
|
65
|
+
*/
|
|
66
|
+
announceZoomChange: () => void;
|
|
61
67
|
}
|
|
62
68
|
export interface UseChartKeyboardNavigationState {
|
|
63
69
|
keyboardNavigation: {
|
|
@@ -78,6 +84,12 @@ export interface UseChartKeyboardNavigationState {
|
|
|
78
84
|
* Indicates whether keyboard navigation is enabled or not.
|
|
79
85
|
*/
|
|
80
86
|
enabled: boolean;
|
|
87
|
+
/**
|
|
88
|
+
* Incremented on each zoom change the user makes with the keyboard, and reset when the chart
|
|
89
|
+
* loses focus. The live region reads the visible range when it changes, so a zoom coming from
|
|
90
|
+
* the pointer or from the application is not announced.
|
|
91
|
+
*/
|
|
92
|
+
zoomAnnouncement: number;
|
|
81
93
|
};
|
|
82
94
|
}
|
|
83
95
|
type UseChartKeyboardNavigationParameters = {
|
|
@@ -58,6 +58,12 @@ export interface UseChartKeyboardNavigationInstance {
|
|
|
58
58
|
* @returns {() => void} A cleanup function unregistering the handler.
|
|
59
59
|
*/
|
|
60
60
|
registerItemActivationHandler: (scope: ItemActivationScope, handler: ItemActivationHandler) => () => void;
|
|
61
|
+
/**
|
|
62
|
+
* Asks for the visible zoom range to be announced to screen readers.
|
|
63
|
+
* Called by the plugin owning keyboard zoom and pan, on each change the user makes with the keys.
|
|
64
|
+
* @returns {void}
|
|
65
|
+
*/
|
|
66
|
+
announceZoomChange: () => void;
|
|
61
67
|
}
|
|
62
68
|
export interface UseChartKeyboardNavigationState {
|
|
63
69
|
keyboardNavigation: {
|
|
@@ -78,6 +84,12 @@ export interface UseChartKeyboardNavigationState {
|
|
|
78
84
|
* Indicates whether keyboard navigation is enabled or not.
|
|
79
85
|
*/
|
|
80
86
|
enabled: boolean;
|
|
87
|
+
/**
|
|
88
|
+
* Incremented on each zoom change the user makes with the keyboard, and reset when the chart
|
|
89
|
+
* loses focus. The live region reads the visible range when it changes, so a zoom coming from
|
|
90
|
+
* the pointer or from the application is not announced.
|
|
91
|
+
*/
|
|
92
|
+
zoomAnnouncement: number;
|
|
81
93
|
};
|
|
82
94
|
}
|
|
83
95
|
type UseChartKeyboardNavigationParameters = {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/
|
|
1
|
+
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import { isBandScaleConfig, isPointScaleConfig, isContinuousScaleConfig } from "../../../../models/axis.mjs";
|
|
3
3
|
import { getColorScale, getOrdinalColorScale } from "../../../colorScale.mjs";
|
|
4
4
|
import { getDefaultTickNumber, getTickNumber } from "../../../ticks.mjs";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import _formatErrorMessage from "@mui/x-internals/formatErrorMessage";
|
|
2
|
-
import _extends from "@babel/runtime/helpers/
|
|
2
|
+
import _extends from "@babel/runtime/helpers/extends";
|
|
3
3
|
import { DEFAULT_RADIUS_AXIS_KEY, DEFAULT_ROTATION_AXIS_KEY } from "../../../../constants/index.mjs";
|
|
4
4
|
export function defaultizeAxis(inAxis, dataset, axisName) {
|
|
5
5
|
const DEFAULT_AXIS_KEY = axisName === 'rotation' ? DEFAULT_ROTATION_AXIS_KEY : DEFAULT_RADIUS_AXIS_KEY;
|
|
@@ -39,7 +39,7 @@ const useChartPolarAxis = ({
|
|
|
39
39
|
const ids = [...(rotationAxis ?? []), ...(radiusAxis ?? [])].filter(axis => axis.id).map(axis => axis.id);
|
|
40
40
|
const duplicates = new Set(ids.filter((id, index) => ids.indexOf(id) !== index));
|
|
41
41
|
if (duplicates.size > 0) {
|
|
42
|
-
(0, _warning.
|
|
42
|
+
(0, _warning.errorOnce)([`MUI X Charts: The following axis ids are duplicated: ${Array.from(duplicates).join(', ')}.`, `Please make sure that each axis has a unique id.`].join('\n'));
|
|
43
43
|
}
|
|
44
44
|
}
|
|
45
45
|
const drawingArea = store.use(_useChartDimensions.selectorChartDrawingArea);
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
|
|
3
|
-
import _extends from "@babel/runtime/helpers/
|
|
3
|
+
import _extends from "@babel/runtime/helpers/extends";
|
|
4
4
|
import * as React from 'react';
|
|
5
|
-
import {
|
|
5
|
+
import { errorOnce } from '@mui/x-internals/warning';
|
|
6
6
|
import useEventCallback from '@mui/utils/useEventCallback';
|
|
7
7
|
import { selectorChartDrawingArea } from "../../corePlugins/useChartDimensions/useChartDimensions.selectors.mjs";
|
|
8
8
|
import { defaultizeAxis } from "./defaultizeAxis.mjs";
|
|
@@ -32,7 +32,7 @@ export const useChartPolarAxis = ({
|
|
|
32
32
|
const ids = [...(rotationAxis ?? []), ...(radiusAxis ?? [])].filter(axis => axis.id).map(axis => axis.id);
|
|
33
33
|
const duplicates = new Set(ids.filter((id, index) => ids.indexOf(id) !== index));
|
|
34
34
|
if (duplicates.size > 0) {
|
|
35
|
-
|
|
35
|
+
errorOnce([`MUI X Charts: The following axis ids are duplicated: ${Array.from(duplicates).join(', ')}.`, `Please make sure that each axis has a unique id.`].join('\n'));
|
|
36
36
|
}
|
|
37
37
|
}
|
|
38
38
|
const drawingArea = store.use(selectorChartDrawingArea);
|
|
@@ -5,7 +5,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.getDrawingAreaCenter = getDrawingAreaCenter;
|
|
7
7
|
exports.selectorChartRotationAxis = exports.selectorChartRawRotationAxis = exports.selectorChartRawRadiusAxis = exports.selectorChartRadiusAxis = exports.selectorChartPolarCenter = exports.selectorChartPolarAxisState = void 0;
|
|
8
|
-
var _store = require("@
|
|
8
|
+
var _store = require("@base-ui/utils/store");
|
|
9
9
|
var _useChartDimensions = require("../../corePlugins/useChartDimensions");
|
|
10
10
|
var _useChartSeries = require("../../corePlugins/useChartSeries");
|
|
11
11
|
var _computeAxisValue = require("./computeAxisValue");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { createSelector, createSelectorMemoized } from '@
|
|
1
|
+
import { createSelector, createSelectorMemoized } from '@base-ui/utils/store';
|
|
2
2
|
import { selectorChartDrawingArea } from "../../corePlugins/useChartDimensions/index.mjs";
|
|
3
3
|
import { selectorChartSeriesProcessed } from "../../corePlugins/useChartSeries/index.mjs";
|
|
4
4
|
import { computeAxisValue } from "./computeAxisValue.mjs";
|
package/internals/plugins/featurePlugins/useChartPolarAxis/useChartPolarInteraction.selectors.d.mts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import type { AxisItemIdentifier } from "../../../../models/axis.mjs";
|
|
1
|
+
import type { AxisId, AxisItemIdentifier } from "../../../../models/axis.mjs";
|
|
2
2
|
export declare const selectorChartsInteractionRotationAxisIndex: (args_0: import("../../corePlugins/useChartId/useChartId.types.mjs").UseChartIdState & import("../../corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.mjs").UseChartSeriesConfigState<keyof import("../../../index.mjs").ChartsSeriesConfig> & import("../../corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.mjs").UseChartExperimentalFeaturesState & import("../../corePlugins/useChartDimensions/useChartDimensions.types.mjs").UseChartDimensionsState & import("../../corePlugins/useChartSeries/useChartSeries.types.mjs").UseChartSeriesState<keyof import("../../../index.mjs").ChartsSeriesConfig> & import("../../corePlugins/useChartAnimation/useChartAnimation.types.mjs").UseChartAnimationState & import("../../../index.mjs").UseChartInteractionListenerState & Partial<import("../useChartInteraction/useChartInteraction.types.mjs").UseChartInteractionState> & {
|
|
3
3
|
cacheKey: import("../../models/index.mjs").ChartStateCacheKey;
|
|
4
4
|
}) => number | null;
|
|
5
5
|
export declare const selectorChartsInteractionRotationAxisIndexes: (args_0: import("../../corePlugins/useChartId/useChartId.types.mjs").UseChartIdState & import("../../corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.mjs").UseChartSeriesConfigState<keyof import("../../../index.mjs").ChartsSeriesConfig> & import("../../corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.mjs").UseChartExperimentalFeaturesState & import("../../corePlugins/useChartDimensions/useChartDimensions.types.mjs").UseChartDimensionsState & import("../../corePlugins/useChartSeries/useChartSeries.types.mjs").UseChartSeriesState<keyof import("../../../index.mjs").ChartsSeriesConfig> & import("../../corePlugins/useChartAnimation/useChartAnimation.types.mjs").UseChartAnimationState & import("../../../index.mjs").UseChartInteractionListenerState & Partial<import("../useChartInteraction/useChartInteraction.types.mjs").UseChartInteractionState> & {
|
|
6
6
|
cacheKey: import("../../models/index.mjs").ChartStateCacheKey;
|
|
7
|
-
}) => number[] | null;
|
|
7
|
+
}, ids: AxisId[] | undefined) => number[] | null;
|
|
8
8
|
export declare const selectorChartsInteractionRotationAxisValue: (args_0: import("../../corePlugins/useChartId/useChartId.types.mjs").UseChartIdState & import("../../corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.mjs").UseChartSeriesConfigState<keyof import("../../../index.mjs").ChartsSeriesConfig> & import("../../corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.mjs").UseChartExperimentalFeaturesState & import("../../corePlugins/useChartDimensions/useChartDimensions.types.mjs").UseChartDimensionsState & import("../../corePlugins/useChartSeries/useChartSeries.types.mjs").UseChartSeriesState<keyof import("../../../index.mjs").ChartsSeriesConfig> & import("../../corePlugins/useChartAnimation/useChartAnimation.types.mjs").UseChartAnimationState & import("../../../index.mjs").UseChartInteractionListenerState & Partial<import("./useChartPolarAxis.types.mjs").UseChartPolarAxisState> & {
|
|
9
9
|
cacheKey: import("../../models/index.mjs").ChartStateCacheKey;
|
|
10
10
|
}) => any;
|
|
@@ -28,7 +28,7 @@ export declare const selectorChartsInteractionRadiusAxisIndex: (args_0: import("
|
|
|
28
28
|
}) => number | null;
|
|
29
29
|
export declare const selectorChartsInteractionRadiusAxisIndexes: (args_0: import("../../corePlugins/useChartId/useChartId.types.mjs").UseChartIdState & import("../../corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.mjs").UseChartSeriesConfigState<keyof import("../../../index.mjs").ChartsSeriesConfig> & import("../../corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.mjs").UseChartExperimentalFeaturesState & import("../../corePlugins/useChartDimensions/useChartDimensions.types.mjs").UseChartDimensionsState & import("../../corePlugins/useChartSeries/useChartSeries.types.mjs").UseChartSeriesState<keyof import("../../../index.mjs").ChartsSeriesConfig> & import("../../corePlugins/useChartAnimation/useChartAnimation.types.mjs").UseChartAnimationState & import("../../../index.mjs").UseChartInteractionListenerState & Partial<import("../useChartInteraction/useChartInteraction.types.mjs").UseChartInteractionState> & {
|
|
30
30
|
cacheKey: import("../../models/index.mjs").ChartStateCacheKey;
|
|
31
|
-
}) => number[] | null;
|
|
31
|
+
}, ids: AxisId[] | undefined) => number[] | null;
|
|
32
32
|
export declare const selectorChartsInteractionRadiusAxisValue: (args_0: import("../../corePlugins/useChartId/useChartId.types.mjs").UseChartIdState & import("../../corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.mjs").UseChartSeriesConfigState<keyof import("../../../index.mjs").ChartsSeriesConfig> & import("../../corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.mjs").UseChartExperimentalFeaturesState & import("../../corePlugins/useChartDimensions/useChartDimensions.types.mjs").UseChartDimensionsState & import("../../corePlugins/useChartSeries/useChartSeries.types.mjs").UseChartSeriesState<keyof import("../../../index.mjs").ChartsSeriesConfig> & import("../../corePlugins/useChartAnimation/useChartAnimation.types.mjs").UseChartAnimationState & import("../../../index.mjs").UseChartInteractionListenerState & Partial<import("./useChartPolarAxis.types.mjs").UseChartPolarAxisState> & {
|
|
33
33
|
cacheKey: import("../../models/index.mjs").ChartStateCacheKey;
|
|
34
34
|
}) => any;
|
package/internals/plugins/featurePlugins/useChartPolarAxis/useChartPolarInteraction.selectors.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import type { AxisItemIdentifier } from "../../../../models/axis.js";
|
|
1
|
+
import type { AxisId, AxisItemIdentifier } from "../../../../models/axis.js";
|
|
2
2
|
export declare const selectorChartsInteractionRotationAxisIndex: (args_0: import("../../corePlugins/useChartId/useChartId.types.js").UseChartIdState & import("../../corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.js").UseChartSeriesConfigState<keyof import("../../../index.js").ChartsSeriesConfig> & import("../../corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.js").UseChartExperimentalFeaturesState & import("../../corePlugins/useChartDimensions/useChartDimensions.types.js").UseChartDimensionsState & import("../../corePlugins/useChartSeries/useChartSeries.types.js").UseChartSeriesState<keyof import("../../../index.js").ChartsSeriesConfig> & import("../../corePlugins/useChartAnimation/useChartAnimation.types.js").UseChartAnimationState & import("../../../index.js").UseChartInteractionListenerState & Partial<import("../useChartInteraction/useChartInteraction.types.js").UseChartInteractionState> & {
|
|
3
3
|
cacheKey: import("../../models/index.js").ChartStateCacheKey;
|
|
4
4
|
}) => number | null;
|
|
5
5
|
export declare const selectorChartsInteractionRotationAxisIndexes: (args_0: import("../../corePlugins/useChartId/useChartId.types.js").UseChartIdState & import("../../corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.js").UseChartSeriesConfigState<keyof import("../../../index.js").ChartsSeriesConfig> & import("../../corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.js").UseChartExperimentalFeaturesState & import("../../corePlugins/useChartDimensions/useChartDimensions.types.js").UseChartDimensionsState & import("../../corePlugins/useChartSeries/useChartSeries.types.js").UseChartSeriesState<keyof import("../../../index.js").ChartsSeriesConfig> & import("../../corePlugins/useChartAnimation/useChartAnimation.types.js").UseChartAnimationState & import("../../../index.js").UseChartInteractionListenerState & Partial<import("../useChartInteraction/useChartInteraction.types.js").UseChartInteractionState> & {
|
|
6
6
|
cacheKey: import("../../models/index.js").ChartStateCacheKey;
|
|
7
|
-
}) => number[] | null;
|
|
7
|
+
}, ids: AxisId[] | undefined) => number[] | null;
|
|
8
8
|
export declare const selectorChartsInteractionRotationAxisValue: (args_0: import("../../corePlugins/useChartId/useChartId.types.js").UseChartIdState & import("../../corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.js").UseChartSeriesConfigState<keyof import("../../../index.js").ChartsSeriesConfig> & import("../../corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.js").UseChartExperimentalFeaturesState & import("../../corePlugins/useChartDimensions/useChartDimensions.types.js").UseChartDimensionsState & import("../../corePlugins/useChartSeries/useChartSeries.types.js").UseChartSeriesState<keyof import("../../../index.js").ChartsSeriesConfig> & import("../../corePlugins/useChartAnimation/useChartAnimation.types.js").UseChartAnimationState & import("../../../index.js").UseChartInteractionListenerState & Partial<import("./useChartPolarAxis.types.js").UseChartPolarAxisState> & {
|
|
9
9
|
cacheKey: import("../../models/index.js").ChartStateCacheKey;
|
|
10
10
|
}) => any;
|
|
@@ -28,7 +28,7 @@ export declare const selectorChartsInteractionRadiusAxisIndex: (args_0: import("
|
|
|
28
28
|
}) => number | null;
|
|
29
29
|
export declare const selectorChartsInteractionRadiusAxisIndexes: (args_0: import("../../corePlugins/useChartId/useChartId.types.js").UseChartIdState & import("../../corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.js").UseChartSeriesConfigState<keyof import("../../../index.js").ChartsSeriesConfig> & import("../../corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.js").UseChartExperimentalFeaturesState & import("../../corePlugins/useChartDimensions/useChartDimensions.types.js").UseChartDimensionsState & import("../../corePlugins/useChartSeries/useChartSeries.types.js").UseChartSeriesState<keyof import("../../../index.js").ChartsSeriesConfig> & import("../../corePlugins/useChartAnimation/useChartAnimation.types.js").UseChartAnimationState & import("../../../index.js").UseChartInteractionListenerState & Partial<import("../useChartInteraction/useChartInteraction.types.js").UseChartInteractionState> & {
|
|
30
30
|
cacheKey: import("../../models/index.js").ChartStateCacheKey;
|
|
31
|
-
}) => number[] | null;
|
|
31
|
+
}, ids: AxisId[] | undefined) => number[] | null;
|
|
32
32
|
export declare const selectorChartsInteractionRadiusAxisValue: (args_0: import("../../corePlugins/useChartId/useChartId.types.js").UseChartIdState & import("../../corePlugins/useChartSeriesConfig/useChartSeriesConfig.types.js").UseChartSeriesConfigState<keyof import("../../../index.js").ChartsSeriesConfig> & import("../../corePlugins/useChartExperimentalFeature/useChartExperimentalFeature.types.js").UseChartExperimentalFeaturesState & import("../../corePlugins/useChartDimensions/useChartDimensions.types.js").UseChartDimensionsState & import("../../corePlugins/useChartSeries/useChartSeries.types.js").UseChartSeriesState<keyof import("../../../index.js").ChartsSeriesConfig> & import("../../corePlugins/useChartAnimation/useChartAnimation.types.js").UseChartAnimationState & import("../../../index.js").UseChartInteractionListenerState & Partial<import("./useChartPolarAxis.types.js").UseChartPolarAxisState> & {
|
|
33
33
|
cacheKey: import("../../models/index.js").ChartStateCacheKey;
|
|
34
34
|
}) => any;
|
package/internals/plugins/featurePlugins/useChartPolarAxis/useChartPolarInteraction.selectors.js
CHANGED
|
@@ -5,7 +5,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.selectorChartsInteractionTooltipRotationAxes = exports.selectorChartsInteractionTooltipRadiusAxes = exports.selectorChartsInteractionRotationAxisValues = exports.selectorChartsInteractionRotationAxisValue = exports.selectorChartsInteractionRotationAxisIndexes = exports.selectorChartsInteractionRotationAxisIndex = exports.selectorChartsInteractionRadiusAxisValues = exports.selectorChartsInteractionRadiusAxisValue = exports.selectorChartsInteractionRadiusAxisIndexes = exports.selectorChartsInteractionRadiusAxisIndex = exports.selectorChartsInteractionRadius = exports.selectorChartsInteractionPolarAxisTooltip = void 0;
|
|
7
7
|
var _isDeepEqual = require("@mui/x-internals/isDeepEqual");
|
|
8
|
-
var _store = require("@
|
|
8
|
+
var _store = require("@base-ui/utils/store");
|
|
9
9
|
var _useChartInteraction = require("../useChartInteraction/useChartInteraction.selectors");
|
|
10
10
|
var _coordinateTransformation = require("./coordinateTransformation");
|
|
11
11
|
var _getAxisIndex = require("./getAxisIndex");
|
|
@@ -38,7 +38,7 @@ const selectorChartsInteractionRotationAngle = (0, _store.createSelector)(_useCh
|
|
|
38
38
|
return (0, _coordinateTransformation.generateSvg2rotation)(center)(x, y);
|
|
39
39
|
});
|
|
40
40
|
const selectorChartsInteractionRotationAxisIndex = exports.selectorChartsInteractionRotationAxisIndex = (0, _store.createSelector)(selectorChartsInteractionRotationAngle, _useChartPolarAxis.selectorChartRotationAxis, optionalGetAxisId, (rotation, rotationAxis, id) => rotation === null ? null : indexGetter(rotation, rotationAxis, id ?? rotationAxis.axisIds[0], 'rotation'));
|
|
41
|
-
const selectorChartsInteractionRotationAxisIndexes = exports.selectorChartsInteractionRotationAxisIndexes = (0, _store.
|
|
41
|
+
const selectorChartsInteractionRotationAxisIndexes = exports.selectorChartsInteractionRotationAxisIndexes = (0, _store.createSelectorMemoized)(selectorChartsInteractionRotationAngle, _useChartPolarAxis.selectorChartRotationAxis, (rotation, rotationAxis, ids) => rotation === null ? null : indexGetter(rotation, rotationAxis, ids ?? rotationAxis.axisIds, 'rotation'));
|
|
42
42
|
const selectorChartsInteractionRotationAxisValue = exports.selectorChartsInteractionRotationAxisValue = (0, _store.createSelector)(_useChartPolarAxis.selectorChartRotationAxis, selectorChartsInteractionRotationAxisIndex, optionalGetAxisId, (rotationAxis, rotationIndex, id) => {
|
|
43
43
|
id = id ?? rotationAxis.axisIds[0];
|
|
44
44
|
if (rotationIndex === null || rotationIndex === -1 || rotationAxis.axisIds.length === 0) {
|
|
@@ -99,7 +99,7 @@ const selectorChartsInteractionRadius = exports.selectorChartsInteractionRadius
|
|
|
99
99
|
return Math.sqrt((x - center.cx) ** 2 + (y - center.cy) ** 2);
|
|
100
100
|
});
|
|
101
101
|
const selectorChartsInteractionRadiusAxisIndex = exports.selectorChartsInteractionRadiusAxisIndex = (0, _store.createSelector)(selectorChartsInteractionRadius, _useChartPolarAxis.selectorChartRadiusAxis, optionalGetAxisId, (radius, radiusAxis, id) => radius === null ? null : indexGetter(radius, radiusAxis, id ?? radiusAxis.axisIds[0], 'radius'));
|
|
102
|
-
const selectorChartsInteractionRadiusAxisIndexes = exports.selectorChartsInteractionRadiusAxisIndexes = (0, _store.
|
|
102
|
+
const selectorChartsInteractionRadiusAxisIndexes = exports.selectorChartsInteractionRadiusAxisIndexes = (0, _store.createSelectorMemoized)(selectorChartsInteractionRadius, _useChartPolarAxis.selectorChartRadiusAxis, (radius, radiusAxis, ids) => radius === null ? null : indexGetter(radius, radiusAxis, ids ?? radiusAxis.axisIds, 'radius'));
|
|
103
103
|
const selectorChartsInteractionRadiusAxisValue = exports.selectorChartsInteractionRadiusAxisValue = (0, _store.createSelector)(_useChartPolarAxis.selectorChartRadiusAxis, selectorChartsInteractionRadiusAxisIndex, optionalGetAxisId, (radiusAxis, radiusIndex, id) => {
|
|
104
104
|
id = id ?? radiusAxis.axisIds[0];
|
|
105
105
|
if (radiusIndex === null || radiusIndex === -1 || radiusAxis.axisIds.length === 0) {
|