Design comparison
Solution retrospective
What ways could I have done the classing differently? Was my overall structure of the html tags okay? How do you think I could have made the better? (i really wanted to disable the submit button, funnily enough I only know how to get this done in react.)
Did I use some antiquated methods in my CSS?
All feedback is deeply appreciated.
Community feedback
- @DamsithcoderPosted over 1 year ago
Great job .Well done if you can put the two divs in a <main> tag ,some warnings will be removed.
<main> <div class="card-1"> ... </div> <div class="card-2"> ... </div> </main> KEEP PRACTICING...!0 - @0xabdulkhaliqPosted over 1 year ago
Hello there 👋. Congratulations on successfully completing your first challenge! 🎉
- I have other recommendations regarding your code that I believe will be of great interest to you.
HTML 🏷️:
- This solution generates accessibility error reports due to
non-semantic
markup
- So fix it by wrapping the
<div class="main-container">
with semantic element<main>
along with<div class="attribution">
with semantic element<footer>
to improve accessibility and organization of your page.
CSS 🎨:
- As per the design we want to center the component
.main-container
both horizontally & vertically with css
- To properly center the component in the page, you should use
Flexbox
orGrid
layout. You can read more about centering in CSS here 📙.
- For this demonstration we use css
grid
to center the component
body { min-height: 100vh; display: grid; place-items: center; margin: 0; }
I hope you find it helpful ! 😄 Above all, the solution you submitted is great
Happy coding!
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