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

Support rendering layers of measurable SVG nodes in plexus #422

Merged

Conversation

tiffon
Copy link
Member

@tiffon tiffon commented Jul 23, 2019

Which problem is this PR solving?

Adds the ability to render a SVG layer of measurable nodes.

Short description of the changes

Adds support for rendering measurable SVG nodes in plexus.

Additional changes:

  • Add the measureNode prop to override how nodes are measured. The use of this prop is shown in the demo.

  • Add a demo graph that uses measurable SVG nodes and overrides how
    they're measured

  • Rename the nodeRender prop to renderNode

- Add the  prop to override how nodes are measured

- Add a demo graph that uses measurable SVG nodes and overrides how
  they're measured

- Rename the nodeRender prop to renderNode

Signed-off-by: Joe Farro <joef@uber.com>
@tiffon tiffon added the plexus Specific to packages/plexus label Jul 23, 2019
@tiffon tiffon requested a review from everett980 July 23, 2019 14:53
@codecov
Copy link

codecov bot commented Jul 23, 2019

Codecov Report

Merging #422 into master will increase coverage by 0.04%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #422      +/-   ##
==========================================
+ Coverage   91.62%   91.67%   +0.04%     
==========================================
  Files         176      176              
  Lines        4010     4010              
  Branches      928      928              
==========================================
+ Hits         3674     3676       +2     
+ Misses        298      296       -2     
  Partials       38       38
Impacted Files Coverage Δ
...eViewer/TimelineHeaderRow/TimelineViewingLayer.tsx 91.52% <0%> (+3.38%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update cbd9ff7...2a14b74. Read the comment docs.

Copy link
Collaborator

@everett980 everett980 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. One minor, possibly-TS question.

...current.measure(),
vertex: vertices[i],
vertex,
...(measureNode && utils ? measureNode(vertex, utils) : current.measure()),
Copy link
Collaborator

Choose a reason for hiding this comment

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

is the measureNode && utils to satisfy TypeScript? It seems like Boolean(measureNode) and Boolean(utils) must always be the same.

Copy link
Member Author

Choose a reason for hiding this comment

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

It's for TypeScript.

@tiffon tiffon merged commit 1e26e57 into jaegertracing:master Jul 26, 2019
@tiffon tiffon deleted the layered-digraph-measurable-svg-nodes branch July 26, 2019 19:27
vvvprabhakar pushed a commit to vvvprabhakar/jaeger-ui that referenced this pull request Jul 5, 2021
…cing#422)

Support rendering layers of measurable SVG nodes in plexus
Signed-off-by: vvvprabhakar <vvvprabhakar@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
plexus Specific to packages/plexus
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants