tor-browser

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

dynamic-toolbar-fixed-top-and-bottom-1.html (992B)


      1 <!DOCTYPE HTML>
      2 <!--
      3  Tests that setting a fixed bottom margin in the compositor does
      4  not affect an element which is fixed to both the top and the bottom;
      5  in other words, the bottom attachment should be ignored.
      6  But for elements which are only attached to the bottom, those should
      7  be affected by the fixed bottom margin normally.
      8 
      9  The fixed margin is specified as a test-pref in reftest.list.
     10 -->
     11 <html>
     12 <meta name="viewport" content="width=device-width">
     13 <style>
     14 html {
     15    scrollbar-width: none;
     16 }
     17 #scrolled {
     18    height: 2000px;
     19    width: 100%;
     20 }
     21 #fixed-to-top {
     22    width: 100%;
     23    height: 200px;
     24    position: fixed;
     25    top: 0;
     26    bottom: 0; /* ignored because this element has both top and height set */
     27    background: green;
     28 }
     29 #fixed-to-bottom {
     30    width: 100%;
     31    height: 200px;
     32    position: fixed;
     33    bottom: 0;
     34    background: blue;
     35 }
     36 </style>
     37 <body>
     38  <div id="scrolled"></div>
     39  <div id="fixed-to-top"></div>
     40  <div id="fixed-to-bottom"></div>
     41 </body>
     42 </html>