Back to the index.
See also the CSS3 User Interface spec.
There are several pseudo-classes that are used to style the various states of form elements. This page tests some of them.
:in-range
: The form field has a (numerical) value that’s in range of its constraints.:out-of-range
: The form field has a (numerical) value that’s not in range of its constraints.Test sheet:
input:out-of-range { border: 1px solid #CB000F; color: red } input:in-range { color: #00882D; font-weight: bold; }
The field expects a number between 1 and 12. Anything else is out of range.
Support for input type="number"
is required for this test.