grid-aspect-ratio-023.html (1069B)
1 <!DOCTYPE html> 2 <title>CSS aspect-ratio: grid track size should respect aspect-ratio when the 3 ratio-dependent axis is the inline axis</title> 4 <link rel="author" title="Mozilla" href="https://www.mozilla.org/"> 5 <link rel="help" href="https://drafts.csswg.org/css-sizing-4/#aspect-ratio"> 6 <link rel="help" href="https://drafts.csswg.org/css-grid/#algo-track-sizing"> 7 <link rel="match" href="../../reference/ref-filled-green-100px-square.xht" /> 8 <style> 9 #reference-overlapped-red { 10 position: absolute; 11 background-color: red; 12 width: 100px; 13 height: 100px; 14 z-index: -1; 15 } 16 </style> 17 18 <p>Test passes if there is a filled green square and <strong>no red</strong>.</p> 19 20 <div id="reference-overlapped-red"></div> 21 <div style="width: 100px;"> 22 <div style="display: grid; grid-auto-flow: column; height: 100px; background: green;"> 23 <div style="height: 100px; aspect-ratio: 1/2;"></div> 24 <div style="height: 100px; aspect-ratio: 1/1; max-width: 25px;"></div> 25 <div style="height: 100px; aspect-ratio: .1/1; min-width: 25px;"></div> 26 </div> 27 </div>