CSS 3 Module | <== Test # ==> | |
---|---|---|
W3C Selectors | 30 of 153 of the static tests category | |
Testing | Date | Revision |
Impossible rules (:root:first-child, etc) (ID #27a) | 2005-10-19 | 1.0 |
This line should be green (there should be no red on this page).
:root:first-child { background-color: red; } :root:last-child { background-color: red; } :root:only-child { background-color: red; } :root:nth-child(1) { background-color: red; } :root:nth-child(n) { background-color: red; } :root:nth-last-child(1) { background-color: red; } :root:nth-last-child(n) { background-color: red; } :root:first-of-type { background-color: red; } :root:last-of-type { background-color: red; } :root:only-of-type { background-color: red; } :root:nth-of-type(1) { background-color: red; } :root:nth-of-type(n) { background-color: red; } :root:nth-last-of-type(1) { background-color: red; } :root:nth-last-of-type(n) { background-color: red; } p { color: green; }
<p>This line should be green (there should be no red on this page).</p>