- From: <bugzilla@jessica.w3.org>
- Date: Tue, 27 Jan 2015 23:30:09 +0000
- To: public-html-admin@w3.org
https://www.w3.org/Bugs/Public/show_bug.cgi?id=27912 Bug ID: 27912 Summary: initial focus precedence: autofocus or fragment identifier Product: HTML WG Version: unspecified Hardware: PC OS: All Status: NEW Severity: normal Priority: P2 Component: HTML5 spec Assignee: dave.null@w3.org Reporter: mail@rodneyrehm.de QA Contact: public-html-bugzilla@w3.org CC: mike@w3.org, public-html-admin@w3.org, public-html-wg-issue-tracking@w3.org There are currently at least 2 ways to set initial focus upon document load. The document itself can define an element to (scroll to and) focus by using the autofocus attribute [1] (limited to form elements). The user can define the element to (scroll to and) focus by using a URL fragment identifier [2]. The specification does not define order of processing autofocus and fragment identifiers. Blink [3] prefers the autofocus attribute. Gecko [4] and WebKit [5] prefer :target but show bugs in doing so. Trident (IE11) prefers :target without bugs. In my opinion Microsoft got this one right. A URL fragment identifier can be argued to be user-input, where autofocus is a document's default state. User input should be more important. I propose to add a note to the autofocus [1] spec saying that fragment identifiers [2] have precedence. [1] http://www.w3.org/html/wg/drafts/html/master/forms.html#autofocusing-a-form-control:-the-autofocus-attribute [2] http://www.w3.org/html/wg/drafts/html/master/browsers.html#scroll-to-fragid [3] https://code.google.com/p/chromium/issues/detail?id=382901 [4] https://bugzilla.mozilla.org/show_bug.cgi?id=840187 [5] https://bugs.webkit.org/show_bug.cgi?id=140963 -- You are receiving this mail because: You are on the CC list for the bug.
Received on Tuesday, 27 January 2015 23:30:17 UTC