File tree 1 file changed +9
-4
lines changed
1 file changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -307,21 +307,26 @@ module.exports = function draw(gd) {
307
307
return ;
308
308
309
309
function positionScrollBar ( legendHeight ) {
310
+ // increase the background and clip-path width
311
+ // by the scrollbar width and margin
310
312
bg . attr ( {
311
313
width : opts . width -
312
314
2 * opts . borderwidth +
313
- constants . scrollBarWidth
315
+ constants . scrollBarWidth +
316
+ constants . scrollBarMargin
314
317
} ) ;
315
318
316
319
clipPath . select ( 'rect' ) . attr ( {
317
- width : opts . width + constants . scrollBarWidth
320
+ width : opts . width +
321
+ constants . scrollBarWidth +
322
+ constants . scrollBarMargin
318
323
} ) ;
319
324
320
325
if ( gd . firstRender ) {
321
326
// Move scrollbar to starting position
322
327
scrollBar . call (
323
328
Drawing . setRect ,
324
- opts . width - constants . scrollBarMargin ,
329
+ opts . width ,
325
330
constants . scrollBarMargin ,
326
331
constants . scrollBarWidth ,
327
332
constants . scrollBarHeight
@@ -373,7 +378,7 @@ module.exports = function draw(gd) {
373
378
scrollBox . attr ( 'transform' , 'translate(0, ' + scrollBoxY + ')' ) ;
374
379
scrollBar . call (
375
380
Drawing . setRect ,
376
- opts . width - constants . scrollBarMargin ,
381
+ opts . width ,
377
382
scrollBarY ,
378
383
constants . scrollBarWidth ,
379
384
constants . scrollBarHeight
You can’t perform that action at this time.
0 commit comments