Tidying up some stuff

This commit is contained in:
Stian Fredrik Aune
2021-03-14 18:56:04 +01:00
parent fe26f52c8d
commit e09eb107d3
2 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -117,7 +117,7 @@ export const CentreBoi = () => {
const stopRun = useCallback(() => { const stopRun = useCallback(() => {
if (state === "connected") { if (state === "connected") {
stop(); stop();
setHidden(false); setHidden(true);
return true; return true;
} }
+2 -2
View File
@@ -8,8 +8,8 @@ export const COLOR_VERY_GOOD = "#6F6";
export const COLOR_STONKS_GOOD = "#3A3"; export const COLOR_STONKS_GOOD = "#3A3";
export const colorByDiff = (diff, prevDiff, stonksDiff = 0) => { export const colorByDiff = (diff, prevDiff, stonksDiff = 0) => {
if (stonksDiff > 0 && diff > 0 && diff > stonksDiff) { if (stonksDiff > 0 && stonksDiff > prevDiff && diff > stonksDiff) {
return COLOR_STONKS_GOOD return COLOR_STONKS_GOOD;
} }
if (diff < 0) { if (diff < 0) {