Index: third_party/WebKit/LayoutTests/fast/css/sticky/sticky-both-sides.html |
diff --git a/third_party/WebKit/LayoutTests/fast/css/sticky/sticky-both-sides.html b/third_party/WebKit/LayoutTests/fast/css/sticky/sticky-both-sides.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..5ca5df94147f63ddb737cfdef1ba7d3cc04f2c01 |
--- /dev/null |
+++ b/third_party/WebKit/LayoutTests/fast/css/sticky/sticky-both-sides.html |
@@ -0,0 +1,74 @@ |
+<!DOCTYPE html> |
+<script> |
+if (window.internals) { |
+ internals.settings.setCSSStickyPositionEnabled(true); |
+} |
+</script> |
+ |
+<html> |
+<head> |
+<style> |
+ body { |
+ margin: 0; |
+ width: 2000px; |
+ overflow: hidden; /* hide scrollbars */ |
+ } |
+ |
+ .container { |
+ position: absolute; |
+ width: 2000px; |
+ height: 180px; |
+ top: 350px; |
+ outline: 2px solid black; |
+ } |
+ |
+ .vertical.container { |
+ top: 0px; |
+ left: 350px; |
+ width: 180px; |
+ height: 2000px; |
+ } |
+ |
+ .box { |
+ width: 800px; |
+ height: 180px; |
+ } |
+ |
+ .vertical .box { |
+ width: 180px; |
+ height: 500px; |
+ } |
+ |
+ .sticky { |
+ position: sticky; |
+ left: 50px; |
+ right: 50px; |
+ background-color: green; |
+ } |
+ |
+ .vertical .sticky { |
+ left: 0; |
+ top: 50px; |
+ bottom: 50px; |
+ background-color: blue; |
+ opacity: 0.75; |
+ } |
+</style> |
+<script> |
+ function doTest() |
+ { |
+ window.scrollTo(300, 300); |
+ } |
+ window.addEventListener('load', doTest, false); |
+</script> |
+</head> |
+<body> |
+ <div class="container"> |
+ <div class="sticky box"></div> |
+ </div> |
+ <div class="vertical container"> |
+ <div class="sticky box"></div> |
+ </div> |
+ |
+</body> |
+</html> |