Design comparison
SolutionDesign
Community feedback
- @MelvinAguilarPosted about 2 years ago
Hi @okida-rafael ๐, good job completing this challenge, and welcome to the Frontend Mentor Community! ๐
Here are a few suggestions I've made that you can consider in the future if you're looking to improve the solution further:
- Try to use semantic tags in your code. Click here for more information.:
With semantic tags:
<body> <main class="container"> . . . </main> <footer class="attribution"> . . . </footer> <body>
- The container isn't centered correctly. You can use flexbox to center elements:
body { width: 100%; min-height: 100vh; display: flex; flex-direction: column; justify-content: center; align-items: center; }
Links with more information:
- The Complete Guide to Centering in CSS.
- A Complete Guide to Flexbox (CSS-Tricks).
- How TO - Center Elements Vertically (W3Schools).
- CSS Layout - Horizontal & Vertical Align (W3Schools).
To improve your solution on mobile devices:
- Instead of using pixels in font size, use relative units of measure like
rem
orem
. The font size in absolute length units (px) does not allow users with limited vision to change the text size in some browsers. Reference. - Use
max-width: 300px
to.container
selector instead of width, this will make the card container a bit responsive on mobile and set the element's maximum width to 300px. Remove this to make the image responsive:
.image { /* width: 290px; */ }
I hope those tips will help you.
Good job, and happy coding!
Marked as helpful2
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