mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-27 10:07:15 +02:00
Previously, absolutely positioned elements jumped directly to their containing block's accumulated visual context, skipping effects (opacity, mix-blend-mode, isolation) from intermediate ancestors. Per CSS spec, these properties create stacking contexts that abspos elements cannot escape — they only escape scroll containers and overflow clips.
30 lines
488 B
HTML
30 lines
488 B
HTML
<!DOCTYPE html>
|
|
<link rel="match" href="../expected/abspos-inside-opacity-inside-relpos-ref.html">
|
|
<style>
|
|
body {
|
|
margin: 0;
|
|
background: white;
|
|
}
|
|
.relpos {
|
|
position: relative;
|
|
width: 200px;
|
|
height: 200px;
|
|
}
|
|
.opacity {
|
|
opacity: 0.5;
|
|
}
|
|
.abspos {
|
|
position: absolute;
|
|
top: 0;
|
|
left: 0;
|
|
width: 100px;
|
|
height: 100px;
|
|
background: black;
|
|
}
|
|
</style>
|
|
<div class="relpos">
|
|
<div class="opacity">
|
|
<div class="abspos"></div>
|
|
</div>
|
|
</div>
|