Skip to content

Commit

Permalink
make sure that superimposed pts are in 'closest' hover data:
Browse files Browse the repository at this point in the history
- so that superimposed trace hover data can skip over 'hoverinfo'
  traces upon hover label creation.
  • Loading branch information
etpinard committed May 2, 2016
1 parent d87fc35 commit 3d99880
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/plots/cartesian/graph_interact.js
Original file line number Diff line number Diff line change
Expand Up @@ -618,7 +618,7 @@ fx.getClosest = function(cd, distfn, pointData) {
// do this for 'closest'
for(var i=0; i<cd.length; i++) {
var newDistance = distfn(cd[i]);
if(newDistance < pointData.distance) {
if(newDistance <= pointData.distance) {
pointData.index = i;
pointData.distance = newDistance;
}
Expand Down

0 comments on commit 3d99880

Please sign in to comment.