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

"label" should accept controller's variables #60

Open
Tails128 opened this issue Sep 12, 2018 · 0 comments
Open

"label" should accept controller's variables #60

Tails128 opened this issue Sep 12, 2018 · 0 comments

Comments

@Tails128
Copy link

Hi,

I'm facing a specific use-case:
I am using a time which i want to display in minutes, but in order to keep the animation smooth I need to use the time as seconds (e.g: with max=1m i'd like to display 60 ticks).
In order to do this I've set label-only=true and i am updating the label with something like this:

minutes = Math.ceil(seconds / 60);
label = '${minutes} m';

Currently the way to make this work is to:

  • give the gauge an id
  • let gauge = document.getElementById(id);
  • get child <b> from gauge
  • change <b>'s innerhtml
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

1 participant