pombase / canto

The PomBase community curation tool
https://curation.pombase.org
Other
19 stars 7 forks source link

Make tooltips more responsive on mouse-over #2397

Closed ValWood closed 3 years ago

ValWood commented 3 years ago

This has always been a bit of a bug-bear, but this is often so slow that it does not appear when you hover over.

For instance here:

Screenshot 2021-01-26 at 15 59 15

New users really need to know why they can't make phenotype annotations at this point. I expected a pop-up but did not see one. I eventually saw it appear a while later.

Is there a different plug in that would do this more quickly (or maybe it's a precision issue? does it only work when you are precisely over the text, and not the text background?).

Also, I wondered why "pathogen host interaction phenotype" was not greyed out at this point too?

ValWood commented 3 years ago

I see now that "pathogen host interaction phenotype" has a clickable pop-up. I think we should be consistent here.

Also Metagenotype pop-up says "Add at least one host organism and at least one pathogen genotype to make a metagenotype.

Maybe it would be useful to say Metagenotypes are used to curate "pathogen-host interaction phenotypes". Add at least one host organism and at least one pathogen genotype to make a metagenotype.

This would make it easier for people to connect the genotype type to the phenotype type in their minds.

ValWood commented 3 years ago

I was in advance mode for all the above comments. ~Is advanced mode available to users?~ no

kimrutherford commented 3 years ago

New users really need to know why they can't make phenotype annotations at this point. I expected a pop-up but did not see one. I eventually saw it appear a while later.

We're currently using the build in browser functionality for those pop-ups. There is no control over how long the browser waits. It's quite quick in Firefox. We can change to use a library to make more fancy pop-up where we can control the wait time.

Is there a different plug in that would do this more quickly

We'll use the same library we use in other places. We don't use it very often. We should be more consistent.

(or maybe it's a precision issue? does it only work when you are precisely over the text, and not the text background?).

That will currently depend on the browser and possible the OS. We'll have more control when we switch to using the library.

Also, I wondered why "pathogen host interaction phenotype" was not greyed out at this point too?

Just an oversight I think.

I see now that "pathogen host interaction phenotype" has a clickable pop-up. I think we should be consistent here.

Yep, definitely. I think that pop-up is for meant for genotype-genotype interactions which is why the text is a bit odd. As you say it would be better to be consistent so I think we should have a mouse-over in this case, not a pop-up. We can use your suggested text in a mouse-over instead of a pop-up.

Is advanced mode available to users?

Yep, it's available to all users, but it's off by default for new users.

@jseager7: I'm think of using uib-tooltip for these mouse-overs.

kimrutherford commented 3 years ago

Also, I wondered why "pathogen host interaction phenotype" was not greyed out at this point too?

I've fixed that problem.

@jseager7 could you re-deploy PHI-Canto when you get a chance?

kimrutherford commented 3 years ago

We can change to use a library to make more fancy pop-up where we can control the wait time.

I've changed from the build-in browser tool-tips to the code we use in a few other places. It pops up instantly for me now. I haven't made any changes to the text yet.

ValWood commented 3 years ago

It pops up faster (possibly?) but I still seem to need to be very precise with my mouse-over in order for the pop-up to appear (using PomBase Canto) Note that PomBase Canto does not seem to have pop-up for "genotype management" or "quick-links". I tested on the gene page-specific links.

kimrutherford commented 3 years ago

It pops up faster (possibly?) but I still seem to need to be very precise with my mouse-over in order for the pop-up to appear (using PomBase Canto)

Sorry, I should have said, because your screenshot with from PHI-Canto, I've only changed the main Canto code not the old code used by pombe Canto.

Note that PomBase Canto does not seem to have pop-up for "genotype management"

There isn't a pop-up for that yet. I can add one if you let me know what text you'd like.

The quick links in pombe Canto are never greyed out so you won't see any pop-ups there.

ValWood commented 3 years ago

OK, will test when in PHI-Canto

jseager7 commented 3 years ago

@kimrutherford Thanks for the help. I'll deploy this on the server shortly.

jseager7 commented 3 years ago

@ValWood I've deployed this change on both the main and demo server now. If you want to test it immediately, I've created a session on the demo server with no alleles or host species added: PMID:999999

ValWood commented 3 years ago

Much better, thanks for that!

kimrutherford commented 3 years ago

Note that PomBase Canto does not seem to have pop-up for "genotype management"

There isn't a pop-up for that yet. I can add one if you let me know what text you'd like.

If you let me know what text you'd like, I'll add it and then close the issue.

ValWood commented 3 years ago

PomBase mouse over for "Add, view and edit genotypes". To make multi-locus phenotype annotations genotypes must be combined here first.

In the PomBase single gene workflow we could also add

~"Single allele Phenotype " pop-up Add single gene allele and phenotype annotations. To make multi-locus phenotype annotations genotypes must be created and combined in "Genotype management" first.~ see below

I think this would be useful as we still get questions about this part of the workflow.

@mah could you edit?

mah11 commented 3 years ago

@mah could you edit?

First, two questions:

thanks :)

ValWood commented 3 years ago

Sorry, not clear, these texts are for PomBase. Right, I thought the question marks only linked to the docs, I didn't realise they also had a pop-up.

It might be useful if the first point for single gene phenotypes was clearly more clearly "you need to go to genotypes first to make multi-locus phenotype annotations" This is still one of the most common mistakes. Either people still as how to do multi-locus, or quite often they will stick the other gene in conditions field, or a comment. An up front reminder would. be useful.

I bolded the points I was trying to make above.

Maybe we can we extend "one or more mutations or an expression change in one copy of a gene at one locus"

to Use for one or more mutations or an expression change in one copy of a gene at one locus. To create multi-locus phenotype annotations genotypes must first be created and combined in "Genotype management".

would that work?

Also, would there be any objection to making the mouse over appear on mouse over the text in addition to the "?"

jseager7 commented 3 years ago

Also, would there be any objection to making the mouse over appear on mouse over the text in addition to the "?"

If the tooltips appear immediately then it could get a bit distracting for curators if they glide their mouse over the list when choosing an option. Tooltips are typically more common for parts of the user interface that are inherently ambiguous, like icons, not so much for text links that are already somewhat self-explanatory.

If we do decide to have tooltips on the links then I don't think we should have the same text on the help icons as well. It just seems redundant.

I think I'd be in favour of personalising the text in the tooltips on the help icons (offering more guidance about the relevant annotation type), because currently the text is all very generic: 'Click for help on [annotation type] (Click to visit documentation)'


P.S. 'tooltip' is the technical (or at least conventional) name for the little interface elements that temporarily appear on mouse-over.

ValWood commented 3 years ago

OK tool tips should be restricted to the icons. I agree they would be distracting. Probably the more responsive pop-ups will improve this a lot anyway. We don't see this yet in pombe-Canto

mah11 commented 3 years ago

Well, I've just realized that part of the issue here is that the "?"s don't all behave the same way. The ones in headers just spawn little "sticky" popups with a slightly different look than the tooltips (see me using my new vocabulary).

Furthermore, "Genotype management" has a relevant "?" with a popup in the "Annotate genotypes" header on the summary page, but doesn't have the kind of "?" that links to the relevant documentation anywhere.

So ... in light of the most recent comments from Val and James, I gather we could do with:

If that sounds right I'll work on the text.

mah11 commented 3 years ago

on this point

Also, would there be any objection to making the mouse over appear on mouse over the text in addition to the "?"

If the tooltips appear immediately then it could get a bit distracting for curators if they glide their mouse over the list when choosing an option.

I don't use the gene-specific pages anywhere near often enough to have a strong preference. But more generally, I do find over-eager tooltips annoying (e.g. on the GitHub ticket lists ... those are positively maddening, and there's more than one kind!!!) because they tend obscure link text that I was trying to read.

