karlgroves/diagnostic.css — pull request #9 by PhilippeVay (2013-05-22 08:07:45+00:00)
Title: More diagnostic/error rules (html[lang], title, legend, [dir], meta refresh (!) and input[type="image"]) and a test file

Hi,

after forking your existing stylesheet, I added a few rules to detect and display:

* lack of `html[lang]`,
* displaying `title`(s) at top of page, flagging duplicates and empty ones (forgot about `title` not in `head`),
* `legend` not being the first element of a `fieldset` (and other element being the first child of the latter),
* `[dir]` whether `rtl` or `ltr`,
* displaying a `` refresh (!) (found the selector in Accessibility First step from Opquast/Temesis, credit is in the comments of the CSS)
* `input[type="image"]` and empty `alt` attribute or lack of (no `:before` or `:after` with this element so it's hard to flag it in pure CSS. Maybe in the future with a base64-encoded background?)

A few links to WCAG 2.0 Techniques are in the comment of some of the rules.

I also added a test file for legends with a valid example and a bad one (I hope so). In this file, each select has a different kind of label; this is intended :)

Feel free to tell me if this is *or isn't* the kind of CSS rules and display you'd like to see in diagnostic.css, I've an extensive list of ideas taken from the [Accessiweb 2.2 checklist](http://accessiweb.org/index.php/accessiweb-22-english-version.html) and other tools :)

Best regards,
Ph. Vayssière