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

Unified Diff: third_party/WebKit/LayoutTests/fragmentation/table-with-border-spacing.html

Issue 2803383002: The first table row is pushed down by border-spacing. (Closed)
Patch Set: break-inside:avoid on a row shouldn't prevent breaking inside adjacent border spacing Created 3 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: third_party/WebKit/LayoutTests/fragmentation/table-with-border-spacing.html
diff --git a/third_party/WebKit/LayoutTests/fragmentation/table-with-border-spacing.html b/third_party/WebKit/LayoutTests/fragmentation/table-with-border-spacing.html
new file mode 100644
index 0000000000000000000000000000000000000000..1b3f242fa3c50300c2bf7a208e280f2449ed2039
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/fragmentation/table-with-border-spacing.html
@@ -0,0 +1,32 @@
+<!DOCTYPE html>
+<style>
+ .cell > div { background:white; }
+</style>
+<p>No red should be seen below.</p>
+<div id="multicol" style="columns:2; column-fill:auto; height:70px; width:200px; line-height:20px;">
+ <div style="position:relative; display:table; border-spacing:10px;">
+ <div class="cell" style="display:table-cell; width:30px; background:red;">
+ <div id="child1">1<br></div>
+ <div id="child2">2<br></div>
+ <div id="child3">3<br></div>
+ <div id="child4">4<br></div>
+ <div id="child5">5<br></div>
+ </div>
+ </div>
+</div>
+<script src="../resources/testharness.js"></script>
+<script src="../resources/testharnessreport.js"></script>
+<script>
+ test(() => {
+ assert_equals(document.getElementById("child1").offsetTop, 10);
+ assert_equals(document.getElementById("child1").offsetHeight, 20);
+ assert_equals(document.getElementById("child2").offsetTop, 30);
+ assert_equals(document.getElementById("child2").offsetHeight, 20);
+ assert_equals(document.getElementById("child3").offsetTop, 50);
+ assert_equals(document.getElementById("child3").offsetHeight, 20);
+ assert_equals(document.getElementById("child4").offsetTop, 70);
+ assert_equals(document.getElementById("child4").offsetHeight, 20);
+ assert_equals(document.getElementById("child5").offsetTop, 90);
+ assert_equals(document.getElementById("child5").offsetHeight, 20);
+ }, "Table with border spacing");
+</script>

Powered by Google App Engine
This is Rietveld 408576698