@visactor/react-vchart 1.11.0-alpha.0 → 1.11.0-alpha.1
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/cjs/charts/AreaChart.d.ts +1 -1
- package/cjs/charts/AreaChart.js +2 -2
- package/cjs/charts/AreaChart.js.map +1 -1
- package/cjs/charts/Bar3dChart.d.ts +10 -0
- package/cjs/charts/Bar3dChart.js +13 -0
- package/cjs/charts/Bar3dChart.js.map +1 -0
- package/cjs/charts/BarChart.d.ts +1 -1
- package/cjs/charts/BarChart.js +1 -1
- package/cjs/charts/BarChart.js.map +1 -1
- package/cjs/charts/BaseChart.d.ts +1 -1
- package/cjs/charts/BaseChart.js +3 -2
- package/cjs/charts/BaseChart.js.map +1 -1
- package/cjs/charts/BoxPlotChart.d.ts +1 -1
- package/cjs/charts/BoxPlotChart.js +1 -2
- package/cjs/charts/BoxPlotChart.js.map +1 -1
- package/cjs/charts/CirclePackingChart.d.ts +1 -1
- package/cjs/charts/CirclePackingChart.js +0 -1
- package/cjs/charts/CirclePackingChart.js.map +1 -1
- package/cjs/charts/CircularProgressChart.d.ts +1 -1
- package/cjs/charts/CircularProgressChart.js +1 -2
- package/cjs/charts/CircularProgressChart.js.map +1 -1
- package/cjs/charts/CommonChart.d.ts +1 -1
- package/cjs/charts/CommonChart.js +1 -2
- package/cjs/charts/CommonChart.js.map +1 -1
- package/cjs/charts/CorrelationChart.d.ts +1 -1
- package/cjs/charts/CorrelationChart.js +1 -2
- package/cjs/charts/CorrelationChart.js.map +1 -1
- package/cjs/charts/Funnel3dChart.d.ts +10 -0
- package/cjs/charts/Funnel3dChart.js +13 -0
- package/cjs/charts/Funnel3dChart.js.map +1 -0
- package/cjs/charts/FunnelChart.d.ts +1 -1
- package/cjs/charts/FunnelChart.js +2 -3
- package/cjs/charts/FunnelChart.js.map +1 -1
- package/cjs/charts/GaugeChart.d.ts +4 -4
- package/cjs/charts/GaugeChart.js +5 -6
- package/cjs/charts/GaugeChart.js.map +1 -1
- package/cjs/charts/HeatmapChart.d.ts +1 -1
- package/cjs/charts/HeatmapChart.js +2 -3
- package/cjs/charts/HeatmapChart.js.map +1 -1
- package/cjs/charts/Histogram3dChart.d.ts +10 -0
- package/cjs/charts/Histogram3dChart.js +13 -0
- package/cjs/charts/Histogram3dChart.js.map +1 -0
- package/cjs/charts/HistogramChart.d.ts +1 -1
- package/cjs/charts/HistogramChart.js +1 -3
- package/cjs/charts/HistogramChart.js.map +1 -1
- package/cjs/charts/LineChart.d.ts +1 -1
- package/cjs/charts/LineChart.js +2 -3
- package/cjs/charts/LineChart.js.map +1 -1
- package/cjs/charts/LinearProgressChart.d.ts +1 -1
- package/cjs/charts/LinearProgressChart.js +2 -3
- package/cjs/charts/LinearProgressChart.js.map +1 -1
- package/cjs/charts/LiquidChart.d.ts +1 -1
- package/cjs/charts/LiquidChart.js +2 -3
- package/cjs/charts/LiquidChart.js.map +1 -1
- package/cjs/charts/MapChart.d.ts +1 -1
- package/cjs/charts/MapChart.js +2 -3
- package/cjs/charts/MapChart.js.map +1 -1
- package/cjs/charts/Pie3dChart.d.ts +10 -0
- package/cjs/charts/Pie3dChart.js +13 -0
- package/cjs/charts/Pie3dChart.js.map +1 -0
- package/cjs/charts/PieChart.d.ts +1 -1
- package/cjs/charts/PieChart.js +2 -3
- package/cjs/charts/PieChart.js.map +1 -1
- package/cjs/charts/RadarChart.d.ts +1 -1
- package/cjs/charts/RadarChart.js +2 -3
- package/cjs/charts/RadarChart.js.map +1 -1
- package/cjs/charts/RangeColumn3dChart.d.ts +10 -0
- package/cjs/charts/RangeColumn3dChart.js +13 -0
- package/cjs/charts/RangeColumn3dChart.js.map +1 -0
- package/cjs/charts/RangeColumnChart.d.ts +1 -1
- package/cjs/charts/RangeColumnChart.js +2 -3
- package/cjs/charts/RangeColumnChart.js.map +1 -1
- package/cjs/charts/RoseChart.d.ts +1 -1
- package/cjs/charts/RoseChart.js +2 -3
- package/cjs/charts/RoseChart.js.map +1 -1
- package/cjs/charts/SankeyChart.d.ts +1 -1
- package/cjs/charts/SankeyChart.js +2 -3
- package/cjs/charts/SankeyChart.js.map +1 -1
- package/cjs/charts/ScatterChart.d.ts +1 -1
- package/cjs/charts/ScatterChart.js +2 -3
- package/cjs/charts/ScatterChart.js.map +1 -1
- package/cjs/charts/SequenceChart.d.ts +1 -1
- package/cjs/charts/SequenceChart.js +2 -3
- package/cjs/charts/SequenceChart.js.map +1 -1
- package/cjs/charts/SunburstChart.d.ts +1 -1
- package/cjs/charts/SunburstChart.js +2 -3
- package/cjs/charts/SunburstChart.js.map +1 -1
- package/cjs/charts/TreemapChart.js +2 -3
- package/cjs/charts/TreemapChart.js.map +1 -1
- package/cjs/charts/WaterfallChart.js +1 -3
- package/cjs/charts/WaterfallChart.js.map +1 -1
- package/cjs/charts/WordCloud3dChart.d.ts +10 -0
- package/cjs/charts/WordCloud3dChart.js +13 -0
- package/cjs/charts/WordCloud3dChart.js.map +1 -0
- package/cjs/charts/WordCloudChart.d.ts +1 -1
- package/cjs/charts/WordCloudChart.js +2 -3
- package/cjs/charts/WordCloudChart.js.map +1 -1
- package/cjs/charts/index.d.ts +26 -10
- package/cjs/charts/index.js +15 -7
- package/cjs/charts/index.js.map +1 -1
- package/cjs/components/BaseComponent.d.ts +1 -1
- package/cjs/components/BaseComponent.js +2 -1
- package/cjs/components/BaseComponent.js.map +1 -1
- package/cjs/components/Brush.js +2 -2
- package/cjs/components/Brush.js.map +1 -1
- package/cjs/components/ContinuousLegend.d.ts +5 -0
- package/cjs/components/ContinuousLegend.js +10 -0
- package/cjs/components/ContinuousLegend.js.map +1 -0
- package/cjs/components/DataZoom.js +2 -2
- package/cjs/components/DataZoom.js.map +1 -1
- package/cjs/components/Indicator.js +2 -2
- package/cjs/components/Indicator.js.map +1 -1
- package/cjs/components/Legend.js +2 -2
- package/cjs/components/Legend.js.map +1 -1
- package/cjs/components/Mark.js +2 -2
- package/cjs/components/Mark.js.map +1 -1
- package/cjs/components/MarkArea.js +2 -2
- package/cjs/components/MarkArea.js.map +1 -1
- package/cjs/components/MarkLine.js +2 -2
- package/cjs/components/MarkLine.js.map +1 -1
- package/cjs/components/MarkPoint.js +2 -2
- package/cjs/components/MarkPoint.js.map +1 -1
- package/cjs/components/Player.js +2 -2
- package/cjs/components/Player.js.map +1 -1
- package/cjs/components/Region.d.ts +1 -2
- package/cjs/components/Region.js +1 -2
- package/cjs/components/Region.js.map +1 -1
- package/cjs/components/ScrollBar.js +2 -2
- package/cjs/components/ScrollBar.js.map +1 -1
- package/cjs/components/Title.js +3 -2
- package/cjs/components/Title.js.map +1 -1
- package/cjs/components/index.d.ts +1 -0
- package/cjs/components/index.js +1 -1
- package/cjs/components/index.js.map +1 -1
- package/cjs/components/tooltip/CanvasTooltip.d.ts +2 -0
- package/cjs/components/tooltip/CanvasTooltip.js +10 -0
- package/cjs/components/tooltip/CanvasTooltip.js.map +1 -0
- package/cjs/components/tooltip/Tooltip.js +2 -2
- package/cjs/components/tooltip/Tooltip.js.map +1 -1
- package/cjs/components/tooltip/index.d.ts +1 -0
- package/cjs/components/tooltip/index.js +1 -1
- package/cjs/components/tooltip/index.js.map +1 -1
- package/cjs/index.d.ts +1 -1
- package/cjs/index.js +1 -1
- package/cjs/index.js.map +1 -1
- package/cjs/series/Area.js +2 -2
- package/cjs/series/Area.js.map +1 -1
- package/cjs/series/Bar.js +3 -3
- package/cjs/series/Bar.js.map +1 -1
- package/cjs/series/Bar3d.d.ts +7 -0
- package/cjs/series/Bar3d.js +10 -0
- package/cjs/series/Bar3d.js.map +1 -0
- package/cjs/series/BaseSeries.d.ts +1 -1
- package/cjs/series/BaseSeries.js +3 -2
- package/cjs/series/BaseSeries.js.map +1 -1
- package/cjs/series/BoxPlot.js +3 -3
- package/cjs/series/BoxPlot.js.map +1 -1
- package/cjs/series/CirclePacking.js +3 -3
- package/cjs/series/CirclePacking.js.map +1 -1
- package/cjs/series/CircularProgress.js +3 -3
- package/cjs/series/CircularProgress.js.map +1 -1
- package/cjs/series/Correlation.js +3 -3
- package/cjs/series/Correlation.js.map +1 -1
- package/cjs/series/Dot.js +3 -3
- package/cjs/series/Dot.js.map +1 -1
- package/cjs/series/Funnel.js +3 -3
- package/cjs/series/Funnel.js.map +1 -1
- package/cjs/series/Funnel3d.d.ts +7 -0
- package/cjs/series/Funnel3d.js +10 -0
- package/cjs/series/Funnel3d.js.map +1 -0
- package/cjs/series/Gauge.js +3 -3
- package/cjs/series/Gauge.js.map +1 -1
- package/cjs/series/Heatmap.js +3 -3
- package/cjs/series/Heatmap.js.map +1 -1
- package/cjs/series/Line.js +3 -2
- package/cjs/series/Line.js.map +1 -1
- package/cjs/series/LinearProgress.js +3 -3
- package/cjs/series/LinearProgress.js.map +1 -1
- package/cjs/series/Link.js +3 -3
- package/cjs/series/Link.js.map +1 -1
- package/cjs/series/Liquid.js +3 -3
- package/cjs/series/Liquid.js.map +1 -1
- package/cjs/series/Map.js +3 -3
- package/cjs/series/Map.js.map +1 -1
- package/cjs/series/Pie.js +3 -3
- package/cjs/series/Pie.js.map +1 -1
- package/cjs/series/Pie3d.d.ts +7 -0
- package/cjs/series/Pie3d.js +10 -0
- package/cjs/series/Pie3d.js.map +1 -0
- package/cjs/series/Radar.js +3 -3
- package/cjs/series/Radar.js.map +1 -1
- package/cjs/series/RangeColumn.js +3 -3
- package/cjs/series/RangeColumn.js.map +1 -1
- package/cjs/series/RangeColumn3d.d.ts +7 -0
- package/cjs/series/RangeColumn3d.js +10 -0
- package/cjs/series/RangeColumn3d.js.map +1 -0
- package/cjs/series/Rose.js +3 -3
- package/cjs/series/Rose.js.map +1 -1
- package/cjs/series/Sankey.js +3 -3
- package/cjs/series/Sankey.js.map +1 -1
- package/cjs/series/Scatter.js +3 -3
- package/cjs/series/Scatter.js.map +1 -1
- package/cjs/series/Series.js +1 -1
- package/cjs/series/Sunburst.js +3 -3
- package/cjs/series/Sunburst.js.map +1 -1
- package/cjs/series/Treemap.js +3 -3
- package/cjs/series/Treemap.js.map +1 -1
- package/cjs/series/Waterfall.js +3 -3
- package/cjs/series/Waterfall.js.map +1 -1
- package/cjs/series/WordCloud.js +3 -3
- package/cjs/series/WordCloud.js.map +1 -1
- package/cjs/series/WordCloud3d.d.ts +7 -0
- package/cjs/series/WordCloud3d.js +10 -0
- package/cjs/series/WordCloud3d.js.map +1 -0
- package/cjs/series/index.d.ts +24 -10
- package/cjs/series/index.js +16 -9
- package/cjs/series/index.js.map +1 -1
- package/esm/charts/AreaChart.d.ts +1 -1
- package/esm/charts/AreaChart.js +3 -4
- package/esm/charts/AreaChart.js.map +1 -1
- package/esm/charts/Bar3dChart.d.ts +10 -0
- package/esm/charts/Bar3dChart.js +9 -0
- package/esm/charts/Bar3dChart.js.map +1 -0
- package/esm/charts/BarChart.d.ts +1 -1
- package/esm/charts/BarChart.js +2 -2
- package/esm/charts/BarChart.js.map +1 -1
- package/esm/charts/BaseChart.d.ts +1 -1
- package/esm/charts/BaseChart.js +3 -2
- package/esm/charts/BaseChart.js.map +1 -1
- package/esm/charts/BoxPlotChart.d.ts +1 -1
- package/esm/charts/BoxPlotChart.js +2 -4
- package/esm/charts/BoxPlotChart.js.map +1 -1
- package/esm/charts/CirclePackingChart.d.ts +1 -1
- package/esm/charts/CirclePackingChart.js +1 -3
- package/esm/charts/CirclePackingChart.js.map +1 -1
- package/esm/charts/CircularProgressChart.d.ts +1 -1
- package/esm/charts/CircularProgressChart.js +2 -4
- package/esm/charts/CircularProgressChart.js.map +1 -1
- package/esm/charts/CommonChart.d.ts +1 -1
- package/esm/charts/CommonChart.js +2 -4
- package/esm/charts/CommonChart.js.map +1 -1
- package/esm/charts/CorrelationChart.d.ts +1 -1
- package/esm/charts/CorrelationChart.js +2 -4
- package/esm/charts/CorrelationChart.js.map +1 -1
- package/esm/charts/Funnel3dChart.d.ts +10 -0
- package/esm/charts/Funnel3dChart.js +9 -0
- package/esm/charts/Funnel3dChart.js.map +1 -0
- package/esm/charts/FunnelChart.d.ts +1 -1
- package/esm/charts/FunnelChart.js +3 -5
- package/esm/charts/FunnelChart.js.map +1 -1
- package/esm/charts/GaugeChart.d.ts +4 -4
- package/esm/charts/GaugeChart.js +5 -7
- package/esm/charts/GaugeChart.js.map +1 -1
- package/esm/charts/HeatmapChart.d.ts +1 -1
- package/esm/charts/HeatmapChart.js +3 -5
- package/esm/charts/HeatmapChart.js.map +1 -1
- package/esm/charts/Histogram3dChart.d.ts +10 -0
- package/esm/charts/Histogram3dChart.js +9 -0
- package/esm/charts/Histogram3dChart.js.map +1 -0
- package/esm/charts/HistogramChart.d.ts +1 -1
- package/esm/charts/HistogramChart.js +2 -5
- package/esm/charts/HistogramChart.js.map +1 -1
- package/esm/charts/LineChart.d.ts +1 -1
- package/esm/charts/LineChart.js +3 -5
- package/esm/charts/LineChart.js.map +1 -1
- package/esm/charts/LinearProgressChart.d.ts +1 -1
- package/esm/charts/LinearProgressChart.js +3 -5
- package/esm/charts/LinearProgressChart.js.map +1 -1
- package/esm/charts/LiquidChart.d.ts +1 -1
- package/esm/charts/LiquidChart.js +3 -5
- package/esm/charts/LiquidChart.js.map +1 -1
- package/esm/charts/MapChart.d.ts +1 -1
- package/esm/charts/MapChart.js +3 -5
- package/esm/charts/MapChart.js.map +1 -1
- package/esm/charts/Pie3dChart.d.ts +10 -0
- package/esm/charts/Pie3dChart.js +9 -0
- package/esm/charts/Pie3dChart.js.map +1 -0
- package/esm/charts/PieChart.d.ts +1 -1
- package/esm/charts/PieChart.js +3 -5
- package/esm/charts/PieChart.js.map +1 -1
- package/esm/charts/RadarChart.d.ts +1 -1
- package/esm/charts/RadarChart.js +3 -5
- package/esm/charts/RadarChart.js.map +1 -1
- package/esm/charts/RangeColumn3dChart.d.ts +10 -0
- package/esm/charts/RangeColumn3dChart.js +9 -0
- package/esm/charts/RangeColumn3dChart.js.map +1 -0
- package/esm/charts/RangeColumnChart.d.ts +1 -1
- package/esm/charts/RangeColumnChart.js +3 -5
- package/esm/charts/RangeColumnChart.js.map +1 -1
- package/esm/charts/RoseChart.d.ts +1 -1
- package/esm/charts/RoseChart.js +3 -5
- package/esm/charts/RoseChart.js.map +1 -1
- package/esm/charts/SankeyChart.d.ts +1 -1
- package/esm/charts/SankeyChart.js +3 -5
- package/esm/charts/SankeyChart.js.map +1 -1
- package/esm/charts/ScatterChart.d.ts +1 -1
- package/esm/charts/ScatterChart.js +3 -5
- package/esm/charts/ScatterChart.js.map +1 -1
- package/esm/charts/SequenceChart.d.ts +1 -1
- package/esm/charts/SequenceChart.js +3 -5
- package/esm/charts/SequenceChart.js.map +1 -1
- package/esm/charts/SunburstChart.d.ts +1 -1
- package/esm/charts/SunburstChart.js +3 -5
- package/esm/charts/SunburstChart.js.map +1 -1
- package/esm/charts/TreemapChart.js +3 -5
- package/esm/charts/TreemapChart.js.map +1 -1
- package/esm/charts/WaterfallChart.js +2 -5
- package/esm/charts/WaterfallChart.js.map +1 -1
- package/esm/charts/WordCloud3dChart.d.ts +10 -0
- package/esm/charts/WordCloud3dChart.js +9 -0
- package/esm/charts/WordCloud3dChart.js.map +1 -0
- package/esm/charts/WordCloudChart.d.ts +1 -1
- package/esm/charts/WordCloudChart.js +3 -5
- package/esm/charts/WordCloudChart.js.map +1 -1
- package/esm/charts/index.d.ts +26 -10
- package/esm/charts/index.js +43 -11
- package/esm/charts/index.js.map +1 -1
- package/esm/components/BaseComponent.d.ts +1 -1
- package/esm/components/BaseComponent.js +4 -1
- package/esm/components/BaseComponent.js.map +1 -1
- package/esm/components/Brush.js +3 -1
- package/esm/components/Brush.js.map +1 -1
- package/esm/components/ContinuousLegend.d.ts +5 -0
- package/esm/components/ContinuousLegend.js +8 -0
- package/esm/components/ContinuousLegend.js.map +1 -0
- package/esm/components/DataZoom.js +3 -1
- package/esm/components/DataZoom.js.map +1 -1
- package/esm/components/Indicator.js +3 -1
- package/esm/components/Indicator.js.map +1 -1
- package/esm/components/Legend.js +3 -1
- package/esm/components/Legend.js.map +1 -1
- package/esm/components/Mark.js +3 -1
- package/esm/components/Mark.js.map +1 -1
- package/esm/components/MarkArea.js +3 -1
- package/esm/components/MarkArea.js.map +1 -1
- package/esm/components/MarkLine.js +3 -1
- package/esm/components/MarkLine.js.map +1 -1
- package/esm/components/MarkPoint.js +3 -1
- package/esm/components/MarkPoint.js.map +1 -1
- package/esm/components/Player.js +3 -1
- package/esm/components/Player.js.map +1 -1
- package/esm/components/Region.d.ts +1 -2
- package/esm/components/Region.js +1 -2
- package/esm/components/Region.js.map +1 -1
- package/esm/components/ScrollBar.js +3 -1
- package/esm/components/ScrollBar.js.map +1 -1
- package/esm/components/Title.js +4 -1
- package/esm/components/Title.js.map +1 -1
- package/esm/components/index.d.ts +1 -0
- package/esm/components/index.js +2 -0
- package/esm/components/index.js.map +1 -1
- package/esm/components/tooltip/CanvasTooltip.d.ts +2 -0
- package/esm/components/tooltip/CanvasTooltip.js +6 -0
- package/esm/components/tooltip/CanvasTooltip.js.map +1 -0
- package/esm/components/tooltip/Tooltip.js +3 -1
- package/esm/components/tooltip/Tooltip.js.map +1 -1
- package/esm/components/tooltip/index.d.ts +1 -0
- package/esm/components/tooltip/index.js +2 -0
- package/esm/components/tooltip/index.js.map +1 -1
- package/esm/index.d.ts +1 -1
- package/esm/index.js +1 -1
- package/esm/index.js.map +1 -1
- package/esm/series/Area.js +3 -1
- package/esm/series/Area.js.map +1 -1
- package/esm/series/Bar.js +4 -2
- package/esm/series/Bar.js.map +1 -1
- package/esm/series/Bar3d.d.ts +7 -0
- package/esm/series/Bar3d.js +6 -0
- package/esm/series/Bar3d.js.map +1 -0
- package/esm/series/BaseSeries.d.ts +1 -1
- package/esm/series/BaseSeries.js +5 -2
- package/esm/series/BaseSeries.js.map +1 -1
- package/esm/series/BoxPlot.js +4 -2
- package/esm/series/BoxPlot.js.map +1 -1
- package/esm/series/CirclePacking.js +4 -2
- package/esm/series/CirclePacking.js.map +1 -1
- package/esm/series/CircularProgress.js +4 -2
- package/esm/series/CircularProgress.js.map +1 -1
- package/esm/series/Correlation.js +4 -2
- package/esm/series/Correlation.js.map +1 -1
- package/esm/series/Dot.js +4 -2
- package/esm/series/Dot.js.map +1 -1
- package/esm/series/Funnel.js +4 -2
- package/esm/series/Funnel.js.map +1 -1
- package/esm/series/Funnel3d.d.ts +7 -0
- package/esm/series/Funnel3d.js +6 -0
- package/esm/series/Funnel3d.js.map +1 -0
- package/esm/series/Gauge.js +4 -2
- package/esm/series/Gauge.js.map +1 -1
- package/esm/series/Heatmap.js +4 -2
- package/esm/series/Heatmap.js.map +1 -1
- package/esm/series/Line.js +4 -1
- package/esm/series/Line.js.map +1 -1
- package/esm/series/LinearProgress.js +4 -2
- package/esm/series/LinearProgress.js.map +1 -1
- package/esm/series/Link.js +4 -2
- package/esm/series/Link.js.map +1 -1
- package/esm/series/Liquid.js +4 -2
- package/esm/series/Liquid.js.map +1 -1
- package/esm/series/Map.js +4 -2
- package/esm/series/Map.js.map +1 -1
- package/esm/series/Pie.js +4 -2
- package/esm/series/Pie.js.map +1 -1
- package/esm/series/Pie3d.d.ts +7 -0
- package/esm/series/Pie3d.js +6 -0
- package/esm/series/Pie3d.js.map +1 -0
- package/esm/series/Radar.js +4 -2
- package/esm/series/Radar.js.map +1 -1
- package/esm/series/RangeColumn.js +4 -2
- package/esm/series/RangeColumn.js.map +1 -1
- package/esm/series/RangeColumn3d.d.ts +7 -0
- package/esm/series/RangeColumn3d.js +6 -0
- package/esm/series/RangeColumn3d.js.map +1 -0
- package/esm/series/Rose.js +4 -2
- package/esm/series/Rose.js.map +1 -1
- package/esm/series/Sankey.js +4 -2
- package/esm/series/Sankey.js.map +1 -1
- package/esm/series/Scatter.js +4 -2
- package/esm/series/Scatter.js.map +1 -1
- package/esm/series/Series.js +1 -1
- package/esm/series/Sunburst.js +4 -2
- package/esm/series/Sunburst.js.map +1 -1
- package/esm/series/Treemap.js +4 -2
- package/esm/series/Treemap.js.map +1 -1
- package/esm/series/Waterfall.js +4 -2
- package/esm/series/Waterfall.js.map +1 -1
- package/esm/series/WordCloud.js +4 -2
- package/esm/series/WordCloud.js.map +1 -1
- package/esm/series/WordCloud3d.d.ts +7 -0
- package/esm/series/WordCloud3d.js +6 -0
- package/esm/series/WordCloud3d.js.map +1 -0
- package/esm/series/index.d.ts +24 -10
- package/esm/series/index.js +40 -12
- package/esm/series/index.js.map +1 -1
- package/package.json +7 -7
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { IAreaChartSpec } from '@visactor/vchart';
|
|
3
3
|
import { BaseChartProps } from './BaseChart';
|
|
4
|
-
export interface AreaChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type'>, Omit<IAreaChartSpec, 'type'> {
|
|
4
|
+
export interface AreaChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>, Omit<IAreaChartSpec, 'type'> {
|
|
5
5
|
}
|
|
6
6
|
export declare const AreaChart: React.ForwardRefExoticComponent<AreaChartProps & {
|
|
7
7
|
children?: React.ReactNode;
|
package/cjs/charts/AreaChart.js
CHANGED
|
@@ -6,8 +6,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
|
|
7
7
|
const vchart_1 = require("@visactor/vchart"), BaseChart_1 = require("./BaseChart");
|
|
8
8
|
|
|
9
|
-
vchart_1.VChart.useRegisters([ vchart_1.registerAreaChart, vchart_1.registerCartesianLinearAxis, vchart_1.registerCartesianBandAxis, vchart_1.registerCartesianTimeAxis, vchart_1.registerCartesianLogAxis, vchart_1.registerDiscreteLegend, vchart_1.registerContinuousLegend, vchart_1.registerTooltip, vchart_1.registerDomTooltipHandler, vchart_1.registerCanvasTooltipHandler, vchart_1.registerCartesianCrossHair, vchart_1.registerDataZoom, vchart_1.registerScrollBar, vchart_1.registerLabel, vchart_1.registerTitle, vchart_1.registerMarkLine, vchart_1.registerMarkPoint, vchart_1.registerMarkArea, vchart_1.registerTotalLabel, vchart_1.registerBrush, vchart_1.registerCustomMark ]),
|
|
10
9
|
exports.AreaChart = (0, BaseChart_1.createChart)("AreaChart", {
|
|
11
10
|
type: "area",
|
|
12
11
|
vchartConstrouctor: vchart_1.VChart
|
|
13
|
-
});
|
|
12
|
+
}, [ vchart_1.registerAreaChart, vchart_1.registerCartesianLinearAxis, vchart_1.registerCartesianBandAxis, vchart_1.registerCartesianTimeAxis, vchart_1.registerCartesianLogAxis, vchart_1.registerCartesianCrossHair, vchart_1.registerLabel ]);
|
|
13
|
+
//# sourceMappingURL=AreaChart.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/charts/AreaChart.tsx"],"names":[],"mappings":";;;AAEA,
|
|
1
|
+
{"version":3,"sources":["../src/charts/AreaChart.tsx"],"names":[],"mappings":";;;AAEA,6CAS0B;AAC1B,2CAA0D;AAM7C,QAAA,SAAS,GAAG,IAAA,uBAAW,EAClC,WAAW,EACX;IACE,IAAI,EAAE,MAAM;IACZ,kBAAkB,EAAE,eAA4B;CACjD,EACD;IACE,0BAAiB;IACjB,oCAA2B;IAC3B,kCAAyB;IACzB,kCAAyB;IACzB,iCAAwB;IACxB,mCAA0B;IAC1B,sBAAa;CACd,CACF,CAAC","file":"AreaChart.js","sourcesContent":["import React from 'react';\nimport type { IAreaChartSpec, IVChartConstructor } from '@visactor/vchart';\nimport {\n VChart,\n registerAreaChart,\n registerCartesianLinearAxis,\n registerCartesianBandAxis,\n registerCartesianTimeAxis, // 非必选\n registerCartesianLogAxis, // 非必选\n registerCartesianCrossHair,\n registerLabel\n} from '@visactor/vchart';\nimport { BaseChartProps, createChart } from './BaseChart';\n\nexport interface AreaChartProps\n extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>,\n Omit<IAreaChartSpec, 'type'> {}\n\nexport const AreaChart = createChart<React.PropsWithChildren<AreaChartProps> & { type: 'area' }>(\n 'AreaChart',\n {\n type: 'area',\n vchartConstrouctor: VChart as IVChartConstructor\n },\n [\n registerAreaChart,\n registerCartesianLinearAxis,\n registerCartesianBandAxis,\n registerCartesianTimeAxis, // 非必选\n registerCartesianLogAxis, // 非必选\n registerCartesianCrossHair,\n registerLabel\n ]\n);\n"]}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { IBar3dChartSpec } from '@visactor/vchart';
|
|
3
|
+
import { BaseChartProps } from './BaseChart';
|
|
4
|
+
export interface Bar3dChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>, Omit<IBar3dChartSpec, 'type'> {
|
|
5
|
+
}
|
|
6
|
+
export declare const Bar3dChart: React.ForwardRefExoticComponent<Bar3dChartProps & {
|
|
7
|
+
children?: React.ReactNode;
|
|
8
|
+
} & {
|
|
9
|
+
type: 'bar3d';
|
|
10
|
+
} & import("../containers/withContainer").ContainerProps & React.RefAttributes<any>>;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: !0
|
|
5
|
+
}), exports.Bar3dChart = void 0;
|
|
6
|
+
|
|
7
|
+
const vchart_1 = require("@visactor/vchart"), BaseChart_1 = require("./BaseChart");
|
|
8
|
+
|
|
9
|
+
exports.Bar3dChart = (0, BaseChart_1.createChart)("Bar3dChart", {
|
|
10
|
+
type: "bar3d",
|
|
11
|
+
vchartConstrouctor: vchart_1.VChart
|
|
12
|
+
}, [ vchart_1.registerBar3dChart, vchart_1.registerCartesianLinearAxis, vchart_1.registerCartesianBandAxis, vchart_1.registerCartesianTimeAxis, vchart_1.registerCartesianLogAxis, vchart_1.registerCartesianCrossHair, vchart_1.registerLabel, vchart_1.registerTotalLabel ]);
|
|
13
|
+
//# sourceMappingURL=Bar3dChart.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/charts/Bar3dChart.tsx"],"names":[],"mappings":";;;AAEA,6CAU0B;AAC1B,2CAA0D;AAQ7C,QAAA,UAAU,GAAG,IAAA,uBAAW,EACnC,YAAY,EACZ;IACE,IAAI,EAAE,OAAO;IACb,kBAAkB,EAAE,eAA4B;CACjD,EACD;IACE,2BAAkB;IAClB,oCAA2B;IAC3B,kCAAyB;IACzB,kCAAyB;IACzB,iCAAwB;IACxB,mCAA0B;IAC1B,sBAAa;IACb,2BAAkB;CACnB,CACF,CAAC","file":"Bar3dChart.js","sourcesContent":["import React from 'react';\nimport type { IBar3dChartSpec, IVChartConstructor } from '@visactor/vchart';\nimport {\n VChart,\n registerBar3dChart,\n registerCartesianLinearAxis,\n registerCartesianBandAxis,\n registerCartesianTimeAxis, // 非必选\n registerCartesianLogAxis, // 非必选\n registerCartesianCrossHair,\n registerLabel,\n registerTotalLabel\n} from '@visactor/vchart';\nimport { BaseChartProps, createChart } from './BaseChart';\n\nexport interface Bar3dChartProps\n extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>,\n Omit<IBar3dChartSpec, 'type'> {\n //\n}\n\nexport const Bar3dChart = createChart<React.PropsWithChildren<Bar3dChartProps> & { type: 'bar3d' }>(\n 'Bar3dChart',\n {\n type: 'bar3d',\n vchartConstrouctor: VChart as IVChartConstructor\n },\n [\n registerBar3dChart,\n registerCartesianLinearAxis,\n registerCartesianBandAxis,\n registerCartesianTimeAxis, // 非必选\n registerCartesianLogAxis, // 非必选\n registerCartesianCrossHair,\n registerLabel,\n registerTotalLabel\n ]\n);\n"]}
|
package/cjs/charts/BarChart.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { IBarChartSpec } from '@visactor/vchart';
|
|
3
3
|
import { BaseChartProps } from './BaseChart';
|
|
4
|
-
export interface BarChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type'>, Omit<IBarChartSpec, 'type'> {
|
|
4
|
+
export interface BarChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>, Omit<IBarChartSpec, 'type'> {
|
|
5
5
|
}
|
|
6
6
|
export declare const BarChart: React.ForwardRefExoticComponent<BarChartProps & {
|
|
7
7
|
children?: React.ReactNode;
|
package/cjs/charts/BarChart.js
CHANGED
|
@@ -9,5 +9,5 @@ const vchart_1 = require("@visactor/vchart"), BaseChart_1 = require("./BaseChart
|
|
|
9
9
|
exports.BarChart = (0, BaseChart_1.createChart)("BarChart", {
|
|
10
10
|
type: "bar",
|
|
11
11
|
vchartConstrouctor: vchart_1.VChart
|
|
12
|
-
});
|
|
12
|
+
}, [ vchart_1.registerBarChart, vchart_1.registerCartesianLinearAxis, vchart_1.registerCartesianBandAxis, vchart_1.registerCartesianTimeAxis, vchart_1.registerCartesianLogAxis, vchart_1.registerCartesianCrossHair, vchart_1.registerLabel, vchart_1.registerTotalLabel ]);
|
|
13
13
|
//# sourceMappingURL=BarChart.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/charts/BarChart.tsx"],"names":[],"mappings":";;;AAEA,
|
|
1
|
+
{"version":3,"sources":["../src/charts/BarChart.tsx"],"names":[],"mappings":";;;AAEA,6CAU0B;AAC1B,2CAA0D;AAQ7C,QAAA,QAAQ,GAAG,IAAA,uBAAW,EACjC,UAAU,EACV;IACE,IAAI,EAAE,KAAK;IACX,kBAAkB,EAAE,eAA4B;CACjD,EACD;IACE,yBAAgB;IAChB,oCAA2B;IAC3B,kCAAyB;IACzB,kCAAyB;IACzB,iCAAwB;IACxB,mCAA0B;IAC1B,sBAAa;IACb,2BAAkB;CACnB,CACF,CAAC","file":"BarChart.js","sourcesContent":["import React from 'react';\nimport type { IBarChartSpec, IVChartConstructor } from '@visactor/vchart';\nimport {\n VChart,\n registerBarChart,\n registerCartesianLinearAxis,\n registerCartesianBandAxis,\n registerCartesianTimeAxis, // 非必选\n registerCartesianLogAxis, // 非必选\n registerCartesianCrossHair,\n registerLabel,\n registerTotalLabel\n} from '@visactor/vchart';\nimport { BaseChartProps, createChart } from './BaseChart';\n\nexport interface BarChartProps\n extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>,\n Omit<IBarChartSpec, 'type'> {\n //\n}\n\nexport const BarChart = createChart<React.PropsWithChildren<BarChartProps> & { type: 'bar' }>(\n 'BarChart',\n {\n type: 'bar',\n vchartConstrouctor: VChart as IVChartConstructor\n },\n [\n registerBarChart,\n registerCartesianLinearAxis,\n registerCartesianBandAxis,\n registerCartesianTimeAxis, // 非必选\n registerCartesianLogAxis, // 非必选\n registerCartesianCrossHair,\n registerLabel,\n registerTotalLabel\n ]\n);\n"]}
|
|
@@ -19,5 +19,5 @@ export interface BaseChartProps extends EventsProps, LegendEventProps, ScrollBar
|
|
|
19
19
|
useSyncRender?: boolean;
|
|
20
20
|
}
|
|
21
21
|
type Props = React.PropsWithChildren<BaseChartProps>;
|
|
22
|
-
export declare const createChart: <T extends Props>(componentName: string, defaultProps?: Partial<T>,
|
|
22
|
+
export declare const createChart: <T extends Props>(componentName: string, defaultProps?: Partial<T>, registers?: (() => void)[]) => React.ForwardRefExoticComponent<React.PropsWithoutRef<T & ContainerProps> & React.RefAttributes<any>>;
|
|
23
23
|
export {};
|
package/cjs/charts/BaseChart.js
CHANGED
|
@@ -115,8 +115,9 @@ const react_1 = __importStar(require("react")), withContainer_1 = __importDefaul
|
|
|
115
115
|
componentId: childId
|
|
116
116
|
}));
|
|
117
117
|
})), tooltipNode));
|
|
118
|
-
})), createChart = (componentName, defaultProps,
|
|
119
|
-
|
|
118
|
+
})), createChart = (componentName, defaultProps, registers) => {
|
|
119
|
+
registers && registers.length && defaultProps.vchartConstrouctor && defaultProps.vchartConstrouctor.useRegisters(registers);
|
|
120
|
+
const Com = (0, withContainer_1.default)(BaseChart, componentName, (props => defaultProps ? Object.assign(props, defaultProps) : props));
|
|
120
121
|
return Com.displayName = componentName, Com;
|
|
121
122
|
};
|
|
122
123
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/charts/BaseChart.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,+CAA2F;AAC3F,gFAA4E;AAC5E,6DAAsE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ec, IVChartConstructor, IHierarchyData } from '@visactor/vchart';\nimport React, { useState, useEffect, useRef, useImperativeHandle, ReactNode } from 'react';\nimport withContainer, { ContainerProps } from '../containers/withContainer';\nimport RootChartContext, { ChartContextType } from '../context/chart';\nimport type { IView } from '@visactor/vgrammar-core';\nimport { isEqual, isNil, pickWithout } from '@visactor/vutils';\nimport ViewContext from '../context/view';\nimport { toArray } from '../util';\nimport { REACT_PRIVATE_PROPS } from '../constants';\nimport {\n bindEventsToChart,\n EventsProps,\n CHART_EVENTS_KEYS,\n CHART_EVENTS,\n LegendEventProps,\n ScrollBarEventProps,\n BrushEventProps,\n DataZoomEventProps,\n PlayerEventProps,\n DimensionEventProps,\n HierarchyEventProps,\n ChartLifeCycleEventProps\n} from '../eventsUtils';\nimport { IReactTooltipProps } from '../components/tooltip/interface';\nimport { initCustomTooltip } from '../components/tooltip/util';\n\nexport type ChartOptions = Omit<IInitOption, 'dom'>;\n\nexport interface BaseChartProps\n extends EventsProps,\n LegendEventProps,\n ScrollBarEventProps,\n BrushEventProps,\n DataZoomEventProps,\n PlayerEventProps,\n DimensionEventProps,\n HierarchyEventProps,\n ChartLifeCycleEventProps,\n IReactTooltipProps {\n vchartConstrouctor?: IVChartConstructor;\n type?: string;\n /** 上层container */\n container?: HTMLDivElement;\n /**\n * used only by <VChart />\n */\n spec?: ISpec;\n /** 数据 */\n data?: IData | IHierarchyData;\n /** 画布宽度 */\n width?: number;\n /** 画布高度 */\n height?: number;\n /** 图表配置 */\n options?: ChartOptions;\n /** skip function diff when component update */\n skipFunctionDiff?: boolean;\n /** 图表渲染完成事件 */\n onReady?: (instance: IVChart, isInitial: boolean) => void;\n /** throw error when chart run into an error */\n onError?: (err: Error) => void;\n /**\n * use sync render\n *\n * @since 1.8.3\n * @deprecated 1.9.0\n **/\n useSyncRender?: boolean;\n}\n\ntype Props = React.PropsWithChildren<BaseChartProps>;\n\nconst notSpecKeys = [\n ...REACT_PRIVATE_PROPS,\n ...CHART_EVENTS_KEYS,\n 'vchartConstrouctor',\n 'useSyncRender',\n 'skipFunctionDiff',\n 'onError',\n 'onReady',\n 'spec',\n 'container',\n 'options'\n];\n\nconst getComponentId = (child: React.ReactNode, index: number) => {\n const componentName = child && (child as any).type && ((child as any).type.displayName || (child as any).type.name);\n return `${componentName}-${index}`;\n};\n\nconst parseSpecFromChildren = (props: Props) => {\n const specFromChildren: Omit<ISpec, 'type' | 'data' | 'width' | 'height'> = {};\n\n toArray(props.children).map((child, index) => {\n const parseSpec = child && (child as any).type && (child as any).type.parseSpec;\n\n if (parseSpec && (child as any).props) {\n const childProps = isNil((child as any).props.componentId)\n ? {\n ...(child as any).props,\n componentId: getComponentId(child, index)\n }\n : (child as any).props;\n\n const specResult = parseSpec(childProps);\n\n if (specResult.isSingle) {\n specFromChildren[specResult.specName] = specResult.spec;\n } else {\n if (!specFromChildren[specResult.specName]) {\n specFromChildren[specResult.specName] = [];\n }\n\n specFromChildren[specResult.specName].push(specResult.spec);\n }\n }\n });\n\n return specFromChildren;\n};\n\nconst BaseChart: React.FC<Props> = React.forwardRef((props, ref) => {\n const [updateId, setUpdateId] = useState<number>(0);\n const chartContext = useRef<ChartContextType>({});\n useImperativeHandle(ref, () => chartContext.current?.chart);\n const hasSpec = !!props.spec;\n const [view, setView] = useState<IView>(null);\n const isUnmount = useRef<boolean>(false);\n const prevSpec = useRef(pickWithout(props, notSpecKeys));\n const specFromChildren = useRef<Omit<ISpec, 'type' | 'data' | 'width' | 'height'>>(null);\n const eventsBinded = React.useRef<BaseChartProps>(null);\n const skipFunctionDiff = !!props.skipFunctionDiff;\n const [tooltipNode, setTooltipNode] = useState<ReactNode>(null);\n\n const parseSpec = (props: Props) => {\n let spec: ISpec = undefined;\n\n if (hasSpec && props.spec) {\n spec = props.spec;\n } else {\n spec = {\n ...prevSpec.current,\n ...specFromChildren.current\n } as ISpec;\n }\n\n const tooltipSpec = initCustomTooltip(setTooltipNode, props, spec.tooltip);\n if (tooltipSpec) {\n spec.tooltip = tooltipSpec;\n }\n return spec;\n };\n\n const createChart = (props: Props) => {\n const cs = new props.vchartConstrouctor(parseSpec(props), {\n ...props.options,\n onError: props.onError,\n autoFit: true,\n dom: props.container\n });\n chartContext.current = { ...chartContext.current, chart: cs };\n isUnmount.current = false;\n };\n\n const handleChartRender = () => {\n // rebind events after render\n if (!isUnmount.current) {\n if (!chartContext.current || !chartContext.current.chart) {\n return;\n }\n\n bindEventsToChart(chartContext.current.chart, props, eventsBinded.current, CHART_EVENTS);\n\n const newView = chartContext.current.chart.getCompiler().getVGrammarView();\n\n setUpdateId(updateId + 1);\n if (props.onReady) {\n props.onReady(chartContext.current.chart, updateId === 0);\n }\n setView(newView);\n }\n };\n\n const renderChart = () => {\n if (chartContext.current.chart) {\n chartContext.current.chart.renderSync({\n reuse: false\n });\n handleChartRender();\n }\n };\n\n useEffect(() => {\n const newSpecFromChildren = hasSpec ? null : parseSpecFromChildren(props);\n\n if (!chartContext.current?.chart) {\n if (!hasSpec) {\n specFromChildren.current = newSpecFromChildren;\n }\n\n createChart(props);\n renderChart();\n eventsBinded.current = props;\n return;\n }\n\n if (hasSpec) {\n if (!isEqual(eventsBinded.current.spec, props.spec, { skipFunction: skipFunctionDiff })) {\n eventsBinded.current = props;\n chartContext.current.chart.updateSpecSync(parseSpec(props), undefined, {\n morph: false,\n enableExitAnimation: false\n });\n handleChartRender();\n }\n return;\n }\n\n const newSpec = pickWithout(props, notSpecKeys);\n\n if (\n !isEqual(newSpec, prevSpec.current, { skipFunction: skipFunctionDiff }) ||\n !isEqual(newSpecFromChildren, specFromChildren.current)\n ) {\n prevSpec.current = newSpec;\n specFromChildren.current = newSpecFromChildren;\n\n chartContext.current.chart.updateSpecSync(parseSpec(props), undefined, {\n morph: false,\n enableExitAnimation: false\n });\n handleChartRender();\n }\n }, [props]);\n\n useEffect(() => {\n return () => {\n if (chartContext) {\n if (chartContext.current && chartContext.current.chart) {\n chartContext.current.chart.release();\n chartContext.current.chart = null;\n }\n }\n eventsBinded.current = null;\n isUnmount.current = true;\n };\n }, []);\n\n return (\n <RootChartContext.Provider value={chartContext.current}>\n <ViewContext.Provider value={view}>\n {toArray(props.children).map((child, index) => {\n if (typeof child === 'string') {\n return;\n }\n\n const childId = getComponentId(child, index);\n\n return (\n <React.Fragment key={childId}>\n {React.cloneElement(child as React.ReactElement<any, React.JSXElementConstructor<any>>, {\n updateId: updateId,\n componentId: childId\n })}\n </React.Fragment>\n );\n })}\n {tooltipNode}\n </ViewContext.Provider>\n </RootChartContext.Provider>\n );\n});\n\nexport const createChart = <T extends Props>(\n componentName: string,\n defaultProps?: Partial<T>,\n callback?: (props: T, defaultProps?: Partial<T>) => T\n) => {\n const Com = withContainer<ContainerProps, T>(BaseChart as any, componentName, (props: T) => {\n if (callback) {\n return callback(props, defaultProps);\n }\n\n if (defaultProps) {\n return Object.assign(props, defaultProps);\n }\n return props;\n });\n Com.displayName = componentName;\n return Com;\n};\n"]}
|
|
1
|
+
{"version":3,"sources":["../src/charts/BaseChart.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,+CAA2F;AAC3F,gFAA4E;AAC5E,6DAAsE;AAEtE,6CAA+D;AAC/D,2DAA0C;AAC1C,kCAAkC;AAClC,4CAAmD;AACnD,gDAawB;AAExB,qDAA+D;AAgD/D,MAAM,WAAW,GAAG;IAClB,GAAG,+BAAmB;IACtB,GAAG,+BAAiB;IACpB,oBAAoB;IACpB,eAAe;IACf,kBAAkB;IAClB,SAAS;IACT,SAAS;IACT,MAAM;IACN,WAAW;IACX,SAAS;CACV,CAAC;AAEF,MAAM,cAAc,GAAG,CAAC,KAAsB,EAAE,KAAa,EAAE,EAAE;IAC/D,MAAM,aAAa,GAAG,KAAK,IAAK,KAAa,CAAC,IAAI,IAAI,CAAE,KAAa,CAAC,IAAI,CAAC,WAAW,IAAK,KAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACpH,OAAO,GAAG,aAAa,IAAI,KAAK,EAAE,CAAC;A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BACtF,QAAQ,EAAE,QAAQ;oBAClB,WAAW,EAAE,OAAO;iBACrB,CAAC,CACa,CAClB,CAAC;YACJ,CAAC,CAAC;YACD,WAAW,CACS,CACG,CAC7B,CAAC;AACJ,CAAC,CAAC,CAAC;AAEI,MAAM,WAAW,GAAG,CACzB,aAAqB,EACrB,YAAyB,EACzB,SAA0B,EAC1B,EAAE;IACF,IAAI,SAAS,IAAI,SAAS,CAAC,MAAM,IAAI,YAAY,CAAC,kBAAkB,EAAE;QACpE,YAAY,CAAC,kBAAkB,CAAC,YAAY,CAAC,SAAS,CAAC,CAAC;KACzD;IAED,MAAM,GAAG,GAAG,IAAA,uBAAa,EAAoB,SAAgB,EAAE,aAAa,EAAE,CAAC,KAAQ,EAAE,EAAE;QACzF,IAAI,YAAY,EAAE;YAChB,OAAO,MAAM,CAAC,MAAM,CAAC,KAAK,EAAE,YAAY,CAAC,CAAC;SAC3C;QACD,OAAO,KAAK,CAAC;IACf,CAAC,CAAC,CAAC;IACH,GAAG,CAAC,WAAW,GAAG,aAAa,CAAC;IAChC,OAAO,GAAG,CAAC;AACb,CAAC,CAAC;AAjBW,QAAA,WAAW,eAiBtB","file":"BaseChart.js","sourcesContent":["import type { IVChart, IData, IInitOption, ISpec, IVChartConstructor, IHierarchyData } from '@visactor/vchart';\nimport React, { useState, useEffect, useRef, useImperativeHandle, ReactNode } from 'react';\nimport withContainer, { ContainerProps } from '../containers/withContainer';\nimport RootChartContext, { ChartContextType } from '../context/chart';\nimport type { IView } from '@visactor/vgrammar-core';\nimport { isEqual, isNil, pickWithout } from '@visactor/vutils';\nimport ViewContext from '../context/view';\nimport { toArray } from '../util';\nimport { REACT_PRIVATE_PROPS } from '../constants';\nimport {\n bindEventsToChart,\n EventsProps,\n CHART_EVENTS_KEYS,\n CHART_EVENTS,\n LegendEventProps,\n ScrollBarEventProps,\n BrushEventProps,\n DataZoomEventProps,\n PlayerEventProps,\n DimensionEventProps,\n HierarchyEventProps,\n ChartLifeCycleEventProps\n} from '../eventsUtils';\nimport { IReactTooltipProps } from '../components/tooltip/interface';\nimport { initCustomTooltip } from '../components/tooltip/util';\n\nexport type ChartOptions = Omit<IInitOption, 'dom'>;\n\nexport interface BaseChartProps\n extends EventsProps,\n LegendEventProps,\n ScrollBarEventProps,\n BrushEventProps,\n DataZoomEventProps,\n PlayerEventProps,\n DimensionEventProps,\n HierarchyEventProps,\n ChartLifeCycleEventProps,\n IReactTooltipProps {\n vchartConstrouctor?: IVChartConstructor;\n type?: string;\n /** 上层container */\n container?: HTMLDivElement;\n /**\n * used only by <VChart />\n */\n spec?: ISpec;\n /** 数据 */\n data?: IData | IHierarchyData;\n /** 画布宽度 */\n width?: number;\n /** 画布高度 */\n height?: number;\n /** 图表配置 */\n options?: ChartOptions;\n /** skip function diff when component update */\n skipFunctionDiff?: boolean;\n /** 图表渲染完成事件 */\n onReady?: (instance: IVChart, isInitial: boolean) => void;\n /** throw error when chart run into an error */\n onError?: (err: Error) => void;\n /**\n * use sync render\n *\n * @since 1.8.3\n * @deprecated 1.9.0\n **/\n useSyncRender?: boolean;\n}\n\ntype Props = React.PropsWithChildren<BaseChartProps>;\n\nconst notSpecKeys = [\n ...REACT_PRIVATE_PROPS,\n ...CHART_EVENTS_KEYS,\n 'vchartConstrouctor',\n 'useSyncRender',\n 'skipFunctionDiff',\n 'onError',\n 'onReady',\n 'spec',\n 'container',\n 'options'\n];\n\nconst getComponentId = (child: React.ReactNode, index: number) => {\n const componentName = child && (child as any).type && ((child as any).type.displayName || (child as any).type.name);\n return `${componentName}-${index}`;\n};\n\nconst parseSpecFromChildren = (props: Props) => {\n const specFromChildren: Omit<ISpec, 'type' | 'data' | 'width' | 'height'> = {};\n\n toArray(props.children).map((child, index) => {\n const parseSpec = child && (child as any).type && (child as any).type.parseSpec;\n\n if (parseSpec && (child as any).props) {\n const childProps = isNil((child as any).props.componentId)\n ? {\n ...(child as any).props,\n componentId: getComponentId(child, index)\n }\n : (child as any).props;\n\n const specResult = parseSpec(childProps);\n\n if (specResult.isSingle) {\n specFromChildren[specResult.specName] = specResult.spec;\n } else {\n if (!specFromChildren[specResult.specName]) {\n specFromChildren[specResult.specName] = [];\n }\n\n specFromChildren[specResult.specName].push(specResult.spec);\n }\n }\n });\n\n return specFromChildren;\n};\n\nconst BaseChart: React.FC<Props> = React.forwardRef((props, ref) => {\n const [updateId, setUpdateId] = useState<number>(0);\n const chartContext = useRef<ChartContextType>({});\n useImperativeHandle(ref, () => chartContext.current?.chart);\n const hasSpec = !!props.spec;\n const [view, setView] = useState<IView>(null);\n const isUnmount = useRef<boolean>(false);\n const prevSpec = useRef(pickWithout(props, notSpecKeys));\n const specFromChildren = useRef<Omit<ISpec, 'type' | 'data' | 'width' | 'height'>>(null);\n const eventsBinded = React.useRef<BaseChartProps>(null);\n const skipFunctionDiff = !!props.skipFunctionDiff;\n const [tooltipNode, setTooltipNode] = useState<ReactNode>(null);\n\n const parseSpec = (props: Props) => {\n let spec: ISpec = undefined;\n\n if (hasSpec && props.spec) {\n spec = props.spec;\n } else {\n spec = {\n ...prevSpec.current,\n ...specFromChildren.current\n } as ISpec;\n }\n\n const tooltipSpec = initCustomTooltip(setTooltipNode, props, spec.tooltip);\n if (tooltipSpec) {\n spec.tooltip = tooltipSpec;\n }\n return spec;\n };\n\n const createChart = (props: Props) => {\n const cs = new props.vchartConstrouctor(parseSpec(props), {\n ...props.options,\n onError: props.onError,\n autoFit: true,\n dom: props.container\n });\n chartContext.current = { ...chartContext.current, chart: cs };\n isUnmount.current = false;\n };\n\n const handleChartRender = () => {\n // rebind events after render\n if (!isUnmount.current) {\n if (!chartContext.current || !chartContext.current.chart) {\n return;\n }\n\n bindEventsToChart(chartContext.current.chart, props, eventsBinded.current, CHART_EVENTS);\n\n const newView = chartContext.current.chart.getCompiler().getVGrammarView();\n\n setUpdateId(updateId + 1);\n if (props.onReady) {\n props.onReady(chartContext.current.chart, updateId === 0);\n }\n setView(newView);\n }\n };\n\n const renderChart = () => {\n if (chartContext.current.chart) {\n chartContext.current.chart.renderSync({\n reuse: false\n });\n handleChartRender();\n }\n };\n\n useEffect(() => {\n const newSpecFromChildren = hasSpec ? null : parseSpecFromChildren(props);\n\n if (!chartContext.current?.chart) {\n if (!hasSpec) {\n specFromChildren.current = newSpecFromChildren;\n }\n\n createChart(props);\n renderChart();\n eventsBinded.current = props;\n return;\n }\n\n if (hasSpec) {\n if (!isEqual(eventsBinded.current.spec, props.spec, { skipFunction: skipFunctionDiff })) {\n eventsBinded.current = props;\n chartContext.current.chart.updateSpecSync(parseSpec(props), undefined, {\n morph: false,\n enableExitAnimation: false\n });\n handleChartRender();\n }\n return;\n }\n\n const newSpec = pickWithout(props, notSpecKeys);\n\n if (\n !isEqual(newSpec, prevSpec.current, { skipFunction: skipFunctionDiff }) ||\n !isEqual(newSpecFromChildren, specFromChildren.current)\n ) {\n prevSpec.current = newSpec;\n specFromChildren.current = newSpecFromChildren;\n\n chartContext.current.chart.updateSpecSync(parseSpec(props), undefined, {\n morph: false,\n enableExitAnimation: false\n });\n handleChartRender();\n }\n }, [props]);\n\n useEffect(() => {\n return () => {\n if (chartContext) {\n if (chartContext.current && chartContext.current.chart) {\n chartContext.current.chart.release();\n chartContext.current.chart = null;\n }\n }\n eventsBinded.current = null;\n isUnmount.current = true;\n };\n }, []);\n\n return (\n <RootChartContext.Provider value={chartContext.current}>\n <ViewContext.Provider value={view}>\n {toArray(props.children).map((child, index) => {\n if (typeof child === 'string') {\n return;\n }\n\n const childId = getComponentId(child, index);\n\n return (\n <React.Fragment key={childId}>\n {React.cloneElement(child as React.ReactElement<any, React.JSXElementConstructor<any>>, {\n updateId: updateId,\n componentId: childId\n })}\n </React.Fragment>\n );\n })}\n {tooltipNode}\n </ViewContext.Provider>\n </RootChartContext.Provider>\n );\n});\n\nexport const createChart = <T extends Props>(\n componentName: string,\n defaultProps?: Partial<T>,\n registers?: (() => void)[]\n) => {\n if (registers && registers.length && defaultProps.vchartConstrouctor) {\n defaultProps.vchartConstrouctor.useRegisters(registers);\n }\n\n const Com = withContainer<ContainerProps, T>(BaseChart as any, componentName, (props: T) => {\n if (defaultProps) {\n return Object.assign(props, defaultProps);\n }\n return props;\n });\n Com.displayName = componentName;\n return Com;\n};\n"]}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { IBoxPlotChartSpec } from '@visactor/vchart';
|
|
3
3
|
import { BaseChartProps } from './BaseChart';
|
|
4
|
-
export interface BoxPlotChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type'>, Omit<IBoxPlotChartSpec, 'type'> {
|
|
4
|
+
export interface BoxPlotChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>, Omit<IBoxPlotChartSpec, 'type'> {
|
|
5
5
|
}
|
|
6
6
|
export declare const BoxPlotChart: React.ForwardRefExoticComponent<BoxPlotChartProps & {
|
|
7
7
|
children?: React.ReactNode;
|
|
@@ -6,9 +6,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
|
|
7
7
|
const vchart_1 = require("@visactor/vchart"), BaseChart_1 = require("./BaseChart");
|
|
8
8
|
|
|
9
|
-
vchart_1.VChart.useRegisters([ vchart_1.registerBoxplotChart, vchart_1.registerCartesianLinearAxis, vchart_1.registerCartesianBandAxis, vchart_1.registerCartesianTimeAxis, vchart_1.registerCartesianLogAxis, vchart_1.registerDiscreteLegend, vchart_1.registerContinuousLegend, vchart_1.registerTooltip, vchart_1.registerDomTooltipHandler, vchart_1.registerCanvasTooltipHandler, vchart_1.registerCartesianCrossHair, vchart_1.registerDataZoom, vchart_1.registerScrollBar, vchart_1.registerLabel, vchart_1.registerTitle, vchart_1.registerMarkLine, vchart_1.registerMarkPoint, vchart_1.registerMarkArea, vchart_1.registerBrush, vchart_1.registerCustomMark ]),
|
|
10
9
|
exports.BoxPlotChart = (0, BaseChart_1.createChart)("BoxPlotChart", {
|
|
11
10
|
type: "boxPlot",
|
|
12
11
|
vchartConstrouctor: vchart_1.VChart
|
|
13
|
-
});
|
|
12
|
+
}, [ vchart_1.registerBoxplotChart, vchart_1.registerCartesianLinearAxis, vchart_1.registerCartesianBandAxis, vchart_1.registerCartesianTimeAxis, vchart_1.registerCartesianLogAxis, vchart_1.registerCartesianCrossHair, vchart_1.registerLabel ]);
|
|
14
13
|
//# sourceMappingURL=BoxPlotChart.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/charts/BoxPlotChart.tsx"],"names":[],"mappings":";;;AAEA,
|
|
1
|
+
{"version":3,"sources":["../src/charts/BoxPlotChart.tsx"],"names":[],"mappings":";;;AAEA,6CAS0B;AAC1B,2CAA0D;AAM7C,QAAA,YAAY,GAAG,IAAA,uBAAW,EACrC,cAAc,EACd;IACE,IAAI,EAAE,SAAS;IACf,kBAAkB,EAAE,eAA4B;CACjD,EACD;IACE,6BAAoB;IACpB,oCAA2B;IAC3B,kCAAyB;IACzB,kCAAyB;IACzB,iCAAwB;IACxB,mCAA0B;IAC1B,sBAAa;CACd,CACF,CAAC","file":"BoxPlotChart.js","sourcesContent":["import React from 'react';\nimport { IBoxPlotChartSpec, IVChartConstructor } from '@visactor/vchart';\nimport {\n VChart,\n registerBoxplotChart,\n registerCartesianLinearAxis,\n registerCartesianBandAxis,\n registerCartesianTimeAxis, // 非必选\n registerCartesianLogAxis, // 非必选\n registerCartesianCrossHair,\n registerLabel\n} from '@visactor/vchart';\nimport { BaseChartProps, createChart } from './BaseChart';\n\nexport interface BoxPlotChartProps\n extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>,\n Omit<IBoxPlotChartSpec, 'type'> {}\n\nexport const BoxPlotChart = createChart<React.PropsWithChildren<BoxPlotChartProps> & { type: 'boxPlot' }>(\n 'BoxPlotChart',\n {\n type: 'boxPlot',\n vchartConstrouctor: VChart as IVChartConstructor\n },\n [\n registerBoxplotChart,\n registerCartesianLinearAxis,\n registerCartesianBandAxis,\n registerCartesianTimeAxis, // 非必选\n registerCartesianLogAxis, // 非必选\n registerCartesianCrossHair,\n registerLabel\n ]\n);\n"]}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { ICirclePackingChartSpec } from '@visactor/vchart';
|
|
3
3
|
import { BaseChartProps } from './BaseChart';
|
|
4
|
-
export interface CirclePackingChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type'>, Omit<ICirclePackingChartSpec, 'type'> {
|
|
4
|
+
export interface CirclePackingChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>, Omit<ICirclePackingChartSpec, 'type'> {
|
|
5
5
|
}
|
|
6
6
|
export declare const CirclePackingChart: React.ForwardRefExoticComponent<CirclePackingChartProps & {
|
|
7
7
|
children?: React.ReactNode;
|
|
@@ -6,7 +6,6 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
|
|
7
7
|
const vchart_1 = require("@visactor/vchart"), BaseChart_1 = require("./BaseChart");
|
|
8
8
|
|
|
9
|
-
vchart_1.VChart.useRegisters([ vchart_1.registerCirclePackingChart, vchart_1.registerDiscreteLegend, vchart_1.registerContinuousLegend, vchart_1.registerTooltip, vchart_1.registerDomTooltipHandler, vchart_1.registerCanvasTooltipHandler, vchart_1.registerTitle, vchart_1.registerCustomMark ]),
|
|
10
9
|
exports.CirclePackingChart = (0, BaseChart_1.createChart)("CirclePackingChart", {
|
|
11
10
|
type: "circlePacking",
|
|
12
11
|
vchartConstrouctor: vchart_1.VChart
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/charts/CirclePackingChart.tsx"],"names":[],"mappings":";;;AAEA,
|
|
1
|
+
{"version":3,"sources":["../src/charts/CirclePackingChart.tsx"],"names":[],"mappings":";;;AAEA,6CAAsE;AACtE,2CAA0D;AAM7C,QAAA,kBAAkB,GAAG,IAAA,uBAAW,EAE3C,oBAAoB,EAAE;IACtB,IAAI,EAAE,eAAe;IACrB,kBAAkB,EAAE,eAA4B;CACjD,CAAC,CAAC","file":"CirclePackingChart.js","sourcesContent":["import React from 'react';\nimport { ICirclePackingChartSpec, IVChartConstructor } from '@visactor/vchart';\nimport { VChart, registerCirclePackingChart } from '@visactor/vchart';\nimport { BaseChartProps, createChart } from './BaseChart';\n\nexport interface CirclePackingChartProps\n extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>,\n Omit<ICirclePackingChartSpec, 'type'> {}\n\nexport const CirclePackingChart = createChart<\n React.PropsWithChildren<CirclePackingChartProps> & { type: 'circlePacking' }\n>('CirclePackingChart', {\n type: 'circlePacking',\n vchartConstrouctor: VChart as IVChartConstructor\n});\n"]}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { ICircularProgressChartSpec } from '@visactor/vchart';
|
|
3
3
|
import { BaseChartProps } from './BaseChart';
|
|
4
|
-
export interface CircularProgressChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type'>, Omit<ICircularProgressChartSpec, 'type'> {
|
|
4
|
+
export interface CircularProgressChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>, Omit<ICircularProgressChartSpec, 'type'> {
|
|
5
5
|
}
|
|
6
6
|
export declare const CircularProgressChart: React.ForwardRefExoticComponent<CircularProgressChartProps & {
|
|
7
7
|
children?: React.ReactNode;
|
|
@@ -6,9 +6,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
|
|
7
7
|
const vchart_1 = require("@visactor/vchart"), BaseChart_1 = require("./BaseChart");
|
|
8
8
|
|
|
9
|
-
vchart_1.VChart.useRegisters([ vchart_1.registerCircularProgressChart, vchart_1.registerPolarLinearAxis, vchart_1.registerPolarBandAxis, vchart_1.registerDiscreteLegend, vchart_1.registerContinuousLegend, vchart_1.registerTooltip, vchart_1.registerDomTooltipHandler, vchart_1.registerCanvasTooltipHandler, vchart_1.registerPolarCrossHair, vchart_1.registerLabel, vchart_1.registerTitle, vchart_1.registerCustomMark, vchart_1.registerIndicator ]),
|
|
10
9
|
exports.CircularProgressChart = (0, BaseChart_1.createChart)("CircularProgressChart", {
|
|
11
10
|
type: "circularProgress",
|
|
12
11
|
vchartConstrouctor: vchart_1.VChart
|
|
13
|
-
});
|
|
12
|
+
}, [ vchart_1.registerCircularProgressChart, vchart_1.registerPolarLinearAxis, vchart_1.registerPolarBandAxis, vchart_1.registerPolarCrossHair, vchart_1.registerLabel ]);
|
|
14
13
|
//# sourceMappingURL=CircularProgressChart.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/charts/CircularProgressChart.tsx"],"names":[],"mappings":";;;AAEA,
|
|
1
|
+
{"version":3,"sources":["../src/charts/CircularProgressChart.tsx"],"names":[],"mappings":";;;AAEA,6CAO0B;AAC1B,2CAA0D;AAM7C,QAAA,qBAAqB,GAAG,IAAA,uBAAW,EAG9C,uBAAuB,EACvB;IACE,IAAI,EAAE,kBAAkB;IACxB,kBAAkB,EAAE,eAA4B;CACjD,EACD;IACE,sCAA6B;IAC7B,gCAAuB;IACvB,8BAAqB;IACrB,+BAAsB;IACtB,sBAAa;CACd,CACF,CAAC","file":"CircularProgressChart.js","sourcesContent":["import React from 'react';\nimport { ICircularProgressChartSpec, IVChartConstructor } from '@visactor/vchart';\nimport {\n VChart,\n registerCircularProgressChart,\n registerPolarLinearAxis, // 必选\n registerPolarBandAxis, // 必选\n registerPolarCrossHair,\n registerLabel\n} from '@visactor/vchart';\nimport { BaseChartProps, createChart } from './BaseChart';\n\nexport interface CircularProgressChartProps\n extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>,\n Omit<ICircularProgressChartSpec, 'type'> {}\n\nexport const CircularProgressChart = createChart<\n React.PropsWithChildren<CircularProgressChartProps> & { type: 'circularProgress' }\n>(\n 'CircularProgressChart',\n {\n type: 'circularProgress',\n vchartConstrouctor: VChart as IVChartConstructor\n },\n [\n registerCircularProgressChart,\n registerPolarLinearAxis, // 必选\n registerPolarBandAxis, // 必选\n registerPolarCrossHair,\n registerLabel\n ]\n);\n"]}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { ICommonChartSpec } from '@visactor/vchart';
|
|
3
3
|
import { BaseChartProps } from './BaseChart';
|
|
4
|
-
export interface CommonChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type'>, Omit<ICommonChartSpec, 'type'> {
|
|
4
|
+
export interface CommonChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>, Omit<ICommonChartSpec, 'type'> {
|
|
5
5
|
}
|
|
6
6
|
export declare const CommonChart: React.ForwardRefExoticComponent<CommonChartProps & {
|
|
7
7
|
children?: React.ReactNode;
|
|
@@ -6,9 +6,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
|
|
7
7
|
const vchart_1 = require("@visactor/vchart"), BaseChart_1 = require("./BaseChart");
|
|
8
8
|
|
|
9
|
-
vchart_1.VChart.useRegisters([ vchart_1.registerCommonChart, vchart_1.registerCartesianLinearAxis, vchart_1.registerCartesianBandAxis, vchart_1.registerCartesianTimeAxis, vchart_1.registerCartesianLogAxis, vchart_1.registerDiscreteLegend, vchart_1.registerContinuousLegend, vchart_1.registerTooltip, vchart_1.registerDomTooltipHandler, vchart_1.registerCanvasTooltipHandler, vchart_1.registerCartesianCrossHair, vchart_1.registerDataZoom, vchart_1.registerScrollBar, vchart_1.registerLabel, vchart_1.registerTitle, vchart_1.registerMarkLine, vchart_1.registerMarkPoint, vchart_1.registerMarkArea, vchart_1.registerTotalLabel, vchart_1.registerBrush, vchart_1.registerCustomMark, vchart_1.registerAreaSeries, vchart_1.registerBarSeries, vchart_1.registerLineSeries, vchart_1.registerScatterSeries, vchart_1.registerPieSeries ]),
|
|
10
9
|
exports.CommonChart = (0, BaseChart_1.createChart)("CommonChart", {
|
|
11
10
|
type: "common",
|
|
12
11
|
vchartConstrouctor: vchart_1.VChart
|
|
13
|
-
});
|
|
12
|
+
}, [ vchart_1.registerCommonChart, vchart_1.registerCartesianLinearAxis, vchart_1.registerCartesianBandAxis, vchart_1.registerCartesianTimeAxis, vchart_1.registerCartesianLogAxis, vchart_1.registerCartesianCrossHair, vchart_1.registerLabel, vchart_1.registerTotalLabel, vchart_1.registerAreaSeries, vchart_1.registerBarSeries, vchart_1.registerLineSeries, vchart_1.registerScatterSeries, vchart_1.registerPieSeries ]);
|
|
14
13
|
//# sourceMappingURL=CommonChart.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/charts/CommonChart.tsx"],"names":[],"mappings":";;;AAEA,
|
|
1
|
+
{"version":3,"sources":["../src/charts/CommonChart.tsx"],"names":[],"mappings":";;;AAEA,6CAe0B;AAC1B,2CAA0D;AAM7C,QAAA,WAAW,GAAG,IAAA,uBAAW,EACpC,aAAa,EACb;IACE,IAAI,EAAE,QAAQ;IACd,kBAAkB,EAAE,eAA4B;CACjD,EACD;IACE,4BAAmB;IACnB,oCAA2B;IAC3B,kCAAyB;IACzB,kCAAyB;IACzB,iCAAwB;IACxB,mCAA0B;IAE1B,sBAAa;IACb,2BAAkB;IAElB,2BAAkB;IAClB,0BAAiB;IACjB,2BAAkB;IAClB,8BAAqB;IACrB,0BAAiB;CAClB,CACF,CAAC","file":"CommonChart.js","sourcesContent":["import React from 'react';\nimport { ICommonChartSpec, IVChartConstructor } from '@visactor/vchart';\nimport {\n VChart,\n registerCommonChart,\n registerCartesianLinearAxis,\n registerCartesianBandAxis,\n registerCartesianTimeAxis, // 非必选\n registerCartesianLogAxis, // 非必选\n registerCartesianCrossHair,\n registerLabel,\n registerTotalLabel,\n registerAreaSeries,\n registerBarSeries,\n registerLineSeries,\n registerScatterSeries,\n registerPieSeries\n} from '@visactor/vchart';\nimport { BaseChartProps, createChart } from './BaseChart';\n\nexport interface CommonChartProps\n extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>,\n Omit<ICommonChartSpec, 'type'> {}\n\nexport const CommonChart = createChart<React.PropsWithChildren<CommonChartProps> & { type: 'common' }>(\n 'CommonChart',\n {\n type: 'common',\n vchartConstrouctor: VChart as IVChartConstructor\n },\n [\n registerCommonChart,\n registerCartesianLinearAxis,\n registerCartesianBandAxis,\n registerCartesianTimeAxis, // 非必选\n registerCartesianLogAxis, // 非必选\n registerCartesianCrossHair,\n\n registerLabel,\n registerTotalLabel,\n\n registerAreaSeries,\n registerBarSeries,\n registerLineSeries,\n registerScatterSeries,\n registerPieSeries\n ]\n);\n"]}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { ICorrelationChartSpec } from '@visactor/vchart';
|
|
3
3
|
import { BaseChartProps } from './BaseChart';
|
|
4
|
-
export interface CorrelationChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type'>, Omit<ICorrelationChartSpec, 'type'> {
|
|
4
|
+
export interface CorrelationChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>, Omit<ICorrelationChartSpec, 'type'> {
|
|
5
5
|
}
|
|
6
6
|
export declare const CorrelationChart: React.ForwardRefExoticComponent<CorrelationChartProps & {
|
|
7
7
|
children?: React.ReactNode;
|
|
@@ -6,9 +6,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
|
|
7
7
|
const vchart_1 = require("@visactor/vchart"), BaseChart_1 = require("./BaseChart");
|
|
8
8
|
|
|
9
|
-
vchart_1.VChart.useRegisters([ vchart_1.registerCorrelationChart, vchart_1.registerDiscreteLegend, vchart_1.registerContinuousLegend, vchart_1.registerTooltip, vchart_1.registerDomTooltipHandler, vchart_1.registerCanvasTooltipHandler, vchart_1.registerTitle, vchart_1.registerCustomMark ]),
|
|
10
9
|
exports.CorrelationChart = (0, BaseChart_1.createChart)("CorrelationChart", {
|
|
11
10
|
type: "correlation",
|
|
12
11
|
vchartConstrouctor: vchart_1.VChart
|
|
13
|
-
});
|
|
12
|
+
}, [ vchart_1.registerCorrelationChart ]);
|
|
14
13
|
//# sourceMappingURL=CorrelationChart.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/charts/CorrelationChart.tsx"],"names":[],"mappings":";;;AAEA,
|
|
1
|
+
{"version":3,"sources":["../src/charts/CorrelationChart.tsx"],"names":[],"mappings":";;;AAEA,6CAAoE;AACpE,2CAA0D;AAM7C,QAAA,gBAAgB,GAAG,IAAA,uBAAW,EACzC,kBAAkB,EAClB;IACE,IAAI,EAAE,aAAa;IACnB,kBAAkB,EAAE,eAA4B;CACjD,EACD,CAAC,iCAAwB,CAAC,CAC3B,CAAC","file":"CorrelationChart.js","sourcesContent":["import React from 'react';\nimport { ICorrelationChartSpec, IVChartConstructor } from '@visactor/vchart';\nimport { VChart, registerCorrelationChart } from '@visactor/vchart';\nimport { BaseChartProps, createChart } from './BaseChart';\n\nexport interface CorrelationChartProps\n extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>,\n Omit<ICorrelationChartSpec, 'type'> {}\n\nexport const CorrelationChart = createChart<React.PropsWithChildren<CorrelationChartProps> & { type: 'correlation' }>(\n 'CorrelationChart',\n {\n type: 'correlation',\n vchartConstrouctor: VChart as IVChartConstructor\n },\n [registerCorrelationChart]\n);\n"]}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { IFunnel3dChartSpec } from '@visactor/vchart';
|
|
3
|
+
import { BaseChartProps } from './BaseChart';
|
|
4
|
+
export interface Funnel3dChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>, Omit<IFunnel3dChartSpec, 'type'> {
|
|
5
|
+
}
|
|
6
|
+
export declare const Funnel3dChart: React.ForwardRefExoticComponent<Funnel3dChartProps & {
|
|
7
|
+
children?: React.ReactNode;
|
|
8
|
+
} & {
|
|
9
|
+
type: 'funnel3d';
|
|
10
|
+
} & import("../containers/withContainer").ContainerProps & React.RefAttributes<any>>;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: !0
|
|
5
|
+
}), exports.Funnel3dChart = void 0;
|
|
6
|
+
|
|
7
|
+
const vchart_1 = require("@visactor/vchart"), BaseChart_1 = require("./BaseChart");
|
|
8
|
+
|
|
9
|
+
exports.Funnel3dChart = (0, BaseChart_1.createChart)("Funnel3dChart", {
|
|
10
|
+
type: "funnel3d",
|
|
11
|
+
vchartConstrouctor: vchart_1.VChart
|
|
12
|
+
}, [ vchart_1.registerFunnel3dChart, vchart_1.registerLabel ]);
|
|
13
|
+
//# sourceMappingURL=Funnel3dChart.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/charts/Funnel3dChart.tsx"],"names":[],"mappings":";;;AAEA,6CAAgF;AAChF,2CAA0D;AAM7C,QAAA,aAAa,GAAG,IAAA,uBAAW,EACtC,eAAe,EACf;IACE,IAAI,EAAE,UAAU;IAChB,kBAAkB,EAAE,eAA4B;CACjD,EACD,CAAC,8BAAqB,EAAE,sBAAa,CAAC,CACvC,CAAC","file":"Funnel3dChart.js","sourcesContent":["import React from 'react';\nimport { IFunnel3dChartSpec, IVChartConstructor } from '@visactor/vchart';\nimport { VChart, registerFunnel3dChart, registerLabel } from '@visactor/vchart';\nimport { BaseChartProps, createChart } from './BaseChart';\n\nexport interface Funnel3dChartProps\n extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>,\n Omit<IFunnel3dChartSpec, 'type'> {}\n\nexport const Funnel3dChart = createChart<React.PropsWithChildren<Funnel3dChartProps> & { type: 'funnel3d' }>(\n 'Funnel3dChart',\n {\n type: 'funnel3d',\n vchartConstrouctor: VChart as IVChartConstructor\n },\n [registerFunnel3dChart, registerLabel]\n);\n"]}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { IFunnelChartSpec } from '@visactor/vchart';
|
|
3
3
|
import { BaseChartProps } from './BaseChart';
|
|
4
|
-
export interface FunnelChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type'>, Omit<IFunnelChartSpec, 'type'> {
|
|
4
|
+
export interface FunnelChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>, Omit<IFunnelChartSpec, 'type'> {
|
|
5
5
|
}
|
|
6
6
|
export declare const FunnelChart: React.ForwardRefExoticComponent<FunnelChartProps & {
|
|
7
7
|
children?: React.ReactNode;
|
|
@@ -6,9 +6,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
|
|
7
7
|
const vchart_1 = require("@visactor/vchart"), BaseChart_1 = require("./BaseChart");
|
|
8
8
|
|
|
9
|
-
vchart_1.VChart.useRegisters([ vchart_1.registerFunnelChart, vchart_1.registerDiscreteLegend, vchart_1.registerContinuousLegend, vchart_1.registerTooltip, vchart_1.registerDomTooltipHandler, vchart_1.registerCanvasTooltipHandler, vchart_1.registerLabel, vchart_1.registerTitle, vchart_1.registerCustomMark ]),
|
|
10
9
|
exports.FunnelChart = (0, BaseChart_1.createChart)("FunnelChart", {
|
|
11
10
|
type: "funnel",
|
|
12
11
|
vchartConstrouctor: vchart_1.VChart
|
|
13
|
-
});
|
|
14
|
-
//# sourceMappingURL=FunnelChart.js.map
|
|
12
|
+
}, [ vchart_1.registerFunnelChart, vchart_1.registerLabel ]);
|
|
13
|
+
//# sourceMappingURL=FunnelChart.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/charts/FunnelChart.tsx"],"names":[],"mappings":";;;AAEA,
|
|
1
|
+
{"version":3,"sources":["../src/charts/FunnelChart.tsx"],"names":[],"mappings":";;;AAEA,6CAA8E;AAC9E,2CAA0D;AAM7C,QAAA,WAAW,GAAG,IAAA,uBAAW,EACpC,aAAa,EACb;IACE,IAAI,EAAE,QAAQ;IACd,kBAAkB,EAAE,eAA4B;CACjD,EACD,CAAC,4BAAmB,EAAE,sBAAa,CAAC,CACrC,CAAC","file":"FunnelChart.js","sourcesContent":["import React from 'react';\nimport { IFunnelChartSpec, IVChartConstructor } from '@visactor/vchart';\nimport { VChart, registerFunnelChart, registerLabel } from '@visactor/vchart';\nimport { BaseChartProps, createChart } from './BaseChart';\n\nexport interface FunnelChartProps\n extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>,\n Omit<IFunnelChartSpec, 'type'> {}\n\nexport const FunnelChart = createChart<React.PropsWithChildren<FunnelChartProps> & { type: 'funnel' }>(\n 'FunnelChart',\n {\n type: 'funnel',\n vchartConstrouctor: VChart as IVChartConstructor\n },\n [registerFunnelChart, registerLabel]\n);\n"]}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type {
|
|
2
|
+
import type { IGaugeChartSpec } from '@visactor/vchart';
|
|
3
3
|
import { BaseChartProps } from './BaseChart';
|
|
4
|
-
export interface
|
|
4
|
+
export interface GaugeChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>, Omit<IGaugeChartSpec, 'type'> {
|
|
5
5
|
}
|
|
6
|
-
export declare const
|
|
6
|
+
export declare const GaugeChart: React.ForwardRefExoticComponent<GaugeChartProps & {
|
|
7
7
|
children?: React.ReactNode;
|
|
8
8
|
} & {
|
|
9
|
-
type: '
|
|
9
|
+
type: 'gauge';
|
|
10
10
|
} & import("../containers/withContainer").ContainerProps & React.RefAttributes<any>>;
|
package/cjs/charts/GaugeChart.js
CHANGED
|
@@ -2,13 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: !0
|
|
5
|
-
}), exports.
|
|
5
|
+
}), exports.GaugeChart = void 0;
|
|
6
6
|
|
|
7
7
|
const vchart_1 = require("@visactor/vchart"), BaseChart_1 = require("./BaseChart");
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
type: "sankey",
|
|
9
|
+
exports.GaugeChart = (0, BaseChart_1.createChart)("GaugeChart", {
|
|
10
|
+
type: "gauge",
|
|
12
11
|
vchartConstrouctor: vchart_1.VChart
|
|
13
|
-
});
|
|
14
|
-
//# sourceMappingURL=GaugeChart.js.map
|
|
12
|
+
}, [ vchart_1.registerGaugeChart ]);
|
|
13
|
+
//# sourceMappingURL=GaugeChart.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/charts/GaugeChart.tsx"],"names":[],"mappings":";;;AAEA,
|
|
1
|
+
{"version":3,"sources":["../src/charts/GaugeChart.tsx"],"names":[],"mappings":";;;AAEA,6CAA8D;AAC9D,2CAA0D;AAM7C,QAAA,UAAU,GAAG,IAAA,uBAAW,EACnC,YAAY,EACZ;IACE,IAAI,EAAE,OAAO;IACb,kBAAkB,EAAE,eAA4B;CACjD,EACD,CAAC,2BAAkB,CAAC,CACrB,CAAC","file":"GaugeChart.js","sourcesContent":["import React from 'react';\nimport type { IGaugeChartSpec, IVChartConstructor } from '@visactor/vchart';\nimport { VChart, registerGaugeChart } from '@visactor/vchart';\nimport { BaseChartProps, createChart } from './BaseChart';\n\nexport interface GaugeChartProps\n extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>,\n Omit<IGaugeChartSpec, 'type'> {}\n\nexport const GaugeChart = createChart<React.PropsWithChildren<GaugeChartProps> & { type: 'gauge' }>(\n 'GaugeChart',\n {\n type: 'gauge',\n vchartConstrouctor: VChart as IVChartConstructor\n },\n [registerGaugeChart]\n);\n"]}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { IHeatmapChartSpec } from '@visactor/vchart';
|
|
3
3
|
import { BaseChartProps } from './BaseChart';
|
|
4
|
-
export interface HeatmapChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type'>, Omit<IHeatmapChartSpec, 'type'> {
|
|
4
|
+
export interface HeatmapChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>, Omit<IHeatmapChartSpec, 'type'> {
|
|
5
5
|
}
|
|
6
6
|
export declare const HeatmapChart: React.ForwardRefExoticComponent<HeatmapChartProps & {
|
|
7
7
|
children?: React.ReactNode;
|
|
@@ -6,9 +6,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
|
|
7
7
|
const vchart_1 = require("@visactor/vchart"), BaseChart_1 = require("./BaseChart");
|
|
8
8
|
|
|
9
|
-
vchart_1.VChart.useRegisters([ vchart_1.registerHeatmapChart, vchart_1.registerCartesianBandAxis, vchart_1.registerDiscreteLegend, vchart_1.registerContinuousLegend, vchart_1.registerTooltip, vchart_1.registerDomTooltipHandler, vchart_1.registerCanvasTooltipHandler, vchart_1.registerCartesianCrossHair, vchart_1.registerDataZoom, vchart_1.registerScrollBar, vchart_1.registerLabel, vchart_1.registerTitle, vchart_1.registerMarkLine, vchart_1.registerMarkPoint, vchart_1.registerMarkArea, vchart_1.registerTotalLabel, vchart_1.registerBrush, vchart_1.registerCustomMark ]),
|
|
10
9
|
exports.HeatmapChart = (0, BaseChart_1.createChart)("HeatmapChart", {
|
|
11
10
|
type: "heatmap",
|
|
12
11
|
vchartConstrouctor: vchart_1.VChart
|
|
13
|
-
});
|
|
14
|
-
//# sourceMappingURL=HeatmapChart.js.map
|
|
12
|
+
}, [ vchart_1.registerHeatmapChart, vchart_1.registerCartesianBandAxis, vchart_1.registerCartesianCrossHair, vchart_1.registerLabel ]);
|
|
13
|
+
//# sourceMappingURL=HeatmapChart.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/charts/HeatmapChart.tsx"],"names":[],"mappings":";;;AAEA,
|
|
1
|
+
{"version":3,"sources":["../src/charts/HeatmapChart.tsx"],"names":[],"mappings":";;;AAEA,6CAM0B;AAC1B,2CAA0D;AAQ7C,QAAA,YAAY,GAAG,IAAA,uBAAW,EACrC,cAAc,EACd;IACE,IAAI,EAAE,SAAS;IACf,kBAAkB,EAAE,eAA4B;CACjD,EACD,CAAC,6BAAoB,EAAE,kCAAyB,EAAE,mCAA0B,EAAE,sBAAa,CAAC,CAC7F,CAAC","file":"HeatmapChart.js","sourcesContent":["import React from 'react';\nimport type { IHeatmapChartSpec, IVChartConstructor } from '@visactor/vchart';\nimport {\n VChart,\n registerHeatmapChart,\n registerCartesianBandAxis,\n registerCartesianCrossHair,\n registerLabel\n} from '@visactor/vchart';\nimport { BaseChartProps, createChart } from './BaseChart';\n\nexport interface HeatmapChartProps\n extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>,\n Omit<IHeatmapChartSpec, 'type'> {\n //\n}\n\nexport const HeatmapChart = createChart<React.PropsWithChildren<HeatmapChartProps> & { type: 'heatmap' }>(\n 'HeatmapChart',\n {\n type: 'heatmap',\n vchartConstrouctor: VChart as IVChartConstructor\n },\n [registerHeatmapChart, registerCartesianBandAxis, registerCartesianCrossHair, registerLabel]\n);\n"]}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { IHistogram3dChartSpec } from '@visactor/vchart';
|
|
3
|
+
import { BaseChartProps } from './BaseChart';
|
|
4
|
+
export interface Histogram3dChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>, Omit<IHistogram3dChartSpec, 'type'> {
|
|
5
|
+
}
|
|
6
|
+
export declare const Histogram3dChart: React.ForwardRefExoticComponent<Histogram3dChartProps & {
|
|
7
|
+
children?: React.ReactNode;
|
|
8
|
+
} & {
|
|
9
|
+
type: 'histogram3d';
|
|
10
|
+
} & import("../containers/withContainer").ContainerProps & React.RefAttributes<any>>;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: !0
|
|
5
|
+
}), exports.Histogram3dChart = void 0;
|
|
6
|
+
|
|
7
|
+
const vchart_1 = require("@visactor/vchart"), BaseChart_1 = require("./BaseChart");
|
|
8
|
+
|
|
9
|
+
exports.Histogram3dChart = (0, BaseChart_1.createChart)("Histogram3dChart", {
|
|
10
|
+
type: "histogram3d",
|
|
11
|
+
vchartConstrouctor: vchart_1.VChart
|
|
12
|
+
}, [ vchart_1.registerHistogram3dChart, vchart_1.registerCartesianLinearAxis, vchart_1.registerCartesianBandAxis, vchart_1.registerCartesianTimeAxis, vchart_1.registerCartesianLogAxis, vchart_1.registerCartesianCrossHair, vchart_1.registerLabel ]);
|
|
13
|
+
//# sourceMappingURL=Histogram3dChart.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/charts/Histogram3dChart.tsx"],"names":[],"mappings":";;;AAEA,6CAS0B;AAC1B,2CAA0D;AAM7C,QAAA,gBAAgB,GAAG,IAAA,uBAAW,EACzC,kBAAkB,EAClB;IACE,IAAI,EAAE,aAAa;IACnB,kBAAkB,EAAE,eAA4B;CACjD,EACD;IACE,iCAAwB;IACxB,oCAA2B;IAC3B,kCAAyB;IACzB,kCAAyB;IACzB,iCAAwB;IACxB,mCAA0B;IAC1B,sBAAa;CACd,CACF,CAAC","file":"Histogram3dChart.js","sourcesContent":["import React from 'react';\nimport { IHistogram3dChartSpec, IVChartConstructor } from '@visactor/vchart';\nimport {\n VChart,\n registerHistogram3dChart,\n registerCartesianLinearAxis,\n registerCartesianBandAxis,\n registerCartesianTimeAxis, // 非必选\n registerCartesianLogAxis, // 非必选\n registerCartesianCrossHair,\n registerLabel\n} from '@visactor/vchart';\nimport { BaseChartProps, createChart } from './BaseChart';\n\nexport interface Histogram3dChartProps\n extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>,\n Omit<IHistogram3dChartSpec, 'type'> {}\n\nexport const Histogram3dChart = createChart<React.PropsWithChildren<Histogram3dChartProps> & { type: 'histogram3d' }>(\n 'Histogram3dChart',\n {\n type: 'histogram3d',\n vchartConstrouctor: VChart as IVChartConstructor\n },\n [\n registerHistogram3dChart,\n registerCartesianLinearAxis,\n registerCartesianBandAxis,\n registerCartesianTimeAxis, // 非必选\n registerCartesianLogAxis, // 非必选\n registerCartesianCrossHair,\n registerLabel\n ]\n);\n"]}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { IHistogramChartSpec } from '@visactor/vchart';
|
|
3
3
|
import { BaseChartProps } from './BaseChart';
|
|
4
|
-
export interface HistogramChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type'>, Omit<IHistogramChartSpec, 'type'> {
|
|
4
|
+
export interface HistogramChartProps extends Omit<BaseChartProps, 'spec' | 'container' | 'type' | 'data'>, Omit<IHistogramChartSpec, 'type'> {
|
|
5
5
|
}
|
|
6
6
|
export declare const HistogramChart: React.ForwardRefExoticComponent<HistogramChartProps & {
|
|
7
7
|
children?: React.ReactNode;
|
|
@@ -6,9 +6,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
|
|
7
7
|
const vchart_1 = require("@visactor/vchart"), BaseChart_1 = require("./BaseChart");
|
|
8
8
|
|
|
9
|
-
vchart_1.VChart.useRegisters([ vchart_1.registerHistogramChart, vchart_1.registerCartesianLinearAxis, vchart_1.registerCartesianBandAxis, vchart_1.registerCartesianTimeAxis, vchart_1.registerCartesianLogAxis, vchart_1.registerDiscreteLegend, vchart_1.registerContinuousLegend, vchart_1.registerTooltip, vchart_1.registerDomTooltipHandler, vchart_1.registerCanvasTooltipHandler, vchart_1.registerCartesianCrossHair, vchart_1.registerDataZoom, vchart_1.registerScrollBar, vchart_1.registerLabel, vchart_1.registerTitle, vchart_1.registerMarkLine, vchart_1.registerMarkPoint, vchart_1.registerMarkArea, vchart_1.registerBrush, vchart_1.registerCustomMark ]),
|
|
10
9
|
exports.HistogramChart = (0, BaseChart_1.createChart)("HistogramChart", {
|
|
11
10
|
type: "histogram",
|
|
12
11
|
vchartConstrouctor: vchart_1.VChart
|
|
13
|
-
});
|
|
14
|
-
//# sourceMappingURL=HistogramChart.js.map
|
|
12
|
+
}, [ vchart_1.registerHistogramChart, vchart_1.registerCartesianLinearAxis, vchart_1.registerCartesianBandAxis, vchart_1.registerCartesianTimeAxis, vchart_1.registerCartesianLogAxis, vchart_1.registerCartesianCrossHair, vchart_1.registerLabel ]);
|