Skip to content

High performance, self-hosted, newsletter and mailing list manager with a modern dashboard. Single binary app.

968 B
Raw Blame
{{ define "admin-twofa" }}
{{ template "admin-public-header" .}}

<section>
	<h4 class="page-title">{{ .L.T "users.twoFA"}}</h4>

	<form method="post" action="/admin/login/twofa">
		<input type="hidden" name="token" value="{{ .Data.Token }}" />
		<input type="hidden" name="next" value="{{ .Data.NextURI }}" />
		<div data-field>
			<input id="totp_code" class="align-center" inputmode="numeric" autocomplete="one-time-code" type="text" name="totp_code" autofocus required
			pattern="[0-9]{6}" maxlength="6" placeholder="• • • • • •" aria-label="{{ .L.T "users.totpCode" }}" aria-describedby="totp-help" />
			<small id="totp-help" data-hint>{{ .L.T "users.totpCodeHelp" }}</small>
		</div>

		{{ if .Data.Error }}<div role="alert" data-variant="danger" class="mb-4">{{ .Data.Error }}</div>{{ end }}

		<button class="w-100" type="submit">{{ .L.T "globals.buttons.continue" }}</button>
	</form>
</section>

{{ template "admin-public-footer" .}}
{{ end }}