grid-placement-using-named-grid-lines-003.html (966B)
1 <!DOCTYPE html> 2 <meta charset="utf-8"> 3 <title>CSS Grid Layout Test: Grid item placement with named line and auto repeat()</title> 4 <link rel="author" title="Oriol Brufau" href="mailto:obrufau@igalia.com"> 5 <link rel="help" href="http://www.w3.org/TR/css-grid-1/#line-placement"> 6 <link rel="match" href="../../reference/ref-filled-green-100px-square.xht"> 7 <meta name="assert" content="Grid placement algorithm is able to select the right line when there is an auto repeat()."> 8 <style> 9 .grid { 10 display: grid; 11 width: 300px; 12 height: 300px; 13 position: relative; 14 top: -200px; 15 left: -200px; 16 grid-template-columns: repeat(auto-fill, 100px 100px) [area-start] 100px [area-end]; 17 grid-template-rows: repeat(auto-fill, 100px 100px [area-start]) [area-start] 100px [area-end]; 18 } 19 .grid > div { 20 grid-area: area; 21 background: green; 22 } 23 </style> 24 <p>Test passes if there is a filled green square and <strong>no red</strong>.</p> 25 <div class="grid"> 26 <div></div> 27 </div>