Turning off Voronoi point path creation, if using the new interactive

guideline and tooltip.

Turns out, Voronoi is not needed in this new interactive mode!
master
Robin Hu 11 years ago
parent 93a26c53c9
commit 1eb01d703d

@ -625,7 +625,7 @@ nv.models.cumulativeLineChart = function() {
chart.yAxis = yAxis;
chart.interactiveLayer = interactiveLayer;
d3.rebind(chart, lines, 'defined', 'isArea', 'x', 'y', 'xScale','yScale', 'size', 'xDomain', 'yDomain', 'forceX', 'forceY', 'interactive', 'clipEdge', 'clipVoronoi', 'id');
d3.rebind(chart, lines, 'defined', 'isArea', 'x', 'y', 'xScale','yScale', 'size', 'xDomain', 'yDomain', 'forceX', 'forceY', 'interactive', 'clipEdge', 'clipVoronoi','useVoronoi', 'id');
chart.margin = function(_) {
if (!arguments.length) return margin;
@ -671,7 +671,8 @@ nv.models.cumulativeLineChart = function() {
if(!arguments.length) return useInteractiveGuideline;
useInteractiveGuideline = _;
if (_ === true) {
lines.interactive(false);
chart.interactive(false);
chart.useVoronoi(false);
}
return chart;
};

@ -417,7 +417,8 @@ nv.models.lineChart = function() {
if(!arguments.length) return useInteractiveGuideline;
useInteractiveGuideline = _;
if (_ === true) {
lines.interactive(false);
chart.interactive(false);
chart.useVoronoi(false);
}
return chart;
};

@ -250,7 +250,7 @@ nv.models.stackedArea = function() {
chart.dispatch = dispatch;
chart.scatter = scatter;
d3.rebind(chart, scatter, 'interactive', 'size', 'xScale', 'yScale', 'zScale', 'xDomain', 'yDomain', 'sizeDomain', 'forceX', 'forceY', 'forceSize', 'clipVoronoi', 'clipRadius');
d3.rebind(chart, scatter, 'interactive', 'size', 'xScale', 'yScale', 'zScale', 'xDomain', 'yDomain', 'sizeDomain', 'forceX', 'forceY', 'forceSize', 'clipVoronoi', 'useVoronoi','clipRadius');
chart.x = function(_) {
if (!arguments.length) return getX;

@ -458,7 +458,7 @@ nv.models.stackedAreaChart = function() {
chart.yAxis = yAxis;
chart.interactiveLayer = interactiveLayer;
d3.rebind(chart, stacked, 'x', 'y', 'size', 'xScale', 'yScale', 'xDomain', 'yDomain', 'sizeDomain', 'interactive', 'offset', 'order', 'style', 'clipEdge', 'forceX', 'forceY', 'forceSize', 'interpolate');
d3.rebind(chart, stacked, 'x', 'y', 'size', 'xScale', 'yScale', 'xDomain', 'yDomain', 'sizeDomain', 'interactive', 'useVoronoi', 'offset', 'order', 'style', 'clipEdge', 'forceX', 'forceY', 'forceSize', 'interpolate');
chart.margin = function(_) {
if (!arguments.length) return margin;
@ -524,7 +524,8 @@ nv.models.stackedAreaChart = function() {
if(!arguments.length) return useInteractiveGuideline;
useInteractiveGuideline = _;
if (_ === true) {
stacked.interactive(false);
chart.interactive(false);
chart.useVoronoi(false);
}
return chart;
};

Loading…
Cancel
Save