@fluentui/react-charting 5.21.14 → 5.21.16
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.json +39 -1
- package/CHANGELOG.md +20 -2
- package/dist/react-charting.d.ts +81 -0
- package/dist/react-charting.js +1 -1
- package/dist/react-charting.min.js +1 -1
- package/etc/react-charting.api.md +13 -0
- package/lib/components/AreaChart/AreaChart.base.d.ts +2 -0
- package/lib/components/AreaChart/AreaChart.base.js +21 -5
- package/lib/components/AreaChart/AreaChart.base.js.map +1 -1
- package/lib/components/CommonComponents/CartesianChart.base.js +9 -9
- package/lib/components/CommonComponents/CartesianChart.base.js.map +1 -1
- package/lib/components/CommonComponents/CartesianChart.types.d.ts +29 -2
- package/lib/components/CommonComponents/CartesianChart.types.js.map +1 -1
- package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.d.ts +2 -0
- package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js +15 -2
- package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js.map +1 -1
- package/lib/components/HeatMapChart/HeatMapChart.base.d.ts +2 -0
- package/lib/components/HeatMapChart/HeatMapChart.base.js +15 -2
- package/lib/components/HeatMapChart/HeatMapChart.base.js.map +1 -1
- package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.d.ts +1 -0
- package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js +12 -2
- package/lib/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js.map +1 -1
- package/lib/components/LineChart/LineChart.base.d.ts +1 -0
- package/lib/components/LineChart/LineChart.base.js +21 -7
- package/lib/components/LineChart/LineChart.base.js.map +1 -1
- package/lib/components/VerticalBarChart/VerticalBarChart.base.d.ts +1 -0
- package/lib/components/VerticalBarChart/VerticalBarChart.base.js +27 -9
- package/lib/components/VerticalBarChart/VerticalBarChart.base.js.map +1 -1
- package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.base.d.ts +1 -0
- package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js +29 -7
- package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js.map +1 -1
- package/lib/utilities/utilities.d.ts +7 -42
- package/lib/utilities/utilities.js +36 -143
- package/lib/utilities/utilities.js.map +1 -1
- package/lib/version.js +1 -1
- package/lib/version.js.map +1 -1
- package/lib-amd/components/AreaChart/AreaChart.base.d.ts +2 -0
- package/lib-amd/components/AreaChart/AreaChart.base.js +20 -4
- package/lib-amd/components/AreaChart/AreaChart.base.js.map +1 -1
- package/lib-amd/components/CommonComponents/CartesianChart.base.js +8 -8
- package/lib-amd/components/CommonComponents/CartesianChart.base.js.map +1 -1
- package/lib-amd/components/CommonComponents/CartesianChart.types.d.ts +29 -2
- package/lib-amd/components/CommonComponents/CartesianChart.types.js.map +1 -1
- package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.d.ts +2 -0
- package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js +14 -1
- package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js.map +1 -1
- package/lib-amd/components/HeatMapChart/HeatMapChart.base.d.ts +2 -0
- package/lib-amd/components/HeatMapChart/HeatMapChart.base.js +14 -1
- package/lib-amd/components/HeatMapChart/HeatMapChart.base.js.map +1 -1
- package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.d.ts +1 -0
- package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js +11 -1
- package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js.map +1 -1
- package/lib-amd/components/LineChart/LineChart.base.d.ts +1 -0
- package/lib-amd/components/LineChart/LineChart.base.js +20 -6
- package/lib-amd/components/LineChart/LineChart.base.js.map +1 -1
- package/lib-amd/components/VerticalBarChart/VerticalBarChart.base.d.ts +1 -0
- package/lib-amd/components/VerticalBarChart/VerticalBarChart.base.js +25 -7
- package/lib-amd/components/VerticalBarChart/VerticalBarChart.base.js.map +1 -1
- package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.base.d.ts +1 -0
- package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js +27 -5
- package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js.map +1 -1
- package/lib-amd/utilities/utilities.d.ts +7 -42
- package/lib-amd/utilities/utilities.js +37 -147
- package/lib-amd/utilities/utilities.js.map +1 -1
- package/lib-amd/version.js +1 -1
- package/lib-amd/version.js.map +1 -1
- package/lib-commonjs/components/AreaChart/AreaChart.base.d.ts +2 -0
- package/lib-commonjs/components/AreaChart/AreaChart.base.js +20 -4
- package/lib-commonjs/components/AreaChart/AreaChart.base.js.map +1 -1
- package/lib-commonjs/components/CommonComponents/CartesianChart.base.js +8 -8
- package/lib-commonjs/components/CommonComponents/CartesianChart.base.js.map +1 -1
- package/lib-commonjs/components/CommonComponents/CartesianChart.types.d.ts +29 -2
- package/lib-commonjs/components/CommonComponents/CartesianChart.types.js.map +1 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.d.ts +2 -0
- package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js +14 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js.map +1 -1
- package/lib-commonjs/components/HeatMapChart/HeatMapChart.base.d.ts +2 -0
- package/lib-commonjs/components/HeatMapChart/HeatMapChart.base.js +14 -1
- package/lib-commonjs/components/HeatMapChart/HeatMapChart.base.js.map +1 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.d.ts +1 -0
- package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js +11 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js.map +1 -1
- package/lib-commonjs/components/LineChart/LineChart.base.d.ts +1 -0
- package/lib-commonjs/components/LineChart/LineChart.base.js +20 -6
- package/lib-commonjs/components/LineChart/LineChart.base.js.map +1 -1
- package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.base.d.ts +1 -0
- package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.base.js +25 -7
- package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.base.js.map +1 -1
- package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.base.d.ts +1 -0
- package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js +27 -5
- package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js.map +1 -1
- package/lib-commonjs/utilities/utilities.d.ts +7 -42
- package/lib-commonjs/utilities/utilities.js +37 -147
- package/lib-commonjs/utilities/utilities.js.map +1 -1
- package/lib-commonjs/version.js +1 -1
- package/lib-commonjs/version.js.map +1 -1
- package/package.json +2 -2
- package/src/components/CommonComponents/CartesianChart.types.ts +71 -2
package/CHANGELOG.json
CHANGED
|
@@ -2,7 +2,45 @@
|
|
|
2
2
|
"name": "@fluentui/react-charting",
|
|
3
3
|
"entries": [
|
|
4
4
|
{
|
|
5
|
-
"date": "
|
|
5
|
+
"date": "Tue, 04 Jun 2024 07:24:09 GMT",
|
|
6
|
+
"tag": "@fluentui/react-charting_v5.21.16",
|
|
7
|
+
"version": "5.21.16",
|
|
8
|
+
"comments": {
|
|
9
|
+
"patch": [
|
|
10
|
+
{
|
|
11
|
+
"author": "110246001+krkshitij@users.noreply.github.com",
|
|
12
|
+
"package": "@fluentui/react-charting",
|
|
13
|
+
"commit": "b857011bdff49fa057f95a16079cfe90431b4184",
|
|
14
|
+
"comment": "Add prop to toggle time display between UTC and local"
|
|
15
|
+
}
|
|
16
|
+
]
|
|
17
|
+
}
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
|
+
"date": "Thu, 30 May 2024 07:24:03 GMT",
|
|
21
|
+
"tag": "@fluentui/react-charting_v5.21.15",
|
|
22
|
+
"version": "5.21.15",
|
|
23
|
+
"comments": {
|
|
24
|
+
"patch": [
|
|
25
|
+
{
|
|
26
|
+
"author": "120183316+srmukher@users.noreply.github.com",
|
|
27
|
+
"package": "@fluentui/react-charting",
|
|
28
|
+
"commit": "a9227118cfdd8654b9dc9b0462b0ef1feb6329e3",
|
|
29
|
+
"comment": "Refactoring utilities to reduce monosize of components"
|
|
30
|
+
}
|
|
31
|
+
],
|
|
32
|
+
"none": [
|
|
33
|
+
{
|
|
34
|
+
"author": "martinhochel@microsoft.com",
|
|
35
|
+
"package": "@fluentui/react-charting",
|
|
36
|
+
"commit": "287ce4504b97d6735b3734f0d0768bbc890a3a6e",
|
|
37
|
+
"comment": "chore: normalize all scripts source to live under /src"
|
|
38
|
+
}
|
|
39
|
+
]
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"date": "Wed, 29 May 2024 07:24:53 GMT",
|
|
6
44
|
"tag": "@fluentui/react-charting_v5.21.14",
|
|
7
45
|
"version": "5.21.14",
|
|
8
46
|
"comments": {
|
package/CHANGELOG.md
CHANGED
|
@@ -1,12 +1,30 @@
|
|
|
1
1
|
# Change Log - @fluentui/react-charting
|
|
2
2
|
|
|
3
|
-
This log was last generated on
|
|
3
|
+
This log was last generated on Tue, 04 Jun 2024 07:24:09 GMT and should not be manually modified.
|
|
4
4
|
|
|
5
5
|
<!-- Start content -->
|
|
6
6
|
|
|
7
|
+
## [5.21.16](https://github.com/microsoft/fluentui/tree/@fluentui/react-charting_v5.21.16)
|
|
8
|
+
|
|
9
|
+
Tue, 04 Jun 2024 07:24:09 GMT
|
|
10
|
+
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-charting_v5.21.15..@fluentui/react-charting_v5.21.16)
|
|
11
|
+
|
|
12
|
+
### Patches
|
|
13
|
+
|
|
14
|
+
- Add prop to toggle time display between UTC and local ([PR #31525](https://github.com/microsoft/fluentui/pull/31525) by 110246001+krkshitij@users.noreply.github.com)
|
|
15
|
+
|
|
16
|
+
## [5.21.15](https://github.com/microsoft/fluentui/tree/@fluentui/react-charting_v5.21.15)
|
|
17
|
+
|
|
18
|
+
Thu, 30 May 2024 07:24:03 GMT
|
|
19
|
+
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-charting_v5.21.14..@fluentui/react-charting_v5.21.15)
|
|
20
|
+
|
|
21
|
+
### Patches
|
|
22
|
+
|
|
23
|
+
- Refactoring utilities to reduce monosize of components ([PR #31291](https://github.com/microsoft/fluentui/pull/31291) by 120183316+srmukher@users.noreply.github.com)
|
|
24
|
+
|
|
7
25
|
## [5.21.14](https://github.com/microsoft/fluentui/tree/@fluentui/react-charting_v5.21.14)
|
|
8
26
|
|
|
9
|
-
Wed, 29 May 2024 07:24:
|
|
27
|
+
Wed, 29 May 2024 07:24:53 GMT
|
|
10
28
|
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-charting_v5.21.13..@fluentui/react-charting_v5.21.14)
|
|
11
29
|
|
|
12
30
|
### Patches
|
package/dist/react-charting.d.ts
CHANGED
|
@@ -16,6 +16,8 @@ import { ITheme as ITheme_2 } from '@fluentui/react';
|
|
|
16
16
|
import * as React_2 from 'react';
|
|
17
17
|
import { SankeyLink } from 'd3-sankey';
|
|
18
18
|
import { SankeyNode } from 'd3-sankey';
|
|
19
|
+
import { ScaleBand } from 'd3-scale';
|
|
20
|
+
import { ScaleLinear } from 'd3-scale';
|
|
19
21
|
import { SVGProps } from 'react';
|
|
20
22
|
import { TimeLocaleDefinition } from 'd3-time-format';
|
|
21
23
|
|
|
@@ -248,6 +250,10 @@ export declare interface IAreaChartStyleProps extends ICartesianChartStyleProps
|
|
|
248
250
|
export declare interface IAreaChartStyles extends ICartesianChartStyles {
|
|
249
251
|
}
|
|
250
252
|
|
|
253
|
+
declare interface IAxisData {
|
|
254
|
+
yAxisDomainValues: number[];
|
|
255
|
+
}
|
|
256
|
+
|
|
251
257
|
export declare interface IBasestate {
|
|
252
258
|
_width?: number;
|
|
253
259
|
_height?: number;
|
|
@@ -481,6 +487,12 @@ export declare interface ICartesianChartProps {
|
|
|
481
487
|
* If RTL is enabled, minimum left and right margins required for secondary y axis title is 60px
|
|
482
488
|
*/
|
|
483
489
|
secondaryYAxistitle?: string;
|
|
490
|
+
/**
|
|
491
|
+
* Whether to use UTC time for axis scale, ticks, and the time display in callouts.
|
|
492
|
+
* When set to `true`, time is displayed equally, regardless of the user's timezone settings.
|
|
493
|
+
* @default true
|
|
494
|
+
*/
|
|
495
|
+
useUTC?: boolean;
|
|
484
496
|
}
|
|
485
497
|
|
|
486
498
|
/**
|
|
@@ -872,6 +884,13 @@ export declare interface IDataPoint {
|
|
|
872
884
|
onClick?: VoidFunction;
|
|
873
885
|
}
|
|
874
886
|
|
|
887
|
+
declare interface IDomainNRange {
|
|
888
|
+
dStartValue: number | Date;
|
|
889
|
+
dEndValue: number | Date;
|
|
890
|
+
rStartValue: number;
|
|
891
|
+
rEndValue: number;
|
|
892
|
+
}
|
|
893
|
+
|
|
875
894
|
export declare interface IDonutChart {
|
|
876
895
|
}
|
|
877
896
|
|
|
@@ -2362,6 +2381,29 @@ export declare interface IMargins {
|
|
|
2362
2381
|
bottom?: number;
|
|
2363
2382
|
}
|
|
2364
2383
|
|
|
2384
|
+
declare interface IMargins_2 {
|
|
2385
|
+
/**
|
|
2386
|
+
* left margin for the chart.
|
|
2387
|
+
* @default 40
|
|
2388
|
+
*/
|
|
2389
|
+
left?: number;
|
|
2390
|
+
/**
|
|
2391
|
+
* Right margin for the chart.
|
|
2392
|
+
* @default 20
|
|
2393
|
+
*/
|
|
2394
|
+
right?: number;
|
|
2395
|
+
/**
|
|
2396
|
+
* Top margin for the chart.
|
|
2397
|
+
* @default 20
|
|
2398
|
+
*/
|
|
2399
|
+
top?: number;
|
|
2400
|
+
/**
|
|
2401
|
+
* Bottom margin for the chart.
|
|
2402
|
+
* @default 35
|
|
2403
|
+
*/
|
|
2404
|
+
bottom?: number;
|
|
2405
|
+
}
|
|
2406
|
+
|
|
2365
2407
|
export declare interface IModifiedCartesianChartProps extends ICartesianChartProps {
|
|
2366
2408
|
/**
|
|
2367
2409
|
* Define the chart title
|
|
@@ -2497,6 +2539,25 @@ export declare interface IModifiedCartesianChartProps extends ICartesianChartPro
|
|
|
2497
2539
|
* Used to control the first render cycle Performance optimization code.
|
|
2498
2540
|
*/
|
|
2499
2541
|
enableFirstRenderOptimization?: boolean;
|
|
2542
|
+
/**
|
|
2543
|
+
* Get the min and max values of the y-axis
|
|
2544
|
+
*/
|
|
2545
|
+
getMinMaxOfYAxis: (points: ILineChartPoints[] | IHorizontalBarChartWithAxisDataPoint[] | IVerticalBarChartDataPoint[] | IDataPoint[], yAxisType: YAxisType | undefined) => {
|
|
2546
|
+
startValue: number;
|
|
2547
|
+
endValue: number;
|
|
2548
|
+
};
|
|
2549
|
+
/**
|
|
2550
|
+
* Create the y-axis
|
|
2551
|
+
*/
|
|
2552
|
+
createYAxis: (yAxisParams: IYAxisParams, isRtl: boolean, axisData: IAxisData, isIntegralDataset: boolean, useSecondaryYScale?: boolean) => ScaleLinear<number, number, never>;
|
|
2553
|
+
/**
|
|
2554
|
+
* Get the domain and range values
|
|
2555
|
+
*/
|
|
2556
|
+
getDomainNRangeValues: (points: ILineChartPoints[] | IVerticalBarChartDataPoint[] | IVerticalStackedBarDataPoint[] | IHorizontalBarChartWithAxisDataPoint[] | IGroupedVerticalBarChartData[] | IHeatMapChartDataPoint[], margins: IMargins, width: number, chartType: ChartTypes, isRTL: boolean, xAxisType: XAxisTypes, barWidth: number, tickValues: Date[] | number[] | undefined, shiftX: number) => IDomainNRange;
|
|
2557
|
+
/**
|
|
2558
|
+
* Create the string y-axis
|
|
2559
|
+
*/
|
|
2560
|
+
createStringYAxis: (yAxisParams: IYAxisParams, dataPoints: string[], isRtl: boolean, barWidth: number | undefined) => ScaleBand<string>;
|
|
2500
2561
|
}
|
|
2501
2562
|
|
|
2502
2563
|
/**
|
|
@@ -3878,6 +3939,26 @@ export declare interface IVSChartDataPoint {
|
|
|
3878
3939
|
callOutAccessibilityData?: IAccessibilityProps;
|
|
3879
3940
|
}
|
|
3880
3941
|
|
|
3942
|
+
declare interface IYAxisParams {
|
|
3943
|
+
yMinMaxValues?: {
|
|
3944
|
+
startValue: number;
|
|
3945
|
+
endValue: number;
|
|
3946
|
+
};
|
|
3947
|
+
maxOfYVal?: number;
|
|
3948
|
+
margins: IMargins_2;
|
|
3949
|
+
containerWidth: number;
|
|
3950
|
+
containerHeight: number;
|
|
3951
|
+
yAxisElement?: SVGElement | null;
|
|
3952
|
+
yAxisTickFormat?: any;
|
|
3953
|
+
yAxisTickCount: number;
|
|
3954
|
+
yMaxValue?: number;
|
|
3955
|
+
yMinValue?: number;
|
|
3956
|
+
tickPadding?: number;
|
|
3957
|
+
eventAnnotationProps?: IEventsAnnotationProps;
|
|
3958
|
+
eventLabelHeight?: number;
|
|
3959
|
+
yAxisPadding?: number;
|
|
3960
|
+
}
|
|
3961
|
+
|
|
3881
3962
|
export declare interface IYValueHover {
|
|
3882
3963
|
legend?: string;
|
|
3883
3964
|
y?: number;
|