Design comparison
Solution retrospective
I am mostly proud of the final look of the card and managing the flexbox for the first time.
What challenges did you encounter, and how did you overcome them?I encountered many challenges designing the card, one of them was paying attention to where to use flexbox, and managing margins to match the overall look of the original design.
What specific areas of your project would you like help with?How to handle elements one at a time.
Community feedback
- @josifermaodevPosted 4 months ago
Congratulations, your code is very good, in my opinion there is nothing to improve! But answering your question about how to deal with elements one at a time. This would be my view:
1 - Using IDs: IDs are unique to each element on a page, allowing you to select and style a specific element.
<div id="elemento1">Element 1</div> <div id="elemento2">Element 2</div> #element1 { color: red; } #element2 { color: blue; }
2 - Using Classes: Classes can be used on multiple elements, but you can combine classes and other selectors to style specific elements.
<div class="element element1">Element 1</div> <div class="element element2">Element 2</div> .element1 { color: red; } .element2 { color: blue; }
3 - Using Pseudo-classes: Pseudo-classes like
:nth-child
,:first-child
,:last-child
, etc., allow you to select elements based on their position within a container.<div class="container"> <div>Element 1</div> <div>Element 2</div> <div>Element 3</div> </div> .container div:nth-child(1) { color: red; } .container div:nth-child(2) { color: blue; } .container div:nth-child(3) { color: green; }
I hope this can help you!
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