| <csstest def=":indeterminate with :checked" module="W3C Selectors" modulename="css3-modsel" number="d5d" rev="1.2" date="20-october-2005" xmlns="http://www.example.org/css3tests"> |
| |
| <author>Tantek Çelik</author> |
| <author>Ian Hickson</author> |
| |
| <dynamic/> |
| |
| <cssrules> |
| input, span { background: green; } |
| input:indeterminate:checked, input:indeterminate:checked + span { background: red; } |
| </cssrules> |
| |
| <code> |
| |
| <div xmlns="http://www.w3.org/1999/xhtml"> |
| |
| <script type="text/javascript"> |
| <![CDATA[ |
| |
| function test() { |
| /* Microsoft specs for .indeterminate say that this is an invalid test |
| as an element can be both .checked and ,indeterminate; however the |
| selectors spec says no element can be :checked:indeterminate. */ |
| document.getElementById("test").indeterminate = true; |
| } |
| |
| window.setTimeout("test()", 100); |
| ]]> |
| </script> |
| |
| <p> <input id="test" type="checkbox" checked="checked"/> <span>Everything in this paragraph should have a green background.</span> </p> |
| |
| </div> |
| |
| </code> |
| </csstest> |