aboutsummaryrefslogtreecommitdiffhomepage
path: root/frontend/app/components/Gaming/Score.tsx
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2025-09-17 19:14:32 +0900
committernsfisis <nsfisis@gmail.com>2025-09-17 19:23:56 +0900
commitfaff26b13da82747fb0efdb6bf1312a9b14d3916 (patch)
treeeb510dc3f92bdb916ff5bdc1191763ff48cf4332 /frontend/app/components/Gaming/Score.tsx
parent4615ca9b8b1989d315ae2322556697b97161b97b (diff)
downloadiosdc-japan-2025-albatross-faff26b13da82747fb0efdb6bf1312a9b14d3916.tar.gz
iosdc-japan-2025-albatross-faff26b13da82747fb0efdb6bf1312a9b14d3916.tar.zst
iosdc-japan-2025-albatross-faff26b13da82747fb0efdb6bf1312a9b14d3916.zip
feat(backend,frontend): implement tournament page
Diffstat (limited to 'frontend/app/components/Gaming/Score.tsx')
-rw-r--r--frontend/app/components/Gaming/Score.tsx4
1 files changed, 2 insertions, 2 deletions
diff --git a/frontend/app/components/Gaming/Score.tsx b/frontend/app/components/Gaming/Score.tsx
index 9b6283f..b4a415c 100644
--- a/frontend/app/components/Gaming/Score.tsx
+++ b/frontend/app/components/Gaming/Score.tsx
@@ -13,8 +13,8 @@ export default function Score({ status, score }: Props) {
if (status === "running") {
intervalId = setInterval(() => {
- const maxValue = Math.pow(10, String(score).length) - 1;
- const minValue = Math.pow(10, String(score).length - 1);
+ const maxValue = Math.pow(10, String(score ?? 100).length) - 1;
+ const minValue = Math.pow(10, String(score ?? 100).length - 1);
const randomValue =
Math.floor(Math.random() * (maxValue - minValue + 1)) + minValue;
setDisplayScore(randomValue);