@correlucas
Posted
👾Hello again Blah =), Congratulations on completing this challenge!
Here's two tips for you =)
Your component is okay but it's missing the vertical alignment. The best way to do it is by using flexbox
. First step is to add min-height: 100vh
to make the body height size becomes 100% of the screen height, this way you make sure that whatever the situation the child element (the container) align the body and then use the flex properties for alignment with display: flex
/ align-items: center;
/ justify-content: center;
body {
min-height: 100vh;
font-family: "Barlow Semi Condensed", sans-serif;
font-weight: 500;
font-size: 13px;
line-height: 1.3;
display: flex;
align-items: center;
justify-content: center;
}
Something you can do is to improve your html markup using meaningful tags and replacing the divs. In this case, for example the main block/div that takes all the content can be wrapped with <main>
or section, if you think about = the cards you can replace the <div>
that’s wrapping each card with <article>
you can wrap the paragraph with the quote with the tag <blockquote>
this way you'll wrap each block of element with the best tag in this situation. Note that <div>
is only a block element without meaning, prefer to use it for small blocks of content inside bigger blocks wrapped with some better markup.
Here's a complete guide for HTML semantic TAGS: https://www.w3schools.com/TAgs/default.asp
✌️ I hope this helps you and happy coding!
Marked as helpful
@blahking
Posted
Thank you@correlucas! I never care about html semantics before, it's my fault😅 I always use the <div> for a container box to wrap other element and <p> for a text container to wrap text. I'll improve my html tags to be more meaningful in the furture.
Thanks again!
@correlucas
Posted
@blahking This is fine, I did the same as you, only recently I started to use more semantic tags because someone commented on my solution hahaha