black-mirror-1 / singlestat-math

Panel based on the default single stat panel with added feature to do math across metrics from multiple queries.
MIT License
14 stars 14 forks source link

Map gauge numerical value color to scaled math value #31

Open techfixpros opened 5 years ago

techfixpros commented 5 years ago

The gauge bar color updates properly with the scaled math value, but the numerical gauge value still follows the unscaled metric A value. Example: metric A is -5, metric B is -17, and the math formula is A-B, the gauge correctly shows 12. The gauge bar is correctly colored per the thresholds, but the numerical value is coloring based on metric A of -5.

petemyron commented 5 years ago

this might be related:

image

Note:

techfixpros commented 5 years ago

I believe you are describing the same symptoms. Here are screenshots of my gauge with the only difference between them being the addition/removal of the math formula to convert the raw to scaled (celcius to farenheit).

raw

scaled

The top image is the raw celcius value with the correct color gauge bar and numeral.

The bottom image is the scaled value using the math field, with the correct color gauge bar, while the numeral is still using the raw value.