Design comparison
SolutionDesign
Community feedback
- @denieldenPosted over 2 years ago
Hi Pablo, great work on this challenge! π
Here are a few tips for improve your code:
- add semantic html like
header, main, button
tags and wrap the relative content for improve the Accessibility - add descriptive text in the
alt
attribute of the images not simple word flag - to make it look as close to the design as possible set the same width of container
card-container
toselector
container class - remove all
margin
from#card-container .card
class because with flex they are superfluous and usegap
property - to make all flag images the same height use the
object-fit: cover and aspect-ratio: 3/2
properties - instead of using
px
use relative units of measurement likerem
-> read here - if you want to use the title for the
href
attribute you have to parse it inurl
, it can give problems creating links with empty spaces or special characters - I would also add a query reset button, I find it very convenient
Overall you did well π Hope this help!
0 - add semantic html like
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