[wp-trac] [WordPress Trac] #63281: Password field has wrongly focus on installations
WordPress Trac
noreply at wordpress.org
Fri May 30 16:25:52 UTC 2025
#63281: Password field has wrongly focus on installations
------------------------------+--------------------------------------------
Reporter: zodiac1978 | Owner: joedolson
Type: defect (bug) | Status: accepted
Priority: normal | Milestone: 6.9
Component: Upgrade/Install | Version:
Severity: normal | Resolution:
Keywords: has-patch commit | Focuses: ui, accessibility, javascript
------------------------------+--------------------------------------------
Changes (by joedolson):
* keywords: has-patch => has-patch commit
Comment:
I could wish there was some documentation of why `wp_is_mobile()` was
checked there in the first place, but the original commit that added this
doesn't mention it in any way in the commit or in the related ticket. I
would guess that @abcd95 is correct, that it was because the automatic
keyboard was disruptive. I'm not totally convinced that this is a good
reason. The more important accessibility concern around autofocusing is
whether or not there's any critical information that precedes the
autofocused input that a user could miss - in this case, I think that
there isn't. The text before the form is largely insignificant.
The lack of a comment at the time it was added means that it's hard to
know whether it could have been a tech issue; e.g. unreliable support or
behavior on mobile devices in 2013. I believe that in iOS at that time,
triggering `.focus()` on an input did not open the onscreen keyboard, so
autofocus would cause problems on mobile because the user would still need
to manually remove and add focus to the field to trigger the keyboard.
For the purpose of this ticket, I think we can leave it as it is; I
suspect that executing a WordPress installation on mobile is not a common
scenario.
Perhaps @johnbillion has some memory of why that was added, as the author
of the patch that added it? I'm sure the 12 year old memory will be super
fresh. :)
But I think that this patch is good to go as it is; if we want to remove
the mobile check, that can go in a separate ticket.
I've tested and confirmed behavior.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/63281#comment:10>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list