Skip to content

Commit

Permalink
minor fix
Browse files Browse the repository at this point in the history
  • Loading branch information
lil5 committed Dec 18, 2024
1 parent c8b6d3a commit c68a65a
Showing 1 changed file with 11 additions and 10 deletions.
21 changes: 11 additions & 10 deletions src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,14 @@ function App() {
if (!version) return output;
let nextV = version;
const result: UpgradeItem[] = [...output];
let foundLo = 0;
// let foundLo = 0;
for (let i = result.length - 1; i >= 0; i--) {
const o = { ...result[i] };
if (o.v == version) {
o.color1 = "#f6d860";
if (o.v !== o.hi) {
nextV = o.hi;
o.color2 = "#37cdbe";
}
}
if (o.v == nextV) {
Expand All @@ -30,15 +31,15 @@ function App() {
nextV = o.hi;
}
}
if (o.u && foundLo == 0) {
foundLo = 1;
}
if (foundLo == 1) {
o.color3 = "#a991f7";
}
if (o.v == version) {
foundLo = 2;
}
// if (o.u && foundLo == 0) {
// foundLo = 1;
// }
// if (foundLo == 1) {
// o.color3 = "#a991f7";
// }
// if (o.v == version) {
// foundLo = 2;
// }
result[i] = o;
}
return result;
Expand Down

0 comments on commit c68a65a

Please sign in to comment.