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

[FEATURE] interactions option #5861

Closed
kurkle opened this issue Nov 24, 2018 · 1 comment · Fixed by #7922
Closed

[FEATURE] interactions option #5861

kurkle opened this issue Nov 24, 2018 · 1 comment · Fixed by #7922

Comments

@kurkle
Copy link
Member

kurkle commented Nov 24, 2018

In my opinion hover and tooltips options {mode, axis, intersect} are tightly bound together.
There could be a use case where that is not true, but by default these could be configured using one set of options.

Current Behavior

hover and tooltips options are configured separately. Controllers usually set default for hover.mode, but not for tooltips.mode => weird effects.

Expected Behavior

hover and tooltips options extend from new interactions option.

Possible Solution

  • Add interactions option that both hover and tooltips extend from.
  • Move defaults (global and chart type specific) to the new option.
  • Extend on chart initialization to keep compatibility with external code?

2nd Possible Solution

  • Update controllers to set defaults for both tooltips and hover

Context

This would ease the configuration of new charts a bit. Also new developers would avoid weird interaction effects when familiarizing with this library for the first time.

Environment

  • Chart.js version: 2.7.3
@benmccann benmccann added this to the Version 3.0 milestone Nov 24, 2018
@benmccann
Copy link
Contributor

Originally discussed in #5857 (comment)

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

Successfully merging a pull request may close this issue.

3 participants