align-content-wrap-004.html (1169B)
1 <!DOCTYPE html> 2 <link rel="author" title="Google LLC" href="http://www.google.com" /> 3 <link rel="help" href="https://drafts.csswg.org/css-flexbox/#cross-sizing" /> 4 <title>css-flexbox: Tests that we size items in a wrapping column flexbox as fit-content</title> 5 <link rel="match" href="../reference/ref-filled-green-100px-square.xht" /> 6 7 <style> 8 .flex { 9 display: flex; 10 flex-wrap: wrap; 11 align-content: center; 12 flex-direction: column; 13 align-items: flex-start; 14 width: 100px; 15 line-height: 1; 16 } 17 .flex > div { 18 min-height: 0; 19 background: green; 20 } 21 .flex * { 22 vertical-align: top; 23 } 24 </style> 25 26 <p>Test passes if there is a filled green square and <strong>no red</strong>.</p> 27 28 <div class="flex"> 29 <div style="align-self: stretch;"> 30 <div style="display: inline-block; width: 20px; height: 40px;"></div> 31 </div> 32 <div style="height: 60px;"> 33 <div style="display: inline-block; height: 15px; width: 20px;"></div> 34 <div style="display: inline-block; height: 15px; width: 100px;"></div> 35 <div style="display: inline-block; height: 15px; width: 100px;"></div> 36 <div style="display: inline-block; height: 15px; width: 100px;"></div> 37 </div> 38 </div>