Skip to content

Commit 0426b61

Browse files
committed
lint in legend.draw
1 parent 24b2912 commit 0426b61

File tree

1 file changed

+9
-8
lines changed

1 file changed

+9
-8
lines changed

src/components/legend/draw.js

+9-8
Original file line numberDiff line numberDiff line change
@@ -341,12 +341,13 @@ module.exports = function draw(gd) {
341341
}
342342
},
343343
clickFn: function(numClicks, e) {
344-
var clickedTrace =
345-
fullLayout._infolayer.selectAll('g.traces').filter(function() {
346-
var bbox = this.getBoundingClientRect();
347-
return (e.clientX >= bbox.left && e.clientX <= bbox.right &&
348-
e.clientY >= bbox.top && e.clientY <= bbox.bottom);
349-
});
344+
var clickedTrace = fullLayout._infolayer.selectAll('g.traces').filter(function() {
345+
var bbox = this.getBoundingClientRect();
346+
return (
347+
e.clientX >= bbox.left && e.clientX <= bbox.right &&
348+
e.clientY >= bbox.top && e.clientY <= bbox.bottom
349+
);
350+
});
350351
if(clickedTrace.size() > 0) {
351352
clickOrDoubleClick(gd, legend, clickedTrace, numClicks, e);
352353
}
@@ -673,8 +674,8 @@ function computeLegendDimensions(gd, groups, traces) {
673674
opts._height = Math.ceil(opts._height);
674675

675676
traces.each(function(d) {
676-
var legendItem = d[0],
677-
bg = d3.select(this).select('.legendtoggle');
677+
var legendItem = d[0];
678+
var bg = d3.select(this).select('.legendtoggle');
678679

679680
Drawing.setRect(bg,
680681
0,

0 commit comments

Comments
 (0)