Source code
Revision control
Copy as Markdown
Other Tools
<!DOCTYPE html>
<link rel="author" title="Javier Contreras" href="mailto:javiercon@microsoft.com">
<style>
body { margin: 0; }
.case { position: relative; width: max-content; }
.lanes {
background: #cdd5e0;
column-gap: 20px;
display: grid;
grid-template-columns: repeat(2, 60px);
grid-template-rows: repeat(20, 20px);
width: max-content;
}
.lanes > div {
background: #5b8def;
color: white;
font: 600 12px/1 sans-serif;
grid-column: 1;
grid-row: 1 / span 2;
height: 40px;
}
.lanes > .second-lane { grid-column: 2; }
.lanes > .third { grid-row: 7 / span 2; }
.lanes > .medium { grid-row: 10 / span 3; height: 60px; }
.lanes > .tall { grid-row: 14 / -1; height: 140px; }
.lanes > .spanner {
background: #8a6df0;
grid-column: 1 / -1;
grid-row: 4 / span 2;
}
.lanes > .centered {
background: #1f9d6b;
grid-row: 15;
height: 20px;
}
.col-rule {
border-left: 4px solid blue;
left: 68px;
position: absolute;
width: 0;
}
</style>
<div class="case">
<div class="lanes">
<div>1</div>
<div class="second-lane">A</div>
<div class="spanner">2</div>
<div class="third">3</div>
<div class="centered">4</div>
<div class="second-lane third">B</div>
<div class="second-lane medium">C</div>
<div class="second-lane tall">D</div>
</div>
<div class="col-rule" style="top: 0; height: 40px;"></div>
<div class="col-rule" style="top: 120px; height: 40px;"></div>
<div class="col-rule" style="top: 180px; height: 60px;"></div>
<div class="col-rule" style="top: 260px; height: 140px;"></div>
</div>