Source code
Revision control
Copy as Markdown
Other Tools
Test Info:
- This WPT test may be referenced by the following Test IDs:
- /css/css-gaps/grid-lanes/row-subgrid-empty-decorations.html - WPT Dashboard Interop Dashboard
<!DOCTYPE html>
<title>
CSS Gap Decorations: a completely empty row subgrid of grid-lanes
paints rules in both axes
</title>
<link rel="author" title="Javier Contreras" href="mailto:javiercon@microsoft.com">
<link rel="match" href="row-subgrid-empty-decorations-ref.html">
<style>
body {
margin: 0;
}
.scene {
height: 330px;
position: relative;
width: 220px;
}
.lanes {
background: #dce6f0;
display: grid-lanes;
gap: 20px;
grid-template-rows: repeat(5, 50px);
height: 330px;
row-rule: 6px solid #243c9c;
width: 220px;
}
.before,
.after,
.side {
background: #52677d;
}
.before,
.after {
width: 30px;
}
.track-two {
grid-row: 2;
}
.track-three {
grid-row: 3;
}
.track-four {
grid-row: 4;
}
.side {
grid-row: 1;
width: 220px;
}
.subgrid {
background: #ffe0a3;
column-gap: 20px;
column-rule: 6px solid #b83b00;
display: grid;
grid-row: 2 / span 3;
grid-template-columns: repeat(2, 50px);
grid-template-rows: subgrid;
row-rule: 6px solid #9c1755;
width: 120px;
}
</style>
<div class="scene">
<div class="lanes">
<div class="before track-two"></div>
<div class="before track-three"></div>
<div class="before track-four"></div>
<div class="side"></div>
<div class="subgrid"></div>
<div class="after track-two"></div>
<div class="after track-three"></div>
<div class="after track-four"></div>
</div>
</div>