blob: 01417f50fbd0f61ddad3575da3f9ca26df690399 [file] [log] [blame]
<!-- Based on fast/repaint/justify-items-legacy-change.html -->
<!DOCTYPE HTML>
<script src="resources/paint-invalidation-test.js"></script>
<script>
function paintInvalidationTest() {
document.getElementById('parentContainer').style.justifyItems = 'legacy center';
}
onload = runPaintInvalidationTest;
</script>
<style>
body {
margin: 0;
}
#parentContainer {
justify-items: center;
background-color: orange;
width: 300px;
height: 400px;
}
#container {
display: grid;
grid: 100px 100px / 150px 150px;
width: 200px;
height: 300px;
background-color: red;
}
.item1 {
grid-row: 1;
grid-column: 1;
background-color: green;
border: solid thin blue;
width: 50px;
}
.item2 {
grid-row: 1;
grid-column: 2;
background-color: green;
border: solid thin blue;
width: 50px;
</style>
<p style="height: 20px">Tests invalidation on justify-items style change (legacy value). Passes if green bars are centerd inside their red container.</p>
<div id="parentContainer">
<div id="container">
<div class="item1">
<div style="height: 50px"></div>
</div>
<div class="item2">
<div style="height: 50px"></div>
</div>
</div>
</div>