15 overflow: hidden; /* Still scrollable with JS */
16 border: 1px solid black;
27 outline: 2px solid black;
38 background-color: green;
45 background-color: red;
51 document.getElementById('overflow').scrollTop = 120;
53 window.addEventListener('load', doTest, false);
57 This test checks that sticky positioned elements are contained by their enclosing ancestor with an overflow clip.
58 There should be no red.
60 <div class="spacer"></div>
62 <div class="indicator box" style="top: 200px;"></div>
63 <div class="container">
64 <div class="sticky box"></div>
68 <div class="group" style="top: 100px">
69 <div class="indicator box" style="top: 120px;"></div>
70 <div class="container">
71 <div class="sticky box"></div>
75 <div class="group" style="top: 240px">
76 <div class="indicator box" style="top: 0;"></div>
77 <div class="container">
78 <div class="sticky box"></div>