tor-browser

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

writing-mode-horizontal-tb.html (958B)


      1 <!DOCTYPE html>
      2 <title>
      3  Scrollers should snap to the closest snap point on initial layout
      4  (using 'writing-mode: horizontal-tb')
      5 </title>
      6 <link rel="help" href="https://drafts.csswg.org/css-scroll-snap/#re-snap" />
      7 <link rel="match" href="snap-after-initial-layout-ref.html" />
      8 <style>
      9 div {
     10  position: absolute;
     11  margin: 0;
     12 }
     13 
     14 #scroller {
     15  height: 500px;
     16  width: 500px;
     17  overflow: hidden;
     18  scroll-snap-type: both mandatory;
     19  writing-mode: horizontal-tb;
     20 }
     21 
     22 #close-target {
     23  width: 200px;
     24  height: 200px;
     25  border: solid green 50px;
     26  top: 50px;
     27  left: 150px;
     28  margin: 50px;
     29  background-color: green;
     30  scroll-snap-align: start end;
     31 }
     32 
     33 #far-target {
     34  width: 300px;
     35  height: 300px;
     36  top: 100px;
     37  left: 500px;
     38  background-color: red;
     39  scroll-snap-align: start end;
     40 }
     41 
     42 .area {
     43  width: 2000px;
     44  height: 2000px;
     45 }
     46 </style>
     47 
     48 <div id="scroller">
     49  <div class="area"></div>
     50  <div id="close-target"></div>
     51  <div id="far-target"></div>
     52 </div>