plotly.js
plotly.js copied to clipboard
legendgroup visibility toggling does not work for shapes when showlegend is false
Toggling behavior of shapes is not consistent with that of traces in the legend.
https://codepen.io/dmyr/pen/abXmLPR
In the example, traces t0 and t1 are in legendgroup: "group1". t1 is hidden from the legend showlegend: false. Clicking t0 in the legend hides both t0 and t1 in the plot. This works as I would expect.
Shapes s0 and s1 are in legendgroup: "group2". s1 is hidden from legend showlegend: false. Clicking s0 in the legend only hides s0 while s1 is still visible in the plot. Expected: all members of the legend group should be hidden in the plot (both s0 and s1).
I'm having the same issue. Have you found a solution?