Skip to content

Commit ff92f21

Browse files
committed
Add box-sizing to legend background
1 parent a170ec7 commit ff92f21

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/components/legend/index.js

+4-1
Original file line numberDiff line numberDiff line change
@@ -460,7 +460,10 @@ legend.draw = function(td) {
460460
.attr('class','bg')
461461
.call(Color.stroke, opts.bordercolor)
462462
.call(Color.fill, opts.bgcolor)
463-
.style('stroke-width', opts.borderwidth + 'px');
463+
.style({
464+
'stroke-width': opts.borderwidth + 'px',
465+
'box-sizing': 'border-box'
466+
});
464467

465468
var scrollBox = legendsvg.selectAll('g.scrollbox')
466469
.data([0]);

0 commit comments

Comments
 (0)