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

Hi! i have some problem with function onHover on the Pie chart. #3799

Closed
Zulfia73 opened this issue Jan 17, 2017 · 4 comments
Closed

Hi! i have some problem with function onHover on the Pie chart. #3799

Zulfia73 opened this issue Jan 17, 2017 · 4 comments

Comments

@Zulfia73
Copy link

Zulfia73 commented Jan 17, 2017

Expected Behavior

reaction to the event mousemove, when i used onHover

Current Behavior

no reaction to the event mousemove, when i used onHover. Although, reaction to the onClick works

Example my code

getOptions = () => { return({ legend: { display: false, }, onClick: (e, legendItem) => { this.setState({ isColor: legendItem[0]._model.label }); }, onHover: (e, legendItem) => { console.log('навели на часть pie, e:', e, 'legendItem: ', legendItem); } }); }

##Answer

hover: { onHover: (e, legendItem) => { console.log('навели на часть pie, e:', e, 'legendItem: ', legendItem); } }
but in documentation say

onHover function(event, legendItem) {}

event - includes pie item, legendItem - undefined

@etimberg
Copy link
Member

@Zulfia73 do you have a fiddle with a test of this?

@alpendergrass
Copy link

I have experienced the same issue on a mixed (line/bar) chart.

@alpendergrass
Copy link

Installing the latest version of Chart.js fixed the problem for me.

@etimberg
Copy link
Member

Closing since there is no test case for this

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

No branches or pull requests

4 participants