Tidying up some stuff
This commit is contained in:
@@ -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;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -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) {
|
||||||
|
|||||||
Reference in New Issue
Block a user