Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / paint / invalidation / spv2 / grid-element-change-rows-repaint.html
blob8bbe13afaefabdd46c1db59e0d89910637ec75cf
1 <!-- Based on fast/css-grid-layout/grid-element-change-rows-repaint.html -->
2 <!DOCTYPE html>
3 <html>
4 <script src="resources/paint-invalidation-test.js"></script>
5 <script>
6 window.expectedPaintInvalidationObjects = [
7 "LayoutGrid DIV class='grid'",
8 "LayoutBlockFlow DIV class='sizedToGridArea'",
9 ];
10 function paintInvalidationTest()
12 var gridElement = document.getElementsByClassName("grid")[0];
13 gridElement.style.gridTemplateRows = "100px 50px";
15 window.addEventListener("load", runPaintInvalidationTest, false);
16 </script>
17 <link href="../../../fast/css-grid-layout/resources/grid.css" rel="stylesheet">
18 <style>
19 body {
20 font: 10px/1 Ahem;
23 .grid {
24 width: -webkit-fit-content;
25 grid-template-rows: 50px 100px;
26 grid-template-columns: 100px;
28 .sizedToGridArea {
29 background-color: purple;
31 </style>
32 <body>
33 <div>This test checks that changing the grid-template-rows lead to a repaint. The final grid element should be 100px * 150px, the grid item should be 100px * 100px. No trace of the elements before the grid-template-rows change should be seen.</div>
34 <div class="constrainedContainer">
35 <div class="grid">
36 <div class="sizedToGridArea"></div>
37 </div>
38 </div>
39 </body>
40 </html>