Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When zooming out on the chart more than two years, the x-axis labeled is mislabeled #9928

Closed
olivier570 opened this issue Jan 17, 2019 · 8 comments

Comments

@olivier570
Copy link

Expected behaviour

When pulling the left lever of the navigator, the chart zooms out. Hovering over the charts shows the data for that data point as well as the corresponding date at the bottom. The date should be in sync with the navigator.

Actual behaviour

If pulling back the left lever, at first all is well. Once we go past about two years back, around where April 17 becomes visible on the left side of the graph, the graph itself scales down slightly for no apparent reason, and the dates indicated at the bottom of the tooltip (when hovering) are wrong: about 13 years less than they should be

Note: this error only happens on the latest version. If we revert back to 6.0 all is well

Live demo with steps to reproduce

https://www.123stat.com/stats/dashboard.htm?script=show_timeline.htm&target=referer_tracker&reports=referrerTracker&no_redirectt=1loginID=demo

Product version

This bug only happens on latest version https://code.highcharts.com/stock/highstock.js

if we use https:////code.highcharts.com/stock/6.0/highstock.js there are no problems

Affected browser(s)

Safari on MacOS

@KacperMadej
Copy link

Hi @olivier570

Please set up a demo that is not login and password protected or please provide an account for testing.

Please use a demo as simple as possible that will show your issue.

@olivier570
Copy link
Author

So sorry. I made a typo in the URL...

The correct URL (public URL) is https://www.123stat.com/stats/dashboard.htm?script=show_timeline.htm&reports=referrerTracker&no_redirect=1&loginID=demo

Thank you!

Olivier

@KacperMadej
Copy link

Thank you for the demo.

  1. Strange scaling down before April 2017 - Direct Access series has value of 481 at week 10 of 2017 causing yAxis to scale up and down depending on being in range (or just out of range) or being outside of the current range and nearest cropped points. Is this the issue you described? If not please add more info.

  2. Bad tooltip - I'm unable to recreate the problem. I scrolled to the data set start and back and each time the xAxis tooltip box info was correct (I checked only values on year end and start to avoid date calculations). Could this be resolved by version 7.0.2 released today? You might have been using the site with cached version 7.0.1 and I have visited the web site for the first time. To verify loaded Highcharts version please open browser console (developer tools) and see what will be returned after running Highcharts.version (be sure to use the window / frame / iframe with the chart and Highcharts loaded - that will be dashboard_frame (show_timeline.htm) in this case). If the problem is visible for you when v7.0.2 is loaded please check other browsers if possible.

Tested on Chrome / Win 7.

@sebastianbochan
Copy link
Contributor

Hi @olivier570,
Unfortunately, in the both cases I was not able to reproduce the issues.

Please let me know which version of Safari / MacOSX do you have?
Could you also post a gif / screenshots of scenario? It will allow us to help reproduce the issues.

Safari: 10.1
MacOSX: 10.12.4.

@olivier570
Copy link
Author

Hello,
In answer to your comments:

  1. the scaling down is not an issue. Just something I noticed happen just when the tooltip dates become incorrect. I thought maybe there was a correlation. That's why I mentioned it.
  2. I tried version 7.0.2 (and cleared the cache): same problem
  3. I tested on MacOS Mojave, with Firefox 64.0, Opera 56.0.3051.116 and Chrome 71.0.3578.98
  4. Attached is a screen shot of the problem taken after moving the left handle of the navigator towards the left.
    Thank you for your time with this. It is appreciated!
    screen_shot

Olivier

@KacperMadej
Copy link

@olivier570
Thank you for the image and full description.
I was able to recreate the problem and create a simple demo with the same problem.
Grouped data takes point properties from beginning of full data set and not from given zoom range as it should.

Simple demo: https://jsfiddle.net/BlackLabel/crw3zuj7/1/

Zoom into the range with pink points.
Orange point will be seen, colors will be used from start of the ful data set, as well as API documented point option (name) and custom point option (myName).

Workaround: disable data grouping

@olivier570
Copy link
Author

Thank you so much. Glad you were able to reproduce!

You are correct: disabling data grouping works... Unfortunately we do need data grouping in our app.

Do you think this will be solved in next version? Meanwhile we are going back to version 6.0 which does not have the issue.

Olivier

@KacperMadej
Copy link

@olivier570
A fix will be provided within next few days and should be published with next version.

Workaround with code fix:
The fix is simple, but nested quite deep in one of the Highstock functions, so the workaround in the demo below is big. Demo: https://jsfiddle.net/BlackLabel/crw3zuj7/2/

Internal note:
Related to #8889

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants