block-ellipsis-repaint-001.html (1181B)
1 <!DOCTYPE html> 2 <html class="reftest-wait"> 3 <meta charset="utf-8"> 4 <title>CSS Overflow: line-clamp ellipsis repaint tests</title> 5 <link rel="author" title="Andreu Botella" href="mailto:abotella@igalia.com"> 6 <link rel="help" href="https://drafts.csswg.org/css-overflow-4/#block-ellipsis"> 7 <link rel="match" href="reference/block-ellipsis-repaint-001-ref.html"> 8 <meta name="assert" content="This test makes sure that, if the line with the ellipsis changes so it breaks at a different point, the ellipsis gets repainted accordingly."> 9 <script src="/common/reftest-wait.js"></script> 10 <style> 11 .clamp { 12 line-clamp: 1; 13 border: 1px solid black; 14 padding: 4px; 15 background-color: yellow; 16 } 17 #atomic { 18 display: inline-block; 19 background-color: orange; 20 width: 2em; 21 } 22 </style> 23 24 <p>The ellipsis should appear right after the end of the first line.</p> 25 26 <div class="clamp"> 27 <span id="atomic"></span> Some text here <br> 28 This line gets clamped 29 </div> 30 31 <script> 32 window.onload = () => { 33 requestAnimationFrame(() => { 34 requestAnimationFrame(() => { 35 document.getElementById("atomic").style.display = "none"; 36 takeScreenshot(); 37 }); 38 }); 39 }; 40 </script>