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

f7Gauge valueText #84

Closed
tanho63 opened this issue Mar 7, 2020 · 1 comment
Closed

f7Gauge valueText #84

tanho63 opened this issue Mar 7, 2020 · 1 comment

Comments

@tanho63
Copy link
Contributor

tanho63 commented Mar 7, 2020

Hi all! In one of the recent commits, valueText was removed as a parameter from f7Gauge with the comment

It does not make sense that the value can be accidentally different from the text displayed. valueText is then an internal parameter.

I think it would be better to try to default valueText to be equal to the value parameter but allow for customization - this gives it a natural default but also some easy flexibility for developers.

In the documentation for Gauge there are several examples of useful "value-text" customizations - namely, adding units, currency symbols, or showing the raw numbers used in the proportion.

image

In my case, I'd like to use valueText in my app because I want to use it as a graphic for "balance from a trade" and would show difference from 50% (i.e. perfectly equal).

Thus in the image below I'd use 40% as the "value parameter" but would want to display "10% in favor of team B" - and it would be nice to be able to show that with the 10% nested into the centre of the gauge.

image

@DivadNojnarg
Copy link
Member

Hi Tan,
if you already have the code, you may propose a pull request!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants