tor-browser

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

will-change-stacking-context-z-index-4.html (941B)


      1 <!DOCTYPE html>
      2 <title>CSS Test: `will-change: z-index`</title>
      3 <link rel="author" title="Oriol Brufau" href="obrufau@igalia.com">
      4 <link rel="help" href="https://www.w3.org/TR/css-will-change/#valdef-will-change-custom-ident">
      5 <link rel="help" href="https://www.w3.org/TR/CSS2/visuren.html#z-index">
      6 <link rel="help" href="https://github.com/w3c/csswg-drafts/issues/11827">
      7 <link rel="match" href="../reference/ref-filled-green-100px-square.xht">
      8 <meta name="assert" content="
      9  `will-change: z-index` doesn't establish a stacking context on a non-positioned block box,
     10   because `z-index` doesn't apply in that case.
     11 ">
     12 <style>
     13 .test {
     14  will-change: z-index;
     15  width: 100px;
     16  background: green;
     17 }
     18 .test::before {
     19  content: "";
     20  display: block;
     21  position: relative;
     22  z-index: -1;
     23  height: 100px;
     24  background: red;
     25 }
     26 </style>
     27 <p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
     28 <div class="test"></div>