select-element-zero-height-001.html (800B)
1 <!DOCTYPE html> 2 <title>Select element in flexbox with zero height</title> 3 <link rel="author" title="Mozilla" href="https://mozilla.org"> 4 <link rel="help" href="https://bugzilla.mozilla.org/show_bug.cgi?id=1591925"> 5 <link rel="help" href="https://drafts.csswg.org/css-flexbox/#content-size-suggestion"> 6 <link rel="match" href="select-element-zero-height-001-ref.html"> 7 <style> 8 .container { 9 display: flex; 10 flex-direction: column; 11 height: 0px; 12 border: 1px dotted black; 13 } 14 select { 15 /* 16 WebKit applies intrinsic (default) margins to control elements in some circumstances, 17 let's disable them to avoid mismatch errors caused by those margins. 18 */ 19 margin: 0; 20 } 21 </style> 22 <body> 23 <div class="container"> 24 <select><option>Hi</option></select> 25 </div> 26 </body>