sec: enforce global auth and remove registration
This commit is contained in:
18
internal/templates/auth.templ
Normal file
18
internal/templates/auth.templ
Normal file
@@ -0,0 +1,18 @@
|
||||
package templates
|
||||
|
||||
templ Login() {
|
||||
@Layout("Login") {
|
||||
<h2>Login</h2>
|
||||
<form action="/login" method="POST" style="max-width: 300px; margin: 0 auto; padding: 20px; border: 1px solid var(--border); background-color: var(--bg);">
|
||||
<div style="margin-bottom: 15px;">
|
||||
<label for="username" style="display: block; margin-bottom: 5px;">Email</label>
|
||||
<input type="text" id="username" name="username" required style="width: 100%; padding: 8px; box-sizing: border-box;" />
|
||||
</div>
|
||||
<div style="margin-bottom: 15px;">
|
||||
<label for="password" style="display: block; margin-bottom: 5px;">Password</label>
|
||||
<input type="password" id="password" name="password" required style="width: 100%; padding: 8px; box-sizing: border-box;" />
|
||||
</div>
|
||||
<button type="submit" style="width: 100%; padding: 10px; cursor: pointer;">Login</button>
|
||||
</form>
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user