column-dense-packing-multi-span-009.html (1513B)
1 <!DOCTYPE html> 2 <html> 3 <link rel="help" href="https://drafts.csswg.org/css-grid-3"> 4 <link rel="match" href="column-dense-packing-multi-span-009-ref.html"> 5 <link rel="author" title="Celeste Pan" href="mailto:celestepan@microsoft.com"> 6 <style> 7 .grid-lanes { 8 display: grid-lanes; 9 flow-tolerance: 0; 10 gap: 10px; 11 padding: 10px; 12 grid-template-columns: repeat(4, 60px); 13 grid-auto-flow: dense; 14 } 15 </style> 16 <body> 17 <p>Ensure that dense-packing correctly accounts for the gaps between items when placing them in track openings. Items to be placed in track openings are yellow.</p> 18 <div class="grid-lanes"> 19 <div style="background: aquamarine; height: 120px;" > 20 1 21 </div> 22 <div style="background: blue; height: 40px;" > 23 2 24 </div> 25 <div style="background: blueviolet; height: 20px;"> 26 3 27 </div> 28 <div style="background: lightsteelblue; height: 60px; grid-column: 4;"> 29 4 30 </div> 31 <div style="background: aqua; height: 20px; grid-column: span 4;"> 32 5 33 </div> 34 <div style="background: yellow; height: 10px; grid-column: span 3;"> 35 6 36 </div> 37 <div style="background: yellow; height: 10px; grid-column: span 3;"> 38 7 39 </div> 40 <div style="background: yellow; height: 10px; grid-column: span 3;"> 41 8 42 </div> 43 <div style="background: green; height: 10px; grid-column: span 3;"> 44 9 45 </div> 46 <div style="background: yellow; height: 10px; grid-column: span 2;"> 47 10 48 </div> 49 </div> 50 </body> 51 </html>