plotly / plotly/react-plotly.js
OnBeforeHover returns just an event rather than datapoints and an event
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 1.1k
- Forks
- 138
- Avg merge
- 3d 2h
- Merged PRs (30d)
- 4
Description
The title really says it all. I've attempted to set up an example in codePen (taking my code and boiling it down), however, the older versions didn't even call OnBeforeHover so I tried updating the versions, but I'm not at all familiar with the way in which scripts are loaded in via HTML tags, I think I've done it correctly, however, I have access to neither createPlotlyComponent nor plotComponentFactory in my code.
https://codepen.io/tim-logan/pen/NWgbBvr?editors=1010
I'm attempting to get enough data to make the hover only be active near the line rather than the entire fill, but it's a lot harder if I only have the mouse event.
Oh, and just for clarity, what I get out is NOT
{
event: mouseEvent,
points: [] /undefined etc
...
}
What I get out is just
event: mouseEvent
(The type definitions claims I should get the first out though)
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the OnBeforeHover behavior using the linked CodePen and inspect the component's type definitions, which claim the callback includes both an event and datapoints. Trace how the callback is exposed and confirm that the returned value includes the datapoints as well as the mouse event.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, react
- Domain
- data-visualization, frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 32/100