@fluentui/react-charts 9.0.0 → 9.0.2

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.
Files changed (79) hide show
  1. package/CHANGELOG.md +33 -2
  2. package/dist/index.d.ts +463 -36
  3. package/lib/GaugeChart.js +1 -0
  4. package/lib/GaugeChart.js.map +1 -0
  5. package/lib/GroupedVerticalBarChart.js +1 -0
  6. package/lib/GroupedVerticalBarChart.js.map +1 -0
  7. package/lib/ScatterChart.js +1 -0
  8. package/lib/ScatterChart.js.map +1 -0
  9. package/lib/components/GaugeChart/GaugeChart.js +589 -0
  10. package/lib/components/GaugeChart/GaugeChart.js.map +1 -0
  11. package/lib/components/GaugeChart/GaugeChart.types.js +4 -0
  12. package/lib/components/GaugeChart/GaugeChart.types.js.map +1 -0
  13. package/lib/components/GaugeChart/index.js +3 -0
  14. package/lib/components/GaugeChart/index.js.map +1 -0
  15. package/lib/components/GaugeChart/useGaugeChartStyles.styles.js +174 -0
  16. package/lib/components/GaugeChart/useGaugeChartStyles.styles.js.map +1 -0
  17. package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.js +492 -0
  18. package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.js.map +1 -0
  19. package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.types.js +4 -0
  20. package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.types.js.map +1 -0
  21. package/lib/components/GroupedVerticalBarChart/index.js +3 -0
  22. package/lib/components/GroupedVerticalBarChart/index.js.map +1 -0
  23. package/lib/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.js +90 -0
  24. package/lib/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.js.map +1 -0
  25. package/lib/components/Legends/Legends.types.js.map +1 -1
  26. package/lib/components/LineChart/LineChart.js.map +1 -1
  27. package/lib/components/ScatterChart/ScatterChart.js +478 -0
  28. package/lib/components/ScatterChart/ScatterChart.js.map +1 -0
  29. package/lib/components/ScatterChart/ScatterChart.types.js +4 -0
  30. package/lib/components/ScatterChart/ScatterChart.types.js.map +1 -0
  31. package/lib/components/ScatterChart/index.js +3 -0
  32. package/lib/components/ScatterChart/index.js.map +1 -0
  33. package/lib/components/ScatterChart/useScatterChartStyles.styles.js +65 -0
  34. package/lib/components/ScatterChart/useScatterChartStyles.styles.js.map +1 -0
  35. package/lib/components/Sparkline/Sparkline.js.map +1 -1
  36. package/lib/index.js +3 -0
  37. package/lib/index.js.map +1 -1
  38. package/lib/types/DataPoint.js.map +1 -1
  39. package/lib/utilities/utilities.js +123 -5
  40. package/lib/utilities/utilities.js.map +1 -1
  41. package/lib-commonjs/GaugeChart.js +6 -0
  42. package/lib-commonjs/GaugeChart.js.map +1 -0
  43. package/lib-commonjs/GroupedVerticalBarChart.js +6 -0
  44. package/lib-commonjs/GroupedVerticalBarChart.js.map +1 -0
  45. package/lib-commonjs/ScatterChart.js +6 -0
  46. package/lib-commonjs/ScatterChart.js.map +1 -0
  47. package/lib-commonjs/components/GaugeChart/GaugeChart.js +618 -0
  48. package/lib-commonjs/components/GaugeChart/GaugeChart.js.map +1 -0
  49. package/lib-commonjs/components/GaugeChart/GaugeChart.types.js +7 -0
  50. package/lib-commonjs/components/GaugeChart/GaugeChart.types.js.map +1 -0
  51. package/lib-commonjs/components/GaugeChart/index.js +8 -0
  52. package/lib-commonjs/components/GaugeChart/index.js.map +1 -0
  53. package/lib-commonjs/components/GaugeChart/useGaugeChartStyles.styles.js +252 -0
  54. package/lib-commonjs/components/GaugeChart/useGaugeChartStyles.styles.js.map +1 -0
  55. package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.js +498 -0
  56. package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.js.map +1 -0
  57. package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.types.js +7 -0
  58. package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.types.js.map +1 -0
  59. package/lib-commonjs/components/GroupedVerticalBarChart/index.js +8 -0
  60. package/lib-commonjs/components/GroupedVerticalBarChart/index.js.map +1 -0
  61. package/lib-commonjs/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.js +139 -0
  62. package/lib-commonjs/components/GroupedVerticalBarChart/useGroupedVerticalBarChartStyles.styles.js.map +1 -0
  63. package/lib-commonjs/components/Legends/Legends.types.js.map +1 -1
  64. package/lib-commonjs/components/LineChart/LineChart.js.map +1 -1
  65. package/lib-commonjs/components/ScatterChart/ScatterChart.js +484 -0
  66. package/lib-commonjs/components/ScatterChart/ScatterChart.js.map +1 -0
  67. package/lib-commonjs/components/ScatterChart/ScatterChart.types.js +7 -0
  68. package/lib-commonjs/components/ScatterChart/ScatterChart.types.js.map +1 -0
  69. package/lib-commonjs/components/ScatterChart/index.js +8 -0
  70. package/lib-commonjs/components/ScatterChart/index.js.map +1 -0
  71. package/lib-commonjs/components/ScatterChart/useScatterChartStyles.styles.js +96 -0
  72. package/lib-commonjs/components/ScatterChart/useScatterChartStyles.styles.js.map +1 -0
  73. package/lib-commonjs/components/Sparkline/Sparkline.js.map +1 -1
  74. package/lib-commonjs/index.js +3 -0
  75. package/lib-commonjs/index.js.map +1 -1
  76. package/lib-commonjs/types/DataPoint.js.map +1 -1
  77. package/lib-commonjs/utilities/utilities.js +115 -5
  78. package/lib-commonjs/utilities/utilities.js.map +1 -1
  79. package/package.json +9 -9
