pug login logout button changes

This commit is contained in:
Sam Hadow 2025-02-12 20:13:08 +01:00
parent 5cfb29131c
commit 021267f17d

View File

@ -8,7 +8,10 @@ html(lang="en-US")
script(src="/socket.io/socket.io.js", defer)
script(src="/script.js", defer)
script(type="module", src="/ecc.js", defer)
script(type="module", src="/popups.js", defer)
if isLoggedIn
script(src="/chat.js", defer)
else
script(type="module", src="/popups.js", defer)
link(rel="stylesheet" href="/css/bootstrap.min.css")
body
#mainbody
@ -19,31 +22,32 @@ html(lang="en-US")
.btn-group.mr-2(role="group", aria-label="register")
button#register.btn.btn-secondary(type="button") register
button#login.btn.btn-secondary(type="button") login
#registerPopup.popup
.popup-content
.btn-group.mr-2.w-100(role="group", aria-label="Add group")
input#sharedsecret.form-control.input-sm.w-50(type="password", placeholder="shared secret", required)
input#publickey.form-control.input-sm.w-50(type="text", placeholder="public key")
button#registerconfirm.btn.btn-secondary(type="button") register
button#registercancel.btn.btn-secondary(type="button") cancel
#registerPopupText
#loginPopup.popup
.popup-content
.btn-group.mr-2.w-100(role="group", aria-label="Add group")
input#privatekey.form-control.input-sm.w-50(type="password", placeholder="private key", required)
button#loginconfirm.btn.btn-secondary(type="button") login
button#logincancel.btn.btn-secondary(type="button") cancel
else
.btn-toolbar.btn-group-sm(role="toolbar", aria-label="Toolbar")
.btn-group.mr-2(role="group", aria-label="logout")
button#logout.btn.btn-secondary(type="button") logout
#registerPopup.popup
.popup-content
.btn-group.mr-2.w-100(role="group", aria-label="Add group")
input#sharedsecret.form-control.input-sm.w-50(type="password", placeholder="shared secret", required)
input#publickey.form-control.input-sm.w-50(type="text", placeholder="public key")
button#registerconfirm.btn.btn-secondary(type="button") register
button#registercancel.btn.btn-secondary(type="button") cancel
#registerPopupText
ul#messages
#loginPopup.popup
.popup-content
.btn-group.mr-2.w-100(role="group", aria-label="Add group")
input#privatekey.form-control.input-sm.w-50(type="password", placeholder="private key", required)
button#loginconfirm.btn.btn-secondary(type="button") login
button#logincancel.btn.btn-secondary(type="button") cancel
form#form(action="")
input#input(autocomplete="off")
button Send
a.btn.btn-primary(href="./account/cookie") Get cookie
ul#messages
form#form(action="")
input#input(autocomplete="off")
button Send