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

Add plotly-esque point data info to pie & sankey event data #1896

Merged
merged 4 commits into from Jul 19, 2017

Conversation

etpinard
Copy link
Contributor

fixes #1875

- no need for two test suite for pie traces.
... respectively, to make pie trace event data more on-par
    with other trace types.
// for event data
l.trace = d.trace;
l.curveNumber = d.trace.index;
l.pointNumber = 'TODO';
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@monfera is there a easy way to grab the pointNumber value off the sankey link & node d3-esque data?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done in 15dc324

Copy link
Contributor

Choose a reason for hiding this comment

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

Thanks @etpinard I missed the question on the road, now see it's done, very nice! 🙇

@@ -410,4 +410,101 @@ describe('sankey tests', function() {
.then(done);
});
});

describe('Test hover/click event data:', function() {
Copy link
Contributor Author

@etpinard etpinard Jul 18, 2017

Choose a reason for hiding this comment

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

Sankey event data wasn't tested anywhere before ⤴️

🙃

@etpinard
Copy link
Contributor Author

@alexcjohnson might as well include this in 1.29.0 too.

@etpinard etpinard added this to the 1.29.0 milestone Jul 19, 2017
@@ -392,18 +394,22 @@ describe('Test event property of interactions on a pie plot:', function() {
expect(typeof trace).toEqual(typeof {}, 'points.trace');

var pt = futureData.points[0];
expect(Object.keys(pt)).toEqual([
expect(Object.keys(pt)).toEqual(jasmine.arrayContaining([
Copy link
Contributor

Choose a reason for hiding this comment

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

nice, didn't know about arrayContaining!

@alexcjohnson
Copy link
Contributor

No comments from me, very nice! 💃

@etpinard etpinard merged commit 756bd69 into master Jul 19, 2017
@etpinard etpinard deleted the fix-pie-sankey-event-data branch July 19, 2017 20:39
@etpinard etpinard mentioned this pull request Jul 20, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Mouse event data for 'pie' and 'sankey' plots doesn't return curveNumber or pointNumber
3 participants