-
Notifications
You must be signed in to change notification settings - Fork 11.9k
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
New time scale ticks.bounds
option
#4556
Conversation
The master implementation is equivalent to |
Wow, amazing to close so many tickets! |
src/scales/scale.time.js
Outdated
|
||
/** | ||
* Ticks distribution along the scale: | ||
* - 'linear': ticks are spread according to their time (distances can vary), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's more accurate to say data rather than ticks here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Or rather maybe more informative to say "ticks and data"
When source:auto
mode, we try to place ticks spread evenly regardless of mode
so I think it helps explain it better if we mention data as well
looks good to me |
`ticks.bounds` (`'data'`(default)|`'label'`): `data` preserves the data range while `labels` ensures that all labels are visible. This option is bypassed by the min/max time options. Remove the useless time scale `_model` object containing private members: instead, make these members private (prefixed by `_`) part of the scale.
a91a1f7
to
92809e2
Compare
And I'm sure I missed some tickets |
Hi Simon and everyone! First of all congrats to you all for such great community! 🥇 🥇 🥇 Tried with your last update for this issue (is it included on ChartJS 2.6 right? Or do I have to upgrade the code manually on Maybe I'm implementing the solution wrong... Below you can see how (tried with just one tick.bounds on xAxis and both, but nothing...) As you can see there are still some dates not included on the chart. Hope one day I could contribute in any code here, Cheers! |
This isn't included in 2.6.0. You have to checkout the latest code from github, build it ( |
It's not released yet, you will have to wait the next release (2.7). However you can try the latest build from master (for testing only - do not pay attention to the version number in this file) and see if it works as you expect. |
Also, I don't think |
Ok cool, thanks a lot for such quick answer guys! :) |
`ticks.bounds` (`'data'`(default)|`'label'`): `data` preserves the data range while `labels` ensures that all labels are visible. This option is bypassed by the min/max time options. Remove the useless time scale `_model` object containing private members: instead, make these members private (prefixed by `_`) part of the scale.
`ticks.bounds` (`'data'`(default)|`'label'`): `data` preserves the data range while `labels` ensures that all labels are visible. This option is bypassed by the min/max time options. Remove the useless time scale `_model` object containing private members: instead, make these members private (prefixed by `_`) part of the scale.
`ticks.bounds` (`'data'`(default)|`'label'`): `data` preserves the data range while `labels` ensures that all labels are visible. This option is bypassed by the min/max time options. Remove the useless time scale `_model` object containing private members: instead, make these members private (prefixed by `_`) part of the scale.
@dabrave did an update fixed your problem? because I'm facing similar problem with version 2.9.4 |
Edit: renamed
scale.ticks.bounds
toscale.bounds
in #4595--
bounds
('data' (default)
|'ticks'
):data
preserves the data range whileticks
ensures that all labels are visible. This option is bypassed by the min/max time options.Remove the useless time scale
_model
object containing private members: instead, make these members private (prefixed by_
) part of the scale.Fixes #2249
Fixes #2513
Fixes #2599
Fixes #2684
Fixes #2774
Fixes #3297
Fixes #3654
Fixes #3671
Fixes #4263
Fixes #4264
Fixes #4529
Fixes #4550