Skip to content

Commit

Permalink
fixed zoom out on defocus in mobile device
Browse files Browse the repository at this point in the history
  • Loading branch information
tanmaylaud committed May 10, 2020
1 parent 5a67859 commit e9b32e6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -108,9 +108,9 @@ function Counter() {
}, []);
useEffect(() => {
if (counter != total) {
if (total - counter == 10000) setCounter(counter + 1);
else if (counter < 10000) setCounter(counter + 100);
else if (counter < 100000) setCounter(counter + 50);
if (total - counter <= 1000) setCounter(counter + 1);
else if (counter < 10000) setCounter(counter + 1000);
else setCounter(counter + 500);
}
}, [counter]);

Expand Down

0 comments on commit e9b32e6

Please sign in to comment.