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

Side by Side Diff: third_party/WebKit/LayoutTests/fragmentation/border-spacing-break-before-unbreakable-row.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 unified diff | Download patch
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <style>
3 #multicol { position:relative; columns:4; column-gap:0; column-fill:auto; wi dth:20px; height:50px; line-height:20px; }
4 table { width:100%; border-spacing:0 20px; }
5 tr { break-inside:avoid; }
6 td { padding:0; }
7 td > div { height:20px; box-sizing:border-box; }
8 .squarepart { position:relative; background:blue; }
9 </style>
10 <p>There should be a blue square below.</p>
11 <div id="multicol">
12 <!-- All table rows are 20px tall, potentially with some overflow past the
13 bottom (which isn't enough to affect fragmentation). -->
14 <table>
15 <tr>
16 <td>
17 <div>
18 <div class="squarepart"><br></div>
19 </div>
20 </td>
21 </tr>
22 <tr>
23 <td>
24 <div style="padding-top:10px;">
25 <div class="squarepart"><br></div>
26 </div>
27 </td>
28 </tr>
29 <tr>
30 <td>
31 <div style="padding-top:20px;">
32 <div class="squarepart"><br></div>
33 </div>
34 </td>
35 </tr>
36 <tr>
37 <td>
38 <div style="padding-top:20px;">
39 <div class="squarepart"><br></div>
40 </div>
41 </td>
42 </tr>
43 </table>
44 </div>
45 <script src="../resources/testharness.js"></script>
46 <script src="../resources/testharnessreport.js"></script>
47 <script>
48 test(() => {
49 var squareparts = document.getElementsByClassName("squarepart");
50 assert_equals(squareparts.length, 4);
51 assert_equals(squareparts[0].offsetTop, 20);
52 assert_equals(squareparts[1].offsetTop, 20);
53 assert_equals(squareparts[2].offsetTop, 20);
54 assert_equals(squareparts[3].offsetTop, 20);
55 }, "It's okay to break inside border spacing");
56 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698