Closed
Bug 297856
Opened 20 years ago
Closed 20 years ago
labels do not forward focus to controls
Categories
(Firefox :: General, defect)
Tracking
()
RESOLVED
INVALID
People
(Reporter: pro696, Unassigned)
References
()
Details
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.8) Gecko/20050511 Firefox/1.0.4 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.8) Gecko/20050511 Firefox/1.0.4 <label> tags do not forward the mouse focus or loss of focus to its associated control (clicks are forwarded correctly, however). Evil IE seems to have performed this correctly, so it was quite a shock that Fx did not. Page 239 of HTML/4.01 specification (http://www.w3.org/TR/1999/REC-html401-19991224) states "When a LABEL element receives focus [p.241] , it passes the focus on to its associated control." Labels become part of their associated control. When hovered, the control must act like it is hovered (including the normal outline around it and the JS onmouseover and onmouseout functions). Example: <input type="checkbox" id="checkbox_id" /> <label for="checkbox_id">Label for Checkbox</label> Full example at http://pro696.homeftp.org/label_flaw.html. Reproducible: Always Steps to Reproduce: 1. Go to http://pro696.homeftp.org/label_flaw.html with javascript enabled 2. Hover over the checkbox 3. Look at the textbox ("Checkbox is hovered") 4. Hover over the "Label for Checkbox" label 5. Look at the textbox Actual Results: Nothing happened Expected Results: The mouse hover over the label should have been forwarded to the control, activating the onmouseover attribute of the control, running the mouseover() function of the document (see the document's source), changing the textbox's value to "Checkbox is hovered". Also, the checkbox should have been highlighted. See the HTML source for the document (http://pro696.homeftp.org/label_flaw.html) as well. No comments have been made to it, but you can see the javascript source. The document is valid XHTML 1.0, fully standards-compliant. A link is provided at the bottom of the page.
Sorry, I lied. IE has the problem in terms of forwarding the mouse focus to the control, but it highlights the control itself.
Comment 2•20 years ago
|
||
hover != focus. Clicking or hitting enter on the text label should _focus_ the checkbox, but hovering does not equate to focus.
Status: UNCONFIRMED → RESOLVED
Closed: 20 years ago
Resolution: --- → INVALID
You need to log in
before you can comment on or make changes to this bug.
Description
•