-
Notifications
You must be signed in to change notification settings - Fork 12
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
Change the color of the scale depending on external conditions. #11
Comments
@deviashin sorry, i got busy didn't have time to take a look, did you work it out? |
Hello! No, unfortunately, I still need help. Under normal circumstances, this works, but in relation to your schedules - it just disappears. I can’t understand how to write code correctly |
@deviashin your code should work, if you change
|
Oh, those square brackets [ ] |
Hello!
There is a structure "if else" as a result of which should change the color of the scale.
Please, how to do this?
Should get something like this:
var color;
if (condition) { color = "rgb(30, 148, 249)"; } else { color = "rgb(229, 73, 7)"; }
datasets: [ { data: [var], backgroundColor: 'color', } ]
The text was updated successfully, but these errors were encountered: