feat: add public leaderboards with opt-out privacy setting

This commit is contained in:
2026-03-07 15:06:42 -08:00
committed by Naomi Carrigan
parent bbdacf272c
commit 3515de62ee
12 changed files with 525 additions and 0 deletions
+5
View File
@@ -2,6 +2,7 @@ import { useState } from "react";
import { GameProvider } from "./context/GameContext.js";
import { CharacterPage } from "./components/game/CharacterPage.js";
import { GameLayout } from "./components/game/GameLayout.js";
import { LeaderboardPage } from "./components/game/LeaderboardPage.js";
import { LoginPage } from "./components/game/LoginPage.js";
import { ProfilePage } from "./components/game/ProfilePage.js";
@@ -49,6 +50,10 @@ export const App = (): React.JSX.Element => {
return <CharacterPage discordId={characterDiscordId} />;
}
if (window.location.pathname === "/leaderboards") {
return <LeaderboardPage />;
}
if (!loggedIn) {
return <LoginPage onLogin={() => { setLoggedIn(true); }} />;
}