Make Chart.Animation/animations/Tooltip importable#5382
Merged
simonbrunel merged 1 commit intochartjs:masterfrom Apr 2, 2018
Merged
Make Chart.Animation/animations/Tooltip importable#5382simonbrunel merged 1 commit intochartjs:masterfrom
Chart.Animation/animations/Tooltip importable#5382simonbrunel merged 1 commit intochartjs:masterfrom
Conversation
simonbrunel
commented
Apr 1, 2018
| @@ -1,5 +1,6 @@ | |||
| { | |||
| "indent-style": "tabs", | |||
| "line-end-style": false, | |||
Member
Author
There was a problem hiding this comment.
@loicbourgois I had to disable this rule, else we can't run gulp lint on Windows with Git configured to AutoCrlf.
simonbrunel
commented
Apr 1, 2018
| /** | ||
| * @namespace Chart.Tooltip.positioners | ||
| */ | ||
| exports.positioners = positioners; |
Member
Author
There was a problem hiding this comment.
@etimberg I'm not sure why we need to expose positioners (Chart.Tooltip.positioners)
Member
There was a problem hiding this comment.
It must be a backwards compatibility thing. Not sure when it first got introduced
Member
Author
There was a problem hiding this comment.
Actually, I think it was public to allow users to implement their own logic:
Chart.Tooltip.positioners.foobar = function(elements) {
// ...
};
options: {
tooltips: {
position: 'foobar'
}
}
Member
Author
There was a problem hiding this comment.
9 tasks
etimberg
approved these changes
Apr 1, 2018
A1vinSmith
reviewed
Jul 31, 2019
| } | ||
| // If the user provided a sorting function, use it to modify the tooltip items | ||
| if (opts.itemSort) { | ||
| tooltipItems = tooltipItems.sort(function(a, b) { |
There was a problem hiding this comment.
tooltipItems.sort(function(a, b) {
return opts.itemSort(a, b, data);
});
remove self-assignment
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Relates to #4478