justify-content-002.htm (1622B)
1 <!DOCTYPE html PUBLIC "-//W3C//DTD//XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> 2 <html xmlns="http://www.w3.org/1999/xhtml"> 3 <head> 4 <title>CSS Test: A flex container with the 'justify-content' property set to 'flex-start'</title> 5 <link rel="author" title="Microsoft" href="http://www.microsoft.com/" /> 6 <link rel="help" href="http://www.w3.org/TR/css-flexbox-1/#justify-content-property" /> 7 <link rel="match" href="reference/justify-content-001-ref.html"> 8 <meta name="fuzzy" content="maxDifference=0-1; totalPixels=0-6578" /> 9 <meta name="flags" content="image"> 10 <meta name="assert" content="This test checks that the flex container with 'justify-content: flex-start' packs flex items toward the start of the main axis of each line." /> 11 <style type="text/css"> 12 #flexbox 13 { 14 background: linear-gradient(to right, red 0, red 150px, orange 150px, orange 300px); 15 display: flex; 16 justify-content: center; 17 justify-content: flex-start; 18 height: 100px; 19 width: 300px; 20 } 21 div div 22 { 23 background-color: blue; 24 width: 75px; 25 } 26 </style> 27 </head> 28 <body> 29 <p>Test passes if there is a single blue rectangle on the left, a single orange rectangle directly to its right, and there is no red visible on the page.</p> 30 <div id="flexbox"> 31 <div></div> 32 <div></div> 33 </div> 34 </body> 35 </html>