Restyle UI with Tailwind CSS: consistent cards, forms, tables and badges across all pages

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
This commit is contained in:
lofyer
2026-07-04 07:54:22 +08:00
co-authored by factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
parent 628246c5c5
commit 08b32d2aa9
9 changed files with 466 additions and 277 deletions
+20 -9
View File
@@ -4,16 +4,27 @@
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Login - WireGuard Admin</title>
<link rel="stylesheet" href="/static/style.css">
<script src="/static/tailwind.js"></script>
</head>
<body class="login-page">
<div class="login-box">
<h1>WireGuard Admin</h1>
{% if error %}<p class="error">{{ error }}</p>{% endif %}
<form method="post" action="/login">
<label>Username <input name="username" autofocus required></label>
<label>Password <input name="password" type="password" required></label>
<button type="submit">Sign in</button>
<body class="flex min-h-screen items-center justify-center bg-slate-900">
<div class="w-80 rounded-xl bg-white p-8 shadow-2xl">
<h1 class="mb-6 text-center text-xl font-bold text-slate-800">WireGuard Admin</h1>
{% if error %}
<p class="mb-4 rounded-md bg-red-50 px-3 py-2 text-sm text-red-700">{{ error }}</p>
{% endif %}
<form method="post" action="/login" class="space-y-4">
<label class="block text-sm font-medium text-slate-600">Username
<input name="username" autofocus required
class="mt-1 w-full rounded-md border border-slate-300 px-3 py-2 text-sm focus:border-blue-500 focus:outline-none focus:ring-1 focus:ring-blue-500">
</label>
<label class="block text-sm font-medium text-slate-600">Password
<input name="password" type="password" required
class="mt-1 w-full rounded-md border border-slate-300 px-3 py-2 text-sm focus:border-blue-500 focus:outline-none focus:ring-1 focus:ring-blue-500">
</label>
<button type="submit"
class="w-full rounded-md bg-blue-600 py-2 text-sm font-semibold text-white hover:bg-blue-700">
Sign in
</button>
</form>
</div>
</body>