You've already forked dynamic-badges-action
Update index.js
Removed automatically set message. Co-authored-by: Simon Schneegans <code@simonschneegans.de>
This commit is contained in:
6
index.js
6
index.js
@@ -41,11 +41,9 @@ try {
|
|||||||
if (val > max) val = max;
|
if (val > max) val = max;
|
||||||
let hue = 0
|
let hue = 0
|
||||||
if (invertColorRange == '') {
|
if (invertColorRange == '') {
|
||||||
hue = Math.floor((val - min) / (max - min) * 100);
|
hue = Math.floor((val - min) / (max - min) * 120);
|
||||||
content.message = val + " / " + max + " " + content.message
|
|
||||||
} else {
|
} else {
|
||||||
hue = Math.floor((max - val) / (max - min) * 100);
|
hue = Math.floor((max - val) / (max - min) * 120);
|
||||||
content.message = valColorRange + " " + content.message
|
|
||||||
}
|
}
|
||||||
content.color = "hsl(" + hue + ", 100%, 50%)";
|
content.color = "hsl(" + hue + ", 100%, 50%)";
|
||||||
} else if (color != '') {
|
} else if (color != '') {
|
||||||
|
|||||||
Reference in New Issue
Block a user