1
0
mirror of https://github.com/hrfee/jfa-go.git synced 2024-12-23 01:20:11 +00:00

userpage: autofill username in pwr modal

This commit is contained in:
Harvey Tindall 2023-06-22 12:39:13 +01:00
parent 22c91be127
commit 3b3f37365a
Signed by: hrfee
GPG Key ID: BBC65952848FB1A2

View File

@ -52,6 +52,9 @@ window.modals = {} as Modals;
}; };
const resetButton = document.getElementById("modal-login-pwr"); const resetButton = document.getElementById("modal-login-pwr");
resetButton.onclick = () => { resetButton.onclick = () => {
const usernameInput = document.getElementById("login-user") as HTMLInputElement;
const input = document.getElementById("pwr-address") as HTMLInputElement;
input.value = usernameInput.value;
window.modals.login.close(); window.modals.login.close();
window.modals.pwr.show(); window.modals.pwr.show();
} }