change-list-style-position-002.html (818B)
1 <!DOCTYPE html> 2 <meta charset="utf-8"> 3 <title>CSS Lists: test the change of list-style-position</title> 4 <link rel="author" title="Oriol Brufau" href="mailto:obrufau@igalia.com"> 5 <link rel="match" href="change-list-style-position-002-ref.html"> 6 <link rel="help" href="https://www.w3.org/TR/CSS22/generate.html#lists"> 7 <style> 8 div { 9 display: list-item; 10 margin-left: 40px; 11 border: 5px solid; 12 } 13 div > div { list-style-type: decimal } 14 div > div > div { list-style-type: lower-roman } 15 .inside { list-style-position: inside } 16 </style> 17 <div><div id="bar"><div id="baz">text</div></div></div> 18 <script> 19 document.getElementById("bar").className = "inside"; 20 document.body.offsetHeight; 21 document.getElementById("bar").className = ""; 22 document.body.offsetHeight; 23 document.getElementById("baz").className = "inside"; 24 </script>