ValWood commented 3 years ago

If that sounds right I'll work on the text.

Please, that would be brill.

But more generally, I do find over-eager tooltips annoying

OK agreed, it would be annoying to see them all the time.

jseager7 commented 3 years ago

Well, I've just realized that part of the issue here is that the "?"s don't all behave the same way. The ones in headers just spawn little "sticky" popups with a slightly different look than the tooltips (see me using my new vocabulary).

The ones that spawn pop-ups are using some older code, and there's really no reason for the inconsistency, especially on the gene page. They should probably all be migrated to the tooltip system, so I'll open an issue for that.

mah11 commented 3 years ago

OK, here's the first chunk of suggestions: On the summary page, change "Annotate genotypes" popup text (I think this is independent of whether it changes to tooltip style).

PomBase version: Add single- or multi-locus genotypes, for haploids or diploids, to use in annotating phenotypes. Genotypes include alleles, expression levels, and optional background details. You can add genotypes individually as you go through the paper, or all at once before you start adding phenotype annotations.

PHI-Canto version: Add single- or multi-locus genotypes for hosts or pathogens, and combine host and pathogen genotypes into metagenotypes, to use in annotating phenotypes. Genotypes include alleles, expression levels, and optional background details. You can add genotypes individually as you go through the paper, or all at once before you start adding phenotype annotations.

mah11 commented 3 years ago

And here are tooltip suggestions for the curation types on gene-specific pages:

type PomBase tooltip text
GO molecular function Annotate a gene product's molecular activity. Click "?" to visit documentation.
GO biological process Annotate a gene product's role in a process. Click "?" to visit documentation.
GO cellular component Annotate the location in a cell where a gene product acts. Click "?" to visit documentation.
Single allele Phenotype Annotate phenotypes for single mutants (i.e. mutation(s) or expression change in one copy of a gene at one locus). Use "Genotype management" for multi-locus (e.g. double mutant) genotypes and their phenotypes. Click "?" to visit documentation.
Protein modification Annotate the type, position, timing, etc. of covalent protein modifications. Click "?" to visit documentation.
Wild-type RNA level Annotate qualitative descriptions for the normal level and timing of RNA expression from a gene. Click "?" to visit documentation.
Wild-type Protein level Annotate qualitative descriptions for the normal level and timing of protein expression from a gene. Click "?" to visit documentation.
Genetic interaction Annotate interaction type and interacting genes. Click "?" to visit documentation.
Physical interaction Annotate interacting gene products and supporting evidence. Click "?" to visit documentation.

Notes:

ValWood commented 3 years ago

Looks good.

jseager7 commented 3 years ago

These changes are ready to be enabled now. Some notes:

image

ValWood commented 3 years ago

OK should we go ahead and implement these changes?

jseager7 commented 3 years ago

Note that the changes are already enabled for PHI-Canto. I'm not sure about the PomBase version of Canto, since I think that's being held behind the latest release of the code.

ValWood commented 3 years ago

OK can close. If there are any issues we can open new tickets once we are in synch...