higlass / higlass-transcripts

Gene transcripts track for HiGlass
MIT License
6 stars 2 forks source link

Transcripts track starts in collapsed mode unless `options.startCollapsed` is manually set #2

Closed alexpreynolds closed 3 years ago

alexpreynolds commented 3 years ago

The README for higlass-transcripts indicates that the default value of options.startCollapsed is false.

However, when I add a horizontal-transcripts track to my viewconf and leave all options unchanged (so that I am using the plugin defaults), the transcript track is rendered in collapsed mode (as if the default value of options.startCollapsed is actually true).

In this case, the transcripts track only shows one row of annotations, even if the genomic range in my HiGlassContainer view should contain multiple overlapping transcripts. The "Show More Transcripts" label is shown, and clicking on it will expand the transcripts track to show all overlapping transcripts, so it otherwise appears to behave correctly.

However, if I manually specify options.startCollapsed = false in the viewconf I am passing to my HiGlassContainer, the transcript track will be set up in "expanded" mode and show all transcripts within the genomic range. The "Show Fewer Transcripts" label is shown and behaves correctly.

alexpreynolds commented 3 years ago

This may be the relevant line: https://github.com/higlass/higlass-transcripts/blob/9b8b66cad400bd182b5b78996fed78199214493b/src/scripts/TranscriptsTrack.js#L1696

alexpreynolds commented 3 years ago

I changed the default in https://github.com/higlass/higlass-transcripts/pull/3 to reflect what the README states.