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

Migrate Sankey renderer to React #4255

Merged
merged 3 commits into from
Oct 17, 2019
Merged

Conversation

kravets-levko
Copy link
Collaborator

@kravets-levko kravets-levko commented Oct 17, 2019

What type of PR is this? (check all applicable)

  • Refactor

Description

  • Convert component to React
  • Revisit code, refine if needed
  • Cleanup
  • Tests

Related Tickets & Documents

#3301 (Migrate Visualizations to React -> Sankey)

Mobile & Desktop Screenshots/Recordings (if there are UI changes)

No visual changes

@kravets-levko kravets-levko added Frontend Visualizations Frontend: React Frontend codebase migration to React labels Oct 17, 2019
@kravets-levko kravets-levko self-assigned this Oct 17, 2019
@arikfr arikfr mentioned this pull request Oct 17, 2019
24 tasks
@kravets-levko kravets-levko force-pushed the migrate-sankey-renderer branch from 8e74f1a to 41cba71 Compare October 17, 2019 08:44
@kravets-levko kravets-levko marked this pull request as ready for review October 17, 2019 09:10
const links = {};
const nodes = [];

// ANGULAR_REMOVE_ME $$ check is for Angular's internal properties
Copy link
Contributor

Choose a reason for hiding this comment

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

Not redundant now?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

No - sankey may still receive data from Angular part, so these properties may be present there. It will be safe to remove when we'll completely remove Angular itself.


// wait a bit before taking snapshot
cy.wait(1000); // eslint-disable-line cypress/no-unnecessary-waiting
cy.percySnapshot('Visualizations - Sunburst', { widths: [viewportWidth] });
Copy link
Contributor

@ranbena ranbena Oct 17, 2019

Choose a reason for hiding this comment

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

Perhaps you can skip the wait by instead of clicking "Show Data Only", visiting page cy.visit('queries/${id}') and then snap?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I added this timeout to wait for chart to load a query results data. "Show Data Only" is actually a link, so it should be completely equal to cy.visit(...). But I may give it a try

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Seems there is no difference - cy.visit need cy.wait as well. I prefer to keep current variant because 1) it already works 2) it's a bit simpler 🙂

Copy link
Contributor

@ranbena ranbena left a comment

Choose a reason for hiding this comment

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

Looks good. A few comments.

@kravets-levko kravets-levko merged commit 0aca649 into master Oct 17, 2019
@kravets-levko kravets-levko deleted the migrate-sankey-renderer branch October 17, 2019 10:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Frontend: React Frontend codebase migration to React Frontend Visualizations
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants