Hamed Yarandi
Hamed Yarandi

Reputation: 1211

How to show annotation for every point on highchart then disappear them

I'm using highchart and I have some annotation on it, but all annotation is load first, I decreased the series animation duration to 10000, The question is how can I show one by one annotations on the chart?

I mean I want to show first annotation on series then disappear the first and show the second and so on.

show this image that I found on the internet:

enter image description here

I will appreciate sharing your data with me, Thanks in advance

Upvotes: 0

Views: 402

Answers (1)

Sebastian Wędzel
Sebastian Wędzel

Reputation: 11633

I prepared a demo which shows how to keep tooltip shown for the last point.

Demo: https://jsfiddle.net/BlackLabel/vL7k1yce/

  render() {
    let chart = this,
      points = chart.series[0].points;
    chart.tooltip.refresh(points[points.length - 1]);
  }

Is that what you wanted to achieve?

API: https://api.highcharts.com/highcharts/chart.events.render

API: https://api.highcharts.com/class-reference/Highcharts.Series#addPoint

Upvotes: 2

Related Questions