tangled
alpha
login
or
join now
willdot.net
/
cocoon
forked from
hailey.at/cocoon
0
fork
atom
An atproto PDS written in Go
0
fork
atom
overview
issues
pulls
pipelines
fix image display
hailey.at
8 months ago
abec4460
23cafe90
+7
-2
3 changed files
expand all
collapse all
unified
split
server
handle_account_totp_enroll.go
static
style.css
templates
totp_enroll.html
-1
server/handle_account_totp_enroll.go
···
40
40
sess.Values["totp-secret"] = secret.String()
41
41
if err := sess.Save(e.Request(), e.Response()); err != nil {
42
42
s.logger.Error("error saving session", "error", err)
43
43
-
44
43
return helpers.ServerError(e, nil)
45
44
}
46
45
+4
server/static/style.css
···
24
24
margin-bottom: 1.5em;
25
25
}
26
26
27
27
+
.center {
28
28
+
justify-content: center;
29
29
+
}
30
30
+
27
31
.centered-body {
28
32
min-height: 100vh;
29
33
justify-content: center;
+3
-1
server/templates/totp_enroll.html
···
19
19
<div class="alert alert-danger margin-bottom-xs">
20
20
<p>{{ index .flashes.errors 0 }}</p>
21
21
</div>
22
22
-
<img src="{{ .Image }}" class="totp-image" />
23
22
{{ end }}
23
23
+
<div class="center">
24
24
+
<img src="{{ .Image }}" class="totp-image" />
25
25
+
</div>
24
26
<form action="/account/totp-enroll" method="post">
25
27
<input name="code" id="code" placeholder="Code" />
26
28
<button class="primary" type="submit" value="Login">Enroll</button>