Skip to content

Commit 262141b

Browse files
Sync overlayed axis when main axis redraw
1 parent bb3e7ae commit 262141b

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

src/plots/cartesian/axes.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2291,6 +2291,17 @@ axes.draw = function(gd, arg, opts) {
22912291
fullLayout._infolayer.select('.g-' + ya._id + 'title').remove();
22922292
}
22932293
});
2294+
} else if(arg && arg.length === 1) {
2295+
fullLayout._paper.selectAll('g.subplot').each(function(d) {
2296+
var id = d[0];
2297+
var plotinfo = fullLayout._plots[id];
2298+
if(plotinfo) {
2299+
var ya = plotinfo.yaxis;
2300+
if(ya.overlaying === arg[0]) {
2301+
arg.push(ya._id);
2302+
}
2303+
}
2304+
});
22942305
}
22952306

22962307
var axList = (!arg || arg === 'redraw') ? axes.listIds(gd) : arg;

0 commit comments

Comments
 (0)