li-with-height-001.html (812B)
1 <!DOCTYPE html> 2 <meta charset="utf-8"> 3 <title>CSS Lists: list with height</title> 4 <link rel=help href="https://www.w3.org/TR/CSS22/generate.html#lists"> 5 <link rel=match href="li-with-height-001-ref.html"> 6 <meta name="assert" content="This is to check the behavior of adding an element at the begining of li" /> 7 8 <p>The test passes if "second" is in the following line of "first".</p> 9 10 <ul> 11 <li id="li_target" style="height:200px; border:1px solid black; width:200px"> 12 <div id="div_target" style="overflow:hidden;">second</div> 13 </li> 14 </ul> 15 16 <script> 17 document.body.clientHeight; 18 19 var text_node = document.createTextNode("first"); 20 var li_target = document.getElementById("li_target"); 21 var div_target = document.getElementById("div_target"); 22 li_target.insertBefore(text_node,div_target); 23 </script>