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

X-axis range doesn't work #491

Closed
mzy2240 opened this issue Apr 9, 2019 · 10 comments
Closed

X-axis range doesn't work #491

mzy2240 opened this issue Apr 9, 2019 · 10 comments

Comments

@mzy2240
Copy link

mzy2240 commented Apr 9, 2019

Codepen

https://codepen.io/anon/pen/OGbwEG

Explanation

  • What is the behavior you expect? Realtime chart just like the example (https://apexcharts.com/javascript-chart-demos/line-charts/realtime/)
  • What is happening instead? Range for x-axis does not work, so the line is getting compressed because of the incoming data.
  • What error message are you getting? Nothing. Besides that, what puzzled me most is that, in our actual practice, the chart in the website only looks as it should in my laptop, but fails in all my colleague's pcs, even if we are using the same system and same chrome version (incognito mode).
@cemujax
Copy link
Contributor

cemujax commented Apr 9, 2019

Why don't you delete sparkline option?

var traffic = Array(11).fill(0)
var options = {
  chart: {
          // sparkline: {
          //   enabled: true
          // },
          ...

https://codepen.io/cemujax/pen/WWRQjW

I hope it's the result you wanted.

@mzy2240
Copy link
Author

mzy2240 commented Apr 9, 2019

No it is still not what I want. If you check the example, you can see the animation is like a moving window, however, even in the codepen that you provided, the waves are compressing instead of going away. You just look at the chart for about 30 seconds and you will get what I'm saying.

@junedchhipa
Copy link
Contributor

Fixed the issue in this commit - c0b1ace
Will be released on npm soon.

@mzy2240
Copy link
Author

mzy2240 commented Apr 9, 2019

Ok I just saw @junedchhipa did a commit about that. Thank you so much for your help!

@mzy2240
Copy link
Author

mzy2240 commented Apr 15, 2019

Hey @junedchhipa I just checked the latest release and I found the bug is still not fixed. Here is the codepen: https://codepen.io/anon/pen/OGbwEG. The line is still compressing instead of window moving.

@junedchhipa junedchhipa reopened this Apr 22, 2019
@junedchhipa junedchhipa changed the title !!!Chart is not consistent using different pc (same system and same Chrome version) X-axis range doesn't work Apr 22, 2019
@mzy2240
Copy link
Author

mzy2240 commented Apr 28, 2019

Just test the codepen with the latest version 3.6.9, the bug is still there and no sign to be fixed. Please re-open the case. @junedchhipa

@junedchhipa
Copy link
Contributor

Wow! I am surprised and embarrassed at the same time that after doing 3 fixes, still this didn’t get solved :)

What on earth is reverting it back!!

I will write more tests to avoid it. Sorry for the trouble you faced.

@junedchhipa junedchhipa reopened this Apr 28, 2019
@junedchhipa
Copy link
Contributor

Just noticed that cdnjs links are still cached and not reflecting the latest version of ApexCharts.
Please try https://unpkg.com/apexcharts@3.6.9/dist/apexcharts.min.js and see if it fixes the issue.

@mzy2240
Copy link
Author

mzy2240 commented Apr 29, 2019

No, unfortunately, it is still not fixed. I have to see it is a weird bug, cause the first time I noticed that, I found the dynamic line behaves different in different PCs, which I never heard and met before.

@junedchhipa
Copy link
Contributor

On what browser does it not work correctly? Please provide more information on how to reproduce it. Closing it until then. Feel free to open if the bug is still not fixed in specific browsers.

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

No branches or pull requests

3 participants