blob: 726ffcd013be4d874edeaeacb13de6dc01a460c2 [file] [log] [blame]
<!DOCTYPE html>
<html>
<script>
if (window.testRunner)
testRunner.overridePreference("WebKitCSSGridLayoutEnabled", 1);
</script>
<link href="resources/grid.css" rel="stylesheet">
<style>
.columnGrid {
grid-columns: 50px 100px;
/* grid-rows is left unset so that the grid items' row is implicit. */
font: 10px/1 Ahem;
}
.rowGrid {
grid-rows: 50px 100px;
/* grid-columns is left unset so that the grid items' column is implicit. */
font: 10px/1 Ahem;
}
</style>
<script src="../../resources/check-layout.js"></script>
<body onload="checkLayout('.grid');">
<p>Test that negative &lt;integer&gt; positions are resolved against the explicit grid (that is don't account for implicit columns and rows).</p>
<div class="constrainedContainer">
<div class="grid columnGrid">
<div class="sizedToGridArea autoRowThirdColumn" data-expected-width="60" data-expected-height="30">XXXXXX XXXXX XXXXX</div>
<div class="sizedToGridArea autoLastRowAutoLastColumn" data-expected-width="100" data-expected-height="30"></div>
</div>
</div>
<div class="constrainedContainer">
<div class="grid columnGrid">
<div class="sizedToGridArea thirdRowAutoColumn" data-expected-width="50" data-expected-height="30">XXXXXX XXXXX XXXXX</div>
<div class="sizedToGridArea autoLastRowAutoLastColumn" data-expected-width="100" data-expected-height="0"></div>
</div>
</div>
<div class="constrainedContainer">
<div class="grid rowGrid">
<div class="sizedToGridArea autoRowThirdColumn" data-expected-width="60" data-expected-height="50">XXXXXX XXXXX XXXXX</div>
<div class="sizedToGridArea autoLastRowAutoLastColumn" data-expected-width="0" data-expected-height="100"></div>
</div>
</div>
<div class="constrainedContainer">
<div class="grid rowGrid">
<div class="sizedToGridArea thirdRowAutoColumn" data-expected-width="60" data-expected-height="30">XXXXXX XXXXX XXXXX</div>
<div class="sizedToGridArea autoLastRowAutoLastColumn" data-expected-width="60" data-expected-height="100"></div>
</div>
</div>
</body>
</html>