tor-browser

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

content-visibility-vs-scrollIntoView-001-ref.html (1124B)


      1 <!doctype HTML>
      2 <html class="reftest-wait">
      3 <meta charset="utf8">
      4 <title>Nested CSS Content Visibility: auto + scrollIntoView</title>
      5 <link rel="author" title="Cathie Chen" href="mailto:cathiechen@igalia.com">
      6 <link rel="help" href="https://drafts.csswg.org/css-contain/#content-visibility">
      7 <meta name="assert" content="Test if target scrollIntoView is visible when it is inside a nested content-visibility: auto">
      8 <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
      9 <script src="/common/reftest-wait.js"></script>
     10 
     11 <style>
     12 
     13    .child {
     14        height: 40000px;
     15        position: relative;
     16    }
     17 
     18    #target {
     19        position: absolute;
     20        bottom: 0;
     21        font: 25px/1 Ahem;
     22    }
     23 
     24    .before_target {
     25        height: 40000px;
     26    }
     27 </style>
     28 
     29 <div id=e1 class="before_target"></div>
     30 <div id=e2 class="before_target"></div>
     31 <div id=e3 class="before_target"></div>
     32 <div id=e4 class="before_target"></div>
     33 <div id=e5 class=child>
     34    <div id=target>PASS</div>
     35 </div>
     36 
     37 <script>
     38    window.onload = () => {
     39        target.scrollIntoView();
     40        requestAnimationFrame(takeScreenshot);
     41    }
     42 </script>