@fluentui/react-charting 5.12.27 → 5.12.30

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 (46) hide show
  1. package/CHANGELOG.json +60 -3
  2. package/CHANGELOG.md +33 -4
  3. package/README.md +21 -7
  4. package/TechnicalDetails.md +76 -0
  5. package/dist/react-charting.js +1 -1
  6. package/dist/react-charting.min.js +1 -1
  7. package/lib/components/CommonComponents/CartesianChart.base.js +1 -1
  8. package/lib/components/CommonComponents/CartesianChart.base.js.map +1 -1
  9. package/lib/components/CommonComponents/CartesianChart.types.d.ts +25 -16
  10. package/lib/components/CommonComponents/CartesianChart.types.js.map +1 -1
  11. package/lib/components/Legends/Legends.types.d.ts +1 -1
  12. package/lib/components/Legends/Legends.types.js.map +1 -1
  13. package/lib/components/Sparkline/Sparkline.styles.js +1 -1
  14. package/lib/components/Sparkline/Sparkline.styles.js.map +1 -1
  15. package/lib/components/StackedBarChart/MultiStackedBarChart.types.d.ts +2 -0
  16. package/lib/components/StackedBarChart/MultiStackedBarChart.types.js.map +1 -1
  17. package/lib/version.js +1 -1
  18. package/lib/version.js.map +1 -1
  19. package/lib-amd/components/CommonComponents/CartesianChart.base.js +1 -1
  20. package/lib-amd/components/CommonComponents/CartesianChart.base.js.map +1 -1
  21. package/lib-amd/components/CommonComponents/CartesianChart.types.d.ts +25 -16
  22. package/lib-amd/components/CommonComponents/CartesianChart.types.js.map +1 -1
  23. package/lib-amd/components/Legends/Legends.types.d.ts +1 -1
  24. package/lib-amd/components/Legends/Legends.types.js.map +1 -1
  25. package/lib-amd/components/Sparkline/Sparkline.styles.js +1 -1
  26. package/lib-amd/components/Sparkline/Sparkline.styles.js.map +1 -1
  27. package/lib-amd/components/StackedBarChart/MultiStackedBarChart.types.d.ts +2 -0
  28. package/lib-amd/components/StackedBarChart/MultiStackedBarChart.types.js.map +1 -1
  29. package/lib-amd/version.js +1 -1
  30. package/lib-amd/version.js.map +1 -1
  31. package/lib-commonjs/components/CommonComponents/CartesianChart.base.js +1 -1
  32. package/lib-commonjs/components/CommonComponents/CartesianChart.base.js.map +1 -1
  33. package/lib-commonjs/components/CommonComponents/CartesianChart.types.d.ts +25 -16
  34. package/lib-commonjs/components/CommonComponents/CartesianChart.types.js.map +1 -1
  35. package/lib-commonjs/components/Legends/Legends.types.d.ts +1 -1
  36. package/lib-commonjs/components/Legends/Legends.types.js.map +1 -1
  37. package/lib-commonjs/components/Sparkline/Sparkline.styles.js +1 -1
  38. package/lib-commonjs/components/Sparkline/Sparkline.styles.js.map +1 -1
  39. package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.types.d.ts +2 -0
  40. package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.types.js.map +1 -1
  41. package/lib-commonjs/version.js +1 -1
  42. package/lib-commonjs/version.js.map +1 -1
  43. package/package.json +4 -4
  44. package/src/components/CommonComponents/CartesianChart.types.ts +25 -16
  45. package/src/components/Legends/Legends.types.ts +1 -1
  46. package/src/components/StackedBarChart/MultiStackedBarChart.types.ts +2 -0
