~gitpocket/gitpocket

4
848267183129ecda3eaa0dac260c280da4c00812
mainfeed-discovery
gitpocket/templates/register.html -rw-r--r--1.9 KiB ViewLogBlameView rawPermalink 6d62ad17e7 feat(admin): restyle the admin page with the site tabs and tables and require an email on sign up 11 hours ago
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
{{define "content"}}
<div class="auth">
<h3 class="rule">Register for {{.Host}} <small>or <a href="/login">log in</a></small></h3>
{{if eq .Data.Mode "closed"}}<p class="info">Registration is closed on {{.Host}}. Ask an administrator for an account.</p>{{else}}<p>Registration gives you a page at <code>~username</code>, repositories under it, SSH and HTTPS push, and pull requests on anything public. {{if eq .Data.AskEmail "off"}}No email is needed{{else if eq .Data.AskEmail "optional"}}An email address is optional{{else}}An email address is needed{{end}} and you are logged in straight away.</p>
<form method="post" action="/register" class="stack centred">
<label>Username <input name="name" required autofocus autocomplete="username" pattern="[a-z0-9][a-z0-9_.-]{0,38}" value="{{.Data.Name}}"><small>Lowercase letters, digits, dot, dash or underscore.</small></label>
<label>Password <input name="password" type="password" required minlength="8" autocomplete="new-password"></label>
{{if ne .Data.AskEmail "off"}}<label>Email{{if eq .Data.AskEmail "optional"}} <span class="muted">(optional)</span>{{end}} <input name="email" type="email" autocomplete="email" maxlength="200" value="{{.Data.Email}}"{{if eq .Data.AskEmail "required"}} required{{end}}><small>{{if .Data.Mail}}We send one link to confirm it, after which it can reset your password. {{end}}Never shown publicly.</small></label>{{end}}
{{if eq .Data.Mode "invite"}}<label>Invite code <input name="invite" required value="{{.Data.Invite}}"></label>{{end}}
<div class="actions"><button class="btn primary">Register ▸</button></div>
</form>{{end}}
<p class="privacy"><strong>Privacy notice</strong>: {{.Host}} stores your username, your email address, a hash of your password, the keys and profile details you choose to add, and the address of each failed login attempt for a few minutes. Nothing is collected for marketing or analytics and nothing is shared with third parties.</p>
</div>
{{end}}