Design comparison
Solution retrospective
This is my first challenge after learning a little bit of html and css. I had a little bit of trouble centering the content. But after searching for a while I finally got it. I hope I can get better advice on what techniques to use.
What challenges did you encounter, and how did you overcome them?I had trouble centering the existing container element. After searching on Google, I finally found a clue by utilizing flexbox combined with the use of the height property set to 100vh to center the element vertically and horizontally.
What specific areas of your project would you like help with?I am still having trouble determining the correct element tag when creating a web element. I still do not fully understand the concept of semantic html and accessibility. In addition to these problems, I am also still having trouble centering elements with the right and most efficient techniques. Feel free to comment and give an advice to me. Thank you so much.
Community feedback
- @MikDra1Posted about 2 months ago
If you want to make your card responsive with ease you can use this technique:
.card { width: 90%; max-width: 37.5rem; }
On the smaller screens card will be 90% of the parent (here body), but as soon as the card will be 37.5rem (600px) it will lock with this size.
Also to put the card in the center I advise you to use this code snippet:
.container { display: grid; place-items: center; }
Hope you found this comment helpful 💗💗💗
Good job and keep going 😁😊😉
Marked as helpful1@NakhaaPosted about 2 months ago@MikDra1 Thank you, that's very helpful. I'm still learning about the concept of responsive web design. I hope I can understand the technique quickly :)
0
Please log in to post a comment
Log in with GitHubJoin our Discord community
Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!
Join our Discord