Home Forums Feature Requests & Feedback Pass chart reference in legend on click event

Pass chart reference in legend on click event

Viewing 4 posts - 1 through 4 (of 4 total)
  • #6769

    Hi,

    I was trying to get the example for hiding/showing a dataseries on legend click to work.
    Because I don’t have my chart reference available where I setup the legends onclick function, it would be nice to have the chart as reference on the passed event.

    Line 12316 in uncompressed 1.5.0 beta version would do the trick:
    eventObjectMap.eventParameter = { x: xy.x, y: xy.y, dataSeries: dataSeries._options, dataPoint: dataPoint, dataPointIndex: eventObjectMap.dataPointIndex, dataSeriesIndex: eventObjectMap.dataSeriesIndex, chart : this.chart };

    Thanks and regards,
    Joachim

    #6782

    Joachim,

    It makes sense. We’ll surely consider this for v1.5 GA. Thanks for the feedback.


    Sunil Urs

    #6787

    Jaochim,

    We’ve added chart reference to event parameters. You can download it from here.


    Sunil Urs

    #6791

    Thanks a lot for the quick solution.

    Regards,
    Joachim

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.