update for pc server

This commit is contained in:
2025-11-25 00:40:22 +01:00
parent 030cfcad9e
commit 0d1d388dca
6 changed files with 212 additions and 114 deletions

View File

@@ -27,40 +27,45 @@ const Login: React.FC = () => {
};
return (
<div className="min-h-screen flex items-center justify-center bg-gray-100">
<div className="bg-white p-8 rounded-lg shadow-md w-96">
<h2 className="text-2xl font-bold mb-6 text-center text-primary">ASF TestArena</h2>
{error && <div className="bg-red-100 text-red-700 p-2 rounded mb-4 text-sm">{error}</div>}
<div className="min-h-screen flex items-center justify-center bg-secondary">
<div className="bg-white p-8 rounded shadow-sm border border-gray-200 w-96">
<div className="flex justify-center mb-6">
<img src="/logo.png" alt="Logo" className="h-12 w-auto" />
</div>
<h2 className="text-xl font-bold mb-6 text-center text-primary">Sign In</h2>
{error && <div className="bg-red-50 text-red-700 p-2 rounded mb-4 text-sm border border-red-100 text-center">{error}</div>}
<form onSubmit={handleSubmit}>
<div className="mb-4">
<label className="block text-sm font-medium text-gray-700 mb-1">Username</label>
<div className="relative">
<User className="absolute left-3 top-2.5 h-5 w-5 text-gray-400" />
<User className="absolute left-3 top-2.5 h-4 w-4 text-gray-400" />
<input
type="text"
className="pl-10 w-full border border-gray-300 rounded-md p-2 focus:ring-accent focus:border-accent outline-none"
className="pl-9 w-full border border-gray-300 rounded p-2 text-sm focus:ring-1 focus:ring-accent focus:border-accent outline-none transition-all"
value={username}
onChange={(e) => setUsername(e.target.value)}
required
placeholder="Enter your username"
/>
</div>
</div>
<div className="mb-6">
<label className="block text-sm font-medium text-gray-700 mb-1">Password</label>
<div className="relative">
<Lock className="absolute left-3 top-2.5 h-5 w-5 text-gray-400" />
<Lock className="absolute left-3 top-2.5 h-4 w-4 text-gray-400" />
<input
type="password"
className="pl-10 w-full border border-gray-300 rounded-md p-2 focus:ring-accent focus:border-accent outline-none"
className="pl-9 w-full border border-gray-300 rounded p-2 text-sm focus:ring-1 focus:ring-accent focus:border-accent outline-none transition-all"
value={password}
onChange={(e) => setPassword(e.target.value)}
required
placeholder="Enter your password"
/>
</div>
</div>
<button
type="submit"
className="w-full bg-accent text-white py-2 rounded-md hover:bg-blue-600 transition-colors"
className="w-full bg-accent text-white py-2 rounded font-medium hover:bg-accent-hover transition-colors shadow-sm"
>
Login
</button>