LibWeb: Allow inline nodes to establish a stacking context

With this change, a stacking context can be established by any
paintable, including inline paintables. The stacking context traversal
is updated to remove the assumption that the stacking context root is
paintable box.
This commit is contained in:
Aliaksandr Kalenik 2024-01-03 02:40:31 +01:00 committed by Andreas Kling
commit 3cf5ad002a
Notes: sideshowbarker 2024-07-16 17:12:03 +09:00
12 changed files with 253 additions and 151 deletions

View file

@ -0,0 +1,23 @@
<style>
span {
z-index: 10;
background: orange;
position: relative;
opacity: 0.5;
font-size: 100px;
}
div {
z-index: 5;
width: 100px;
height: 100px;
background: green;
position: relative;
top: -10px;
}
</style><span id="inline-stacking-context">hello</span><div></div>
<script src="../include.js"></script>
<script>
test(() => {
println(internals.hitTest(50, 50).node.parentNode === document.getElementById("inline-stacking-context"));
});
</script>