ui: center login page, add logo and title

Login now fills the viewport (min-h-screen flex items-center/justify-center)
with the logo, "Artifacto" title, and tagline above the password form.
Drops the header/footer chrome on this page since there's nothing to link
to before sign-in.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-04-22 23:15:42 +02:00
parent b1ff3ca80f
commit 1af1c3efe2

View File

@@ -1,12 +1,18 @@
{{ define "login" }} {{ define "login" }}
{{ template "head" "Log in" }} {{ template "head" "Log in" }}
{{ template "header" false }} <main class="min-h-screen flex items-center justify-center px-6 py-12">
<main class="max-w-6xl mx-auto px-6 py-8"> <div class="w-full max-w-sm">
<div class="max-w-sm mx-auto mt-16"> <div class="flex flex-col items-center text-center mb-8">
<h1 class="text-2xl font-semibold mb-4">Log in</h1> <img src="/static/logo.png" alt=""
class="w-20 h-20 rounded-full ring-1 ring-slate-700 mb-4 shadow-lg shadow-indigo-500/10">
<h1 class="text-3xl font-semibold tracking-tight">Artifacto</h1>
<p class="text-sm text-slate-400 mt-1">self-hosted HTML artifact publisher</p>
</div>
{{ if .Error }} {{ if .Error }}
<div class="rounded bg-red-900/40 border border-red-800 text-red-200 px-3 py-2 mb-3 text-sm">{{ .Error }}</div> <div class="rounded bg-red-900/40 border border-red-800 text-red-200 px-3 py-2 mb-3 text-sm">{{ .Error }}</div>
{{ end }} {{ end }}
<form method="post" action="/login" class="space-y-3"> <form method="post" action="/login" class="space-y-3">
<input type="hidden" name="next" value="{{ .Next }}"> <input type="hidden" name="next" value="{{ .Next }}">
<label class="block"> <label class="block">
@@ -18,5 +24,6 @@
</form> </form>
</div> </div>
</main> </main>
{{ template "footer" }} </body>
</html>
{{ end }} {{ end }}