Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(301)

Side by Side Diff: third_party/WebKit/LayoutTests/fast/css/sticky/sticky-top-zoomed-expected.html

Issue 1308273010: Adapt and reland old position sticky implementation (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Merge with master (removing horizontal-bt test) Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <script>
3 if (window.internals) {
4 internals.settings.setCSSStickyPositionEnabled(true);
5 }
6 </script>
7
8 <html>
9 <head>
10 <style>
11 body {
12 margin: 0;
13 height: 2000px;
14 }
15
16 ::-webkit-scrollbar {
17 width: 0px;
18 height: 0px;
19 }
20
21 .group {
22 display: inline-block;
23 position: relative;
24 width: 160px;
25 height: 300px;
26 }
27
28 .container {
29 width: 150px;
30 height: 300px;
31 outline: 2px solid black;
32 }
33
34 .box {
35 width: 150px;
36 height: 150px;
37 }
38
39 .sticky {
40 position: sticky;
41 top: 75px;
42 background-color: green;
43 }
44
45 .indicator {
46 position: absolute;
47 top: 0;
48 left: 0;
49 background-color: red;
50 }
51 </style>
52 <script>
53 function doTest()
54 {
55 if (window.internals)
56 internals.setPageScaleFactor(1.5);
57 }
58 window.addEventListener('load', doTest, false);
59 </script>
60 </head>
61 <body>
62 <div class="group" style="top: -100px">
63 <div class="indicator box" style="top: 150px;"></div>
64 <div class="container">
65 <div class="sticky box"></div>
66 </div>
67 </div>
68
69 <div class="group" style="top: 0">
70 <div class="indicator box" style="top: 75px;"></div>
71 <div class="container">
72 <div class="sticky box"></div>
73 </div>
74 </div>
75
76 <div class="group" style="top: 100px">
77 <div class="indicator box" style="top: 0;"></div>
78 <div class="container">
79 <div class="sticky box"></div>
80 </div>
81 </div>
82 </body>
83 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698