The default bug view has changed. See this FAQ.

No Accessible name for control when label has position:absolute and overflow:hidden

RESOLVED DUPLICATE of bug 501580

Status

()

Core
Disability Access APIs
RESOLVED DUPLICATE of bug 501580
5 years ago
3 years ago

People

(Reporter: Hans Hillen, Unassigned)

Tracking

(Blocks: 1 bug, {access})

Trunk
x86
Windows 7
access
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

5 years ago
Created attachment 628303 [details]
hiddenlabelbug.html

User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7_4) AppleWebKit/536.5 (KHTML, like Gecko) Chrome/19.0.1084.52 Safari/536.5

Steps to reproduce:

When a form control's label is hidden off screen, Firefox exposes Null as accessible name for the control. This seems to be occur whenever the label is styled with position:absolute; and overflow:hidden; (even if the label itself is still visible on the screen). If either the position or overflow CSS property is removed, the problem no longer occurs. Only when both position:absolute and overflow:hidden are set.

The attached test case demonstrates this issue (HTML code shown below).

<!DOCTYPE HTML>
<html lang="en-US">
<head>
	<meta charset="UTF-8">
	<title>Test Case for label bug </title>
	<style type="text/css">
		.element-invisible {
			overflow: hidden;
			position: absolute;
			/*left: -999em;
			width: 1em;
			*/
		}
	</style>
</head>

<body>	
	<h1>Test case for label issue</h1>
	<label class="element-invisible" for="sampleTxt1">A hidden label</label>
	<br /><br />
	<input type="text" id="sampleTxt1" />
</body>
</html>		



Expected results:

The label's styles should have no effect on the accessible name of the associated form control (especially since position and overflow are often used to hide content off screen).
(Reporter)

Updated

5 years ago
Component: Untriaged → Disability Access
OS: Mac OS X → Windows 7
(Reporter)

Comment 1

5 years ago
It seems that the label is no longer considered an accessible object once the position and overflow style are set.

Updated

5 years ago
Attachment #628303 - Attachment mime type: text/plain → text/html
Keywords: access

Updated

3 years ago
Blocks: 459353
Component: Disability Access → Disability Access APIs
Product: Firefox → Core
Version: 12 Branch → Trunk

Comment 2

3 years ago
This is blocking web developers from using sanctioned techniques to apply more context information for screen reader users. Read here:
http://juicystudio.com/article/hidden-label-firefox-bug.php
Alex, can you take a look please?
Status: UNCONFIRMED → NEW
Ever confirmed: true

Updated

3 years ago
Status: NEW → RESOLVED
Last Resolved: 3 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 501580
You need to log in before you can comment on or make changes to this bug.