eweitz / ideogram

Chromosome visualization for the web
https://eweitz.github.io/ideogram
Other
288 stars 72 forks source link

Instantly summarize interaction direction #294

Closed eweitz closed 2 years ago

eweitz commented 2 years ago

This smoothens hovering over an interacting gene tooltip in the related genes kit.

Jank in the tooltip had been caused by fetching GPML pathway data upon hover. The relevant endpoints were reasonably fast, but even 200 ms of rearranging text is enough to substantially degrade a quick gesture like tooltip hovering.

Now, such GPML data is fetched immediately after retrieving crude interaction data, and it's done in the background. This is made performant via the ixn NPM package, which distributes compressed GPML data over the jsDelivr CDN. The files are typically ~10x smaller than fetched via the WikiPathways API, and they're served more performantly due to CDN caching and protocols, and with much higher availability.

Here's how it looks. Note how the tooltip content does not momentarily rearrange, as before.

https://user-images.githubusercontent.com/1334561/154066992-a40b3e19-d934-4c31-9803-dad243e46356.mov