W3C home > Mailing lists > Public > public-html@w3.org > September 2010

[Bug 10710] New: Require controls to have programatically associated names

From: <bugzilla@jessica.w3.org>
Date: Fri, 24 Sep 2010 06:45:04 +0000
To: public-html@w3.org
Message-ID: <bug-10710-2495@http.www.w3.org/Bugs/Public/>
http://www.w3.org/Bugs/Public/show_bug.cgi?id=10710

           Summary: Require controls to have programatically associated
                    names
           Product: HTML WG
           Version: unspecified
          Platform: PC
        OS/Version: All
            Status: NEW
          Keywords: a11y
          Severity: normal
          Priority: P2
         Component: HTML5 spec (editor: Ian Hickson)
        AssignedTo: ian@hixie.ch
        ReportedBy: bhawkeslewis@googlemail.com
         QAContact: public-html-bugzilla@w3.org
                CC: mike@w3.org, public-html-wg-issue-tracking@w3.org,
                    public-html@w3.org


WCAG 2.0 1.1 requires: "If non-text content is a control or accepts user input,
then it has a name that describes its purpose."

Including controls in the page without providing them with such names is a
common antipattern. For example, I often see:

   * links and buttons whose only "content" is provided by an "alt"-less "img"
or a background image
   * form controls without labels.

I have not yet seen a use case for having a control without a programatically
associated name, whereas the omission of such names does considerable damage to
the accessibility, media independence, and restylability of the web.

Proposal: Require controls to have programatically associated names.

Specifically:

   * Require "a href" and "button" to have descendant non-whitespace text
content (either in a text node or an "alt" attribute) that names the control.
   * Require image "input" elements to have a non-whitespace "alt" attribute
that names the control.
   * Require reset, button and submit "input" elements to have a non-whitespace
"value" attribute that names the control.
   * Require "input" elements of other types (except "hidden") to have a
programmatically associated "label" element with descendant non-whitespace text
content (either in a text node or an "alt" attribute) that names the control.
   * Require radio button groups to have a programmatically associated "legend"
element that names the control.
   * Require "select" elements to have a programmatically associated "label"
element with descendant non-whitespace text content (either in a text node or
an "alt" attribute) that names the control.
   * Require "optiongroup" elements to have a non-whitespace "label" attribute
that names the group.
   * Require "option" elements to have either a non-whitespace "label"
attribute or descendant non-whitespace text content (either in a text node or
an "alt" attribute that names the option.
   * Require "command" elements to have a non-whitespace "label" attribute
(note the spec currently requires non-empty only) that names the command.
   * Require nested "menu" elements to have a non-whitespace "label" attribute
that names the submenu.

(If I've missed out controls or HTML-native ways to associate them with names,
corrections welcome.)

-- 
Configure bugmail: http://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
Received on Friday, 24 September 2010 06:45:08 UTC

This archive was generated by hypermail 2.3.1 : Monday, 29 September 2014 09:39:19 UTC