Design comparison
Solution retrospective
Hello my community,
kindly review my solution and share your tips and feedback on how to improve my design and code.
Thanks 2div
Community feedback
- @pikapikamartPosted almost 3 years ago
Hey, nice work on this one. I see that you somehow went on another approach on this one, it's fine but I really recommend that when you tackle other challenges, following the design itself should be the best ui approach :>
Here are some other suggestions besides Deniel helpful suggestion and don't mind me reiterating some already suggested ones:
- Using
main
tag on the.container
instead ofdiv
would make the site more accessible. When creating websites, you should usemain
tag to nest the main-content of that webpage, on this case, the whole content should be inside themain
. - To center the contents on your solution, you don't need to use
margin
on the.container
since it is not really consistent. What you can do is that, add these stylings on the.container
:
justify-content: center; min-height: 100vh;
This way, the item will be centered properly and dynamically.
- The
margin
on the.card
could be removed since its parent (.container
) is already making it centered. - For the
img
, you could just usealt=""
andaria-hidden="true"
on it since the image doesn't really depict anything visually and could just be left empty so that screen reader won't read it. - Also when you use
img
orsvg
, you don't use words that relates to graphic like "image"` since those elements are already graphics. - For the bold text, you can use
h1
on it for now. Remember that a webpage needs to have anh1
and you can replace thep
tag with it on this. - When wrapping up text content, use meaningful elements like a
p
tag, change yourspan
into usingp
tag.
Aside from those, great job again on this one^^
Marked as helpful1 - Using
- @denieldenPosted almost 3 years ago
Hello Hersi, great job! Congratulations on completing the challenge.
I have a few advice for you:
- add
main
tag and wrap the card for Accessibility - remove
margin, max-width and min-width
properties fromcontainer
class - remove all
margin
fromcard
class - use
justify-content: center;
to thecontainer
class for center the card. Read here -> flex guide - add
heigth: 100vh
tocontainer
class because Flexbox aligns to the size of the parent container.
Overall you did well :)
Hope this help and happy coding!
Marked as helpful1@pikapikamartPosted almost 3 years ago@denielden Hey, really nice feedback on this challenge. One thing to change though, instead of
height: 100vh
always usemin-height: 100vh
so that the element won't have a fixed height. That's it and really nice feedback again^^Marked as helpful1@denieldenPosted almost 3 years ago@pikapikamart Thank you so much! You're right :)
Marked as helpful1 - add
- @2divPosted almost 3 years ago
Thank you both you @Deniel & @Raymart , your comment and feedback was very very helpful.
@Raymart thank for your deep explaining it was really helped me a lot since im in the beginning in this field.
I have revised my code and design and applied what learned from both you.
I am really amazed how my code is less and everything is good.
Only one thing on mobile display not okay, the card look too small , i could not find out why ? any idea about it?
1@pikapikamartPosted almost 3 years ago@2div Hey, great that you find it useful^^
I think you just need to adjust the
height
andwidth
of the.card
selector on this. Also, I don't know if you coded it to be smaller but check if you are zoomed in or zoomed out when coding. Looks great by the way:>Marked as helpful1
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