tor-browser

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

contain-html-overflow-003.html (721B)


      1 <!doctype html>
      2 <html lang=en>
      3  <meta charset=utf-8>
      4  <title>CSS-contain test: size containment on html prevents overflow propagation</title>
      5  <link rel="author" title="Florian Rivoal" href="https://florian.rivoal.net">
      6  <meta name=flags content="">
      7  <meta name=assert content="size containment on html prevents overflow propagation">
      8  <link rel="match" href="reference/contain-body-overflow-001-ref.html">
      9  <link rel=help href="https://drafts.csswg.org/css-contain-1/#contain-property">
     10 
     11 <style>
     12 html, body, p, div {
     13    margin: 0;
     14    width: 200px;
     15    height: 200px;
     16 }
     17 div { background: red; }
     18 body {
     19    overflow: hidden;
     20 }
     21 html {
     22    contain: size;
     23 }
     24 </style>
     25 
     26 <p>Test passes if there is no red.
     27 
     28 <div></div>