-
Notifications
You must be signed in to change notification settings - Fork 63
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
New SVG gene glyph with directional arrows #2775
Conversation
Codecov Report
@@ Coverage Diff @@
## main #2775 +/- ##
==========================================
- Coverage 59.97% 59.97% -0.01%
==========================================
Files 584 584
Lines 26651 26576 -75
Branches 6447 6444 -3
==========================================
- Hits 15985 15938 -47
+ Misses 10338 10324 -14
+ Partials 328 314 -14
Continue to review full report at Codecov.
|
a68e237
to
5c746b2
Compare
e37f1a7
to
ba08013
Compare
2bf2d40
to
ba08013
Compare
ba08013
to
410ab7c
Compare
I think the agreement from the meeting was this PR should be ok to go, at least conceptually. any concerns? one note was that the Chevron glyph is being removed, and we wondered if any third party libs directly used this glyph cc @bbimber |
@hextraza Sebastian, could you give this a quick look? I dont think we need chevron; however, we might need to do some tweaks on our plugin to adapt to this. |
I don't believe chevron is re-exported so should not cause breakage in third party code |
maybe can merge optimistically :) |
…chevrons on subfeatures, and convert SVG features to typescript (#2775) * New style of arrowhead on gene glyph * Updates * Misc * T1 * Fix some tsc * Fix tsc * Misc * Add Arrow component * Add arrow * Fix tests * Less use of any * More typescript * Updates * Add outline variable * Fix flip on arrow * Minor refactor to avoid ClientRect * Update snaps * No arrow if no strand * Arrow before box so box covers arrow
This removes the chevron code for directional indications (xref #1909)
The arrows are added on top level features (e.g. the subfeature Box glyphs do not draw the arrowheads) and it determines this using a topLevel prop
Fun technical detail but this also uses a line+polygon elements instead of a single
polyline
to draw the polygon. Also note there is code drawing arrows like this on main, but it is hidden behind the chevron.Reason for polygon+line is because it is sharper this way, see screenshots
polygon triangle
polyline triangle, has a little "foot" on the arrow when the polyline presumably doesn't come to a perfect point
also converted the svg features to typescript in the process. can separate into multiple PR if helpful
also uses an outline config variable for boxes, instead of only displaying the outline when selected (current main does this) and not use color2 but instead a new config variable that is nothing by default (color2 is the intron color) (xref #2449)