biocore / biocore/empress

Synchronize "default lengths" between feature metadata / sample metadata / length-scaling feature metadata barplots

Open
#358 0 comments 0 reactions 1 assignee Claimed by @fedarko View on GitHub
barplots nice to have
Dominant language
JavaScript
Stars
56
Forks
32
PR merge metrics
No merged PRs in 30d

Description

## Desired changes

- On changing between sample and feature metadata barplots, the "Default length" / "Length" values should be updated to what they were in the previous tab.
- On enabling / disabling length scaling for feature metadata barplots, the "Maximum length" and "Default length" values should be updated to match each other.

These changes _might_ be frustrating if a user purposefully wants a sample metadata barplot with a different length than a feature metadata barplot or whatever, but for most users this should smooth out the UI.

## Discussion

From @ElDeveloper, in #357:

---

> I just noticed something a bit off with the bar scaling, maybe worth fixing here? When you click on the scale checkbox and you have a length different to 100 (the default), the maximum length is set by default to 100. I think this should by default be the maximum length so that bars don't shrink out of the blue. See this animated gif:
>
> ![default-length](https://user-images.githubusercontent.com/375307/91591318-9f076800-e911-11ea-9e41-d69c94f3ed9a.gif)
>
> Thoughts?

---

Another reply in #357:

---

> That's a really good point, and I agree that the UI for this is a bit confusing. Part of the challenge here is that, if the user has already done some length-scaling stuff for a layer, I'm not sure we want to mess with that when the user switches back to non-length-scaling -- do you think an acceptable compromise would be setting the "max length" for scaling to the default length the first time the "length scaling" checkbox is checked? Or maybe we should just update it every time.
>
> I guess in the same vein we should definitely synchronize the default lengths between feature and sample metadata barplots --
>
> ![asdf](https://user-images.githubusercontent.com/4177727/91617229-6c269980-e93c-11ea-9ee4-a050dca6014c.gif)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.