File tree 1 file changed +5
-3
lines changed
Filter options
1 file changed +5
-3
lines changed
Original file line number Diff line number Diff line change @@ -2517,7 +2517,8 @@ function calculateReservedMargins(margins) {
2517
2517
2518
2518
function plotAutoSize ( gd , aobj ) {
2519
2519
var fullLayout = gd . _fullLayout ,
2520
- context = gd . _context ;
2520
+ context = gd . _context
2521
+ computedStyle ;
2521
2522
2522
2523
var newHeight , newWidth ;
2523
2524
@@ -2548,8 +2549,9 @@ function plotAutoSize(gd, aobj) {
2548
2549
// provide height and width for the container div,
2549
2550
// specify size in layout, or take the defaults,
2550
2551
// but don't enforce any ratio restrictions
2551
- newHeight = parseFloat ( window . getComputedStyle ( gd ) . height ) || fullLayout . height ;
2552
- newWidth = parseFloat ( window . getComputedStyle ( gd ) . width ) || fullLayout . width ;
2552
+ computedStyle = window . getComputedStyle ( gd ) ;
2553
+ newHeight = parseFloat ( computedStyle . height ) || fullLayout . height ;
2554
+ newWidth = parseFloat ( computedStyle . width ) || fullLayout . width ;
2553
2555
}
2554
2556
2555
2557
if ( Math . abs ( fullLayout . width - newWidth ) > 1 ||
You can’t perform that action at this time.
0 commit comments