@fluentui/react-charts 9.3.27 → 9.3.29
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/CHANGELOG.md +32 -2
- package/dist/index.d.cts +51 -0
- package/dist/index.d.ts +51 -0
- package/lib/components/AnnotationOnlyChart/AnnotationOnlyChart.js +1 -4
- package/lib/components/AnnotationOnlyChart/AnnotationOnlyChart.js.map +1 -1
- package/lib/components/AnnotationOnlyChart/AnnotationOnlyChart.types.js.map +1 -1
- package/lib/components/AnnotationOnlyChart/index.js.map +1 -1
- package/lib/components/AnnotationOnlyChart/useAnnotationOnlyChartStyles.styles.raw.js.map +1 -1
- package/lib/components/AreaChart/AreaChart.js +35 -5
- package/lib/components/AreaChart/AreaChart.js.map +1 -1
- package/lib/components/AreaChart/AreaChart.types.js.map +1 -1
- package/lib/components/AreaChart/index.js.map +1 -1
- package/lib/components/AreaChart/useAreaChartStyles.styles.raw.js.map +1 -1
- package/lib/components/ChartTable/ChartTable.js.map +1 -1
- package/lib/components/ChartTable/ChartTable.types.js.map +1 -1
- package/lib/components/ChartTable/index.js.map +1 -1
- package/lib/components/ChartTable/useChartTableStyles.styles.raw.js.map +1 -1
- package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.js +19 -29
- package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.js.map +1 -1
- package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.types.js.map +1 -1
- package/lib/components/CommonComponents/Annotations/index.js.map +1 -1
- package/lib/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.js +2 -2
- package/lib/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.js.map +1 -1
- package/lib/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.raw.js +2 -2
- package/lib/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.raw.js.map +1 -1
- package/lib/components/CommonComponents/CartesianChart.js +17 -15
- package/lib/components/CommonComponents/CartesianChart.js.map +1 -1
- package/lib/components/CommonComponents/CartesianChart.types.js.map +1 -1
- package/lib/components/CommonComponents/ChartPopover.js +3 -2
- package/lib/components/CommonComponents/ChartPopover.js.map +1 -1
- package/lib/components/CommonComponents/ChartPopover.types.js.map +1 -1
- package/lib/components/CommonComponents/index.js.map +1 -1
- package/lib/components/CommonComponents/useCartesianChartStyles.styles.raw.js.map +1 -1
- package/lib/components/CommonComponents/useChartPopoverStyles.styles.raw.js.map +1 -1
- package/lib/components/DeclarativeChart/DeclarativeChart.js +9 -9
- package/lib/components/DeclarativeChart/DeclarativeChart.js.map +1 -1
- package/lib/components/DeclarativeChart/PlotlyColorAdapter.js +4 -4
- package/lib/components/DeclarativeChart/PlotlyColorAdapter.js.map +1 -1
- package/lib/components/DeclarativeChart/PlotlySchemaAdapter.js +92 -110
- package/lib/components/DeclarativeChart/PlotlySchemaAdapter.js.map +1 -1
- package/lib/components/DeclarativeChart/index.js.map +1 -1
- package/lib/components/DonutChart/Arc/Arc.js.map +1 -1
- package/lib/components/DonutChart/Arc/Arc.types.js.map +1 -1
- package/lib/components/DonutChart/Arc/index.js.map +1 -1
- package/lib/components/DonutChart/Arc/useArcStyles.styles.raw.js.map +1 -1
- package/lib/components/DonutChart/DonutChart.js.map +1 -1
- package/lib/components/DonutChart/DonutChart.types.js.map +1 -1
- package/lib/components/DonutChart/Pie/Pie.js.map +1 -1
- package/lib/components/DonutChart/Pie/Pie.types.js.map +1 -1
- package/lib/components/DonutChart/Pie/index.js.map +1 -1
- package/lib/components/DonutChart/Pie/usePieStyles.styles.raw.js.map +1 -1
- package/lib/components/DonutChart/index.js.map +1 -1
- package/lib/components/DonutChart/useDonutChartStyles.styles.raw.js.map +1 -1
- package/lib/components/FunnelChart/FunnelChart.js +5 -5
- package/lib/components/FunnelChart/FunnelChart.js.map +1 -1
- package/lib/components/FunnelChart/FunnelChart.types.js.map +1 -1
- package/lib/components/FunnelChart/funnelGeometry.js.map +1 -1
- package/lib/components/FunnelChart/index.js.map +1 -1
- package/lib/components/FunnelChart/useFunnelChartStyles.styles.raw.js.map +1 -1
- package/lib/components/GanttChart/GanttChart.js +4 -3
- package/lib/components/GanttChart/GanttChart.js.map +1 -1
- package/lib/components/GanttChart/GanttChart.types.js.map +1 -1
- package/lib/components/GanttChart/index.js.map +1 -1
- package/lib/components/GanttChart/useGanttChartStyles.styles.raw.js.map +1 -1
- package/lib/components/GaugeChart/GaugeChart.js +34 -13
- package/lib/components/GaugeChart/GaugeChart.js.map +1 -1
- package/lib/components/GaugeChart/GaugeChart.types.js.map +1 -1
- package/lib/components/GaugeChart/index.js.map +1 -1
- package/lib/components/GaugeChart/useGaugeChartStyles.styles.raw.js.map +1 -1
- package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.js +45 -46
- package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.js.map +1 -1
- package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.types.js.map +1 -1
- package/lib/components/GroupedVerticalBarChart/index.js.map +1 -1
- package/lib/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.raw.js.map +1 -1
- package/lib/components/HeatMapChart/HeatMapChart.js +1 -0
- package/lib/components/HeatMapChart/HeatMapChart.js.map +1 -1
- package/lib/components/HeatMapChart/HeatMapChart.types.js.map +1 -1
- package/lib/components/HeatMapChart/index.js.map +1 -1
- package/lib/components/HeatMapChart/useHeatMapChartStyles.styles.raw.js.map +1 -1
- package/lib/components/HorizontalBarChart/HorizontalBarChart.js +5 -6
- package/lib/components/HorizontalBarChart/HorizontalBarChart.js.map +1 -1
- package/lib/components/HorizontalBarChart/HorizontalBarChart.types.js.map +1 -1
- package/lib/components/HorizontalBarChart/index.js.map +1 -1
- package/lib/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.raw.js.map +1 -1
- package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.js +4 -4
- package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.js.map +1 -1
- package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.js.map +1 -1
- package/lib/components/HorizontalBarChartWithAxis/index.js.map +1 -1
- package/lib/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.raw.js.map +1 -1
- package/lib/components/Legends/Legends.js +16 -20
- package/lib/components/Legends/Legends.js.map +1 -1
- package/lib/components/Legends/Legends.types.js.map +1 -1
- package/lib/components/Legends/OverflowMenu.js +13 -10
- package/lib/components/Legends/OverflowMenu.js.map +1 -1
- package/lib/components/Legends/index.js.map +1 -1
- package/lib/components/Legends/shape.js.map +1 -1
- package/lib/components/Legends/useLegendsStyles.styles.raw.js.map +1 -1
- package/lib/components/LineChart/LineChart.js +40 -36
- package/lib/components/LineChart/LineChart.js.map +1 -1
- package/lib/components/LineChart/LineChart.types.js.map +1 -1
- package/lib/components/LineChart/eventAnnotation/EventAnnotation.js.map +1 -1
- package/lib/components/LineChart/eventAnnotation/LabelLink.js.map +1 -1
- package/lib/components/LineChart/eventAnnotation/Textbox.js.map +1 -1
- package/lib/components/LineChart/index.js.map +1 -1
- package/lib/components/LineChart/useLineChartStyles.styles.raw.js.map +1 -1
- package/lib/components/PolarChart/PolarChart.js +3 -4
- package/lib/components/PolarChart/PolarChart.js.map +1 -1
- package/lib/components/PolarChart/PolarChart.types.js.map +1 -1
- package/lib/components/PolarChart/PolarChart.utils.js +3 -3
- package/lib/components/PolarChart/PolarChart.utils.js.map +1 -1
- package/lib/components/PolarChart/index.js.map +1 -1
- package/lib/components/PolarChart/usePolarChartStyles.styles.raw.js.map +1 -1
- package/lib/components/ResponsiveContainer/ResponsiveContainer.js +1 -1
- package/lib/components/ResponsiveContainer/ResponsiveContainer.js.map +1 -1
- package/lib/components/ResponsiveContainer/ResponsiveContainer.types.js.map +1 -1
- package/lib/components/ResponsiveContainer/index.js.map +1 -1
- package/lib/components/ResponsiveContainer/useResponsiveChildStyles.styles.raw.js.map +1 -1
- package/lib/components/ResponsiveContainer/withResponsiveContainer.js.map +1 -1
- package/lib/components/SankeyChart/SankeyChart.js.map +1 -1
- package/lib/components/SankeyChart/SankeyChart.types.js.map +1 -1
- package/lib/components/SankeyChart/index.js.map +1 -1
- package/lib/components/SankeyChart/useSankeyChartStyles.styles.raw.js.map +1 -1
- package/lib/components/ScatterChart/ScatterChart.js +3 -3
- package/lib/components/ScatterChart/ScatterChart.js.map +1 -1
- package/lib/components/ScatterChart/ScatterChart.types.js.map +1 -1
- package/lib/components/ScatterChart/index.js.map +1 -1
- package/lib/components/ScatterChart/useScatterChartStyles.styles.raw.js.map +1 -1
- package/lib/components/Sparkline/Sparkline.js +1 -3
- package/lib/components/Sparkline/Sparkline.js.map +1 -1
- package/lib/components/Sparkline/Sparkline.types.js.map +1 -1
- package/lib/components/Sparkline/index.js.map +1 -1
- package/lib/components/Sparkline/useSparklineStyles.styles.raw.js.map +1 -1
- package/lib/components/VegaDeclarativeChart/VegaDeclarativeChart.js.map +1 -1
- package/lib/components/VegaDeclarativeChart/VegaDeclarativeChartHooks.js.map +1 -1
- package/lib/components/VegaDeclarativeChart/VegaLiteColorAdapter.js +2 -2
- package/lib/components/VegaDeclarativeChart/VegaLiteColorAdapter.js.map +1 -1
- package/lib/components/VegaDeclarativeChart/VegaLiteExpressionEvaluator.js +1 -0
- package/lib/components/VegaDeclarativeChart/VegaLiteExpressionEvaluator.js.map +1 -1
- package/lib/components/VegaDeclarativeChart/VegaLiteSchemaAdapter.js +88 -88
- package/lib/components/VegaDeclarativeChart/VegaLiteSchemaAdapter.js.map +1 -1
- package/lib/components/VegaDeclarativeChart/VegaLiteTypes.js.map +1 -1
- package/lib/components/VegaDeclarativeChart/index.js.map +1 -1
- package/lib/components/VerticalBarChart/VerticalBarChart.js +2 -1
- package/lib/components/VerticalBarChart/VerticalBarChart.js.map +1 -1
- package/lib/components/VerticalBarChart/VerticalBarChart.types.js.map +1 -1
- package/lib/components/VerticalBarChart/index.js.map +1 -1
- package/lib/components/VerticalBarChart/useVerticalBarChartStyles.styles.raw.js.map +1 -1
- package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.js +6 -5
- package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.js.map +1 -1
- package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.types.js.map +1 -1
- package/lib/components/VerticalStackedBarChart/index.js.map +1 -1
- package/lib/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.raw.js.map +1 -1
- package/lib/types/ChartAnnotation.js.map +1 -1
- package/lib/types/DataPoint.js.map +1 -1
- package/lib/types/EventAnnotation.js.map +1 -1
- package/lib/types/LegendDataItem.js.map +1 -1
- package/lib/types/index.js.map +1 -1
- package/lib/utilities/ChartTitle.js +3 -4
- package/lib/utilities/ChartTitle.js.map +1 -1
- package/lib/utilities/Common.styles.js +1 -4
- package/lib/utilities/Common.styles.js.map +1 -1
- package/lib/utilities/Common.styles.raw.js +1 -4
- package/lib/utilities/Common.styles.raw.js.map +1 -1
- package/lib/utilities/FocusableTooltipText.js.map +1 -1
- package/lib/utilities/KeyCodes.js.map +1 -1
- package/lib/utilities/SVGTooltipText.js.map +1 -1
- package/lib/utilities/async-utils.js.map +1 -1
- package/lib/utilities/colors.js.map +1 -1
- package/lib/utilities/getWindow.js.map +1 -1
- package/lib/utilities/hooks.js.map +1 -1
- package/lib/utilities/image-export-utils.js.map +1 -1
- package/lib/utilities/index.js.map +1 -1
- package/lib/utilities/overflow-utils.js.map +1 -1
- package/lib/utilities/scatterpolar-utils.js +3 -4
- package/lib/utilities/scatterpolar-utils.js.map +1 -1
- package/lib/utilities/string.js.map +1 -1
- package/lib/utilities/test-data/specialChartNames.js +11 -0
- package/lib/utilities/test-data/specialChartNames.js.map +1 -0
- package/lib/utilities/test-data.js.map +1 -1
- package/lib/utilities/utilities.js +9 -9
- package/lib/utilities/utilities.js.map +1 -1
- package/lib/utilities/vbc-utils.js.map +1 -1
- package/lib-commonjs/components/AnnotationOnlyChart/AnnotationOnlyChart.cjs +1 -4
- package/lib-commonjs/components/AnnotationOnlyChart/AnnotationOnlyChart.cjs.map +1 -1
- package/lib-commonjs/components/AnnotationOnlyChart/AnnotationOnlyChart.types.cjs.map +1 -1
- package/lib-commonjs/components/AnnotationOnlyChart/index.cjs.map +1 -1
- package/lib-commonjs/components/AnnotationOnlyChart/useAnnotationOnlyChartStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/AreaChart/AreaChart.cjs +35 -5
- package/lib-commonjs/components/AreaChart/AreaChart.cjs.map +1 -1
- package/lib-commonjs/components/AreaChart/AreaChart.types.cjs.map +1 -1
- package/lib-commonjs/components/AreaChart/index.cjs.map +1 -1
- package/lib-commonjs/components/AreaChart/useAreaChartStyles.styles.cjs +3 -3
- package/lib-commonjs/components/AreaChart/useAreaChartStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/AreaChart/useAreaChartStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/AreaChart/useAreaChartStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/ChartTable/ChartTable.cjs.map +1 -1
- package/lib-commonjs/components/ChartTable/ChartTable.types.cjs.map +1 -1
- package/lib-commonjs/components/ChartTable/index.cjs.map +1 -1
- package/lib-commonjs/components/ChartTable/useChartTableStyles.styles.cjs +3 -3
- package/lib-commonjs/components/ChartTable/useChartTableStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/ChartTable/useChartTableStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/ChartTable/useChartTableStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.cjs +19 -29
- package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.cjs.map +1 -1
- package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.types.cjs.map +1 -1
- package/lib-commonjs/components/CommonComponents/Annotations/index.cjs.map +1 -1
- package/lib-commonjs/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.cjs +14 -14
- package/lib-commonjs/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.cjs.map +1 -1
- package/lib-commonjs/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.raw.cjs +14 -14
- package/lib-commonjs/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/CommonComponents/CartesianChart.cjs +17 -15
- package/lib-commonjs/components/CommonComponents/CartesianChart.cjs.map +1 -1
- package/lib-commonjs/components/CommonComponents/CartesianChart.types.cjs.map +1 -1
- package/lib-commonjs/components/CommonComponents/ChartPopover.cjs +3 -2
- package/lib-commonjs/components/CommonComponents/ChartPopover.cjs.map +1 -1
- package/lib-commonjs/components/CommonComponents/ChartPopover.types.cjs.map +1 -1
- package/lib-commonjs/components/CommonComponents/index.cjs.map +1 -1
- package/lib-commonjs/components/CommonComponents/useCartesianChartStyles.styles.cjs +3 -3
- package/lib-commonjs/components/CommonComponents/useCartesianChartStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/CommonComponents/useCartesianChartStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/CommonComponents/useCartesianChartStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/CommonComponents/useChartPopoverStyles.styles.cjs +3 -3
- package/lib-commonjs/components/CommonComponents/useChartPopoverStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/CommonComponents/useChartPopoverStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/CommonComponents/useChartPopoverStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/DeclarativeChart/DeclarativeChart.cjs +9 -9
- package/lib-commonjs/components/DeclarativeChart/DeclarativeChart.cjs.map +1 -1
- package/lib-commonjs/components/DeclarativeChart/PlotlyColorAdapter.cjs +13 -13
- package/lib-commonjs/components/DeclarativeChart/PlotlyColorAdapter.cjs.map +1 -1
- package/lib-commonjs/components/DeclarativeChart/PlotlySchemaAdapter.cjs +122 -140
- package/lib-commonjs/components/DeclarativeChart/PlotlySchemaAdapter.cjs.map +1 -1
- package/lib-commonjs/components/DeclarativeChart/index.cjs.map +1 -1
- package/lib-commonjs/components/DonutChart/Arc/Arc.cjs.map +1 -1
- package/lib-commonjs/components/DonutChart/Arc/Arc.types.cjs.map +1 -1
- package/lib-commonjs/components/DonutChart/Arc/index.cjs.map +1 -1
- package/lib-commonjs/components/DonutChart/Arc/useArcStyles.styles.cjs +3 -3
- package/lib-commonjs/components/DonutChart/Arc/useArcStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/DonutChart/Arc/useArcStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/DonutChart/Arc/useArcStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/DonutChart/DonutChart.cjs.map +1 -1
- package/lib-commonjs/components/DonutChart/DonutChart.types.cjs.map +1 -1
- package/lib-commonjs/components/DonutChart/Pie/Pie.cjs.map +1 -1
- package/lib-commonjs/components/DonutChart/Pie/Pie.types.cjs.map +1 -1
- package/lib-commonjs/components/DonutChart/Pie/index.cjs.map +1 -1
- package/lib-commonjs/components/DonutChart/Pie/usePieStyles.styles.cjs +3 -3
- package/lib-commonjs/components/DonutChart/Pie/usePieStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/DonutChart/Pie/usePieStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/DonutChart/Pie/usePieStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/DonutChart/index.cjs.map +1 -1
- package/lib-commonjs/components/DonutChart/useDonutChartStyles.styles.cjs +3 -3
- package/lib-commonjs/components/DonutChart/useDonutChartStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/DonutChart/useDonutChartStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/DonutChart/useDonutChartStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/FunnelChart/FunnelChart.cjs +5 -5
- package/lib-commonjs/components/FunnelChart/FunnelChart.cjs.map +1 -1
- package/lib-commonjs/components/FunnelChart/FunnelChart.types.cjs.map +1 -1
- package/lib-commonjs/components/FunnelChart/funnelGeometry.cjs +6 -6
- package/lib-commonjs/components/FunnelChart/funnelGeometry.cjs.map +1 -1
- package/lib-commonjs/components/FunnelChart/index.cjs.map +1 -1
- package/lib-commonjs/components/FunnelChart/useFunnelChartStyles.styles.cjs +3 -3
- package/lib-commonjs/components/FunnelChart/useFunnelChartStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/FunnelChart/useFunnelChartStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/FunnelChart/useFunnelChartStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/GanttChart/GanttChart.cjs +4 -3
- package/lib-commonjs/components/GanttChart/GanttChart.cjs.map +1 -1
- package/lib-commonjs/components/GanttChart/GanttChart.types.cjs.map +1 -1
- package/lib-commonjs/components/GanttChart/index.cjs.map +1 -1
- package/lib-commonjs/components/GanttChart/useGanttChartStyles.styles.cjs +3 -3
- package/lib-commonjs/components/GanttChart/useGanttChartStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/GanttChart/useGanttChartStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/GanttChart/useGanttChartStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/GaugeChart/GaugeChart.cjs +41 -20
- package/lib-commonjs/components/GaugeChart/GaugeChart.cjs.map +1 -1
- package/lib-commonjs/components/GaugeChart/GaugeChart.types.cjs.map +1 -1
- package/lib-commonjs/components/GaugeChart/index.cjs.map +1 -1
- package/lib-commonjs/components/GaugeChart/useGaugeChartStyles.styles.cjs +3 -3
- package/lib-commonjs/components/GaugeChart/useGaugeChartStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/GaugeChart/useGaugeChartStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/GaugeChart/useGaugeChartStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.cjs +44 -44
- package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.cjs.map +1 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.types.cjs.map +1 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/index.cjs.map +1 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.cjs +3 -3
- package/lib-commonjs/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/HeatMapChart/HeatMapChart.cjs +1 -0
- package/lib-commonjs/components/HeatMapChart/HeatMapChart.cjs.map +1 -1
- package/lib-commonjs/components/HeatMapChart/HeatMapChart.types.cjs.map +1 -1
- package/lib-commonjs/components/HeatMapChart/index.cjs.map +1 -1
- package/lib-commonjs/components/HeatMapChart/useHeatMapChartStyles.styles.cjs +3 -3
- package/lib-commonjs/components/HeatMapChart/useHeatMapChartStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/HeatMapChart/useHeatMapChartStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/HeatMapChart/useHeatMapChartStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.cjs +5 -6
- package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.cjs.map +1 -1
- package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.types.cjs.map +1 -1
- package/lib-commonjs/components/HorizontalBarChart/index.cjs.map +1 -1
- package/lib-commonjs/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.cjs +3 -3
- package/lib-commonjs/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.cjs +4 -4
- package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.cjs.map +1 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.cjs.map +1 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/index.cjs.map +1 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.cjs +3 -3
- package/lib-commonjs/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/Legends/Legends.cjs +16 -19
- package/lib-commonjs/components/Legends/Legends.cjs.map +1 -1
- package/lib-commonjs/components/Legends/Legends.types.cjs.map +1 -1
- package/lib-commonjs/components/Legends/OverflowMenu.cjs +12 -9
- package/lib-commonjs/components/Legends/OverflowMenu.cjs.map +1 -1
- package/lib-commonjs/components/Legends/index.cjs.map +1 -1
- package/lib-commonjs/components/Legends/shape.cjs.map +1 -1
- package/lib-commonjs/components/Legends/useLegendsStyles.styles.cjs +11 -11
- package/lib-commonjs/components/Legends/useLegendsStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/Legends/useLegendsStyles.styles.raw.cjs +11 -11
- package/lib-commonjs/components/Legends/useLegendsStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/LineChart/LineChart.cjs +40 -36
- package/lib-commonjs/components/LineChart/LineChart.cjs.map +1 -1
- package/lib-commonjs/components/LineChart/LineChart.types.cjs.map +1 -1
- package/lib-commonjs/components/LineChart/eventAnnotation/EventAnnotation.cjs.map +1 -1
- package/lib-commonjs/components/LineChart/eventAnnotation/LabelLink.cjs.map +1 -1
- package/lib-commonjs/components/LineChart/eventAnnotation/Textbox.cjs.map +1 -1
- package/lib-commonjs/components/LineChart/index.cjs.map +1 -1
- package/lib-commonjs/components/LineChart/useLineChartStyles.styles.cjs +3 -3
- package/lib-commonjs/components/LineChart/useLineChartStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/LineChart/useLineChartStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/LineChart/useLineChartStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/PolarChart/PolarChart.cjs +3 -4
- package/lib-commonjs/components/PolarChart/PolarChart.cjs.map +1 -1
- package/lib-commonjs/components/PolarChart/PolarChart.types.cjs.map +1 -1
- package/lib-commonjs/components/PolarChart/PolarChart.utils.cjs +10 -10
- package/lib-commonjs/components/PolarChart/PolarChart.utils.cjs.map +1 -1
- package/lib-commonjs/components/PolarChart/index.cjs.map +1 -1
- package/lib-commonjs/components/PolarChart/usePolarChartStyles.styles.cjs +3 -3
- package/lib-commonjs/components/PolarChart/usePolarChartStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/PolarChart/usePolarChartStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/PolarChart/usePolarChartStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/ResponsiveContainer/ResponsiveContainer.cjs +1 -1
- package/lib-commonjs/components/ResponsiveContainer/ResponsiveContainer.cjs.map +1 -1
- package/lib-commonjs/components/ResponsiveContainer/ResponsiveContainer.types.cjs.map +1 -1
- package/lib-commonjs/components/ResponsiveContainer/index.cjs.map +1 -1
- package/lib-commonjs/components/ResponsiveContainer/useResponsiveChildStyles.styles.cjs +3 -3
- package/lib-commonjs/components/ResponsiveContainer/useResponsiveChildStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/ResponsiveContainer/useResponsiveChildStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/ResponsiveContainer/useResponsiveChildStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/ResponsiveContainer/withResponsiveContainer.cjs.map +1 -1
- package/lib-commonjs/components/SankeyChart/SankeyChart.cjs +5 -5
- package/lib-commonjs/components/SankeyChart/SankeyChart.cjs.map +1 -1
- package/lib-commonjs/components/SankeyChart/SankeyChart.types.cjs.map +1 -1
- package/lib-commonjs/components/SankeyChart/index.cjs.map +1 -1
- package/lib-commonjs/components/SankeyChart/useSankeyChartStyles.styles.cjs +3 -3
- package/lib-commonjs/components/SankeyChart/useSankeyChartStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/SankeyChart/useSankeyChartStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/SankeyChart/useSankeyChartStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/ScatterChart/ScatterChart.cjs +3 -3
- package/lib-commonjs/components/ScatterChart/ScatterChart.cjs.map +1 -1
- package/lib-commonjs/components/ScatterChart/ScatterChart.types.cjs.map +1 -1
- package/lib-commonjs/components/ScatterChart/index.cjs.map +1 -1
- package/lib-commonjs/components/ScatterChart/useScatterChartStyles.styles.cjs +3 -3
- package/lib-commonjs/components/ScatterChart/useScatterChartStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/ScatterChart/useScatterChartStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/ScatterChart/useScatterChartStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/Sparkline/Sparkline.cjs +1 -3
- package/lib-commonjs/components/Sparkline/Sparkline.cjs.map +1 -1
- package/lib-commonjs/components/Sparkline/Sparkline.types.cjs.map +1 -1
- package/lib-commonjs/components/Sparkline/index.cjs.map +1 -1
- package/lib-commonjs/components/Sparkline/useSparklineStyles.styles.cjs +3 -3
- package/lib-commonjs/components/Sparkline/useSparklineStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/Sparkline/useSparklineStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/Sparkline/useSparklineStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/VegaDeclarativeChart/VegaDeclarativeChart.cjs.map +1 -1
- package/lib-commonjs/components/VegaDeclarativeChart/VegaDeclarativeChartHooks.cjs +3 -3
- package/lib-commonjs/components/VegaDeclarativeChart/VegaDeclarativeChartHooks.cjs.map +1 -1
- package/lib-commonjs/components/VegaDeclarativeChart/VegaLiteColorAdapter.cjs +7 -7
- package/lib-commonjs/components/VegaDeclarativeChart/VegaLiteColorAdapter.cjs.map +1 -1
- package/lib-commonjs/components/VegaDeclarativeChart/VegaLiteExpressionEvaluator.cjs +1 -0
- package/lib-commonjs/components/VegaDeclarativeChart/VegaLiteExpressionEvaluator.cjs.map +1 -1
- package/lib-commonjs/components/VegaDeclarativeChart/VegaLiteSchemaAdapter.cjs +105 -105
- package/lib-commonjs/components/VegaDeclarativeChart/VegaLiteSchemaAdapter.cjs.map +1 -1
- package/lib-commonjs/components/VegaDeclarativeChart/VegaLiteTypes.cjs.map +1 -1
- package/lib-commonjs/components/VegaDeclarativeChart/index.cjs.map +1 -1
- package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.cjs +2 -1
- package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.cjs.map +1 -1
- package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.types.cjs.map +1 -1
- package/lib-commonjs/components/VerticalBarChart/index.cjs.map +1 -1
- package/lib-commonjs/components/VerticalBarChart/useVerticalBarChartStyles.styles.cjs +3 -3
- package/lib-commonjs/components/VerticalBarChart/useVerticalBarChartStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/VerticalBarChart/useVerticalBarChartStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/VerticalBarChart/useVerticalBarChartStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.cjs +6 -5
- package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.cjs.map +1 -1
- package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.types.cjs.map +1 -1
- package/lib-commonjs/components/VerticalStackedBarChart/index.cjs.map +1 -1
- package/lib-commonjs/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.cjs +3 -3
- package/lib-commonjs/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/types/ChartAnnotation.cjs.map +1 -1
- package/lib-commonjs/types/DataPoint.cjs.map +1 -1
- package/lib-commonjs/types/EventAnnotation.cjs.map +1 -1
- package/lib-commonjs/types/LegendDataItem.cjs.map +1 -1
- package/lib-commonjs/types/index.cjs.map +1 -1
- package/lib-commonjs/utilities/ChartTitle.cjs +3 -4
- package/lib-commonjs/utilities/ChartTitle.cjs.map +1 -1
- package/lib-commonjs/utilities/Common.styles.cjs +9 -12
- package/lib-commonjs/utilities/Common.styles.cjs.map +1 -1
- package/lib-commonjs/utilities/Common.styles.raw.cjs +9 -12
- package/lib-commonjs/utilities/Common.styles.raw.cjs.map +1 -1
- package/lib-commonjs/utilities/FocusableTooltipText.cjs.map +1 -1
- package/lib-commonjs/utilities/KeyCodes.cjs.map +1 -1
- package/lib-commonjs/utilities/SVGTooltipText.cjs.map +1 -1
- package/lib-commonjs/utilities/async-utils.cjs.map +1 -1
- package/lib-commonjs/utilities/colors.cjs +7 -7
- package/lib-commonjs/utilities/colors.cjs.map +1 -1
- package/lib-commonjs/utilities/getWindow.cjs.map +1 -1
- package/lib-commonjs/utilities/hooks.cjs.map +1 -1
- package/lib-commonjs/utilities/image-export-utils.cjs +3 -3
- package/lib-commonjs/utilities/image-export-utils.cjs.map +1 -1
- package/lib-commonjs/utilities/index.cjs.map +1 -1
- package/lib-commonjs/utilities/overflow-utils.cjs +4 -4
- package/lib-commonjs/utilities/overflow-utils.cjs.map +1 -1
- package/lib-commonjs/utilities/scatterpolar-utils.cjs +6 -7
- package/lib-commonjs/utilities/scatterpolar-utils.cjs.map +1 -1
- package/lib-commonjs/utilities/string.cjs +1 -1
- package/lib-commonjs/utilities/string.cjs.map +1 -1
- package/lib-commonjs/utilities/test-data/specialChartNames.cjs +21 -0
- package/lib-commonjs/utilities/test-data/specialChartNames.cjs.map +1 -0
- package/lib-commonjs/utilities/test-data.cjs +18 -18
- package/lib-commonjs/utilities/test-data.cjs.map +1 -1
- package/lib-commonjs/utilities/utilities.cjs +92 -92
- package/lib-commonjs/utilities/utilities.cjs.map +1 -1
- package/lib-commonjs/utilities/vbc-utils.cjs +7 -7
- package/lib-commonjs/utilities/vbc-utils.cjs.map +1 -1
- package/package.json +9 -9
|
@@ -15,6 +15,7 @@ const X1_INNER_PADDING = 0.1;
|
|
|
15
15
|
const VERTICAL_BAR_GAP = 1;
|
|
16
16
|
const MIN_BAR_HEIGHT = 1;
|
|
17
17
|
export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, forwardedRef)=>{
|
|
18
|
+
var _ref;
|
|
18
19
|
var _props_legendProps, _props_legendProps1, _barData_, _lineData__data_, _lineData_;
|
|
19
20
|
const props = {
|
|
20
21
|
xAxisCategoryOrder: 'default',
|
|
@@ -41,7 +42,7 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
41
42
|
let _xAxisOuterPadding = 0;
|
|
42
43
|
let _barLegends = [];
|
|
43
44
|
let _lineLegends = [];
|
|
44
|
-
let _legendColorMap =
|
|
45
|
+
let _legendColorMap = Object.create(null);
|
|
45
46
|
const { cartesianChartRef, legendsRef: _legendsRef } = useImageExport(props.componentRef, props.hideLegend);
|
|
46
47
|
const Y_ORIGIN = 0;
|
|
47
48
|
const _rectRef = React.useRef(null);
|
|
@@ -78,7 +79,6 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
78
79
|
_xAxisOuterPadding = getScalePadding(props.xAxisOuterPadding);
|
|
79
80
|
};
|
|
80
81
|
const _createDataset = (barData, lineData)=>{
|
|
81
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
82
82
|
const datasetForBars = [];
|
|
83
83
|
const linePointsByX = Object.create(null);
|
|
84
84
|
const visitedX = new Set();
|
|
@@ -97,12 +97,12 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
97
97
|
});
|
|
98
98
|
});
|
|
99
99
|
barData.forEach((point, index)=>{
|
|
100
|
-
|
|
101
|
-
const
|
|
100
|
+
var _linePointsByX_point_name;
|
|
101
|
+
const barPointsByLegend = Object.create(null);
|
|
102
102
|
const legendToBarPoint = Object.create(null);
|
|
103
103
|
point.series.forEach((seriesPoint)=>{
|
|
104
|
-
if (!
|
|
105
|
-
|
|
104
|
+
if (!barPointsByLegend[seriesPoint.legend]) {
|
|
105
|
+
barPointsByLegend[seriesPoint.legend] = [
|
|
106
106
|
{
|
|
107
107
|
...seriesPoint
|
|
108
108
|
}
|
|
@@ -111,27 +111,30 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
111
111
|
...seriesPoint
|
|
112
112
|
};
|
|
113
113
|
} else {
|
|
114
|
-
|
|
114
|
+
barPointsByLegend[seriesPoint.legend].push({
|
|
115
115
|
...seriesPoint
|
|
116
116
|
});
|
|
117
117
|
legendToBarPoint[seriesPoint.legend].data += seriesPoint.data;
|
|
118
118
|
}
|
|
119
119
|
});
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
120
|
+
datasetForBars.push({
|
|
121
|
+
barPointsByLegend,
|
|
122
|
+
xAxisPoint: point.name,
|
|
123
|
+
indexNum: index,
|
|
124
|
+
groupSeries: [
|
|
125
|
+
...Object.values(legendToBarPoint),
|
|
126
|
+
...(_linePointsByX_point_name = linePointsByX[point.name]) !== null && _linePointsByX_point_name !== void 0 ? _linePointsByX_point_name : []
|
|
127
|
+
],
|
|
128
|
+
stackCallOutAccessibilityData: point.stackCallOutAccessibilityData
|
|
129
|
+
});
|
|
129
130
|
visitedX.add(point.name);
|
|
130
131
|
});
|
|
131
132
|
Object.keys(linePointsByX).forEach((xPoint)=>{
|
|
132
133
|
if (!visitedX.has(xPoint)) {
|
|
133
134
|
datasetForBars.push({
|
|
135
|
+
barPointsByLegend: Object.create(null),
|
|
134
136
|
xAxisPoint: xPoint,
|
|
137
|
+
indexNum: datasetForBars.length,
|
|
135
138
|
groupSeries: linePointsByX[xPoint]
|
|
136
139
|
});
|
|
137
140
|
}
|
|
@@ -195,18 +198,18 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
195
198
|
});
|
|
196
199
|
};
|
|
197
200
|
const _processDataV2 = (dataV2)=>{
|
|
198
|
-
const barPointsByX =
|
|
201
|
+
const barPointsByX = Object.create(null);
|
|
199
202
|
const lineData = [];
|
|
200
203
|
dataV2.forEach((series)=>{
|
|
201
204
|
if (series.type === 'bar') {
|
|
202
205
|
series.data.forEach((point)=>{
|
|
206
|
+
var _series_key, _point_color;
|
|
203
207
|
if (!barPointsByX[point.x]) {
|
|
204
208
|
barPointsByX[point.x] = {
|
|
205
209
|
name: point.x,
|
|
206
210
|
series: []
|
|
207
211
|
};
|
|
208
212
|
}
|
|
209
|
-
var _series_key, _point_color;
|
|
210
213
|
barPointsByX[point.x].series.push({
|
|
211
214
|
key: (_series_key = series.key) !== null && _series_key !== void 0 ? _series_key : series.legend,
|
|
212
215
|
data: point.y,
|
|
@@ -229,21 +232,22 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
229
232
|
};
|
|
230
233
|
};
|
|
231
234
|
const _prepareChartData = ()=>{
|
|
235
|
+
var _ref, _ref1;
|
|
232
236
|
let barData = props.data;
|
|
233
237
|
let lineData;
|
|
234
238
|
if (Array.isArray(props.dataV2) && props.dataV2.length > 0) {
|
|
235
239
|
({ barData, lineData } = _processDataV2(props.dataV2));
|
|
236
240
|
}
|
|
237
|
-
_legendColorMap =
|
|
241
|
+
_legendColorMap = Object.create(null);
|
|
238
242
|
let colorIndex = 0;
|
|
239
|
-
var _barData_map, _lineData_map;
|
|
240
243
|
return {
|
|
241
|
-
barData: (
|
|
244
|
+
barData: (_ref = barData === null || barData === void 0 ? void 0 : barData.map((point)=>{
|
|
245
|
+
var _ref;
|
|
242
246
|
var _point_series;
|
|
243
|
-
var _point_series_map;
|
|
244
247
|
return {
|
|
245
248
|
...point,
|
|
246
|
-
series: (
|
|
249
|
+
series: (_ref = (_point_series = point.series) === null || _point_series === void 0 ? void 0 : _point_series.map((seriesPoint)=>{
|
|
250
|
+
var _seriesPoint_color;
|
|
247
251
|
// TODO: Add support for gradient colors
|
|
248
252
|
const startColor = seriesPoint.color ? seriesPoint.color : getNextColor(colorIndex, 0);
|
|
249
253
|
const endColor = startColor;
|
|
@@ -254,15 +258,14 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
254
258
|
];
|
|
255
259
|
}
|
|
256
260
|
colorIndex += 1;
|
|
257
|
-
var _seriesPoint_color;
|
|
258
261
|
return {
|
|
259
262
|
...seriesPoint,
|
|
260
263
|
color: (_seriesPoint_color = seriesPoint.color) !== null && _seriesPoint_color !== void 0 ? _seriesPoint_color : _legendColorMap[seriesPoint.legend][0]
|
|
261
264
|
};
|
|
262
|
-
})) !== null &&
|
|
265
|
+
})) !== null && _ref !== void 0 ? _ref : []
|
|
263
266
|
};
|
|
264
|
-
})) !== null &&
|
|
265
|
-
lineData: (
|
|
267
|
+
})) !== null && _ref !== void 0 ? _ref : [],
|
|
268
|
+
lineData: (_ref1 = lineData === null || lineData === void 0 ? void 0 : lineData.map((series)=>{
|
|
266
269
|
let lineColor;
|
|
267
270
|
if (typeof series.color === 'undefined') {
|
|
268
271
|
lineColor = getNextColor(colorIndex, 0);
|
|
@@ -280,7 +283,7 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
280
283
|
...series,
|
|
281
284
|
color: _legendColorMap[series.legend][0]
|
|
282
285
|
};
|
|
283
|
-
})) !== null &&
|
|
286
|
+
})) !== null && _ref1 !== void 0 ? _ref1 : []
|
|
284
287
|
};
|
|
285
288
|
};
|
|
286
289
|
const _getOrderedXAxisLabels = (barData, lineData)=>{
|
|
@@ -290,7 +293,7 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
290
293
|
return sortAxisCategories(_mapCategoryToValues(barData, lineData), props.xAxisCategoryOrder);
|
|
291
294
|
};
|
|
292
295
|
const _mapCategoryToValues = (barData, lineData)=>{
|
|
293
|
-
const categoryToValues =
|
|
296
|
+
const categoryToValues = Object.create(null);
|
|
294
297
|
barData.forEach((point)=>{
|
|
295
298
|
if (!categoryToValues[point.name]) {
|
|
296
299
|
categoryToValues[point.name] = [];
|
|
@@ -310,8 +313,7 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
310
313
|
return categoryToValues;
|
|
311
314
|
};
|
|
312
315
|
const { barData, lineData } = _prepareChartData();
|
|
313
|
-
|
|
314
|
-
const firstXValue = (_barData__name = (_barData_ = barData[0]) === null || _barData_ === void 0 ? void 0 : _barData_.name) !== null && _barData__name !== void 0 ? _barData__name : (_lineData_ = lineData[0]) === null || _lineData_ === void 0 ? void 0 : (_lineData__data_ = _lineData_.data[0]) === null || _lineData__data_ === void 0 ? void 0 : _lineData__data_.x;
|
|
316
|
+
const firstXValue = (_ref = (_barData_ = barData[0]) === null || _barData_ === void 0 ? void 0 : _barData_.name) !== null && _ref !== void 0 ? _ref : (_lineData_ = lineData[0]) === null || _lineData_ === void 0 ? void 0 : (_lineData__data_ = _lineData_.data[0]) === null || _lineData__data_ === void 0 ? void 0 : _lineData__data_.x;
|
|
315
317
|
const _xAxisType = isInvalidValue(firstXValue) ? XAxisTypes.StringAxis : getTypeOfAxis(firstXValue, true);
|
|
316
318
|
const { barLegends, lineLegends, xAxisLabels, datasetForBars } = _createDataSetOfGVBC(barData, lineData);
|
|
317
319
|
_barLegends = barLegends;
|
|
@@ -320,10 +322,8 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
320
322
|
_datasetForBars = datasetForBars;
|
|
321
323
|
const legendBars = _getLegendData();
|
|
322
324
|
_adjustProps();
|
|
323
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any -- Add commentMore actions
|
|
324
325
|
function _getMinMaxOfYAxis(datasetForBars, yAxisType, useSecondaryYScale) {
|
|
325
326
|
const values = [];
|
|
326
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
327
327
|
datasetForBars.forEach((data)=>{
|
|
328
328
|
data.groupSeries.forEach((point)=>{
|
|
329
329
|
if (!useSecondaryYScale === !point.useSecondaryYScale) {
|
|
@@ -409,14 +409,13 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
409
409
|
groupData)=>{
|
|
410
410
|
_showCallout(focusEvent.currentTarget, pointData, groupData);
|
|
411
411
|
};
|
|
412
|
-
const _buildGraph = (// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
413
|
-
singleSet, // eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
412
|
+
const _buildGraph = (singleSet, // eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
414
413
|
xScale0, // eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
415
414
|
xScale1, yScalePrimary, yScaleSecondary, containerHeight, xElement)=>{
|
|
416
415
|
const singleGroup = [];
|
|
417
416
|
const barLabelsForGroup = [];
|
|
418
417
|
// Get the actual legends present at this x-axis point
|
|
419
|
-
const presentLegends = _barLegends.filter((key)=>key
|
|
418
|
+
const presentLegends = _barLegends.filter((key)=>Object.prototype.hasOwnProperty.call(singleSet.barPointsByLegend, key));
|
|
420
419
|
const effectiveGroupWidth = calcRequiredWidth(_barWidth, presentLegends.length, X1_INNER_PADDING);
|
|
421
420
|
// For stacked bars, center the single bar group in the available space
|
|
422
421
|
// Instead of using the global legend position, use the local position within present legends
|
|
@@ -428,10 +427,10 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
428
427
|
effectiveGroupWidth
|
|
429
428
|
]).paddingInner(X1_INNER_PADDING);
|
|
430
429
|
_barLegends.forEach((legendTitle, legendIndex)=>{
|
|
431
|
-
const barPoints = singleSet[legendTitle];
|
|
430
|
+
const barPoints = singleSet.barPointsByLegend[legendTitle];
|
|
432
431
|
if (barPoints) {
|
|
433
|
-
const yBarScale = barPoints[0].useSecondaryYScale && yScaleSecondary ? yScaleSecondary : yScalePrimary;
|
|
434
432
|
var _localScale;
|
|
433
|
+
const yBarScale = barPoints[0].useSecondaryYScale && yScaleSecondary ? yScaleSecondary : yScalePrimary;
|
|
435
434
|
const xPoint = ((_localScale = localScale(legendTitle)) !== null && _localScale !== void 0 ? _localScale : 0) + (localScale.bandwidth() - _barWidth) / 2;
|
|
436
435
|
const isLegendActive = _legendHighlighted(legendTitle) || _noLegendHighlighted();
|
|
437
436
|
const barOpacity = isLegendActive ? '' : '0.1';
|
|
@@ -644,12 +643,13 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
644
643
|
const x2 = scaleLineX(point.x);
|
|
645
644
|
const y2 = yScale(point.y);
|
|
646
645
|
if (pointIdx > 0) {
|
|
646
|
+
var _ref, _ref1;
|
|
647
647
|
var _series_lineOptions, _series_lineOptions1, _series_lineOptions2;
|
|
648
648
|
const x1 = scaleLineX(series.data[pointIdx - 1].x);
|
|
649
649
|
const y1 = yScale(series.data[pointIdx - 1].y);
|
|
650
650
|
if (lineBorderWidth > 0) {
|
|
651
|
+
var _ref2;
|
|
651
652
|
var _series_lineOptions3;
|
|
652
|
-
var _series_lineOptions_lineBorderColor;
|
|
653
653
|
lineBorderGroup.push(/*#__PURE__*/ React.createElement("line", {
|
|
654
654
|
key: `lineBorder-${seriesIdx}-${pointIdx}`,
|
|
655
655
|
x1: x1,
|
|
@@ -657,13 +657,12 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
657
657
|
x2: x2,
|
|
658
658
|
y2: y2,
|
|
659
659
|
fill: "transparent",
|
|
660
|
-
stroke: (
|
|
660
|
+
stroke: (_ref2 = (_series_lineOptions3 = series.lineOptions) === null || _series_lineOptions3 === void 0 ? void 0 : _series_lineOptions3.lineBorderColor) !== null && _ref2 !== void 0 ? _ref2 : tokens.colorNeutralBackground1,
|
|
661
661
|
strokeWidth: 3 + lineBorderWidth * 2,
|
|
662
662
|
strokeLinecap: "round",
|
|
663
663
|
opacity: shouldHighlight ? 1 : 0.1
|
|
664
664
|
}));
|
|
665
665
|
}
|
|
666
|
-
var _series_lineOptions_strokeWidth, _series_lineOptions_strokeLinecap;
|
|
667
666
|
lineGroup.push(/*#__PURE__*/ React.createElement("line", {
|
|
668
667
|
key: `line-${seriesIdx}-${pointIdx}`,
|
|
669
668
|
x1: x1,
|
|
@@ -671,8 +670,8 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
671
670
|
x2: x2,
|
|
672
671
|
y2: y2,
|
|
673
672
|
stroke: series.color,
|
|
674
|
-
strokeWidth: (
|
|
675
|
-
strokeLinecap: (
|
|
673
|
+
strokeWidth: (_ref = (_series_lineOptions = series.lineOptions) === null || _series_lineOptions === void 0 ? void 0 : _series_lineOptions.strokeWidth) !== null && _ref !== void 0 ? _ref : 3,
|
|
674
|
+
strokeLinecap: (_ref1 = (_series_lineOptions1 = series.lineOptions) === null || _series_lineOptions1 === void 0 ? void 0 : _series_lineOptions1.strokeLinecap) !== null && _ref1 !== void 0 ? _ref1 : 'round',
|
|
676
675
|
strokeDasharray: (_series_lineOptions2 = series.lineOptions) === null || _series_lineOptions2 === void 0 ? void 0 : _series_lineOptions2.strokeDasharray,
|
|
677
676
|
opacity: shouldHighlight ? 1 : 0.1,
|
|
678
677
|
onMouseOver: (e)=>_onLineHover(e, series, seriesIdx, pointIdx, scaleLineX),
|
|
@@ -752,17 +751,16 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
752
751
|
};
|
|
753
752
|
const _showCallout = (target, pointData, // eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
754
753
|
groupData, _activeLinePoint = '')=>{
|
|
754
|
+
var _pointData_xAxisCalloutData, _pointData_xAxisCalloutData1;
|
|
755
755
|
setPopoverTarget(target);
|
|
756
756
|
setPopoverOpen(_noLegendHighlighted() || _legendHighlighted(pointData.legend));
|
|
757
757
|
setCalloutLegend(pointData.legend);
|
|
758
758
|
setDataForHoverCard(pointData.data);
|
|
759
759
|
setColor(pointData.color);
|
|
760
|
-
var _pointData_xAxisCalloutData;
|
|
761
760
|
setXCalloutValue((_pointData_xAxisCalloutData = pointData.xAxisCalloutData) !== null && _pointData_xAxisCalloutData !== void 0 ? _pointData_xAxisCalloutData : groupData.xAxisPoint);
|
|
762
761
|
setYCalloutValue(pointData.yAxisCalloutData);
|
|
763
762
|
setCallOutAccessibilityData(props.isCalloutForStack ? groupData.stackCallOutAccessibilityData : pointData.callOutAccessibilityData);
|
|
764
763
|
setYValueHover(groupData.groupSeries.filter((item)=>_noLegendHighlighted() || _legendHighlighted(item.legend)));
|
|
765
|
-
var _pointData_xAxisCalloutData1;
|
|
766
764
|
setHoverXValue((_pointData_xAxisCalloutData1 = pointData.xAxisCalloutData) !== null && _pointData_xAxisCalloutData1 !== void 0 ? _pointData_xAxisCalloutData1 : groupData.xAxisPoint);
|
|
767
765
|
setActiveLinePoint(props.isCalloutForStack ? groupData.xAxisPoint : _activeLinePoint);
|
|
768
766
|
};
|
|
@@ -775,7 +773,7 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
775
773
|
points: _datasetForBars,
|
|
776
774
|
chartType: ChartTypes.GroupedVerticalBarChart,
|
|
777
775
|
getDomainNRangeValues: _getDomainNRangeValues,
|
|
778
|
-
getMinMaxOfYAxis: _getMinMaxOfYAxis,
|
|
776
|
+
getMinMaxOfYAxis: (_points, yAxisType, useSecondaryYScale)=>_getMinMaxOfYAxis(_datasetForBars, yAxisType, useSecondaryYScale),
|
|
779
777
|
createStringYAxis: createStringYAxis,
|
|
780
778
|
calloutProps: calloutProps,
|
|
781
779
|
legendBars: legendBars,
|
|
@@ -789,6 +787,7 @@ export const GroupedVerticalBarChart = /*#__PURE__*/ React.forwardRef((_props, f
|
|
|
789
787
|
getGraphData: _getGraphData,
|
|
790
788
|
getAxisData: _getAxisData,
|
|
791
789
|
onChartMouseLeave: _handleChartMouseLeave,
|
|
790
|
+
onChartBlur: _handleChartMouseLeave,
|
|
792
791
|
getDomainMargins: _getDomainMargins,
|
|
793
792
|
..._xAxisType === XAxisTypes.StringAxis && {
|
|
794
793
|
xAxisInnerPadding: _xAxisInnerPadding,
|