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

Highlight a search result feature in track #2316

Open
cmdcolin opened this issue Sep 12, 2021 · 3 comments
Open

Highlight a search result feature in track #2316

cmdcolin opened this issue Sep 12, 2021 · 3 comments
Labels
enhancement New feature or request text searching related to text searching

Comments

@cmdcolin
Copy link
Collaborator

Currently if a search result is hit, it may be outside the current scroll view, requiring the user to scroll down to see it

It may be useful to autoscroll or force that feature to the top of the layout

It may also be useful to highlight that feature as a feature selection or similar automatically

@cmdcolin cmdcolin added enhancement New feature or request text searching related to text searching labels Sep 12, 2021
@cmdcolin
Copy link
Collaborator Author

I think this may be a good thing to get prioritized somehow, because after search, due to the small height on the opened tracks by default, the feature you searched for may not be visible in the output

it may even be nice to modify the layout similar to the sorting of the pileup to make the feature the user searched for to be sorted at the top

@bbimber
Copy link
Contributor

bbimber commented Dec 15, 2021

@cmdcolin I'd like to second this. We used this heavily on JB1, though in slightly difference use case. We publish a big variant catalog. We provide links to open JBrowse at a specific variant site. It was really useful to be able to highlight that position (i.e. big vertical line at that coordinate). Otherwise it's very hard for the user to identify exactly which position they are looking at.

Reading your post more carefully, our use case isnt really text-search based and you might be describing more of a targeted highlight.

@scottcain
Copy link
Member

To follow on to @bbimber comment (and this may constitute a separate issue): at AGR, we have a custom JS genome browser widget (based on https://github.com/GMOD/GenomeFeatureComponent) that allows users to click on a variant in a table, and the widget responds by adding a "highlight column" (ie, top to bottom through all tracks) for that feature. That functionality is reciprocal: clicking on the feature in the widget highlights the column in the table as well. Finally, it also acts as a toggle; clicking a highlighted feature removes the highlight in both places. I realize that if I want to port this functionality to an embedded JBrowse instance, I'll have to write JS in the page, but before that can happen I have to have the ability to add highlights in JBrowse more generally.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request text searching related to text searching
Projects
None yet
Development

No branches or pull requests

3 participants