row-dense-packing-001.html (1365B)
1 <!DOCTYPE html> 2 <html> 3 <link rel="help" href="https://drafts.csswg.org/css-grid-3"> 4 <link rel="match" href="row-dense-packing-001-ref.html"> 5 <link rel="author" title="Celeste Pan" href="mailto:celestepan@microsoft.com"> 6 <style> 7 .grid-lanes { 8 display: grid-lanes; 9 background: gray; 10 flow-tolerance: 0; 11 grid-lanes-direction: row; 12 grid-template-rows: repeat(3, 50px); 13 width: 170px; 14 grid-auto-flow: dense; 15 } 16 </style> 17 <body> 18 <p>Ensure that dense-packing places items correctly in grid-lanes.</p> 19 <div class="grid-lanes"> 20 <div style="background: lightskyblue; width: 20px;" > 21 1 22 </div> 23 <div style="background: lightcoral; width: 60px;" > 24 2 25 </div> 26 <div style="background: lightgreen; width: 60px;"> 27 3 28 </div> 29 <div style="background: brown; width: 10px; grid-row: span 2;"> 30 4 31 </div> 32 <div style="background: red; width: 40px;"> 33 5 34 </div> 35 <div style="background: pink; width: 45px;"> 36 6 37 </div> 38 <div style="background: yellow; width: 40px;"> 39 7 40 </div> 41 <div style="background: brown; width: 10px; grid-row: span 2;"> 42 8 43 </div> 44 <div style="background: blueviolet; width: 12px; grid-row: 2; margin-left: 3px;"> 45 9 46 </div> 47 <div style="background: orange; width: 20px; grid-row: 2;"> 48 10 49 </div> 50 </div> 51 </body> 52 </html>