delux
delux

Reputation: 1886

Dragging annotations to the left edge is causing issues

I have this JSFiddle, where I can draw annotations and drag them around.

But, in case I draw a segment or arrow-segment and in case I try to drag them to the most left edge of the chart, they are changing it's position and are aligning vertically and parallelly to the left edge. The demo can be seen in this video.

I tested and concluded that the issue has nothing to do with the plugins which I am having in the code I posted. So I wonder if this is a highcharts bug or if this behavior can be fixed within the onDrag event?

H.wrap(H.Annotation.prototype, 'onDrag', function(proceed) {  
  var annotation = this;
  proceed.apply(this, Array.prototype.slice.call(arguments, 1));
  //do something here?
});

Upvotes: 0

Views: 56

Answers (1)

Sebastian Wędzel
Sebastian Wędzel

Reputation: 11633

It looks like a bug, I reported it on the Highcharts Github issue channel where you can follow this thread: https://github.com/highcharts/highcharts/issues/14944

Setting ordinal=false resolves the issue: https://jsfiddle.net/BlackLabel/cnosa15L/1/

Upvotes: 1

Related Questions