add guest login to login page

This commit is contained in:
Wingy 2022-10-03 10:40:14 -04:00
parent 9685c7f909
commit 0086399678
2 changed files with 16 additions and 1 deletions

View file

@ -66,6 +66,9 @@ module.exports.strings = {
CONFIRM_ACCOUNT_SET_PW_TEXT: name => `Hello ${name}! Please set your password here.`,
CONFIRM_ACCOUNT_SUCCESS: `Welcome to ${_CC.config.siteTitle}!`,
LOGIN_BUTTON: 'Log In',
LOGIN_GUEST_PASSWORD_PLACEHOLDER: 'p4ssw0rd;',
LOGIN_GUEST_PASSWORD: 'Guest Password',
LOGIN_GUEST: 'Log In as a Guest',
LOGIN_PASSWORD_PLACEHOLDER: 'pa$$word!',
LOGIN_PASSWORD: 'Password',
LOGIN_USERNAME_PLACEHOLDER: 'john',

View file

@ -17,4 +17,16 @@ block content
.field
.control
input.button.is-primary(type='submit' value=lang('LOGIN_BUTTON'))
if _CC.config.guestPassword
hr
h3= lang('LOGIN_GUEST')
form(method='POST', action='/login/guest')
.field
label.label= lang('LOGIN_GUEST_PASSWORD')
.control.has-icons-left
input.input(type='password', name='guestpassword', placeholder=lang('LOGIN_GUEST_PASSWORD_PLACEHOLDER'))
span.icon.is-small.is-left
i.fas.fa-lock
.field
.control
input.button.is-primary(type='submit', value=lang('LOGIN_BUTTON'))