That is because the flex-container is only as high, as the items inside it, like a regular block container. The defaults for flex-direction and align-items are row and stretch respectively, that means the main-axis is the inline axis and the cross-axis is the block axis. Create a file called style.css (the file is already linked in the tag of the HTML code).Visit this page, copy the HTML code and save the file.The align-items property accepts five possible values: This tutorial will introduce you the align-items property and how to use it within a flex-container. The justify-content property specifies how the flex-items are distributed along the main axis, whereas the align-items property specifies how the flex-items are distributed along the cross axis of the flex-container. As you already learned in the second tutorial of this series, a flex-container has two following axes:
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |