diff options
| author | Arda Serdar Pektezol <1669855+pektezol@users.noreply.github.com> | 2025-10-26 13:51:31 +0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-10-26 12:51:31 +0300 |
| commit | 6a631744d9c80ff9a1a9f4b278bc0337ecdb494e (patch) | |
| tree | 3acf1f505751d997b1b7482823eacabcb79a03f3 /frontend/src/components/Leaderboards.tsx | |
| parent | fix/frontend: tablet view logout button (#286) (diff) | |
| download | lphub-6a631744d9c80ff9a1a9f4b278bc0337ecdb494e.tar.gz lphub-6a631744d9c80ff9a1a9f4b278bc0337ecdb494e.tar.bz2 lphub-6a631744d9c80ff9a1a9f4b278bc0337ecdb494e.zip | |
chore/frontend: semicolon linting (#287)
Diffstat (limited to 'frontend/src/components/Leaderboards.tsx')
| -rw-r--r-- | frontend/src/components/Leaderboards.tsx | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/frontend/src/components/Leaderboards.tsx b/frontend/src/components/Leaderboards.tsx index 1a4aa48..073c21b 100644 --- a/frontend/src/components/Leaderboards.tsx +++ b/frontend/src/components/Leaderboards.tsx | |||
| @@ -6,7 +6,7 @@ import { MapLeaderboard } from "@customTypes/Map"; | |||
| 6 | import { ticks_to_time, time_ago } from "@utils/Time"; | 6 | import { ticks_to_time, time_ago } from "@utils/Time"; |
| 7 | import { API } from "@api/Api"; | 7 | import { API } from "@api/Api"; |
| 8 | import useMessage from "@hooks/UseMessage"; | 8 | import useMessage from "@hooks/UseMessage"; |
| 9 | import "@css/Maps.css" | 9 | import "@css/Maps.css"; |
| 10 | 10 | ||
| 11 | interface LeaderboardsProps { | 11 | interface LeaderboardsProps { |
| 12 | mapID: string; | 12 | mapID: string; |
| @@ -26,7 +26,7 @@ const Leaderboards: React.FC<LeaderboardsProps> = ({ mapID }) => { | |||
| 26 | 26 | ||
| 27 | React.useEffect(() => { | 27 | React.useEffect(() => { |
| 28 | _fetch_map_leaderboards(); | 28 | _fetch_map_leaderboards(); |
| 29 | }, [pageNumber, navigate]) | 29 | }, [pageNumber, navigate]); |
| 30 | 30 | ||
| 31 | if (!data) { | 31 | if (!data) { |
| 32 | return ( | 32 | return ( |
| @@ -103,14 +103,14 @@ const Leaderboards: React.FC<LeaderboardsProps> = ({ mapID }) => { | |||
| 103 | 103 | ||
| 104 | {r.kind === "multiplayer" ? ( | 104 | {r.kind === "multiplayer" ? ( |
| 105 | <span> | 105 | <span> |
| 106 | <button onClick={() => { message("Demo Information", `Host Demo ID: ${r.host_demo_id} \nParnter Demo ID: ${r.partner_demo_id}`) }}><img src={ThreedotIcon} alt="demo_id" /></button> | 106 | <button onClick={() => { message("Demo Information", `Host Demo ID: ${r.host_demo_id} \nParnter Demo ID: ${r.partner_demo_id}`); }}><img src={ThreedotIcon} alt="demo_id" /></button> |
| 107 | <button onClick={() => window.location.href = `/api/v1/demos?uuid=${r.partner_demo_id}`}><img src={DownloadIcon} alt="download" style={{ filter: "hue-rotate(160deg) contrast(60%) saturate(1000%)" }} /></button> | 107 | <button onClick={() => window.location.href = `/api/v1/demos?uuid=${r.partner_demo_id}`}><img src={DownloadIcon} alt="download" style={{ filter: "hue-rotate(160deg) contrast(60%) saturate(1000%)" }} /></button> |
| 108 | <button onClick={() => window.location.href = `/api/v1/demos?uuid=${r.host_demo_id}`}><img src={DownloadIcon} alt="download" style={{ filter: "hue-rotate(300deg) contrast(60%) saturate(1000%)" }} /></button> | 108 | <button onClick={() => window.location.href = `/api/v1/demos?uuid=${r.host_demo_id}`}><img src={DownloadIcon} alt="download" style={{ filter: "hue-rotate(300deg) contrast(60%) saturate(1000%)" }} /></button> |
| 109 | </span> | 109 | </span> |
| 110 | ) : r.kind === "singleplayer" && ( | 110 | ) : r.kind === "singleplayer" && ( |
| 111 | 111 | ||
| 112 | <span> | 112 | <span> |
| 113 | <button onClick={() => { message("Demo Information", `Demo ID: ${r.demo_id}`) }}><img src={ThreedotIcon} alt="demo_id" /></button> | 113 | <button onClick={() => { message("Demo Information", `Demo ID: ${r.demo_id}`); }}><img src={ThreedotIcon} alt="demo_id" /></button> |
| 114 | <button onClick={() => window.location.href = `/api/v1/demos?uuid=${r.demo_id}`}><img src={DownloadIcon} alt="download" /></button> | 114 | <button onClick={() => window.location.href = `/api/v1/demos?uuid=${r.demo_id}`}><img src={DownloadIcon} alt="download" /></button> |
| 115 | </span> | 115 | </span> |
| 116 | )} | 116 | )} |