Feat: Enable admin password in admin mode (#540)

* WIP: save local changes before merging
* Enable admin password in admin mode #374
This commit is contained in:
Burt
2025-11-05 21:48:28 +08:00
committed by GitHub
parent 96ed2c6ea7
commit 8b853a963d
13 changed files with 421 additions and 91 deletions

View File

@@ -14,7 +14,7 @@ import { useAuth } from '../contexts/AuthContext'
import { useLanguage } from '../contexts/LanguageContext'
import { t } from '../i18n/translations'
export function LandingPage() {
export function LandingPage({ isAdminMode = false }: { isAdminMode?: boolean }) {
const [showLoginModal, setShowLoginModal] = useState(false)
const { user, logout } = useAuth()
const { language, setLanguage } = useLanguage()
@@ -31,6 +31,7 @@ export function LandingPage() {
onLanguageChange={setLanguage}
user={user}
onLogout={logout}
isAdminMode={isAdminMode}
onPageChange={(page) => {
console.log('LandingPage onPageChange called with:', page)
if (page === 'competition') {