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

hovertemplate support for sankey #3284

Merged
merged 3 commits into from Dec 7, 2018

Conversation

Projects
None yet
2 participants
@antoinerg
Copy link
Collaborator

commented Nov 23, 2018

Closes #3269

@antoinerg

This comment has been minimized.

Copy link
Collaborator Author

commented Nov 23, 2018

I am not sure the description of hovertemplate attributes is satisfactory. I'd like to discuss the changes made in commit d952713.

Finally, because the inclusion hovertemplate in Fx.loneHover calls have been tested in other traces, is it necessary to test it again in sankey_test.js? Is it OK to only check for the existence of the expected variables in eventData? 🤔

@@ -146,6 +147,10 @@ var attrs = module.exports = overrideAll({
].join(' ')
},
hoverlabel: fxAttrs.hoverlabel, // needs editType override,
hovertemplate: hovertemplateAttrs({}, {

This comment has been minimized.

Copy link
@etpinard

etpinard Nov 26, 2018

Member

Hmm. Sankey event data is a bit of mess:

image

image

There's probably way more stuff it in than we need. Moreover, some of it isn't consistent with event data for other traces e.g. the trace key should be fullData. I'm not how much we can change it w/o making breaking changes.

Oh well, these descriptions look ok to me.

This comment has been minimized.

Copy link
@antoinerg

antoinerg Nov 28, 2018

Author Collaborator

I added fullData to the eventData in commit 3204274

This comment has been minimized.

Copy link
@etpinard

etpinard Dec 7, 2018

Member

v2 changes tracked in #168 (comment)

@etpinard

This comment has been minimized.

Copy link
Member

commented Nov 26, 2018

Finally, because the inclusion hovertemplate in Fx.loneHover calls have been tested in other traces, is it necessary to test it again in sankey_test.js?

I would add one "true" hovertemplate test case where we check that a user-defined hovertemplate gives the correct hover label content. You're right though, no need to re-test all the loneHover logic again 👌

@antoinerg

This comment has been minimized.

Copy link
Collaborator Author

commented Nov 28, 2018

I would add one "true" hovertemplate test case where we check that a user-defined hovertemplate gives the correct hover label content.

Done in commit 3204274!

@etpinard etpinard added this to the v1.43.0 milestone Dec 7, 2018

@etpinard

This comment has been minimized.

Copy link
Member

commented Dec 7, 2018

@antoinerg oops I forgot about this PR.

Looks good 💃

@antoinerg antoinerg merged commit 8ce56d7 into master Dec 7, 2018

7 checks passed

ci/circleci: build Your tests passed on CircleCI!
Details
ci/circleci: publish Your tests passed on CircleCI!
Details
ci/circleci: test-image Your tests passed on CircleCI!
Details
ci/circleci: test-image2 Your tests passed on CircleCI!
Details
ci/circleci: test-jasmine Your tests passed on CircleCI!
Details
ci/circleci: test-jasmine2 Your tests passed on CircleCI!
Details
ci/circleci: test-syntax Your tests passed on CircleCI!
Details

@antoinerg antoinerg deleted the 3269-sankey-hovertemplate branch Dec 7, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.