Skip to content

Commit 122723f

Browse files
committed
Switch calculation to max instead of sum
1 parent 3c70b49 commit 122723f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/plots/plots.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2049,7 +2049,7 @@ plots.doAutoMargin = function(gd) {
20492049
for(var m in pushMargin) {
20502050
if(m !== 'base') {
20512051
if(isNumeric(pushMargin[m][s].size)) {
2052-
autoMarginPush += pushMargin[m][s].size;
2052+
autoMarginPush = pushMargin[m][s].size > autoMarginPush ? pushMargin[m][s].size : autoMarginPush;
20532053
}
20542054
}
20552055
}

0 commit comments

Comments
 (0)