-
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
Tooltip support for CanvasPattern and CanvasGradient #5869
Conversation
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 like the use of the global opacity and the code simplification. In your fiddle, the tooltip with a pattern (second dataset) is a bit strange because the pattern seems to move in the tooltip box. But I guess that's a good choice since it works better with gradient (third dataset).
padding: 15 | ||
} | ||
}, | ||
plugins: [{ |
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.
Well done, I never thought about using plugins to test interactions!
This PR replaces
mergeOpacity
calls withctx.globalAlpha
to supportCanvasPattern
andCanvasGradient
as tooltip item colors.master: https://jsfiddle.net/nagix/hLn3uy5q/
master + This PR: https://jsfiddle.net/nagix/xc3vo2kh/
Fixes #4279