This commit is contained in:
2026-03-09 22:15:47 +00:00
parent e21acde732
commit 3b26f9b090
4 changed files with 12 additions and 2 deletions

Binary file not shown.

Binary file not shown.

View File

@@ -7,7 +7,7 @@
<body> <body>
<div class="center"> <div class="center">
<form id="infoForm"> <form id="infoForm">
<h2>Personal Information</h2> <h2>"Password Manager"</h2>
<hr> <hr>
<div class="inputGroup"> <div class="inputGroup">
<p>Password Name</p> <p>Password Name</p>
@@ -22,7 +22,7 @@
<input type="checkbox" id="set" name="Set?"> <input type="checkbox" id="set" name="Set?">
</div> </div>
<button type="submit">Submit</button> <button type="submit">Submit</button>
<a href="/login">Log Out</a> <a href="/login" id="logout">Log Out</a>
</form> </form>
<div class="error"> <div class="error">

View File

@@ -9,6 +9,10 @@ const errorMessage = document.querySelector(".error p");
const success = document.querySelector(".success"); const success = document.querySelector(".success");
const successMessage = document.querySelector(".success p"); const successMessage = document.querySelector(".success p");
const logoutLink = document.querySelector("#logout");
//logoutLink.onclick = logout;
openKeyDB(); openKeyDB();
const encryptionKey = await getEncryptionKey() const encryptionKey = await getEncryptionKey()
@@ -184,3 +188,9 @@ function base64ToBuffer(base64) {
} }
return bytes; return bytes;
} }
function logout() {
localStorage.removeItem("token");
window.location.href = "/login"
}