package/CHANGELOG.md CHANGED
@@ -1,12 +1,43 @@
1
1
  # Change Log - @fluentui/react-charts
2
2
 
3
- This log was last generated on Wed, 26 Mar 2025 15:52:05 GMT and should not be manually modified.
3
+ This log was last generated on Tue, 01 Apr 2025 14:05:32 GMT and should not be manually modified.
4
4
 
5
5
  <!-- Start content -->
6
6
 
7
+ ## [9.0.2](https://github.com/microsoft/fluentui/tree/@fluentui/react-charts_v9.0.2)
8
+
9
+ Tue, 01 Apr 2025 14:05:32 GMT
10
+ [Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-charts_v9.0.1..@fluentui/react-charts_v9.0.2)
11
+
12
+ ### Patches
13
+
14
+ - Migrate Gauge chart to V9 ([PR #33998](https://github.com/microsoft/fluentui/pull/33998) by 74965306+Anush2303@users.noreply.github.com)
15
+ - (feat) Implement grouped vertical bar and scatter chart ([PR #34091](https://github.com/microsoft/fluentui/pull/34091) by 98592573+AtishayMsft@users.noreply.github.com)
16
+ - Bump @fluentui/react-button to v9.4.4 ([PR #34129](https://github.com/microsoft/fluentui/pull/34129) by beachball)
17
+ - Bump @fluentui/react-overflow to v9.3.4 ([PR #34129](https://github.com/microsoft/fluentui/pull/34129) by beachball)
18
+ - Bump @fluentui/react-popover to v9.10.4 ([PR #34129](https://github.com/microsoft/fluentui/pull/34129) by beachball)
19
+ - Bump @fluentui/react-tabster to v9.24.4 ([PR #34129](https://github.com/microsoft/fluentui/pull/34129) by beachball)
20
+ - Bump @fluentui/react-tooltip to v9.6.4 ([PR #34129](https://github.com/microsoft/fluentui/pull/34129) by beachball)
21
+
22
+ ## [9.0.1](https://github.com/microsoft/fluentui/tree/@fluentui/react-charts_v9.0.1)
23
+
24
+ Thu, 27 Mar 2025 21:12:51 GMT
25
+ [Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-charts_v9.0.0..@fluentui/react-charts_v9.0.1)
26
+
27
+ ### Patches
28
+
29
+ - Bump @fluentui/react-button to v9.4.3 ([PR #34034](https://github.com/microsoft/fluentui/pull/34034) by beachball)
30
+ - Bump @fluentui/react-jsx-runtime to v9.0.53 ([PR #34034](https://github.com/microsoft/fluentui/pull/34034) by beachball)
31
+ - Bump @fluentui/react-overflow to v9.3.3 ([PR #34034](https://github.com/microsoft/fluentui/pull/34034) by beachball)
32
+ - Bump @fluentui/react-popover to v9.10.3 ([PR #34034](https://github.com/microsoft/fluentui/pull/34034) by beachball)
33
+ - Bump @fluentui/react-shared-contexts to v9.23.1 ([PR #34034](https://github.com/microsoft/fluentui/pull/34034) by beachball)
34
+ - Bump @fluentui/react-tabster to v9.24.3 ([PR #34034](https://github.com/microsoft/fluentui/pull/34034) by beachball)
35
+ - Bump @fluentui/react-tooltip to v9.6.3 ([PR #34034](https://github.com/microsoft/fluentui/pull/34034) by beachball)
36
+ - Bump @fluentui/react-utilities to v9.18.23 ([PR #34034](https://github.com/microsoft/fluentui/pull/34034) by beachball)
37
+
7
38
  ## [9.0.0](https://github.com/microsoft/fluentui/tree/@fluentui/react-charts_v9.0.0)
8
39
 
9
- Wed, 26 Mar 2025 15:52:05 GMT
40
+ Wed, 26 Mar 2025 15:52:37 GMT
10
41
  [Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-charts-preview_v0.2.2..@fluentui/react-charts_v9.0.0)
11
42
 
12
43
  ### Patches
package/dist/index.d.ts CHANGED
@@ -22,6 +22,40 @@ export declare interface AccessibilityProps {
22
22
  ariaDescribedBy?: string;
23
23
  }
24
24
 
25
+ export declare const ARC_PADDING = 2;
26
+
27
+ /**
28
+ * {@docCategory ChartData}
29
+ */
30
+ declare interface BaseDataPoint {
31
+ /**
32
+ * Defines the function that is executed on clicking line
33
+ */
34
+ onDataPointClick?: () => void;
35
+ /**
36
+ * Callout data for x axis
37
+ */
38
+ xAxisCalloutData?: string;
39
+ /**
40
+ * Callout data for y axis
41
+ */
42
+ yAxisCalloutData?: string | {
43
+ [id: string]: number;
44
+ };
45
+ /**
46
+ * Whether to hide callout data for the point.
47
+ */
48
+ hideCallout?: boolean;
49
+ /**
50
+ * Accessibility data for callout
51
+ */
52
+ callOutAccessibilityData?: AccessibilityProps;
53
+ /**
54
+ * X axis Accessibility data for callout
55
+ */
56
+ xAxisCalloutAccessibilityData?: AccessibilityProps;
57
+ }
58
+
25
59
  export declare interface Basestate {
26
60
  _width?: number;
27
61
  _height?: number;
@@ -48,6 +82,14 @@ export declare interface Basestate {
48
82
  containerHeight?: number;
49
83
  }
50
84
 
85
+ export declare const BREAKPOINTS: {
86
+ minRadius: number;
87
+ arcWidth: number;
88
+ fontSize: number;
89
+ }[];
90
+
91
+ export declare const calcNeedleRotation: (chartValue: number, minValue: number, maxValue: number) => number;
92
+
51
93
  /**
52
94
  * Cartesian Chart component
53
95
  * {@docCategory CartesianChart}
@@ -538,7 +580,8 @@ declare enum ChartTypes {
538
580
  VerticalStackedBarChart = 3,
539
581
  GroupedVerticalBarChart = 4,
540
582
  HeatMapChart = 5,
541
- HorizontalBarChartWithAxis = 6
583
+ HorizontalBarChartWithAxis = 6,
584
+ ScatterChart = 7
542
585
  }
543
586
 
544
587
  export declare interface ChildProps {
@@ -835,10 +878,231 @@ export declare interface EventsAnnotationProps {
835
878
  mergedLabel: (count: number) => string;
836
879
  }
837
880
 
881
+ export declare interface ExtendedSegment extends GaugeChartSegment {
882
+ start: number;
883
+ end: number;
884
+ }
885
+
886
+ export declare const GaugeChart: React_2.FunctionComponent<GaugeChartProps>;
887
+
888
+ /**
889
+ * Gauge Chart properties
890
+ * {@docCategory GaugeChart}
891
+ */
892
+ export declare interface GaugeChartProps {
893
+ /**
894
+ * Width of the chart
895
+ */
896
+ width?: number;
897
+ /**
898
+ * Height of the chart
899
+ */
900
+ height?: number;
901
+ /**
902
+ * Title of the chart
903
+ */
904
+ chartTitle?: string;
905
+ /**
906
+ * Current value of the gauge
907
+ */
908
+ chartValue: number;
909
+ /**
910
+ * Sections of the gauge
911
+ */
912
+ segments: GaugeChartSegment[];
913
+ /**
914
+ * Minimum value of the gauge
915
+ * @defaultvalue 0
916
+ */
917
+ minValue?: number;
918
+ /**
919
+ * Maximum value of the gauge
920
+ */
921
+ maxValue?: number;
922
+ /**
923
+ * Additional text to display below the chart value
924
+ */
925
+ sublabel?: string;
926
+ /**
927
+ * Hide the min and max values of the gauge
928
+ * @defaultvalue false
929
+ */
930
+ hideMinMax?: boolean;
931
+ /**
932
+ * Format of the chart value
933
+ * @defaultvalue GaugeValueFormat.Percentage
934
+ */
935
+ chartValueFormat?: GaugeValueFormat | ((sweepFraction: [number, number]) => string);
936
+ /**
937
+ * Decides whether to show/hide legends
938
+ * @defaultvalue false
939
+ */
940
+ hideLegend?: boolean;
941
+ legendProps?: Partial<LegendsProps>;
942
+ /**
943
+ * Do not show tooltips in chart
944
+ * @defaultvalue false
945
+ */
946
+ hideTooltip?: boolean;
947
+ /**
948
+ * Call to provide customized styling that will layer on top of the variant rules
949
+ */
950
+ styles?: GaugeChartStyles;
951
+ /**
952
+ * Defines the culture to localize the numbers and dates
953
+ */
954
+ culture?: string;
955
+ /**
956
+ * Props for the callout in the chart
957
+ */
958
+ calloutProps?: Partial<ChartPopoverProps>;
959
+ /**
960
+ * Specifies the variant of GaugeChart to be rendered
961
+ * @defaultvalue GaugeChartVariant.MultipleSegments
962
+ */
963
+ variant?: GaugeChartVariant;
964
+ /**
965
+ * Prop to enable the gradient in the chart
966
+ * @default false
967
+ */
968
+ enableGradient?: boolean;
969
+ /**
970
+ * Prop to enable the round corners in the chart
971
+ * @default false
972
+ */
973
+ roundCorners?: boolean;
974
+ }
975
+
976
+ /**
977
+ * Gauge Chart segment interface.
978
+ * {@docCategory GaugeChart}
979
+ */
980
+ export declare interface GaugeChartSegment {
981
+ /**
982
+ * Legend text for a segment
983
+ */
984
+ legend: string;
985
+ /**
986
+ * Size of the segment
987
+ */
988
+ size: number;
989
+ /**
990
+ * Color of the segment
991
+ */
992
+ color?: string;
993
+ /**
994
+ * Gradient color of the segment
995
+ */
996
+ gradient?: [string, string];
997
+ /**
998
+ * Accessibility data for the segment
999
+ */
1000
+ accessibilityData?: AccessibilityProps;
1001
+ }
1002
+
1003
+ /**
1004
+ * Gauge Chart styles
1005
+ * {@docCategory GaugeChart}
1006
+ */
1007
+ export declare interface GaugeChartStyles {
1008
+ /**
1009
+ * Styles for the root element
1010
+ */
1011
+ root?: string;
1012
+ /**
1013
+ * Styles for the chart
1014
+ */
1015
+ chart?: string;
1016
+ /**
1017
+ * Styles for the min and max values
1018
+ */
1019
+ limits?: string;
1020
+ /**
1021
+ * Styles for the chart value
1022
+ */
1023
+ chartValue?: string;
1024
+ /**
1025
+ * Styles for the sublabel
1026
+ */
1027
+ sublabel?: string;
1028
+ /**
1029
+ * Styles for the needle
1030
+ */
1031
+ needle?: string;
1032
+ /**
1033
+ * Styles for the chart title
1034
+ */
1035
+ chartTitle?: string;
1036
+ /**
1037
+ * Styles for the segments
1038
+ */
1039
+ segment?: string;
1040
+ /**
1041
+ * Styles for gradient segments
1042
+ */
1043
+ gradientSegment?: string;
1044
+ /**
1045
+ * Styles for the legends container
1046
+ */
1047
+ legendsContainer?: string;
1048
+ /**
1049
+ * Styles for callout root-content
1050
+ */
1051
+ calloutContentRoot?: string;
1052
+ /**
1053
+ * Styles for callout x-content
1054
+ */
1055
+ calloutContentX?: string;
1056
+ /**
1057
+ * Styles for callout y-content
1058
+ */
1059
+ calloutContentY?: string;
1060
+ /**
1061
+ * Styles for description message
1062
+ */
1063
+ descriptionMessage?: string;
1064
+ /**
1065
+ * Styles for callout Date time container
1066
+ */
1067
+ calloutDateTimeContainer?: string;
1068
+ /**
1069
+ * Styles for callout info container
1070
+ */
1071
+ calloutInfoContainer?: string;
1072
+ /**
1073
+ * Styles for callout block container
1074
+ */
1075
+ calloutBlockContainer?: string;
1076
+ /**
1077
+ * Styles for callout legend text
1078
+ */
1079
+ calloutlegendText?: string;
1080
+ /**
1081
+ * Styles for the shape object in the callout
1082
+ */
1083
+ shapeStyles?: string;
1084
+ }
1085
+
1086
+ /**
1087
+ * {@docCategory GaugeChart}
1088
+ */
1089
+ export declare type GaugeChartVariant = 'single-segment' | 'multiple-segments';
1090
+
1091
+ /**
1092
+ * {@docCategory GaugeChart}
1093
+ */
1094
+ export declare type GaugeValueFormat = 'percentage' | 'fraction';
1095
+
1096
+ export declare const getChartValueLabel: (chartValue: number, minValue: number, maxValue: number, chartValueFormat?: GaugeValueFormat | ((sweepFraction: [number, number]) => string) | undefined, forCallout?: boolean) => string;
1097
+
838
1098
  export declare const getColorFromToken: (token: string, isDarkTheme?: boolean) => string;
839
1099
 
840
1100
  export declare const getNextColor: (index: number, offset?: number, isDarkTheme?: boolean) => string;
841
1101
 
1102
+ export declare const getSegmentLabel: (segment: ExtendedSegment, minValue: number, maxValue: number, variant?: GaugeChartVariant, isAriaLabel?: boolean) => string;
1103
+
1104
+ export declare const GroupedVerticalBarChart: React_2.FC<GroupedVerticalBarChartProps>;
1105
+
842
1106
  /**
843
1107
  * {@docCategory ChartData}
844
1108
  */
@@ -857,6 +1121,96 @@ export declare interface GroupedVerticalBarChartData {
857
1121
  stackCallOutAccessibilityData?: AccessibilityProps;
858
1122
  }
859
1123
 
1124
+ /**
1125
+ * Vertical Bar Chart properties
1126
+ * {@docCategory VerticalBarChart}
1127
+ */
1128
+ export declare interface GroupedVerticalBarChartProps extends CartesianChartProps {
1129
+ /**
1130
+ * Data to render in the chart.
1131
+ */
1132
+ data?: GroupedVerticalBarChartData[];
1133
+ /**
1134
+ * Width of each bar in the chart. When set to `undefined` or `'default'`, the bar width defaults to 16px,
1135
+ * which may decrease to prevent overlap. When set to `'auto'`, the bar width is calculated from padding values.
1136
+ * @default 16
1137
+ */
1138
+ barWidth?: number | 'default' | 'auto';
1139
+ /**
1140
+ * Colors from which to select the color of each bar.
1141
+ */
1142
+ colors?: string[];
1143
+ /**
1144
+ * chart title for the chart
1145
+ */
1146
+ chartTitle?: string;
1147
+ /**
1148
+ * This prop makes sure that all the bars are of same color.
1149
+ * it will take the first color from the array of colors in
1150
+ * prop `colors` or if `colors` prop is not given then default color is palette.blueLight
1151
+ * @default false
1152
+ */
1153
+ useSingleColor?: boolean;
1154
+ /**
1155
+ * Call to provide customized styling that will layer on top of the variant rules.
1156
+ */
1157
+ styles?: GroupedVerticalBarChartStyles;
1158
+ /**
1159
+ * The prop used to define the culture to localized the numbers
1160
+ */
1161
+ culture?: string;
1162
+ /**
1163
+ * To display multi stack callout or single callout
1164
+ * @default false
1165
+ */
1166
+ isCalloutForStack?: boolean;
1167
+ /**
1168
+ * Prop to hide the bar labels
1169
+ * @default false
1170
+ */
1171
+ hideLabels?: boolean;
1172
+ /**
1173
+ * Maximum width of a bar, in pixels.
1174
+ * @default 24
1175
+ */
1176
+ maxBarWidth?: number;
1177
+ /**
1178
+ * Padding between bars as a fraction of the [step](https://d3js.org/d3-scale/band#band_step).
1179
+ * Takes a number in the range [0, 1]. Only applicable to string x-axis.
1180
+ * @default 2/3
1181
+ */
1182
+ xAxisInnerPadding?: number;
1183
+ /**
1184
+ * Padding before the first bar and after the last bar as a fraction of
1185
+ * the [step](https://d3js.org/d3-scale/band#band_step). Takes a number in the range [0, 1].
1186
+ * Only applicable to string x-axis.
1187
+ */
1188
+ xAxisOuterPadding?: number;
1189
+ /**
1190
+ * Specifies the mode of the chart.
1191
+ * @default 'default'
1192
+ */
1193
+ mode?: 'default' | 'plotly';
1194
+ }
1195
+
1196
+ /**
1197
+ * Vertical Bar Chart style properties
1198
+ * {@docCategory VerticalBarChart}
1199
+ */
1200
+ export declare interface GroupedVerticalBarChartStyleProps extends CartesianChartStyleProps {
1201
+ }
1202
+
1203
+ /**
1204
+ * Vertical Bar Chart styles
1205
+ * {@docCategory VerticalBarChart}
1206
+ */
1207
+ export declare interface GroupedVerticalBarChartStyles extends CartesianChartStyles {
1208
+ /**
1209
+ * Style for the bar labels
1210
+ */
1211
+ barLabel: string;
1212
+ }
1213
+
860
1214
  /**
861
1215
  * {@docCategory ChartData}
862
1216
  */
@@ -1280,16 +1634,51 @@ export declare interface LegendsProps {
1280
1634
  */
1281
1635
  onChange?: (selectedLegends: string[], event: React_2.MouseEvent<HTMLButtonElement>, currentLegend?: Legend) => void;
1282
1636
  /**
1283
- * Keys (title) that will be initially used to set selected items.
1284
- * This prop is used for multiSelect scenarios.
1285
- * In other cases, defaultSelectedLegend should be used.
1637
+ * Keys (title) that will be initially used to set selected items. This prop is used for multi-select scenarios when
1638
+ * canSelectMultipleLegends is true; for single-select, use defaultSelectedLegend.
1639
+ *
1640
+ * Updating this prop does not change the selection after the component has been initialized. For controlled
1641
+ * selections, use selectedLegends instead.
1642
+ *
1643
+ * @see selectedLegends for setting the selected legends in controlled mode.
1644
+ * @see defaultSelectedLegend for setting the initially selected legend when canSelectMultipleLegends is false.
1286
1645
  */
1287
1646
  defaultSelectedLegends?: string[];
1288
1647
  /**
1289
- * Key that will be initially used to set selected item.
1290
- * This prop is used for singleSelect scenarios.
1648
+ * Key that will be initially used to set selected item. This prop is used for single-select scenarios when
1649
+ * canSelectMultipleLegends is false or unspecified; for multi-select, use defaultSelectedLegends.
1650
+ *
1651
+ * Updating this prop does not change the selection after the component has been initialized. For controlled
1652
+ * selections, use selectedLegend instead.
1653
+ *
1654
+ * @see selectedLegend for setting the selected legend in controlled mode.
1655
+ * @see defaultSelectedLegends for setting the initially selected legends when canSelectMultipleLegends is true.
1291
1656
  */
1292
1657
  defaultSelectedLegend?: string;
1658
+ /**
1659
+ * Keys (title) that will be used to set selected items in multi-select scenarios when canSelectMultipleLegends is
1660
+ * true. For single-select, use selectedLegend.
1661
+ *
1662
+ * When this prop is provided, the component is controlled and does not automatically update the selection based on
1663
+ * user interactions; the parent component must update the value passed to this property by handling the onChange
1664
+ * event.
1665
+ *
1666
+ * @see defaultSelectedLegends for setting the initially-selected legends in uncontrolled mode.
1667
+ * @see selectedLegends for setting the selected legends when `canSelectMultipleLegends` is `true`.
1668
+ */
1669
+ selectedLegends?: string[];
1670
+ /**
1671
+ * Key (title) that will be used to set the selected item in single-select scenarios when canSelectMultipleLegends is
1672
+ * false or unspecified. For multi-select, use selectedLegends.
1673
+ *
1674
+ * When this prop is provided, the component is controlled and does not automatically update the selection based on
1675
+ * user interactions; the parent component must update the value passed to this property by handling the onChange
1676
+ * event.
1677
+ *
1678
+ * @see defaultSelectedLegend for setting the initially-selected legend in uncontrolled mode.
1679
+ * @see selectedLegend for setting the selected legend when `canSelectMultipleLegends` is `false`.
1680
+ */
1681
+ selectedLegend?: string;
1293
1682
  /**
1294
1683
  * The shape for the legend.
1295
1684
  */
@@ -1366,43 +1755,15 @@ export declare const LineChart: React_2.FunctionComponent<LineChartProps>;
1366
1755
  /**
1367
1756
  * {@docCategory ChartData}
1368
1757
  */
1369
- export declare interface LineChartDataPoint {
1758
+ export declare interface LineChartDataPoint extends BaseDataPoint {
1370
1759
  /**
1371
1760
  * Independent value of the data point, rendered along the x-axis.
1372
- * If x is a number, then each y-coordinate is plotted at its x-coordinate.
1373
- * If data type on x is Date, then the data is spaced evenly by d3-scale
1374
1761
  */
1375
1762
  x: number | Date;
1376
1763
  /**
1377
1764
  * Dependent value of the data point, rendered along the y-axis.
1378
1765
  */
1379
1766
  y: number;
1380
- /**
1381
- * Defines the function that is executed on clicking line
1382
- */
1383
- onDataPointClick?: () => void;
1384
- /**
1385
- * Callout data for x axis
1386
- */
1387
- xAxisCalloutData?: string;
1388
- /**
1389
- * Callout data for y axis
1390
- */
1391
- yAxisCalloutData?: string | {
1392
- [id: string]: number;
1393
- };
1394
- /**
1395
- * Whether to hide callout data for the point.
1396
- */
1397
- hideCallout?: boolean;
1398
- /**
1399
- * Accessibility data for callout
1400
- */
1401
- callOutAccessibilityData?: AccessibilityProps;
1402
- /**
1403
- * X axis Accessibility data for callout
1404
- */
1405
- xAxisCalloutAccessibilityData?: AccessibilityProps;
1406
1767
  }
1407
1768
 
1408
1769
  /**
@@ -1471,7 +1832,7 @@ export declare interface LineChartPoints {
1471
1832
  /**
1472
1833
  * dataPoints for the line chart
1473
1834
  */
1474
- data: LineChartDataPoint[];
1835
+ data: LineChartDataPoint[] | ScatterChartDataPoint[];
1475
1836
  /**
1476
1837
  * gaps in the line chart where a line is not drawn
1477
1838
  */
@@ -1790,6 +2151,72 @@ declare interface ResponsiveContainerProps {
1790
2151
  height?: number | string;
1791
2152
  }
1792
2153
 
2154
+ /**
2155
+ * ScatterChart component
2156
+ * {@docCategory ScatterChart}
2157
+ */
2158
+ export declare const ScatterChart: React_2.FunctionComponent<ScatterChartProps>;
2159
+
2160
+ /**
2161
+ * {@docCategory ChartData}
2162
+ * ScatterChartDataPoint interface.
2163
+ */
2164
+ export declare interface ScatterChartDataPoint extends BaseDataPoint {
2165
+ /**
2166
+ * Independent value of the data point, rendered along the x-axis.
2167
+ */
2168
+ x: number | Date | string;
2169
+ /**
2170
+ * Dependent value of the data point, rendered along the y-axis.
2171
+ */
2172
+ y: number;
2173
+ /**
2174
+ * Marker size of the points
2175
+ */
2176
+ markerSize?: number;
2177
+ }
2178
+
2179
+ /**
2180
+ * Line Chart properties
2181
+ * {@docCategory LineChart}
2182
+ */
2183
+ export declare interface ScatterChartProps extends CartesianChartProps {
2184
+ /**
2185
+ * Data to render in the chart.
2186
+ */
2187
+ data: ChartProps;
2188
+ /**
2189
+ * Call to provide customized styling that will layer on top of the variant rules.
2190
+ */
2191
+ styles?: ScatterChartStyles;
2192
+ /**
2193
+ * Define a custom callout renderer for a data point
2194
+ */
2195
+ onRenderCalloutPerDataPoint?: RenderFunction<CustomizedCalloutData>;
2196
+ /**
2197
+ * Callback for getting callout description message
2198
+ */
2199
+ getCalloutDescriptionMessage?: (calloutDataProps: CustomizedCalloutData) => string | undefined;
2200
+ /**
2201
+ * The prop used to define the culture to localized the numbers
2202
+ */
2203
+ culture?: string;
2204
+ }
2205
+
2206
+ /**
2207
+ * Scatter Chart style properties
2208
+ * {@docCategory ScatterChart}
2209
+ */
2210
+ export declare interface ScatterChartStyleProps extends CartesianChartStyleProps {
2211
+ }
2212
+
2213
+ /**
2214
+ * Scatter Chart styles
2215
+ * {@docCategory ScatterChart}
2216
+ */
2217
+ export declare interface ScatterChartStyles extends CartesianChartStyles {
2218
+ }
2219
+
1793
2220
  /**
1794
2221
  * DeclarativeChart schema.
1795
2222
  * {@docCategory DeclarativeChart}
@@ -0,0 +1 @@
1
+ export * from './components/GaugeChart/index';
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["GaugeChart.ts"],"sourcesContent":["export * from './components/GaugeChart/index';\n"],"names":[],"rangeMappings":"","mappings":"AAAA,cAAc,gCAAgC"}
@@ -0,0 +1 @@
1
+ export * from './components/GroupedVerticalBarChart/index';
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["GroupedVerticalBarChart.ts"],"sourcesContent":["export * from './components/GroupedVerticalBarChart/index';\n"],"names":[],"rangeMappings":"","mappings":"AAAA,cAAc,6CAA6C"}
@@ -0,0 +1 @@
1
+ export * from './components/ScatterChart/index';
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["ScatterChart.ts"],"sourcesContent":["export * from './components/ScatterChart/index';\n"],"names":[],"rangeMappings":"","mappings":"AAAA,cAAc,kCAAkC"}