Source code
Revision control
Copy as Markdown
Other Tools
Test Info:
- This WPT test may be referenced by the following Test IDs:
- /css/css-overflow/scroll-markers/scroll-marker-group-scroll-container-change-crash.html - WPT Dashboard Interop Dashboard
<!DOCTYPE html>
<title>CSS Overflow Test: Moving the scroll container between nested scroll-marker-groups does not crash</title>
<style>
#outer, #inner {
scroll-marker-group: before;
}
#outer {
overflow: auto;
position: relative;
}
#item {
position: absolute;
}
#item::scroll-marker {
content: "";
}
</style>
<div id="outer"><div id="inner"><div id="item"></div></div></div>
<script>
outer.offsetTop;
// Move #item's ::scroll-marker from #outer's group to #inner's group.
outer.style.overflow = "visible";
inner.style.overflow = "auto";
item.style.position = "static";
</script>