Stats Preview Card || Mobile Frist || Css Grid & Flexbox
Design comparison
Solution retrospective
Hi thereπ This challenge was a great learning experience for me. Kindly check it out and give your feedback(s). Thanksππ
Community feedback
- @vanzasetiaPosted over 2 years ago
Hello, Ernest! π
Great work on this challenge! Your solution looks pretty good! π
There are some areas that you could do to improve this solution,
- I would recommend increasing the breakpoint of the media query because it's too early to make the layout into two columns. On mobile landscape 360px * 640px, the layout becomes the two columns layout or the desktop layout.
- In your CSS, I noticed this selector
section article.stat-number h2
which would be much be asstat-number-heading
. I would recommend only nesting when you want to style pseudo-elements, pseudo-classes (:hover
,:focus
, etc) and@media
queries. It's a good practice to keep the CSS specificity as low and flat as possible. High specificity will make your stylesheet hard to maintain. - In addition to the previous point, the stat number should not be a heading, it should be a paragraph because the content below it is too small. You might find it helpful if you think of a heading as a title in the document.
- I would recommend making the stats as a
ul
instead of asection
and wrapping each stats item withli
. Usingsection
andarticle
too much might cause a lot of noise for users of the screen reader.
I hope this helps! Keep up the good work! π
Marked as helpful0@gbabohernestPosted over 2 years ago@vanzasetia thanks for so much for the feedbacks. I wil do my best to keep things simple in my code. Thanks a lot. π
1 - Account deleted
Hi there,
-
remove the margin from the article and add to the body
place-items:center; min-height:100vh;
-
check the HTML report to fix accessibility issues
hope this is helpful
Marked as helpful0@gbabohernestPosted over 2 years ago@Old1337 thank you. it was helpful. π
1 -
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