Source code

Revision control

Copy as Markdown

Other Tools

Test Info:

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>CSS Grid Lanes Test: With `track-reverse` on columns, an overflowing item aligns to the end edge of its two-column grid area for `flow-start` and the start edge for `flow-end`</title>
<link rel="author" title="Celeste Pan" href="mailto:celestepan@microsoft.com">
<link rel="match" href="column-track-reverse-justify-items-002-ref.html">
<style>
html, body {
font: 16px/1 monospace;
background: white;
}
.label {
font: 16px/1 monospace;
}
.grid-lanes {
display: grid-lanes;
grid-lanes-direction: column track-reverse;
grid-template-columns: repeat(3, 50px);
gap: 0;
width: 150px;
height: 40px;
border: 1px solid;
margin-bottom: 4px;
}
item {
display: block;
height: 24px;
color: white;
background: #2ca02c;
}
.wide {
width: 150px;
grid-column: span 2;
color: black;
background: yellow;
}
</style>
</head>
<body>
<div class="label">justify-items: flow-start (spanning item)</div>
<div class="grid-lanes" style="justify-items: flow-start;">
<item class="wide">1</item>
</div>
<div class="label">justify-items: flow-end (spanning item)</div>
<div class="grid-lanes" style="justify-items: flow-end;">
<item class="wide">1</item>
</div>
<div class="label">justify-self: flow-start (spanning item)</div>
<div class="grid-lanes">
<item class="wide" style="justify-self: flow-start;">1</item>
</div>
<div class="label">justify-self: flow-end (spanning item)</div>
<div class="grid-lanes">
<item class="wide" style="justify-self: flow-end;">1</item>
</div>
</body>
</html>