tor-browser

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

contain-paint-024.html (1225B)


      1 <!DOCTYPE html>
      2 
      3  <meta charset="UTF-8">
      4 
      5  <title>CSS Containment Test: 'contain: paint' and absolutely positioned descendants</title>
      6 
      7  <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/">
      8  <link rel="help" href="https://www.w3.org/TR/css-contain-1/#containment-paint">
      9  <link rel="match" href="../reference/ref-filled-green-100px-square.xht">
     10 
     11  <meta content="This test checks that paint containment does not apply to non-atomic inline elements so they do not act as containing block for absolutely positioned descendants." name="assert">
     12 
     13  <style>
     14  div#correct-containing-block
     15    {
     16      background-color: red;
     17      height: 100px;
     18      position: relative;
     19      width: 100px;
     20    }
     21 
     22  div#incorrect-containing-block
     23    {
     24      contain: paint;
     25      display: inline;
     26    }
     27 
     28  div#abspos
     29    {
     30      background-color: green;
     31      bottom: 0;
     32      height: 100%;
     33      position: absolute;
     34      right: 0;
     35      width: 100%;
     36    }
     37  </style>
     38 
     39  <p>Test passes if there is a filled green square and <strong>no red</strong>.
     40 
     41  <div id="correct-containing-block">
     42 
     43    <div id="incorrect-containing-block">
     44 
     45      <div id="abspos"></div>
     46 
     47    </div>
     48 
     49  </div>