@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,356 +0,0 @@
|
|
|
1
|
-
'use client';
|
|
2
|
-
"use strict";
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
Object.defineProperty(exports, "DonutChart", {
|
|
7
|
-
enumerable: true,
|
|
8
|
-
get: function() {
|
|
9
|
-
return DonutChart;
|
|
10
|
-
}
|
|
11
|
-
});
|
|
12
|
-
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
|
13
|
-
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
|
14
|
-
const _index = require("./Pie/index");
|
|
15
|
-
const _useDonutChartStylesstyles = require("./useDonutChartStyles.styles");
|
|
16
|
-
const _chartutilities = require("@fluentui/chart-utilities");
|
|
17
|
-
const _index1 = require("../../utilities/index");
|
|
18
|
-
const _index2 = require("../../index");
|
|
19
|
-
const _reactutilities = require("@fluentui/react-utilities");
|
|
20
|
-
const _reacttabster = require("@fluentui/react-tabster");
|
|
21
|
-
const _ChartPopover = require("../CommonComponents/ChartPopover");
|
|
22
|
-
const _hooks = require("../../utilities/hooks");
|
|
23
|
-
const MIN_LEGEND_CONTAINER_HEIGHT = 40;
|
|
24
|
-
const DonutChart = /*#__PURE__*/ _react.forwardRef(({ innerRadius = 0, hideLabels = true, ...restProps }, forwardedRef)=>{
|
|
25
|
-
var _props_legendProps;
|
|
26
|
-
const props = {
|
|
27
|
-
innerRadius,
|
|
28
|
-
hideLabels,
|
|
29
|
-
...restProps
|
|
30
|
-
};
|
|
31
|
-
const { chartContainerRef: _rootElem, legendsRef: _legendsRef } = (0, _hooks.useImageExport)(props.componentRef, props.hideLegend, false);
|
|
32
|
-
const _uniqText = (0, _reactutilities.useId)('_Pie_');
|
|
33
|
-
let _calloutAnchorPoint;
|
|
34
|
-
let _emptyChartId;
|
|
35
|
-
const legendContainer = _react.useRef(null);
|
|
36
|
-
const prevSize = _react.useRef({});
|
|
37
|
-
const [value, setValue] = _react.useState('');
|
|
38
|
-
const [legend, setLegend] = _react.useState('');
|
|
39
|
-
const [_width, setWidth] = _react.useState(props.width || 200);
|
|
40
|
-
const [_height, setHeight] = _react.useState(props.height || 200);
|
|
41
|
-
const [activeLegend, setActiveLegend] = _react.useState(undefined);
|
|
42
|
-
const [color, setColor] = _react.useState('');
|
|
43
|
-
const [xCalloutValue, setXCalloutValue] = _react.useState('');
|
|
44
|
-
const [yCalloutValue, setYCalloutValue] = _react.useState('');
|
|
45
|
-
const [selectedLegends, setSelectedLegends] = _react.useState(((_props_legendProps = props.legendProps) === null || _props_legendProps === void 0 ? void 0 : _props_legendProps.selectedLegends) || []);
|
|
46
|
-
const [focusedArcId, setFocusedArcId] = _react.useState('');
|
|
47
|
-
const [dataPointCalloutProps, setDataPointCalloutProps] = _react.useState();
|
|
48
|
-
const [refSelected, setRefSelected] = _react.useState(null);
|
|
49
|
-
const [isPopoverOpen, setPopoverOpen] = _react.useState(false);
|
|
50
|
-
const prevPropsRef = _react.useRef(null);
|
|
51
|
-
_react.useEffect(()=>{
|
|
52
|
-
_fitParentContainer();
|
|
53
|
-
}, []);
|
|
54
|
-
_react.useEffect(()=>{
|
|
55
|
-
if (prevPropsRef.current) {
|
|
56
|
-
var _prevProps_legendProps, _props_legendProps;
|
|
57
|
-
const prevProps = prevPropsRef.current;
|
|
58
|
-
if (!(0, _index1.areArraysEqual)((_prevProps_legendProps = prevProps.legendProps) === null || _prevProps_legendProps === void 0 ? void 0 : _prevProps_legendProps.selectedLegends, (_props_legendProps = props.legendProps) === null || _props_legendProps === void 0 ? void 0 : _props_legendProps.selectedLegends)) {
|
|
59
|
-
var _props_legendProps1;
|
|
60
|
-
setSelectedLegends(((_props_legendProps1 = props.legendProps) === null || _props_legendProps1 === void 0 ? void 0 : _props_legendProps1.selectedLegends) || []);
|
|
61
|
-
}
|
|
62
|
-
}
|
|
63
|
-
prevPropsRef.current = props;
|
|
64
|
-
}, [
|
|
65
|
-
props
|
|
66
|
-
]);
|
|
67
|
-
_react.useEffect(()=>{
|
|
68
|
-
if (prevSize.current.height !== props.height || prevSize.current.width !== props.width) {
|
|
69
|
-
_fitParentContainer();
|
|
70
|
-
}
|
|
71
|
-
prevSize.current.height = props.height;
|
|
72
|
-
prevSize.current.width = props.width;
|
|
73
|
-
}, [
|
|
74
|
-
props.width,
|
|
75
|
-
props.height
|
|
76
|
-
]);
|
|
77
|
-
function _elevateToMinimums(data) {
|
|
78
|
-
let sumOfData = 0;
|
|
79
|
-
const minPercent = 0.01;
|
|
80
|
-
const elevatedData = [];
|
|
81
|
-
data.forEach((item)=>{
|
|
82
|
-
sumOfData += item.data;
|
|
83
|
-
});
|
|
84
|
-
data.forEach((item)=>{
|
|
85
|
-
elevatedData.push(minPercent * sumOfData > item.data && item.data > 0 ? {
|
|
86
|
-
...item,
|
|
87
|
-
data: minPercent * sumOfData,
|
|
88
|
-
yAxisCalloutData: item.yAxisCalloutData === undefined ? item.data.toLocaleString() : item.yAxisCalloutData
|
|
89
|
-
} : item);
|
|
90
|
-
});
|
|
91
|
-
return elevatedData;
|
|
92
|
-
}
|
|
93
|
-
function _createLegends(chartData) {
|
|
94
|
-
if (props.order === 'sorted') {
|
|
95
|
-
chartData.sort((a, b)=>{
|
|
96
|
-
return b.data - a.data;
|
|
97
|
-
});
|
|
98
|
-
}
|
|
99
|
-
const legendDataItems = chartData.map((point, index)=>{
|
|
100
|
-
const color = point.color;
|
|
101
|
-
// mapping data to the format Legends component needs
|
|
102
|
-
const legend = {
|
|
103
|
-
title: point.legend,
|
|
104
|
-
color,
|
|
105
|
-
hoverAction: ()=>{
|
|
106
|
-
_handleChartMouseLeave();
|
|
107
|
-
setActiveLegend(point.legend);
|
|
108
|
-
},
|
|
109
|
-
onMouseOutAction: ()=>{
|
|
110
|
-
setActiveLegend(undefined);
|
|
111
|
-
}
|
|
112
|
-
};
|
|
113
|
-
return legend;
|
|
114
|
-
});
|
|
115
|
-
const legends = /*#__PURE__*/ _react.createElement(_index2.Legends, {
|
|
116
|
-
legends: legendDataItems,
|
|
117
|
-
centerLegends: true,
|
|
118
|
-
overflowText: props.legendsOverflowText,
|
|
119
|
-
...props.legendProps,
|
|
120
|
-
onChange: _onLegendSelectionChange,
|
|
121
|
-
legendRef: _legendsRef
|
|
122
|
-
});
|
|
123
|
-
return legends;
|
|
124
|
-
}
|
|
125
|
-
function _onLegendSelectionChange(selectedLegends, event, currentLegend) {
|
|
126
|
-
var _props_legendProps, _props_legendProps1;
|
|
127
|
-
if (props.legendProps && ((_props_legendProps = props.legendProps) === null || _props_legendProps === void 0 ? void 0 : _props_legendProps.canSelectMultipleLegends)) {
|
|
128
|
-
setSelectedLegends(selectedLegends);
|
|
129
|
-
} else {
|
|
130
|
-
setSelectedLegends(selectedLegends.slice(-1));
|
|
131
|
-
}
|
|
132
|
-
if ((_props_legendProps1 = props.legendProps) === null || _props_legendProps1 === void 0 ? void 0 : _props_legendProps1.onChange) {
|
|
133
|
-
props.legendProps.onChange(selectedLegends, event, currentLegend);
|
|
134
|
-
}
|
|
135
|
-
}
|
|
136
|
-
function _focusCallback(data, id, e, targetElement) {
|
|
137
|
-
setPopoverOpen(_noLegendsHighlighted() || _isLegendHighlighted(data.legend));
|
|
138
|
-
setValue(data.data.toString());
|
|
139
|
-
setLegend(data.legend);
|
|
140
|
-
setColor(data.color);
|
|
141
|
-
setXCalloutValue(data.xAxisCalloutData);
|
|
142
|
-
setYCalloutValue(data.yAxisCalloutData);
|
|
143
|
-
setFocusedArcId(id);
|
|
144
|
-
setDataPointCalloutProps(data);
|
|
145
|
-
setRefSelected(targetElement);
|
|
146
|
-
}
|
|
147
|
-
function _hoverCallback(data, e, targetElement) {
|
|
148
|
-
if (_calloutAnchorPoint !== data) {
|
|
149
|
-
_calloutAnchorPoint = data;
|
|
150
|
-
setPopoverOpen(_noLegendsHighlighted() || _isLegendHighlighted(data.legend));
|
|
151
|
-
setValue(data.data.toString());
|
|
152
|
-
setLegend(data.legend);
|
|
153
|
-
setColor(data.color);
|
|
154
|
-
setXCalloutValue(data.xAxisCalloutData);
|
|
155
|
-
setYCalloutValue(data.yAxisCalloutData);
|
|
156
|
-
setDataPointCalloutProps(data);
|
|
157
|
-
setRefSelected(targetElement);
|
|
158
|
-
}
|
|
159
|
-
}
|
|
160
|
-
function _onBlur() {
|
|
161
|
-
setFocusedArcId('');
|
|
162
|
-
}
|
|
163
|
-
function _hoverLeave() {
|
|
164
|
-
/**/ }
|
|
165
|
-
function _handleChartMouseLeave() {
|
|
166
|
-
_calloutAnchorPoint = null;
|
|
167
|
-
setPopoverOpen(false);
|
|
168
|
-
}
|
|
169
|
-
function _valueInsideDonut(valueInsideDonut, data) {
|
|
170
|
-
const highlightedLegends = _getHighlightedLegend();
|
|
171
|
-
if (valueInsideDonut !== undefined && (highlightedLegends.length === 1 || isPopoverOpen)) {
|
|
172
|
-
const pointValue = data.find((point)=>_isLegendHighlighted(point.legend));
|
|
173
|
-
return pointValue ? pointValue.yAxisCalloutData ? pointValue.yAxisCalloutData : pointValue.data : valueInsideDonut;
|
|
174
|
-
} else if (highlightedLegends.length > 0) {
|
|
175
|
-
let totalValue = 0;
|
|
176
|
-
data.forEach((point)=>{
|
|
177
|
-
if (highlightedLegends.includes(point.legend)) {
|
|
178
|
-
totalValue += point.data;
|
|
179
|
-
}
|
|
180
|
-
});
|
|
181
|
-
return totalValue;
|
|
182
|
-
} else {
|
|
183
|
-
return valueInsideDonut;
|
|
184
|
-
}
|
|
185
|
-
}
|
|
186
|
-
function _toLocaleString(data) {
|
|
187
|
-
const localeString = (0, _chartutilities.formatToLocaleString)(data, props.culture);
|
|
188
|
-
if (!localeString) {
|
|
189
|
-
return data;
|
|
190
|
-
}
|
|
191
|
-
return localeString === null || localeString === void 0 ? void 0 : localeString.toString();
|
|
192
|
-
}
|
|
193
|
-
/**
|
|
194
|
-
* This function returns
|
|
195
|
-
* the selected legend if there is one
|
|
196
|
-
* or the hovered legend if none of the legends is selected.
|
|
197
|
-
*/ function _getHighlightedLegend() {
|
|
198
|
-
return selectedLegends.length > 0 ? selectedLegends : activeLegend ? [
|
|
199
|
-
activeLegend
|
|
200
|
-
] : [];
|
|
201
|
-
}
|
|
202
|
-
function _isLegendHighlighted(legend) {
|
|
203
|
-
return _getHighlightedLegend().includes(legend);
|
|
204
|
-
}
|
|
205
|
-
function _noLegendsHighlighted() {
|
|
206
|
-
return _getHighlightedLegend().length === 0;
|
|
207
|
-
}
|
|
208
|
-
function _isChartEmpty() {
|
|
209
|
-
return !(props.data && props.data.chartData && props.data.chartData.filter((d)=>d.data > 0).length > 0);
|
|
210
|
-
}
|
|
211
|
-
function _addDefaultColors(donutChartDataPoint) {
|
|
212
|
-
return donutChartDataPoint ? donutChartDataPoint.map((item, index)=>{
|
|
213
|
-
let defaultColor;
|
|
214
|
-
if (typeof item.color === 'undefined') {
|
|
215
|
-
defaultColor = (0, _index1.getNextColor)(index, 0);
|
|
216
|
-
} else {
|
|
217
|
-
defaultColor = (0, _index1.getColorFromToken)(item.color);
|
|
218
|
-
}
|
|
219
|
-
return {
|
|
220
|
-
...item,
|
|
221
|
-
defaultColor
|
|
222
|
-
};
|
|
223
|
-
}) : [];
|
|
224
|
-
}
|
|
225
|
-
/**
|
|
226
|
-
* Computes the vertical space the chart title occupies above the donut.
|
|
227
|
-
* Kept in sync with the title rendered inside the SVG so that
|
|
228
|
-
* `_fitParentContainer` can reserve this space when sizing the chart.
|
|
229
|
-
*/ function _getTitleHeight() {
|
|
230
|
-
var _props_data, _props_titleStyles_titleFont, _props_titleStyles;
|
|
231
|
-
return ((_props_data = props.data) === null || _props_data === void 0 ? void 0 : _props_data.chartTitle) ? Math.max((typeof ((_props_titleStyles = props.titleStyles) === null || _props_titleStyles === void 0 ? void 0 : (_props_titleStyles_titleFont = _props_titleStyles.titleFont) === null || _props_titleStyles_titleFont === void 0 ? void 0 : _props_titleStyles_titleFont.size) === 'number' ? props.titleStyles.titleFont.size : 13) + _index1.CHART_TITLE_PADDING, 36) : 0;
|
|
232
|
-
}
|
|
233
|
-
/**
|
|
234
|
-
* When screen resizes, along with screen, chart also auto adjusted.
|
|
235
|
-
* This method used to adjust height and width of the charts.
|
|
236
|
-
*/ function _fitParentContainer() {
|
|
237
|
-
//_reqID = requestAnimationFrame(() => {
|
|
238
|
-
let legendContainerHeight;
|
|
239
|
-
if (props.hideLegend) {
|
|
240
|
-
// If there is no legend, need not to allocate some space from total chart space.
|
|
241
|
-
legendContainerHeight = 0;
|
|
242
|
-
} else {
|
|
243
|
-
const legendContainerComputedStyles = legendContainer.current && getComputedStyle(legendContainer.current);
|
|
244
|
-
legendContainerHeight = (legendContainer.current && legendContainer.current.getBoundingClientRect().height || MIN_LEGEND_CONTAINER_HEIGHT) + parseFloat(legendContainerComputedStyles && legendContainerComputedStyles.marginTop || '0') + parseFloat(legendContainerComputedStyles && legendContainerComputedStyles.marginBottom || '0');
|
|
245
|
-
}
|
|
246
|
-
if (props.parentRef || _rootElem.current) {
|
|
247
|
-
const container = props.parentRef ? props.parentRef : _rootElem.current;
|
|
248
|
-
const currentContainerWidth = container.getBoundingClientRect().width;
|
|
249
|
-
const currentContainerHeight = container.getBoundingClientRect().height > legendContainerHeight ? container.getBoundingClientRect().height : 200;
|
|
250
|
-
// The SVG is rendered `titleHeight / 2` taller than `_height` (see the `height` attribute below)
|
|
251
|
-
// to fit the title. Reserve that space here so the total rendered content never exceeds the
|
|
252
|
-
// measured container height. Otherwise, when the container height is unconstrained (e.g. an
|
|
253
|
-
// auto-height parent), the extra pixels feed back into the ResizeObserver and the chart grows
|
|
254
|
-
// on every frame in an infinite loop.
|
|
255
|
-
const availableHeight = currentContainerHeight - legendContainerHeight - _getTitleHeight() / 2;
|
|
256
|
-
const shouldResize = _width !== currentContainerWidth || _height !== availableHeight;
|
|
257
|
-
if (shouldResize) {
|
|
258
|
-
setWidth(currentContainerWidth);
|
|
259
|
-
setHeight(availableHeight);
|
|
260
|
-
}
|
|
261
|
-
}
|
|
262
|
-
//});
|
|
263
|
-
}
|
|
264
|
-
const { data, hideLegend = false } = props;
|
|
265
|
-
const points = _addDefaultColors(data === null || data === void 0 ? void 0 : data.chartData);
|
|
266
|
-
const classes = (0, _useDonutChartStylesstyles.useDonutChartStyles)(props);
|
|
267
|
-
const legendBars = _createLegends(points.filter((d)=>d.data >= 0));
|
|
268
|
-
const donutMarginHorizontal = props.hideLabels ? 0 : 80;
|
|
269
|
-
const donutMarginVertical = props.hideLabels ? 0 : 40;
|
|
270
|
-
const titleHeight = _getTitleHeight();
|
|
271
|
-
const outerRadius = Math.min(_width - donutMarginHorizontal, _height - donutMarginVertical - titleHeight) / 2;
|
|
272
|
-
const chartData = _elevateToMinimums(points);
|
|
273
|
-
const valueInsideDonut = props.innerRadius > _index1.MIN_DONUT_RADIUS ? _valueInsideDonut(props.valueInsideDonut, chartData) : '';
|
|
274
|
-
const arrowAttributes = (0, _reacttabster.useArrowNavigationGroup)({
|
|
275
|
-
circular: true,
|
|
276
|
-
axis: 'horizontal'
|
|
277
|
-
});
|
|
278
|
-
return !_isChartEmpty() ? /*#__PURE__*/ _react.createElement("div", {
|
|
279
|
-
className: classes.root,
|
|
280
|
-
ref: (rootElem)=>{
|
|
281
|
-
_rootElem.current = rootElem;
|
|
282
|
-
},
|
|
283
|
-
onMouseLeave: _handleChartMouseLeave
|
|
284
|
-
}, props.xAxisAnnotation && /*#__PURE__*/ _react.createElement("text", {
|
|
285
|
-
className: classes.axisAnnotation,
|
|
286
|
-
x: _width / 2,
|
|
287
|
-
y: _height - 10,
|
|
288
|
-
textAnchor: "middle"
|
|
289
|
-
}, props.xAxisAnnotation), /*#__PURE__*/ _react.createElement("div", {
|
|
290
|
-
className: classes.chartWrapper,
|
|
291
|
-
...arrowAttributes
|
|
292
|
-
}, /*#__PURE__*/ _react.createElement("svg", {
|
|
293
|
-
className: classes.chart,
|
|
294
|
-
"aria-label": data === null || data === void 0 ? void 0 : data.chartTitle,
|
|
295
|
-
width: _width,
|
|
296
|
-
height: _height + titleHeight / 2
|
|
297
|
-
}, !hideLegend && (data === null || data === void 0 ? void 0 : data.chartTitle) && /*#__PURE__*/ _react.createElement(_index1.ChartTitle, {
|
|
298
|
-
title: data.chartTitle,
|
|
299
|
-
x: _width / 2,
|
|
300
|
-
y: 0,
|
|
301
|
-
maxWidth: _width - 20,
|
|
302
|
-
className: classes.chartTitle,
|
|
303
|
-
titleStyles: props.titleStyles,
|
|
304
|
-
tooltipClassName: classes.svgTooltip
|
|
305
|
-
}), /*#__PURE__*/ _react.createElement(_index.Pie, {
|
|
306
|
-
width: _width,
|
|
307
|
-
height: _height,
|
|
308
|
-
outerRadius: outerRadius,
|
|
309
|
-
innerRadius: props.innerRadius,
|
|
310
|
-
data: chartData,
|
|
311
|
-
onFocusCallback: _focusCallback,
|
|
312
|
-
hoverOnCallback: _hoverCallback,
|
|
313
|
-
hoverLeaveCallback: _hoverLeave,
|
|
314
|
-
uniqText: _uniqText,
|
|
315
|
-
onBlurCallback: _onBlur,
|
|
316
|
-
activeArc: _getHighlightedLegend(),
|
|
317
|
-
focusedArcId: focusedArcId || '',
|
|
318
|
-
href: props.href,
|
|
319
|
-
valueInsideDonut: _toLocaleString(valueInsideDonut),
|
|
320
|
-
showLabelsInPercent: props.showLabelsInPercent,
|
|
321
|
-
hideLabels: props.hideLabels
|
|
322
|
-
}))), /*#__PURE__*/ _react.createElement(_ChartPopover.ChartPopover, {
|
|
323
|
-
xCalloutValue: xCalloutValue,
|
|
324
|
-
yCalloutValue: yCalloutValue,
|
|
325
|
-
culture: props.culture,
|
|
326
|
-
positioning: {
|
|
327
|
-
target: refSelected
|
|
328
|
-
},
|
|
329
|
-
isPopoverOpen: !props.hideTooltip && isPopoverOpen && (_noLegendsHighlighted() || _isLegendHighlighted(legend)),
|
|
330
|
-
legend: legend,
|
|
331
|
-
YValue: value,
|
|
332
|
-
color: color,
|
|
333
|
-
isCalloutForStack: false,
|
|
334
|
-
customCallout: {
|
|
335
|
-
customizedCallout: props.onRenderCalloutPerDataPoint ? props.onRenderCalloutPerDataPoint(dataPointCalloutProps) : undefined,
|
|
336
|
-
customCalloutProps: props.calloutPropsPerDataPoint ? props.calloutPropsPerDataPoint(dataPointCalloutProps) : undefined
|
|
337
|
-
},
|
|
338
|
-
isCartesian: false
|
|
339
|
-
}), !hideLegend && /*#__PURE__*/ _react.createElement("div", {
|
|
340
|
-
ref: (e)=>{
|
|
341
|
-
legendContainer.current = e;
|
|
342
|
-
},
|
|
343
|
-
className: classes.legendContainer,
|
|
344
|
-
style: {
|
|
345
|
-
marginTop: (data === null || data === void 0 ? void 0 : data.chartTitle) ? `-${titleHeight}px` : undefined
|
|
346
|
-
}
|
|
347
|
-
}, legendBars)) : /*#__PURE__*/ _react.createElement("div", {
|
|
348
|
-
id: _emptyChartId,
|
|
349
|
-
role: 'alert',
|
|
350
|
-
style: {
|
|
351
|
-
opacity: '0'
|
|
352
|
-
},
|
|
353
|
-
"aria-label": 'Graph has no data to display'
|
|
354
|
-
});
|
|
355
|
-
});
|
|
356
|
-
DonutChart.displayName = 'DonutChart';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/components/DonutChart/DonutChart.tsx"],"sourcesContent":["'use client';\n\n/* eslint-disable react/jsx-no-bind */\nimport * as React from 'react';\nimport { Pie } from './Pie/index';\nimport type { DonutChartProps } from './DonutChart.types';\nimport { useDonutChartStyles } from './useDonutChartStyles.styles';\nimport type { ChartDataPoint } from '../../DonutChart';\nimport { formatToLocaleString } from '@fluentui/chart-utilities';\nimport {\n areArraysEqual,\n getColorFromToken,\n getNextColor,\n MIN_DONUT_RADIUS,\n ChartTitle,\n CHART_TITLE_PADDING,\n} from '../../utilities/index';\nimport type { Legend } from '../../index';\nimport { Legends } from '../../index';\nimport { useId } from '@fluentui/react-utilities';\nimport type { JSXElement } from '@fluentui/react-utilities';\nimport { useArrowNavigationGroup } from '@fluentui/react-tabster';\nimport { ChartPopover } from '../CommonComponents/ChartPopover';\nimport { useImageExport } from '../../utilities/hooks';\n\nconst MIN_LEGEND_CONTAINER_HEIGHT = 40;\n\n// Create a DonutChart variant which uses these default styles and this styled subcomponent.\n/**\n * Donutchart component.\n * {@docCategory DonutChart}\n */\nexport const DonutChart: React.FunctionComponent<DonutChartProps> = React.forwardRef<HTMLDivElement, DonutChartProps>(\n ({ innerRadius = 0, hideLabels = true, ...restProps }, forwardedRef) => {\n const props = { innerRadius, hideLabels, ...restProps };\n const { chartContainerRef: _rootElem, legendsRef: _legendsRef } = useImageExport(\n props.componentRef,\n props.hideLegend,\n false,\n );\n const _uniqText: string = useId('_Pie_');\n\n let _calloutAnchorPoint: ChartDataPoint | null;\n let _emptyChartId: string | null;\n const legendContainer = React.useRef<HTMLDivElement | null>(null);\n const prevSize = React.useRef<{ width?: number; height?: number }>({});\n\n const [value, setValue] = React.useState<string | undefined>('');\n const [legend, setLegend] = React.useState<string | undefined>('');\n const [_width, setWidth] = React.useState<number | undefined>(props.width || 200);\n const [_height, setHeight] = React.useState<number | undefined>(props.height || 200);\n const [activeLegend, setActiveLegend] = React.useState<string | undefined>(undefined);\n const [color, setColor] = React.useState<string | undefined>('');\n const [xCalloutValue, setXCalloutValue] = React.useState<string>('');\n const [yCalloutValue, setYCalloutValue] = React.useState<string>('');\n const [selectedLegends, setSelectedLegends] = React.useState<string[]>(props.legendProps?.selectedLegends || []);\n const [focusedArcId, setFocusedArcId] = React.useState<string>('');\n const [dataPointCalloutProps, setDataPointCalloutProps] = React.useState<ChartDataPoint | undefined>();\n const [refSelected, setRefSelected] = React.useState<HTMLElement | null>(null);\n const [isPopoverOpen, setPopoverOpen] = React.useState(false);\n const prevPropsRef = React.useRef<DonutChartProps | null>(null);\n\n React.useEffect(() => {\n _fitParentContainer();\n }, []);\n\n React.useEffect(() => {\n if (prevPropsRef.current) {\n const prevProps = prevPropsRef.current;\n if (!areArraysEqual(prevProps.legendProps?.selectedLegends, props.legendProps?.selectedLegends)) {\n setSelectedLegends(props.legendProps?.selectedLegends || []);\n }\n }\n prevPropsRef.current = props;\n }, [props]);\n\n React.useEffect(() => {\n if (prevSize.current.height !== props.height || prevSize.current.width !== props.width) {\n _fitParentContainer();\n }\n prevSize.current.height = props.height;\n prevSize.current.width = props.width;\n }, [props.width, props.height]);\n\n function _elevateToMinimums(data: ChartDataPoint[]) {\n let sumOfData = 0;\n const minPercent = 0.01;\n const elevatedData: ChartDataPoint[] = [];\n data.forEach(item => {\n sumOfData += item.data!;\n });\n data.forEach(item => {\n elevatedData.push(\n minPercent * sumOfData > item.data! && item.data! > 0\n ? {\n ...item,\n data: minPercent * sumOfData,\n yAxisCalloutData:\n item.yAxisCalloutData === undefined ? item.data!.toLocaleString() : item.yAxisCalloutData,\n }\n : item,\n );\n });\n return elevatedData;\n }\n function _createLegends(chartData: ChartDataPoint[]): JSXElement {\n if (props.order === 'sorted') {\n chartData.sort((a: ChartDataPoint, b: ChartDataPoint) => {\n return b.data! - a.data!;\n });\n }\n const legendDataItems = chartData.map((point: ChartDataPoint, index: number) => {\n const color: string = point.color!;\n // mapping data to the format Legends component needs\n const legend: Legend = {\n title: point.legend!,\n color,\n hoverAction: () => {\n _handleChartMouseLeave();\n setActiveLegend(point.legend!);\n },\n onMouseOutAction: () => {\n setActiveLegend(undefined);\n },\n };\n return legend;\n });\n const legends = (\n <Legends\n legends={legendDataItems}\n centerLegends\n overflowText={props.legendsOverflowText}\n {...props.legendProps}\n onChange={_onLegendSelectionChange}\n legendRef={_legendsRef}\n />\n );\n return legends;\n }\n function _onLegendSelectionChange(\n selectedLegends: string[],\n event: React.MouseEvent<HTMLButtonElement>,\n currentLegend?: Legend,\n ): void {\n if (props.legendProps && props.legendProps?.canSelectMultipleLegends) {\n setSelectedLegends(selectedLegends);\n } else {\n setSelectedLegends(selectedLegends.slice(-1));\n }\n if (props.legendProps?.onChange) {\n props.legendProps.onChange(selectedLegends, event, currentLegend);\n }\n }\n\n function _focusCallback(\n data: ChartDataPoint,\n id: string,\n e: React.FocusEvent<SVGPathElement>,\n targetElement?: HTMLElement | null,\n ): void {\n setPopoverOpen(_noLegendsHighlighted() || _isLegendHighlighted(data.legend));\n setValue(data.data!.toString());\n setLegend(data.legend);\n setColor(data.color!);\n setXCalloutValue(data.xAxisCalloutData!);\n setYCalloutValue(data.yAxisCalloutData!);\n setFocusedArcId(id);\n setDataPointCalloutProps(data);\n setRefSelected(targetElement!);\n }\n\n function _hoverCallback(\n data: ChartDataPoint,\n e: React.MouseEvent<SVGPathElement>,\n targetElement?: HTMLElement | null,\n ): void {\n if (_calloutAnchorPoint !== data) {\n _calloutAnchorPoint = data;\n setPopoverOpen(_noLegendsHighlighted() || _isLegendHighlighted(data.legend));\n setValue(data.data!.toString());\n setLegend(data.legend);\n setColor(data.color!);\n setXCalloutValue(data.xAxisCalloutData!);\n setYCalloutValue(data.yAxisCalloutData!);\n setDataPointCalloutProps(data);\n setRefSelected(targetElement!);\n }\n }\n function _onBlur(): void {\n setFocusedArcId('');\n }\n\n function _hoverLeave(): void {\n /**/\n }\n\n function _handleChartMouseLeave() {\n _calloutAnchorPoint = null;\n setPopoverOpen(false);\n }\n\n function _valueInsideDonut(valueInsideDonut: string | number | undefined, data: ChartDataPoint[]) {\n const highlightedLegends = _getHighlightedLegend();\n if (valueInsideDonut !== undefined && (highlightedLegends.length === 1 || isPopoverOpen)) {\n const pointValue = data.find(point => _isLegendHighlighted(point.legend));\n return pointValue\n ? pointValue.yAxisCalloutData\n ? pointValue.yAxisCalloutData\n : pointValue.data!\n : valueInsideDonut;\n } else if (highlightedLegends.length > 0) {\n let totalValue = 0;\n data.forEach(point => {\n if (highlightedLegends.includes(point.legend!)) {\n totalValue += point.data!;\n }\n });\n return totalValue;\n } else {\n return valueInsideDonut;\n }\n }\n\n function _toLocaleString(data: string | number | undefined) {\n const localeString = formatToLocaleString(data, props.culture);\n if (!localeString) {\n return data;\n }\n return localeString?.toString();\n }\n\n /**\n * This function returns\n * the selected legend if there is one\n * or the hovered legend if none of the legends is selected.\n */\n function _getHighlightedLegend() {\n return selectedLegends.length > 0 ? selectedLegends : activeLegend ? [activeLegend] : [];\n }\n\n function _isLegendHighlighted(legend: string | undefined): boolean {\n return _getHighlightedLegend().includes(legend!);\n }\n\n function _noLegendsHighlighted(): boolean {\n return _getHighlightedLegend().length === 0;\n }\n\n function _isChartEmpty(): boolean {\n return !(\n props.data &&\n props.data.chartData &&\n props.data.chartData!.filter((d: ChartDataPoint) => d.data! > 0).length > 0\n );\n }\n\n function _addDefaultColors(donutChartDataPoint?: ChartDataPoint[]): ChartDataPoint[] {\n return donutChartDataPoint\n ? donutChartDataPoint.map((item, index) => {\n let defaultColor: string;\n if (typeof item.color === 'undefined') {\n defaultColor = getNextColor(index, 0);\n } else {\n defaultColor = getColorFromToken(item.color);\n }\n return { ...item, defaultColor };\n })\n : [];\n }\n\n /**\n * Computes the vertical space the chart title occupies above the donut.\n * Kept in sync with the title rendered inside the SVG so that\n * `_fitParentContainer` can reserve this space when sizing the chart.\n */\n function _getTitleHeight(): number {\n return props.data?.chartTitle\n ? Math.max(\n (typeof props.titleStyles?.titleFont?.size === 'number' ? props.titleStyles.titleFont.size : 13) +\n CHART_TITLE_PADDING,\n 36,\n )\n : 0;\n }\n\n /**\n * When screen resizes, along with screen, chart also auto adjusted.\n * This method used to adjust height and width of the charts.\n */\n function _fitParentContainer(): void {\n //_reqID = requestAnimationFrame(() => {\n let legendContainerHeight;\n if (props.hideLegend) {\n // If there is no legend, need not to allocate some space from total chart space.\n legendContainerHeight = 0;\n } else {\n const legendContainerComputedStyles = legendContainer.current && getComputedStyle(legendContainer.current);\n legendContainerHeight =\n ((legendContainer.current && legendContainer.current.getBoundingClientRect().height) ||\n MIN_LEGEND_CONTAINER_HEIGHT) +\n parseFloat((legendContainerComputedStyles && legendContainerComputedStyles.marginTop) || '0') +\n parseFloat((legendContainerComputedStyles && legendContainerComputedStyles.marginBottom) || '0');\n }\n if (props.parentRef || _rootElem.current) {\n const container = props.parentRef ? props.parentRef : _rootElem.current!;\n const currentContainerWidth = container.getBoundingClientRect().width;\n const currentContainerHeight =\n container.getBoundingClientRect().height > legendContainerHeight\n ? container.getBoundingClientRect().height\n : 200;\n // The SVG is rendered `titleHeight / 2` taller than `_height` (see the `height` attribute below)\n // to fit the title. Reserve that space here so the total rendered content never exceeds the\n // measured container height. Otherwise, when the container height is unconstrained (e.g. an\n // auto-height parent), the extra pixels feed back into the ResizeObserver and the chart grows\n // on every frame in an infinite loop.\n const availableHeight = currentContainerHeight - legendContainerHeight - _getTitleHeight() / 2;\n const shouldResize = _width !== currentContainerWidth || _height !== availableHeight;\n if (shouldResize) {\n setWidth(currentContainerWidth);\n setHeight(availableHeight);\n }\n }\n //});\n }\n\n const { data, hideLegend = false } = props;\n const points = _addDefaultColors(data?.chartData);\n\n const classes = useDonutChartStyles(props);\n\n const legendBars = _createLegends(points.filter(d => d.data! >= 0));\n const donutMarginHorizontal = props.hideLabels ? 0 : 80;\n const donutMarginVertical = props.hideLabels ? 0 : 40;\n const titleHeight = _getTitleHeight();\n const outerRadius = Math.min(_width! - donutMarginHorizontal, _height! - donutMarginVertical - titleHeight) / 2;\n const chartData = _elevateToMinimums(points);\n const valueInsideDonut =\n props.innerRadius! > MIN_DONUT_RADIUS ? _valueInsideDonut(props.valueInsideDonut!, chartData!) : '';\n const arrowAttributes = useArrowNavigationGroup({ circular: true, axis: 'horizontal' });\n return !_isChartEmpty() ? (\n <div\n className={classes.root}\n ref={(rootElem: HTMLDivElement | null) => {\n _rootElem.current = rootElem;\n }}\n onMouseLeave={_handleChartMouseLeave}\n >\n {props.xAxisAnnotation && (\n <text className={classes.axisAnnotation} x={_width! / 2} y={_height! - 10} textAnchor=\"middle\">\n {props.xAxisAnnotation}\n </text>\n )}\n <div className={classes.chartWrapper} {...arrowAttributes}>\n <svg\n className={classes.chart}\n aria-label={data?.chartTitle}\n width={_width}\n height={_height! + titleHeight / 2}\n >\n {!hideLegend && data?.chartTitle && (\n <ChartTitle\n title={data.chartTitle}\n x={_width! / 2}\n y={0}\n maxWidth={_width! - 20}\n className={classes.chartTitle}\n titleStyles={props.titleStyles}\n tooltipClassName={classes.svgTooltip}\n />\n )}\n <Pie\n width={_width!}\n height={_height!}\n outerRadius={outerRadius}\n innerRadius={props.innerRadius!}\n data={chartData!}\n onFocusCallback={_focusCallback}\n hoverOnCallback={_hoverCallback}\n hoverLeaveCallback={_hoverLeave}\n uniqText={_uniqText}\n onBlurCallback={_onBlur}\n activeArc={_getHighlightedLegend()}\n focusedArcId={focusedArcId || ''}\n href={props.href!}\n valueInsideDonut={_toLocaleString(valueInsideDonut)}\n showLabelsInPercent={props.showLabelsInPercent}\n hideLabels={props.hideLabels}\n />\n </svg>\n </div>\n <ChartPopover\n xCalloutValue={xCalloutValue}\n yCalloutValue={yCalloutValue}\n culture={props.culture}\n positioning={{\n target: refSelected,\n }}\n isPopoverOpen={\n !props.hideTooltip && isPopoverOpen && (_noLegendsHighlighted() || _isLegendHighlighted(legend))\n }\n legend={legend!}\n YValue={value!}\n color={color}\n isCalloutForStack={false}\n customCallout={{\n customizedCallout: props.onRenderCalloutPerDataPoint\n ? props.onRenderCalloutPerDataPoint(dataPointCalloutProps!)\n : undefined,\n customCalloutProps: props.calloutPropsPerDataPoint\n ? props.calloutPropsPerDataPoint(dataPointCalloutProps!)\n : undefined,\n }}\n isCartesian={false}\n />\n {!hideLegend && (\n <div\n ref={(e: HTMLDivElement) => {\n legendContainer.current = e;\n }}\n className={classes.legendContainer}\n style={{ marginTop: data?.chartTitle ? `-${titleHeight}px` : undefined }}\n >\n {legendBars}\n </div>\n )}\n </div>\n ) : (\n <div id={_emptyChartId!} role={'alert'} style={{ opacity: '0' }} aria-label={'Graph has no data to display'} />\n );\n },\n);\n\nDonutChart.displayName = 'DonutChart';\n"],"names":["React","Pie","useDonutChartStyles","formatToLocaleString","areArraysEqual","getColorFromToken","getNextColor","MIN_DONUT_RADIUS","ChartTitle","CHART_TITLE_PADDING","Legends","useId","useArrowNavigationGroup","ChartPopover","useImageExport","MIN_LEGEND_CONTAINER_HEIGHT","DonutChart","forwardRef","innerRadius","hideLabels","restProps","forwardedRef","props","chartContainerRef","_rootElem","legendsRef","_legendsRef","componentRef","hideLegend","_uniqText","_calloutAnchorPoint","_emptyChartId","legendContainer","useRef","prevSize","value","setValue","useState","legend","setLegend","_width","setWidth","width","_height","setHeight","height","activeLegend","setActiveLegend","undefined","color","setColor","xCalloutValue","setXCalloutValue","yCalloutValue","setYCalloutValue","selectedLegends","setSelectedLegends","legendProps","focusedArcId","setFocusedArcId","dataPointCalloutProps","setDataPointCalloutProps","refSelected","setRefSelected","isPopoverOpen","setPopoverOpen","prevPropsRef","useEffect","_fitParentContainer","current","prevProps","_elevateToMinimums","data","sumOfData","minPercent","elevatedData","forEach","item","push","yAxisCalloutData","toLocaleString","_createLegends","chartData","order","sort","a","b","legendDataItems","map","point","index","title","hoverAction","_handleChartMouseLeave","onMouseOutAction","legends","centerLegends","overflowText","legendsOverflowText","onChange","_onLegendSelectionChange","legendRef","event","currentLegend","canSelectMultipleLegends","slice","_focusCallback","id","e","targetElement","_noLegendsHighlighted","_isLegendHighlighted","toString","xAxisCalloutData","_hoverCallback","_onBlur","_hoverLeave","_valueInsideDonut","valueInsideDonut","highlightedLegends","_getHighlightedLegend","length","pointValue","find","totalValue","includes","_toLocaleString","localeString","culture","_isChartEmpty","filter","d","_addDefaultColors","donutChartDataPoint","defaultColor","_getTitleHeight","chartTitle","Math","max","titleStyles","titleFont","size","legendContainerHeight","legendContainerComputedStyles","getComputedStyle","getBoundingClientRect","parseFloat","marginTop","marginBottom","parentRef","container","currentContainerWidth","currentContainerHeight","availableHeight","shouldResize","points","classes","legendBars","donutMarginHorizontal","donutMarginVertical","titleHeight","outerRadius","min","arrowAttributes","circular","axis","div","className","root","ref","rootElem","onMouseLeave","xAxisAnnotation","text","axisAnnotation","x","y","textAnchor","chartWrapper","svg","chart","aria-label","maxWidth","tooltipClassName","svgTooltip","onFocusCallback","hoverOnCallback","hoverLeaveCallback","uniqText","onBlurCallback","activeArc","href","showLabelsInPercent","positioning","target","hideTooltip","YValue","isCalloutForStack","customCallout","customizedCallout","onRenderCalloutPerDataPoint","customCalloutProps","calloutPropsPerDataPoint","isCartesian","style","role","opacity","displayName"],"mappings":"AAAA;;;;;+BAgCagB;;;;;;;iEA7BU,QAAQ;uBACX,cAAc;2CAEE,+BAA+B;gCAE9B,4BAA4B;wBAQ1D,wBAAwB;wBAEP,cAAc;gCAChB,4BAA4B;8BAEV,0BAA0B;8BACrC,mCAAmC;uBACjC,wBAAwB;AAEvD,MAAMD,8BAA8B;AAO7B,mBAAMC,WAA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K,MAAM;QAASD,OAAO;YAAEE,SAAS;QAAI;QAAGzB,cAAY;;AAEjF,GACA;AAEFrK,WAAW+L,WAAW,GAAG"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/components/DonutChart/DonutChart.types.ts"],"sourcesContent":["import type * as React from 'react';\nimport type { JSXElement } from '@fluentui/react-utilities';\nimport type { CartesianChartProps, CartesianChartStyleProps } from '../CommonComponents/index';\nimport type { ChartProps, ChartDataPoint, Chart } from './index';\nimport type { ChartPopoverProps } from '../CommonComponents/ChartPopover.types';\nimport type { LegendsProps } from '../Legends/index';\nimport type { TitleStyles } from '../../utilities/Common.styles';\n\n/**\n * Donut Chart properties.\n * {@docCategory DonutChart}\n */\nexport interface DonutChartProps extends CartesianChartProps {\n /**\n * Title styles configuration for the chart title\n */\n titleStyles?: TitleStyles;\n\n /**\n * Data to render in the chart.\n */\n data?: ChartProps;\n\n /**\n * inner radius for donut size\n */\n innerRadius?: number;\n\n /**\n * Call to provide customized styling that will layer on top of the variant rules.\n */\n styles?: DonutChartStyles;\n\n /**\n * props for inside donut value\n */\n valueInsideDonut?: string | number;\n\n /**\n * Define a custom callout renderer for a data point\n */\n onRenderCalloutPerDataPoint?: (dataPointCalloutProps: ChartDataPoint) => JSXElement | undefined;\n\n /**\n * Define a custom callout props override\n */\n calloutPropsPerDataPoint?: (dataPointCalloutProps: ChartDataPoint) => ChartPopoverProps;\n\n /**\n * props for the callout in the chart\n */\n calloutProps?: ChartPopoverProps;\n\n /**\n * The prop used to define the culture to localized the numbers\n */\n culture?: string;\n\n /**\n * Prop to show the arc labels in percentage format\n * @default false\n */\n showLabelsInPercent?: boolean;\n\n /**\n * Prop to hide the arc labels\n * @default true\n */\n hideLabels?: boolean;\n\n /**\n * Below height used for resizing of the chart\n * Wrap chart in your container and send the updated height and width to these props.\n * These values decide wheather chart re render or not. Please check examples for reference\n */\n height?: number;\n\n /**\n * Below width used for resizing of the chart\n * Wrap chart in your container and send the updated height and width to these props.\n * These values decide wheather chart re render or not. Please check examples for reference\n */\n width?: number;\n\n /**\n * this prop takes its parent as a HTML element to define the width and height of the chart\n */\n parentRef?: HTMLElement | null;\n\n /**\n * Additional CSS class(es) to apply to the Chart.\n */\n className?: string;\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n legendsOverflowText?: any;\n\n /*\n * props for the legends in the chart\n */\n legendProps?: Partial<LegendsProps>;\n\n /** decides wether to show/hide legends\n * @defaultvalue false\n */\n hideLegend?: boolean;\n\n /**\n * Url that the data-viz needs to redirect to upon clicking on it\n */\n href?: string;\n\n /**\n * Do not show tooltips in chart\n * @default false\n */\n hideTooltip?: boolean;\n\n /**\n * Optional callback to access the Chart interface. Use this instead of ref for accessing\n * the public methods and properties of the component.\n */\n componentRef?: React.Ref<Chart>;\n\n /**\n * Prop to enable the round corners in the chart\n * @default false\n */\n roundCorners?: boolean;\n\n /**\n * Rendering order of the legend\n * @default 'default'\n * 'default' - as per data provided\n * 'sorted' - in descending order of value\n */\n order?: 'default' | 'sorted';\n}\n\n/**\n * Donut Chart style properties\n * {@docCategory DonutChart}\n */\nexport interface DonutChartStyleProps extends CartesianChartStyleProps {}\n\n/**\n * Donut Chart styles\n * {@docCategory DonutChart}\n */\nexport interface DonutChartStyles {\n /**\n * Style for the root element.\n */\n root?: string;\n\n /**\n * Style for the chart.\n */\n chart?: string;\n /**\n * Style for the legend container.\n */\n legendContainer: string;\n\n /**\n * Style for the chart title.\n */\n chartTitle?: string;\n\n /**\n * styles for axis annotation\n */\n axisAnnotation?: string;\n\n /**\n * Styles for the chart wrapper div\n */\n chartWrapper?: string;\n\n /**\n * Style for SVG tooltip text\n */\n svgTooltip?: string;\n}\n"],"names":[],"mappings":"AAiJA;;;CAGC,GACD,WAkCC"}
|
|
@@ -1,79 +0,0 @@
|
|
|
1
|
-
'use client';
|
|
2
|
-
"use strict";
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
Object.defineProperty(exports, "Pie", {
|
|
7
|
-
enumerable: true,
|
|
8
|
-
get: function() {
|
|
9
|
-
return Pie;
|
|
10
|
-
}
|
|
11
|
-
});
|
|
12
|
-
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
|
13
|
-
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
|
14
|
-
const _d3shape = require("d3-shape");
|
|
15
|
-
const _index = require("../Arc/index");
|
|
16
|
-
const _usePieStylesstyles = require("./usePieStyles.styles");
|
|
17
|
-
const _index1 = require("../../../utilities/index");
|
|
18
|
-
const TEXT_PADDING = 5;
|
|
19
|
-
const Pie = /*#__PURE__*/ _react.forwardRef((props, forwardedRef)=>{
|
|
20
|
-
_react.useEffect(()=>{
|
|
21
|
-
(0, _index1.wrapTextInsideDonut)(classes.insideDonutString, props.innerRadius * 2 - TEXT_PADDING);
|
|
22
|
-
}, []);
|
|
23
|
-
let _totalValue;
|
|
24
|
-
const classes = (0, _usePieStylesstyles.usePieStyles)(props);
|
|
25
|
-
const pieForFocusRing = (0, _d3shape.pie)().sort(null).value((d)=>d.data).padAngle(0);
|
|
26
|
-
function _focusCallback(data, id, e, targetElement) {
|
|
27
|
-
props.onFocusCallback(data, id, e, targetElement);
|
|
28
|
-
}
|
|
29
|
-
function _hoverCallback(data, e, targetElement) {
|
|
30
|
-
props.hoverOnCallback(data, e, targetElement);
|
|
31
|
-
}
|
|
32
|
-
function _computeTotalValue() {
|
|
33
|
-
let totalValue = 0;
|
|
34
|
-
props.data.forEach((arc)=>{
|
|
35
|
-
totalValue += arc.data;
|
|
36
|
-
});
|
|
37
|
-
return totalValue;
|
|
38
|
-
}
|
|
39
|
-
function arcGenerator(d, i, focusData, href) {
|
|
40
|
-
const color = d && d.data && d.data.color;
|
|
41
|
-
return /*#__PURE__*/ _react.createElement(_index.Arc, {
|
|
42
|
-
key: i,
|
|
43
|
-
data: d,
|
|
44
|
-
focusData: focusData,
|
|
45
|
-
innerRadius: props.innerRadius,
|
|
46
|
-
outerRadius: props.outerRadius,
|
|
47
|
-
color: color,
|
|
48
|
-
onFocusCallback: _focusCallback,
|
|
49
|
-
hoverOnCallback: _hoverCallback,
|
|
50
|
-
onBlurCallback: props.onBlurCallback,
|
|
51
|
-
hoverLeaveCallback: props.hoverLeaveCallback,
|
|
52
|
-
uniqText: props.uniqText,
|
|
53
|
-
activeArc: props.activeArc,
|
|
54
|
-
href: href,
|
|
55
|
-
calloutId: props.calloutId,
|
|
56
|
-
valueInsideDonut: props.valueInsideDonut,
|
|
57
|
-
focusedArcId: props.focusedArcId,
|
|
58
|
-
showLabelsInPercent: props.showLabelsInPercent,
|
|
59
|
-
totalValue: _totalValue,
|
|
60
|
-
hideLabels: props.hideLabels
|
|
61
|
-
});
|
|
62
|
-
}
|
|
63
|
-
const { data } = props;
|
|
64
|
-
// Filter out data points with value 0 to avoid gaps in the donut chart
|
|
65
|
-
const filteredData = data.filter((d)=>d.data !== 0);
|
|
66
|
-
const focusData = pieForFocusRing(filteredData.map((d)=>d.data));
|
|
67
|
-
const piechart = (0, _d3shape.pie)().sort(null).value((d)=>d.data).padAngle(0.02)(filteredData);
|
|
68
|
-
const translate = `translate(${props.width / 2}, ${props.height / 2})`;
|
|
69
|
-
_totalValue = _computeTotalValue();
|
|
70
|
-
return /*#__PURE__*/ _react.createElement("g", {
|
|
71
|
-
transform: translate
|
|
72
|
-
}, piechart.map((d, i)=>arcGenerator(d, i, focusData[i], props.href)), props.valueInsideDonut && /*#__PURE__*/ _react.createElement("text", {
|
|
73
|
-
y: 5,
|
|
74
|
-
textAnchor: "middle",
|
|
75
|
-
dominantBaseline: "middle",
|
|
76
|
-
className: classes.insideDonutString
|
|
77
|
-
}, props.valueInsideDonut));
|
|
78
|
-
});
|
|
79
|
-
Pie.displayName = 'Pie';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/components/DonutChart/Pie/Pie.tsx"],"sourcesContent":["'use client';\n\n/* eslint-disable react-hooks/exhaustive-deps */\n/* eslint-disable react/jsx-no-bind */\n/* eslint-disable @typescript-eslint/no-explicit-any */\nimport * as React from 'react';\nimport type { JSXElement } from '@fluentui/react-utilities';\nimport { pie as d3Pie } from 'd3-shape';\nimport type { PieProps } from './index';\nimport { Arc } from '../Arc/index';\nimport type { ChartDataPoint } from '../index';\nimport { usePieStyles } from './usePieStyles.styles';\nimport { wrapTextInsideDonut } from '../../../utilities/index';\nconst TEXT_PADDING: number = 5;\n\n// Create a Pie within Donut Chart variant which uses these default styles and this styled subcomponent.\n/**\n * Pie component within Donut Chart.\n * {@docCategory PieDonutChart}\n */\nexport const Pie: React.FunctionComponent<PieProps> = React.forwardRef<HTMLDivElement, PieProps>(\n (props, forwardedRef) => {\n React.useEffect(() => {\n wrapTextInsideDonut(classes.insideDonutString, props.innerRadius! * 2 - TEXT_PADDING);\n }, []);\n\n let _totalValue: number;\n const classes = usePieStyles(props);\n const pieForFocusRing = d3Pie()\n .sort(null)\n\n .value((d: any) => d.data)\n .padAngle(0);\n\n function _focusCallback(\n data: ChartDataPoint,\n id: string,\n e: React.FocusEvent<SVGPathElement>,\n targetElement?: HTMLElement | null,\n ): void {\n props.onFocusCallback!(data, id, e, targetElement);\n }\n\n function _hoverCallback(\n data: ChartDataPoint,\n e: React.MouseEvent<SVGPathElement>,\n targetElement?: HTMLElement | null,\n ): void {\n props.hoverOnCallback!(data, e, targetElement);\n }\n\n function _computeTotalValue() {\n let totalValue = 0;\n props.data.forEach((arc: ChartDataPoint) => {\n totalValue += arc.data!;\n });\n return totalValue;\n }\n\n function arcGenerator(d: any, i: number, focusData: any, href?: string): JSXElement {\n const color = d && d.data && d.data.color;\n return (\n <Arc\n key={i}\n data={d}\n focusData={focusData}\n innerRadius={props.innerRadius}\n outerRadius={props.outerRadius}\n color={color!}\n onFocusCallback={_focusCallback}\n hoverOnCallback={_hoverCallback}\n onBlurCallback={props.onBlurCallback}\n hoverLeaveCallback={props.hoverLeaveCallback}\n uniqText={props.uniqText}\n activeArc={props.activeArc}\n href={href}\n calloutId={props.calloutId}\n valueInsideDonut={props.valueInsideDonut}\n focusedArcId={props.focusedArcId}\n showLabelsInPercent={props.showLabelsInPercent}\n totalValue={_totalValue}\n hideLabels={props.hideLabels}\n />\n );\n }\n\n const { data } = props;\n\n // Filter out data points with value 0 to avoid gaps in the donut chart\n const filteredData = data.filter((d: ChartDataPoint) => d.data !== 0);\n\n const focusData = pieForFocusRing(filteredData.map(d => d.data!));\n\n const piechart = d3Pie<ChartDataPoint>()\n .sort(null)\n\n .value((d: any) => d.data)\n .padAngle(0.02)(filteredData);\n const translate = `translate(${props.width / 2}, ${props.height / 2})`;\n\n _totalValue = _computeTotalValue();\n\n return (\n <g transform={translate}>\n {piechart.map((d: any, i: number) => arcGenerator(d, i, focusData[i], props.href))}\n {props.valueInsideDonut && (\n <text y={5} textAnchor=\"middle\" dominantBaseline=\"middle\" className={classes.insideDonutString}>\n {props.valueInsideDonut}\n </text>\n )}\n </g>\n );\n },\n);\nPie.displayName = 'Pie';\n"],"names":["React","pie","d3Pie","Arc","usePieStyles","wrapTextInsideDonut","TEXT_PADDING","Pie","forwardRef","props","forwardedRef","useEffect","classes","insideDonutString","innerRadius","_totalValue","pieForFocusRing","sort","value","d","data","padAngle","_focusCallback","id","e","targetElement","onFocusCallback","_hoverCallback","hoverOnCallback","_computeTotalValue","totalValue","forEach","arc","arcGenerator","i","focusData","href","color","key","outerRadius","onBlurCallback","hoverLeaveCallback","uniqText","activeArc","calloutId","valueInsideDonut","focusedArcId","showLabelsInPercent","hideLabels","filteredData","filter","map","piechart","translate","width","height","g","transform","text","y","textAnchor","dominantBaseline","className","displayName"],"mappings":"AAAA;;;;;+BAoBaO;;;;;;;iEAfU,QAAQ;yBAEF,WAAW;uBAEpB,eAAe;oCAEN,wBAAwB;wBACjB,2BAA2B;AAC/D,MAAMD,eAAuB;AAOtB,YAAMC,WAAAA,GAAyCP,OAAMQ,UAAU,CACpE,CAACC,OAAOC;IAC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BAAqBtC,MAAMsC,mBAAmB;YAC9CjB,YAAYf;YACZiC,YAAYvC,MAAMuC,UAAU;;IAGlC;IAEA,MAAM,EAAE5B,IAAI,EAAE,GAAGX;IAEjB,uEAAuE;IACvE,MAAMwC,eAAe7B,KAAK8B,MAAM,CAAC,CAAC/B,IAAsBA,EAAEC,IAAI,KAAK;IAEnE,MAAMe,YAAYnB,gBAAgBiC,aAAaE,GAAG,CAAChC,CAAAA,IAAKA,EAAEC,IAAI;IAE9D,MAAMgC,eAAWlD,YAAAA,IACde,IAAI,CAAC,MAELC,KAAK,CAAC,CAACC,IAAWA,EAAEC,IAAI,EACxBC,QAAQ,CAAC,MAAM4B;IAClB,MAAMI,YAAY,CAAC,UAAU,EAAE5C,MAAM6C,KAAK,GAAG,EAAE,EAAE,EAAE7C,MAAM8C,MAAM,GAAG,EAAE,CAAC,CAAC;IAEtExC,cAAcc;IAEd,OAAA,WAAA,GACE,OAAA,aAAA,CAAC2B,KAAAA;QAAEC,WAAWJ;OACXD,SAASD,GAAG,CAAC,CAAChC,GAAQe,IAAcD,aAAad,GAAGe,GAAGC,SAAS,CAACD,EAAE,EAAEzB,MAAM2B,IAAI,IAC/E3B,MAAMoC,gBAAgB,IAAA,WAAA,GACrB,OAAA,aAAA,CAACa,QAAAA;QAAKC,GAAG;QAAGC,YAAW;QAASC,kBAAiB;QAASC,WAAWlD,QAAQC,iBAAiB;OAC3FJ,MAAMoC,gBAAgB;AAKjC,GACA;AACFtC,IAAIwD,WAAW,GAAG"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/components/DonutChart/Pie/Pie.types.ts"],"sourcesContent":["import type { ChartDataPoint } from '../index';\n\nexport interface PieProps {\n /**\n * Width of the Pie.\n */\n width: number;\n /**\n * Height of the Pie.\n */\n height: number;\n /**\n * outerRadius of the Pie.\n */\n outerRadius: number;\n /**\n * innerRadius of the Pie.\n */\n innerRadius: number;\n /**\n * Data to render in the Pie.\n */\n data: ChartDataPoint[];\n /**\n * shape for pie.\n */\n /* eslint-disable @typescript-eslint/no-explicit-any */\n pie?: any;\n\n pieForFocusRing?: any;\n\n /**\n * Defines the function that is executed upon hovering over the legend\n */\n hoverOnCallback?: Function;\n /**\n * Defines the function that is executed upon hovering over the legend\n */\n onFocusCallback?: Function;\n /**\n * Defines the function that is executed upon hovering Leave the legend\n */\n onBlurCallback?: Function;\n /**\n * Defines the function that is executed upon hovering Leave the legend\n */\n hoverLeaveCallback?: Function;\n /**\n * Uniq string for chart\n */\n uniqText?: string;\n /**\n * Active Arc for chart\n */\n activeArc?: string[];\n\n /**\n * string for callout id\n */\n calloutId?: string;\n\n /**\n * internal prop for href\n */\n href?: string;\n\n /**\n * props for inside donut value\n */\n valueInsideDonut?: string | number;\n\n /**\n * id of the focused arc\n */\n focusedArcId?: string;\n\n /**\n * Prop to show the arc labels in percentage format\n */\n showLabelsInPercent?: boolean;\n\n /**\n * Prop to hide the arc labels\n */\n hideLabels?: boolean;\n\n /**\n * Call to provide customized styling that will layer on top of the variant rules.\n */\n styles?: PieStyles;\n\n /**\n * Additional CSS class(es) to apply to the Chart.\n */\n className?: string;\n}\n\nexport interface PieStyles {\n /**\n * Style set for the card header component root\n */\n root: string;\n\n /**\n * Style set for the inside donut string\n */\n insideDonutString: string;\n}\n"],"names":[],"mappings":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/components/DonutChart/Pie/index.ts"],"sourcesContent":["export * from './Pie';\nexport * from './Pie.types';\n"],"names":[],"mappings":";;;;;uBAAc,QAAQ;uBACR,cAAc"}
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
'use client';
|
|
2
|
-
"use strict";
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
function _export(target, all) {
|
|
7
|
-
for(var name in all)Object.defineProperty(target, name, {
|
|
8
|
-
enumerable: true,
|
|
9
|
-
get: all[name]
|
|
10
|
-
});
|
|
11
|
-
}
|
|
12
|
-
_export(exports, {
|
|
13
|
-
donutPieClassNames: function() {
|
|
14
|
-
return donutPieClassNames;
|
|
15
|
-
},
|
|
16
|
-
usePieStyles: function() {
|
|
17
|
-
return usePieStyles;
|
|
18
|
-
}
|
|
19
|
-
});
|
|
20
|
-
const _react = require("@griffel/react");
|
|
21
|
-
const donutPieClassNames = {
|
|
22
|
-
root: 'fui-donut-pie__root',
|
|
23
|
-
insideDonutString: 'fui-donut-pie__insideDonutString'
|
|
24
|
-
};
|
|
25
|
-
/**
|
|
26
|
-
* Base Styles
|
|
27
|
-
*/ const useStyles = /*#__PURE__*/ (0, _react.__styles)({
|
|
28
|
-
root: {},
|
|
29
|
-
insideDonutString: {
|
|
30
|
-
Bahqtrf: "fk6fouc",
|
|
31
|
-
Be2twd7: "fojgt09",
|
|
32
|
-
Bhrd7zp: "fl43uef",
|
|
33
|
-
Bg96gwp: "fcen8rp",
|
|
34
|
-
Bkfmm31: "fhuob2q",
|
|
35
|
-
Bvjb7m6: "fhv2zbx"
|
|
36
|
-
}
|
|
37
|
-
}, {
|
|
38
|
-
d: [
|
|
39
|
-
".fk6fouc{font-family:var(--fontFamilyBase);}",
|
|
40
|
-
".fojgt09{font-size:var(--fontSizeHero700);}",
|
|
41
|
-
".fl43uef{font-weight:var(--fontWeightSemibold);}",
|
|
42
|
-
".fcen8rp{line-height:var(--lineHeightHero700);}",
|
|
43
|
-
".fhuob2q{fill:var(--colorNeutralForeground1);}",
|
|
44
|
-
".fhv2zbx{forced-color-adjust:auto;}"
|
|
45
|
-
]
|
|
46
|
-
});
|
|
47
|
-
const usePieStyles = (props)=>{
|
|
48
|
-
var _props_styles, _props_styles1;
|
|
49
|
-
const { className } = props;
|
|
50
|
-
const baseStyles = useStyles();
|
|
51
|
-
return {
|
|
52
|
-
root: (0, _react.mergeClasses)(donutPieClassNames.root, baseStyles.root, className, (_props_styles = props.styles) === null || _props_styles === void 0 ? void 0 : _props_styles.root),
|
|
53
|
-
insideDonutString: (0, _react.mergeClasses)(donutPieClassNames.insideDonutString, baseStyles.insideDonutString, className, (_props_styles1 = props.styles) === null || _props_styles1 === void 0 ? void 0 : _props_styles1.insideDonutString)
|
|
54
|
-
};
|
|
55
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["usePieStyles.styles.js"],"sourcesContent":["'use client';\nimport { tokens, typographyStyles } from '@fluentui/react-theme';\nimport { makeStyles, mergeClasses } from '@griffel/react';\n/**\n * @internal\n */ export const donutPieClassNames = {\n root: 'fui-donut-pie__root',\n insideDonutString: 'fui-donut-pie__insideDonutString'\n};\n/**\n * Base Styles\n */ const useStyles = makeStyles({\n root: {},\n insideDonutString: {\n ...typographyStyles.title2,\n fill: tokens.colorNeutralForeground1,\n forcedColorAdjust: 'auto'\n }\n});\n/**\n * Apply styling to the Pie inside donut chart component\n */ export const usePieStyles = (props)=>{\n var _props_styles, _props_styles1;\n const { className } = props;\n const baseStyles = useStyles();\n return {\n root: mergeClasses(donutPieClassNames.root, baseStyles.root, className, (_props_styles = props.styles) === null || _props_styles === void 0 ? void 0 : _props_styles.root),\n insideDonutString: mergeClasses(donutPieClassNames.insideDonutString, baseStyles.insideDonutString, className, (_props_styles1 = props.styles) === null || _props_styles1 === void 0 ? void 0 : _props_styles1.insideDonutString)\n };\n};\n"],"names":["tokens","typographyStyles","__styles","mergeClasses","donutPieClassNames","root","insideDonutString","useStyles","Bahqtrf","Be2twd7","Bhrd7zp","Bg96gwp","Bkfmm31","Bvjb7m6","d","usePieStyles","props","_props_styles","_props_styles1","className","baseStyles","styles"],"mappings":"AAAA,YAAY;;;;;;;;;;;;IAKKI,kBAAkB;;;gBAgBN;eAAZW;;;uBAnBwB,gBAAgB;AAG9C,2BAA2B;IAClCV,IAAI,EAAE,qBAAqB;IAC3BC,iBAAiB,EAAE;AACvB,CAAC;AACD;;CAEA,GAAI,MAAMC,SAAS,GAAA,WAAA,OAAGL,eAAA,EAAA;IAAAG,IAAA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