Commit 4f027ab4 authored by Miyoung Shin's avatar Miyoung Shin Committed by Commit Bot

[css-grid] Migrate grid-baseline-must-respect-grid-order.html to WPT

CL migrates grid-baseline-must-respect-grid-order.html to
external/wpt/css/css-grid/alignment, adding links to the relevant
specs and a test assertion describing its purpose, renaming it to
grid-baseline-004.html.

BUG=1063749, 767015

Change-Id: Ie0427d83993ec9b5e67b33652bc25b1bca32e1d8
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2147759
Commit-Queue: Miyoung Shin <myid.shin@igalia.com>
Reviewed-by: default avatarManuel Rego <rego@igalia.com>
Reviewed-by: default avatarJavier Fernandez <jfernandez@igalia.com>
Cr-Commit-Position: refs/heads/master@{#759595}
parent a7d35451
<!DOCTYPE html> <!DOCTYPE html>
<link href="resources/grid.css" rel="stylesheet"> <title>CSS Grid: Grid container baseline</title>
<link href="resources/grid-alignment.css" rel="stylesheet"> <link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com">
<link rel="help" href="https://drafts.csswg.org/css-grid/#grid-baselines">
<link rel="help" href="https://drafts.csswg.org/css-grid/#grid-order">
<link rel="help" href="https://crbug.com/234191">
<meta name="assert" content="Check that grid container must use its first item in grid-modified document order (grid order) to compute its baseline."/>
<link href="/css/support/grid.css" rel="stylesheet">
<link href="/css/support/alignment.css" rel="stylesheet">
<link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
<style> <style>
body { margin: 0; } body { margin: 0; }
.container { .container {
position: relative; position: relative;
font: 10px/1 Ahem; font: 10px/1 Ahem;
border: 5px solid; border: 5px solid;
width: 470px; width: 470px;
} }
.grid { .grid {
display: inline-grid; display: inline-grid;
...@@ -19,48 +27,51 @@ body { margin: 0; } ...@@ -19,48 +27,51 @@ body { margin: 0; }
.twoRows { grid-template-rows: 50px 50px; } .twoRows { grid-template-rows: 50px 50px; }
.threeRows { grid-template-rows: 50px 50px 50px; } .threeRows { grid-template-rows: 50px 50px 50px; }
.empty { .empty {
border-color: black; border-color: black;
border-style: solid; border-style: solid;
margin: 15px 0px 30px; margin: 15px 0px 30px;
border-width: 5px 0px 10px; border-width: 5px 0px 10px;
padding: 10px 0px 20px; padding: 10px 0px 20px;
} }
.item { .item {
height: 25px; height: 25px;
border-color: black; border-color: black;
border-style: solid; border-style: solid;
} }
.style1 { .style1 {
border-width: 5px 0px 10px; border-width: 5px 0px 10px;
padding: 10px 0px 20px; padding: 10px 0px 20px;
} }
.style2 { .style2 {
border-width: 10px 0px 5px; border-width: 10px 0px 5px;
padding: 20px 0px 10px; padding: 20px 0px 10px;
margin-top: 10px; margin-top: 10px;
} }
.style3 { .style3 {
border-width: 10px 0px 20px; border-width: 10px 0px 20px;
padding: 5px 0px 10px; padding: 5px 0px 10px;
margin-top: 20px; margin-top: 20px;
} }
.bothRowFirstColumn, .secondRowSecondColumn { .bothRowFirstColumn, .secondRowSecondColumn {
margin-right: 10px; margin-right: 10px;
margin-top: 10px; margin-top: 10px;
margin-bottom: 10px; margin-bottom: 10px;
background-color: pink; background-color: pink;
} }
.firstRowBothColumn, .secondRowBothColumn { .firstRowBothColumn, .secondRowBothColumn {
margin-top: 15px; margin-top: 15px;
margin-bottom: 15px; margin-bottom: 15px;
background-color: green; background-color: green;
} }
</style> </style>
<script src="../../resources/testharness.js"></script> <script src="/resources/testharness.js"></script>
<script src="../../resources/testharnessreport.js"></script> <script src="/resources/testharnessreport.js"></script>
<script src="../../resources/check-layout-th.js"></script> <script src="/resources/check-layout-th.js"></script>
<body onload="checkLayout('.grid, container')"> <script type="text/javascript">
setup({ explicit_done: true });
</script>
<body onload="document.fonts.ready.then(() => { checkLayout('.grid, container'); })">
<div id="log"></div> <div id="log"></div>
<p> <p>
The test shows 3 grids each of them with 3 items sorted differently in the DOM.<br> The test shows 3 grids each of them with 3 items sorted differently in the DOM.<br>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment