tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

line-clamp-with-abspos-023.html (1049B)


      1 <!DOCTYPE html>
      2 <meta charset="utf-8">
      3 <title>CSS Overflow: abspos in line-clamp in zero-sized div</title>
      4 <link rel="author" title="Florian Rivoal" href="https://florian.rivoal.net">
      5 <link rel="help" href="https://drafts.csswg.org/css-overflow-4/#line-clamp">
      6 <link rel="match" href="reference/line-clamp-with-abspos-023-ref.html">
      7 <meta name="assert" content="Absolute positioned boxes inside a line-clamp container are shown if their containing block is after the clamp point. This test specifically tests that this is the case where the container is an other-wise empty, zero-height div, which does fit before the clamp point.">
      8 <style>
      9 .clamp {
     10  line-clamp: auto;
     11  max-height: 4lh;
     12  font: 16px / 32px serif;
     13  background-color: yellow;
     14 }
     15 .rel {
     16  position: relative;
     17 }
     18 .abspos {
     19  position: absolute;
     20  right: 0;
     21  width: 100px;
     22  height: 100px;
     23  background-color: green;
     24 }
     25 </style>
     26 <div class="clamp">
     27 Line 1<br>
     28 Line 2<br>
     29 Line 3<br>
     30 Line 4<br>
     31 <div class="rel"><div class="abspos">This abspos should be visible</div></div>
     32 Line 5
     33 </div>