Skip to content

Commit 29cf98f

Browse files
committed
fix to set scaleanchorDflt and constrainDflt to undefined when no image is present
1 parent 31dbc8e commit 29cf98f

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

Diff for: src/plots/cartesian/layout_defaults.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -305,12 +305,13 @@ module.exports = function supplyLayoutDefaults(layoutIn, layoutOut, fullData) {
305305
var scaleanchorDflt;
306306
if(axLetter === 'y' && !axLayoutIn.hasOwnProperty('scaleanchor') && axHasImage[axName]) {
307307
scaleanchorDflt = axLayoutOut.anchor;
308-
}
308+
} else {scaleanchorDflt = undefined;}
309309

310310
var constrainDflt;
311311
if(!axLayoutIn.hasOwnProperty('constrain') && axHasImage[axName]) {
312312
constrainDflt = 'domain';
313-
}
313+
} else {constrainDflt = undefined;}
314+
314315
handleConstraintDefaults(axLayoutIn, axLayoutOut, coerce, {
315316
allAxisIds: allAxisIds,
316317
layoutOut: layoutOut,

0 commit comments

Comments
 (0)