mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 19:38:12 +00:00
LibWeb: Apply scroll offset to PushStackingContext command
In cases where the stacking context painting requires a separate bitmap, the destination position needs to be translated by the scrolling offset to ensure it ends up in the correct position.
This commit is contained in:
parent
384c6cf0f9
commit
5484062095
5 changed files with 150 additions and 1 deletions
|
@ -0,0 +1,52 @@
|
|||
<!DOCTYPE html>
|
||||
<style>
|
||||
html {
|
||||
background: white;
|
||||
}
|
||||
body {
|
||||
position: absolute;
|
||||
inset: 0px;
|
||||
display: flex;
|
||||
background: pink;
|
||||
}
|
||||
#outer {
|
||||
overflow: hidden;
|
||||
background: orange;
|
||||
margin-top: 100px;
|
||||
}
|
||||
#inner {
|
||||
height: 1000px;
|
||||
background: yellow;
|
||||
}
|
||||
.item {
|
||||
box-sizing: border-box;
|
||||
border: 1px solid black;
|
||||
background: lime;
|
||||
height: 50px;
|
||||
width: 200px;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
opacity: 0.5;
|
||||
}
|
||||
</style><body><div id="outer"><div id="inner">
|
||||
<div class="item">11</div>
|
||||
<div class="item">12</div>
|
||||
<div class="item">13</div>
|
||||
<div class="item">14</div>
|
||||
<div class="item">15</div>
|
||||
<div class="item">16</div>
|
||||
<div class="item">17</div>
|
||||
<div class="item">18</div>
|
||||
<div class="item">19</div>
|
||||
<div class="item">20</div>
|
||||
<div class="item">21</div>
|
||||
<div class="item">22</div>
|
||||
<div class="item">23</div>
|
||||
<div class="item">24</div>
|
||||
<div class="item">25</div>
|
||||
<div class="item">26</div>
|
||||
<div class="item">27</div>
|
||||
<div class="item">28</div>
|
||||
<div class="item">29</div>
|
||||
<div class="item">30</div>
|
Loading…
Add table
Add a link
Reference in a new issue