Skip to content

Commit 507f74f

Browse files
authored
1 parent 4e64b64 commit 507f74f

File tree

1 file changed

+41
-0
lines changed

1 file changed

+41
-0
lines changed
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
<!DOCTYPE html>
2+
<html>
3+
<head>
4+
<link rel="author" title="Sammy Gill" href="mailto:[email protected]">
5+
<meta name="assert" content="Margin, border, and padding of subgrids should influence the offset of items in the same baseline alignment context">
6+
<link rel="help" href="https://drafts.csswg.org/css-grid-2/#subgrid-item-contribution">
7+
<link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
8+
<script src="/resources/testharness.js"></script>
9+
<script src="/resources/testharnessreport.js"></script>
10+
<script src="/resources/check-layout-th.js"></script>
11+
<style>
12+
html,body {
13+
color:black; background-color:white; padding:0; margin:0;
14+
}
15+
.grid {
16+
font:16px/1 Ahem;
17+
display: inline-grid;
18+
border: 1px solid black;
19+
grid-template-columns: auto auto;
20+
}
21+
.subgrid {
22+
display: grid;
23+
grid-template-rows: subgrid;
24+
border: 9px solid blue;
25+
margin-top: 15px;
26+
padding-top: 6px;
27+
}
28+
.first-baseline {
29+
align-self: baseline;
30+
}
31+
</style>
32+
</head>
33+
<body onload="checkLayout('.first-baseline')">
34+
<div id="target" class="grid">
35+
<div data-offset-y="31" class="first-baseline">X</div>
36+
<div class="subgrid">
37+
<div data-offset-y="31" class="first-baseline">X</div>
38+
</div>
39+
</div>
40+
</body>
41+
</html>

0 commit comments

Comments
 (0)