aboutsummaryrefslogtreecommitdiffhomepage
path: root/frontend/app/components/Gaming/Score.tsx
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2026-03-06 02:18:40 +0900
committernsfisis <nsfisis@gmail.com>2026-03-06 02:18:40 +0900
commit46f9ba5d8c295454381655e6ec02ad3cf8bd79db (patch)
treec54719cb129ee05f96c4898219588062f71daa36 /frontend/app/components/Gaming/Score.tsx
parent27f509ccf4fbfeaa1bc2580ae2251461dc44ebfa (diff)
downloadphperkaigi-2026-albatross-46f9ba5d8c295454381655e6ec02ad3cf8bd79db.tar.gz
phperkaigi-2026-albatross-46f9ba5d8c295454381655e6ec02ad3cf8bd79db.tar.zst
phperkaigi-2026-albatross-46f9ba5d8c295454381655e6ec02ad3cf8bd79db.zip
style: switch from tab to space indentation in frontend and worker/php
Update biome.json indentStyle from "tab" to "space" and reformat all files in both workspaces. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Diffstat (limited to 'frontend/app/components/Gaming/Score.tsx')
-rw-r--r--frontend/app/components/Gaming/Score.tsx48
1 files changed, 24 insertions, 24 deletions
diff --git a/frontend/app/components/Gaming/Score.tsx b/frontend/app/components/Gaming/Score.tsx
index ee23a6c..8e1e61d 100644
--- a/frontend/app/components/Gaming/Score.tsx
+++ b/frontend/app/components/Gaming/Score.tsx
@@ -1,36 +1,36 @@
import { useEffect, useState } from "react";
type Props = {
- status: string | null;
- score: number | null;
+ status: string | null;
+ score: number | null;
};
export default function Score({ status, score }: Props) {
- const [randomScore, setRandomScore] = useState<number | null>(null);
+ const [randomScore, setRandomScore] = useState<number | null>(null);
- useEffect(() => {
- if (status !== "running") {
- return;
- }
+ useEffect(() => {
+ if (status !== "running") {
+ return;
+ }
- const intervalId = setInterval(() => {
- 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;
- setRandomScore(randomValue);
- }, 50);
+ const intervalId = setInterval(() => {
+ 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;
+ setRandomScore(randomValue);
+ }, 50);
- return () => {
- clearInterval(intervalId);
- };
- }, [status, score]);
+ return () => {
+ clearInterval(intervalId);
+ };
+ }, [status, score]);
- const displayScore = status === "running" ? randomScore : score;
+ const displayScore = status === "running" ? randomScore : score;
- return (
- <span className={status === "running" ? "animate-pulse" : ""}>
- {displayScore}
- </span>
- );
+ return (
+ <span className={status === "running" ? "animate-pulse" : ""}>
+ {displayScore}
+ </span>
+ );
}