tor-browser

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

contain-paint-scrollable-frame-1.html (1338B)


      1 <!DOCTYPE HTML>
      2 <html reftest-async-scroll>
      3 <body>
      4  <div style="width:400px; height:200px; overflow:scroll;
      5              scrollbar-width: none;
      6              border:2px solid black; background: red;
      7              contain:paint;"
      8       reftest-displayport-x="0" reftest-displayport-y="0"
      9       reftest-displayport-w="800" reftest-displayport-h="2000"
     10       reftest-async-scroll-x="0" reftest-async-scroll-y="100">
     11    <!-- This element is what we're hoping will fill the scrollport
     12         when the reftest snapshot is taken: -->
     13    <div style="background: lime; margin-top: 100px; height: 600px"></div>
     14 
     15    <!-- This element is just to be sure the scrollframe's "contain:paint"
     16         styling is actually having an effect. "contain:paint" should make the
     17         scrollframe become a containing block for this fixed-pos element, and
     18         then this element will position itself off the bottom of the
     19         scrollframe and will be entirely clipped. If we fail to honor
     20         "contain:paint" for some reason, then this element will instead use
     21         the *viewport* as its containing block, and it'll show up in the
     22         reftest snapshot and cause the reftest to fail. -->
     23    <div style="position: fixed; top: 320px; width: 50px; height: 50px;
     24                background: purple;"></div>
     25  </div>
     26 </body>
     27 </html>