Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 <!DOCTYPE html> | |
| 2 | |
|
Julien - ping for review
2014/01/08 15:31:45
Unneeded space.
ostap
2014/01/09 03:44:14
Done.
| |
| 3 <html> | |
| 4 <head> | |
| 5 <style> | |
| 6 .group { | |
| 7 display: inline-block; | |
| 8 position: relative; | |
| 9 width: 150px; | |
| 10 height: 500px; | |
| 11 } | |
| 12 | |
| 13 #overflow { | |
| 14 width: 600px; | |
| 15 height: 550px; | |
| 16 overflow: hidden; | |
| 17 border: 1px solid black; | |
| 18 } | |
| 19 | |
| 20 .spacer { | |
| 21 float: left; | |
| 22 width: 10px; | |
| 23 height: 1200px; | |
| 24 } | |
| 25 .container { | |
| 26 width: 100px; | |
| 27 height: 400px; | |
| 28 outline: 2px solid black; | |
| 29 } | |
| 30 | |
| 31 .box { | |
| 32 width: 100px; | |
| 33 height: 200px; | |
| 34 } | |
| 35 | |
| 36 .sticky { | |
| 37 position: relative; | |
| 38 top: 100px; | |
| 39 background-color: green; | |
| 40 } | |
| 41 </style> | |
| 42 </head> | |
| 43 <body> | |
| 44 This test checks that sticky positioned elements are contained by their enclosin g ancestor with an overflow clip. | |
| 45 There should be no red. | |
| 46 <div id="overflow"> | |
| 47 <div class="spacer"></div> | |
| 48 | |
| 49 <div class="group" style="top: -120px"> | |
| 50 <div class="container"> | |
| 51 <div class="sticky box" style="top: 200px"></div> | |
| 52 </div> | |
| 53 </div> | |
| 54 | |
| 55 <div class="group" style="top: -20px"> | |
| 56 <div class="container"> | |
| 57 <div class="sticky box" style="top: 120px"></div> | |
| 58 </div> | |
| 59 </div> | |
| 60 | |
| 61 <div class="group" style="top: 120px"> | |
| 62 <div class="container"> | |
| 63 <div class="sticky box" style="top: 0"></div> | |
| 64 </div> | |
| 65 </div> | |
| 66 </div> | |
| 67 </body> | |
| 68 </html> | |
| OLD | NEW |