blob: 35f05fae778ec15490a98bc1d4b4af9e35229847 [file] [log] [blame]
<!DOCTYPE html> <!-- webkit-test-runner [ AsyncOverflowScrollingEnabled=true ] -->
<html>
<head>
<title>Tests that we make a scrolling tree node for composited layers nested inside position:absolute in a stacking-context scroller</title>
<style>
.scroller {
overflow: scroll;
margin: 20px;
height: 300px;
width: 300px;
border: 2px solid black;
opacity: 0.9;
}
.absolute {
position:absolute;
left: 50px;
top: 50px;
width: 200px;
height: 120px;
padding: 20px;
background: gray;
}
.composited {
transform: translateZ(0);
width: 100px;
height: 100px;
background-color: green;
}
.spacer {
height: 500px;
width: 10px;
background-image: repeating-linear-gradient(to bottom, white, silver 200px);
}
</style>
<script>
if (window.testRunner)
testRunner.dumpAsText();
window.addEventListener('load', () => {
if (window.internals)
document.getElementById('tree').innerText = internals.scrollingStateTreeAsText();
}, false);
</script>
</head>
<body>
<div class="scroller">
<div class="spacer"></div>
<div class="absolute">
<div class="composited box"></div>
</div>
<div class="spacer"></div>
</div>
<pre id="tree"></pre>
</body>
</html>