@@ -40,7 +40,7 @@ export interface ICartesianChartStyleProps {
40
40
  href?: string;
41
41
 
42
42
  /**
43
- * prop to check if the chart is selcted or hovered upon to determine opacity
43
+ * prop to check if the chart is selected or hovered upon to determine opacity
44
44
  */
45
45
  shouldHighlight?: boolean;
46
46
 
@@ -112,20 +112,23 @@ export interface ICartesianChartStyles {
112
112
  calloutDateTimeContainer?: IStyle;
113
113
 
114
114
  /**
115
- * styles for callout Date time container
115
+ * styles for callout info container
116
116
  */
117
117
  calloutInfoContainer?: IStyle;
118
118
 
119
119
  /**
120
- * styles for callout Date time container
120
+ * styles for callout block container
121
121
  */
122
122
  calloutBlockContainer?: IStyle;
123
123
 
124
124
  /**
125
- * styles for callout y-content
125
+ * styles for callout legend text
126
126
  */
127
127
  calloutlegendText?: IStyle;
128
128
 
129
+ /**
130
+ * styles for tooltip
131
+ */
129
132
  tooltip?: IStyle;
130
133
 
131
134
  /**
@@ -139,7 +142,7 @@ export interface ICartesianChartStyles {
139
142
  opacityChangeOnHover?: IStyle;
140
143
 
141
144
  /**
142
- * styles set for the shape object in the callout
145
+ * styles for the shape object in the callout
143
146
  */
144
147
  shapeStyles?: IStyle;
145
148
  }
@@ -200,8 +203,9 @@ export interface ICartesianChartProps {
200
203
  tickValues?: number[] | Date[];
201
204
 
202
205
  /**
203
- * the format in for the data on x-axis. For date object this can be specified to your requirement. Eg: '%m/%d', '%d'
204
- * Please look at https://www.npmjs.com/package/d3-time-format for all the formats supported
206
+ * the format for the data on x-axis. For date object this can be specified to your requirement. Eg: '%m/%d', '%d'
207
+ * Please look at https://github.com/d3/d3-time-format for all the formats supported for date axis
208
+ * Only applicable for date axis. For y-axis format use yAxisTickFormat prop.
205
209
  */
206
210
  tickFormat?: string;
207
211
 
@@ -211,7 +215,7 @@ export interface ICartesianChartProps {
211
215
  strokeWidth?: number;
212
216
 
213
217
  /**
214
- * x Axis labels tick padding
218
+ * x Axis labels tick padding. This defines the gap between tick labels and tick lines.
215
219
  * @default 10
216
220
  */
217
221
  xAxisTickPadding?: number;
@@ -236,25 +240,26 @@ export interface ICartesianChartProps {
236
240
 
237
241
  /**
238
242
  * Number of ticks on the y-axis.
239
- * Tick count should be factor of difference between (yMinValue, yMaxValue)
243
+ * Tick count should be factor of difference between (yMinValue, yMaxValue)?
240
244
  * @default 4
241
245
  */
242
246
  yAxisTickCount?: number;
243
247
 
244
248
  /**
245
- * defines the number of ticks on the x-axis
249
+ * defines the number of ticks on the x-axis. Tries to match the nearest interval satisfying the count.
250
+ * Does not work for string axis.
246
251
  * @default 6
247
252
  */
248
253
  xAxisTickCount?: number;
249
254
 
250
255
  /**
251
- * define the size of the tick on the x-axis
256
+ * define the size of the tick lines on the x-axis
252
257
  * @default 10
253
258
  */
254
259
  xAxistickSize?: number;
255
260
 
256
261
  /**
257
- * define the space between the tick and the data point
262
+ * defines the space between the tick line and the data label
258
263
  * @default 10
259
264
  */
260
265
  tickPadding?: number;
@@ -308,7 +313,7 @@ export interface ICartesianChartProps {
308
313
 
309
314
  /**
310
315
  * @default false
311
- * Used to display x axis labels values (whole value)
316
+ * Used to wrap x axis labels values (whole value)
312
317
  */
313
318
  wrapXAxisLables?: boolean;
314
319
 
@@ -385,7 +390,7 @@ export interface IModifiedCartesianChartProps extends ICartesianChartProps {
385
390
  yAxisType?: YAxisType;
386
391
 
387
392
  /**
388
- * Legeds of the chart.
393
+ * Legends of the chart.
389
394
  */
390
395
  legendBars: JSX.Element;
391
396
 
@@ -426,6 +431,7 @@ export interface IModifiedCartesianChartProps extends ICartesianChartProps {
426
431
 
427
432
  /**
428
433
  * Used for tick styles of the x axis of the chart
434
+ * Tick params are applicable for date axis only.
429
435
  */
430
436
  tickParams?: {
431
437
  tickValues?: number[] | Date[];
@@ -442,10 +448,13 @@ export interface IModifiedCartesianChartProps extends ICartesianChartProps {
442
448
  */
443
449
  yAxisPadding?: number;
444
450
 
451
+ /**
452
+ * Children elements specific to derived chart types.
453
+ */
445
454
  children(props: IChildProps): React.ReactNode;
446
455
 
447
456
  /**
448
- * To enable callout for bar. Using for only Vertical stacked bar chart.
457
+ * To enable callout for individualbar or complete stack. Using for only Vertical stacked bar chart.
449
458
  * @default false
450
459
  * @type {boolean}
451
460
  */
@@ -483,7 +492,7 @@ export interface IModifiedCartesianChartProps extends ICartesianChartProps {
483
492
  svgFocusZoneProps?: IFocusZoneProps;
484
493
 
485
494
  /**
486
- * The prop used to define the culture to localized the numbers
495
+ * The prop used to define the culture to localize the numbers
487
496
  */
488
497
  culture?: string;
489
498
 
@@ -105,7 +105,7 @@ export interface ILegend {
105
105
  shape?: LegendShape;
106
106
 
107
107
  /**
108
- * Indicated whether of not to apply stripe pattern
108
+ * Indicated whether or not to apply stripe pattern
109
109
  */
110
110
  stripePattern?: boolean;
111
111
 
@@ -35,6 +35,7 @@ export interface IMultiStackedBarChartProps {
35
35
 
36
36
  /**
37
37
  * This property tells whether to show ratio on top of stacked bar chart or not.
38
+ * This property is applicable only if there are 1 or 2 datapoints.
38
39
  */
39
40
  hideRatio?: boolean[];
40
41
 
@@ -64,6 +65,7 @@ export interface IMultiStackedBarChartProps {
64
65
 
65
66
  /**
66
67
  * If this value is set to true the denominator will not be shown for the ratio above the chart
68
+ * This prop is applicable only if hide ratio is false and there are exactly 2 datapoints.
67
69
  */
68
70
  hideDenominator?: boolean[];
69
71