[whatwg] Idea: pseudo-classes :valid and :invalid for whole form?

Rafał Miłecki zajec5 at gmail.com
Tue Jun 14 14:16:56 PDT 2011

We already have required attribute and :valid plus :invalid classes,
which are nice. However some may want to display additional warning
when form wasn't filled correctly. Just some single warning, not
specific field-related. Could you consider adding form element class
for such a purpose?

<p id="err">You've to fill all required fields</p>
form:invalid #err {
display: block;


More information about the whatwg mailing list