- From: Leif Halvard Silli <lhs@malform.no>
- Date: Wed, 20 Aug 2008 04:12:26 +0200
- To: Justin James <j_james@mindspring.com>
- CC: 'Gez Lemon' <gez.lemon@gmail.com>, "'Patrick H. Lauke'" <redux@splintered.co.uk>, wai-xtech@w3.org, public-html@w3.org
Justin James 2008-08-19 22.38: >> Leif Halvard Silli Sent: Tuesday, August 19, 2008 2:49 >> It seems to me that the understanding of conformance versus >> validation could be improved by requiring the role="" >> attribute, and have spesific @alt requirements for each role. > > The techno-geek in me loves this idea. The pragmatist in me > says that it makes things too complicated for the typical HTML > author. :( > > Unless, of course, we assign a default @role for @role="" and a > missing @role, and the default @role has @alt rules of "@alt > must be present (even with a value of empty string), see WCAG > for information on how to use it." That would take the entire > thrust of Karl's proposal and merge it with this excellent idea > presented here. The large majority of HTML authors who are > savvy enough to use @role will also be able to follow along > with the idea that @role can affect @alt requirements. A default @role value? Perhaps. Against 1: The presence of @role is very simple to validate. So why allow omitting it? To validate HTML 4 docs as if being HTML 5? Against 2: What validation response should lack of @role then lead to? Some tryouts for the last question: If the default value was (1) somethign requiring alt text => endless requests for alt text (though the author could add @role to get rid of many of them.) (2) role="decorative" => endless requests for @alt text removal. (3) role="undefined" => error response = not what you wanted. (4) role="private-undefined" (the name of the default role should seem unfitting for "public" pages) => validator announces (a) the lack of @role; (b) the name of the default role (c) that such a value is incorrect for pages which are corporate, governmental or public, and for all other pages in need of a measure of universal access and accessibility (d) that the @alt can not be evaluated before @role is added (though the presence of @alt, and - possibly - repeated alt values could be evaluated, depending on how the defult value was defined, and always with an advice to add @role before editing the @alt attribute). Over all, @role would open many new possibilities for better validation services: Repeated alt could trigger a response. (It would be ok for IMG-s with e.g. role=logo, but unexpected with some other roles.) Some loopholes could become narrower. (Use of white-space in order to achieve conformance should e.g. throw an error if the role is role="logo".) @Role would allow the validator to apply "heuristics". (E.g., for advice, the validator could "calculate" whether the presence of role="logo" one one IMG, lowers or increeases the chance that role=private-undefined on another seems correct, or not.) -- leif halvard silli
Received on Wednesday, 20 August 2008 02:13:23 UTC