summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/css/css-anchor-position/position-visibility-anchors-visible-after-scroll-out-ref.html
blob: bd4fe1f09f8ae455f71645958092e7f53e4617b1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
<!DOCTYPE html>
<meta charset="utf-8">
<style>
  #scroll-container {
    overflow: hidden scroll;
    width: 300px;
    height: 100px;
  }

  #spacer {
    height: 200px;
  }
</style>

<div id="scroll-container">
  <div id="spacer"><div>
</div>

<script>
  const scroller = document.getElementById('scroll-container');
  scroller.scrollTop = 100;
</script>