@fluentui/react-charts 9.3.21 → 9.74.3-experimental.esm.20260709-49ee7a20cf.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/CHANGELOG.md +20 -2
- package/package.json +15 -17
- package/dist/index.d.ts +0 -5724
- package/lib/AnnotationOnlyChart.js +0 -1
- package/lib/AnnotationOnlyChart.js.map +0 -1
- package/lib/AreaChart.js +0 -1
- package/lib/AreaChart.js.map +0 -1
- package/lib/CartesianChart.js +0 -1
- package/lib/CartesianChart.js.map +0 -1
- package/lib/ChartTable.js +0 -1
- package/lib/ChartTable.js.map +0 -1
- package/lib/DeclarativeChart.js +0 -1
- package/lib/DeclarativeChart.js.map +0 -1
- package/lib/DonutChart.js +0 -1
- package/lib/DonutChart.js.map +0 -1
- package/lib/FunnelChart.js +0 -1
- package/lib/FunnelChart.js.map +0 -1
- package/lib/GanttChart.js +0 -1
- package/lib/GanttChart.js.map +0 -1
- package/lib/GaugeChart.js +0 -1
- package/lib/GaugeChart.js.map +0 -1
- package/lib/GroupedVerticalBarChart.js +0 -1
- package/lib/GroupedVerticalBarChart.js.map +0 -1
- package/lib/HeatMapChart.js +0 -1
- package/lib/HeatMapChart.js.map +0 -1
- package/lib/HorizontalBarChart.js +0 -1
- package/lib/HorizontalBarChart.js.map +0 -1
- package/lib/HorizontalBarChartWithAxis.js +0 -1
- package/lib/HorizontalBarChartWithAxis.js.map +0 -1
- package/lib/Legends.js +0 -1
- package/lib/Legends.js.map +0 -1
- package/lib/LineChart.js +0 -1
- package/lib/LineChart.js.map +0 -1
- package/lib/PolarChart.js +0 -1
- package/lib/PolarChart.js.map +0 -1
- package/lib/Popover.js +0 -1
- package/lib/Popover.js.map +0 -1
- package/lib/ResponsiveContainer.js +0 -1
- package/lib/ResponsiveContainer.js.map +0 -1
- package/lib/SankeyChart.js +0 -1
- package/lib/SankeyChart.js.map +0 -1
- package/lib/ScatterChart.js +0 -1
- package/lib/ScatterChart.js.map +0 -1
- package/lib/Sparkline.js +0 -1
- package/lib/Sparkline.js.map +0 -1
- package/lib/VegaDeclarativeChart.js +0 -1
- package/lib/VegaDeclarativeChart.js.map +0 -1
- package/lib/VerticalBarChart.js +0 -1
- package/lib/VerticalBarChart.js.map +0 -1
- package/lib/VerticalStackedBarChart.js +0 -1
- package/lib/VerticalStackedBarChart.js.map +0 -1
- package/lib/components/AnnotationOnlyChart/AnnotationOnlyChart.js +0 -196
- package/lib/components/AnnotationOnlyChart/AnnotationOnlyChart.js.map +0 -1
- package/lib/components/AnnotationOnlyChart/AnnotationOnlyChart.types.js +0 -3
- package/lib/components/AnnotationOnlyChart/AnnotationOnlyChart.types.js.map +0 -1
- package/lib/components/AnnotationOnlyChart/index.js +0 -2
- package/lib/components/AnnotationOnlyChart/index.js.map +0 -1
- package/lib/components/AnnotationOnlyChart/useAnnotationOnlyChartStyles.styles.js +0 -33
- package/lib/components/AnnotationOnlyChart/useAnnotationOnlyChartStyles.styles.js.map +0 -1
- package/lib/components/AnnotationOnlyChart/useAnnotationOnlyChartStyles.styles.raw.js +0 -24
- package/lib/components/AnnotationOnlyChart/useAnnotationOnlyChartStyles.styles.raw.js.map +0 -1
- package/lib/components/AreaChart/AreaChart.js +0 -932
- package/lib/components/AreaChart/AreaChart.js.map +0 -1
- package/lib/components/AreaChart/AreaChart.types.js +0 -4
- package/lib/components/AreaChart/AreaChart.types.js.map +0 -1
- package/lib/components/AreaChart/index.js +0 -3
- package/lib/components/AreaChart/index.js.map +0 -1
- package/lib/components/AreaChart/useAreaChartStyles.styles.js +0 -63
- package/lib/components/AreaChart/useAreaChartStyles.styles.js.map +0 -1
- package/lib/components/AreaChart/useAreaChartStyles.styles.raw.js +0 -33
- package/lib/components/AreaChart/useAreaChartStyles.styles.raw.js.map +0 -1
- package/lib/components/ChartTable/ChartTable.js +0 -160
- package/lib/components/ChartTable/ChartTable.js.map +0 -1
- package/lib/components/ChartTable/ChartTable.types.js +0 -4
- package/lib/components/ChartTable/ChartTable.types.js.map +0 -1
- package/lib/components/ChartTable/index.js +0 -3
- package/lib/components/ChartTable/index.js.map +0 -1
- package/lib/components/ChartTable/useChartTableStyles.styles.js +0 -136
- package/lib/components/ChartTable/useChartTableStyles.styles.js.map +0 -1
- package/lib/components/ChartTable/useChartTableStyles.styles.raw.js +0 -68
- package/lib/components/ChartTable/useChartTableStyles.styles.raw.js.map +0 -1
- package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.js +0 -659
- package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.js.map +0 -1
- package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.types.js +0 -1
- package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.types.js.map +0 -1
- package/lib/components/CommonComponents/Annotations/index.js +0 -2
- package/lib/components/CommonComponents/Annotations/index.js.map +0 -1
- package/lib/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.js +0 -223
- package/lib/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.js.map +0 -1
- package/lib/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.raw.js +0 -139
- package/lib/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.raw.js.map +0 -1
- package/lib/components/CommonComponents/CartesianChart.js +0 -665
- package/lib/components/CommonComponents/CartesianChart.js.map +0 -1
- package/lib/components/CommonComponents/CartesianChart.types.js +0 -2
- package/lib/components/CommonComponents/CartesianChart.types.js.map +0 -1
- package/lib/components/CommonComponents/ChartPopover.js +0 -197
- package/lib/components/CommonComponents/ChartPopover.js.map +0 -1
- package/lib/components/CommonComponents/ChartPopover.types.js +0 -1
- package/lib/components/CommonComponents/ChartPopover.types.js.map +0 -1
- package/lib/components/CommonComponents/index.js +0 -6
- package/lib/components/CommonComponents/index.js.map +0 -1
- package/lib/components/CommonComponents/useCartesianChartStyles.styles.js +0 -189
- package/lib/components/CommonComponents/useCartesianChartStyles.styles.js.map +0 -1
- package/lib/components/CommonComponents/useCartesianChartStyles.styles.raw.js +0 -131
- package/lib/components/CommonComponents/useCartesianChartStyles.styles.raw.js.map +0 -1
- package/lib/components/CommonComponents/useChartPopoverStyles.styles.js +0 -171
- package/lib/components/CommonComponents/useChartPopoverStyles.styles.js.map +0 -1
- package/lib/components/CommonComponents/useChartPopoverStyles.styles.raw.js +0 -127
- package/lib/components/CommonComponents/useChartPopoverStyles.styles.raw.js.map +0 -1
- package/lib/components/DeclarativeChart/DeclarativeChart.js +0 -397
- package/lib/components/DeclarativeChart/DeclarativeChart.js.map +0 -1
- package/lib/components/DeclarativeChart/PlotlyColorAdapter.js +0 -163
- package/lib/components/DeclarativeChart/PlotlyColorAdapter.js.map +0 -1
- package/lib/components/DeclarativeChart/PlotlySchemaAdapter.js +0 -3490
- package/lib/components/DeclarativeChart/PlotlySchemaAdapter.js.map +0 -1
- package/lib/components/DeclarativeChart/index.js +0 -1
- package/lib/components/DeclarativeChart/index.js.map +0 -1
- package/lib/components/DonutChart/Arc/Arc.js +0 -118
- package/lib/components/DonutChart/Arc/Arc.js.map +0 -1
- package/lib/components/DonutChart/Arc/Arc.types.js +0 -1
- package/lib/components/DonutChart/Arc/Arc.types.js.map +0 -1
- package/lib/components/DonutChart/Arc/index.js +0 -2
- package/lib/components/DonutChart/Arc/index.js.map +0 -1
- package/lib/components/DonutChart/Arc/useArcStyles.styles.js +0 -80
- package/lib/components/DonutChart/Arc/useArcStyles.styles.js.map +0 -1
- package/lib/components/DonutChart/Arc/useArcStyles.styles.raw.js +0 -49
- package/lib/components/DonutChart/Arc/useArcStyles.styles.raw.js.map +0 -1
- package/lib/components/DonutChart/DonutChart.js +0 -349
- package/lib/components/DonutChart/DonutChart.js.map +0 -1
- package/lib/components/DonutChart/DonutChart.types.js +0 -4
- package/lib/components/DonutChart/DonutChart.types.js.map +0 -1
- package/lib/components/DonutChart/Pie/Pie.js +0 -72
- package/lib/components/DonutChart/Pie/Pie.js.map +0 -1
- package/lib/components/DonutChart/Pie/Pie.types.js +0 -1
- package/lib/components/DonutChart/Pie/Pie.types.js.map +0 -1
- package/lib/components/DonutChart/Pie/index.js +0 -2
- package/lib/components/DonutChart/Pie/index.js.map +0 -1
- package/lib/components/DonutChart/Pie/usePieStyles.styles.js +0 -41
- package/lib/components/DonutChart/Pie/usePieStyles.styles.js.map +0 -1
- package/lib/components/DonutChart/Pie/usePieStyles.styles.raw.js +0 -30
- package/lib/components/DonutChart/Pie/usePieStyles.styles.raw.js.map +0 -1
- package/lib/components/DonutChart/index.js +0 -3
- package/lib/components/DonutChart/index.js.map +0 -1
- package/lib/components/DonutChart/useDonutChartStyles.styles.js +0 -98
- package/lib/components/DonutChart/useDonutChartStyles.styles.js.map +0 -1
- package/lib/components/DonutChart/useDonutChartStyles.styles.raw.js +0 -62
- package/lib/components/DonutChart/useDonutChartStyles.styles.raw.js.map +0 -1
- package/lib/components/FunnelChart/FunnelChart.js +0 -401
- package/lib/components/FunnelChart/FunnelChart.js.map +0 -1
- package/lib/components/FunnelChart/FunnelChart.types.js +0 -4
- package/lib/components/FunnelChart/FunnelChart.types.js.map +0 -1
- package/lib/components/FunnelChart/funnelGeometry.js +0 -219
- package/lib/components/FunnelChart/funnelGeometry.js.map +0 -1
- package/lib/components/FunnelChart/index.js +0 -2
- package/lib/components/FunnelChart/index.js.map +0 -1
- package/lib/components/FunnelChart/useFunnelChartStyles.styles.js +0 -83
- package/lib/components/FunnelChart/useFunnelChartStyles.styles.js.map +0 -1
- package/lib/components/FunnelChart/useFunnelChartStyles.styles.raw.js +0 -65
- package/lib/components/FunnelChart/useFunnelChartStyles.styles.raw.js.map +0 -1
- package/lib/components/GanttChart/GanttChart.js +0 -535
- package/lib/components/GanttChart/GanttChart.js.map +0 -1
- package/lib/components/GanttChart/GanttChart.types.js +0 -4
- package/lib/components/GanttChart/GanttChart.types.js.map +0 -1
- package/lib/components/GanttChart/index.js +0 -2
- package/lib/components/GanttChart/index.js.map +0 -1
- package/lib/components/GanttChart/useGanttChartStyles.styles.js +0 -27
- package/lib/components/GanttChart/useGanttChartStyles.styles.js.map +0 -1
- package/lib/components/GanttChart/useGanttChartStyles.styles.raw.js +0 -26
- package/lib/components/GanttChart/useGanttChartStyles.styles.raw.js.map +0 -1
- package/lib/components/GaugeChart/GaugeChart.js +0 -568
- package/lib/components/GaugeChart/GaugeChart.js.map +0 -1
- package/lib/components/GaugeChart/GaugeChart.types.js +0 -4
- package/lib/components/GaugeChart/GaugeChart.types.js.map +0 -1
- package/lib/components/GaugeChart/index.js +0 -3
- package/lib/components/GaugeChart/index.js.map +0 -1
- package/lib/components/GaugeChart/useGaugeChartStyles.styles.js +0 -197
- package/lib/components/GaugeChart/useGaugeChartStyles.styles.js.map +0 -1
- package/lib/components/GaugeChart/useGaugeChartStyles.styles.raw.js +0 -149
- package/lib/components/GaugeChart/useGaugeChartStyles.styles.raw.js.map +0 -1
- package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.js +0 -813
- package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.js.map +0 -1
- package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.types.js +0 -4
- package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.types.js.map +0 -1
- package/lib/components/GroupedVerticalBarChart/index.js +0 -3
- package/lib/components/GroupedVerticalBarChart/index.js.map +0 -1
- package/lib/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.js +0 -77
- package/lib/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.js.map +0 -1
- package/lib/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.raw.js +0 -40
- package/lib/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.raw.js.map +0 -1
- package/lib/components/HeatMapChart/HeatMapChart.js +0 -677
- package/lib/components/HeatMapChart/HeatMapChart.js.map +0 -1
- package/lib/components/HeatMapChart/HeatMapChart.types.js +0 -4
- package/lib/components/HeatMapChart/HeatMapChart.types.js.map +0 -1
- package/lib/components/HeatMapChart/index.js +0 -3
- package/lib/components/HeatMapChart/index.js.map +0 -1
- package/lib/components/HeatMapChart/useHeatMapChartStyles.styles.js +0 -48
- package/lib/components/HeatMapChart/useHeatMapChartStyles.styles.js.map +0 -1
- package/lib/components/HeatMapChart/useHeatMapChartStyles.styles.raw.js +0 -42
- package/lib/components/HeatMapChart/useHeatMapChartStyles.styles.raw.js.map +0 -1
- package/lib/components/HorizontalBarChart/HorizontalBarChart.js +0 -411
- package/lib/components/HorizontalBarChart/HorizontalBarChart.js.map +0 -1
- package/lib/components/HorizontalBarChart/HorizontalBarChart.types.js +0 -7
- package/lib/components/HorizontalBarChart/HorizontalBarChart.types.js.map +0 -1
- package/lib/components/HorizontalBarChart/index.js +0 -3
- package/lib/components/HorizontalBarChart/index.js.map +0 -1
- package/lib/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.js +0 -175
- package/lib/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.js.map +0 -1
- package/lib/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.raw.js +0 -125
- package/lib/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.raw.js.map +0 -1
- package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.js +0 -720
- package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.js.map +0 -1
- package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.js +0 -4
- package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.js.map +0 -1
- package/lib/components/HorizontalBarChartWithAxis/index.js +0 -3
- package/lib/components/HorizontalBarChartWithAxis/index.js.map +0 -1
- package/lib/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.js +0 -62
- package/lib/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.js.map +0 -1
- package/lib/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.raw.js +0 -54
- package/lib/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.raw.js.map +0 -1
- package/lib/components/Legends/Legends.js +0 -323
- package/lib/components/Legends/Legends.js.map +0 -1
- package/lib/components/Legends/Legends.types.js +0 -3
- package/lib/components/Legends/Legends.types.js.map +0 -1
- package/lib/components/Legends/OverflowMenu.js +0 -33
- package/lib/components/Legends/OverflowMenu.js.map +0 -1
- package/lib/components/Legends/index.js +0 -3
- package/lib/components/Legends/index.js.map +0 -1
- package/lib/components/Legends/shape.js +0 -36
- package/lib/components/Legends/shape.js.map +0 -1
- package/lib/components/Legends/useLegendsStyles.styles.js +0 -262
- package/lib/components/Legends/useLegendsStyles.styles.js.map +0 -1
- package/lib/components/Legends/useLegendsStyles.styles.raw.js +0 -142
- package/lib/components/Legends/useLegendsStyles.styles.raw.js.map +0 -1
- package/lib/components/LineChart/LineChart.js +0 -1332
- package/lib/components/LineChart/LineChart.js.map +0 -1
- package/lib/components/LineChart/LineChart.types.js +0 -3
- package/lib/components/LineChart/LineChart.types.js.map +0 -1
- package/lib/components/LineChart/eventAnnotation/EventAnnotation.js +0 -118
- package/lib/components/LineChart/eventAnnotation/EventAnnotation.js.map +0 -1
- package/lib/components/LineChart/eventAnnotation/LabelLink.js +0 -59
- package/lib/components/LineChart/eventAnnotation/LabelLink.js.map +0 -1
- package/lib/components/LineChart/eventAnnotation/Textbox.js +0 -42
- package/lib/components/LineChart/eventAnnotation/Textbox.js.map +0 -1
- package/lib/components/LineChart/index.js +0 -4
- package/lib/components/LineChart/index.js.map +0 -1
- package/lib/components/LineChart/useLineChartStyles.styles.js +0 -93
- package/lib/components/LineChart/useLineChartStyles.styles.js.map +0 -1
- package/lib/components/LineChart/useLineChartStyles.styles.raw.js +0 -50
- package/lib/components/LineChart/useLineChartStyles.styles.raw.js.map +0 -1
- package/lib/components/PolarChart/PolarChart.js +0 -577
- package/lib/components/PolarChart/PolarChart.js.map +0 -1
- package/lib/components/PolarChart/PolarChart.types.js +0 -4
- package/lib/components/PolarChart/PolarChart.types.js.map +0 -1
- package/lib/components/PolarChart/PolarChart.utils.js +0 -174
- package/lib/components/PolarChart/PolarChart.utils.js.map +0 -1
- package/lib/components/PolarChart/index.js +0 -2
- package/lib/components/PolarChart/index.js.map +0 -1
- package/lib/components/PolarChart/usePolarChartStyles.styles.js +0 -72
- package/lib/components/PolarChart/usePolarChartStyles.styles.js.map +0 -1
- package/lib/components/PolarChart/usePolarChartStyles.styles.raw.js +0 -61
- package/lib/components/PolarChart/usePolarChartStyles.styles.raw.js.map +0 -1
- package/lib/components/ResponsiveContainer/ResponsiveContainer.js +0 -99
- package/lib/components/ResponsiveContainer/ResponsiveContainer.js.map +0 -1
- package/lib/components/ResponsiveContainer/ResponsiveContainer.types.js +0 -4
- package/lib/components/ResponsiveContainer/ResponsiveContainer.types.js.map +0 -1
- package/lib/components/ResponsiveContainer/index.js +0 -3
- package/lib/components/ResponsiveContainer/index.js.map +0 -1
- package/lib/components/ResponsiveContainer/useResponsiveChildStyles.styles.js +0 -30
- package/lib/components/ResponsiveContainer/useResponsiveChildStyles.styles.js.map +0 -1
- package/lib/components/ResponsiveContainer/useResponsiveChildStyles.styles.raw.js +0 -29
- package/lib/components/ResponsiveContainer/useResponsiveChildStyles.styles.raw.js.map +0 -1
- package/lib/components/ResponsiveContainer/withResponsiveContainer.js +0 -20
- package/lib/components/ResponsiveContainer/withResponsiveContainer.js.map +0 -1
- package/lib/components/SankeyChart/SankeyChart.js +0 -1026
- package/lib/components/SankeyChart/SankeyChart.js.map +0 -1
- package/lib/components/SankeyChart/SankeyChart.types.js +0 -3
- package/lib/components/SankeyChart/SankeyChart.types.js.map +0 -1
- package/lib/components/SankeyChart/index.js +0 -3
- package/lib/components/SankeyChart/index.js.map +0 -1
- package/lib/components/SankeyChart/useSankeyChartStyles.styles.js +0 -123
- package/lib/components/SankeyChart/useSankeyChartStyles.styles.js.map +0 -1
- package/lib/components/SankeyChart/useSankeyChartStyles.styles.raw.js +0 -79
- package/lib/components/SankeyChart/useSankeyChartStyles.styles.raw.js.map +0 -1
- package/lib/components/ScatterChart/ScatterChart.js +0 -544
- package/lib/components/ScatterChart/ScatterChart.js.map +0 -1
- package/lib/components/ScatterChart/ScatterChart.types.js +0 -4
- package/lib/components/ScatterChart/ScatterChart.types.js.map +0 -1
- package/lib/components/ScatterChart/index.js +0 -3
- package/lib/components/ScatterChart/index.js.map +0 -1
- package/lib/components/ScatterChart/useScatterChartStyles.styles.js +0 -84
- package/lib/components/ScatterChart/useScatterChartStyles.styles.js.map +0 -1
- package/lib/components/ScatterChart/useScatterChartStyles.styles.raw.js +0 -41
- package/lib/components/ScatterChart/useScatterChartStyles.styles.raw.js.map +0 -1
- package/lib/components/Sparkline/Sparkline.js +0 -123
- package/lib/components/Sparkline/Sparkline.js.map +0 -1
- package/lib/components/Sparkline/Sparkline.types.js +0 -4
- package/lib/components/Sparkline/Sparkline.types.js.map +0 -1
- package/lib/components/Sparkline/index.js +0 -3
- package/lib/components/Sparkline/index.js.map +0 -1
- package/lib/components/Sparkline/useSparklineStyles.styles.js +0 -40
- package/lib/components/Sparkline/useSparklineStyles.styles.js.map +0 -1
- package/lib/components/Sparkline/useSparklineStyles.styles.raw.js +0 -31
- package/lib/components/Sparkline/useSparklineStyles.styles.raw.js.map +0 -1
- package/lib/components/VegaDeclarativeChart/VegaDeclarativeChart.js +0 -405
- package/lib/components/VegaDeclarativeChart/VegaDeclarativeChart.js.map +0 -1
- package/lib/components/VegaDeclarativeChart/VegaDeclarativeChartHooks.js +0 -20
- package/lib/components/VegaDeclarativeChart/VegaDeclarativeChartHooks.js.map +0 -1
- package/lib/components/VegaDeclarativeChart/VegaLiteColorAdapter.js +0 -415
- package/lib/components/VegaDeclarativeChart/VegaLiteColorAdapter.js.map +0 -1
- package/lib/components/VegaDeclarativeChart/VegaLiteExpressionEvaluator.js +0 -537
- package/lib/components/VegaDeclarativeChart/VegaLiteExpressionEvaluator.js.map +0 -1
- package/lib/components/VegaDeclarativeChart/VegaLiteSchemaAdapter.js +0 -3279
- package/lib/components/VegaDeclarativeChart/VegaLiteSchemaAdapter.js.map +0 -1
- package/lib/components/VegaDeclarativeChart/VegaLiteTypes.js +0 -28
- package/lib/components/VegaDeclarativeChart/VegaLiteTypes.js.map +0 -1
- package/lib/components/VegaDeclarativeChart/index.js +0 -1
- package/lib/components/VegaDeclarativeChart/index.js.map +0 -1
- package/lib/components/VerticalBarChart/VerticalBarChart.js +0 -930
- package/lib/components/VerticalBarChart/VerticalBarChart.js.map +0 -1
- package/lib/components/VerticalBarChart/VerticalBarChart.types.js +0 -4
- package/lib/components/VerticalBarChart/VerticalBarChart.types.js.map +0 -1
- package/lib/components/VerticalBarChart/index.js +0 -3
- package/lib/components/VerticalBarChart/index.js.map +0 -1
- package/lib/components/VerticalBarChart/useVerticalBarChartStyles.styles.js +0 -86
- package/lib/components/VerticalBarChart/useVerticalBarChartStyles.styles.js.map +0 -1
- package/lib/components/VerticalBarChart/useVerticalBarChartStyles.styles.raw.js +0 -48
- package/lib/components/VerticalBarChart/useVerticalBarChartStyles.styles.raw.js.map +0 -1
- package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.js +0 -1077
- package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.js.map +0 -1
- package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.types.js +0 -4
- package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.types.js.map +0 -1
- package/lib/components/VerticalStackedBarChart/index.js +0 -3
- package/lib/components/VerticalStackedBarChart/index.js.map +0 -1
- package/lib/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.js +0 -74
- package/lib/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.js.map +0 -1
- package/lib/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.raw.js +0 -38
- package/lib/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.raw.js.map +0 -1
- package/lib/index.js +0 -26
- package/lib/index.js.map +0 -1
- package/lib/types/ChartAnnotation.js +0 -1
- package/lib/types/ChartAnnotation.js.map +0 -1
- package/lib/types/DataPoint.js +0 -3
- package/lib/types/DataPoint.js.map +0 -1
- package/lib/types/EventAnnotation.js +0 -1
- package/lib/types/EventAnnotation.js.map +0 -1
- package/lib/types/LegendDataItem.js +0 -1
- package/lib/types/LegendDataItem.js.map +0 -1
- package/lib/types/index.js +0 -3
- package/lib/types/index.js.map +0 -1
- package/lib/utilities/ChartTitle.js +0 -45
- package/lib/utilities/ChartTitle.js.map +0 -1
- package/lib/utilities/Common.styles.js +0 -117
- package/lib/utilities/Common.styles.js.map +0 -1
- package/lib/utilities/Common.styles.raw.js +0 -115
- package/lib/utilities/Common.styles.raw.js.map +0 -1
- package/lib/utilities/FocusableTooltipText.js +0 -65
- package/lib/utilities/FocusableTooltipText.js.map +0 -1
- package/lib/utilities/KeyCodes.js +0 -11
- package/lib/utilities/KeyCodes.js.map +0 -1
- package/lib/utilities/SVGTooltipText.js +0 -179
- package/lib/utilities/SVGTooltipText.js.map +0 -1
- package/lib/utilities/async-utils.js +0 -380
- package/lib/utilities/async-utils.js.map +0 -1
- package/lib/utilities/colors.js +0 -281
- package/lib/utilities/colors.js.map +0 -1
- package/lib/utilities/getWindow.js +0 -25
- package/lib/utilities/getWindow.js.map +0 -1
- package/lib/utilities/hooks.js +0 -34
- package/lib/utilities/hooks.js.map +0 -1
- package/lib/utilities/image-export-utils.js +0 -405
- package/lib/utilities/image-export-utils.js.map +0 -1
- package/lib/utilities/index.js +0 -5
- package/lib/utilities/index.js.map +0 -1
- package/lib/utilities/overflow-utils.js +0 -27
- package/lib/utilities/overflow-utils.js.map +0 -1
- package/lib/utilities/scatterpolar-utils.js +0 -52
- package/lib/utilities/scatterpolar-utils.js.map +0 -1
- package/lib/utilities/string.js +0 -32
- package/lib/utilities/string.js.map +0 -1
- package/lib/utilities/test-data.js +0 -565
- package/lib/utilities/test-data.js.map +0 -1
- package/lib/utilities/utilities.js +0 -1990
- package/lib/utilities/utilities.js.map +0 -1
- package/lib/utilities/vbc-utils.js +0 -51
- package/lib/utilities/vbc-utils.js.map +0 -1
- package/lib-commonjs/AnnotationOnlyChart.js +0 -6
- package/lib-commonjs/AnnotationOnlyChart.js.map +0 -1
- package/lib-commonjs/AreaChart.js +0 -6
- package/lib-commonjs/AreaChart.js.map +0 -1
- package/lib-commonjs/CartesianChart.js +0 -6
- package/lib-commonjs/CartesianChart.js.map +0 -1
- package/lib-commonjs/ChartTable.js +0 -6
- package/lib-commonjs/ChartTable.js.map +0 -1
- package/lib-commonjs/DeclarativeChart.js +0 -6
- package/lib-commonjs/DeclarativeChart.js.map +0 -1
- package/lib-commonjs/DonutChart.js +0 -6
- package/lib-commonjs/DonutChart.js.map +0 -1
- package/lib-commonjs/FunnelChart.js +0 -6
- package/lib-commonjs/FunnelChart.js.map +0 -1
- package/lib-commonjs/GanttChart.js +0 -6
- package/lib-commonjs/GanttChart.js.map +0 -1
- package/lib-commonjs/GaugeChart.js +0 -6
- package/lib-commonjs/GaugeChart.js.map +0 -1
- package/lib-commonjs/GroupedVerticalBarChart.js +0 -6
- package/lib-commonjs/GroupedVerticalBarChart.js.map +0 -1
- package/lib-commonjs/HeatMapChart.js +0 -6
- package/lib-commonjs/HeatMapChart.js.map +0 -1
- package/lib-commonjs/HorizontalBarChart.js +0 -6
- package/lib-commonjs/HorizontalBarChart.js.map +0 -1
- package/lib-commonjs/HorizontalBarChartWithAxis.js +0 -6
- package/lib-commonjs/HorizontalBarChartWithAxis.js.map +0 -1
- package/lib-commonjs/Legends.js +0 -6
- package/lib-commonjs/Legends.js.map +0 -1
- package/lib-commonjs/LineChart.js +0 -6
- package/lib-commonjs/LineChart.js.map +0 -1
- package/lib-commonjs/PolarChart.js +0 -6
- package/lib-commonjs/PolarChart.js.map +0 -1
- package/lib-commonjs/Popover.js +0 -6
- package/lib-commonjs/Popover.js.map +0 -1
- package/lib-commonjs/ResponsiveContainer.js +0 -6
- package/lib-commonjs/ResponsiveContainer.js.map +0 -1
- package/lib-commonjs/SankeyChart.js +0 -6
- package/lib-commonjs/SankeyChart.js.map +0 -1
- package/lib-commonjs/ScatterChart.js +0 -6
- package/lib-commonjs/ScatterChart.js.map +0 -1
- package/lib-commonjs/Sparkline.js +0 -6
- package/lib-commonjs/Sparkline.js.map +0 -1
- package/lib-commonjs/VegaDeclarativeChart.js +0 -6
- package/lib-commonjs/VegaDeclarativeChart.js.map +0 -1
- package/lib-commonjs/VerticalBarChart.js +0 -6
- package/lib-commonjs/VerticalBarChart.js.map +0 -1
- package/lib-commonjs/VerticalStackedBarChart.js +0 -6
- package/lib-commonjs/VerticalStackedBarChart.js.map +0 -1
- package/lib-commonjs/components/AnnotationOnlyChart/AnnotationOnlyChart.js +0 -207
- package/lib-commonjs/components/AnnotationOnlyChart/AnnotationOnlyChart.js.map +0 -1
- package/lib-commonjs/components/AnnotationOnlyChart/AnnotationOnlyChart.types.js +0 -6
- package/lib-commonjs/components/AnnotationOnlyChart/AnnotationOnlyChart.types.js.map +0 -1
- package/lib-commonjs/components/AnnotationOnlyChart/index.js +0 -7
- package/lib-commonjs/components/AnnotationOnlyChart/index.js.map +0 -1
- package/lib-commonjs/components/AnnotationOnlyChart/useAnnotationOnlyChartStyles.styles.js +0 -57
- package/lib-commonjs/components/AnnotationOnlyChart/useAnnotationOnlyChartStyles.styles.js.map +0 -1
- package/lib-commonjs/components/AnnotationOnlyChart/useAnnotationOnlyChartStyles.styles.raw.js +0 -34
- package/lib-commonjs/components/AnnotationOnlyChart/useAnnotationOnlyChartStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/AreaChart/AreaChart.js +0 -938
- package/lib-commonjs/components/AreaChart/AreaChart.js.map +0 -1
- package/lib-commonjs/components/AreaChart/AreaChart.types.js +0 -7
- package/lib-commonjs/components/AreaChart/AreaChart.types.js.map +0 -1
- package/lib-commonjs/components/AreaChart/index.js +0 -8
- package/lib-commonjs/components/AreaChart/index.js.map +0 -1
- package/lib-commonjs/components/AreaChart/useAreaChartStyles.styles.js +0 -96
- package/lib-commonjs/components/AreaChart/useAreaChartStyles.styles.js.map +0 -1
- package/lib-commonjs/components/AreaChart/useAreaChartStyles.styles.raw.js +0 -49
- package/lib-commonjs/components/AreaChart/useAreaChartStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/ChartTable/ChartTable.js +0 -171
- package/lib-commonjs/components/ChartTable/ChartTable.js.map +0 -1
- package/lib-commonjs/components/ChartTable/ChartTable.types.js +0 -7
- package/lib-commonjs/components/ChartTable/ChartTable.types.js.map +0 -1
- package/lib-commonjs/components/ChartTable/index.js +0 -8
- package/lib-commonjs/components/ChartTable/index.js.map +0 -1
- package/lib-commonjs/components/ChartTable/useChartTableStyles.styles.js +0 -200
- package/lib-commonjs/components/ChartTable/useChartTableStyles.styles.js.map +0 -1
- package/lib-commonjs/components/ChartTable/useChartTableStyles.styles.raw.js +0 -82
- package/lib-commonjs/components/ChartTable/useChartTableStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.js +0 -670
- package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.js.map +0 -1
- package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.types.js +0 -4
- package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.types.js.map +0 -1
- package/lib-commonjs/components/CommonComponents/Annotations/index.js +0 -7
- package/lib-commonjs/components/CommonComponents/Annotations/index.js.map +0 -1
- package/lib-commonjs/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.js +0 -325
- package/lib-commonjs/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.js.map +0 -1
- package/lib-commonjs/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.raw.js +0 -174
- package/lib-commonjs/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.raw.js.map +0 -1
- package/lib-commonjs/components/CommonComponents/CartesianChart.js +0 -673
- package/lib-commonjs/components/CommonComponents/CartesianChart.js.map +0 -1
- package/lib-commonjs/components/CommonComponents/CartesianChart.types.js +0 -5
- package/lib-commonjs/components/CommonComponents/CartesianChart.types.js.map +0 -1
- package/lib-commonjs/components/CommonComponents/ChartPopover.js +0 -207
- package/lib-commonjs/components/CommonComponents/ChartPopover.js.map +0 -1
- package/lib-commonjs/components/CommonComponents/ChartPopover.types.js +0 -4
- package/lib-commonjs/components/CommonComponents/ChartPopover.types.js.map +0 -1
- package/lib-commonjs/components/CommonComponents/index.js +0 -11
- package/lib-commonjs/components/CommonComponents/index.js.map +0 -1
- package/lib-commonjs/components/CommonComponents/useCartesianChartStyles.styles.js +0 -268
- package/lib-commonjs/components/CommonComponents/useCartesianChartStyles.styles.js.map +0 -1
- package/lib-commonjs/components/CommonComponents/useCartesianChartStyles.styles.raw.js +0 -144
- package/lib-commonjs/components/CommonComponents/useCartesianChartStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/CommonComponents/useChartPopoverStyles.styles.js +0 -238
- package/lib-commonjs/components/CommonComponents/useChartPopoverStyles.styles.js.map +0 -1
- package/lib-commonjs/components/CommonComponents/useChartPopoverStyles.styles.raw.js +0 -141
- package/lib-commonjs/components/CommonComponents/useChartPopoverStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/DeclarativeChart/DeclarativeChart.js +0 -400
- package/lib-commonjs/components/DeclarativeChart/DeclarativeChart.js.map +0 -1
- package/lib-commonjs/components/DeclarativeChart/PlotlyColorAdapter.js +0 -195
- package/lib-commonjs/components/DeclarativeChart/PlotlyColorAdapter.js.map +0 -1
- package/lib-commonjs/components/DeclarativeChart/PlotlySchemaAdapter.js +0 -3577
- package/lib-commonjs/components/DeclarativeChart/PlotlySchemaAdapter.js.map +0 -1
- package/lib-commonjs/components/DeclarativeChart/index.js +0 -6
- package/lib-commonjs/components/DeclarativeChart/index.js.map +0 -1
- package/lib-commonjs/components/DonutChart/Arc/Arc.js +0 -125
- package/lib-commonjs/components/DonutChart/Arc/Arc.js.map +0 -1
- package/lib-commonjs/components/DonutChart/Arc/Arc.types.js +0 -4
- package/lib-commonjs/components/DonutChart/Arc/Arc.types.js.map +0 -1
- package/lib-commonjs/components/DonutChart/Arc/index.js +0 -7
- package/lib-commonjs/components/DonutChart/Arc/index.js.map +0 -1
- package/lib-commonjs/components/DonutChart/Arc/useArcStyles.styles.js +0 -110
- package/lib-commonjs/components/DonutChart/Arc/useArcStyles.styles.js.map +0 -1
- package/lib-commonjs/components/DonutChart/Arc/useArcStyles.styles.raw.js +0 -63
- package/lib-commonjs/components/DonutChart/Arc/useArcStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/DonutChart/DonutChart.js +0 -356
- package/lib-commonjs/components/DonutChart/DonutChart.js.map +0 -1
- package/lib-commonjs/components/DonutChart/DonutChart.types.js +0 -7
- package/lib-commonjs/components/DonutChart/DonutChart.types.js.map +0 -1
- package/lib-commonjs/components/DonutChart/Pie/Pie.js +0 -79
- package/lib-commonjs/components/DonutChart/Pie/Pie.js.map +0 -1
- package/lib-commonjs/components/DonutChart/Pie/Pie.types.js +0 -4
- package/lib-commonjs/components/DonutChart/Pie/Pie.types.js.map +0 -1
- package/lib-commonjs/components/DonutChart/Pie/index.js +0 -7
- package/lib-commonjs/components/DonutChart/Pie/index.js.map +0 -1
- package/lib-commonjs/components/DonutChart/Pie/usePieStyles.styles.js +0 -55
- package/lib-commonjs/components/DonutChart/Pie/usePieStyles.styles.js.map +0 -1
- package/lib-commonjs/components/DonutChart/Pie/usePieStyles.styles.raw.js +0 -44
- package/lib-commonjs/components/DonutChart/Pie/usePieStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/DonutChart/index.js +0 -8
- package/lib-commonjs/components/DonutChart/index.js.map +0 -1
- package/lib-commonjs/components/DonutChart/useDonutChartStyles.styles.js +0 -145
- package/lib-commonjs/components/DonutChart/useDonutChartStyles.styles.js.map +0 -1
- package/lib-commonjs/components/DonutChart/useDonutChartStyles.styles.raw.js +0 -76
- package/lib-commonjs/components/DonutChart/useDonutChartStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/FunnelChart/FunnelChart.js +0 -412
- package/lib-commonjs/components/FunnelChart/FunnelChart.js.map +0 -1
- package/lib-commonjs/components/FunnelChart/FunnelChart.types.js +0 -7
- package/lib-commonjs/components/FunnelChart/FunnelChart.types.js.map +0 -1
- package/lib-commonjs/components/FunnelChart/funnelGeometry.js +0 -246
- package/lib-commonjs/components/FunnelChart/funnelGeometry.js.map +0 -1
- package/lib-commonjs/components/FunnelChart/index.js +0 -7
- package/lib-commonjs/components/FunnelChart/index.js.map +0 -1
- package/lib-commonjs/components/FunnelChart/useFunnelChartStyles.styles.js +0 -118
- package/lib-commonjs/components/FunnelChart/useFunnelChartStyles.styles.js.map +0 -1
- package/lib-commonjs/components/FunnelChart/useFunnelChartStyles.styles.raw.js +0 -79
- package/lib-commonjs/components/FunnelChart/useFunnelChartStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/GanttChart/GanttChart.js +0 -546
- package/lib-commonjs/components/GanttChart/GanttChart.js.map +0 -1
- package/lib-commonjs/components/GanttChart/GanttChart.types.js +0 -7
- package/lib-commonjs/components/GanttChart/GanttChart.types.js.map +0 -1
- package/lib-commonjs/components/GanttChart/index.js +0 -7
- package/lib-commonjs/components/GanttChart/index.js.map +0 -1
- package/lib-commonjs/components/GanttChart/useGanttChartStyles.styles.js +0 -42
- package/lib-commonjs/components/GanttChart/useGanttChartStyles.styles.js.map +0 -1
- package/lib-commonjs/components/GanttChart/useGanttChartStyles.styles.raw.js +0 -42
- package/lib-commonjs/components/GanttChart/useGanttChartStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/GaugeChart/GaugeChart.js +0 -597
- package/lib-commonjs/components/GaugeChart/GaugeChart.js.map +0 -1
- package/lib-commonjs/components/GaugeChart/GaugeChart.types.js +0 -7
- package/lib-commonjs/components/GaugeChart/GaugeChart.types.js.map +0 -1
- package/lib-commonjs/components/GaugeChart/index.js +0 -8
- package/lib-commonjs/components/GaugeChart/index.js.map +0 -1
- package/lib-commonjs/components/GaugeChart/useGaugeChartStyles.styles.js +0 -281
- package/lib-commonjs/components/GaugeChart/useGaugeChartStyles.styles.js.map +0 -1
- package/lib-commonjs/components/GaugeChart/useGaugeChartStyles.styles.raw.js +0 -167
- package/lib-commonjs/components/GaugeChart/useGaugeChartStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.js +0 -818
- package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.js.map +0 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.types.js +0 -7
- package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.types.js.map +0 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/index.js +0 -8
- package/lib-commonjs/components/GroupedVerticalBarChart/index.js.map +0 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.js +0 -116
- package/lib-commonjs/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.js.map +0 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.raw.js +0 -56
- package/lib-commonjs/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/HeatMapChart/HeatMapChart.js +0 -688
- package/lib-commonjs/components/HeatMapChart/HeatMapChart.js.map +0 -1
- package/lib-commonjs/components/HeatMapChart/HeatMapChart.types.js +0 -7
- package/lib-commonjs/components/HeatMapChart/HeatMapChart.types.js.map +0 -1
- package/lib-commonjs/components/HeatMapChart/index.js +0 -8
- package/lib-commonjs/components/HeatMapChart/index.js.map +0 -1
- package/lib-commonjs/components/HeatMapChart/useHeatMapChartStyles.styles.js +0 -71
- package/lib-commonjs/components/HeatMapChart/useHeatMapChartStyles.styles.js.map +0 -1
- package/lib-commonjs/components/HeatMapChart/useHeatMapChartStyles.styles.raw.js +0 -60
- package/lib-commonjs/components/HeatMapChart/useHeatMapChartStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.js +0 -417
- package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.js.map +0 -1
- package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.types.js +0 -17
- package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.types.js.map +0 -1
- package/lib-commonjs/components/HorizontalBarChart/index.js +0 -8
- package/lib-commonjs/components/HorizontalBarChart/index.js.map +0 -1
- package/lib-commonjs/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.js +0 -264
- package/lib-commonjs/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.js.map +0 -1
- package/lib-commonjs/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.raw.js +0 -139
- package/lib-commonjs/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.js +0 -726
- package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.js.map +0 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.js +0 -7
- package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.js.map +0 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/index.js +0 -8
- package/lib-commonjs/components/HorizontalBarChartWithAxis/index.js.map +0 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.js +0 -86
- package/lib-commonjs/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.js.map +0 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.raw.js +0 -70
- package/lib-commonjs/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/Legends/Legends.js +0 -333
- package/lib-commonjs/components/Legends/Legends.js.map +0 -1
- package/lib-commonjs/components/Legends/Legends.types.js +0 -6
- package/lib-commonjs/components/Legends/Legends.types.js.map +0 -1
- package/lib-commonjs/components/Legends/OverflowMenu.js +0 -44
- package/lib-commonjs/components/Legends/OverflowMenu.js.map +0 -1
- package/lib-commonjs/components/Legends/index.js +0 -8
- package/lib-commonjs/components/Legends/index.js.map +0 -1
- package/lib-commonjs/components/Legends/shape.js +0 -47
- package/lib-commonjs/components/Legends/shape.js.map +0 -1
- package/lib-commonjs/components/Legends/useLegendsStyles.styles.js +0 -456
- package/lib-commonjs/components/Legends/useLegendsStyles.styles.js.map +0 -1
- package/lib-commonjs/components/Legends/useLegendsStyles.styles.raw.js +0 -178
- package/lib-commonjs/components/Legends/useLegendsStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/LineChart/LineChart.js +0 -1337
- package/lib-commonjs/components/LineChart/LineChart.js.map +0 -1
- package/lib-commonjs/components/LineChart/LineChart.types.js +0 -6
- package/lib-commonjs/components/LineChart/LineChart.types.js.map +0 -1
- package/lib-commonjs/components/LineChart/eventAnnotation/EventAnnotation.js +0 -129
- package/lib-commonjs/components/LineChart/eventAnnotation/EventAnnotation.js.map +0 -1
- package/lib-commonjs/components/LineChart/eventAnnotation/LabelLink.js +0 -70
- package/lib-commonjs/components/LineChart/eventAnnotation/LabelLink.js.map +0 -1
- package/lib-commonjs/components/LineChart/eventAnnotation/Textbox.js +0 -53
- package/lib-commonjs/components/LineChart/eventAnnotation/Textbox.js.map +0 -1
- package/lib-commonjs/components/LineChart/index.js +0 -9
- package/lib-commonjs/components/LineChart/index.js.map +0 -1
- package/lib-commonjs/components/LineChart/useLineChartStyles.styles.js +0 -132
- package/lib-commonjs/components/LineChart/useLineChartStyles.styles.js.map +0 -1
- package/lib-commonjs/components/LineChart/useLineChartStyles.styles.raw.js +0 -63
- package/lib-commonjs/components/LineChart/useLineChartStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/PolarChart/PolarChart.js +0 -587
- package/lib-commonjs/components/PolarChart/PolarChart.js.map +0 -1
- package/lib-commonjs/components/PolarChart/PolarChart.types.js +0 -7
- package/lib-commonjs/components/PolarChart/PolarChart.types.js.map +0 -1
- package/lib-commonjs/components/PolarChart/PolarChart.utils.js +0 -204
- package/lib-commonjs/components/PolarChart/PolarChart.utils.js.map +0 -1
- package/lib-commonjs/components/PolarChart/index.js +0 -7
- package/lib-commonjs/components/PolarChart/index.js.map +0 -1
- package/lib-commonjs/components/PolarChart/usePolarChartStyles.styles.js +0 -107
- package/lib-commonjs/components/PolarChart/usePolarChartStyles.styles.js.map +0 -1
- package/lib-commonjs/components/PolarChart/usePolarChartStyles.styles.raw.js +0 -75
- package/lib-commonjs/components/PolarChart/usePolarChartStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/ResponsiveContainer/ResponsiveContainer.js +0 -107
- package/lib-commonjs/components/ResponsiveContainer/ResponsiveContainer.js.map +0 -1
- package/lib-commonjs/components/ResponsiveContainer/ResponsiveContainer.types.js +0 -7
- package/lib-commonjs/components/ResponsiveContainer/ResponsiveContainer.types.js.map +0 -1
- package/lib-commonjs/components/ResponsiveContainer/index.js +0 -8
- package/lib-commonjs/components/ResponsiveContainer/index.js.map +0 -1
- package/lib-commonjs/components/ResponsiveContainer/useResponsiveChildStyles.styles.js +0 -50
- package/lib-commonjs/components/ResponsiveContainer/useResponsiveChildStyles.styles.js.map +0 -1
- package/lib-commonjs/components/ResponsiveContainer/useResponsiveChildStyles.styles.raw.js +0 -47
- package/lib-commonjs/components/ResponsiveContainer/useResponsiveChildStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/ResponsiveContainer/withResponsiveContainer.js +0 -28
- package/lib-commonjs/components/ResponsiveContainer/withResponsiveContainer.js.map +0 -1
- package/lib-commonjs/components/SankeyChart/SankeyChart.js +0 -1042
- package/lib-commonjs/components/SankeyChart/SankeyChart.js.map +0 -1
- package/lib-commonjs/components/SankeyChart/SankeyChart.types.js +0 -6
- package/lib-commonjs/components/SankeyChart/SankeyChart.types.js.map +0 -1
- package/lib-commonjs/components/SankeyChart/index.js +0 -8
- package/lib-commonjs/components/SankeyChart/index.js.map +0 -1
- package/lib-commonjs/components/SankeyChart/useSankeyChartStyles.styles.js +0 -202
- package/lib-commonjs/components/SankeyChart/useSankeyChartStyles.styles.js.map +0 -1
- package/lib-commonjs/components/SankeyChart/useSankeyChartStyles.styles.raw.js +0 -97
- package/lib-commonjs/components/SankeyChart/useSankeyChartStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/ScatterChart/ScatterChart.js +0 -550
- package/lib-commonjs/components/ScatterChart/ScatterChart.js.map +0 -1
- package/lib-commonjs/components/ScatterChart/ScatterChart.types.js +0 -7
- package/lib-commonjs/components/ScatterChart/ScatterChart.types.js.map +0 -1
- package/lib-commonjs/components/ScatterChart/index.js +0 -8
- package/lib-commonjs/components/ScatterChart/index.js.map +0 -1
- package/lib-commonjs/components/ScatterChart/useScatterChartStyles.styles.js +0 -120
- package/lib-commonjs/components/ScatterChart/useScatterChartStyles.styles.js.map +0 -1
- package/lib-commonjs/components/ScatterChart/useScatterChartStyles.styles.raw.js +0 -55
- package/lib-commonjs/components/ScatterChart/useScatterChartStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/Sparkline/Sparkline.js +0 -129
- package/lib-commonjs/components/Sparkline/Sparkline.js.map +0 -1
- package/lib-commonjs/components/Sparkline/Sparkline.types.js +0 -7
- package/lib-commonjs/components/Sparkline/Sparkline.types.js.map +0 -1
- package/lib-commonjs/components/Sparkline/index.js +0 -8
- package/lib-commonjs/components/Sparkline/index.js.map +0 -1
- package/lib-commonjs/components/Sparkline/useSparklineStyles.styles.js +0 -57
- package/lib-commonjs/components/Sparkline/useSparklineStyles.styles.js.map +0 -1
- package/lib-commonjs/components/Sparkline/useSparklineStyles.styles.raw.js +0 -45
- package/lib-commonjs/components/Sparkline/useSparklineStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/VegaDeclarativeChart/VegaDeclarativeChart.js +0 -274
- package/lib-commonjs/components/VegaDeclarativeChart/VegaDeclarativeChart.js.map +0 -1
- package/lib-commonjs/components/VegaDeclarativeChart/VegaDeclarativeChartHooks.js +0 -35
- package/lib-commonjs/components/VegaDeclarativeChart/VegaDeclarativeChartHooks.js.map +0 -1
- package/lib-commonjs/components/VegaDeclarativeChart/VegaLiteColorAdapter.js +0 -412
- package/lib-commonjs/components/VegaDeclarativeChart/VegaLiteColorAdapter.js.map +0 -1
- package/lib-commonjs/components/VegaDeclarativeChart/VegaLiteExpressionEvaluator.js +0 -533
- package/lib-commonjs/components/VegaDeclarativeChart/VegaLiteExpressionEvaluator.js.map +0 -1
- package/lib-commonjs/components/VegaDeclarativeChart/VegaLiteSchemaAdapter.js +0 -3214
- package/lib-commonjs/components/VegaDeclarativeChart/VegaLiteSchemaAdapter.js.map +0 -1
- package/lib-commonjs/components/VegaDeclarativeChart/VegaLiteTypes.js +0 -31
- package/lib-commonjs/components/VegaDeclarativeChart/VegaLiteTypes.js.map +0 -1
- package/lib-commonjs/components/VegaDeclarativeChart/index.js +0 -6
- package/lib-commonjs/components/VegaDeclarativeChart/index.js.map +0 -1
- package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.js +0 -932
- package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.js.map +0 -1
- package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.types.js +0 -7
- package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.types.js.map +0 -1
- package/lib-commonjs/components/VerticalBarChart/index.js +0 -8
- package/lib-commonjs/components/VerticalBarChart/index.js.map +0 -1
- package/lib-commonjs/components/VerticalBarChart/useVerticalBarChartStyles.styles.js +0 -128
- package/lib-commonjs/components/VerticalBarChart/useVerticalBarChartStyles.styles.js.map +0 -1
- package/lib-commonjs/components/VerticalBarChart/useVerticalBarChartStyles.styles.raw.js +0 -64
- package/lib-commonjs/components/VerticalBarChart/useVerticalBarChartStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.js +0 -1088
- package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.js.map +0 -1
- package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.types.js +0 -7
- package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.types.js.map +0 -1
- package/lib-commonjs/components/VerticalStackedBarChart/index.js +0 -8
- package/lib-commonjs/components/VerticalStackedBarChart/index.js.map +0 -1
- package/lib-commonjs/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.js +0 -116
- package/lib-commonjs/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.js.map +0 -1
- package/lib-commonjs/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.raw.js +0 -56
- package/lib-commonjs/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.raw.js.map +0 -1
- package/lib-commonjs/index.js +0 -31
- package/lib-commonjs/index.js.map +0 -1
- package/lib-commonjs/types/ChartAnnotation.js +0 -4
- package/lib-commonjs/types/ChartAnnotation.js.map +0 -1
- package/lib-commonjs/types/DataPoint.js +0 -6
- package/lib-commonjs/types/DataPoint.js.map +0 -1
- package/lib-commonjs/types/EventAnnotation.js +0 -4
- package/lib-commonjs/types/EventAnnotation.js.map +0 -1
- package/lib-commonjs/types/LegendDataItem.js +0 -4
- package/lib-commonjs/types/LegendDataItem.js.map +0 -1
- package/lib-commonjs/types/index.js +0 -8
- package/lib-commonjs/types/index.js.map +0 -1
- package/lib-commonjs/utilities/ChartTitle.js +0 -53
- package/lib-commonjs/utilities/ChartTitle.js.map +0 -1
- package/lib-commonjs/utilities/Common.styles.js +0 -138
- package/lib-commonjs/utilities/Common.styles.js.map +0 -1
- package/lib-commonjs/utilities/Common.styles.raw.js +0 -138
- package/lib-commonjs/utilities/Common.styles.raw.js.map +0 -1
- package/lib-commonjs/utilities/FocusableTooltipText.js +0 -75
- package/lib-commonjs/utilities/FocusableTooltipText.js.map +0 -1
- package/lib-commonjs/utilities/KeyCodes.js +0 -21
- package/lib-commonjs/utilities/KeyCodes.js.map +0 -1
- package/lib-commonjs/utilities/SVGTooltipText.js +0 -189
- package/lib-commonjs/utilities/SVGTooltipText.js.map +0 -1
- package/lib-commonjs/utilities/async-utils.js +0 -382
- package/lib-commonjs/utilities/async-utils.js.map +0 -1
- package/lib-commonjs/utilities/colors.js +0 -311
- package/lib-commonjs/utilities/colors.js.map +0 -1
- package/lib-commonjs/utilities/getWindow.js +0 -28
- package/lib-commonjs/utilities/getWindow.js.map +0 -1
- package/lib-commonjs/utilities/hooks.js +0 -45
- package/lib-commonjs/utilities/hooks.js.map +0 -1
- package/lib-commonjs/utilities/image-export-utils.js +0 -423
- package/lib-commonjs/utilities/image-export-utils.js.map +0 -1
- package/lib-commonjs/utilities/index.js +0 -10
- package/lib-commonjs/utilities/index.js.map +0 -1
- package/lib-commonjs/utilities/overflow-utils.js +0 -36
- package/lib-commonjs/utilities/overflow-utils.js.map +0 -1
- package/lib-commonjs/utilities/scatterpolar-utils.js +0 -67
- package/lib-commonjs/utilities/scatterpolar-utils.js.map +0 -1
- package/lib-commonjs/utilities/string.js +0 -29
- package/lib-commonjs/utilities/string.js.map +0 -1
- package/lib-commonjs/utilities/test-data.js +0 -628
- package/lib-commonjs/utilities/test-data.js.map +0 -1
- package/lib-commonjs/utilities/utilities.js +0 -2016
- package/lib-commonjs/utilities/utilities.js.map +0 -1
- package/lib-commonjs/utilities/vbc-utils.js +0 -72
- package/lib-commonjs/utilities/vbc-utils.js.map +0 -1
|
@@ -1,665 +0,0 @@
|
|
|
1
|
-
'use client';
|
|
2
|
-
import * as React from 'react';
|
|
3
|
-
import { useCartesianChartStyles } from './useCartesianChartStyles.styles';
|
|
4
|
-
import { select as d3Select } from 'd3-selection';
|
|
5
|
-
import { createNumericXAxis, createStringXAxis, createDateXAxis, XAxisTypes, YAxisType, createWrapOfXLabels, rotateXAxisLabels, calculateLongestLabelWidth, createYAxisLabels, ChartTypes, wrapContent, useRtl, truncateString, tooltipOfAxislabels, getSecureProps, DEFAULT_WRAP_WIDTH, autoLayoutXAxisLabels, getChartTitleInlineStyles } from '../../utilities/index';
|
|
6
|
-
import { useId } from '@fluentui/react-utilities';
|
|
7
|
-
import { SVGTooltipText } from '../../utilities/SVGTooltipText';
|
|
8
|
-
import { ChartAnnotationLayer } from './Annotations/ChartAnnotationLayer';
|
|
9
|
-
import { ChartPopover } from './ChartPopover';
|
|
10
|
-
import { useFocusableGroup, useArrowNavigationGroup } from '@fluentui/react-tabster';
|
|
11
|
-
const HORIZONTAL_MARGIN_FOR_YAXIS_TITLE = 24;
|
|
12
|
-
const VERTICAL_MARGIN_FOR_XAXIS_TITLE = 20;
|
|
13
|
-
const AXIS_TITLE_PADDING = 8;
|
|
14
|
-
const DEFAULT_MARGIN_WITH_TICKS = 40;
|
|
15
|
-
const DEFAULT_MARGIN_NO_TICKS = 20;
|
|
16
|
-
/**
|
|
17
|
-
* Cartesian Chart component
|
|
18
|
-
* {@docCategory CartesianChart}
|
|
19
|
-
*/ export const CartesianChart = /*#__PURE__*/ React.forwardRef(({ hideTickOverlap = true, ...props }, forwardedRef)=>{
|
|
20
|
-
const chartContainer = React.useRef(null);
|
|
21
|
-
let legendContainer;
|
|
22
|
-
const minLegendContainerHeight = 40;
|
|
23
|
-
const xAxisElement = React.useRef(null);
|
|
24
|
-
const yAxisElement = React.useRef(null);
|
|
25
|
-
const yAxisElementSecondary = React.useRef(null);
|
|
26
|
-
let margins;
|
|
27
|
-
const idForGraph = 'chart_';
|
|
28
|
-
let _reqID;
|
|
29
|
-
const _useRtl = useRtl();
|
|
30
|
-
let _tickLabels;
|
|
31
|
-
const _isFirstRender = React.useRef(true);
|
|
32
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
33
|
-
let _xScale;
|
|
34
|
-
const isIntegralDataset = React.useMemo(()=>{
|
|
35
|
-
return !props.points.some((point)=>point.y % 1 !== 0);
|
|
36
|
-
}, [
|
|
37
|
-
props.points
|
|
38
|
-
]);
|
|
39
|
-
const _tooltipId = useId('tooltip_');
|
|
40
|
-
/* Used for when WrapXAxisLabels props appeared.
|
|
41
|
-
* To display the total word (space separated words), Need to have more space than usual.
|
|
42
|
-
* This height will get total height need to disaply total word.
|
|
43
|
-
* These value need to be removed from actual svg height/graph height.
|
|
44
|
-
* Defalut value is 0. And this values calculted when 'wrapXAxisLables' or 'showXAxisLablesTooltip' is true.
|
|
45
|
-
*/ let _removalValueForTextTuncate = 0;
|
|
46
|
-
const _yAxisTickText = React.useRef([]);
|
|
47
|
-
const [containerWidth, setContainerWidth] = React.useState(0);
|
|
48
|
-
const [containerHeight, setContainerHeight] = React.useState(0);
|
|
49
|
-
const [startFromX, setStartFromX] = React.useState(0);
|
|
50
|
-
const prevWidthRef = React.useRef(undefined);
|
|
51
|
-
const prevHeightRef = React.useRef(undefined);
|
|
52
|
-
const classes = useCartesianChartStyles(props);
|
|
53
|
-
const focusAttributes = useFocusableGroup();
|
|
54
|
-
const arrowAttributes = useArrowNavigationGroup({
|
|
55
|
-
circular: true,
|
|
56
|
-
axis: 'horizontal'
|
|
57
|
-
});
|
|
58
|
-
// ComponentdidMount and Componentwillunmount logic
|
|
59
|
-
React.useEffect(()=>{
|
|
60
|
-
_fitParentContainer();
|
|
61
|
-
if (props.showYAxisLables) {
|
|
62
|
-
const maxYAxisLabelLength = calculateMaxYAxisLabelLength(classes.yAxis);
|
|
63
|
-
if (startFromX !== maxYAxisLabelLength) {
|
|
64
|
-
setStartFromX(maxYAxisLabelLength);
|
|
65
|
-
}
|
|
66
|
-
} else if (startFromX !== 0) {
|
|
67
|
-
setStartFromX(0);
|
|
68
|
-
}
|
|
69
|
-
return ()=>{
|
|
70
|
-
if (_reqID !== undefined) {
|
|
71
|
-
cancelAnimationFrame(_reqID);
|
|
72
|
-
}
|
|
73
|
-
};
|
|
74
|
-
}, [
|
|
75
|
-
props
|
|
76
|
-
]);
|
|
77
|
-
// ComponentDidUpdate logic
|
|
78
|
-
React.useEffect(()=>{
|
|
79
|
-
// Check if height or width changed
|
|
80
|
-
if (prevWidthRef.current !== undefined && prevHeightRef.current !== undefined && (prevWidthRef.current !== props.width || prevHeightRef.current !== props.height)) {
|
|
81
|
-
_fitParentContainer();
|
|
82
|
-
}
|
|
83
|
-
// Update refs with current values
|
|
84
|
-
prevWidthRef.current = props.width;
|
|
85
|
-
prevHeightRef.current = props.height;
|
|
86
|
-
if (props.showYAxisLables) {
|
|
87
|
-
const maxYAxisLabelLength = calculateMaxYAxisLabelLength(classes.yAxis);
|
|
88
|
-
if (startFromX !== maxYAxisLabelLength) {
|
|
89
|
-
setStartFromX(maxYAxisLabelLength);
|
|
90
|
-
}
|
|
91
|
-
} else if (startFromX !== 0) {
|
|
92
|
-
setStartFromX(0);
|
|
93
|
-
}
|
|
94
|
-
}, [
|
|
95
|
-
props.width,
|
|
96
|
-
props.height,
|
|
97
|
-
props.chartType,
|
|
98
|
-
props.showYAxisLables,
|
|
99
|
-
props.yAxisType
|
|
100
|
-
]);
|
|
101
|
-
React.useImperativeHandle(props.componentRef, ()=>{
|
|
102
|
-
var _chartContainer_current;
|
|
103
|
-
return {
|
|
104
|
-
chartContainer: (_chartContainer_current = chartContainer.current) !== null && _chartContainer_current !== void 0 ? _chartContainer_current : null
|
|
105
|
-
};
|
|
106
|
-
}, []);
|
|
107
|
-
/**
|
|
108
|
-
* Dedicated function to return the Callout JSX Element , which can further be used to only call this when
|
|
109
|
-
* only the calloutprops and charthover props changes.
|
|
110
|
-
* @param calloutProps
|
|
111
|
-
* @param chartHoverProps
|
|
112
|
-
* @returns
|
|
113
|
-
*/ // eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
114
|
-
function _generateCallout(calloutProps) {
|
|
115
|
-
return /*#__PURE__*/ React.createElement(ChartPopover, calloutProps);
|
|
116
|
-
}
|
|
117
|
-
function calculateMaxYAxisLabelLength(className) {
|
|
118
|
-
const formatTickLabel = (str)=>{
|
|
119
|
-
if (props.showYAxisLablesTooltip) {
|
|
120
|
-
return truncateString(str, props.noOfCharsToTruncate || 4);
|
|
121
|
-
}
|
|
122
|
-
return str;
|
|
123
|
-
};
|
|
124
|
-
return calculateLongestLabelWidth(_yAxisTickText.current.map((label)=>formatTickLabel(label)), `.${className} text`);
|
|
125
|
-
}
|
|
126
|
-
const { calloutProps, points, chartType, svgProps, culture, dateLocalizeOptions, timeFormatLocale, customDateTimeFormatter } = props;
|
|
127
|
-
if (props.parentRef) {
|
|
128
|
-
_fitParentContainer();
|
|
129
|
-
}
|
|
130
|
-
margins = _calcMargins();
|
|
131
|
-
// Callback for margins to the chart
|
|
132
|
-
props.getmargins && props.getmargins(margins);
|
|
133
|
-
let callout = null;
|
|
134
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
135
|
-
let yScalePrimary;
|
|
136
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
137
|
-
let yScaleSecondary;
|
|
138
|
-
let children = null;
|
|
139
|
-
if (props.enableFirstRenderOptimization && chartContainer.current || !props.enableFirstRenderOptimization) {
|
|
140
|
-
var _props_xAxis, _props_xAxis1, _props_xAxis2;
|
|
141
|
-
_isFirstRender.current = false;
|
|
142
|
-
var _props_showRoundOffXTickValues;
|
|
143
|
-
const XAxisParams = {
|
|
144
|
-
domainNRangeValues: props.getDomainNRangeValues(points, props.getDomainMargins ? props.getDomainMargins(containerWidth) : margins, containerWidth, chartType, _useRtl, props.xAxisType, props.barwidth, props.tickValues),
|
|
145
|
-
// FIXME: In XAxisParams, containerHeight is used by HBWA to generate vertical gridlines.
|
|
146
|
-
// Since the x-axis in HBWA is numeric, it typically doesn't require transformation.
|
|
147
|
-
// However, if transformation props are enabled, the updated _removalValueForTextTuncate
|
|
148
|
-
// will only be available in the next render, as it's set after the axis is created.
|
|
149
|
-
// Solution: Delay the creation of gridlines until after the transformation has been applied,
|
|
150
|
-
// or precompute the required height for transformed labels (_removalValueForTextTuncate).
|
|
151
|
-
containerHeight: containerHeight - _removalValueForTextTuncate,
|
|
152
|
-
margins,
|
|
153
|
-
xAxisElement: xAxisElement.current,
|
|
154
|
-
showRoundOffXTickValues: (_props_showRoundOffXTickValues = props.showRoundOffXTickValues) !== null && _props_showRoundOffXTickValues !== void 0 ? _props_showRoundOffXTickValues : true,
|
|
155
|
-
xAxisCount: props.xAxisTickCount,
|
|
156
|
-
xAxistickSize: props.xAxistickSize,
|
|
157
|
-
tickPadding: props.tickPadding || props.showXAxisLablesTooltip ? 5 : 10,
|
|
158
|
-
xAxisPadding: props.xAxisPadding,
|
|
159
|
-
xAxisInnerPadding: props.xAxisInnerPadding,
|
|
160
|
-
xAxisOuterPadding: props.xAxisOuterPadding,
|
|
161
|
-
containerWidth,
|
|
162
|
-
hideTickOverlap: props.rotateXAxisLables || ((_props_xAxis = props.xAxis) === null || _props_xAxis === void 0 ? void 0 : _props_xAxis.tickLayout) === 'auto' ? false : hideTickOverlap,
|
|
163
|
-
calcMaxLabelWidth: _calcMaxLabelWidthWithTransform,
|
|
164
|
-
xMinValue: props.xMinValue,
|
|
165
|
-
xMaxValue: props.xMaxValue,
|
|
166
|
-
...props.xAxis
|
|
167
|
-
};
|
|
168
|
-
/**
|
|
169
|
-
* These scales used for 2 purposes.
|
|
170
|
-
* 1. To create x and y axis
|
|
171
|
-
* 2. To draw the graph.
|
|
172
|
-
* For area/line chart using same scales. For other charts, creating their own scales to draw the graph.
|
|
173
|
-
*/ // eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
174
|
-
let xScale;
|
|
175
|
-
let tickValues;
|
|
176
|
-
let tickLabels;
|
|
177
|
-
switch(props.xAxisType){
|
|
178
|
-
case XAxisTypes.NumericAxis:
|
|
179
|
-
({ xScale, tickValues, tickLabels } = createNumericXAxis(XAxisParams, props.tickParams, props.chartType, culture, props.xScaleType, _useRtl));
|
|
180
|
-
break;
|
|
181
|
-
case XAxisTypes.DateAxis:
|
|
182
|
-
({ xScale, tickValues, tickLabels } = createDateXAxis(XAxisParams, props.tickParams, culture, dateLocalizeOptions, timeFormatLocale, customDateTimeFormatter, props.useUTC, props.chartType));
|
|
183
|
-
break;
|
|
184
|
-
case XAxisTypes.StringAxis:
|
|
185
|
-
({ xScale, tickValues, tickLabels } = createStringXAxis(XAxisParams, props.tickParams, props.datasetForXAxisDomain, culture, _useRtl));
|
|
186
|
-
break;
|
|
187
|
-
default:
|
|
188
|
-
({ xScale, tickValues, tickLabels } = createNumericXAxis(XAxisParams, props.tickParams, props.chartType, culture, props.xScaleType, _useRtl));
|
|
189
|
-
}
|
|
190
|
-
_xScale = xScale;
|
|
191
|
-
_tickLabels = tickLabels;
|
|
192
|
-
if (((_props_xAxis1 = props.xAxis) === null || _props_xAxis1 === void 0 ? void 0 : _props_xAxis1.tickLayout) === 'auto') {
|
|
193
|
-
_removalValueForTextTuncate = autoLayoutXAxisLabels(tickValues, _tickLabels, _xScale, xAxisElement.current, containerWidth, chartContainer.current);
|
|
194
|
-
} else {
|
|
195
|
-
_transformXAxisLabels();
|
|
196
|
-
}
|
|
197
|
-
const YAxisParams = {
|
|
198
|
-
margins: props.getYDomainMargins ? props.getYDomainMargins(containerHeight) : margins,
|
|
199
|
-
containerWidth,
|
|
200
|
-
containerHeight: containerHeight - _removalValueForTextTuncate,
|
|
201
|
-
yAxisElement: yAxisElement.current,
|
|
202
|
-
yAxisTickFormat: props.yAxisTickFormat,
|
|
203
|
-
yAxisTickCount: props.yAxisTickCount,
|
|
204
|
-
yMinValue: props.yMinValue || 0,
|
|
205
|
-
yMaxValue: props.yMaxValue || 0,
|
|
206
|
-
tickPadding: 10,
|
|
207
|
-
maxOfYVal: props.maxOfYVal,
|
|
208
|
-
yMinMaxValues: props.getMinMaxOfYAxis(points, props.yAxisType),
|
|
209
|
-
// please note these padding default values must be consistent in here
|
|
210
|
-
// and the parent chart(HBWA/Vertical etc..) for more details refer example
|
|
211
|
-
// http://using-d3js.com/04_07_ordinal_scales.html
|
|
212
|
-
yAxisPadding: props.yAxisPadding || 0,
|
|
213
|
-
tickValues: props.yAxisTickValues,
|
|
214
|
-
...props.yAxis
|
|
215
|
-
};
|
|
216
|
-
/**
|
|
217
|
-
* These scales used for 2 purposes.
|
|
218
|
-
* 1. To create x and y axis
|
|
219
|
-
* 2. To draw the graph.
|
|
220
|
-
* For area/line chart using same scales. For other charts, creating their own scales to draw the graph.
|
|
221
|
-
*/ const axisData = {
|
|
222
|
-
yAxisDomainValues: [],
|
|
223
|
-
yAxisTickText: []
|
|
224
|
-
};
|
|
225
|
-
if (props.yAxisType && props.yAxisType === YAxisType.StringAxis) {
|
|
226
|
-
yScalePrimary = props.createStringYAxis(YAxisParams, props.stringDatasetForYAxisDomain, _useRtl, axisData, props.barwidth, props.chartType);
|
|
227
|
-
} else {
|
|
228
|
-
// TODO: Since the scale domain values are now computed independently for both the primary and
|
|
229
|
-
// secondary y-axes, the yMinValue and yMaxValue props are no longer necessary for accurately
|
|
230
|
-
// rendering the secondary y-axis. Therefore, rather than checking the secondaryYScaleOptions
|
|
231
|
-
// prop to determine whether to create a secondary y-axis, it's more appropriate to check if any
|
|
232
|
-
// data points are assigned to use the secondary y-scale.
|
|
233
|
-
if (props === null || props === void 0 ? void 0 : props.secondaryYScaleOptions) {
|
|
234
|
-
var _props_secondaryYScaleOptions, _props_secondaryYScaleOptions1;
|
|
235
|
-
var _props_secondaryYScaleOptions_yMaxValue;
|
|
236
|
-
const YAxisParamsSecondary = {
|
|
237
|
-
margins,
|
|
238
|
-
containerWidth,
|
|
239
|
-
containerHeight: containerHeight - _removalValueForTextTuncate,
|
|
240
|
-
yAxisElement: yAxisElementSecondary.current,
|
|
241
|
-
yAxisTickFormat: props.yAxisTickFormat,
|
|
242
|
-
yAxisTickCount: props.yAxisTickCount,
|
|
243
|
-
yMinValue: ((_props_secondaryYScaleOptions = props.secondaryYScaleOptions) === null || _props_secondaryYScaleOptions === void 0 ? void 0 : _props_secondaryYScaleOptions.yMinValue) || 0,
|
|
244
|
-
yMaxValue: (_props_secondaryYScaleOptions_yMaxValue = (_props_secondaryYScaleOptions1 = props.secondaryYScaleOptions) === null || _props_secondaryYScaleOptions1 === void 0 ? void 0 : _props_secondaryYScaleOptions1.yMaxValue) !== null && _props_secondaryYScaleOptions_yMaxValue !== void 0 ? _props_secondaryYScaleOptions_yMaxValue : 100,
|
|
245
|
-
tickPadding: 10,
|
|
246
|
-
yMinMaxValues: props.getMinMaxOfYAxis(points, props.yAxisType, true),
|
|
247
|
-
yAxisPadding: props.yAxisPadding
|
|
248
|
-
};
|
|
249
|
-
yScaleSecondary = props.createYAxis(YAxisParamsSecondary, _useRtl, axisData, isIntegralDataset, chartType, true, props.roundedTicks, props.secondaryYScaleType, _useRtl);
|
|
250
|
-
}
|
|
251
|
-
yScalePrimary = props.createYAxis(YAxisParams, _useRtl, axisData, isIntegralDataset, chartType, false, props.roundedTicks, props.yScaleType, _useRtl);
|
|
252
|
-
}
|
|
253
|
-
_yAxisTickText.current = axisData.yAxisTickText;
|
|
254
|
-
props.getAxisData && props.getAxisData(axisData);
|
|
255
|
-
// Removing previously created tooltips.
|
|
256
|
-
try {
|
|
257
|
-
// eslint-disable-next-line @nx/workspace-no-restricted-globals
|
|
258
|
-
document.getElementById(_tooltipId) && document.getElementById(_tooltipId).remove();
|
|
259
|
-
// eslint-disable-next-line no-empty
|
|
260
|
-
} catch (e) {}
|
|
261
|
-
// Used to display tooltip at x axis labels.
|
|
262
|
-
if (props.showXAxisLablesTooltip || ((_props_xAxis2 = props.xAxis) === null || _props_xAxis2 === void 0 ? void 0 : _props_xAxis2.tickLayout) === 'auto') {
|
|
263
|
-
const _xAxisElement = xAxisElement.current ? d3Select(xAxisElement.current).call(xScale) : null;
|
|
264
|
-
const tooltipProps = {
|
|
265
|
-
tooltipCls: classes.tooltip,
|
|
266
|
-
id: _tooltipId,
|
|
267
|
-
axis: _xAxisElement,
|
|
268
|
-
container: chartContainer.current
|
|
269
|
-
};
|
|
270
|
-
_xAxisElement && tooltipOfAxislabels(tooltipProps);
|
|
271
|
-
}
|
|
272
|
-
// Used to display tooltip at y axis labels.
|
|
273
|
-
if (props.showYAxisLablesTooltip) {
|
|
274
|
-
// To create y axis tick values by if specified truncating the rest of the text
|
|
275
|
-
// and showing elipsis or showing the whole string,
|
|
276
|
-
yScalePrimary && createYAxisLabels(yAxisElement.current, yScalePrimary, props.noOfCharsToTruncate || 4, props.showYAxisLablesTooltip || false, _useRtl);
|
|
277
|
-
const _yAxisElement = yAxisElement.current ? d3Select(yAxisElement.current).call(yScalePrimary) : null;
|
|
278
|
-
const ytooltipProps = {
|
|
279
|
-
tooltipCls: classes.tooltip,
|
|
280
|
-
id: _tooltipId,
|
|
281
|
-
axis: _yAxisElement,
|
|
282
|
-
container: chartContainer.current
|
|
283
|
-
};
|
|
284
|
-
_yAxisElement && tooltipOfAxislabels(ytooltipProps);
|
|
285
|
-
}
|
|
286
|
-
// Call back to the chart.
|
|
287
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
288
|
-
const _getData = (xScale, yScalePrimary, yScaleSecondary)=>{
|
|
289
|
-
props.getGraphData && props.getGraphData(xScale, yScalePrimary, containerHeight - _removalValueForTextTuncate, containerWidth, xAxisElement.current, yAxisElement.current, yScaleSecondary);
|
|
290
|
-
};
|
|
291
|
-
// Callback function for chart, returns axis
|
|
292
|
-
_getData(xScale, yScalePrimary, yScaleSecondary);
|
|
293
|
-
children = props.children({
|
|
294
|
-
xScale,
|
|
295
|
-
yScalePrimary,
|
|
296
|
-
yScaleSecondary,
|
|
297
|
-
containerHeight,
|
|
298
|
-
containerWidth
|
|
299
|
-
});
|
|
300
|
-
if (!props.hideTooltip && calloutProps.isPopoverOpen) {
|
|
301
|
-
callout = _generateCallout(calloutProps);
|
|
302
|
-
}
|
|
303
|
-
}
|
|
304
|
-
const svgDimensions = {
|
|
305
|
-
width: containerWidth,
|
|
306
|
-
height: containerHeight
|
|
307
|
-
};
|
|
308
|
-
const plotWidth = Math.max(0, svgDimensions.width - margins.left - margins.right);
|
|
309
|
-
const plotHeight = Math.max(0, svgDimensions.height - margins.top - margins.bottom - _removalValueForTextTuncate);
|
|
310
|
-
const plotRect = {
|
|
311
|
-
x: margins.left,
|
|
312
|
-
y: margins.top,
|
|
313
|
-
width: plotWidth,
|
|
314
|
-
height: plotHeight
|
|
315
|
-
};
|
|
316
|
-
var _props_annotations;
|
|
317
|
-
const annotations = (_props_annotations = props.annotations) !== null && _props_annotations !== void 0 ? _props_annotations : [];
|
|
318
|
-
const hasAnnotations = annotations.length > 0;
|
|
319
|
-
const annotationContext = hasAnnotations ? {
|
|
320
|
-
plotRect,
|
|
321
|
-
svgRect: svgDimensions,
|
|
322
|
-
isRtl: _useRtl,
|
|
323
|
-
xScale: _xScale,
|
|
324
|
-
yScalePrimary,
|
|
325
|
-
yScaleSecondary
|
|
326
|
-
} : undefined;
|
|
327
|
-
const xAxisTitleMaxWidth = svgDimensions.width - margins.left - margins.right - AXIS_TITLE_PADDING * 2;
|
|
328
|
-
const yAxisTitleMaxHeight = svgDimensions.height - margins.bottom - margins.top - _removalValueForTextTuncate - AXIS_TITLE_PADDING * 2;
|
|
329
|
-
const yAxisTitleCenterY = margins.top + AXIS_TITLE_PADDING + yAxisTitleMaxHeight / 2;
|
|
330
|
-
const yAxisTitleCenterX = _useRtl ? svgDimensions.width - AXIS_TITLE_PADDING : HORIZONTAL_MARGIN_FOR_YAXIS_TITLE - AXIS_TITLE_PADDING;
|
|
331
|
-
const secondaryYAxisTitleCenterX = _useRtl ? HORIZONTAL_MARGIN_FOR_YAXIS_TITLE - AXIS_TITLE_PADDING : svgDimensions.width - AXIS_TITLE_PADDING;
|
|
332
|
-
const commonSvgToolTipProps = {
|
|
333
|
-
wrapContent,
|
|
334
|
-
showBackground: true,
|
|
335
|
-
className: classes.svgTooltip,
|
|
336
|
-
content: ''
|
|
337
|
-
};
|
|
338
|
-
/**
|
|
339
|
-
* When screen resizes, along with screen, chart also auto adjusted.
|
|
340
|
-
* This method used to adjust height and width of the charts.
|
|
341
|
-
*/ function _fitParentContainer() {
|
|
342
|
-
//_reqID = requestAnimationFrame(() => {
|
|
343
|
-
let legendContainerHeight;
|
|
344
|
-
if (props.hideLegend) {
|
|
345
|
-
// If there is no legend, need not to allocate some space from total chart space.
|
|
346
|
-
legendContainerHeight = 0;
|
|
347
|
-
} else {
|
|
348
|
-
const legendContainerComputedStyles = legendContainer && getComputedStyle(legendContainer);
|
|
349
|
-
legendContainerHeight = (legendContainer && legendContainer.getBoundingClientRect().height || minLegendContainerHeight) + parseFloat(legendContainerComputedStyles && legendContainerComputedStyles.marginTop || '0') + parseFloat(legendContainerComputedStyles && legendContainerComputedStyles.marginBottom || '0');
|
|
350
|
-
}
|
|
351
|
-
if (props.parentRef || chartContainer.current) {
|
|
352
|
-
var _props_reflowProps;
|
|
353
|
-
const container = props.parentRef ? props.parentRef : chartContainer.current;
|
|
354
|
-
const currentContainerWidth = ((_props_reflowProps = props.reflowProps) === null || _props_reflowProps === void 0 ? void 0 : _props_reflowProps.mode) === 'min-width' && !_isFirstRender.current ? Math.max(container.getBoundingClientRect().width, _calculateChartMinWidth()) : container.getBoundingClientRect().width;
|
|
355
|
-
const currentContainerHeight = container.getBoundingClientRect().height > legendContainerHeight ? container.getBoundingClientRect().height : 350;
|
|
356
|
-
const shouldResize = containerWidth !== currentContainerWidth || containerHeight !== currentContainerHeight - legendContainerHeight;
|
|
357
|
-
if (shouldResize) {
|
|
358
|
-
setContainerWidth(currentContainerWidth);
|
|
359
|
-
setContainerHeight(currentContainerHeight - legendContainerHeight);
|
|
360
|
-
}
|
|
361
|
-
}
|
|
362
|
-
//});
|
|
363
|
-
}
|
|
364
|
-
function _onChartLeave() {
|
|
365
|
-
props.onChartMouseLeave && props.onChartMouseLeave();
|
|
366
|
-
}
|
|
367
|
-
function _calculateChartMinWidth() {
|
|
368
|
-
// Adding 10px for padding on both sides
|
|
369
|
-
const labelWidth = _calcMaxLabelWidthWithTransform(_tickLabels) + 10;
|
|
370
|
-
let minChartWidth = margins.left + margins.right + labelWidth * (_tickLabels.length - 1);
|
|
371
|
-
if ([
|
|
372
|
-
ChartTypes.GroupedVerticalBarChart,
|
|
373
|
-
ChartTypes.VerticalBarChart,
|
|
374
|
-
ChartTypes.VerticalStackedBarChart
|
|
375
|
-
].includes(props.chartType)) {
|
|
376
|
-
const minDomainMargin = 8;
|
|
377
|
-
minChartWidth += minDomainMargin * 2;
|
|
378
|
-
}
|
|
379
|
-
return minChartWidth;
|
|
380
|
-
}
|
|
381
|
-
function _getChartDescription() {
|
|
382
|
-
return (props.chartTitle || 'Chart. ') + _getAxisTitle('X', props.xAxisTitle, props.xAxisType) + _getAxisTitle('Y', props.yAxisTitle, props.yAxisType || YAxisType.NumericAxis) + (props.secondaryYScaleOptions ? _getAxisTitle('secondary Y', props.secondaryYAxistitle, YAxisType.NumericAxis) : '');
|
|
383
|
-
}
|
|
384
|
-
function _getAxisTitle(axisLabel, axisTitle, axisType) {
|
|
385
|
-
return `The ${axisLabel} axis displays ` + (axisTitle || (axisType === XAxisTypes.StringAxis || axisType === YAxisType.StringAxis ? 'categories' : axisType === XAxisTypes.DateAxis || axisType === YAxisType.DateAxis ? 'time' : 'values')) + '. ';
|
|
386
|
-
}
|
|
387
|
-
function _calcMaxLabelWidthWithTransform(x) {
|
|
388
|
-
// Case: rotated labels
|
|
389
|
-
if (!props.wrapXAxisLables && props.rotateXAxisLables && props.xAxisType === XAxisTypes.StringAxis) {
|
|
390
|
-
const longestLabelWidth = calculateLongestLabelWidth(x, `.${classes.xAxis} text`);
|
|
391
|
-
return Math.ceil(longestLabelWidth * Math.cos(Math.PI / 4));
|
|
392
|
-
}
|
|
393
|
-
// Case: truncated labels
|
|
394
|
-
if (props.showXAxisLablesTooltip) {
|
|
395
|
-
const tickLabels = x.map((val)=>{
|
|
396
|
-
const numChars = props.noOfCharsToTruncate || 4;
|
|
397
|
-
return val.toString().length > numChars ? `${val.toString().slice(0, numChars)}...` : val;
|
|
398
|
-
});
|
|
399
|
-
const longestLabelWidth = calculateLongestLabelWidth(tickLabels, `.${classes.xAxis} text`);
|
|
400
|
-
return Math.ceil(longestLabelWidth);
|
|
401
|
-
}
|
|
402
|
-
// Case: wrapped labels
|
|
403
|
-
if (props.wrapXAxisLables) {
|
|
404
|
-
// FIXME: Calculate the max width of lines instead of words. This requires applying
|
|
405
|
-
// the wrapping transformation earlier to obtain the actual rendered lines.
|
|
406
|
-
const words = [];
|
|
407
|
-
x.forEach((val)=>{
|
|
408
|
-
words.push(...val.toString().split(/\s+/));
|
|
409
|
-
});
|
|
410
|
-
// This approach works well in most cases, since overflow typically occurs only when
|
|
411
|
-
// a single word exceeds the specified width — otherwise, the text will wrap as expected.
|
|
412
|
-
const longestLabelWidth = calculateLongestLabelWidth(words, `.${classes.xAxis} text`);
|
|
413
|
-
return Math.max(Math.ceil(longestLabelWidth), DEFAULT_WRAP_WIDTH);
|
|
414
|
-
}
|
|
415
|
-
// Default case
|
|
416
|
-
const longestLabelWidth = calculateLongestLabelWidth(x, `.${classes.xAxis} text`);
|
|
417
|
-
return Math.ceil(longestLabelWidth);
|
|
418
|
-
}
|
|
419
|
-
function _transformXAxisLabels() {
|
|
420
|
-
_removalValueForTextTuncate = 0;
|
|
421
|
-
/*
|
|
422
|
-
* To enable wrapping of x axis tick values or to display complete x axis tick values,
|
|
423
|
-
* we need to calculate how much space it needed to render the text.
|
|
424
|
-
* No need to re-calculate every time the chart renders and same time need to get an update. So using setState.
|
|
425
|
-
* Required space will be calculated first time chart rendering and if any width/height of chart updated.
|
|
426
|
-
* */ if (props.wrapXAxisLables || props.showXAxisLablesTooltip) {
|
|
427
|
-
let maxXAxisLabelWidth;
|
|
428
|
-
if (props.xAxisType === XAxisTypes.StringAxis) {
|
|
429
|
-
var _props_datasetForXAxisDomain;
|
|
430
|
-
if ((((_props_datasetForXAxisDomain = props.datasetForXAxisDomain) === null || _props_datasetForXAxisDomain === void 0 ? void 0 : _props_datasetForXAxisDomain.length) || 0) > 1) {
|
|
431
|
-
maxXAxisLabelWidth = _xScale.step();
|
|
432
|
-
} else {
|
|
433
|
-
maxXAxisLabelWidth = containerWidth;
|
|
434
|
-
}
|
|
435
|
-
}
|
|
436
|
-
const wrapLabelProps = {
|
|
437
|
-
node: xAxisElement.current,
|
|
438
|
-
xAxis: _xScale,
|
|
439
|
-
showXAxisLablesTooltip: props.showXAxisLablesTooltip || false,
|
|
440
|
-
noOfCharsToTruncate: props.noOfCharsToTruncate || 4,
|
|
441
|
-
width: maxXAxisLabelWidth,
|
|
442
|
-
container: chartContainer.current
|
|
443
|
-
};
|
|
444
|
-
var _createWrapOfXLabels;
|
|
445
|
-
_removalValueForTextTuncate = (_createWrapOfXLabels = createWrapOfXLabels(wrapLabelProps)) !== null && _createWrapOfXLabels !== void 0 ? _createWrapOfXLabels : 0;
|
|
446
|
-
}
|
|
447
|
-
if (!props.wrapXAxisLables && props.rotateXAxisLables && props.xAxisType === XAxisTypes.StringAxis) {
|
|
448
|
-
const rotateLabelProps = {
|
|
449
|
-
node: xAxisElement.current,
|
|
450
|
-
xAxis: _xScale
|
|
451
|
-
};
|
|
452
|
-
var _rotateXAxisLabels;
|
|
453
|
-
const rotatedHeight = (_rotateXAxisLabels = rotateXAxisLabels(rotateLabelProps)) !== null && _rotateXAxisLabels !== void 0 ? _rotateXAxisLabels : 0;
|
|
454
|
-
// margins.bottom is used as padding here
|
|
455
|
-
_removalValueForTextTuncate = rotatedHeight + margins.bottom;
|
|
456
|
-
}
|
|
457
|
-
}
|
|
458
|
-
function _calcMargins() {
|
|
459
|
-
let _margins = _getDefaultMargins();
|
|
460
|
-
_margins = _applyTitleMargins(_margins);
|
|
461
|
-
_margins = _applyAnnotationMargins(_margins);
|
|
462
|
-
if (_useRtl) {
|
|
463
|
-
_margins = _swapRtlMargins(_margins);
|
|
464
|
-
}
|
|
465
|
-
return {
|
|
466
|
-
..._margins,
|
|
467
|
-
...props.margins
|
|
468
|
-
};
|
|
469
|
-
}
|
|
470
|
-
function _getDefaultMargins() {
|
|
471
|
-
return {
|
|
472
|
-
top: DEFAULT_MARGIN_NO_TICKS,
|
|
473
|
-
// Smaller than the default because it is based on the line height rather than
|
|
474
|
-
// the length of the tick labels.
|
|
475
|
-
bottom: DEFAULT_MARGIN_WITH_TICKS - 5,
|
|
476
|
-
// For the actual margin, add the tick size, tick padding, and some extra space to
|
|
477
|
-
// the width of the longest yaxis tick label (startFromX).
|
|
478
|
-
left: Math.max(DEFAULT_MARGIN_WITH_TICKS, startFromX + 20),
|
|
479
|
-
right: props.secondaryYScaleOptions ? DEFAULT_MARGIN_WITH_TICKS : DEFAULT_MARGIN_NO_TICKS
|
|
480
|
-
};
|
|
481
|
-
}
|
|
482
|
-
function _applyTitleMargins(_margins) {
|
|
483
|
-
const updated = {
|
|
484
|
-
..._margins
|
|
485
|
-
};
|
|
486
|
-
if (props.xAxisTitle !== undefined && props.xAxisTitle !== '') {
|
|
487
|
-
updated.bottom += VERTICAL_MARGIN_FOR_XAXIS_TITLE;
|
|
488
|
-
}
|
|
489
|
-
if (props.yAxisTitle !== undefined && props.yAxisTitle !== '') {
|
|
490
|
-
updated.left += HORIZONTAL_MARGIN_FOR_YAXIS_TITLE;
|
|
491
|
-
}
|
|
492
|
-
if (props.secondaryYAxistitle !== undefined && props.secondaryYAxistitle !== '') {
|
|
493
|
-
updated.right += HORIZONTAL_MARGIN_FOR_YAXIS_TITLE;
|
|
494
|
-
}
|
|
495
|
-
return updated;
|
|
496
|
-
}
|
|
497
|
-
function _applyAnnotationMargins(_margins) {
|
|
498
|
-
const updated = {
|
|
499
|
-
..._margins
|
|
500
|
-
};
|
|
501
|
-
if (props.xAxisAnnotation !== undefined && props.xAxisAnnotation !== '') {
|
|
502
|
-
updated.top += VERTICAL_MARGIN_FOR_XAXIS_TITLE;
|
|
503
|
-
}
|
|
504
|
-
if (props.yAxisAnnotation !== undefined && props.yAxisAnnotation !== '' && (props.secondaryYAxistitle === undefined || props.secondaryYAxistitle === '')) {
|
|
505
|
-
updated.right += HORIZONTAL_MARGIN_FOR_YAXIS_TITLE;
|
|
506
|
-
}
|
|
507
|
-
return updated;
|
|
508
|
-
}
|
|
509
|
-
function _swapRtlMargins(_margins) {
|
|
510
|
-
return {
|
|
511
|
-
..._margins,
|
|
512
|
-
left: _margins.right,
|
|
513
|
-
right: _margins.left
|
|
514
|
-
};
|
|
515
|
-
}
|
|
516
|
-
/**
|
|
517
|
-
* We have use the {@link defaultTabbableElement } to fix
|
|
518
|
-
* the Focus not landing on chart while tabbing, instead goes to legend.
|
|
519
|
-
* This issue is observed in Area, line chart after performance optimization done in the PR {@link https://github.com/microsoft/fluentui/pull/27721 }
|
|
520
|
-
* This issue is observed in Bar charts after the changes done by FocusZone team in the PR: {@link https://github.com/microsoft/fluentui/pull/24175 }
|
|
521
|
-
* The issue in Bar Charts(VB and VSB) is due to a {@link FocusZone } update where previously an event listener was
|
|
522
|
-
* attached on keydown to the window, so that whenever the tab key is pressed all outer FocusZone's
|
|
523
|
-
* tab-indexes are updated (an outer FocusZone is a FocusZone that is not within another one).
|
|
524
|
-
* But now after the above PR : they are attaching the
|
|
525
|
-
* listeners to the FocusZone elements instead of the window. So in the first render cycle in Bar charts
|
|
526
|
-
* bars are not created as in the first render cycle the size of the chart container is not known( or is 0)
|
|
527
|
-
* which creates bars of height 0 so instead we do not create any bars and instead return empty fragments.
|
|
528
|
-
*
|
|
529
|
-
* We have tried 2 Approaches to fix the issue:
|
|
530
|
-
* 1. Using the {@link elementRef} property of FocusZone where we dispatch event for tab keydown
|
|
531
|
-
* after the second render cycle which triggers an update of the tab index in FocusZone.
|
|
532
|
-
* But this is a hacky solution and not a proper fix and also elementRef is deprecated.
|
|
533
|
-
* 2. Using the default tabbable element to fix the issue.
|
|
534
|
-
*/ return /*#__PURE__*/ React.createElement("div", {
|
|
535
|
-
id: idForGraph,
|
|
536
|
-
className: classes.root,
|
|
537
|
-
role: 'presentation',
|
|
538
|
-
ref: (rootElem)=>{
|
|
539
|
-
chartContainer.current = rootElem;
|
|
540
|
-
},
|
|
541
|
-
onMouseLeave: _onChartLeave
|
|
542
|
-
}, /*#__PURE__*/ React.createElement("div", {
|
|
543
|
-
className: classes.chartWrapper,
|
|
544
|
-
...focusAttributes,
|
|
545
|
-
...arrowAttributes
|
|
546
|
-
}, _isFirstRender.current, /*#__PURE__*/ React.createElement("svg", {
|
|
547
|
-
width: svgDimensions.width,
|
|
548
|
-
height: svgDimensions.height,
|
|
549
|
-
role: "region",
|
|
550
|
-
"aria-label": _getChartDescription(),
|
|
551
|
-
style: {
|
|
552
|
-
display: 'block'
|
|
553
|
-
},
|
|
554
|
-
className: classes.chart,
|
|
555
|
-
...getSecureProps(svgProps)
|
|
556
|
-
}, /*#__PURE__*/ React.createElement("g", {
|
|
557
|
-
ref: (e)=>{
|
|
558
|
-
xAxisElement.current = e;
|
|
559
|
-
},
|
|
560
|
-
id: `xAxisGElement${idForGraph}`,
|
|
561
|
-
// To add wrap of x axis lables feature, need to remove word height from svg height.
|
|
562
|
-
transform: `translate(0, ${svgDimensions.height - margins.bottom - _removalValueForTextTuncate})`,
|
|
563
|
-
className: classes.xAxis
|
|
564
|
-
}), props.xAxisTitle !== undefined && props.xAxisTitle !== '' && /*#__PURE__*/ React.createElement(SVGTooltipText, {
|
|
565
|
-
...commonSvgToolTipProps,
|
|
566
|
-
content: props.xAxisTitle,
|
|
567
|
-
textProps: {
|
|
568
|
-
x: margins.left + AXIS_TITLE_PADDING + xAxisTitleMaxWidth / 2,
|
|
569
|
-
y: svgDimensions.height - AXIS_TITLE_PADDING,
|
|
570
|
-
className: classes.axisTitle,
|
|
571
|
-
textAnchor: 'middle'
|
|
572
|
-
},
|
|
573
|
-
maxWidth: xAxisTitleMaxWidth
|
|
574
|
-
}), props.xAxisAnnotation !== undefined && props.xAxisAnnotation !== '' && (()=>{
|
|
575
|
-
var _props_titleStyles;
|
|
576
|
-
const { titleFont, titleXAnchor, titleYAnchor, titlePad } = (_props_titleStyles = props.titleStyles) !== null && _props_titleStyles !== void 0 ? _props_titleStyles : {};
|
|
577
|
-
const fontSize = typeof (titleFont === null || titleFont === void 0 ? void 0 : titleFont.size) === 'number' ? titleFont.size : 13;
|
|
578
|
-
var _titlePad_l;
|
|
579
|
-
const padL = (_titlePad_l = titlePad === null || titlePad === void 0 ? void 0 : titlePad.l) !== null && _titlePad_l !== void 0 ? _titlePad_l : 0;
|
|
580
|
-
var _titlePad_r;
|
|
581
|
-
const padR = (_titlePad_r = titlePad === null || titlePad === void 0 ? void 0 : titlePad.r) !== null && _titlePad_r !== void 0 ? _titlePad_r : 0;
|
|
582
|
-
var _titlePad_t;
|
|
583
|
-
const padT = (_titlePad_t = titlePad === null || titlePad === void 0 ? void 0 : titlePad.t) !== null && _titlePad_t !== void 0 ? _titlePad_t : 0;
|
|
584
|
-
var _titlePad_b;
|
|
585
|
-
const padB = (_titlePad_b = titlePad === null || titlePad === void 0 ? void 0 : titlePad.b) !== null && _titlePad_b !== void 0 ? _titlePad_b : 0;
|
|
586
|
-
const xPos = (titleXAnchor === 'left' ? margins.left + AXIS_TITLE_PADDING : titleXAnchor === 'right' ? margins.left + AXIS_TITLE_PADDING + xAxisTitleMaxWidth : margins.left + AXIS_TITLE_PADDING + xAxisTitleMaxWidth / 2) + padL - padR;
|
|
587
|
-
const yPos = Math.max(fontSize + AXIS_TITLE_PADDING, VERTICAL_MARGIN_FOR_XAXIS_TITLE - AXIS_TITLE_PADDING) + padT - padB;
|
|
588
|
-
const textAnchor = titleXAnchor === 'left' ? 'start' : titleXAnchor === 'right' ? 'end' : 'middle';
|
|
589
|
-
const dominantBaseline = titleYAnchor === 'top' ? 'hanging' : titleYAnchor === 'bottom' ? 'alphabetic' : titleYAnchor === 'middle' ? 'central' : 'auto';
|
|
590
|
-
return /*#__PURE__*/ React.createElement(SVGTooltipText, {
|
|
591
|
-
...commonSvgToolTipProps,
|
|
592
|
-
content: props.xAxisAnnotation,
|
|
593
|
-
textProps: {
|
|
594
|
-
x: xPos,
|
|
595
|
-
y: yPos,
|
|
596
|
-
className: classes.axisAnnotation,
|
|
597
|
-
textAnchor,
|
|
598
|
-
dominantBaseline,
|
|
599
|
-
'aria-hidden': true,
|
|
600
|
-
style: getChartTitleInlineStyles(titleFont)
|
|
601
|
-
},
|
|
602
|
-
maxWidth: xAxisTitleMaxWidth
|
|
603
|
-
});
|
|
604
|
-
})(), /*#__PURE__*/ React.createElement("g", {
|
|
605
|
-
ref: (e)=>{
|
|
606
|
-
yAxisElement.current = e;
|
|
607
|
-
},
|
|
608
|
-
id: `yAxisGElement${idForGraph}`,
|
|
609
|
-
transform: `translate(${_useRtl ? svgDimensions.width - margins.right : margins.left}, 0)`,
|
|
610
|
-
className: classes.yAxis
|
|
611
|
-
}), props.secondaryYScaleOptions && /*#__PURE__*/ React.createElement("g", null, /*#__PURE__*/ React.createElement("g", {
|
|
612
|
-
ref: (e)=>{
|
|
613
|
-
yAxisElementSecondary.current = e;
|
|
614
|
-
},
|
|
615
|
-
id: `yAxisGElementSecondary${idForGraph}`,
|
|
616
|
-
transform: `translate(${_useRtl ? margins.left : svgDimensions.width - margins.right}, 0)`,
|
|
617
|
-
className: classes.yAxis
|
|
618
|
-
}), props.secondaryYAxistitle !== undefined && props.secondaryYAxistitle !== '' && /*#__PURE__*/ React.createElement(SVGTooltipText, {
|
|
619
|
-
...commonSvgToolTipProps,
|
|
620
|
-
content: props.secondaryYAxistitle,
|
|
621
|
-
textProps: {
|
|
622
|
-
x: secondaryYAxisTitleCenterX,
|
|
623
|
-
y: yAxisTitleCenterY,
|
|
624
|
-
textAnchor: 'middle',
|
|
625
|
-
transform: `rotate(-90, ${secondaryYAxisTitleCenterX}, ${yAxisTitleCenterY})`,
|
|
626
|
-
className: classes.axisTitle
|
|
627
|
-
},
|
|
628
|
-
maxWidth: yAxisTitleMaxHeight
|
|
629
|
-
})), children, props.yAxisTitle !== undefined && props.yAxisTitle !== '' && /*#__PURE__*/ React.createElement(SVGTooltipText, {
|
|
630
|
-
...commonSvgToolTipProps,
|
|
631
|
-
content: props.yAxisTitle,
|
|
632
|
-
textProps: {
|
|
633
|
-
x: yAxisTitleCenterX,
|
|
634
|
-
y: yAxisTitleCenterY,
|
|
635
|
-
textAnchor: 'middle',
|
|
636
|
-
transform: `rotate(-90, ${yAxisTitleCenterX}, ${yAxisTitleCenterY})`,
|
|
637
|
-
className: classes.axisTitle
|
|
638
|
-
},
|
|
639
|
-
maxWidth: yAxisTitleMaxHeight
|
|
640
|
-
}), props.yAxisAnnotation !== undefined && props.yAxisAnnotation !== '' && (props.secondaryYAxistitle === undefined || props.secondaryYAxistitle === '') && /*#__PURE__*/ React.createElement(SVGTooltipText, {
|
|
641
|
-
...commonSvgToolTipProps,
|
|
642
|
-
content: props.yAxisAnnotation,
|
|
643
|
-
textProps: {
|
|
644
|
-
x: secondaryYAxisTitleCenterX,
|
|
645
|
-
y: yAxisTitleCenterY,
|
|
646
|
-
textAnchor: 'middle',
|
|
647
|
-
transform: `rotate(-90, ${secondaryYAxisTitleCenterX}, ${yAxisTitleCenterY})`,
|
|
648
|
-
className: classes.axisAnnotation,
|
|
649
|
-
'aria-hidden': true
|
|
650
|
-
},
|
|
651
|
-
maxWidth: yAxisTitleMaxHeight
|
|
652
|
-
})), hasAnnotations && annotationContext && /*#__PURE__*/ React.createElement(ChartAnnotationLayer, {
|
|
653
|
-
annotations: annotations,
|
|
654
|
-
context: annotationContext,
|
|
655
|
-
className: classes.annotationLayer
|
|
656
|
-
})), !props.hideLegend && /*#__PURE__*/ React.createElement("div", {
|
|
657
|
-
ref: (e)=>{
|
|
658
|
-
legendContainer = e;
|
|
659
|
-
},
|
|
660
|
-
className: classes.legendContainer
|
|
661
|
-
}, props.legendBars), callout && /*#__PURE__*/ React.createElement(React.Suspense, {
|
|
662
|
-
fallback: /*#__PURE__*/ React.createElement("div", null, "Loading...")
|
|
663
|
-
}, callout));
|
|
664
|
-
});
|
|
665
|
-
CartesianChart.displayName = 'CartesianChart';
|