Skip to content

Commit

Permalink
fix: display grey colored zero uptime while loading
Browse files Browse the repository at this point in the history
  • Loading branch information
agrrh committed Dec 10, 2023
1 parent 7294945 commit 0e26a53
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions frontend/src/lib/Component.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
export let view = 'quarter';
export let name = 'changeme';
export let uptime = 1.0;
export let uptime = 0.0;
export let observations = [];
export let tickCapacitySeconds = 60;
Expand Down Expand Up @@ -35,7 +35,10 @@
return [proto, hostAndPath];
}
if (uptime > thresholds[0]) {
if (dummy) {
uptimeStateClasses = 'has-text-grey';
}
else if (uptime > thresholds[0]) {
uptimeStateClasses = 'has-text-success';
} else if (uptime > thresholds[1]) {
uptimeStateClasses = 'has-text-warning-dark';
Expand Down

0 comments on commit 0e26a53

Please sign in to comment.