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

Unified Diff: LayoutTests/fast/dom/HTMLDialogElement/top-layer-containing-block-scrolled-viewport-expected.html

Issue 14373010: Make abspos <dialog>'s containing block be the ICB. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: review comments Created 7 years, 7 months 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 side-by-side diff with in-line comments
Download patch
Index: LayoutTests/fast/dom/HTMLDialogElement/top-layer-containing-block-scrolled-viewport-expected.html
diff --git a/LayoutTests/fast/dom/HTMLDialogElement/top-layer-containing-block-scrolled-viewport-expected.html b/LayoutTests/fast/dom/HTMLDialogElement/top-layer-containing-block-scrolled-viewport-expected.html
new file mode 100644
index 0000000000000000000000000000000000000000..8fef0800d2481323bc4489f45925cb16f1cd0560
--- /dev/null
+++ b/LayoutTests/fast/dom/HTMLDialogElement/top-layer-containing-block-scrolled-viewport-expected.html
@@ -0,0 +1,32 @@
+<!DOCTYPE html>
+<html>
+<head>
+<style>
+.pseudodialog {
+ position: absolute;
+ left: 0; right: 0;
+ margin: auto;
+ border: solid;
+ padding: 1em;
+ background: white;
+ color: black;
+}
+</style>
+</head>
+<body style="height: 10000px; width: 10000px">
+<p style="position: fixed">
+This tests that a top layer element's containing block is the initial containing
+block. The dialog is positioned at (1200, 1200) and the window is scrolled to
+(1000, 1000) so the dialog should be positioned at (200, 200) relative to the
+viewport.
+</p>
+<div class="pseudodialog" style="top: 1200px; left: 1200px; right: auto; height: 250px; width: 50%; background-color: yellow">
+ This dialog should be onscreen with a width of 50% of the viewport. It is the child of an narrow element
+ positioned off screen, but its containing block is the initial containing block, so its
+ position and percent lengths are relative to that.
+</div>
+<script>
+window.scroll(1000, 1000);
+</script>
+</body>
+</html>

Powered by Google App Engine
This is Rietveld 408576698