| <!DOCTYPE html> |
| <html> |
| <head> |
| <style> |
| html, body { |
| margin: 0; |
| } |
| .sticky { |
| position: sticky; |
| width: 10px; |
| height: 10px; |
| } |
| .top { |
| top: 1px; |
| } |
| .bottom { |
| bottom: 1px; |
| } |
| .left { |
| left: 1px; |
| } |
| .right { |
| right: 1px; |
| } |
| .container { |
| position: absolute; |
| top: 100px; |
| left: 100px; |
| width: 200px; |
| height: 200px; |
| } |
| .composited { |
| will-change: transform; |
| } |
| .spacer { |
| height: 10px; |
| } |
| </style> |
| </head> |
| |
| <!-- Fixed position elements may skip compositing without a scrollable |
| ancestor. To make sure this test covers the intended scenario, we force the |
| body element to be tall, so that the FrameView is scrolling. --> |
| <body style="height: 4000px"> |
| <div class="container"> |
| <div id="div-tl" class="sticky top left">X</div> |
| <div id="div-tr" class="sticky top right">X</div> |
| <div id="div-bl" class="sticky bottom left">X</div> |
| <div id="div-br" class="sticky bottom right">X</div> |
| <span id="span-tl" class="sticky top left">X</span> |
| <span id="span-tlbr" class="sticky top left bottom right">X</span> |
| </div> |
| <div class="composited container"> |
| <div class="spacer"></div> |
| <div id="composited-top" class="sticky top">X</div> |
| </div> |
| </body> |
| </html> |