Commit 053d4060 by Dominik Prokop

Fix thresholds default colors not being applied

parent 778ed912
...@@ -199,6 +199,7 @@ $arrowSize: 15px; ...@@ -199,6 +199,7 @@ $arrowSize: 15px;
margin: 0; margin: 0;
float: left; float: left;
z-index: 0; z-index: 0;
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAMCAIAAADZF8uwAAAAGUlEQVQYV2M4gwH+YwCGIasIUwhT25BVBADtzYNYrHvv4gAAAABJRU5ErkJggg==);
} }
.sp-preview-inner, .sp-preview-inner,
......
...@@ -198,6 +198,7 @@ export class ThresholdManager { ...@@ -198,6 +198,7 @@ export class ThresholdManager {
} }
let fillColor, lineColor; let fillColor, lineColor;
switch (threshold.colorMode) { switch (threshold.colorMode) {
case 'critical': { case 'critical': {
fillColor = 'rgba(234, 112, 112, 0.12)'; fillColor = 'rgba(234, 112, 112, 0.12)';
...@@ -215,6 +216,12 @@ export class ThresholdManager { ...@@ -215,6 +216,12 @@ export class ThresholdManager {
break; break;
} }
case 'custom': { case 'custom': {
if (!threshold.fillColor) {
threshold.fillColor = 'rgba(255, 255, 255, 1)';
}
if (!threshold.lineColor) {
threshold.lineColor = 'rgba(255, 255, 255, 0)';
}
fillColor = threshold.fillColor; fillColor = threshold.fillColor;
lineColor = threshold.lineColor; lineColor = threshold.lineColor;
break; break;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment