@evergis/charts 3.1.6 → 3.1.8
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/LICENSE +2 -2
- package/README.md +10 -0
- package/dist/charts/BarChart/draw.d.ts +2 -2
- package/dist/charts/BarChart/drawGrid/index.d.ts +2 -2
- package/dist/charts/BarChart/drawGrid/types.d.ts +8 -8
- package/dist/charts/BarChart/drawLines/index.d.ts +13 -13
- package/dist/charts/BarChart/drawLines/types.d.ts +9 -9
- package/dist/charts/BarChart/drawTooltip/getLabel.d.ts +2 -2
- package/dist/charts/BarChart/drawTooltip/getLabelY.d.ts +2 -2
- package/dist/charts/BarChart/drawTooltip/index.d.ts +2 -2
- package/dist/charts/BarChart/drawTooltip/types.d.ts +12 -13
- package/dist/charts/BarChart/getBars/index.d.ts +3 -3
- package/dist/charts/BarChart/getBars/types.d.ts +6 -6
- package/dist/charts/BarChart/getDomain.d.ts +5 -5
- package/dist/charts/BarChart/hooks/useSelection.d.ts +2 -2
- package/dist/charts/BarChart/index.d.ts +3 -3
- package/dist/charts/BarChart/marshaling.d.ts +2 -2
- package/dist/charts/BarChart/resizeBarWidth/index.d.ts +2 -2
- package/dist/charts/BarChart/resizeBarWidth/types.d.ts +5 -5
- package/dist/charts/BarChart/styled.d.ts +37 -37
- package/dist/charts/BarChart/types.d.ts +148 -148
- package/dist/charts/BubbleChart/bubbleChartDefaultProps.d.ts +14 -14
- package/dist/charts/BubbleChart/draw.d.ts +2 -2
- package/dist/charts/BubbleChart/drawGrid/index.d.ts +2 -2
- package/dist/charts/BubbleChart/drawGrid/types.d.ts +8 -8
- package/dist/charts/BubbleChart/drawTooltip/index.d.ts +2 -2
- package/dist/charts/BubbleChart/drawTooltip/styled.d.ts +1 -1
- package/dist/charts/BubbleChart/drawTooltip/types.d.ts +4 -4
- package/dist/charts/BubbleChart/index.d.ts +3 -3
- package/dist/charts/BubbleChart/styled.d.ts +17 -17
- package/dist/charts/BubbleChart/types.d.ts +55 -55
- package/dist/charts/BubbleChart/unmount.d.ts +1 -1
- package/dist/charts/CalendarChart/draw.d.ts +2 -2
- package/dist/charts/CalendarChart/index.d.ts +3 -3
- package/dist/charts/CalendarChart/styled.d.ts +18 -18
- package/dist/charts/CalendarChart/types.d.ts +22 -22
- package/dist/charts/HorizontalBarChart/Bar/index.d.ts +3 -3
- package/dist/charts/HorizontalBarChart/Bar/styled.d.ts +1 -1
- package/dist/charts/HorizontalBarChart/Bar/types.d.ts +11 -11
- package/dist/charts/HorizontalBarChart/Tooltip/index.d.ts +3 -3
- package/dist/charts/HorizontalBarChart/Tooltip/types.d.ts +5 -5
- package/dist/charts/HorizontalBarChart/XScale/hooks/useScale.d.ts +2 -2
- package/dist/charts/HorizontalBarChart/XScale/index.d.ts +3 -3
- package/dist/charts/HorizontalBarChart/XScale/styled.d.ts +3 -3
- package/dist/charts/HorizontalBarChart/hooks/useMarshaling.d.ts +5 -5
- package/dist/charts/HorizontalBarChart/hooks/useStackWrapper.d.ts +12 -12
- package/dist/charts/HorizontalBarChart/hooks/useTooltip/index.d.ts +3 -3
- package/dist/charts/HorizontalBarChart/hooks/useTooltip/types.d.ts +6 -3
- package/dist/charts/HorizontalBarChart/index.d.ts +3 -3
- package/dist/charts/HorizontalBarChart/styled.d.ts +30 -30
- package/dist/charts/HorizontalBarChart/types.d.ts +41 -41
- package/dist/charts/LineChart/draw.d.ts +2 -2
- package/dist/charts/LineChart/drawGrid/index.d.ts +2 -2
- package/dist/charts/LineChart/drawGrid/types.d.ts +9 -9
- package/dist/charts/LineChart/drawLabel/index.d.ts +3 -3
- package/dist/charts/LineChart/drawLabel/styled.d.ts +2 -2
- package/dist/charts/LineChart/drawLabel/types.d.ts +7 -7
- package/dist/charts/LineChart/drawTooltip/index.d.ts +2 -2
- package/dist/charts/LineChart/drawTooltip/types.d.ts +9 -9
- package/dist/charts/LineChart/index.d.ts +3 -3
- package/dist/charts/LineChart/styled.d.ts +27 -27
- package/dist/charts/LineChart/types.d.ts +78 -78
- package/dist/charts/PieChart/draw.d.ts +2 -2
- package/dist/charts/PieChart/drawRadialLabels/helpers.d.ts +3 -3
- package/dist/charts/PieChart/drawRadialLabels/index.d.ts +2 -2
- package/dist/charts/PieChart/drawRadialLabels/types.d.ts +11 -11
- package/dist/charts/PieChart/drawTooltips/index.d.ts +2 -2
- package/dist/charts/PieChart/drawTooltips/types.d.ts +8 -8
- package/dist/charts/PieChart/index.d.ts +3 -3
- package/dist/charts/PieChart/styled.d.ts +18 -18
- package/dist/charts/PieChart/types.d.ts +54 -54
- package/dist/charts/RadarChart/draw.d.ts +2 -2
- package/dist/charts/RadarChart/drawRadialLabels/index.d.ts +2 -2
- package/dist/charts/RadarChart/drawRadialLabels/styled.d.ts +2 -2
- package/dist/charts/RadarChart/drawRadialLabels/types.d.ts +25 -25
- package/dist/charts/RadarChart/helpers.d.ts +2 -2
- package/dist/charts/RadarChart/index.d.ts +3 -3
- package/dist/charts/RadarChart/styled.d.ts +13 -13
- package/dist/charts/RadarChart/types.d.ts +42 -42
- package/dist/charts.esm.js +3327 -3297
- package/dist/charts.esm.js.map +1 -1
- package/dist/common/components/SwipeScroll/animate.d.ts +6 -6
- package/dist/common/components/SwipeScroll/hooks/useSwipe.d.ts +2 -2
- package/dist/common/components/SwipeScroll/index.d.ts +3 -3
- package/dist/common/components/SwipeScroll/styled.d.ts +1 -1
- package/dist/common/components/SwipeScroll/types.d.ts +8 -8
- package/dist/common/components/Wrapper.d.ts +1 -1
- package/dist/common/components/labels/index.d.ts +7 -7
- package/dist/common/components/labels/types.d.ts +6 -6
- package/dist/common/components/tooltips/index.d.ts +14 -14
- package/dist/common/types/interpolator.d.ts +1 -1
- package/dist/common/types/margin.d.ts +6 -6
- package/dist/helpers/appendSvg.d.ts +2 -2
- package/dist/helpers/common.d.ts +2 -2
- package/dist/helpers/computeDimensions.d.ts +2 -2
- package/dist/helpers/getLegend/index.d.ts +19 -19
- package/dist/helpers/getLegend/types.d.ts +15 -15
- package/dist/helpers/getTextWidth.d.ts +1 -1
- package/dist/helpers/index.d.ts +1 -1
- package/dist/helpers/math.d.ts +2 -2
- package/dist/helpers/stackedData.d.ts +2 -2
- package/dist/helpers/textAlignCenter.d.ts +2 -2
- package/dist/helpers/throttle.d.ts +1 -1
- package/dist/hooks/index.d.ts +2 -2
- package/dist/hooks/useNode.d.ts +2 -2
- package/dist/hooks/useResize.d.ts +1 -1
- package/dist/index.d.ts +26 -26
- package/dist/index.js +3553 -5
- package/dist/index.js.map +1 -0
- package/package.json +29 -40
- package/dist/charts.cjs.development.js +0 -3513
- package/dist/charts.cjs.development.js.map +0 -1
- package/dist/charts.cjs.production.min.js +0 -2
- package/dist/charts.cjs.production.min.js.map +0 -1
- package/dist/jest.config.d.ts +0 -14
- package/dist/stories/Bar/Examples.stories.d.ts +0 -23
- package/dist/stories/Bar/HorizontalBar.stories.d.ts +0 -25
- package/dist/stories/Bar/Statistics.stories.d.ts +0 -7
- package/dist/stories/Bar/VerticalBar.stories.d.ts +0 -41
- package/dist/stories/Bubble/Bubble.stories.d.ts +0 -23
- package/dist/stories/Bubble/Examples.stories.d.ts +0 -4
- package/dist/stories/Bubble/examples/VEB/InvestBubble.d.ts +0 -5
- package/dist/stories/Bubble/examples/VEB/hooks/useCustomize.d.ts +0 -3
- package/dist/stories/Bubble/examples/VEB/hooks/useRenderTooltip/index.d.ts +0 -4
- package/dist/stories/Bubble/examples/VEB/hooks/useRenderTooltip/styled.d.ts +0 -8
- package/dist/stories/Bubble/examples/VEB/styled.d.ts +0 -1
- package/dist/stories/Calendar/Calendar.stories.d.ts +0 -23
- package/dist/stories/Calendar/ColorScheme.stories.d.ts +0 -7
- package/dist/stories/Calendar/Examples.stories.d.ts +0 -11
- package/dist/stories/Calendar/Legend.stories.d.ts +0 -30
- package/dist/stories/Common/SwipeScroll/SwipeScroll.stories.d.ts +0 -13
- package/dist/stories/Common/SwipeScroll/hooks/useSwipe.d.ts +0 -1
- package/dist/stories/Line/Examples.stories.d.ts +0 -7
- package/dist/stories/Line/Line.stories.d.ts +0 -48
- package/dist/stories/Line/examples/Beeline.d.ts +0 -5
- package/dist/stories/Line/examples/GeoVeb.d.ts +0 -5
- package/dist/stories/Line/examples/GeoVebInterval/data.d.ts +0 -9
- package/dist/stories/Line/examples/GeoVebInterval/index.d.ts +0 -5
- package/dist/stories/Line/examples/GeoVebInterval/styled.d.ts +0 -4
- package/dist/stories/Line/examples/Msp.d.ts +0 -5
- package/dist/stories/Pie/ColorScheme.stories.d.ts +0 -7
- package/dist/stories/Pie/Examples.stories.d.ts +0 -7
- package/dist/stories/Pie/Pie.stories.d.ts +0 -47
- package/dist/stories/Radar/Chart.stories.d.ts +0 -38
- package/dist/stories/Radar/Github.stories.d.ts +0 -7
- package/dist/stories/Radar/Gradient.stories.d.ts +0 -7
- package/dist/stories/Radar/Veb.stories.d.ts +0 -7
- package/dist/stories/Sankey/Examples.stories.d.ts +0 -4
- package/dist/stories/Sankey/examples/RelatedIndustries/data.d.ts +0 -2
- package/dist/stories/Sankey/examples/RelatedIndustries/index.d.ts +0 -5
- package/dist/stories/__internal__/colors.d.ts +0 -40
- package/dist/stories/__internal__/components/BeelineLineChart/hooks/useCustomize.d.ts +0 -11
- package/dist/stories/__internal__/components/BeelineLineChart/hooks/useLineRenderTooltip/index.d.ts +0 -5
- package/dist/stories/__internal__/components/BeelineLineChart/hooks/useLineRenderTooltip/styled.d.ts +0 -5
- package/dist/stories/__internal__/components/BeelineLineChart/index.d.ts +0 -3
- package/dist/stories/__internal__/components/BeelineLineChart/styled.d.ts +0 -3
- package/dist/stories/__internal__/components/BeelineRangeLineChart/Range/index.d.ts +0 -7
- package/dist/stories/__internal__/components/BeelineRangeLineChart/Range/styled.d.ts +0 -3
- package/dist/stories/__internal__/components/BeelineRangeLineChart/hooks/useChange.d.ts +0 -8
- package/dist/stories/__internal__/components/BeelineRangeLineChart/index.d.ts +0 -2
- package/dist/stories/__internal__/components/BeelineRangeLineChart/styled.d.ts +0 -4
- package/dist/stories/__internal__/components/BeelineTrafficHorizontalBarChart/data.d.ts +0 -5
- package/dist/stories/__internal__/components/BeelineTrafficHorizontalBarChart/hooks/useRenderDataTable.d.ts +0 -2
- package/dist/stories/__internal__/components/BeelineTrafficHorizontalBarChart/index.d.ts +0 -2
- package/dist/stories/__internal__/components/BeelineTrafficHorizontalBarChart/styled.d.ts +0 -3
- package/dist/stories/__internal__/components/Divider.d.ts +0 -6
- package/dist/stories/__internal__/components/GeoVebBarCharts.d.ts +0 -2
- package/dist/stories/__internal__/components/GeoVebHorizontalBarCharts/data.d.ts +0 -47
- package/dist/stories/__internal__/components/GeoVebHorizontalBarCharts/hooks/useRenderTooltip.d.ts +0 -3
- package/dist/stories/__internal__/components/GeoVebHorizontalBarCharts/hooks/useSimpleRenderTooltip.d.ts +0 -3
- package/dist/stories/__internal__/components/GeoVebHorizontalBarCharts/index.d.ts +0 -4
- package/dist/stories/__internal__/components/GeoVebHorizontalBarCharts/styled.d.ts +0 -4
- package/dist/stories/__internal__/components/GeoYearsBarChart/index.d.ts +0 -2
- package/dist/stories/__internal__/components/GeoYearsBarChart/styled.d.ts +0 -4
- package/dist/stories/__internal__/components/MixedTableChart/Chart/index.d.ts +0 -3
- package/dist/stories/__internal__/components/MixedTableChart/Chart/styled.d.ts +0 -2
- package/dist/stories/__internal__/components/MixedTableChart/index.d.ts +0 -3
- package/dist/stories/__internal__/components/MixedTableChart/styled.d.ts +0 -5
- package/dist/stories/__internal__/components/MixedTableChart/types.d.ts +0 -21
- package/dist/stories/__internal__/components/MspDashboardChart/hooks/useAnimation.d.ts +0 -5
- package/dist/stories/__internal__/components/MspDashboardChart/index.d.ts +0 -3
- package/dist/stories/__internal__/components/MspDashboardChart/styled.d.ts +0 -5
- package/dist/stories/__internal__/components/MspPromSupplyBarChart/hooks/useAnimationAreas.d.ts +0 -6
- package/dist/stories/__internal__/components/MspPromSupplyBarChart/hooks/useAnimationBars.d.ts +0 -5
- package/dist/stories/__internal__/components/MspPromSupplyBarChart/hooks/useCustomize.d.ts +0 -4
- package/dist/stories/__internal__/components/MspPromSupplyBarChart/hooks/useData.d.ts +0 -8
- package/dist/stories/__internal__/components/MspPromSupplyBarChart/hooks/useMarshalledMap.d.ts +0 -1
- package/dist/stories/__internal__/components/MspPromSupplyBarChart/hooks/useRenderTooltip.d.ts +0 -2
- package/dist/stories/__internal__/components/MspPromSupplyBarChart/index.d.ts +0 -9
- package/dist/stories/__internal__/components/MspPromSupplyBarChart/styled.d.ts +0 -22
- package/dist/stories/__internal__/components/SankeyTriChart/Groups/getCSSProperties.d.ts +0 -4
- package/dist/stories/__internal__/components/SankeyTriChart/Groups/helpers.d.ts +0 -1
- package/dist/stories/__internal__/components/SankeyTriChart/Groups/index.d.ts +0 -5
- package/dist/stories/__internal__/components/SankeyTriChart/Groups/styled.d.ts +0 -1
- package/dist/stories/__internal__/components/SankeyTriChart/ItemContent/getCSSProperties.d.ts +0 -3
- package/dist/stories/__internal__/components/SankeyTriChart/ItemContent/index.d.ts +0 -5
- package/dist/stories/__internal__/components/SankeyTriChart/ItemContent/styled.d.ts +0 -8
- package/dist/stories/__internal__/components/SankeyTriChart/draw.d.ts +0 -2
- package/dist/stories/__internal__/components/SankeyTriChart/helpers.d.ts +0 -9
- package/dist/stories/__internal__/components/SankeyTriChart/index.d.ts +0 -10
- package/dist/stories/__internal__/components/SankeyTriChart/marshaling.d.ts +0 -6
- package/dist/stories/__internal__/components/SankeyTriChart/styled.d.ts +0 -1
- package/dist/stories/__internal__/components/SankeyTriChart/types.d.ts +0 -40
- package/dist/stories/__internal__/components/SberBarMixChart/colors.d.ts +0 -3
- package/dist/stories/__internal__/components/SberBarMixChart/data.d.ts +0 -8
- package/dist/stories/__internal__/components/SberBarMixChart/hooks/styled.d.ts +0 -3
- package/dist/stories/__internal__/components/SberBarMixChart/hooks/useRenderTooltip.d.ts +0 -2
- package/dist/stories/__internal__/components/SberBarMixChart/index.d.ts +0 -2
- package/dist/stories/__internal__/components/SberBarMixChart/styled.d.ts +0 -1
- package/dist/stories/__internal__/components/StatisticsBarCharts/NumbersStatistics.d.ts +0 -2
- package/dist/stories/__internal__/components/StatisticsBarCharts/StringsStatistics.d.ts +0 -2
- package/dist/stories/__internal__/components/StatisticsBarCharts/index.d.ts +0 -2
- package/dist/stories/__internal__/components/StatisticsBarCharts/styled.d.ts +0 -1
- package/dist/stories/__internal__/components/VebEstimationBarChart/data.d.ts +0 -38
- package/dist/stories/__internal__/components/VebEstimationBarChart/hooks/useCustomize.d.ts +0 -5
- package/dist/stories/__internal__/components/VebEstimationBarChart/hooks/useDrawBars.d.ts +0 -4
- package/dist/stories/__internal__/components/VebEstimationBarChart/hooks/useRenderLabel/index.d.ts +0 -9
- package/dist/stories/__internal__/components/VebEstimationBarChart/hooks/useRenderLabel/styled.d.ts +0 -1
- package/dist/stories/__internal__/components/VebEstimationBarChart/hooks/useRenderTooltip/index.d.ts +0 -8
- package/dist/stories/__internal__/components/VebEstimationBarChart/hooks/useRenderTooltip/styled.d.ts +0 -13
- package/dist/stories/__internal__/components/VebEstimationBarChart/index.d.ts +0 -3
- package/dist/stories/__internal__/components/VebEstimationBarChart/styled.d.ts +0 -2
- package/dist/stories/__internal__/components/VebFilterBarChart/index.d.ts +0 -2
- package/dist/stories/__internal__/components/VebGroupHorizontalBarChart/hooks/useRenderSum/index.d.ts +0 -3
- package/dist/stories/__internal__/components/VebGroupHorizontalBarChart/hooks/useRenderSum/styled.d.ts +0 -1
- package/dist/stories/__internal__/components/VebGroupHorizontalBarChart/hooks/useRenderTooltip/index.d.ts +0 -1
- package/dist/stories/__internal__/components/VebGroupHorizontalBarChart/hooks/useRenderTooltip/styled.d.ts +0 -5
- package/dist/stories/__internal__/components/VebGroupHorizontalBarChart/index.d.ts +0 -3
- package/dist/stories/__internal__/components/VebGroupHorizontalBarChart/styled.d.ts +0 -5
- package/dist/stories/__internal__/components/VebGroupHorizontalBarChart/types.d.ts +0 -11
- package/dist/stories/__internal__/curves.d.ts +0 -8
- package/dist/stories/__internal__/data/msp.d.ts +0 -14
- package/dist/stories/__internal__/data/mspDashboard.d.ts +0 -1
- package/dist/stories/__internal__/data/mspPromSupply.d.ts +0 -11
- package/dist/stories/__internal__/data/population.d.ts +0 -4
- package/dist/stories/__internal__/data/veb.d.ts +0 -31
- package/dist/stories/__internal__/helpers/Path.d.ts +0 -10
- package/dist/stories/__internal__/helpers/Vector.d.ts +0 -9
- package/dist/stories/__internal__/helpers/animation.d.ts +0 -15
- package/dist/stories/__internal__/helpers/hexToRGB.d.ts +0 -1
- package/dist/stories/__internal__/helpers/random.d.ts +0 -1
- package/dist/stories/__internal__/helpers/randomData.d.ts +0 -14
- package/dist/stories/__internal__/helpers/randomHorizontalBarData.d.ts +0 -5
- package/dist/stories/__internal__/helpers/randomIntervalData.d.ts +0 -11
- package/dist/stories/__internal__/helpers/randomLineData.d.ts +0 -8
- package/dist/stories/__internal__/helpers/randomText.d.ts +0 -1
- package/dist/stories/__internal__/helpers/roundedRect.d.ts +0 -10
- package/dist/stories/__internal__/helpers/shuffleArray.d.ts +0 -1
- package/dist/stories/__internal__/hooks/useBarData.d.ts +0 -10
- package/dist/stories/__internal__/hooks/useLegend.d.ts +0 -1
- package/dist/stories/__internal__/hooks/useMinMaxValue.d.ts +0 -4
- package/dist/stories/__internal__/interpolates.d.ts +0 -23
- package/dist/storybook-static/1.05dfd83c.iframe.bundle.d.ts +0 -0
- package/dist/storybook-static/189.8c077122866758d3cf20.manager.bundle.d.ts +0 -0
- package/dist/storybook-static/190.58050c9beb344d4cefd9.manager.bundle.d.ts +0 -2
- package/dist/storybook-static/191.b202c06c72968435b80b.manager.bundle.d.ts +0 -0
- package/dist/storybook-static/192.83987c5b15f8a80893c5.manager.bundle.d.ts +0 -0
- package/dist/storybook-static/193.8a12aa992b466e778018.manager.bundle.d.ts +0 -2
- package/dist/storybook-static/2.0231c7b6.iframe.bundle.d.ts +0 -0
- package/dist/storybook-static/6.6185fd0d.iframe.bundle.d.ts +0 -0
- package/dist/storybook-static/7.0ede09e9.iframe.bundle.d.ts +0 -0
- package/dist/storybook-static/8.6f0230ef.iframe.bundle.d.ts +0 -2
- package/dist/storybook-static/main.6b7543c14993fcfcab71.manager.bundle.d.ts +0 -2
- package/dist/storybook-static/main.724b5942.iframe.bundle.d.ts +0 -9
- package/dist/storybook-static/runtime~main.92273705.iframe.bundle.d.ts +0 -1
- package/dist/storybook-static/runtime~main.c89e55a461c11ef29193.manager.bundle.d.ts +0 -1
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
export
|
|
4
|
-
svg: d3.Selection<SVGSVGElement, unknown, null, undefined>;
|
|
5
|
-
yScale: d3.ScaleLinear<number, number>;
|
|
6
|
-
xScale: d3.ScaleLinear<number, number>;
|
|
7
|
-
lastIndex: number;
|
|
8
|
-
yTicksCount: number;
|
|
9
|
-
} & Pick<LineChartProps, 'drawGridX' | 'drawGridY'>;
|
|
1
|
+
import { LineChartProps } from '../types';
|
|
2
|
+
import * as d3 from 'd3';
|
|
3
|
+
export type DrawGridProps = {
|
|
4
|
+
svg: d3.Selection<SVGSVGElement, unknown, null, undefined>;
|
|
5
|
+
yScale: d3.ScaleLinear<number, number>;
|
|
6
|
+
xScale: d3.ScaleLinear<number, number>;
|
|
7
|
+
lastIndex: number;
|
|
8
|
+
yTicksCount: number;
|
|
9
|
+
} & Pick<LineChartProps, 'drawGridX' | 'drawGridY'>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { DrawLabelProps } from './types';
|
|
2
|
-
export declare const labelClassName = "d3-chart-label";
|
|
3
|
-
export declare const drawLabel: ({ node, data, yScale, xScale, formatLabel, eachLabel, }: DrawLabelProps) => void;
|
|
1
|
+
import { DrawLabelProps } from './types';
|
|
2
|
+
export declare const labelClassName = "d3-chart-label";
|
|
3
|
+
export declare const drawLabel: ({ node, data, yScale, xScale, formatLabel, eachLabel, }: DrawLabelProps) => void;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const LabelContainer: import(
|
|
2
|
-
export declare const Label: import(
|
|
1
|
+
export declare const LabelContainer: import('styled-components').StyledComponent<"div", any, {}, never>;
|
|
2
|
+
export declare const Label: import('styled-components').StyledComponent<"div", any, {}, never>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
export
|
|
4
|
-
node: HTMLElement;
|
|
5
|
-
yScale: d3.ScaleLinear<number, number>;
|
|
6
|
-
xScale: d3.ScaleLinear<number, number>;
|
|
7
|
-
} & Pick<LineChartProps, 'data' | 'formatLabel' | 'eachLabel'>;
|
|
1
|
+
import { LineChartProps } from '../types';
|
|
2
|
+
import * as d3 from 'd3';
|
|
3
|
+
export type DrawLabelProps = {
|
|
4
|
+
node: HTMLElement;
|
|
5
|
+
yScale: d3.ScaleLinear<number, number>;
|
|
6
|
+
xScale: d3.ScaleLinear<number, number>;
|
|
7
|
+
} & Pick<LineChartProps, 'data' | 'formatLabel' | 'eachLabel'>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { DrawTooltipProps } from './types';
|
|
2
|
-
export declare const drawTooltip: ({ svg, node, data: argData, xScale, yScale, dynamicCircleRadius, formatDynamicTooltip, renderTooltip, stackedTooltipIndex, stackedTooltip, tooltipLineTop, tooltipRoot, tooltipClassName, dotSnapping, lastIndex, }: DrawTooltipProps) => void;
|
|
1
|
+
import { DrawTooltipProps } from './types';
|
|
2
|
+
export declare const drawTooltip: ({ svg, node, data: argData, xScale, yScale, dynamicCircleRadius, formatDynamicTooltip, renderTooltip, stackedTooltipIndex, stackedTooltip, tooltipLineTop, tooltipRoot, tooltipClassName, dotSnapping, lastIndex, }: DrawTooltipProps) => void;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
export
|
|
4
|
-
svg: d3.Selection<SVGSVGElement, unknown, null, undefined>;
|
|
5
|
-
node: HTMLElement;
|
|
6
|
-
yScale: d3.ScaleLinear<number, number>;
|
|
7
|
-
xScale: d3.ScaleLinear<number, number>;
|
|
8
|
-
lastIndex: number;
|
|
9
|
-
} & Pick<LineChartProps, 'data' | 'dynamicCircleRadius' | 'formatDynamicTooltip' | 'renderTooltip' | 'stackedTooltipIndex' | 'stackedTooltip' | 'tooltipLineTop' | 'tooltipRoot' | 'tooltipClassName' | 'dotSnapping'>;
|
|
1
|
+
import { LineChartProps } from '../types';
|
|
2
|
+
import * as d3 from 'd3';
|
|
3
|
+
export type DrawTooltipProps = {
|
|
4
|
+
svg: d3.Selection<SVGSVGElement, unknown, null, undefined>;
|
|
5
|
+
node: HTMLElement;
|
|
6
|
+
yScale: d3.ScaleLinear<number, number>;
|
|
7
|
+
xScale: d3.ScaleLinear<number, number>;
|
|
8
|
+
lastIndex: number;
|
|
9
|
+
} & Pick<LineChartProps, 'data' | 'dynamicCircleRadius' | 'formatDynamicTooltip' | 'renderTooltip' | 'stackedTooltipIndex' | 'stackedTooltip' | 'tooltipLineTop' | 'tooltipRoot' | 'tooltipClassName' | 'dotSnapping'>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { FC } from
|
|
2
|
-
import { LineChartProps } from
|
|
3
|
-
export declare const LineChart: FC<LineChartProps>;
|
|
1
|
+
import { FC } from 'react';
|
|
2
|
+
import { LineChartProps } from './types';
|
|
3
|
+
export declare const LineChart: FC<LineChartProps>;
|
|
@@ -1,27 +1,27 @@
|
|
|
1
|
-
import { JSXElementConstructor } from
|
|
2
|
-
export declare const lineChartClassNames: {
|
|
3
|
-
lineChartYScaleGlobal: string;
|
|
4
|
-
lineChartYScaleRight: string;
|
|
5
|
-
lineChartXScaleGlobal: string;
|
|
6
|
-
lineChartLinesGlobal: string;
|
|
7
|
-
lineChartLine: string;
|
|
8
|
-
lineChartAreasGlobal: string;
|
|
9
|
-
lineChartArea: string;
|
|
10
|
-
lineChartDotsGlobalContainer: string;
|
|
11
|
-
lineChartDotsGlobal: string;
|
|
12
|
-
lineChartDot: string;
|
|
13
|
-
lineChartGridGlobal: string;
|
|
14
|
-
lineChartGridLineX: string;
|
|
15
|
-
lineChartGridLineY: string;
|
|
16
|
-
lineChartLabelContainer: string;
|
|
17
|
-
lineChartLabelFlex: string;
|
|
18
|
-
lineChartLabel: string;
|
|
19
|
-
lineChartMouseGlobal: string;
|
|
20
|
-
lineChartMouseLine: string;
|
|
21
|
-
lineChartMouseRect: string;
|
|
22
|
-
lineChartMouseCircle: string;
|
|
23
|
-
lineChartMouseLabelContainer: string;
|
|
24
|
-
lineChartMouseLabel: string;
|
|
25
|
-
};
|
|
26
|
-
export declare const SvgWrapper: import(
|
|
27
|
-
export declare const TooltipStyles: JSXElementConstructor<any>;
|
|
1
|
+
import { JSXElementConstructor } from 'react';
|
|
2
|
+
export declare const lineChartClassNames: {
|
|
3
|
+
lineChartYScaleGlobal: string;
|
|
4
|
+
lineChartYScaleRight: string;
|
|
5
|
+
lineChartXScaleGlobal: string;
|
|
6
|
+
lineChartLinesGlobal: string;
|
|
7
|
+
lineChartLine: string;
|
|
8
|
+
lineChartAreasGlobal: string;
|
|
9
|
+
lineChartArea: string;
|
|
10
|
+
lineChartDotsGlobalContainer: string;
|
|
11
|
+
lineChartDotsGlobal: string;
|
|
12
|
+
lineChartDot: string;
|
|
13
|
+
lineChartGridGlobal: string;
|
|
14
|
+
lineChartGridLineX: string;
|
|
15
|
+
lineChartGridLineY: string;
|
|
16
|
+
lineChartLabelContainer: string;
|
|
17
|
+
lineChartLabelFlex: string;
|
|
18
|
+
lineChartLabel: string;
|
|
19
|
+
lineChartMouseGlobal: string;
|
|
20
|
+
lineChartMouseLine: string;
|
|
21
|
+
lineChartMouseRect: string;
|
|
22
|
+
lineChartMouseCircle: string;
|
|
23
|
+
lineChartMouseLabelContainer: string;
|
|
24
|
+
lineChartMouseLabel: string;
|
|
25
|
+
};
|
|
26
|
+
export declare const SvgWrapper: import('styled-components').StyledComponent<"div", any, {}, never>;
|
|
27
|
+
export declare const TooltipStyles: JSXElementConstructor<any>;
|
|
@@ -1,78 +1,78 @@
|
|
|
1
|
-
import { CSSProperties, PropsWithChildren, ReactNode } from
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
export
|
|
5
|
-
|
|
6
|
-
export interface LineChartProps extends PropsWithChildren {
|
|
7
|
-
className?: string;
|
|
8
|
-
style?: CSSProperties;
|
|
9
|
-
data: LineChartData[];
|
|
10
|
-
width?: number;
|
|
11
|
-
height?: number;
|
|
12
|
-
margin?: Margin;
|
|
13
|
-
labels?: (string | number)[];
|
|
14
|
-
customYAxis?: LineChartCustomAxis;
|
|
15
|
-
customXAxis?: LineChartCustomAxis;
|
|
16
|
-
customYAxisSelection?: LineChartCustomAxisSelection;
|
|
17
|
-
customXAxisSelection?: LineChartCustomAxisSelection;
|
|
18
|
-
yAxisPadding?: number;
|
|
19
|
-
xAxisPadding?: number;
|
|
20
|
-
curve?: d3.CurveFactory;
|
|
21
|
-
areaCurve?: d3.CurveFactory;
|
|
22
|
-
drawGridY?: boolean;
|
|
23
|
-
drawGridX?: boolean;
|
|
24
|
-
min?: number;
|
|
25
|
-
max?: number;
|
|
26
|
-
stacked?: boolean;
|
|
27
|
-
formatLabel?: (value: number, index: number, label: HTMLDivElement[]) => string | number;
|
|
28
|
-
withLabels?: boolean;
|
|
29
|
-
eachLabel?: (value: number, index: number, divs: HTMLDivElement[]) => void;
|
|
30
|
-
dynamicTooltipEnable?: boolean;
|
|
31
|
-
dynamicCircleRadius?: number;
|
|
32
|
-
formatDynamicTooltip?: (invertValue: number, value: number | null) => number | string;
|
|
33
|
-
renderTooltip?: (datas: LineChartDatas[], properties: {
|
|
34
|
-
indexX: number;
|
|
35
|
-
indexY: number;
|
|
36
|
-
svg: d3.Selection<SVGSVGElement, unknown, null, undefined>;
|
|
37
|
-
event: MouseEvent | TouchEvent;
|
|
38
|
-
}) => ReactNode;
|
|
39
|
-
stackedTooltip?: boolean;
|
|
40
|
-
stackedTooltipIndex?: number | undefined;
|
|
41
|
-
tooltipLineTop?: boolean;
|
|
42
|
-
customize?: (args: {
|
|
43
|
-
svg: d3.Selection<SVGSVGElement, unknown, null, undefined>;
|
|
44
|
-
yScale: d3.ScaleLinear<number, number>;
|
|
45
|
-
xScale: d3.ScaleLinear<number, number>;
|
|
46
|
-
}) => void;
|
|
47
|
-
customYScale?: (yScale: (value: number) => number) => void;
|
|
48
|
-
customLine?: (line: d3.Line<[number, number]>) => void;
|
|
49
|
-
tooltipRoot?: Element;
|
|
50
|
-
tooltipClassName?: string;
|
|
51
|
-
xScaleItemWidth?: number;
|
|
52
|
-
dotSnapping?: boolean;
|
|
53
|
-
rightAxis?: number[];
|
|
54
|
-
}
|
|
55
|
-
export
|
|
56
|
-
radius?: number;
|
|
57
|
-
style?: string;
|
|
58
|
-
filter?: (value: LineChartData, index: number, circles: (d3.BaseType | SVGCircleElement)[] | ArrayLike<d3.BaseType | SVGCircleElement>) => boolean;
|
|
59
|
-
};
|
|
60
|
-
export
|
|
61
|
-
name?: string;
|
|
62
|
-
values: (number | null)[];
|
|
63
|
-
minAreaValues?: (number | null)[];
|
|
64
|
-
stroke?: string;
|
|
65
|
-
fill?: string;
|
|
66
|
-
tooltipOff?: boolean;
|
|
67
|
-
style?: string;
|
|
68
|
-
dot?: LineChartDot;
|
|
69
|
-
dynamicDotStyle?: string;
|
|
70
|
-
dynamicDotOff?: boolean;
|
|
71
|
-
areaStyle?: string;
|
|
72
|
-
tooltipOrder?: number;
|
|
73
|
-
};
|
|
74
|
-
export
|
|
75
|
-
value: number | null;
|
|
76
|
-
invertValue: number;
|
|
77
|
-
};
|
|
78
|
-
export {};
|
|
1
|
+
import { CSSProperties, PropsWithChildren, ReactNode } from 'react';
|
|
2
|
+
import { Margin } from '../../common/types/margin';
|
|
3
|
+
import * as d3 from 'd3';
|
|
4
|
+
export type LineChartCustomAxis = (axis: d3.Axis<d3.NumberValue>) => void;
|
|
5
|
+
type LineChartCustomAxisSelection = (selection: d3.Selection<SVGGElement, unknown, null, undefined>) => void;
|
|
6
|
+
export interface LineChartProps extends PropsWithChildren {
|
|
7
|
+
className?: string;
|
|
8
|
+
style?: CSSProperties;
|
|
9
|
+
data: LineChartData[];
|
|
10
|
+
width?: number;
|
|
11
|
+
height?: number;
|
|
12
|
+
margin?: Margin;
|
|
13
|
+
labels?: (string | number)[];
|
|
14
|
+
customYAxis?: LineChartCustomAxis;
|
|
15
|
+
customXAxis?: LineChartCustomAxis;
|
|
16
|
+
customYAxisSelection?: LineChartCustomAxisSelection;
|
|
17
|
+
customXAxisSelection?: LineChartCustomAxisSelection;
|
|
18
|
+
yAxisPadding?: number;
|
|
19
|
+
xAxisPadding?: number;
|
|
20
|
+
curve?: d3.CurveFactory;
|
|
21
|
+
areaCurve?: d3.CurveFactory;
|
|
22
|
+
drawGridY?: boolean;
|
|
23
|
+
drawGridX?: boolean;
|
|
24
|
+
min?: number;
|
|
25
|
+
max?: number;
|
|
26
|
+
stacked?: boolean;
|
|
27
|
+
formatLabel?: (value: number, index: number, label: HTMLDivElement[]) => string | number;
|
|
28
|
+
withLabels?: boolean;
|
|
29
|
+
eachLabel?: (value: number, index: number, divs: HTMLDivElement[]) => void;
|
|
30
|
+
dynamicTooltipEnable?: boolean;
|
|
31
|
+
dynamicCircleRadius?: number;
|
|
32
|
+
formatDynamicTooltip?: (invertValue: number, value: number | null) => number | string;
|
|
33
|
+
renderTooltip?: (datas: LineChartDatas[], properties: {
|
|
34
|
+
indexX: number;
|
|
35
|
+
indexY: number;
|
|
36
|
+
svg: d3.Selection<SVGSVGElement, unknown, null, undefined>;
|
|
37
|
+
event: MouseEvent | TouchEvent;
|
|
38
|
+
}) => ReactNode;
|
|
39
|
+
stackedTooltip?: boolean;
|
|
40
|
+
stackedTooltipIndex?: number | undefined;
|
|
41
|
+
tooltipLineTop?: boolean;
|
|
42
|
+
customize?: (args: {
|
|
43
|
+
svg: d3.Selection<SVGSVGElement, unknown, null, undefined>;
|
|
44
|
+
yScale: d3.ScaleLinear<number, number>;
|
|
45
|
+
xScale: d3.ScaleLinear<number, number>;
|
|
46
|
+
}) => void;
|
|
47
|
+
customYScale?: (yScale: (value: number) => number) => void;
|
|
48
|
+
customLine?: (line: d3.Line<[number, number]>) => void;
|
|
49
|
+
tooltipRoot?: Element;
|
|
50
|
+
tooltipClassName?: string;
|
|
51
|
+
xScaleItemWidth?: number;
|
|
52
|
+
dotSnapping?: boolean;
|
|
53
|
+
rightAxis?: number[];
|
|
54
|
+
}
|
|
55
|
+
export type LineChartDot = {
|
|
56
|
+
radius?: number;
|
|
57
|
+
style?: string;
|
|
58
|
+
filter?: (value: LineChartData, index: number, circles: (d3.BaseType | SVGCircleElement)[] | ArrayLike<d3.BaseType | SVGCircleElement>) => boolean;
|
|
59
|
+
};
|
|
60
|
+
export type LineChartData = {
|
|
61
|
+
name?: string;
|
|
62
|
+
values: (number | null)[];
|
|
63
|
+
minAreaValues?: (number | null)[];
|
|
64
|
+
stroke?: string;
|
|
65
|
+
fill?: string;
|
|
66
|
+
tooltipOff?: boolean;
|
|
67
|
+
style?: string;
|
|
68
|
+
dot?: LineChartDot;
|
|
69
|
+
dynamicDotStyle?: string;
|
|
70
|
+
dynamicDotOff?: boolean;
|
|
71
|
+
areaStyle?: string;
|
|
72
|
+
tooltipOrder?: number;
|
|
73
|
+
};
|
|
74
|
+
export type LineChartDatas = Omit<LineChartData, 'values'> & {
|
|
75
|
+
value: number | null;
|
|
76
|
+
invertValue: number;
|
|
77
|
+
};
|
|
78
|
+
export {};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { PieChartProps } from './types';
|
|
2
|
-
export declare const draw: (node: HTMLElement | null, props: PieChartProps) => void;
|
|
1
|
+
import { PieChartProps } from './types';
|
|
2
|
+
export declare const draw: (node: HTMLElement | null, props: PieChartProps) => void;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { PieChartDatum } from '../types';
|
|
2
|
-
export declare const getMidFactor: (d: PieChartDatum) => 1 | -1;
|
|
3
|
-
export declare const getAlign: (d: PieChartDatum) =>
|
|
1
|
+
import { PieChartDatum } from '../types';
|
|
2
|
+
export declare const getMidFactor: (d: PieChartDatum) => 1 | -1;
|
|
3
|
+
export declare const getAlign: (d: PieChartDatum) => "start" | "end";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { DrawRadialLabels } from './types';
|
|
2
|
-
export declare const drawRadialLabels: ({ arc, enableRadialLabels, global, node, radius, dataReady, radialLabelsLinkHorizontalLength, formatRadialLabel, radialLabelsTextXOffset, translateX, translateY, radialLabelYOffset, radialAngleXOffset, }: DrawRadialLabels) => void;
|
|
1
|
+
import { DrawRadialLabels } from './types';
|
|
2
|
+
export declare const drawRadialLabels: ({ arc, enableRadialLabels, global, node, radius, dataReady, radialLabelsLinkHorizontalLength, formatRadialLabel, radialLabelsTextXOffset, translateX, translateY, radialLabelYOffset, radialAngleXOffset, }: DrawRadialLabels) => void;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
export
|
|
4
|
-
global: any;
|
|
5
|
-
arc: d3.Arc<any, d3.DefaultArcObject>;
|
|
6
|
-
node: HTMLElement;
|
|
7
|
-
radius: number;
|
|
8
|
-
dataReady: PieChartDatum[];
|
|
9
|
-
translateX: number;
|
|
10
|
-
translateY: number;
|
|
11
|
-
} & Pick<PieChartProps, 'enableRadialLabels' | 'radialLabelsLinkHorizontalLength' | 'radialLabelsTextXOffset' | 'formatRadialLabel' | 'radialLabelYOffset' | 'radialAngleXOffset'>;
|
|
1
|
+
import { PieChartProps, PieChartDatum } from '../types';
|
|
2
|
+
import * as d3 from 'd3';
|
|
3
|
+
export type DrawRadialLabels = {
|
|
4
|
+
global: any;
|
|
5
|
+
arc: d3.Arc<any, d3.DefaultArcObject>;
|
|
6
|
+
node: HTMLElement;
|
|
7
|
+
radius: number;
|
|
8
|
+
dataReady: PieChartDatum[];
|
|
9
|
+
translateX: number;
|
|
10
|
+
translateY: number;
|
|
11
|
+
} & Pick<PieChartProps, 'enableRadialLabels' | 'radialLabelsLinkHorizontalLength' | 'radialLabelsTextXOffset' | 'formatRadialLabel' | 'radialLabelYOffset' | 'radialAngleXOffset'>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { DrawTooltipProps } from './types';
|
|
2
|
-
export declare const drawTooltip: ({ fullChartTooltip, global, tooltipRoot, data, tooltipClassName, tooltipBind, renderTooltip, arc, allSlices, tooltipStyle, width, height, radius, }: DrawTooltipProps) => void;
|
|
1
|
+
import { DrawTooltipProps } from './types';
|
|
2
|
+
export declare const drawTooltip: ({ fullChartTooltip, global, tooltipRoot, data, tooltipClassName, tooltipBind, renderTooltip, arc, allSlices, tooltipStyle, width, height, radius, }: DrawTooltipProps) => void;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
export
|
|
4
|
-
global: d3.Selection<SVGGElement, unknown, null, undefined>;
|
|
5
|
-
allSlices: d3.Selection<SVGPathElement, PieChartDatum, SVGGElement, unknown>;
|
|
6
|
-
arc: d3.Arc<any, d3.DefaultArcObject>;
|
|
7
|
-
radius: number;
|
|
8
|
-
};
|
|
1
|
+
import { PieChartProps, PieChartDatum } from '../types';
|
|
2
|
+
import * as d3 from 'd3';
|
|
3
|
+
export type DrawTooltipProps = Pick<PieChartProps, 'fullChartTooltip' | 'tooltipRoot' | 'data' | 'tooltipClassName' | 'tooltipBind' | 'renderTooltip' | 'tooltipStyle' | 'width' | 'height'> & {
|
|
4
|
+
global: d3.Selection<SVGGElement, unknown, null, undefined>;
|
|
5
|
+
allSlices: d3.Selection<SVGPathElement, PieChartDatum, SVGGElement, unknown>;
|
|
6
|
+
arc: d3.Arc<any, d3.DefaultArcObject>;
|
|
7
|
+
radius: number;
|
|
8
|
+
};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { FC } from
|
|
2
|
-
import { PieChartProps } from
|
|
3
|
-
export declare const PieChart: FC<PieChartProps>;
|
|
1
|
+
import { FC } from 'react';
|
|
2
|
+
import { PieChartProps } from './types';
|
|
3
|
+
export declare const PieChart: FC<PieChartProps>;
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
export declare const pieChartclassNames: {
|
|
2
|
-
pieGlobal: string;
|
|
3
|
-
pieSlice: string;
|
|
4
|
-
pieSliceLabel: string;
|
|
5
|
-
pieSliceLabelValue: string;
|
|
6
|
-
pieSliceLabelName: string;
|
|
7
|
-
pieRadialLabel: string;
|
|
8
|
-
pieRadialLink: string;
|
|
9
|
-
pieTooltipContainer: string;
|
|
10
|
-
pieTooltipFlex: string;
|
|
11
|
-
pieTooltip: string;
|
|
12
|
-
pieTooltipItem: string;
|
|
13
|
-
pieTooltipName: string;
|
|
14
|
-
pieTooltipValue: string;
|
|
15
|
-
pieTooltipColorBox: string;
|
|
16
|
-
pieFullChartTooltipCircle: string;
|
|
17
|
-
};
|
|
18
|
-
export declare const SvgWrapper: import(
|
|
1
|
+
export declare const pieChartclassNames: {
|
|
2
|
+
pieGlobal: string;
|
|
3
|
+
pieSlice: string;
|
|
4
|
+
pieSliceLabel: string;
|
|
5
|
+
pieSliceLabelValue: string;
|
|
6
|
+
pieSliceLabelName: string;
|
|
7
|
+
pieRadialLabel: string;
|
|
8
|
+
pieRadialLink: string;
|
|
9
|
+
pieTooltipContainer: string;
|
|
10
|
+
pieTooltipFlex: string;
|
|
11
|
+
pieTooltip: string;
|
|
12
|
+
pieTooltipItem: string;
|
|
13
|
+
pieTooltipName: string;
|
|
14
|
+
pieTooltipValue: string;
|
|
15
|
+
pieTooltipColorBox: string;
|
|
16
|
+
pieFullChartTooltipCircle: string;
|
|
17
|
+
};
|
|
18
|
+
export declare const SvgWrapper: import('styled-components').StyledComponent<"div", any, {}, never>;
|
|
@@ -1,54 +1,54 @@
|
|
|
1
|
-
import { ReactElement, ReactNode, CSSProperties, PropsWithChildren } from
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
export interface PieChartProps extends PropsWithChildren {
|
|
5
|
-
data: PieChartData[];
|
|
6
|
-
className?: string;
|
|
7
|
-
style?: CSSProperties;
|
|
8
|
-
width?: number;
|
|
9
|
-
height?: number;
|
|
10
|
-
outerRadius?: number;
|
|
11
|
-
startAngle?: number;
|
|
12
|
-
endAngle?: number;
|
|
13
|
-
padAngle?: number;
|
|
14
|
-
cornerRadius?: number;
|
|
15
|
-
borderWidth?: number;
|
|
16
|
-
borderColor?: string;
|
|
17
|
-
margin?: Margin;
|
|
18
|
-
onClick?: (data: PieChartData) => void;
|
|
19
|
-
enableSlicesLabels?: boolean;
|
|
20
|
-
formatSliceLabel?: PieChartFormatLabel;
|
|
21
|
-
formatSliceTitle?: PieChartFormatLabel;
|
|
22
|
-
formatSliceLabelName?: PieChartFormatLabel;
|
|
23
|
-
slicesLabelsSkipAngle?: number;
|
|
24
|
-
enableSlicesLabelsName?: boolean;
|
|
25
|
-
backgroundColor?: string;
|
|
26
|
-
enableRadialLabels?: boolean;
|
|
27
|
-
radialLabelsLinkHorizontalLength?: number;
|
|
28
|
-
radialLabelsTextXOffset?: number;
|
|
29
|
-
formatRadialLabel?: PieChartFormatRadialLabel;
|
|
30
|
-
radialLabelYOffset?: number;
|
|
31
|
-
svgElements?: ReactElement;
|
|
32
|
-
radialAngleXOffset?: number;
|
|
33
|
-
withTooltip?: boolean;
|
|
34
|
-
fullChartTooltip?: boolean;
|
|
35
|
-
tooltipRoot?: Element;
|
|
36
|
-
tooltipBind?: boolean;
|
|
37
|
-
tooltipClassName?: string;
|
|
38
|
-
renderTooltip?: (data: PieChartDatum[] | PieChartData[]) => ReactNode;
|
|
39
|
-
tooltipStyle?: CSSProperties;
|
|
40
|
-
}
|
|
41
|
-
export
|
|
42
|
-
id?: number | string;
|
|
43
|
-
cornerRadius?: number;
|
|
44
|
-
name?: ReactNode;
|
|
45
|
-
color?: string;
|
|
46
|
-
value: number;
|
|
47
|
-
};
|
|
48
|
-
export
|
|
49
|
-
data: PieChartData;
|
|
50
|
-
index: number;
|
|
51
|
-
value: number;
|
|
52
|
-
} & d3.DefaultArcObject;
|
|
53
|
-
export
|
|
54
|
-
export
|
|
1
|
+
import { ReactElement, ReactNode, CSSProperties, PropsWithChildren } from 'react';
|
|
2
|
+
import { Margin } from '../../common/types/margin';
|
|
3
|
+
import * as d3 from "d3";
|
|
4
|
+
export interface PieChartProps extends PropsWithChildren {
|
|
5
|
+
data: PieChartData[];
|
|
6
|
+
className?: string;
|
|
7
|
+
style?: CSSProperties;
|
|
8
|
+
width?: number;
|
|
9
|
+
height?: number;
|
|
10
|
+
outerRadius?: number;
|
|
11
|
+
startAngle?: number;
|
|
12
|
+
endAngle?: number;
|
|
13
|
+
padAngle?: number;
|
|
14
|
+
cornerRadius?: number;
|
|
15
|
+
borderWidth?: number;
|
|
16
|
+
borderColor?: string;
|
|
17
|
+
margin?: Margin;
|
|
18
|
+
onClick?: (data: PieChartData) => void;
|
|
19
|
+
enableSlicesLabels?: boolean;
|
|
20
|
+
formatSliceLabel?: PieChartFormatLabel;
|
|
21
|
+
formatSliceTitle?: PieChartFormatLabel;
|
|
22
|
+
formatSliceLabelName?: PieChartFormatLabel;
|
|
23
|
+
slicesLabelsSkipAngle?: number;
|
|
24
|
+
enableSlicesLabelsName?: boolean;
|
|
25
|
+
backgroundColor?: string;
|
|
26
|
+
enableRadialLabels?: boolean;
|
|
27
|
+
radialLabelsLinkHorizontalLength?: number;
|
|
28
|
+
radialLabelsTextXOffset?: number;
|
|
29
|
+
formatRadialLabel?: PieChartFormatRadialLabel;
|
|
30
|
+
radialLabelYOffset?: number;
|
|
31
|
+
svgElements?: ReactElement;
|
|
32
|
+
radialAngleXOffset?: number;
|
|
33
|
+
withTooltip?: boolean;
|
|
34
|
+
fullChartTooltip?: boolean;
|
|
35
|
+
tooltipRoot?: Element;
|
|
36
|
+
tooltipBind?: boolean;
|
|
37
|
+
tooltipClassName?: string;
|
|
38
|
+
renderTooltip?: (data: PieChartDatum[] | PieChartData[]) => ReactNode;
|
|
39
|
+
tooltipStyle?: CSSProperties;
|
|
40
|
+
}
|
|
41
|
+
export type PieChartData = {
|
|
42
|
+
id?: number | string;
|
|
43
|
+
cornerRadius?: number;
|
|
44
|
+
name?: ReactNode;
|
|
45
|
+
color?: string;
|
|
46
|
+
value: number;
|
|
47
|
+
};
|
|
48
|
+
export type PieChartDatum = {
|
|
49
|
+
data: PieChartData;
|
|
50
|
+
index: number;
|
|
51
|
+
value: number;
|
|
52
|
+
} & d3.DefaultArcObject;
|
|
53
|
+
export type PieChartFormatLabel = (datum: PieChartDatum) => string;
|
|
54
|
+
export type PieChartFormatRadialLabel = (datum: PieChartDatum) => ReactNode;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { RadarChartProps } from './types';
|
|
2
|
-
export declare const draw: (node: HTMLElement | null, props: RadarChartProps) => void;
|
|
1
|
+
import { RadarChartProps } from './types';
|
|
2
|
+
export declare const draw: (node: HTMLElement | null, props: RadarChartProps) => void;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { DrawRadialLabels } from './types';
|
|
2
|
-
export declare const drawRadialLabels: ({ node, dataLength, radiusScale, maxValue, angleSlice, radius, xOffset, yOffset, translateX, translateY, renderLabel, selectLabel, }: DrawRadialLabels) => void;
|
|
1
|
+
import { DrawRadialLabels } from './types';
|
|
2
|
+
export declare const drawRadialLabels: ({ node, dataLength, radiusScale, maxValue, angleSlice, radius, xOffset, yOffset, translateX, translateY, renderLabel, selectLabel, }: DrawRadialLabels) => void;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { LabelContainerProps } from './types';
|
|
2
|
-
export declare const LabelContainer: import(
|
|
1
|
+
import { LabelContainerProps } from './types';
|
|
2
|
+
export declare const LabelContainer: import('styled-components').StyledComponent<"div", any, LabelContainerProps, never>;
|
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
export
|
|
6
|
-
node: HTMLElement;
|
|
7
|
-
dataLength: number;
|
|
8
|
-
radiusScale: any;
|
|
9
|
-
maxValue: number;
|
|
10
|
-
angleSlice: number;
|
|
11
|
-
radius: number;
|
|
12
|
-
renderLabel: RenderLabel | ReactNode;
|
|
13
|
-
xOffset?: number;
|
|
14
|
-
yOffset?: number;
|
|
15
|
-
translateX?: number;
|
|
16
|
-
translateY?: number;
|
|
17
|
-
selectLabel: (label: d3.Selection<HTMLDivElement, unknown, null, undefined>, anchor: RadarChartRenderLabelAnchor, index: number) => void;
|
|
18
|
-
};
|
|
19
|
-
export
|
|
20
|
-
anchor: RadarChartRenderLabelAnchor;
|
|
21
|
-
translateX: number;
|
|
22
|
-
translateY: number;
|
|
23
|
-
index: number;
|
|
24
|
-
};
|
|
25
|
-
export {};
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { RadarChartRenderLabelAnchor } from '../types';
|
|
3
|
+
import * as d3 from 'd3';
|
|
4
|
+
type RenderLabel = (anchor: RadarChartRenderLabelAnchor, index: number) => ReactNode;
|
|
5
|
+
export type DrawRadialLabels = {
|
|
6
|
+
node: HTMLElement;
|
|
7
|
+
dataLength: number;
|
|
8
|
+
radiusScale: any;
|
|
9
|
+
maxValue: number;
|
|
10
|
+
angleSlice: number;
|
|
11
|
+
radius: number;
|
|
12
|
+
renderLabel: RenderLabel | ReactNode;
|
|
13
|
+
xOffset?: number;
|
|
14
|
+
yOffset?: number;
|
|
15
|
+
translateX?: number;
|
|
16
|
+
translateY?: number;
|
|
17
|
+
selectLabel: (label: d3.Selection<HTMLDivElement, unknown, null, undefined>, anchor: RadarChartRenderLabelAnchor, index: number) => void;
|
|
18
|
+
};
|
|
19
|
+
export type LabelContainerProps = {
|
|
20
|
+
anchor: RadarChartRenderLabelAnchor;
|
|
21
|
+
translateX: number;
|
|
22
|
+
translateY: number;
|
|
23
|
+
index: number;
|
|
24
|
+
};
|
|
25
|
+
export {};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const getTextAnchor: (index: number, length: number) =>
|
|
2
|
-
export declare const getMaxWidth: (elements: SVGElement[]) => number;
|
|
1
|
+
export declare const getTextAnchor: (index: number, length: number) => "start" | "middle" | "end";
|
|
2
|
+
export declare const getMaxWidth: (elements: SVGElement[]) => number;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { RadarChartProps } from './types';
|
|
3
|
-
export declare const RadarChart:
|
|
1
|
+
import { FC } from 'react';
|
|
2
|
+
import { RadarChartProps } from './types';
|
|
3
|
+
export declare const RadarChart: FC<RadarChartProps>;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
export declare const radarChartclassNames: {
|
|
2
|
-
radar: string;
|
|
3
|
-
radarAxis: string;
|
|
4
|
-
radarAxisTextGlobal: string;
|
|
5
|
-
radarAxisText: string;
|
|
6
|
-
radarPolygon: string;
|
|
7
|
-
radarLabel: string;
|
|
8
|
-
radarLabelName: string;
|
|
9
|
-
radarLabelBadge: string;
|
|
10
|
-
radarLabelBadgePrefix: string;
|
|
11
|
-
radarCircle: string;
|
|
12
|
-
};
|
|
13
|
-
export declare const SvgWrapper: import(
|
|
1
|
+
export declare const radarChartclassNames: {
|
|
2
|
+
radar: string;
|
|
3
|
+
radarAxis: string;
|
|
4
|
+
radarAxisTextGlobal: string;
|
|
5
|
+
radarAxisText: string;
|
|
6
|
+
radarPolygon: string;
|
|
7
|
+
radarLabel: string;
|
|
8
|
+
radarLabelName: string;
|
|
9
|
+
radarLabelBadge: string;
|
|
10
|
+
radarLabelBadgePrefix: string;
|
|
11
|
+
radarCircle: string;
|
|
12
|
+
};
|
|
13
|
+
export declare const SvgWrapper: import('styled-components').StyledComponent<"div", any, {}, never>;
|