Skip to content

Conversation

etpinard
Copy link
Contributor

Slipping this in 1.46.0.

This PR first fixes an unreported bug for scatter traces with hoveron: 'points+fills' and then adds hovertemplate support for box/violin points. Please note that hovertemplate has no effect on the box/violin mean/q1/q3/kde etc labels. This part will remain unresolved until we can spec the API.

cc @plotly/plotly_js and @nicolaskruchten

@etpinard etpinard added bug something broken feature something new status: reviewable labels Mar 26, 2019
@etpinard etpinard added this to the v1.46.0 milestone Mar 26, 2019
.then(function() { _hoverNatural(gd, 180, 200); })
.then(function() {
assertHoverLabelContent({
nums: 'trace 1',
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Before the fix, this used to show '%{x} | %{y}', that is the raw hover template string.

@antoinerg
Copy link
Contributor

This PR introduces a first-level attribute hovertemplate that applies only to points. This seems like a reasonable default and it shouldn't be a problem in the future as I think our next API will have second-level (or higher) attributes hovertemplate for the other elements.

Thanks for the addition @etpinard ! 💃

@etpinard etpinard merged commit 7b2946a into master Mar 26, 2019
@etpinard etpinard deleted the box-violin-pts-hovertemplate branch March 26, 2019 19:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug something broken feature something new
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants