Files
LEDMatrix/web_interface/templates/v3/login.html
T
ChuckandClaude Opus 5.5 ba6eccb489 build(web): generate the UI's Tailwind CSS with the pinned standalone CLI (#685)
Replaces the hand-written Tailwind subset in app.css with a real, purged
Tailwind build: scripts/build_css.py runs the pinned, SHA-256-checked
standalone Tailwind CLI (no Node), the generated tailwind.css and
plugin-frame.css are committed, and CI fails when they are stale. The Pi
never builds anything. The login page (#683) now links tailwind.css too,
and the load-order test covers every template that links app.css.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-30 09:38:16 -04:00

65 lines
3.2 KiB
HTML

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Log in - LED Matrix Control Panel</title>
<meta name="theme-color" content="#111827">
<link rel="icon" type="image/png" sizes="192x192" href="{{ url_for('static', filename='v3/icons/icon-192.png') }}">
<script>
// Same theme choice as the main interface (base.html), before CSS loads.
(function() {
var theme = null;
try { theme = localStorage.getItem('theme'); } catch (e) { /* private mode */ }
if (!theme) {
try {
theme = window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light';
} catch (e) { theme = 'light'; }
}
document.documentElement.setAttribute('data-theme', theme);
})();
</script>
<link rel="stylesheet" href="{{ url_for('static', filename='v3/vendor/fontawesome/css/all.min.css') }}">
<!-- Utilities from scripts/build_css.py; app.css second, as in base.html. -->
<link rel="stylesheet" href="{{ url_for('static', filename='v3/tailwind.css') }}">
<link rel="stylesheet" href="{{ url_for('static', filename='v3/app.css') }}">
<style>
.login-wrap { max-width: 24rem; margin: 0 auto; padding: 4rem 1rem; }
.login-error { border: 1px solid #fecaca; border-radius: 0.375rem; padding: 0.75rem; }
.login-help { margin-top: 1.5rem; }
</style>
</head>
<body class="bg-gray-50 min-h-screen">
<main class="login-wrap">
<div class="bg-white rounded-lg shadow p-6">
<h1 class="text-lg font-semibold text-gray-900 mb-2">
<i class="fas fa-tv text-blue-600 mr-2" aria-hidden="true"></i>LED Matrix Control
</h1>
<p class="text-sm text-gray-600 mb-6">This display's settings are protected by a password.</p>
{% if error %}
<div class="login-error bg-red-50 text-red-600 text-sm mb-4" role="alert">{{ error }}</div>
{% endif %}
<form method="post" action="{{ url_for('ledmatrix_auth.login') }}" class="space-y-4">
<input type="hidden" name="next" value="{{ next_path }}">
<div class="form-group">
<label for="password" class="block text-sm font-medium text-gray-700">Password</label>
<input type="password" id="password" name="password" required autofocus
autocomplete="current-password" class="form-control mt-1 w-full">
</div>
<button type="submit" class="btn bg-blue-600 hover:bg-blue-700 text-white px-4 py-2 rounded-md w-full">
<i class="fas fa-sign-in-alt mr-2" aria-hidden="true"></i>Log in
</button>
</form>
<p class="login-help text-sm text-gray-600">
Forgot it? On the Pi, run
<code class="bg-gray-100 font-mono">sudo python3 ~/LEDMatrix/scripts/reset_web_password.py</code>
(use the folder LEDMatrix is installed in), or open the interface from the Pi itself.
</p>
</div>
</main>
</body>
</html>