aboutsummaryrefslogtreecommitdiff
path: root/static/pages
diff options
context:
space:
mode:
authorNathan Reiner <nathan@nathanreiner.xyz>2025-11-25 08:59:00 +0100
committerNathan Reiner <nathan@nathanreiner.xyz>2025-11-25 08:59:00 +0100
commitdc36b1684c4da47defe8d3941ef60efb7cd8087e (patch)
tree9bdba4348155755f580d8a8b4e691168c42186f0 /static/pages
parent742bc755eb1ead278d1ee75dbd0d7ae03a3d29f1 (diff)
login: add autocomplete tags
Diffstat (limited to 'static/pages')
-rw-r--r--static/pages/login/index.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/static/pages/login/index.js b/static/pages/login/index.js
index 984d001..2cdd4c6 100644
--- a/static/pages/login/index.js
+++ b/static/pages/login/index.js
@@ -32,6 +32,7 @@ export default class LoginView extends sfw.element.Container {
children: [
this.#input = Input.new({
placeholder: 'Username',
+ autocomplete: 'username',
onkeydown: (e) => {
if (e.key === 'Enter') {
return this.#next();
@@ -65,12 +66,14 @@ export default class LoginView extends sfw.element.Container {
this.#user.innerText = '';
this.#input.value = '';
this.#input.placeholder = 'Username';
+ this.#input.autocomplete = 'username';
this.#input.type = 'text';
} else {
await this.onpassword(this.#input.value);
this.#user.innerText = this.#input.value;
this.#input.value = '';
this.#input.placeholder = 'Password';
+ this.#input.autocomplete = 'current-password';
this.#input.type = 'password';
}
}