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 values with labels not aligned #149

Closed
jimfilippou opened this issue Oct 9, 2018 · 4 comments
Closed

X axis values with labels not aligned #149

jimfilippou opened this issue Oct 9, 2018 · 4 comments

Comments

@jimfilippou
Copy link
Contributor

Codepen

https://codepen.io/jimfilippou-the-animator/pen/aRpxdG

Explanation

The X-axis takes 100% of the area but line chart doesn't

@junedchhipa
Copy link
Contributor

Try this:

grid: {
    padding: {
       left: 0,
      right: 0
    }
}

@jimfilippou
Copy link
Contributor Author

I have updated my pen https://codepen.io/jimfilippou-the-animator/pen/aRpxdG
The issue seems to be resolved only for first and last values, however, the initial issue persists

@junedchhipa
Copy link
Contributor

junedchhipa commented Oct 9, 2018

If you do not provide any labels or categories, ApexCharts generates labels in 1.2.3... fashion and gives xaxis.tickAmount: 8 as default.
In such a case, you will have to play with tickAmount and see what works. I guess tickAmount: 7 will work in your case.

I will change tickAmount default to equal the number of data-points for such use-cases in the next releases.

@jimfilippou
Copy link
Contributor Author

Fixed, but close the issue whenever you default the tickAmount to the data points.
Thanks once again! 🙌 🎉

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

2 participants