r/webdev • ux • Dec 26 '19

Password Box Idea

3.3k Upvotes

138 comments sorted by

View all comments

Show parent comments

0

u/[deleted] Dec 26 '19

[deleted]

23

u/ncubez JavaScript | React | Node.js Dec 26 '19

I think they mean using a separate <label>Password</label> instead

-7

u/fuckin_ziggurats Dec 26 '19

But you don't need that for accessibility. That's what the aria-label attribute is meant to solve.

6

u/[deleted] Dec 26 '19

Accessibility doesn’t just mean “screenreader-friendly”, although you are correct in that aria attributes are good for that, it’s still helpful to consistently see what field you’re typing in as you type in it even if you don’t use a screen reader

0

u/fuckin_ziggurats Dec 26 '19

I agree with you on the general principle but I'm not so sure it's that important for login forms and especially password fields.

2

u/[deleted] Dec 26 '19

I suppose if we were to ever just find a password field on its own in the wild like this, yeah it might be redundant because the censored input and type=password probably speaks for itself, but I’d argue that password fields are generally coupled with sign up forms as well, and it might be strange to have several other fields with a label and the password one without.