Skip to content

Duplicate x-axis label with 'category ascending' #862

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

Closed
john-soklaski opened this issue Aug 17, 2016 · 2 comments
Closed

Duplicate x-axis label with 'category ascending' #862

john-soklaski opened this issue Aug 17, 2016 · 2 comments
Labels
bug something broken

Comments

@john-soklaski
Copy link
Contributor

Repro at:
https://codepen.io/john-soklaski/pen/QEoJAz

When the xaxis in this example has categoryorder: 'category ascending' set, there is a duplicate '1' on the xaxis, if it is not set, the duplicate label no longer appears.

@john-soklaski
Copy link
Contributor Author

I think this is due to an off by one error in flattenUniqueSort. Fix at master...john-soklaski:category_ascending_bug

@etpinard
Copy link
Contributor

Thanks for the report. Confirmed.

At first glance your fix looks appropriate. Categorical ordering is tested here. Would you mind testing that suite by running:

npm run test-jasmine -- tests/calcdata_test.js

and see that it doesn't break anything?

If the tests pass, PR away 🚀

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

No branches or pull requests

2 participants