GoBlog/templates/login.gohtml

26 lines
1.1 KiB
Plaintext

{{ define "title" }}
<title>{{ string .Blog.Lang "login" }} - {{ mdtext .Blog.Title }}</title>
{{ end }}
{{ define "main" }}
<main>
<h1>{{ string .Blog.Lang "login" }}</h1>
<form class="fw p" method="post">
<input type="hidden" name="loginaction" value="login">
<input type="hidden" name="loginmethod" value="{{ .Data.loginmethod }}">
<input type="hidden" name="loginheaders" value="{{ .Data.loginheaders }}">
<input type="hidden" name="loginbody" value="{{ .Data.loginbody }}">
<input type="text" name="username" autocomplete="username" placeholder="{{ string .Blog.Lang "username" }}">
<input type="password" name="password" autocomplete="current-password" placeholder="{{ string .Blog.Lang "password" }}">
{{ if .Data.totp }}
<input type="text" name="token" inputmode="numeric" pattern="[0-9]*" autocomplete="one-time-code" placeholder="{{ string .Blog.Lang "totp" }}">
{{ end }}
<input type="submit" value="{{ string .Blog.Lang "login" }}">
</form>
{{ include "author" . }}
</main>
{{ end }}
{{ define "login" }}
{{ template "base" . }}
{{ end }}