@fluentui/react-charts 9.3.5 → 9.3.6
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 +23 -2
- package/dist/index.d.ts +223 -44
- package/lib/AnnotationOnlyChart.js +1 -0
- package/lib/AnnotationOnlyChart.js.map +1 -0
- package/lib/components/AnnotationOnlyChart/AnnotationOnlyChart.js +208 -0
- package/lib/components/AnnotationOnlyChart/AnnotationOnlyChart.js.map +1 -0
- package/lib/components/AnnotationOnlyChart/AnnotationOnlyChart.types.js +1 -0
- package/lib/components/AnnotationOnlyChart/AnnotationOnlyChart.types.js.map +1 -0
- package/lib/components/AnnotationOnlyChart/index.js +2 -0
- package/lib/components/AnnotationOnlyChart/index.js.map +1 -0
- package/lib/components/AnnotationOnlyChart/useAnnotationOnlyChartStyles.styles.js +31 -0
- package/lib/components/AnnotationOnlyChart/useAnnotationOnlyChartStyles.styles.js.map +1 -0
- package/lib/components/AnnotationOnlyChart/useAnnotationOnlyChartStyles.styles.raw.js +23 -0
- package/lib/components/AnnotationOnlyChart/useAnnotationOnlyChartStyles.styles.raw.js.map +1 -0
- package/lib/components/AreaChart/useAreaChartStyles.styles.js +11 -6
- package/lib/components/AreaChart/useAreaChartStyles.styles.js.map +1 -1
- package/lib/components/AreaChart/useAreaChartStyles.styles.raw.js +3 -1
- package/lib/components/AreaChart/useAreaChartStyles.styles.raw.js.map +1 -1
- package/lib/components/ChartTable/useChartTableStyles.styles.js +59 -39
- package/lib/components/ChartTable/useChartTableStyles.styles.js.map +1 -1
- package/lib/components/ChartTable/useChartTableStyles.styles.raw.js +5 -5
- package/lib/components/ChartTable/useChartTableStyles.styles.raw.js.map +1 -1
- package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.js +617 -0
- package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.js.map +1 -0
- package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.types.js +1 -0
- package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.types.js.map +1 -0
- package/lib/components/CommonComponents/Annotations/index.js +2 -0
- package/lib/components/CommonComponents/Annotations/index.js.map +1 -0
- package/lib/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.js +173 -0
- package/lib/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.js.map +1 -0
- package/lib/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.raw.js +126 -0
- package/lib/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.raw.js.map +1 -0
- package/lib/components/CommonComponents/CartesianChart.js +157 -132
- package/lib/components/CommonComponents/CartesianChart.js.map +1 -1
- package/lib/components/CommonComponents/CartesianChart.types.js.map +1 -1
- package/lib/components/CommonComponents/index.js +2 -0
- package/lib/components/CommonComponents/index.js.map +1 -1
- package/lib/components/CommonComponents/useCartesianChartStyles.styles.js +29 -13
- package/lib/components/CommonComponents/useCartesianChartStyles.styles.js.map +1 -1
- package/lib/components/CommonComponents/useCartesianChartStyles.styles.raw.js +14 -1
- package/lib/components/CommonComponents/useCartesianChartStyles.styles.raw.js.map +1 -1
- package/lib/components/CommonComponents/useChartPopoverStyles.styles.js +2 -6
- package/lib/components/CommonComponents/useChartPopoverStyles.styles.js.map +1 -1
- package/lib/components/CommonComponents/useChartPopoverStyles.styles.raw.js +3 -2
- package/lib/components/CommonComponents/useChartPopoverStyles.styles.raw.js.map +1 -1
- package/lib/components/DeclarativeChart/DeclarativeChart.js +39 -19
- package/lib/components/DeclarativeChart/DeclarativeChart.js.map +1 -1
- package/lib/components/DeclarativeChart/PlotlyColorAdapter.js +4 -8
- package/lib/components/DeclarativeChart/PlotlyColorAdapter.js.map +1 -1
- package/lib/components/DeclarativeChart/PlotlySchemaAdapter.js +644 -72
- package/lib/components/DeclarativeChart/PlotlySchemaAdapter.js.map +1 -1
- package/lib/components/DonutChart/Arc/useArcStyles.styles.js +23 -8
- package/lib/components/DonutChart/Arc/useArcStyles.styles.js.map +1 -1
- package/lib/components/DonutChart/Arc/useArcStyles.styles.raw.js +2 -2
- package/lib/components/DonutChart/Arc/useArcStyles.styles.raw.js.map +1 -1
- package/lib/components/DonutChart/useDonutChartStyles.styles.js +2 -2
- package/lib/components/DonutChart/useDonutChartStyles.styles.js.map +1 -1
- package/lib/components/GanttChart/GanttChart.js +3 -3
- package/lib/components/GanttChart/GanttChart.js.map +1 -1
- package/lib/components/GanttChart/GanttChart.types.js.map +1 -1
- package/lib/components/GanttChart/useGanttChartStyles.styles.js +3 -1
- package/lib/components/GanttChart/useGanttChartStyles.styles.js.map +1 -1
- package/lib/components/GanttChart/useGanttChartStyles.styles.raw.js +3 -1
- package/lib/components/GanttChart/useGanttChartStyles.styles.raw.js.map +1 -1
- package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.js +1 -1
- package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.js.map +1 -1
- package/lib/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.js +11 -6
- package/lib/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.js.map +1 -1
- package/lib/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.raw.js +3 -1
- package/lib/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.raw.js.map +1 -1
- package/lib/components/HeatMapChart/HeatMapChart.js +1 -1
- package/lib/components/HeatMapChart/HeatMapChart.js.map +1 -1
- package/lib/components/HeatMapChart/HeatMapChart.types.js.map +1 -1
- package/lib/components/HeatMapChart/useHeatMapChartStyles.styles.js +3 -1
- package/lib/components/HeatMapChart/useHeatMapChartStyles.styles.js.map +1 -1
- package/lib/components/HeatMapChart/useHeatMapChartStyles.styles.raw.js +3 -1
- package/lib/components/HeatMapChart/useHeatMapChartStyles.styles.raw.js.map +1 -1
- package/lib/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.js +25 -12
- package/lib/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.js.map +1 -1
- package/lib/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.raw.js +4 -4
- package/lib/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.raw.js.map +1 -1
- package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.js +2 -2
- package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.js.map +1 -1
- package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.js.map +1 -1
- package/lib/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.js +3 -1
- package/lib/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.js.map +1 -1
- package/lib/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.raw.js +3 -1
- package/lib/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.raw.js.map +1 -1
- package/lib/components/Legends/useLegendsStyles.styles.js +97 -37
- package/lib/components/Legends/useLegendsStyles.styles.js.map +1 -1
- package/lib/components/Legends/useLegendsStyles.styles.raw.js +10 -11
- package/lib/components/Legends/useLegendsStyles.styles.raw.js.map +1 -1
- package/lib/components/LineChart/LineChart.js +1 -1
- package/lib/components/LineChart/LineChart.js.map +1 -1
- package/lib/components/LineChart/useLineChartStyles.styles.js +15 -10
- package/lib/components/LineChart/useLineChartStyles.styles.js.map +1 -1
- package/lib/components/LineChart/useLineChartStyles.styles.raw.js +3 -1
- package/lib/components/LineChart/useLineChartStyles.styles.raw.js.map +1 -1
- package/lib/components/SankeyChart/useSankeyChartStyles.styles.js +13 -10
- package/lib/components/SankeyChart/useSankeyChartStyles.styles.js.map +1 -1
- package/lib/components/ScatterChart/ScatterChart.js +1 -1
- package/lib/components/ScatterChart/ScatterChart.js.map +1 -1
- package/lib/components/ScatterChart/ScatterChart.types.js.map +1 -1
- package/lib/components/ScatterChart/useScatterChartStyles.styles.js +13 -8
- package/lib/components/ScatterChart/useScatterChartStyles.styles.js.map +1 -1
- package/lib/components/ScatterChart/useScatterChartStyles.styles.raw.js +3 -1
- package/lib/components/ScatterChart/useScatterChartStyles.styles.raw.js.map +1 -1
- package/lib/components/VerticalBarChart/VerticalBarChart.js +1 -1
- package/lib/components/VerticalBarChart/VerticalBarChart.js.map +1 -1
- package/lib/components/VerticalBarChart/useVerticalBarChartStyles.styles.js +13 -8
- package/lib/components/VerticalBarChart/useVerticalBarChartStyles.styles.js.map +1 -1
- package/lib/components/VerticalBarChart/useVerticalBarChartStyles.styles.raw.js +3 -1
- package/lib/components/VerticalBarChart/useVerticalBarChartStyles.styles.raw.js.map +1 -1
- package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.js +1 -1
- package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.js.map +1 -1
- package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.types.js.map +1 -1
- package/lib/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.js +11 -6
- package/lib/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.js.map +1 -1
- package/lib/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.raw.js +3 -1
- package/lib/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.raw.js.map +1 -1
- package/lib/index.js +1 -0
- package/lib/index.js.map +1 -1
- package/lib/types/ChartAnnotation.js +1 -0
- package/lib/types/ChartAnnotation.js.map +1 -0
- package/lib/types/index.js +1 -0
- package/lib/types/index.js.map +1 -1
- package/lib/utilities/Common.styles.js +1 -2
- package/lib/utilities/Common.styles.js.map +1 -1
- package/lib/utilities/Common.styles.raw.js +1 -2
- package/lib/utilities/Common.styles.raw.js.map +1 -1
- package/lib/utilities/image-export-utils.js +108 -0
- package/lib/utilities/image-export-utils.js.map +1 -1
- package/lib/utilities/utilities.js +16 -13
- package/lib/utilities/utilities.js.map +1 -1
- package/lib-commonjs/AnnotationOnlyChart.js +6 -0
- package/lib-commonjs/AnnotationOnlyChart.js.map +1 -0
- package/lib-commonjs/components/AnnotationOnlyChart/AnnotationOnlyChart.js +219 -0
- package/lib-commonjs/components/AnnotationOnlyChart/AnnotationOnlyChart.js.map +1 -0
- package/lib-commonjs/components/AnnotationOnlyChart/AnnotationOnlyChart.types.js +6 -0
- package/lib-commonjs/components/AnnotationOnlyChart/AnnotationOnlyChart.types.js.map +1 -0
- package/lib-commonjs/components/AnnotationOnlyChart/index.js +7 -0
- package/lib-commonjs/components/AnnotationOnlyChart/index.js.map +1 -0
- package/lib-commonjs/components/AnnotationOnlyChart/useAnnotationOnlyChartStyles.styles.js +56 -0
- package/lib-commonjs/components/AnnotationOnlyChart/useAnnotationOnlyChartStyles.styles.js.map +1 -0
- package/lib-commonjs/components/AnnotationOnlyChart/useAnnotationOnlyChartStyles.styles.raw.js +33 -0
- package/lib-commonjs/components/AnnotationOnlyChart/useAnnotationOnlyChartStyles.styles.raw.js.map +1 -0
- package/lib-commonjs/components/AreaChart/useAreaChartStyles.styles.js +14 -15
- package/lib-commonjs/components/AreaChart/useAreaChartStyles.styles.js.map +1 -1
- package/lib-commonjs/components/AreaChart/useAreaChartStyles.styles.raw.js +3 -1
- package/lib-commonjs/components/AreaChart/useAreaChartStyles.styles.raw.js.map +1 -1
- package/lib-commonjs/components/ChartTable/useChartTableStyles.styles.js +74 -102
- package/lib-commonjs/components/ChartTable/useChartTableStyles.styles.js.map +1 -1
- package/lib-commonjs/components/ChartTable/useChartTableStyles.styles.raw.js +4 -4
- package/lib-commonjs/components/ChartTable/useChartTableStyles.styles.raw.js.map +1 -1
- package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.js +628 -0
- package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.js.map +1 -0
- package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.types.js +4 -0
- package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.types.js.map +1 -0
- package/lib-commonjs/components/CommonComponents/Annotations/index.js +7 -0
- package/lib-commonjs/components/CommonComponents/Annotations/index.js.map +1 -0
- package/lib-commonjs/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.js +265 -0
- package/lib-commonjs/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.js.map +1 -0
- package/lib-commonjs/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.raw.js +161 -0
- package/lib-commonjs/components/CommonComponents/Annotations/useChartAnnotationLayer.styles.raw.js.map +1 -0
- package/lib-commonjs/components/CommonComponents/CartesianChart.js +157 -131
- package/lib-commonjs/components/CommonComponents/CartesianChart.js.map +1 -1
- package/lib-commonjs/components/CommonComponents/CartesianChart.types.js.map +1 -1
- package/lib-commonjs/components/CommonComponents/index.js +2 -0
- package/lib-commonjs/components/CommonComponents/index.js.map +1 -1
- package/lib-commonjs/components/CommonComponents/useCartesianChartStyles.styles.js +32 -21
- package/lib-commonjs/components/CommonComponents/useCartesianChartStyles.styles.js.map +1 -1
- package/lib-commonjs/components/CommonComponents/useCartesianChartStyles.styles.raw.js +14 -1
- package/lib-commonjs/components/CommonComponents/useCartesianChartStyles.styles.raw.js.map +1 -1
- package/lib-commonjs/components/CommonComponents/useChartPopoverStyles.styles.js +0 -14
- package/lib-commonjs/components/CommonComponents/useChartPopoverStyles.styles.js.map +1 -1
- package/lib-commonjs/components/CommonComponents/useChartPopoverStyles.styles.raw.js +2 -1
- package/lib-commonjs/components/CommonComponents/useChartPopoverStyles.styles.raw.js.map +1 -1
- package/lib-commonjs/components/DeclarativeChart/DeclarativeChart.js +38 -18
- package/lib-commonjs/components/DeclarativeChart/DeclarativeChart.js.map +1 -1
- package/lib-commonjs/components/DeclarativeChart/PlotlyColorAdapter.js.map +1 -1
- package/lib-commonjs/components/DeclarativeChart/PlotlySchemaAdapter.js +630 -38
- package/lib-commonjs/components/DeclarativeChart/PlotlySchemaAdapter.js.map +1 -1
- package/lib-commonjs/components/DonutChart/Arc/useArcStyles.styles.js +25 -16
- package/lib-commonjs/components/DonutChart/Arc/useArcStyles.styles.js.map +1 -1
- package/lib-commonjs/components/DonutChart/Arc/useArcStyles.styles.raw.js +1 -1
- package/lib-commonjs/components/DonutChart/Arc/useArcStyles.styles.raw.js.map +1 -1
- package/lib-commonjs/components/DonutChart/useDonutChartStyles.styles.js +2 -2
- package/lib-commonjs/components/DonutChart/useDonutChartStyles.styles.js.map +1 -1
- package/lib-commonjs/components/GanttChart/GanttChart.js +3 -3
- package/lib-commonjs/components/GanttChart/GanttChart.js.map +1 -1
- package/lib-commonjs/components/GanttChart/GanttChart.types.js.map +1 -1
- package/lib-commonjs/components/GanttChart/useGanttChartStyles.styles.js +3 -1
- package/lib-commonjs/components/GanttChart/useGanttChartStyles.styles.js.map +1 -1
- package/lib-commonjs/components/GanttChart/useGanttChartStyles.styles.raw.js +3 -1
- package/lib-commonjs/components/GanttChart/useGanttChartStyles.styles.raw.js.map +1 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.js +1 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.js.map +1 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.js +14 -15
- package/lib-commonjs/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.js.map +1 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.raw.js +3 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.raw.js.map +1 -1
- package/lib-commonjs/components/HeatMapChart/HeatMapChart.js +1 -1
- package/lib-commonjs/components/HeatMapChart/HeatMapChart.js.map +1 -1
- package/lib-commonjs/components/HeatMapChart/HeatMapChart.types.js.map +1 -1
- package/lib-commonjs/components/HeatMapChart/useHeatMapChartStyles.styles.js +3 -1
- package/lib-commonjs/components/HeatMapChart/useHeatMapChartStyles.styles.js.map +1 -1
- package/lib-commonjs/components/HeatMapChart/useHeatMapChartStyles.styles.raw.js +3 -1
- package/lib-commonjs/components/HeatMapChart/useHeatMapChartStyles.styles.raw.js.map +1 -1
- package/lib-commonjs/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.js +47 -34
- package/lib-commonjs/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.js.map +1 -1
- package/lib-commonjs/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.raw.js +3 -3
- package/lib-commonjs/components/HorizontalBarChart/useHorizontalBarChartStyles.styles.raw.js.map +1 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.js +2 -2
- package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.js.map +1 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.types.js.map +1 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.js +3 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.js.map +1 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.raw.js +3 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/useHorizontalBarChartWithAxisStyles.styles.raw.js.map +1 -1
- package/lib-commonjs/components/Legends/useLegendsStyles.styles.js +144 -86
- package/lib-commonjs/components/Legends/useLegendsStyles.styles.js.map +1 -1
- package/lib-commonjs/components/Legends/useLegendsStyles.styles.raw.js +9 -10
- package/lib-commonjs/components/Legends/useLegendsStyles.styles.raw.js.map +1 -1
- package/lib-commonjs/components/LineChart/LineChart.js +1 -1
- package/lib-commonjs/components/LineChart/LineChart.js.map +1 -1
- package/lib-commonjs/components/LineChart/useLineChartStyles.styles.js +18 -19
- package/lib-commonjs/components/LineChart/useLineChartStyles.styles.js.map +1 -1
- package/lib-commonjs/components/LineChart/useLineChartStyles.styles.raw.js +3 -1
- package/lib-commonjs/components/LineChart/useLineChartStyles.styles.raw.js.map +1 -1
- package/lib-commonjs/components/SankeyChart/useSankeyChartStyles.styles.js +16 -19
- package/lib-commonjs/components/SankeyChart/useSankeyChartStyles.styles.js.map +1 -1
- package/lib-commonjs/components/ScatterChart/ScatterChart.js +1 -1
- package/lib-commonjs/components/ScatterChart/ScatterChart.js.map +1 -1
- package/lib-commonjs/components/ScatterChart/ScatterChart.types.js.map +1 -1
- package/lib-commonjs/components/ScatterChart/useScatterChartStyles.styles.js +16 -17
- package/lib-commonjs/components/ScatterChart/useScatterChartStyles.styles.js.map +1 -1
- package/lib-commonjs/components/ScatterChart/useScatterChartStyles.styles.raw.js +3 -1
- package/lib-commonjs/components/ScatterChart/useScatterChartStyles.styles.raw.js.map +1 -1
- package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.js +1 -1
- package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.js.map +1 -1
- package/lib-commonjs/components/VerticalBarChart/useVerticalBarChartStyles.styles.js +16 -17
- package/lib-commonjs/components/VerticalBarChart/useVerticalBarChartStyles.styles.js.map +1 -1
- package/lib-commonjs/components/VerticalBarChart/useVerticalBarChartStyles.styles.raw.js +3 -1
- package/lib-commonjs/components/VerticalBarChart/useVerticalBarChartStyles.styles.raw.js.map +1 -1
- package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.js +1 -1
- package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.js.map +1 -1
- package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.types.js.map +1 -1
- package/lib-commonjs/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.js +14 -15
- package/lib-commonjs/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.js.map +1 -1
- package/lib-commonjs/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.raw.js +3 -1
- package/lib-commonjs/components/VerticalStackedBarChart/useVerticalStackedBarChartStyles.styles.raw.js.map +1 -1
- package/lib-commonjs/index.js +1 -0
- package/lib-commonjs/index.js.map +1 -1
- package/lib-commonjs/types/ChartAnnotation.js +6 -0
- package/lib-commonjs/types/ChartAnnotation.js.map +1 -0
- package/lib-commonjs/types/index.js +1 -0
- package/lib-commonjs/types/index.js.map +1 -1
- package/lib-commonjs/utilities/Common.styles.js +1 -2
- package/lib-commonjs/utilities/Common.styles.js.map +1 -1
- package/lib-commonjs/utilities/Common.styles.raw.js +1 -2
- package/lib-commonjs/utilities/Common.styles.raw.js.map +1 -1
- package/lib-commonjs/utilities/image-export-utils.js +108 -0
- package/lib-commonjs/utilities/image-export-utils.js.map +1 -1
- package/lib-commonjs/utilities/utilities.js +16 -13
- package/lib-commonjs/utilities/utilities.js.map +1 -1
- package/package.json +11 -11
package/CHANGELOG.md
CHANGED
|
@@ -1,12 +1,33 @@
|
|
|
1
1
|
# Change Log - @fluentui/react-charts
|
|
2
2
|
|
|
3
|
-
This log was last generated on
|
|
3
|
+
This log was last generated on Tue, 11 Nov 2025 19:13:26 GMT and should not be manually modified.
|
|
4
4
|
|
|
5
5
|
<!-- Start content -->
|
|
6
6
|
|
|
7
|
+
## [9.3.6](https://github.com/microsoft/fluentui/tree/@fluentui/react-charts_v9.3.6)
|
|
8
|
+
|
|
9
|
+
Tue, 11 Nov 2025 19:13:26 GMT
|
|
10
|
+
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-charts_v9.3.5..@fluentui/react-charts_v9.3.6)
|
|
11
|
+
|
|
12
|
+
### Patches
|
|
13
|
+
|
|
14
|
+
- add reference lines logic in line and scatter chart ([PR #35474](https://github.com/microsoft/fluentui/pull/35474) by anushgupta@microsoft.com)
|
|
15
|
+
- add chart annotations ([PR #35457](https://github.com/microsoft/fluentui/pull/35457) by anushgupta@microsoft.com)
|
|
16
|
+
- add support for chart only annotation ([PR #35461](https://github.com/microsoft/fluentui/pull/35461) by anushgupta@microsoft.com)
|
|
17
|
+
- fix: adjust chart margin for continuous y-axis tick labels ([PR #35376](https://github.com/microsoft/fluentui/pull/35376) by kumarkshitij@microsoft.com)
|
|
18
|
+
- chore: Bump @griffel/react package. ([PR #35469](https://github.com/microsoft/fluentui/pull/35469) by estebanmu@microsoft.com)
|
|
19
|
+
- Bump @fluentui/react-button to v9.6.12 ([PR #35462](https://github.com/microsoft/fluentui/pull/35462) by beachball)
|
|
20
|
+
- Bump @fluentui/react-jsx-runtime to v9.3.3 ([PR #35462](https://github.com/microsoft/fluentui/pull/35462) by beachball)
|
|
21
|
+
- Bump @fluentui/react-overflow to v9.6.5 ([PR #35462](https://github.com/microsoft/fluentui/pull/35462) by beachball)
|
|
22
|
+
- Bump @fluentui/react-popover to v9.12.12 ([PR #35462](https://github.com/microsoft/fluentui/pull/35462) by beachball)
|
|
23
|
+
- Bump @fluentui/react-shared-contexts to v9.26.0 ([PR #35462](https://github.com/microsoft/fluentui/pull/35462) by beachball)
|
|
24
|
+
- Bump @fluentui/react-tabster to v9.26.10 ([PR #35462](https://github.com/microsoft/fluentui/pull/35462) by beachball)
|
|
25
|
+
- Bump @fluentui/react-tooltip to v9.8.11 ([PR #35462](https://github.com/microsoft/fluentui/pull/35462) by beachball)
|
|
26
|
+
- Bump @fluentui/react-utilities to v9.25.4 ([PR #35462](https://github.com/microsoft/fluentui/pull/35462) by beachball)
|
|
27
|
+
|
|
7
28
|
## [9.3.5](https://github.com/microsoft/fluentui/tree/@fluentui/react-charts_v9.3.5)
|
|
8
29
|
|
|
9
|
-
Thu, 06 Nov 2025
|
|
30
|
+
Thu, 06 Nov 2025 15:01:18 GMT
|
|
10
31
|
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-charts_v9.3.4..@fluentui/react-charts_v9.3.5)
|
|
11
32
|
|
|
12
33
|
### Patches
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { CurveFactory } from 'd3-shape';
|
|
2
2
|
import type { JSXElement } from '@fluentui/react-utilities';
|
|
3
|
+
import type { Margin } from '@fluentui/chart-utilities';
|
|
3
4
|
import { PositioningShorthand } from '@fluentui/react-positioning';
|
|
4
5
|
import * as React_2 from 'react';
|
|
5
6
|
import { RefObject } from 'react';
|
|
@@ -37,6 +38,50 @@ export declare interface AccessibilityProps {
|
|
|
37
38
|
*/
|
|
38
39
|
export declare function adjustPadding(sankey: SankeyLayoutGenerator, height: number, nodesInColumn: NodesInColumns): void;
|
|
39
40
|
|
|
41
|
+
export declare const AnnotationOnlyChart: React_2.FC<AnnotationOnlyChartProps>;
|
|
42
|
+
|
|
43
|
+
/**
|
|
44
|
+
* Props for the annotation-only chart renderer.
|
|
45
|
+
*/
|
|
46
|
+
export declare interface AnnotationOnlyChartProps {
|
|
47
|
+
/**
|
|
48
|
+
* Collection of annotations to render.
|
|
49
|
+
*/
|
|
50
|
+
annotations: ChartAnnotation[];
|
|
51
|
+
/** Optional layout title extracted from the Plotly schema. */
|
|
52
|
+
chartTitle?: string;
|
|
53
|
+
/** Optional descriptive text for accessibility. */
|
|
54
|
+
description?: string;
|
|
55
|
+
/** Desired width in pixels (if absent the chart will grow to fit the container). */
|
|
56
|
+
width?: number;
|
|
57
|
+
/** Desired height in pixels. */
|
|
58
|
+
height?: number;
|
|
59
|
+
/** Paper/background colour specified in the Plotly layout. */
|
|
60
|
+
paperBackgroundColor?: string;
|
|
61
|
+
/** Plot area background colour specified in the Plotly layout. */
|
|
62
|
+
plotBackgroundColor?: string;
|
|
63
|
+
/** Global layout font colour. */
|
|
64
|
+
fontColor?: string;
|
|
65
|
+
/** Global layout font family. */
|
|
66
|
+
fontFamily?: string;
|
|
67
|
+
/** Layout margin converted to padding for the outer wrapper. */
|
|
68
|
+
margin?: Partial<Margin>;
|
|
69
|
+
/** Component ref propagated by the DeclarativeChart surface. */
|
|
70
|
+
componentRef?: React_2.RefObject<Chart>;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export declare interface AnnotationPlotRect {
|
|
74
|
+
x: number;
|
|
75
|
+
y: number;
|
|
76
|
+
width: number;
|
|
77
|
+
height: number;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
export declare interface AnnotationPoint {
|
|
81
|
+
x: number;
|
|
82
|
+
y: number;
|
|
83
|
+
}
|
|
84
|
+
|
|
40
85
|
export declare const ARC_PADDING = 2;
|
|
41
86
|
|
|
42
87
|
export declare const AreaChart: React_2.FunctionComponent<AreaChartProps>;
|
|
@@ -378,6 +423,10 @@ export declare interface CartesianChartProps {
|
|
|
378
423
|
* @default 10
|
|
379
424
|
*/
|
|
380
425
|
xAxistickSize?: number;
|
|
426
|
+
/**
|
|
427
|
+
* Text annotations rendered on top of the chart area
|
|
428
|
+
*/
|
|
429
|
+
annotations?: ChartAnnotation[];
|
|
381
430
|
/**
|
|
382
431
|
* defines the space between the tick line and the data label
|
|
383
432
|
* @default 10
|
|
@@ -550,6 +599,15 @@ export declare interface CartesianChartProps {
|
|
|
550
599
|
* Use this to control `tickStep`, `tick0`, etc.
|
|
551
600
|
*/
|
|
552
601
|
yAxis?: AxisProps;
|
|
602
|
+
/**
|
|
603
|
+
*@default false
|
|
604
|
+
*Used for showing complete y axis lables */
|
|
605
|
+
showYAxisLables?: boolean;
|
|
606
|
+
/**
|
|
607
|
+
*@default false
|
|
608
|
+
*Used for to elipse y axis labes and show tooltip on x axis labels
|
|
609
|
+
*/
|
|
610
|
+
showYAxisLablesTooltip?: boolean;
|
|
553
611
|
}
|
|
554
612
|
|
|
555
613
|
/**
|
|
@@ -657,10 +715,18 @@ export declare interface CartesianChartStyles {
|
|
|
657
715
|
* Styles for the chart wrapper div
|
|
658
716
|
*/
|
|
659
717
|
chartWrapper?: string;
|
|
718
|
+
/**
|
|
719
|
+
* Styles for the element wrapping the svg and overlays for annotation
|
|
720
|
+
*/
|
|
721
|
+
plotContainer?: string;
|
|
660
722
|
/**
|
|
661
723
|
* Styles for the svg tooltip
|
|
662
724
|
*/
|
|
663
725
|
svgTooltip?: string;
|
|
726
|
+
/**
|
|
727
|
+
* Styles applied to the annotation layer root element
|
|
728
|
+
*/
|
|
729
|
+
annotationLayer?: string;
|
|
664
730
|
/**
|
|
665
731
|
* Styles for the chart svg element
|
|
666
732
|
*/
|
|
@@ -675,6 +741,141 @@ export declare interface Chart {
|
|
|
675
741
|
toImage?: (opts?: ImageExportOptions) => Promise<string>;
|
|
676
742
|
}
|
|
677
743
|
|
|
744
|
+
export declare interface ChartAnnotation {
|
|
745
|
+
/** Optional id for React reconciliation */
|
|
746
|
+
id?: string;
|
|
747
|
+
/** Primary textual content */
|
|
748
|
+
text: string;
|
|
749
|
+
/** Coordinates describing where the annotation should be anchored */
|
|
750
|
+
coordinates: ChartAnnotationCoordinate;
|
|
751
|
+
/** Layout customisation */
|
|
752
|
+
layout?: ChartAnnotationLayoutProps;
|
|
753
|
+
/** Visual styling */
|
|
754
|
+
style?: ChartAnnotationStyleProps;
|
|
755
|
+
/** Optional connector line that links the annotation to its anchor. */
|
|
756
|
+
connector?: ChartAnnotationConnectorProps;
|
|
757
|
+
/** Accessibility metadata */
|
|
758
|
+
accessibility?: ChartAnnotationAccessibilityProps;
|
|
759
|
+
/** Optional application specific metadata */
|
|
760
|
+
data?: Record<string, unknown>;
|
|
761
|
+
}
|
|
762
|
+
|
|
763
|
+
export declare interface ChartAnnotationAccessibilityProps {
|
|
764
|
+
/** Accessible label announced by assistive technologies */
|
|
765
|
+
ariaLabel?: string;
|
|
766
|
+
/** Accessible description id */
|
|
767
|
+
ariaDescribedBy?: string;
|
|
768
|
+
/** Custom role */
|
|
769
|
+
role?: string;
|
|
770
|
+
}
|
|
771
|
+
|
|
772
|
+
export declare type ChartAnnotationArrowHead = 'none' | 'start' | 'end' | 'both';
|
|
773
|
+
|
|
774
|
+
export declare interface ChartAnnotationConnectorProps {
|
|
775
|
+
/** Distance in pixels between the annotation element and the start of the connector. */
|
|
776
|
+
startPadding?: number;
|
|
777
|
+
/** Distance in pixels between the anchor point and the end of the connector. */
|
|
778
|
+
endPadding?: number;
|
|
779
|
+
/** Stroke colour for the connector. */
|
|
780
|
+
strokeColor?: string;
|
|
781
|
+
/** Stroke width in pixels. */
|
|
782
|
+
strokeWidth?: number;
|
|
783
|
+
/** SVG stroke dash array for dashed connectors. */
|
|
784
|
+
dashArray?: string;
|
|
785
|
+
/** Arrow head placement. Defaults to `'end'`. */
|
|
786
|
+
arrow?: ChartAnnotationArrowHead;
|
|
787
|
+
}
|
|
788
|
+
|
|
789
|
+
export declare interface ChartAnnotationContext {
|
|
790
|
+
/** Rectangle describing the drawable area of the chart (without margins) */
|
|
791
|
+
plotRect: AnnotationPlotRect;
|
|
792
|
+
/** Size of the owning SVG element */
|
|
793
|
+
svgRect: {
|
|
794
|
+
width: number;
|
|
795
|
+
height: number;
|
|
796
|
+
};
|
|
797
|
+
/** Indicates if layout should be mirrored */
|
|
798
|
+
isRtl?: boolean;
|
|
799
|
+
/** Primary x scale mapping data domain to pixels */
|
|
800
|
+
xScale?: (value: any) => number;
|
|
801
|
+
/** Primary y scale mapping data domain to pixels */
|
|
802
|
+
yScalePrimary?: (value: any) => number;
|
|
803
|
+
/** Secondary y scale when present */
|
|
804
|
+
yScaleSecondary?: (value: any) => number;
|
|
805
|
+
}
|
|
806
|
+
|
|
807
|
+
export declare type ChartAnnotationCoordinate = {
|
|
808
|
+
/** Cartesian data coordinates mapped through the chart scales or
|
|
809
|
+
* Normalised coordinates within the plot area (0-1) or
|
|
810
|
+
* Absolute pixel position relative to the chart's SVG origin
|
|
811
|
+
*/
|
|
812
|
+
type: 'data' | 'relative' | 'pixel';
|
|
813
|
+
/** x-axis value in the data domain */
|
|
814
|
+
x: number | string | Date;
|
|
815
|
+
/** y-axis value in the data domain */
|
|
816
|
+
y: number | string | Date;
|
|
817
|
+
/** Use the secondary y scale when available */
|
|
818
|
+
yAxis?: 'primary' | 'secondary';
|
|
819
|
+
};
|
|
820
|
+
|
|
821
|
+
export declare type ChartAnnotationHorizontalAlign = 'start' | 'center' | 'end';
|
|
822
|
+
|
|
823
|
+
export declare const ChartAnnotationLayer: React_2.FC<ChartAnnotationLayerProps>;
|
|
824
|
+
|
|
825
|
+
export declare interface ChartAnnotationLayerProps {
|
|
826
|
+
annotations?: ChartAnnotation[];
|
|
827
|
+
context: ChartAnnotationContext;
|
|
828
|
+
className?: string;
|
|
829
|
+
}
|
|
830
|
+
|
|
831
|
+
export declare interface ChartAnnotationLayoutProps {
|
|
832
|
+
/** Horizontal alignment of the annotation relative to the anchor point */
|
|
833
|
+
align?: ChartAnnotationHorizontalAlign;
|
|
834
|
+
/** Vertical alignment of the annotation relative to the anchor point */
|
|
835
|
+
verticalAlign?: ChartAnnotationVerticalAlign;
|
|
836
|
+
/** Horizontal offset in pixels applied after alignment */
|
|
837
|
+
offsetX?: number;
|
|
838
|
+
/** Vertical offset in pixels applied after alignment */
|
|
839
|
+
offsetY?: number;
|
|
840
|
+
/** Optional maximum width for wrapped text */
|
|
841
|
+
maxWidth?: number;
|
|
842
|
+
/** Whether the annotation should remain inside the plot area */
|
|
843
|
+
clipToBounds?: boolean;
|
|
844
|
+
/** Additional CSS classes applied to the annotation wrapper */
|
|
845
|
+
className?: string;
|
|
846
|
+
}
|
|
847
|
+
|
|
848
|
+
export declare interface ChartAnnotationStyleProps {
|
|
849
|
+
/** Text colour */
|
|
850
|
+
textColor?: string;
|
|
851
|
+
/** Background colour for the annotation container */
|
|
852
|
+
backgroundColor?: string;
|
|
853
|
+
/** Border colour */
|
|
854
|
+
borderColor?: string;
|
|
855
|
+
/** Border width */
|
|
856
|
+
borderWidth?: number;
|
|
857
|
+
/** Border style (solid, dashed, etc.) */
|
|
858
|
+
borderStyle?: React_2.CSSProperties['borderStyle'];
|
|
859
|
+
/** Border radius */
|
|
860
|
+
borderRadius?: number;
|
|
861
|
+
/** Box shadow applied to annotation */
|
|
862
|
+
boxShadow?: string;
|
|
863
|
+
/** Font size override */
|
|
864
|
+
fontSize?: string;
|
|
865
|
+
/** Font weight override */
|
|
866
|
+
fontWeight?: React_2.CSSProperties['fontWeight'];
|
|
867
|
+
/** Padding around the text. Accepts CSS shorthand notation */
|
|
868
|
+
padding?: string;
|
|
869
|
+
/** Opacity for the annotation container */
|
|
870
|
+
opacity?: number;
|
|
871
|
+
/** Optional class name applied to the annotation element */
|
|
872
|
+
className?: string;
|
|
873
|
+
/** Rotation, in degrees, applied to the annotation container */
|
|
874
|
+
rotation?: number;
|
|
875
|
+
}
|
|
876
|
+
|
|
877
|
+
export declare type ChartAnnotationVerticalAlign = 'top' | 'middle' | 'bottom';
|
|
878
|
+
|
|
678
879
|
/**
|
|
679
880
|
* Chart data mode for chart data text
|
|
680
881
|
* default: show the datapoint.x value
|
|
@@ -904,6 +1105,18 @@ export declare interface ColorFillBarsProps {
|
|
|
904
1105
|
|
|
905
1106
|
declare type ColorwayType = 'default' | 'builtin' | 'others' | undefined;
|
|
906
1107
|
|
|
1108
|
+
export declare type ConnectorRenderData = {
|
|
1109
|
+
key: string;
|
|
1110
|
+
start: AnnotationPoint;
|
|
1111
|
+
end: AnnotationPoint;
|
|
1112
|
+
strokeColor: string;
|
|
1113
|
+
strokeWidth: number;
|
|
1114
|
+
dashArray?: string;
|
|
1115
|
+
arrow: ChartAnnotationArrowHead;
|
|
1116
|
+
markerSize: number;
|
|
1117
|
+
markerStrokeWidth: number;
|
|
1118
|
+
};
|
|
1119
|
+
|
|
907
1120
|
/**
|
|
908
1121
|
* Used for custom callout data interface. As Area chart callout data will be prepared from given props.data,
|
|
909
1122
|
* Those required data passing to onRenderCalloutPerDataPoint and onRenderCalloutPerStack.
|
|
@@ -1497,17 +1710,6 @@ export declare interface GanttChartProps extends CartesianChartProps {
|
|
|
1497
1710
|
* @default 1/2
|
|
1498
1711
|
*/
|
|
1499
1712
|
yAxisPadding?: number;
|
|
1500
|
-
/**
|
|
1501
|
-
* If true, truncates y-axis tick labels longer than `noOfCharsToTruncate` with ellipses
|
|
1502
|
-
* and displays them in a tooltip on hover.
|
|
1503
|
-
* @default false
|
|
1504
|
-
*/
|
|
1505
|
-
showYAxisLablesTooltip?: boolean;
|
|
1506
|
-
/**
|
|
1507
|
-
* If true, renders full y-axis tick labels without truncation.
|
|
1508
|
-
* @default false
|
|
1509
|
-
*/
|
|
1510
|
-
showYAxisLables?: boolean;
|
|
1511
1713
|
/**
|
|
1512
1714
|
* If true, enables gradient fills for the bars.
|
|
1513
1715
|
* @default false
|
|
@@ -2102,19 +2304,10 @@ export declare interface HeatMapChartProps extends CartesianChartProps {
|
|
|
2102
2304
|
* The prop used to define the culture to localized the numbers
|
|
2103
2305
|
*/
|
|
2104
2306
|
culture?: string;
|
|
2105
|
-
/**
|
|
2106
|
-
*@default false
|
|
2107
|
-
*Used for showing complete y axis lables */
|
|
2108
|
-
showYAxisLables?: boolean;
|
|
2109
2307
|
/**
|
|
2110
2308
|
* @default alphabetical
|
|
2111
2309
|
* The prop used to decide order of string axis labels */
|
|
2112
2310
|
sortOrder?: 'none' | 'alphabetical';
|
|
2113
|
-
/**
|
|
2114
|
-
*@default false
|
|
2115
|
-
*Used for to elipse y axis labes and show tooltip on x axis labels
|
|
2116
|
-
*/
|
|
2117
|
-
showYAxisLablesTooltip?: boolean;
|
|
2118
2311
|
}
|
|
2119
2312
|
|
|
2120
2313
|
/**
|
|
@@ -2384,15 +2577,6 @@ export declare interface HorizontalBarChartWithAxisProps extends CartesianChartP
|
|
|
2384
2577
|
* it's padding between bar's or lines in the graph
|
|
2385
2578
|
*/
|
|
2386
2579
|
yAxisPadding?: number;
|
|
2387
|
-
/**
|
|
2388
|
-
*@default false
|
|
2389
|
-
*Used for to elipse y axis labes and show tooltip on x axis labels
|
|
2390
|
-
*/
|
|
2391
|
-
showYAxisLablesTooltip?: boolean;
|
|
2392
|
-
/**
|
|
2393
|
-
*@default false
|
|
2394
|
-
*Used for showing complete y axis lables */
|
|
2395
|
-
showYAxisLables?: boolean;
|
|
2396
2580
|
/**
|
|
2397
2581
|
* @default false
|
|
2398
2582
|
* The prop used to enable gradient fill color for the chart.
|
|
@@ -2480,6 +2664,7 @@ export declare interface HorizontalDataPoint {
|
|
|
2480
2664
|
|
|
2481
2665
|
declare interface IAxisData {
|
|
2482
2666
|
yAxisDomainValues: number[];
|
|
2667
|
+
yAxisTickText: string[];
|
|
2483
2668
|
}
|
|
2484
2669
|
|
|
2485
2670
|
/**
|
|
@@ -3257,11 +3442,11 @@ export declare interface ModifiedCartesianChartProps extends CartesianChartProps
|
|
|
3257
3442
|
/**
|
|
3258
3443
|
* Get the domain and range values
|
|
3259
3444
|
*/
|
|
3260
|
-
getDomainNRangeValues: (points: LineChartPoints[] | VerticalBarChartDataPoint[] | VerticalStackedBarDataPoint[] | HorizontalBarChartWithAxisDataPoint[] | GroupedVerticalBarChartData[] | HeatMapChartDataPoint[] | GanttChartDataPoint[], margins: Margins, width: number, chartType: ChartTypes, isRTL: boolean, xAxisType: XAxisTypes, barWidth: number, tickValues: Date[] | number[] | string[] | undefined
|
|
3445
|
+
getDomainNRangeValues: (points: LineChartPoints[] | VerticalBarChartDataPoint[] | VerticalStackedBarDataPoint[] | HorizontalBarChartWithAxisDataPoint[] | GroupedVerticalBarChartData[] | HeatMapChartDataPoint[] | GanttChartDataPoint[], margins: Margins, width: number, chartType: ChartTypes, isRTL: boolean, xAxisType: XAxisTypes, barWidth: number, tickValues: Date[] | number[] | string[] | undefined) => IDomainNRange;
|
|
3261
3446
|
/**
|
|
3262
3447
|
* Create the string y-axis
|
|
3263
3448
|
*/
|
|
3264
|
-
createStringYAxis: (yAxisParams: IYAxisParams, dataPoints: string[], isRtl: boolean, barWidth: number | undefined, chartType?: ChartTypes) => ScaleBand<string>;
|
|
3449
|
+
createStringYAxis: (yAxisParams: IYAxisParams, dataPoints: string[], isRtl: boolean, axisData: IAxisData, barWidth: number | undefined, chartType?: ChartTypes) => ScaleBand<string>;
|
|
3265
3450
|
/**
|
|
3266
3451
|
* Controls whether the numeric x-axis domain should be extended to start and end at nice rounded values.
|
|
3267
3452
|
* @default true
|
|
@@ -3326,6 +3511,13 @@ declare interface RenderFunction<P> {
|
|
|
3326
3511
|
(props?: P, defaultRender?: (props?: P) => JSXElement | null): JSXElement | null;
|
|
3327
3512
|
}
|
|
3328
3513
|
|
|
3514
|
+
export declare interface ResolvedAnnotationPosition {
|
|
3515
|
+
/** Final absolute position after applying layout and offsets */
|
|
3516
|
+
point: AnnotationPoint;
|
|
3517
|
+
/** Raw anchor position before offsets (used for connectors) */
|
|
3518
|
+
anchor: AnnotationPoint;
|
|
3519
|
+
}
|
|
3520
|
+
|
|
3329
3521
|
/**
|
|
3330
3522
|
* Responsive Child props
|
|
3331
3523
|
* {@docCategory ResponsiveContainer}
|
|
@@ -3657,10 +3849,6 @@ export declare interface ScatterChartProps extends CartesianChartProps {
|
|
|
3657
3849
|
* The prop used to define the culture to localized the numbers
|
|
3658
3850
|
*/
|
|
3659
3851
|
culture?: string;
|
|
3660
|
-
/**
|
|
3661
|
-
* The prop used to define the y axis labels tooltip visibility
|
|
3662
|
-
*/
|
|
3663
|
-
showYAxisLablesTooltip?: boolean;
|
|
3664
3852
|
}
|
|
3665
3853
|
|
|
3666
3854
|
/**
|
|
@@ -4107,15 +4295,6 @@ export declare interface VerticalStackedBarChartProps extends CartesianChartProp
|
|
|
4107
4295
|
* @default 'default'
|
|
4108
4296
|
*/
|
|
4109
4297
|
mode?: 'default' | 'plotly';
|
|
4110
|
-
/**
|
|
4111
|
-
*@default false
|
|
4112
|
-
*Used for to elipse y axis labes and show tooltip on x axis labels
|
|
4113
|
-
*/
|
|
4114
|
-
showYAxisLablesTooltip?: boolean;
|
|
4115
|
-
/**
|
|
4116
|
-
*@default false
|
|
4117
|
-
*Used for showing complete y axis lables */
|
|
4118
|
-
showYAxisLables?: boolean;
|
|
4119
4298
|
}
|
|
4120
4299
|
|
|
4121
4300
|
/**
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './components/AnnotationOnlyChart/index';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/AnnotationOnlyChart.ts"],"sourcesContent":["export * from './components/AnnotationOnlyChart/index';\n"],"names":[],"mappings":"AAAA,cAAc,yCAAyC"}
|
|
@@ -0,0 +1,208 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import { ChartAnnotationLayer } from '../CommonComponents/Annotations/ChartAnnotationLayer';
|
|
4
|
+
import { toImage as exportToImage } from '../../utilities/image-export-utils';
|
|
5
|
+
import { useRtl } from '../../utilities';
|
|
6
|
+
import { useAnnotationOnlyChartStyles } from './useAnnotationOnlyChartStyles.styles';
|
|
7
|
+
const DEFAULT_HEIGHT = 650;
|
|
8
|
+
const FALLBACK_WIDTH = 400;
|
|
9
|
+
const buildPadding = (margin)=>{
|
|
10
|
+
if (!margin) {
|
|
11
|
+
return undefined;
|
|
12
|
+
}
|
|
13
|
+
var _margin_t;
|
|
14
|
+
const top = (_margin_t = margin.t) !== null && _margin_t !== void 0 ? _margin_t : 0;
|
|
15
|
+
var _margin_r;
|
|
16
|
+
const right = (_margin_r = margin.r) !== null && _margin_r !== void 0 ? _margin_r : 0;
|
|
17
|
+
var _margin_b;
|
|
18
|
+
const bottom = (_margin_b = margin.b) !== null && _margin_b !== void 0 ? _margin_b : 0;
|
|
19
|
+
var _margin_l;
|
|
20
|
+
const left = (_margin_l = margin.l) !== null && _margin_l !== void 0 ? _margin_l : 0;
|
|
21
|
+
if (top === 0 && right === 0 && bottom === 0 && left === 0) {
|
|
22
|
+
return undefined;
|
|
23
|
+
}
|
|
24
|
+
return `${top}px ${right}px ${bottom}px ${left}px`;
|
|
25
|
+
};
|
|
26
|
+
export const AnnotationOnlyChart = (props)=>{
|
|
27
|
+
const { annotations, chartTitle, description, width, height, paperBackgroundColor, plotBackgroundColor, fontColor, fontFamily, margin, componentRef } = props;
|
|
28
|
+
const isRtl = useRtl();
|
|
29
|
+
const classes = useAnnotationOnlyChartStyles();
|
|
30
|
+
const containerRef = React.useRef(null);
|
|
31
|
+
const contentRef = React.useRef(null);
|
|
32
|
+
const [measuredWidth, setMeasuredWidth] = React.useState(width !== null && width !== void 0 ? width : 0);
|
|
33
|
+
const [contentHeight, setContentHeight] = React.useState(height !== null && height !== void 0 ? height : DEFAULT_HEIGHT);
|
|
34
|
+
React.useEffect(()=>{
|
|
35
|
+
if (typeof width === 'number' && width > 0) {
|
|
36
|
+
setMeasuredWidth(width);
|
|
37
|
+
return;
|
|
38
|
+
}
|
|
39
|
+
const node = containerRef.current;
|
|
40
|
+
if (!node || typeof ResizeObserver === 'undefined') {
|
|
41
|
+
const rect = node === null || node === void 0 ? void 0 : node.getBoundingClientRect();
|
|
42
|
+
if (rect && rect.width > 0) {
|
|
43
|
+
setMeasuredWidth(rect.width);
|
|
44
|
+
} else {
|
|
45
|
+
setMeasuredWidth((prev)=>prev > 0 ? prev : FALLBACK_WIDTH);
|
|
46
|
+
}
|
|
47
|
+
return;
|
|
48
|
+
}
|
|
49
|
+
const observer = new ResizeObserver((entries)=>{
|
|
50
|
+
const entry = entries[0];
|
|
51
|
+
if (!entry) {
|
|
52
|
+
return;
|
|
53
|
+
}
|
|
54
|
+
const newWidth = entry.contentRect.width;
|
|
55
|
+
if (newWidth > 0 && Math.abs(newWidth - measuredWidth) > 0.5) {
|
|
56
|
+
setMeasuredWidth(newWidth);
|
|
57
|
+
}
|
|
58
|
+
});
|
|
59
|
+
const rect = node.getBoundingClientRect();
|
|
60
|
+
if (rect.width > 0) {
|
|
61
|
+
setMeasuredWidth(rect.width);
|
|
62
|
+
}
|
|
63
|
+
observer.observe(node);
|
|
64
|
+
return ()=>observer.disconnect();
|
|
65
|
+
}, [
|
|
66
|
+
width,
|
|
67
|
+
measuredWidth
|
|
68
|
+
]);
|
|
69
|
+
const resolvedWidth = Math.max(measuredWidth || FALLBACK_WIDTH, 1);
|
|
70
|
+
const resolvedHeight = Math.max(height !== null && height !== void 0 ? height : DEFAULT_HEIGHT, 1);
|
|
71
|
+
React.useEffect(()=>{
|
|
72
|
+
const node = contentRef.current;
|
|
73
|
+
if (!node) {
|
|
74
|
+
setContentHeight((prev)=>prev > 0 ? prev : resolvedHeight);
|
|
75
|
+
return;
|
|
76
|
+
}
|
|
77
|
+
if (typeof ResizeObserver === 'undefined') {
|
|
78
|
+
const rect = node.getBoundingClientRect();
|
|
79
|
+
setContentHeight((prev)=>rect.height > 0 ? rect.height : prev > 0 ? prev : resolvedHeight);
|
|
80
|
+
return;
|
|
81
|
+
}
|
|
82
|
+
const observer = new ResizeObserver((entries)=>{
|
|
83
|
+
const entry = entries[0];
|
|
84
|
+
if (!entry) {
|
|
85
|
+
return;
|
|
86
|
+
}
|
|
87
|
+
const newHeight = entry.contentRect.height;
|
|
88
|
+
if (newHeight > 0) {
|
|
89
|
+
setContentHeight((prev)=>Math.abs(prev - newHeight) > 0.5 ? newHeight : prev);
|
|
90
|
+
}
|
|
91
|
+
});
|
|
92
|
+
const rect = node.getBoundingClientRect();
|
|
93
|
+
setContentHeight((prev)=>rect.height > 0 ? rect.height : prev > 0 ? prev : resolvedHeight);
|
|
94
|
+
observer.observe(node);
|
|
95
|
+
return ()=>observer.disconnect();
|
|
96
|
+
}, [
|
|
97
|
+
resolvedHeight,
|
|
98
|
+
resolvedWidth,
|
|
99
|
+
annotations,
|
|
100
|
+
chartTitle,
|
|
101
|
+
description,
|
|
102
|
+
margin,
|
|
103
|
+
plotBackgroundColor,
|
|
104
|
+
paperBackgroundColor,
|
|
105
|
+
fontColor,
|
|
106
|
+
fontFamily
|
|
107
|
+
]);
|
|
108
|
+
const svgHeight = Math.max(Math.ceil(contentHeight || 0), resolvedHeight);
|
|
109
|
+
const context = {
|
|
110
|
+
plotRect: {
|
|
111
|
+
x: 0,
|
|
112
|
+
y: 0,
|
|
113
|
+
width: resolvedWidth,
|
|
114
|
+
height: resolvedHeight
|
|
115
|
+
},
|
|
116
|
+
svgRect: {
|
|
117
|
+
width: resolvedWidth,
|
|
118
|
+
height: resolvedHeight
|
|
119
|
+
},
|
|
120
|
+
isRtl
|
|
121
|
+
};
|
|
122
|
+
const padding = buildPadding(margin);
|
|
123
|
+
// Inline styles for dynamic values that can't be in makeStyles
|
|
124
|
+
const rootStyle = React.useMemo(()=>({
|
|
125
|
+
width: width ? `${width}px` : '100%',
|
|
126
|
+
minHeight: resolvedHeight,
|
|
127
|
+
...paperBackgroundColor && {
|
|
128
|
+
backgroundColor: paperBackgroundColor
|
|
129
|
+
},
|
|
130
|
+
...fontColor && {
|
|
131
|
+
color: fontColor
|
|
132
|
+
},
|
|
133
|
+
...fontFamily && {
|
|
134
|
+
fontFamily
|
|
135
|
+
},
|
|
136
|
+
...padding && {
|
|
137
|
+
padding
|
|
138
|
+
}
|
|
139
|
+
}), [
|
|
140
|
+
fontColor,
|
|
141
|
+
fontFamily,
|
|
142
|
+
paperBackgroundColor,
|
|
143
|
+
padding,
|
|
144
|
+
resolvedHeight,
|
|
145
|
+
width
|
|
146
|
+
]);
|
|
147
|
+
const contentStyle = React.useMemo(()=>({
|
|
148
|
+
...plotBackgroundColor && {
|
|
149
|
+
backgroundColor: plotBackgroundColor
|
|
150
|
+
}
|
|
151
|
+
}), [
|
|
152
|
+
plotBackgroundColor
|
|
153
|
+
]);
|
|
154
|
+
const resolvedAnnotations = annotations !== null && annotations !== void 0 ? annotations : [];
|
|
155
|
+
const hasAnnotations = resolvedAnnotations.length > 0;
|
|
156
|
+
const ariaLabel = hasAnnotations ? description !== null && description !== void 0 ? description : chartTitle : undefined;
|
|
157
|
+
React.useImperativeHandle(componentRef, ()=>{
|
|
158
|
+
const chartHandle = {
|
|
159
|
+
chartContainer: containerRef.current,
|
|
160
|
+
toImage: (opts)=>{
|
|
161
|
+
if (!containerRef.current) {
|
|
162
|
+
return Promise.reject(new Error('Chart container is not defined'));
|
|
163
|
+
}
|
|
164
|
+
return exportToImage(containerRef.current, undefined, isRtl, opts);
|
|
165
|
+
}
|
|
166
|
+
};
|
|
167
|
+
return chartHandle;
|
|
168
|
+
}, [
|
|
169
|
+
isRtl
|
|
170
|
+
]);
|
|
171
|
+
return /*#__PURE__*/ React.createElement("div", {
|
|
172
|
+
ref: containerRef,
|
|
173
|
+
"data-chart-annotation-container": "true"
|
|
174
|
+
}, /*#__PURE__*/ React.createElement("svg", {
|
|
175
|
+
width: resolvedWidth,
|
|
176
|
+
height: svgHeight,
|
|
177
|
+
viewBox: `0 0 ${resolvedWidth} ${svgHeight}`,
|
|
178
|
+
style: {
|
|
179
|
+
width: width ? `${width}px` : '100%',
|
|
180
|
+
height: `${svgHeight}px`,
|
|
181
|
+
display: 'block'
|
|
182
|
+
},
|
|
183
|
+
role: ariaLabel ? 'img' : undefined,
|
|
184
|
+
"aria-label": ariaLabel
|
|
185
|
+
}, /*#__PURE__*/ React.createElement("foreignObject", {
|
|
186
|
+
x: 0,
|
|
187
|
+
y: 0,
|
|
188
|
+
width: resolvedWidth,
|
|
189
|
+
height: svgHeight
|
|
190
|
+
}, /*#__PURE__*/ React.createElement("div", {
|
|
191
|
+
ref: contentRef,
|
|
192
|
+
className: classes.root,
|
|
193
|
+
style: rootStyle,
|
|
194
|
+
"data-chart-annotation-only": "true",
|
|
195
|
+
"aria-label": ariaLabel
|
|
196
|
+
}, chartTitle && /*#__PURE__*/ React.createElement("span", {
|
|
197
|
+
className: classes.title,
|
|
198
|
+
"aria-hidden": "true"
|
|
199
|
+
}, chartTitle), /*#__PURE__*/ React.createElement("div", {
|
|
200
|
+
className: classes.content,
|
|
201
|
+
style: contentStyle,
|
|
202
|
+
role: "presentation"
|
|
203
|
+
}, hasAnnotations ? /*#__PURE__*/ React.createElement(ChartAnnotationLayer, {
|
|
204
|
+
annotations: resolvedAnnotations,
|
|
205
|
+
context: context
|
|
206
|
+
}) : null)))));
|
|
207
|
+
};
|
|
208
|
+
AnnotationOnlyChart.displayName = 'AnnotationOnlyChart';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/components/AnnotationOnlyChart/AnnotationOnlyChart.tsx"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { ChartAnnotationLayer } from '../CommonComponents/Annotations/ChartAnnotationLayer';\nimport { toImage as exportToImage } from '../../utilities/image-export-utils';\nimport { useRtl } from '../../utilities';\nimport { useAnnotationOnlyChartStyles } from './useAnnotationOnlyChartStyles.styles';\nimport type { AnnotationOnlyChartProps } from './AnnotationOnlyChart.types';\nimport type { Chart, ImageExportOptions } from '../../types/index';\nimport type { ChartAnnotationContext } from '../CommonComponents/Annotations/ChartAnnotationLayer.types';\n\nconst DEFAULT_HEIGHT = 650;\nconst FALLBACK_WIDTH = 400;\n\nconst buildPadding = (margin: AnnotationOnlyChartProps['margin']): string | undefined => {\n if (!margin) {\n return undefined;\n }\n\n const top = margin.t ?? 0;\n const right = margin.r ?? 0;\n const bottom = margin.b ?? 0;\n const left = margin.l ?? 0;\n\n if (top === 0 && right === 0 && bottom === 0 && left === 0) {\n return undefined;\n }\n\n return `${top}px ${right}px ${bottom}px ${left}px`;\n};\n\nexport const AnnotationOnlyChart: React.FC<AnnotationOnlyChartProps> = props => {\n const {\n annotations,\n chartTitle,\n description,\n width,\n height,\n paperBackgroundColor,\n plotBackgroundColor,\n fontColor,\n fontFamily,\n margin,\n componentRef,\n } = props;\n\n const isRtl = useRtl();\n const classes = useAnnotationOnlyChartStyles();\n const containerRef = React.useRef<HTMLDivElement | null>(null);\n const contentRef = React.useRef<HTMLDivElement | null>(null);\n const [measuredWidth, setMeasuredWidth] = React.useState<number>(width ?? 0);\n const [contentHeight, setContentHeight] = React.useState<number>(height ?? DEFAULT_HEIGHT);\n\n React.useEffect(() => {\n if (typeof width === 'number' && width > 0) {\n setMeasuredWidth(width);\n return;\n }\n\n const node = containerRef.current;\n if (!node || typeof ResizeObserver === 'undefined') {\n const rect = node?.getBoundingClientRect();\n if (rect && rect.width > 0) {\n setMeasuredWidth(rect.width);\n } else {\n setMeasuredWidth(prev => (prev > 0 ? prev : FALLBACK_WIDTH));\n }\n return;\n }\n\n const observer = new ResizeObserver(entries => {\n const entry = entries[0];\n if (!entry) {\n return;\n }\n const newWidth = entry.contentRect.width;\n if (newWidth > 0 && Math.abs(newWidth - measuredWidth) > 0.5) {\n setMeasuredWidth(newWidth);\n }\n });\n\n const rect = node.getBoundingClientRect();\n if (rect.width > 0) {\n setMeasuredWidth(rect.width);\n }\n\n observer.observe(node);\n return () => observer.disconnect();\n }, [width, measuredWidth]);\n\n const resolvedWidth = Math.max(measuredWidth || FALLBACK_WIDTH, 1);\n const resolvedHeight = Math.max(height ?? DEFAULT_HEIGHT, 1);\n\n React.useEffect(() => {\n const node = contentRef.current;\n if (!node) {\n setContentHeight(prev => (prev > 0 ? prev : resolvedHeight));\n return;\n }\n\n if (typeof ResizeObserver === 'undefined') {\n const rect = node.getBoundingClientRect();\n setContentHeight(prev => (rect.height > 0 ? rect.height : prev > 0 ? prev : resolvedHeight));\n return;\n }\n\n const observer = new ResizeObserver(entries => {\n const entry = entries[0];\n if (!entry) {\n return;\n }\n\n const newHeight = entry.contentRect.height;\n if (newHeight > 0) {\n setContentHeight(prev => (Math.abs(prev - newHeight) > 0.5 ? newHeight : prev));\n }\n });\n\n const rect = node.getBoundingClientRect();\n setContentHeight(prev => (rect.height > 0 ? rect.height : prev > 0 ? prev : resolvedHeight));\n\n observer.observe(node);\n return () => observer.disconnect();\n }, [\n resolvedHeight,\n resolvedWidth,\n annotations,\n chartTitle,\n description,\n margin,\n plotBackgroundColor,\n paperBackgroundColor,\n fontColor,\n fontFamily,\n ]);\n\n const svgHeight = Math.max(Math.ceil(contentHeight || 0), resolvedHeight);\n\n const context: ChartAnnotationContext = {\n plotRect: { x: 0, y: 0, width: resolvedWidth, height: resolvedHeight },\n svgRect: { width: resolvedWidth, height: resolvedHeight },\n isRtl,\n };\n\n const padding = buildPadding(margin);\n\n // Inline styles for dynamic values that can't be in makeStyles\n const rootStyle: React.CSSProperties = React.useMemo(\n () => ({\n width: width ? `${width}px` : '100%',\n minHeight: resolvedHeight,\n ...(paperBackgroundColor && { backgroundColor: paperBackgroundColor }),\n ...(fontColor && { color: fontColor }),\n ...(fontFamily && { fontFamily }),\n ...(padding && { padding }),\n }),\n [fontColor, fontFamily, paperBackgroundColor, padding, resolvedHeight, width],\n );\n\n const contentStyle: React.CSSProperties = React.useMemo(\n () => ({\n ...(plotBackgroundColor && { backgroundColor: plotBackgroundColor }),\n }),\n [plotBackgroundColor],\n );\n\n const resolvedAnnotations = annotations ?? [];\n const hasAnnotations = resolvedAnnotations.length > 0;\n const ariaLabel = hasAnnotations ? description ?? chartTitle : undefined;\n\n React.useImperativeHandle(\n componentRef,\n () => {\n const chartHandle: Chart = {\n chartContainer: containerRef.current,\n toImage: (opts?: ImageExportOptions) => {\n if (!containerRef.current) {\n return Promise.reject(new Error('Chart container is not defined'));\n }\n\n return exportToImage(containerRef.current, undefined, isRtl, opts);\n },\n };\n\n return chartHandle;\n },\n [isRtl],\n );\n\n return (\n <div ref={containerRef} data-chart-annotation-container=\"true\">\n <svg\n width={resolvedWidth}\n height={svgHeight}\n viewBox={`0 0 ${resolvedWidth} ${svgHeight}`}\n style={{ width: width ? `${width}px` : '100%', height: `${svgHeight}px`, display: 'block' }}\n role={ariaLabel ? 'img' : undefined}\n aria-label={ariaLabel}\n >\n <foreignObject x={0} y={0} width={resolvedWidth} height={svgHeight}>\n <div\n ref={contentRef}\n className={classes.root}\n style={rootStyle}\n data-chart-annotation-only=\"true\"\n aria-label={ariaLabel}\n >\n {chartTitle && (\n <span className={classes.title} aria-hidden=\"true\">\n {chartTitle}\n </span>\n )}\n <div className={classes.content} style={contentStyle} role=\"presentation\">\n {hasAnnotations ? <ChartAnnotationLayer annotations={resolvedAnnotations} context={context} /> : null}\n </div>\n </div>\n </foreignObject>\n </svg>\n </div>\n );\n};\n\nAnnotationOnlyChart.displayName = 'AnnotationOnlyChart';\n"],"names":["React","ChartAnnotationLayer","toImage","exportToImage","useRtl","useAnnotationOnlyChartStyles","DEFAULT_HEIGHT","FALLBACK_WIDTH","buildPadding","margin","undefined","top","t","right","r","bottom","b","left","l","AnnotationOnlyChart","props","annotations","chartTitle","description","width","height","paperBackgroundColor","plotBackgroundColor","fontColor","fontFamily","componentRef","isRtl","classes","containerRef","useRef","contentRef","measuredWidth","setMeasuredWidth","useState","contentHeight","setContentHeight","useEffect","node","current","ResizeObserver","rect","getBoundingClientRect","prev","observer","entries","entry","newWidth","contentRect","Math","abs","observe","disconnect","resolvedWidth","max","resolvedHeight","newHeight","svgHeight","ceil","context","plotRect","x","y","svgRect","padding","rootStyle","useMemo","minHeight","backgroundColor","color","contentStyle","resolvedAnnotations","hasAnnotations","length","ariaLabel","useImperativeHandle","chartHandle","chartContainer","opts","Promise","reject","Error","div","ref","data-chart-annotation-container","svg","viewBox","style","display","role","aria-label","foreignObject","className","root","data-chart-annotation-only","span","title","aria-hidden","content","displayName"],"mappings":"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"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/components/AnnotationOnlyChart/AnnotationOnlyChart.types.ts"],"sourcesContent":["import * as React from 'react';\nimport type { ChartAnnotation } from '../../types/ChartAnnotation';\nimport type { Chart } from '../../types/index';\nimport type { Margin } from '@fluentui/chart-utilities';\n\n/**\n * Props for the annotation-only chart renderer.\n */\nexport interface AnnotationOnlyChartProps {\n /**\n * Collection of annotations to render.\n */\n annotations: ChartAnnotation[];\n /** Optional layout title extracted from the Plotly schema. */\n chartTitle?: string;\n /** Optional descriptive text for accessibility. */\n description?: string;\n /** Desired width in pixels (if absent the chart will grow to fit the container). */\n width?: number;\n /** Desired height in pixels. */\n height?: number;\n /** Paper/background colour specified in the Plotly layout. */\n paperBackgroundColor?: string;\n /** Plot area background colour specified in the Plotly layout. */\n plotBackgroundColor?: string;\n /** Global layout font colour. */\n fontColor?: string;\n /** Global layout font family. */\n fontFamily?: string;\n /** Layout margin converted to padding for the outer wrapper. */\n margin?: Partial<Margin>;\n /** Component ref propagated by the DeclarativeChart surface. */\n componentRef?: React.RefObject<Chart>;\n}\n"],"names":["React"],"mappings":"AAAA,YAAYA,WAAW,QAAQ"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/components/AnnotationOnlyChart/index.ts"],"sourcesContent":["export * from './AnnotationOnlyChart';\nexport * from './AnnotationOnlyChart.types';\n"],"names":[],"mappings":"AAAA,cAAc,wBAAwB;AACtC,cAAc,8BAA8B"}
|