File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -2517,7 +2517,8 @@ function calculateReservedMargins(margins) {
25172517
25182518function plotAutoSize ( gd , aobj ) {
25192519 var fullLayout = gd . _fullLayout ,
2520- context = gd . _context ;
2520+ context = gd . _context ,
2521+ computedStyle ;
25212522
25222523 var newHeight , newWidth ;
25232524
@@ -2548,8 +2549,9 @@ function plotAutoSize(gd, aobj) {
25482549 // provide height and width for the container div,
25492550 // specify size in layout, or take the defaults,
25502551 // 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 ;
25532555 }
25542556
25552557 if ( Math . abs ( fullLayout . width - newWidth ) > 1 ||
You can’t perform that action at this time.
0 commit comments