If number of traces are large such that scroll bar appears on the the legend bar then clicking behaviour is not working as expected.
Please see the codepen below.
Here if I try to select trace 13 then the scroll automatically goes to trace 20 and deselects it. This behaviour can be seen in the chrome. In IE however sometimes clicking on the legend doesn’t deselect or select the trace.