Clicking on legend group titles should always toggle the group, even when groupclick=item
Follow up on https://github.com/plotly/plotly.js/pull/5906
This would be a huge plus and make groupclick much more useful. I flip back and forth between the modes as I visualize data from multiple sources and each source provides multiple "views" of the same data. Sometimes all views from a producer will be unhelpful but sometimes a producer that produces many views will have one useful view. So in that case I want be able to easily say "Give me all views from producer 1, no views from producer 2, and the third view from producer 3" which can be cumbersome if each producer gives me up to 100 views.
If anyone has any other suggestions/workarounds in the mean time that would also be helpful.
Is this the function that would need to change? I can't identify the line it handles legend group title clicks.
https://github.com/plotly/plotly.js/blob/8050b274d5373586af5c1612c5627645cea5050d/src/components/legend/handle_click.js#L64-L70
Am I missing something or you want to revert a previous work with groupclick="toggleitem" in legend ? I can't really make it work anyway
Am I missing something or you want to revert a previous work with groupclick="toggleitem" in legend ? I can't really make it work anyway
No we are not going to revert the previous work. Just labeled it as a current bug.
Any updates?
Am I missing something or you want to revert a previous work with groupclick="toggleitem" in legend ? I can't really make it work anyway
No we are not going to revert the previous work. Just labeled it as a current bug.
If the group title is clicked then shouldn't it do togglegroup? For example, if I have groupclick = "toggleitem", I want the individual trace to be toggled, but if the group title is clicked I want the group itself to be toggled. Is there a way to implement that?
Am I missing something or you want to revert a previous work with groupclick="toggleitem" in legend ? I can't really make it work anyway
No we are not going to revert the previous work. Just labeled it as a current bug.
If the group title is clicked then shouldn't it do togglegroup? For example, if I have groupclick = "toggleitem", I want the individual trace to be toggled, but if the group title is clicked I want the group itself to be toggled. Is there a way to implement that?
This is what exactly what I'm looking for. I really need this
Hi! Could anyone please shed some light on this: Is it so that the desired behavior is to have a possibility to run a setup like Something like
legend: {
groupclick: 'togglegroup',
itemclick: 'toggle',
},
and thus toggle group via group title click and individual trace via respective trace item click? I know that for my use case this is certainly the desired behavior, just checking if there is consensus about this.
And is it so that this is not currently supported?
In my experience with 2.16.3 individual trace toggling only works with groupclick: 'toggleitem'.
Confusingly, doubleclick, which if i gather correctly defaults to itemdoubleclick:'toggleothers' toggles other groups but keeps other traces within the group, item of which was double clicked, untoggled