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

Selection range is incorrect at start if the upper bound is the max index #2454

Open
bnjbvr opened this issue Aug 19, 2018 · 0 comments
Open

Comments

@bnjbvr
Copy link

bnjbvr commented Aug 19, 2018

  • C3 version: 0.6.7
  • D3 version: 5.5.0
  • Browser: Firefox Nightly 63 (2018-08-18)
  • OS: Linux 64bits (latest Ubuntu LTS)

See the following JSFiddle: https://jsfiddle.net/xnpksgjb/12/

My intent is to pre-select the last 3 categories, by using their indexes in the series list, so I use the configuration option axis.x.selection for this; note the same issue happens with zoom.initialRange set to the same values.

The pre-selected range that is shown is correct, but when one tries to move it around by dragging it to the left, in the subchart, it gets bigger than what's shown to screen. So it seems the X domain upper bound is bigger than the maximum width, and is just trimmed at start.

If you change the highExtent value to something less than the maximum possible index, then it works fine, so this suggests it's an issue only with the last value.

This is unfortunate, because zoom.initialRange and axis.x.selection looked like good candidates to replace the extent option that disappeared in latest versions.

Please let me know if I can help in any way!

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

1 participant