feat: Implement password reset and change functionality

Co-authored-by: mathieumoran1 <[email protected]>
This commit is contained in:
Cursor Agent
2025-12-20 23:13:51 +00:00
co-authored by mathieumoran1
parent 7a5ef7e9a0
commit c83b4685a2
11 changed files with 386 additions and 18 deletions
+4
View File
@@ -16,6 +16,10 @@ window.onload = async function () {
if (token) {
try {
const decoded = JSON.parse(atob(token.split('.')[1])); // Manually decoding JWT
if (decoded.mustChangePassword) {
window.location.href = '/change-password.html';
return;
}
const userName = decoded.name;
document.getElementById('user-name').textContent = userName;
if (decoded.admin) {