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 location string to tooltip for wiggle and SNPCoverage tracks #1576

Merged
merged 8 commits into from
Dec 21, 2020

Conversation

cmdcolin
Copy link
Collaborator

@cmdcolin cmdcolin commented Dec 20, 2020

Kind of simple but something that I think can help readability

localhost_3000__config=test_data%2Fvolvox%2Fconfig json session=local-SQOKyHDOv (2)
localhost_3000__config=test_data%2Fvolvox%2Fconfig json session=local-SQOKyHDOv (1)
localhost_3000__config=test_data%2Fvolvox%2Fconfig json session=local-SQOKyHDOv

@codecov
Copy link

codecov bot commented Dec 20, 2020

Codecov Report

Merging #1576 (47900e1) into master (4bb285b) will decrease coverage by 0.02%.
The diff coverage is 21.62%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1576      +/-   ##
==========================================
- Coverage   59.51%   59.48%   -0.03%     
==========================================
  Files         435      435              
  Lines       19564    19584      +20     
  Branches     4567     4573       +6     
==========================================
+ Hits        11643    11650       +7     
- Misses       7627     7640      +13     
  Partials      294      294              
Impacted Files Coverage Δ
packages/core/BaseFeatureWidget/index.ts 71.42% <0.00%> (ø)
...ns/alignments/src/AlignmentsFeatureDetail/index.js 71.42% <0.00%> (ø)
...rc/LinearSNPCoverageDisplay/components/Tooltip.tsx 21.87% <0.00%> (-5.05%) ⬇️
...iew/src/BreakpointAlignmentsFeatureDetail/index.js 28.57% <0.00%> (ø)
plugins/variants/src/VariantFeatureWidget/index.js 42.85% <0.00%> (ø)
plugins/wiggle/src/BigWigAdapter/BigWigAdapter.ts 94.44% <ø> (ø)
...gle/src/LinearWiggleDisplay/components/Tooltip.tsx 40.00% <0.00%> (-17.15%) ⬇️
...kages/core/BaseFeatureWidget/BaseFeatureDetail.tsx 69.35% <88.88%> (+1.25%) ⬆️

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 4bb285b...47900e1. Read the comment docs.

@garrettjstevens
Copy link
Collaborator

I like this. Would it be possible to show just one number instead of start..end when the length is 1? For example have the location here:
image

Match the overview location here:

image

@cmdcolin
Copy link
Collaborator Author

@garrettjstevens added a change for that, also corrects it to use feature.get('start')+1 for the displayed loc

@cmdcolin cmdcolin force-pushed the improve_tooltip_snpcov branch from dc93f03 to eeb2283 Compare December 21, 2020 18:58
@cmdcolin
Copy link
Collaborator Author

I made an additional proposal to the feature detail dialogs that it makes model.featureData=undefined by default rather than model.featureData={}

This uses types.frozen() instead of types.frozen({}) in the model definition

If this is not the case, then the base feature details can receive undefined entries for start,end,etc. and then end.toLocaleString is a crash, etc.

@cmdcolin
Copy link
Collaborator Author

Just because there is some precedent for these things possibly being an empty object, to avoid a crash, I check for empty object now

@cmdcolin cmdcolin merged commit 940eafa into master Dec 21, 2020
@cmdcolin cmdcolin added the enhancement New feature or request label Dec 21, 2020
@cmdcolin cmdcolin deleted the improve_tooltip_snpcov branch December 22, 2020 02:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants