@fluentui/react-charting 5.16.36 → 5.16.38
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 +43 -1
- package/CHANGELOG.md +22 -2
- package/dist/react-charting.js +1 -1
- package/dist/react-charting.min.js +1 -1
- package/lib/components/AreaChart/AreaChart.base.d.ts +1 -0
- package/lib/components/AreaChart/AreaChart.base.js +38 -27
- package/lib/components/AreaChart/AreaChart.base.js.map +1 -1
- package/lib/components/CommonComponents/CartesianChart.base.js +2 -1
- package/lib/components/CommonComponents/CartesianChart.base.js.map +1 -1
- package/lib/components/DonutChart/DonutChart.base.d.ts +1 -0
- package/lib/components/DonutChart/DonutChart.base.js +9 -2
- package/lib/components/DonutChart/DonutChart.base.js.map +1 -1
- package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.d.ts +2 -0
- package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js +11 -2
- package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js.map +1 -1
- package/lib/components/HeatMapChart/HeatMapChart.base.d.ts +5 -0
- package/lib/components/HeatMapChart/HeatMapChart.base.js +10 -3
- package/lib/components/HeatMapChart/HeatMapChart.base.js.map +1 -1
- package/lib/components/HorizontalBarChart/HorizontalBarChart.base.d.ts +2 -0
- package/lib/components/HorizontalBarChart/HorizontalBarChart.base.js +9 -2
- package/lib/components/HorizontalBarChart/HorizontalBarChart.base.js.map +1 -1
- package/lib/components/LineChart/LineChart.base.d.ts +2 -0
- package/lib/components/LineChart/LineChart.base.js +12 -2
- package/lib/components/LineChart/LineChart.base.js.map +1 -1
- package/lib/components/PieChart/PieChart.base.d.ts +6 -1
- package/lib/components/PieChart/PieChart.base.js +17 -5
- package/lib/components/PieChart/PieChart.base.js.map +1 -1
- package/lib/components/SankeyChart/SankeyChart.base.d.ts +1 -0
- package/lib/components/SankeyChart/SankeyChart.base.js +48 -41
- package/lib/components/SankeyChart/SankeyChart.base.js.map +1 -1
- package/lib/components/Sparkline/Sparkline.base.d.ts +1 -0
- package/lib/components/Sparkline/Sparkline.base.js +40 -30
- package/lib/components/Sparkline/Sparkline.base.js.map +1 -1
- package/lib/components/StackedBarChart/MultiStackedBarChart.base.d.ts +2 -0
- package/lib/components/StackedBarChart/MultiStackedBarChart.base.js +37 -25
- package/lib/components/StackedBarChart/MultiStackedBarChart.base.js.map +1 -1
- package/lib/components/StackedBarChart/StackedBarChart.base.d.ts +2 -0
- package/lib/components/StackedBarChart/StackedBarChart.base.js +68 -54
- package/lib/components/StackedBarChart/StackedBarChart.base.js.map +1 -1
- package/lib/components/TreeChart/TreeChart.base.js +2 -1
- package/lib/components/TreeChart/TreeChart.base.js.map +1 -1
- package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.base.d.ts +1 -0
- package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js +39 -26
- package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js.map +1 -1
- package/lib/version.js +1 -1
- package/lib/version.js.map +1 -1
- package/lib-amd/AreaChart.js +1 -1
- package/lib-amd/AreaChart.js.map +1 -1
- package/lib-amd/CartesianChart.js +1 -1
- package/lib-amd/CartesianChart.js.map +1 -1
- package/lib-amd/DonutChart.js +1 -1
- package/lib-amd/DonutChart.js.map +1 -1
- package/lib-amd/GroupedVerticalBarChart.js +1 -1
- package/lib-amd/GroupedVerticalBarChart.js.map +1 -1
- package/lib-amd/HeatMapChart.js +1 -1
- package/lib-amd/HeatMapChart.js.map +1 -1
- package/lib-amd/HorizontalBarChart.js +1 -1
- package/lib-amd/HorizontalBarChart.js.map +1 -1
- package/lib-amd/HorizontalBarChartWithAxis.js +1 -1
- package/lib-amd/HorizontalBarChartWithAxis.js.map +1 -1
- package/lib-amd/Legends.js +1 -1
- package/lib-amd/Legends.js.map +1 -1
- package/lib-amd/LineChart.js +1 -1
- package/lib-amd/LineChart.js.map +1 -1
- package/lib-amd/PieChart.js +1 -1
- package/lib-amd/PieChart.js.map +1 -1
- package/lib-amd/SankeyChart.js +1 -1
- package/lib-amd/SankeyChart.js.map +1 -1
- package/lib-amd/Sparkline.js +1 -1
- package/lib-amd/Sparkline.js.map +1 -1
- package/lib-amd/StackedBarChart.js +1 -1
- package/lib-amd/StackedBarChart.js.map +1 -1
- package/lib-amd/TreeChart.js +1 -1
- package/lib-amd/TreeChart.js.map +1 -1
- package/lib-amd/VerticalBarChart.js +1 -1
- package/lib-amd/VerticalBarChart.js.map +1 -1
- package/lib-amd/VerticalStackedBarChart.js +1 -1
- package/lib-amd/VerticalStackedBarChart.js.map +1 -1
- package/lib-amd/components/AreaChart/AreaChart.base.d.ts +1 -0
- package/lib-amd/components/AreaChart/AreaChart.base.js +46 -35
- package/lib-amd/components/AreaChart/AreaChart.base.js.map +1 -1
- package/lib-amd/components/AreaChart/AreaChart.styles.js +1 -1
- package/lib-amd/components/AreaChart/AreaChart.styles.js.map +1 -1
- package/lib-amd/components/AreaChart/index.js +2 -2
- package/lib-amd/components/AreaChart/index.js.map +1 -1
- package/lib-amd/components/CommonComponents/CartesianChart.base.js +13 -12
- package/lib-amd/components/CommonComponents/CartesianChart.base.js.map +1 -1
- package/lib-amd/components/CommonComponents/CartesianChart.styles.js +3 -3
- package/lib-amd/components/CommonComponents/CartesianChart.styles.js.map +1 -1
- package/lib-amd/components/CommonComponents/index.js +2 -2
- package/lib-amd/components/CommonComponents/index.js.map +1 -1
- package/lib-amd/components/DonutChart/Arc/Arc.js +1 -1
- package/lib-amd/components/DonutChart/Arc/Arc.js.map +1 -1
- package/lib-amd/components/DonutChart/Arc/index.js +2 -2
- package/lib-amd/components/DonutChart/Arc/index.js.map +1 -1
- package/lib-amd/components/DonutChart/DonutChart.base.d.ts +1 -0
- package/lib-amd/components/DonutChart/DonutChart.base.js +13 -6
- package/lib-amd/components/DonutChart/DonutChart.base.js.map +1 -1
- package/lib-amd/components/DonutChart/Pie/Pie.js +1 -1
- package/lib-amd/components/DonutChart/Pie/Pie.js.map +1 -1
- package/lib-amd/components/DonutChart/Pie/index.js +2 -2
- package/lib-amd/components/DonutChart/Pie/index.js.map +1 -1
- package/lib-amd/components/DonutChart/index.js +3 -3
- package/lib-amd/components/DonutChart/index.js.map +1 -1
- package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.d.ts +2 -0
- package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js +16 -7
- package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js.map +1 -1
- package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.styles.js +1 -1
- package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.styles.js.map +1 -1
- package/lib-amd/components/GroupedVerticalBarChart/index.js +2 -2
- package/lib-amd/components/GroupedVerticalBarChart/index.js.map +1 -1
- package/lib-amd/components/HeatMapChart/HeatMapChart.base.d.ts +5 -0
- package/lib-amd/components/HeatMapChart/HeatMapChart.base.js +15 -8
- package/lib-amd/components/HeatMapChart/HeatMapChart.base.js.map +1 -1
- package/lib-amd/components/HeatMapChart/index.js +2 -2
- package/lib-amd/components/HeatMapChart/index.js.map +1 -1
- package/lib-amd/components/HorizontalBarChart/HorizontalBarChart.base.d.ts +2 -0
- package/lib-amd/components/HorizontalBarChart/HorizontalBarChart.base.js +14 -7
- package/lib-amd/components/HorizontalBarChart/HorizontalBarChart.base.js.map +1 -1
- package/lib-amd/components/HorizontalBarChart/HorizontalBarChart.styles.js +2 -2
- package/lib-amd/components/HorizontalBarChart/HorizontalBarChart.styles.js.map +1 -1
- package/lib-amd/components/HorizontalBarChart/index.js +3 -3
- package/lib-amd/components/HorizontalBarChart/index.js.map +1 -1
- package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js +6 -6
- package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js.map +1 -1
- package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.styles.js +1 -1
- package/lib-amd/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.styles.js.map +1 -1
- package/lib-amd/components/HorizontalBarChartWithAxis/index.js +2 -2
- package/lib-amd/components/HorizontalBarChartWithAxis/index.js.map +1 -1
- package/lib-amd/components/Legends/Legends.base.js +11 -11
- package/lib-amd/components/Legends/Legends.base.js.map +1 -1
- package/lib-amd/components/Legends/Legends.styles.js +2 -2
- package/lib-amd/components/Legends/Legends.styles.js.map +1 -1
- package/lib-amd/components/Legends/index.js +3 -3
- package/lib-amd/components/Legends/index.js.map +1 -1
- package/lib-amd/components/Legends/shape.js +2 -2
- package/lib-amd/components/Legends/shape.js.map +1 -1
- package/lib-amd/components/LineChart/LineChart.base.d.ts +2 -0
- package/lib-amd/components/LineChart/LineChart.base.js +26 -16
- package/lib-amd/components/LineChart/LineChart.base.js.map +1 -1
- package/lib-amd/components/LineChart/LineChart.styles.js +1 -1
- package/lib-amd/components/LineChart/LineChart.styles.js.map +1 -1
- package/lib-amd/components/LineChart/eventAnnotation/EventAnnotation.js +2 -2
- package/lib-amd/components/LineChart/eventAnnotation/EventAnnotation.js.map +1 -1
- package/lib-amd/components/LineChart/eventAnnotation/Textbox.js +2 -2
- package/lib-amd/components/LineChart/eventAnnotation/Textbox.js.map +1 -1
- package/lib-amd/components/LineChart/index.js +3 -3
- package/lib-amd/components/LineChart/index.js.map +1 -1
- package/lib-amd/components/PieChart/Arc/Arc.js +2 -2
- package/lib-amd/components/PieChart/Arc/Arc.js.map +1 -1
- package/lib-amd/components/PieChart/Arc/index.js +2 -2
- package/lib-amd/components/PieChart/Arc/index.js.map +1 -1
- package/lib-amd/components/PieChart/Pie/Pie.js +1 -1
- package/lib-amd/components/PieChart/Pie/Pie.js.map +1 -1
- package/lib-amd/components/PieChart/Pie/index.js +2 -2
- package/lib-amd/components/PieChart/Pie/index.js.map +1 -1
- package/lib-amd/components/PieChart/PieChart.base.d.ts +6 -1
- package/lib-amd/components/PieChart/PieChart.base.js +17 -5
- package/lib-amd/components/PieChart/PieChart.base.js.map +1 -1
- package/lib-amd/components/PieChart/PieChart.styles.js +1 -1
- package/lib-amd/components/PieChart/PieChart.styles.js.map +1 -1
- package/lib-amd/components/PieChart/index.js +2 -2
- package/lib-amd/components/PieChart/index.js.map +1 -1
- package/lib-amd/components/SankeyChart/SankeyChart.base.d.ts +1 -0
- package/lib-amd/components/SankeyChart/SankeyChart.base.js +49 -42
- package/lib-amd/components/SankeyChart/SankeyChart.base.js.map +1 -1
- package/lib-amd/components/SankeyChart/SankeyChart.styles.js +1 -1
- package/lib-amd/components/SankeyChart/SankeyChart.styles.js.map +1 -1
- package/lib-amd/components/SankeyChart/index.js +2 -2
- package/lib-amd/components/SankeyChart/index.js.map +1 -1
- package/lib-amd/components/Sparkline/Sparkline.base.d.ts +1 -0
- package/lib-amd/components/Sparkline/Sparkline.base.js +40 -30
- package/lib-amd/components/Sparkline/Sparkline.base.js.map +1 -1
- package/lib-amd/components/Sparkline/Sparkline.styles.js +1 -1
- package/lib-amd/components/Sparkline/Sparkline.styles.js.map +1 -1
- package/lib-amd/components/Sparkline/index.js +2 -2
- package/lib-amd/components/Sparkline/index.js.map +1 -1
- package/lib-amd/components/StackedBarChart/MultiStackedBarChart.base.d.ts +2 -0
- package/lib-amd/components/StackedBarChart/MultiStackedBarChart.base.js +41 -29
- package/lib-amd/components/StackedBarChart/MultiStackedBarChart.base.js.map +1 -1
- package/lib-amd/components/StackedBarChart/MultiStackedBarChart.styles.js +1 -1
- package/lib-amd/components/StackedBarChart/MultiStackedBarChart.styles.js.map +1 -1
- package/lib-amd/components/StackedBarChart/StackedBarChart.base.d.ts +2 -0
- package/lib-amd/components/StackedBarChart/StackedBarChart.base.js +70 -56
- package/lib-amd/components/StackedBarChart/StackedBarChart.base.js.map +1 -1
- package/lib-amd/components/StackedBarChart/StackedBarChart.styles.js +1 -1
- package/lib-amd/components/StackedBarChart/StackedBarChart.styles.js.map +1 -1
- package/lib-amd/components/StackedBarChart/index.js +5 -5
- package/lib-amd/components/StackedBarChart/index.js.map +1 -1
- package/lib-amd/components/TreeChart/TreeChart.base.js +4 -3
- package/lib-amd/components/TreeChart/TreeChart.base.js.map +1 -1
- package/lib-amd/components/TreeChart/TreeChart.styles.js +4 -4
- package/lib-amd/components/TreeChart/TreeChart.styles.js.map +1 -1
- package/lib-amd/components/TreeChart/index.js +2 -2
- package/lib-amd/components/TreeChart/index.js.map +1 -1
- package/lib-amd/components/VerticalBarChart/VerticalBarChart.base.js +6 -6
- package/lib-amd/components/VerticalBarChart/VerticalBarChart.base.js.map +1 -1
- package/lib-amd/components/VerticalBarChart/VerticalBarChart.styles.js +1 -1
- package/lib-amd/components/VerticalBarChart/VerticalBarChart.styles.js.map +1 -1
- package/lib-amd/components/VerticalBarChart/index.js +2 -2
- package/lib-amd/components/VerticalBarChart/index.js.map +1 -1
- package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.base.d.ts +1 -0
- package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js +49 -36
- package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js.map +1 -1
- package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.styles.js +1 -1
- package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.styles.js.map +1 -1
- package/lib-amd/components/VerticalStackedBarChart/index.js +2 -2
- package/lib-amd/components/VerticalStackedBarChart/index.js.map +1 -1
- package/lib-amd/index.js +19 -19
- package/lib-amd/index.js.map +1 -1
- package/lib-amd/types/index.js +2 -2
- package/lib-amd/types/index.js.map +1 -1
- package/lib-amd/utilities/ChartHoverCard/ChartHoverCard.base.js +1 -1
- package/lib-amd/utilities/ChartHoverCard/ChartHoverCard.base.js.map +1 -1
- package/lib-amd/utilities/ChartHoverCard/index.js +3 -3
- package/lib-amd/utilities/ChartHoverCard/index.js.map +1 -1
- package/lib-amd/utilities/FocusableTooltipText.js +2 -2
- package/lib-amd/utilities/FocusableTooltipText.js.map +1 -1
- package/lib-amd/utilities/index.js +3 -3
- package/lib-amd/utilities/index.js.map +1 -1
- package/lib-amd/utilities/utilities.js +4 -4
- 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/AreaChart.js +1 -1
- package/lib-commonjs/AreaChart.js.map +1 -1
- package/lib-commonjs/CartesianChart.js +1 -1
- package/lib-commonjs/CartesianChart.js.map +1 -1
- package/lib-commonjs/DonutChart.js +1 -1
- package/lib-commonjs/DonutChart.js.map +1 -1
- package/lib-commonjs/GroupedVerticalBarChart.js +1 -1
- package/lib-commonjs/GroupedVerticalBarChart.js.map +1 -1
- package/lib-commonjs/HeatMapChart.js +1 -1
- package/lib-commonjs/HeatMapChart.js.map +1 -1
- package/lib-commonjs/HorizontalBarChart.js +1 -1
- package/lib-commonjs/HorizontalBarChart.js.map +1 -1
- package/lib-commonjs/HorizontalBarChartWithAxis.js +1 -1
- package/lib-commonjs/HorizontalBarChartWithAxis.js.map +1 -1
- package/lib-commonjs/Legends.js +1 -1
- package/lib-commonjs/Legends.js.map +1 -1
- package/lib-commonjs/LineChart.js +1 -1
- package/lib-commonjs/LineChart.js.map +1 -1
- package/lib-commonjs/PieChart.js +1 -1
- package/lib-commonjs/PieChart.js.map +1 -1
- package/lib-commonjs/SankeyChart.js +1 -1
- package/lib-commonjs/SankeyChart.js.map +1 -1
- package/lib-commonjs/Sparkline.js +1 -1
- package/lib-commonjs/Sparkline.js.map +1 -1
- package/lib-commonjs/StackedBarChart.js +1 -1
- package/lib-commonjs/StackedBarChart.js.map +1 -1
- package/lib-commonjs/TreeChart.js +1 -1
- package/lib-commonjs/TreeChart.js.map +1 -1
- package/lib-commonjs/VerticalBarChart.js +1 -1
- package/lib-commonjs/VerticalBarChart.js.map +1 -1
- package/lib-commonjs/VerticalStackedBarChart.js +1 -1
- package/lib-commonjs/VerticalStackedBarChart.js.map +1 -1
- package/lib-commonjs/components/AreaChart/AreaChart.base.d.ts +1 -0
- package/lib-commonjs/components/AreaChart/AreaChart.base.js +46 -35
- package/lib-commonjs/components/AreaChart/AreaChart.base.js.map +1 -1
- package/lib-commonjs/components/AreaChart/AreaChart.styles.js +1 -1
- package/lib-commonjs/components/AreaChart/AreaChart.styles.js.map +1 -1
- package/lib-commonjs/components/AreaChart/index.js +2 -2
- package/lib-commonjs/components/AreaChart/index.js.map +1 -1
- package/lib-commonjs/components/CommonComponents/CartesianChart.base.js +13 -12
- package/lib-commonjs/components/CommonComponents/CartesianChart.base.js.map +1 -1
- package/lib-commonjs/components/CommonComponents/CartesianChart.styles.js +3 -3
- package/lib-commonjs/components/CommonComponents/CartesianChart.styles.js.map +1 -1
- package/lib-commonjs/components/CommonComponents/index.js +2 -2
- package/lib-commonjs/components/CommonComponents/index.js.map +1 -1
- package/lib-commonjs/components/DonutChart/Arc/Arc.js +1 -1
- package/lib-commonjs/components/DonutChart/Arc/Arc.js.map +1 -1
- package/lib-commonjs/components/DonutChart/Arc/index.js +2 -2
- package/lib-commonjs/components/DonutChart/Arc/index.js.map +1 -1
- package/lib-commonjs/components/DonutChart/DonutChart.base.d.ts +1 -0
- package/lib-commonjs/components/DonutChart/DonutChart.base.js +13 -6
- package/lib-commonjs/components/DonutChart/DonutChart.base.js.map +1 -1
- package/lib-commonjs/components/DonutChart/Pie/Pie.js +1 -1
- package/lib-commonjs/components/DonutChart/Pie/Pie.js.map +1 -1
- package/lib-commonjs/components/DonutChart/Pie/index.js +2 -2
- package/lib-commonjs/components/DonutChart/Pie/index.js.map +1 -1
- package/lib-commonjs/components/DonutChart/index.js +3 -3
- package/lib-commonjs/components/DonutChart/index.js.map +1 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.d.ts +2 -0
- package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js +16 -7
- package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.base.js.map +1 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.styles.js +1 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.styles.js.map +1 -1
- package/lib-commonjs/components/GroupedVerticalBarChart/index.js +2 -2
- package/lib-commonjs/components/GroupedVerticalBarChart/index.js.map +1 -1
- package/lib-commonjs/components/HeatMapChart/HeatMapChart.base.d.ts +5 -0
- package/lib-commonjs/components/HeatMapChart/HeatMapChart.base.js +15 -8
- package/lib-commonjs/components/HeatMapChart/HeatMapChart.base.js.map +1 -1
- package/lib-commonjs/components/HeatMapChart/index.js +2 -2
- package/lib-commonjs/components/HeatMapChart/index.js.map +1 -1
- package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.base.d.ts +2 -0
- package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.base.js +14 -7
- package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.base.js.map +1 -1
- package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.styles.js +2 -2
- package/lib-commonjs/components/HorizontalBarChart/HorizontalBarChart.styles.js.map +1 -1
- package/lib-commonjs/components/HorizontalBarChart/index.js +3 -3
- package/lib-commonjs/components/HorizontalBarChart/index.js.map +1 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js +6 -6
- package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.base.js.map +1 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.styles.js +1 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/HorizontalBarChartWithAxis.styles.js.map +1 -1
- package/lib-commonjs/components/HorizontalBarChartWithAxis/index.js +2 -2
- package/lib-commonjs/components/HorizontalBarChartWithAxis/index.js.map +1 -1
- package/lib-commonjs/components/Legends/Legends.base.js +11 -11
- package/lib-commonjs/components/Legends/Legends.base.js.map +1 -1
- package/lib-commonjs/components/Legends/Legends.styles.js +2 -2
- package/lib-commonjs/components/Legends/Legends.styles.js.map +1 -1
- package/lib-commonjs/components/Legends/index.js +3 -3
- package/lib-commonjs/components/Legends/index.js.map +1 -1
- package/lib-commonjs/components/Legends/shape.js +2 -2
- package/lib-commonjs/components/Legends/shape.js.map +1 -1
- package/lib-commonjs/components/LineChart/LineChart.base.d.ts +2 -0
- package/lib-commonjs/components/LineChart/LineChart.base.js +26 -16
- package/lib-commonjs/components/LineChart/LineChart.base.js.map +1 -1
- package/lib-commonjs/components/LineChart/LineChart.styles.js +1 -1
- package/lib-commonjs/components/LineChart/LineChart.styles.js.map +1 -1
- package/lib-commonjs/components/LineChart/eventAnnotation/EventAnnotation.js +2 -2
- package/lib-commonjs/components/LineChart/eventAnnotation/EventAnnotation.js.map +1 -1
- package/lib-commonjs/components/LineChart/eventAnnotation/Textbox.js +2 -2
- package/lib-commonjs/components/LineChart/eventAnnotation/Textbox.js.map +1 -1
- package/lib-commonjs/components/LineChart/index.js +3 -3
- package/lib-commonjs/components/LineChart/index.js.map +1 -1
- package/lib-commonjs/components/PieChart/Arc/Arc.js +2 -2
- package/lib-commonjs/components/PieChart/Arc/Arc.js.map +1 -1
- package/lib-commonjs/components/PieChart/Arc/index.js +2 -2
- package/lib-commonjs/components/PieChart/Arc/index.js.map +1 -1
- package/lib-commonjs/components/PieChart/Pie/Pie.js +1 -1
- package/lib-commonjs/components/PieChart/Pie/Pie.js.map +1 -1
- package/lib-commonjs/components/PieChart/Pie/index.js +2 -2
- package/lib-commonjs/components/PieChart/Pie/index.js.map +1 -1
- package/lib-commonjs/components/PieChart/PieChart.base.d.ts +6 -1
- package/lib-commonjs/components/PieChart/PieChart.base.js +17 -5
- package/lib-commonjs/components/PieChart/PieChart.base.js.map +1 -1
- package/lib-commonjs/components/PieChart/PieChart.styles.js +1 -1
- package/lib-commonjs/components/PieChart/PieChart.styles.js.map +1 -1
- package/lib-commonjs/components/PieChart/index.js +2 -2
- package/lib-commonjs/components/PieChart/index.js.map +1 -1
- package/lib-commonjs/components/SankeyChart/SankeyChart.base.d.ts +1 -0
- package/lib-commonjs/components/SankeyChart/SankeyChart.base.js +49 -42
- package/lib-commonjs/components/SankeyChart/SankeyChart.base.js.map +1 -1
- package/lib-commonjs/components/SankeyChart/SankeyChart.styles.js +1 -1
- package/lib-commonjs/components/SankeyChart/SankeyChart.styles.js.map +1 -1
- package/lib-commonjs/components/SankeyChart/index.js +2 -2
- package/lib-commonjs/components/SankeyChart/index.js.map +1 -1
- package/lib-commonjs/components/Sparkline/Sparkline.base.d.ts +1 -0
- package/lib-commonjs/components/Sparkline/Sparkline.base.js +40 -30
- package/lib-commonjs/components/Sparkline/Sparkline.base.js.map +1 -1
- package/lib-commonjs/components/Sparkline/Sparkline.styles.js +1 -1
- package/lib-commonjs/components/Sparkline/Sparkline.styles.js.map +1 -1
- package/lib-commonjs/components/Sparkline/index.js +2 -2
- package/lib-commonjs/components/Sparkline/index.js.map +1 -1
- package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.base.d.ts +2 -0
- package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.base.js +41 -29
- package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.base.js.map +1 -1
- package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.styles.js +1 -1
- package/lib-commonjs/components/StackedBarChart/MultiStackedBarChart.styles.js.map +1 -1
- package/lib-commonjs/components/StackedBarChart/StackedBarChart.base.d.ts +2 -0
- package/lib-commonjs/components/StackedBarChart/StackedBarChart.base.js +70 -56
- package/lib-commonjs/components/StackedBarChart/StackedBarChart.base.js.map +1 -1
- package/lib-commonjs/components/StackedBarChart/StackedBarChart.styles.js +1 -1
- package/lib-commonjs/components/StackedBarChart/StackedBarChart.styles.js.map +1 -1
- package/lib-commonjs/components/StackedBarChart/index.js +5 -5
- package/lib-commonjs/components/StackedBarChart/index.js.map +1 -1
- package/lib-commonjs/components/TreeChart/TreeChart.base.js +4 -3
- package/lib-commonjs/components/TreeChart/TreeChart.base.js.map +1 -1
- package/lib-commonjs/components/TreeChart/TreeChart.styles.js +4 -4
- package/lib-commonjs/components/TreeChart/TreeChart.styles.js.map +1 -1
- package/lib-commonjs/components/TreeChart/index.js +2 -2
- package/lib-commonjs/components/TreeChart/index.js.map +1 -1
- package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.base.js +6 -6
- package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.base.js.map +1 -1
- package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.styles.js +1 -1
- package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.styles.js.map +1 -1
- package/lib-commonjs/components/VerticalBarChart/index.js +2 -2
- package/lib-commonjs/components/VerticalBarChart/index.js.map +1 -1
- package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.base.d.ts +1 -0
- package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js +49 -36
- package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.base.js.map +1 -1
- package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.styles.js +1 -1
- package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.styles.js.map +1 -1
- package/lib-commonjs/components/VerticalStackedBarChart/index.js +2 -2
- package/lib-commonjs/components/VerticalStackedBarChart/index.js.map +1 -1
- package/lib-commonjs/index.js +19 -19
- package/lib-commonjs/index.js.map +1 -1
- package/lib-commonjs/types/index.js +2 -2
- package/lib-commonjs/types/index.js.map +1 -1
- package/lib-commonjs/utilities/ChartHoverCard/ChartHoverCard.base.js +1 -1
- package/lib-commonjs/utilities/ChartHoverCard/ChartHoverCard.base.js.map +1 -1
- package/lib-commonjs/utilities/ChartHoverCard/index.js +3 -3
- package/lib-commonjs/utilities/ChartHoverCard/index.js.map +1 -1
- package/lib-commonjs/utilities/FocusableTooltipText.js +2 -2
- package/lib-commonjs/utilities/FocusableTooltipText.js.map +1 -1
- package/lib-commonjs/utilities/index.js +3 -3
- package/lib-commonjs/utilities/index.js.map +1 -1
- package/lib-commonjs/utilities/utilities.js +4 -4
- 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 +5 -5
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Arc.js","sourceRoot":"../src/","sources":["components/PieChart/Arc/Arc.tsx"],"names":[],"mappings":";;;;IAOA;QAAyB
|
|
1
|
+
{"version":3,"file":"Arc.js","sourceRoot":"../src/","sources":["components/PieChart/Arc/Arc.tsx"],"names":[],"mappings":";;;;IAOA;QAAyB,+BAA8B;QAAvD;YAAA,qEAsBC;YAjBQ,WAAK,GAAO,EAAE,CAAC;YAOf,iBAAW,GAAG,UAAC,QAAmB;gBACvC,YAAY,CAAC,QAAQ,CAAC,CAAC;YACzB,CAAC,CAAC;;QAQJ,CAAC;QAfe,4BAAwB,GAAtC,UAAuC,SAA8B;YACnE,YAAY,CAAC,SAAS,CAAC,CAAC;YACxB,OAAO,IAAI,CAAC;QACd,CAAC;QAMM,oBAAM,GAAb;;YACQ,IAAA,KAAiB,IAAI,CAAC,KAAK,EAAzB,KAAK,WAAA,EAAE,GAAG,SAAe,CAAC;YAClC,IAAM,aAAa,GAAG,IAAA,8BAAkB,GAAyB,CAAC;YAClE,IAAM,UAAU,GAAG,aAAa,CAAC,sBAAS,EAAE,EAAE,KAAK,OAAA,EAAE,CAAC,CAAC;YACvD,OAAO,8BAAM,CAAC,EAAE,GAAG,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,EAAE,SAAS,EAAE,UAAU,CAAC,IAAI,EAAE,OAAO,EAAE,MAAA,IAAI,CAAC,KAAK,CAAC,IAAI,0CAAE,IAAI,CAAC,OAAO,GAAI,CAAC;QAC/G,CAAC;QApBa,gBAAY,GAAuB;YAC/C,GAAG,EAAE,KAAK,CAAC,GAAG,EAAE;SACjB,CAAC;QAmBJ,UAAC;KAAA,AAtBD,CAAyB,KAAK,CAAC,SAAS,GAsBvC;IAtBY,kBAAG;IAwBhB;QAAgC,sCAAG;QAAnC;;QAeA,CAAC;QAdQ,2BAAM,GAAb;YACQ,IAAA,KAAyB,IAAI,CAAC,KAAK,EAAjC,IAAI,UAAA,EAAE,GAAG,SAAA,EAAE,OAAO,aAAe,CAAC;YACpC,IAAA,KAAmB,GAAG,CAAC,QAAQ,CAAC,IAAI,CAAC,EAApC,MAAM,QAAA,EAAE,MAAM,QAAsB,CAAC;YAC5C,IAAM,cAAc,GAAG,oBAAa,MAAM,eAAK,MAAM,MAAG,CAAC;YAEzD,OAAO,CACL,2BAAG,SAAS,EAAC,KAAK;gBACf,iBAAM,MAAM,WAAE;gBACf,8BAAM,SAAS,EAAE,cAAc,EAAE,UAAU,EAAC,QAAQ;oBACjD,IAAK,CAAC,IAAK,CAAC,CAAC;;oBAAG,IAAA,iCAAqB,EAAC,IAAK,CAAC,IAAK,CAAC,CAAC,EAAE,OAAO,CAAC,CACzD,CACL,CACL,CAAC;QACJ,CAAC;QACH,iBAAC;IAAD,CAAC,AAfD,CAAgC,GAAG,GAelC;IAfY,gCAAU;IAiBvB,SAAS,YAAY,CAAC,QAAmB;QACvC,QAAQ,CAAC,GAAG,CAAC,WAAW,CAAC,QAAQ,CAAC,WAAW,CAAC,CAAC;QAC/C,QAAQ,CAAC,GAAG,CAAC,WAAW,CAAC,QAAQ,CAAC,WAAW,CAAC,CAAC;IACjD,CAAC","sourcesContent":["import * as React from 'react';\nimport * as shape from 'd3-shape';\nimport { IArcProps, IArcStyles } from './Arc.types';\nimport { classNamesFunction } from '@fluentui/react/lib/Utilities';\nimport { getStyles } from './Arc.styles';\nimport { convertToLocaleString } from '../../../utilities/utilities';\n\nexport class Arc extends React.Component<IArcProps, {}> {\n public static defaultProps: Partial<IArcProps> = {\n arc: shape.arc(),\n };\n\n public state: {} = {};\n\n public static getDerivedStateFromProps(nextProps: Readonly<IArcProps>): null {\n _updateChart(nextProps);\n return null;\n }\n\n public updateChart = (newProps: IArcProps) => {\n _updateChart(newProps);\n };\n\n public render(): JSX.Element {\n const { color, arc } = this.props;\n const getClassNames = classNamesFunction<IArcProps, IArcStyles>();\n const classNames = getClassNames(getStyles, { color });\n return <path d={arc(this.props.data)} className={classNames.root} onClick={this.props.data?.data.onClick} />;\n }\n}\n\nexport class LabeledArc extends Arc {\n public render(): JSX.Element {\n const { data, arc, culture } = this.props;\n const [labelX, labelY] = arc.centroid(data);\n const labelTranslate = `translate(${labelX}, ${labelY})`;\n\n return (\n <g className=\"arc\">\n {super.render()}\n <text transform={labelTranslate} textAnchor=\"middle\">\n {data!.data!.x}-{convertToLocaleString(data!.data!.y, culture)}\n </text>\n </g>\n );\n }\n}\n\nfunction _updateChart(newProps: IArcProps): void {\n newProps.arc.innerRadius(newProps.innerRadius);\n newProps.arc.outerRadius(newProps.outerRadius);\n}\n"]}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
define(["require", "exports", "tslib", "./Arc", "./Arc.types"], function (require, exports, tslib_1, Arc_1, Arc_types_1) {
|
|
2
2
|
"use strict";
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
|
|
5
|
-
|
|
4
|
+
tslib_1.__exportStar(Arc_1, exports);
|
|
5
|
+
tslib_1.__exportStar(Arc_types_1, exports);
|
|
6
6
|
});
|
|
7
7
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"../src/","sources":["components/PieChart/Arc/index.ts"],"names":[],"mappings":";;;IAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"../src/","sources":["components/PieChart/Arc/index.ts"],"names":[],"mappings":";;;IAAA,qCAAsB;IACtB,2CAA4B","sourcesContent":["export * from './Arc';\nexport * from './Arc.types';\n"]}
|
|
@@ -3,7 +3,7 @@ define(["require", "exports", "tslib", "react", "d3-shape", "d3-scale", "../Arc/
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
4
|
exports.Pie = void 0;
|
|
5
5
|
var Pie = /** @class */ (function (_super) {
|
|
6
|
-
|
|
6
|
+
tslib_1.__extends(Pie, _super);
|
|
7
7
|
function Pie(props) {
|
|
8
8
|
var _this = _super.call(this, props) || this;
|
|
9
9
|
_this.arcGenerator = function (d, i) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Pie.js","sourceRoot":"../src/","sources":["components/PieChart/Pie/Pie.tsx"],"names":[],"mappings":";;;;IAOA;QAAyB
|
|
1
|
+
{"version":3,"file":"Pie.js","sourceRoot":"../src/","sources":["components/PieChart/Pie/Pie.tsx"],"names":[],"mappings":";;;;IAOA;QAAyB,+BAA8B;QAUrD,aAAY,KAAgB;YAA5B,YACE,kBAAM,KAAK,CAAC,SACb;YAEM,kBAAY,GAAG,UAAC,CAAW,EAAE,CAAS;gBAC3C,OAAO,CACL,oBAAC,gBAAU,IACT,OAAO,EAAE,KAAI,CAAC,KAAK,CAAC,OAAO,EAC3B,GAAG,EAAE,CAAC,EACN,IAAI,EAAE,CAAC,EACP,WAAW,EAAE,KAAI,CAAC,KAAK,CAAC,WAAW,EACnC,WAAW,EAAE,KAAI,CAAC,KAAK,CAAC,WAAW,EACnC,KAAK,EAAE,UAAG,KAAI,CAAC,MAAM,CAAC,CAAC,CAAC,CAAE,GAC1B,CACH,CAAC;YACJ,CAAC,CAAC;;QAbF,CAAC;QAeM,oBAAM,GAAb;YAAA,iBAcC;YAbC,qEAAqE;YAC/D,IAAA,KAAmD,IAAI,CAAC,KAAK,EAA3D,GAAG,SAAA,EAAE,MAAM,YAAA,EAAE,IAAI,UAAA,EAAE,KAAK,WAAA,EAAE,MAAM,YAAA,EAAE,UAAU,gBAAe,CAAC;YAEpE,IAAI,CAAC,MAAM,GAAG,KAAK,CAAC,YAAY,EAAE,CAAC,KAAK,CAAC,MAAO,CAAC,CAAC;YAElD,IAAM,QAAQ,GAAG,GAAG,CAAC,IAAI,CAAC,CAAC;YAC3B,IAAM,SAAS,GAAG,oBAAa,KAAK,GAAG,CAAC,eAAK,MAAM,GAAG,CAAC,MAAG,CAAC;YAE3D,OAAO,CACL,6BAAK,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,gBAAc,UAAU;gBACvD,2BAAG,SAAS,EAAE,SAAS,IAAG,QAAQ,CAAC,GAAG,CAAC,UAAC,CAAW,EAAE,CAAS,IAAK,OAAA,KAAI,CAAC,YAAY,CAAC,CAAC,EAAE,CAAC,CAAC,EAAvB,CAAuB,CAAC,CAAK,CAC5F,CACP,CAAC;QACJ,CAAC;QAxCa,gBAAY,GAAuB;YAC/C,GAAG,EAAE,KAAK;iBACP,GAAG,EAAE;iBACL,IAAI,CAAC,IAAI,CAAC;gBACX,uDAAuD;iBACtD,KAAK,CAAC,UAAC,CAAM,IAAK,OAAA,CAAC,CAAC,CAAC,EAAH,CAAG,CAAC;SAC1B,CAAC;QAmCJ,UAAC;KAAA,AA1CD,CAAyB,KAAK,CAAC,SAAS,GA0CvC;IA1CY,kBAAG","sourcesContent":["import * as React from 'react';\nimport * as shape from 'd3-shape';\nimport * as scale from 'd3-scale';\nimport { IPieProps } from './Pie.types';\nimport { LabeledArc } from '../Arc/Arc';\nimport { IArcData } from '../Arc/Arc.types';\n\nexport class Pie extends React.Component<IPieProps, {}> {\n public static defaultProps: Partial<IPieProps> = {\n pie: shape\n .pie()\n .sort(null)\n /* eslint-disable @typescript-eslint/no-explicit-any */\n .value((d: any) => d.y),\n };\n private colors: scale.ScaleOrdinal<string | number, any>;\n\n constructor(props: IPieProps) {\n super(props);\n }\n\n public arcGenerator = (d: IArcData, i: number): JSX.Element => {\n return (\n <LabeledArc\n culture={this.props.culture}\n key={i}\n data={d}\n innerRadius={this.props.innerRadius}\n outerRadius={this.props.outerRadius}\n color={`${this.colors(i)}`}\n />\n );\n };\n\n public render(): JSX.Element {\n // const getClassNames = classNamesFunction<IPieProps, IPieStyles>();\n const { pie, colors, data, width, height, chartTitle } = this.props;\n\n this.colors = scale.scaleOrdinal().range(colors!);\n\n const piechart = pie(data);\n const translate = `translate(${width / 2}, ${height / 2})`;\n\n return (\n <svg width={width} height={height} aria-label={chartTitle}>\n <g transform={translate}>{piechart.map((d: IArcData, i: number) => this.arcGenerator(d, i))}</g>\n </svg>\n );\n }\n}\n"]}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
define(["require", "exports", "tslib", "./Pie", "./Pie.types"], function (require, exports, tslib_1, Pie_1, Pie_types_1) {
|
|
2
2
|
"use strict";
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
|
|
5
|
-
|
|
4
|
+
tslib_1.__exportStar(Pie_1, exports);
|
|
5
|
+
tslib_1.__exportStar(Pie_types_1, exports);
|
|
6
6
|
});
|
|
7
7
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"../src/","sources":["components/PieChart/Pie/index.ts"],"names":[],"mappings":";;;IAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"../src/","sources":["components/PieChart/Pie/index.ts"],"names":[],"mappings":";;;IAAA,qCAAsB;IACtB,2CAA4B","sourcesContent":["export * from './Pie';\nexport * from './Pie.types';\n"]}
|
|
@@ -1,7 +1,12 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { IPieChartProps } from './PieChart.types';
|
|
3
|
-
export
|
|
3
|
+
export interface IPieChartState {
|
|
4
|
+
emptyChart?: boolean;
|
|
5
|
+
}
|
|
6
|
+
export declare class PieChartBase extends React.Component<IPieChartProps, IPieChartState> {
|
|
4
7
|
static defaultProps: Partial<IPieChartProps>;
|
|
5
8
|
private _classNames;
|
|
9
|
+
constructor(props: IPieChartProps);
|
|
10
|
+
componentDidMount(): void;
|
|
6
11
|
render(): JSX.Element;
|
|
7
12
|
}
|
|
@@ -4,10 +4,22 @@ define(["require", "exports", "tslib", "react", "@fluentui/react/lib/Utilities",
|
|
|
4
4
|
exports.PieChartBase = void 0;
|
|
5
5
|
var getClassNames = (0, Utilities_1.classNamesFunction)();
|
|
6
6
|
var PieChartBase = /** @class */ (function (_super) {
|
|
7
|
-
|
|
8
|
-
function PieChartBase() {
|
|
9
|
-
|
|
7
|
+
tslib_1.__extends(PieChartBase, _super);
|
|
8
|
+
function PieChartBase(props) {
|
|
9
|
+
var _this = _super.call(this, props) || this;
|
|
10
|
+
_this.state = {
|
|
11
|
+
emptyChart: false,
|
|
12
|
+
};
|
|
13
|
+
return _this;
|
|
10
14
|
}
|
|
15
|
+
PieChartBase.prototype.componentDidMount = function () {
|
|
16
|
+
var isChartEmpty = !(this.props.data &&
|
|
17
|
+
this.props.data.length > 0 &&
|
|
18
|
+
this.props.data.filter(function (item) { return item.y > 0; }).length > 0);
|
|
19
|
+
if (this.state.emptyChart !== isChartEmpty) {
|
|
20
|
+
this.setState({ emptyChart: isChartEmpty });
|
|
21
|
+
}
|
|
22
|
+
};
|
|
11
23
|
PieChartBase.prototype.render = function () {
|
|
12
24
|
var _a = this.props, data = _a.data, width = _a.width, height = _a.height, colors = _a.colors, chartTitle = _a.chartTitle;
|
|
13
25
|
var _b = this.props, theme = _b.theme, className = _b.className, styles = _b.styles, culture = _b.culture;
|
|
@@ -19,9 +31,9 @@ define(["require", "exports", "tslib", "react", "@fluentui/react/lib/Utilities",
|
|
|
19
31
|
});
|
|
20
32
|
var radius = Math.min(width, height) / 2;
|
|
21
33
|
var outerRadius = radius - 10;
|
|
22
|
-
return (React.createElement("div", { className: this._classNames.root },
|
|
34
|
+
return !this.state.emptyChart ? (React.createElement("div", { className: this._classNames.root },
|
|
23
35
|
this.props.chartTitle && React.createElement("p", { className: this._classNames.chartTitle }, this.props.chartTitle),
|
|
24
|
-
React.createElement(Pie_1.Pie, { culture: culture, width: width, height: height, outerRadius: outerRadius, innerRadius: 0, data: data, colors: colors, chartTitle: chartTitle })));
|
|
36
|
+
React.createElement(Pie_1.Pie, { culture: culture, width: width, height: height, outerRadius: outerRadius, innerRadius: 0, data: data, colors: colors, chartTitle: chartTitle }))) : (React.createElement("div", { id: (0, Utilities_1.getId)('_PieChart_'), role: 'alert', style: { opacity: '0' }, "aria-label": 'Graph has no data to display' }));
|
|
25
37
|
};
|
|
26
38
|
PieChartBase.defaultProps = {
|
|
27
39
|
data: [],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PieChart.base.js","sourceRoot":"../src/","sources":["components/PieChart/PieChart.base.tsx"],"names":[],"mappings":";;;;
|
|
1
|
+
{"version":3,"file":"PieChart.base.js","sourceRoot":"../src/","sources":["components/PieChart/PieChart.base.tsx"],"names":[],"mappings":";;;;IAMA,IAAM,aAAa,GAAG,IAAA,8BAAkB,GAAwC,CAAC;IAKjF;QAAkC,wCAA+C;QAQ/E,sBAAmB,KAAqB;YAAxC,YACE,kBAAM,KAAK,CAAC,SAIb;YAHC,KAAI,CAAC,KAAK,GAAG;gBACX,UAAU,EAAE,KAAK;aAClB,CAAC;;QACJ,CAAC;QAEM,wCAAiB,GAAxB;YACE,IAAM,YAAY,GAAG,CAAC,CACpB,IAAI,CAAC,KAAK,CAAC,IAAI;gBACf,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,GAAG,CAAC;gBAC1B,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,UAAA,IAAI,IAAI,OAAA,IAAI,CAAC,CAAC,GAAG,CAAC,EAAV,CAAU,CAAC,CAAC,MAAM,GAAG,CAAC,CACtD,CAAC;YACF,IAAI,IAAI,CAAC,KAAK,CAAC,UAAU,KAAK,YAAY,EAAE;gBAC1C,IAAI,CAAC,QAAQ,CAAC,EAAE,UAAU,EAAE,YAAY,EAAE,CAAC,CAAC;aAC7C;QACH,CAAC;QAEM,6BAAM,GAAb;YACQ,IAAA,KAA8C,IAAI,CAAC,KAAK,EAAtD,IAAI,UAAA,EAAE,KAAK,WAAA,EAAE,MAAM,YAAA,EAAE,MAAM,YAAA,EAAE,UAAU,gBAAe,CAAC;YAEzD,IAAA,KAAwC,IAAI,CAAC,KAAK,EAAhD,KAAK,WAAA,EAAE,SAAS,eAAA,EAAE,MAAM,YAAA,EAAE,OAAO,aAAe,CAAC;YACzD,IAAI,CAAC,WAAW,GAAG,aAAa,CAAC,MAAO,EAAE;gBACxC,KAAK,EAAE,KAAM;gBACb,KAAK,EAAE,KAAM;gBACb,MAAM,EAAE,MAAO;gBACf,SAAS,WAAA;aACV,CAAC,CAAC;YACH,IAAM,MAAM,GAAG,IAAI,CAAC,GAAG,CAAC,KAAM,EAAE,MAAO,CAAC,GAAG,CAAC,CAAC;YAC7C,IAAM,WAAW,GAAG,MAAM,GAAG,EAAE,CAAC;YAEhC,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,UAAU,CAAC,CAAC,CAAC,CAC9B,6BAAK,SAAS,EAAE,IAAI,CAAC,WAAW,CAAC,IAAI;gBAClC,IAAI,CAAC,KAAK,CAAC,UAAU,IAAI,2BAAG,SAAS,EAAE,IAAI,CAAC,WAAW,CAAC,UAAU,IAAG,IAAI,CAAC,KAAK,CAAC,UAAU,CAAK;gBAChG,oBAAC,SAAG,IACF,OAAO,EAAE,OAAO,EAChB,KAAK,EAAE,KAAM,EACb,MAAM,EAAE,MAAO,EACf,WAAW,EAAE,WAAW,EACxB,WAAW,EAAE,CAAC,EACd,IAAI,EAAE,IAAK,EACX,MAAM,EAAE,MAAO,EACf,UAAU,EAAE,UAAW,GACvB,CACE,CACP,CAAC,CAAC,CAAC,CACF,6BACE,EAAE,EAAE,IAAA,iBAAK,EAAC,YAAY,CAAC,EACvB,IAAI,EAAE,OAAO,EACb,KAAK,EAAE,EAAE,OAAO,EAAE,GAAG,EAAE,gBACX,8BAA8B,GAC1C,CACH,CAAC;QACJ,CAAC;QA5Da,yBAAY,GAA4B;YACpD,IAAI,EAAE,EAAE;YACR,KAAK,EAAE,GAAG;YACV,MAAM,EAAE,GAAG;SACZ,CAAC;QAyDJ,mBAAC;KAAA,AA9DD,CAAkC,KAAK,CAAC,SAAS,GA8DhD;IA9DY,oCAAY","sourcesContent":["import * as React from 'react';\nimport { classNamesFunction, getId } from '@fluentui/react/lib/Utilities';\nimport { IPieChartProps, IPieChartStyleProps, IPieChartStyles } from './PieChart.types';\nimport { Pie } from './Pie/Pie';\nimport { IProcessedStyleSet } from '@fluentui/react/lib/Styling';\n\nconst getClassNames = classNamesFunction<IPieChartStyleProps, IPieChartStyles>();\nexport interface IPieChartState {\n emptyChart?: boolean;\n}\n\nexport class PieChartBase extends React.Component<IPieChartProps, IPieChartState> {\n public static defaultProps: Partial<IPieChartProps> = {\n data: [],\n width: 600,\n height: 350,\n };\n private _classNames: IProcessedStyleSet<IPieChartStyles>;\n\n public constructor(props: IPieChartProps) {\n super(props);\n this.state = {\n emptyChart: false,\n };\n }\n\n public componentDidMount(): void {\n const isChartEmpty = !(\n this.props.data &&\n this.props.data.length > 0 &&\n this.props.data.filter(item => item.y > 0).length > 0\n );\n if (this.state.emptyChart !== isChartEmpty) {\n this.setState({ emptyChart: isChartEmpty });\n }\n }\n\n public render(): JSX.Element {\n const { data, width, height, colors, chartTitle } = this.props;\n\n const { theme, className, styles, culture } = this.props;\n this._classNames = getClassNames(styles!, {\n theme: theme!,\n width: width!,\n height: height!,\n className,\n });\n const radius = Math.min(width!, height!) / 2;\n const outerRadius = radius - 10;\n\n return !this.state.emptyChart ? (\n <div className={this._classNames.root}>\n {this.props.chartTitle && <p className={this._classNames.chartTitle}>{this.props.chartTitle}</p>}\n <Pie\n culture={culture}\n width={width!}\n height={height!}\n outerRadius={outerRadius}\n innerRadius={0}\n data={data!}\n colors={colors!}\n chartTitle={chartTitle!}\n />\n </div>\n ) : (\n <div\n id={getId('_PieChart_')}\n role={'alert'}\n style={{ opacity: '0' }}\n aria-label={'Graph has no data to display'}\n />\n );\n }\n}\n"]}
|
|
@@ -25,7 +25,7 @@ define(["require", "exports", "tslib"], function (require, exports, tslib_1) {
|
|
|
25
25
|
},
|
|
26
26
|
],
|
|
27
27
|
chartTitle: [
|
|
28
|
-
|
|
28
|
+
tslib_1.__assign({ textAlign: 'center' }, theme.fonts.mediumPlus),
|
|
29
29
|
],
|
|
30
30
|
};
|
|
31
31
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PieChart.styles.js","sourceRoot":"../src/","sources":["components/PieChart/PieChart.styles.ts"],"names":[],"mappings":";;;;IAEO,IAAM,SAAS,GAAG,UAAC,KAA0B;QAC1C,IAAA,SAAS,GAA2B,KAAK,UAAhC,EAAE,KAAK,GAAoB,KAAK,MAAzB,EAAE,KAAK,GAAa,KAAK,MAAlB,EAAE,MAAM,GAAK,KAAK,OAAV,CAAW;QAElD,IAAM,UAAU,GAAG,KAAK,GAAG,EAAE,CAAC;QAC9B,IAAM,YAAY,GAAG,EAAE,CAAC;QACxB,IAAM,WAAW,GAAG,MAAM,GAAG,EAAE,CAAC;QAEhC,OAAO;YACL,IAAI,EAAE;gBACJ,KAAK,CAAC,KAAK,CAAC,MAAM;gBAClB,aAAa;gBACb,SAAS;gBACT;oBACE,KAAK,EAAE,UAAU,GAAG,CAAC,GAAG,YAAY;iBACrC;aACF;YACD,KAAK,EAAE;gBACL;oBACE,OAAO,EAAE,YAAY;oBACrB,KAAK,EAAE,UAAU;oBACjB,MAAM,EAAE,WAAW;oBACnB,SAAS,EAAE,aAAa;iBACzB;aACF;YACD,UAAU,EAAE;
|
|
1
|
+
{"version":3,"file":"PieChart.styles.js","sourceRoot":"../src/","sources":["components/PieChart/PieChart.styles.ts"],"names":[],"mappings":";;;;IAEO,IAAM,SAAS,GAAG,UAAC,KAA0B;QAC1C,IAAA,SAAS,GAA2B,KAAK,UAAhC,EAAE,KAAK,GAAoB,KAAK,MAAzB,EAAE,KAAK,GAAa,KAAK,MAAlB,EAAE,MAAM,GAAK,KAAK,OAAV,CAAW;QAElD,IAAM,UAAU,GAAG,KAAK,GAAG,EAAE,CAAC;QAC9B,IAAM,YAAY,GAAG,EAAE,CAAC;QACxB,IAAM,WAAW,GAAG,MAAM,GAAG,EAAE,CAAC;QAEhC,OAAO;YACL,IAAI,EAAE;gBACJ,KAAK,CAAC,KAAK,CAAC,MAAM;gBAClB,aAAa;gBACb,SAAS;gBACT;oBACE,KAAK,EAAE,UAAU,GAAG,CAAC,GAAG,YAAY;iBACrC;aACF;YACD,KAAK,EAAE;gBACL;oBACE,OAAO,EAAE,YAAY;oBACrB,KAAK,EAAE,UAAU;oBACjB,MAAM,EAAE,WAAW;oBACnB,SAAS,EAAE,aAAa;iBACzB;aACF;YACD,UAAU,EAAE;mCAER,SAAS,EAAE,QAAQ,IAChB,KAAK,CAAC,KAAK,CAAC,UAAU;aAE5B;SACF,CAAC;IACJ,CAAC,CAAC;IA/BW,QAAA,SAAS,aA+BpB","sourcesContent":["import { IPieChartStyleProps, IPieChartStyles } from './PieChart.types';\n\nexport const getStyles = (props: IPieChartStyleProps): IPieChartStyles => {\n const { className, theme, width, height } = props;\n\n const chartWidth = width + 30;\n const chartPadding = 20;\n const chartHeight = height + 10;\n\n return {\n root: [\n theme.fonts.medium,\n 'ms-PieChart',\n className,\n {\n width: chartWidth + 2 * chartPadding,\n },\n ],\n chart: [\n {\n padding: chartPadding,\n width: chartWidth,\n height: chartHeight,\n boxSizing: 'content-box',\n },\n ],\n chartTitle: [\n {\n textAlign: 'center',\n ...theme.fonts.mediumPlus,\n },\n ],\n };\n};\n"]}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
define(["require", "exports", "tslib", "./PieChart", "./PieChart.types"], function (require, exports, tslib_1, PieChart_1, PieChart_types_1) {
|
|
2
2
|
"use strict";
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
|
|
5
|
-
|
|
4
|
+
tslib_1.__exportStar(PieChart_1, exports);
|
|
5
|
+
tslib_1.__exportStar(PieChart_types_1, exports);
|
|
6
6
|
});
|
|
7
7
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"../src/","sources":["components/PieChart/index.ts"],"names":[],"mappings":";;;IAAA
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"../src/","sources":["components/PieChart/index.ts"],"names":[],"mappings":";;;IAAA,0CAA2B;IAC3B,gDAAiC","sourcesContent":["export * from './PieChart';\nexport * from './PieChart.types';\n"]}
|
|
@@ -11,6 +11,7 @@ export interface ISankeyChartState extends IBasestate, IChartHoverCardProps {
|
|
|
11
11
|
refSelected?: any;
|
|
12
12
|
selectedLink?: SLink;
|
|
13
13
|
shouldOverflow: boolean;
|
|
14
|
+
emptyChart?: boolean;
|
|
14
15
|
}
|
|
15
16
|
export declare class SankeyChartBase extends React.Component<ISankeyChartProps, ISankeyChartState> {
|
|
16
17
|
private _classNames;
|
|
@@ -26,7 +26,7 @@ define(["require", "exports", "tslib", "react", "@fluentui/react/lib/Utilities",
|
|
|
26
26
|
var DEFAULT_TEXT_COLOR = '#323130';
|
|
27
27
|
var NON_SELECTED_TEXT_COLOR = '#FFFFFF';
|
|
28
28
|
var SankeyChartBase = /** @class */ (function (_super) {
|
|
29
|
-
|
|
29
|
+
tslib_1.__extends(SankeyChartBase, _super);
|
|
30
30
|
function SankeyChartBase(props) {
|
|
31
31
|
var _this = _super.call(this, props) || this;
|
|
32
32
|
_this._isRtl = (0, Utilities_1.getRTL)();
|
|
@@ -74,6 +74,10 @@ define(["require", "exports", "tslib", "react", "@fluentui/react/lib/Utilities",
|
|
|
74
74
|
selectedNodes: new Set(),
|
|
75
75
|
shouldOverflow: false,
|
|
76
76
|
isCalloutVisible: false,
|
|
77
|
+
emptyChart: !(_this.props.data &&
|
|
78
|
+
_this.props.data.SankeyChartData &&
|
|
79
|
+
_this.props.data.SankeyChartData.nodes.length > 0 &&
|
|
80
|
+
_this.props.data.SankeyChartData.links.length > 0),
|
|
77
81
|
};
|
|
78
82
|
_this._calloutId = (0, Utilities_1.getId)('callout');
|
|
79
83
|
_this._linkId = (0, Utilities_1.getId)('link');
|
|
@@ -95,47 +99,50 @@ define(["require", "exports", "tslib", "react", "@fluentui/react/lib/Utilities",
|
|
|
95
99
|
};
|
|
96
100
|
SankeyChartBase.prototype.render = function () {
|
|
97
101
|
var _this = this;
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
React.createElement(
|
|
134
|
-
React.createElement(
|
|
135
|
-
React.createElement("
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
React.createElement(
|
|
102
|
+
if (!this.state.emptyChart) {
|
|
103
|
+
var _a = this.props, theme = _a.theme, className = _a.className, styles = _a.styles, pathColor = _a.pathColor;
|
|
104
|
+
this._classNames = getClassNames(styles, {
|
|
105
|
+
theme: theme,
|
|
106
|
+
width: this.state.containerWidth,
|
|
107
|
+
height: this.state.containerHeight,
|
|
108
|
+
pathColor: pathColor,
|
|
109
|
+
className: className,
|
|
110
|
+
});
|
|
111
|
+
// We are using the this._margins.left and this._margins.top in sankey extent while constructing the layout
|
|
112
|
+
var _b = this._preRenderLayout(), height = _b.height, width = _b.width;
|
|
113
|
+
this._normalizeData(this.props.data.SankeyChartData);
|
|
114
|
+
var nodePadding = 8;
|
|
115
|
+
nodePadding = this._adjustPadding(this._sankey, height - 6, this._nodesInColumn);
|
|
116
|
+
this._sankey.nodePadding(nodePadding);
|
|
117
|
+
this._sankey(this.props.data.SankeyChartData);
|
|
118
|
+
this._populateNodeActualValue(this.props.data.SankeyChartData);
|
|
119
|
+
this._assignNodeColors();
|
|
120
|
+
var nodeData = this._createNodes(width);
|
|
121
|
+
var linkData = this._createLinks();
|
|
122
|
+
var calloutProps = {
|
|
123
|
+
isCalloutVisible: this.state.isCalloutVisible,
|
|
124
|
+
directionalHint: Callout_1.DirectionalHint.topAutoEdge,
|
|
125
|
+
id: "toolTip".concat(this._calloutId),
|
|
126
|
+
target: this.state.refSelected,
|
|
127
|
+
color: this.state.color,
|
|
128
|
+
XValue: this.state.xCalloutValue,
|
|
129
|
+
YValue: this.state.yCalloutValue ? this.state.yCalloutValue : this.state.dataForHoverCard,
|
|
130
|
+
descriptionMessage: this.state.descriptionMessage,
|
|
131
|
+
isBeakVisible: false,
|
|
132
|
+
gapSpace: 15,
|
|
133
|
+
onDismiss: this._onCloseCallout,
|
|
134
|
+
className: this._classNames.calloutContentRoot,
|
|
135
|
+
preventDismissOnLostFocus: true,
|
|
136
|
+
};
|
|
137
|
+
return (React.createElement("div", { className: this._classNames.root, role: 'presentation', ref: function (rootElem) { return (_this.chartContainer = rootElem); }, onMouseLeave: this._onCloseCallout },
|
|
138
|
+
React.createElement(react_focus_1.FocusZone, { direction: react_focus_1.FocusZoneDirection.bidirectional, isCircularNavigation: true, handleTabKey: react_focus_1.FocusZoneTabbableElements.all },
|
|
139
|
+
React.createElement("svg", { width: width, height: height, id: (0, Utilities_1.getId)('sankeyChart') },
|
|
140
|
+
React.createElement("g", { className: this._classNames.links, strokeOpacity: 1 }, linkData),
|
|
141
|
+
React.createElement("g", { className: this._classNames.nodes }, nodeData),
|
|
142
|
+
calloutProps.isCalloutVisible && (React.createElement(Callout_1.Callout, tslib_1.__assign({}, calloutProps),
|
|
143
|
+
React.createElement(index_1.ChartHoverCard, { XValue: calloutProps.XValue, YValue: calloutProps.YValue, color: calloutProps.color, descriptionMessage: calloutProps.descriptionMessage ? calloutProps.descriptionMessage : '' })))))));
|
|
144
|
+
}
|
|
145
|
+
return (React.createElement("div", { id: (0, Utilities_1.getId)('_SankeyChart_'), role: 'alert', style: { opacity: '0' }, "aria-label": 'Graph has no data to display' }));
|
|
139
146
|
};
|
|
140
147
|
SankeyChartBase.prototype._preRenderLayout = function () {
|
|
141
148
|
var width = this.state.containerWidth - this._margins.right;
|