Design comparison
SolutionDesign
Solution retrospective
Hey guys, i'm not much familiar with grid, please tell me how i could have done better.
Community feedback
- @vanzasetiaPosted almost 3 years ago
๐ Hi Daniel!
๐ Congratulations on finishing this challenge! I have some feedback on this solution:
- Accessibility
- ๐ Good job on using
main
landmark! - Every page should only contain one
h1
. In this case, you can have a hiddenh1
if you want and make all the currenth1
toh2
. - Use CSS to uppercase the text. The uppercased word in the HTML will be spelled by the screen reader (spelled letter by letter).
- For any decorative images, each
img
tag should have emptyalt=""
andaria-hidden="true"
attributes to make all web assistive technologies such as screen reader ignore those images. In this case, all images are decorative only. - The Learn More buttons should be links. They commonly will navigate the user to another webpage.
- Let me tell you that anchor tags are for navigation - moving to different pages or content on the same screen, while the
button
elements are for actions like opening a modal, submitting a form, toggling element, etc. - Next time, if you are going to use
button
element, always specify thetype
of thebutton
. In this case, you can set the type of them astype="button"
. By doing that, you prevent the button from behaving unexpectedly (like submitting). - Create a custom
:focus-visible
styling to any interactive elements (button
, links,input
,textarea
). This will make the users can navigate this website using keyboard (by usingTab
key) easily. - Changing the
html
or root font size can cause huge accessibility implications for those of the users with different font size or zoom requirements. Read what an accessibility expert (Grace Snow) has said about it.
- ๐ Good job on using
- Styling
- Don't limit the height of the
body
element, it will not allow the users to scroll the page if the page content needs moreheight
. Usemin-height
instead. - It looks like you make the site responsive in a complex way. I would recommend just having one breakpoint. So, if you are using the desktop-first approach, then create the styling for the desktop, and then when three columns layout is not looking good anymore, just make it one column.
- Don't limit the height of the
- Best Practice (Recommended)
- Write your code with consistent style (e.g. the indentation, quotes, whitespace, etc). If you write your code with consistent style, it will make it easier to read for everyone (including you, yourself).
- I would recommend writing the styling using mobile-first approach. It often makes me write less code.
That's it! Hopefully, this is helpful!
Marked as helpful1@Danielhu3Posted almost 3 years agoThanks! I already applied some of your tips.
1 - Accessibility
- @abhik-bPosted almost 3 years ago
๐ Hello Daniel , Your solution looks amazing & it is pretty responsive however I think you can watch this video which solves another frontend mentor challenge & you can learn a lot about CSS Grid through that video.
Please keep contributing this amazing solutions ๐
Marked as helpful0
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