Skip to content

Commit efaeb3b

Browse files
committed
Add hidden username field for accessibility
1 parent 6cebfa4 commit efaeb3b

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

src/browser/pages/login.css

+5-1
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,17 @@
1717
margin-top: 1em;
1818
}
1919

20-
.login-form > .field > .input {
20+
.login-form > .field > .password {
2121
border: 1px solid #b6b6b6;
2222
box-sizing: border-box;
2323
padding: 1em;
2424
flex: 1;
2525
}
2626

27+
.login-form > .field > .user {
28+
display: none;
29+
}
30+
2731
.login-form > .field > .submit {
2832
background-color: transparent;
2933
border: 1px solid #b6b6b6;

src/browser/pages/login.tsx

+2-1
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,10 @@ export const Login: React.FunctionComponent<LoginProps> = (props) => {
4040
<div className="sub">Please log in below</div>
4141
</div>
4242
<div className="field">
43+
<input className="user" type="text" autoComplete="username" />
4344
<input
4445
autoFocus
45-
className="input"
46+
className="password"
4647
type="password"
4748
placeholder="password"
4849
autoComplete="current-password"

0 commit comments

Comments
 (0)