Source code

Revision control

Copy as Markdown

Other Tools

Test Info:

<!doctype html>
<meta charset="utf8">
<title>CSS contain-intrinsic-size: grid definite size, large size</title>
<link rel="author" title="Vladimir Levin" href="mailto:vmpstr@chromium.org">
<link rel="match" href="contain-intrinsic-size-024-ref.html">
<meta name="assert" content="contain-intrinsic-size sizes grid container, even if definite tracks are smaller">
<style>
#grid {
border: 3px solid black;
display: grid;
grid-template: 55px 66px / 77px 88px;
contain-intrinsic-size: 200px 300px;
contain: size;
width: max-content;
background: lightblue;
grid-gap: 5px;
}
.item {
background: lightgreen;
opacity: 0.5;
height: 100%;
}
</style>
<div id=grid>
<div class=item></div>
<div class=item></div>
<div class=item></div>
<div class=item></div>
</div>