summaryrefslogtreecommitdiff
path: root/views/account_mail_verify.pug
diff options
context:
space:
mode:
authorTor Andersson <tor@ccxvii.net>2025-05-01 22:04:10 +0200
committerTor Andersson <tor@ccxvii.net>2025-05-12 00:21:06 +0200
commit9f67e66b83d158b99582c2984fc253b6e6abd537 (patch)
tree9ccd06c22afdafa4607c012f4b99deeb0b87a3c8 /views/account_mail_verify.pug
parent1eaa2ef7ca02e1534ba5f1baefdc794f675065e0 (diff)
downloadserver-9f67e66b83d158b99582c2984fc253b6e6abd537.tar.gz
Simplify form post actions.HEADmaster
Put account management pages under "/account" URL prefix. Set logged in user in res.locals for use in pug templates. Tweak verification flow. Require password to change name and mail. Show user statistics on profile (use pug mixin). Remove "api" prefix on many routes.
Diffstat (limited to 'views/account_mail_verify.pug')
-rw-r--r--views/account_mail_verify.pug32
1 files changed, 32 insertions, 0 deletions
diff --git a/views/account_mail_verify.pug b/views/account_mail_verify.pug
new file mode 100644
index 0000000..fddf2fa
--- /dev/null
+++ b/views/account_mail_verify.pug
@@ -0,0 +1,32 @@
+//- vim:ts=4:sw=4:
+doctype html
+html
+ head
+ include head
+ title Verify mail
+ body
+ include header
+ article
+ h1 Verify mail
+ if flash
+ p.error= flash
+
+ p Your mail address is <code>#{user.mail}</code>
+
+ p If the above address is wrong, you can <a href="/account/change-mail">change it</a>!
+
+ if sent_token
+ p Your token is in the mail!
+ else
+ form(method="post" action="/account/mail/verify-send")
+ p
+ button(type="submit") Send token
+
+ form(method="post")
+ p
+ label Enter your mail verification token here:
+ br
+ input(type="text" name="token" size=32 value=token style="font-family:monospace" required)
+ p
+ button(type="submit") Verify
+