Design comparison
Solution retrospective
-
Better understanding different HTML elements.
-
Studing the aside tag, found that it is used as a call-out box Aside definition from web.dev.
-
Always thought that tables were old school, but I understand now that tables are suitable for displaying tabular data in a structured and understandable manner, as it is in the Nutrition section.
-
Learnt how to change color of the bullet markers.
-
Learnt this CSS property
list-style-position: inside;
to deal with inline bullet lists. Not the case in this project. -
Explored how bullet lists are rendered from ul and ol tags. See this content Custom bullets with CSS ::marker.
-
I wouldn't add a container encapsulating header, main and footer. I don't like this, but since we have backgrounds all over the project and we have to add margins, paddings and stuff to the global layout. To solve this, I added a pseudo-element ::before to the body, so now I have two backgrounds placed correctly.
-
Changing the default behaviour of li from
display: list-item
todisplay: flex
will cause the loss of appearance of markers. You will have to manage it manually. -
To get better responsiveness and attend to the design, the li tags must be
display: flex;
andalign-items: center
.
Not sure. If you find anything please feel free to help. Thank you for your help!
Community feedback
- @mikov144Posted 4 months ago
Hi! Great work! I don't have too much to add, but I noticed that in some places you have 2 spaces before the line, and in some it's 4. Wouldn't it be better to keep everything on 2 spaces, so the code is not going to get so stretched? Then again, good job!
Marked as helpful1@flaviocmbPosted 4 months ago@mikov144 The way I think is that the article will equally separate each section. Therefore, 4 sections with equal spaces. The gap property was used to accomplish this task.
As for the other 2 spaces, I believe that the line dividing the two sections could be done using a div block, and that would work just fine. However, I chose to create a state (in CSS architecture) for a line with reuse in mind. If I add more sections, the article remains responsible for separating the spaces, and the state created for the line just adds spaces in addition to the section's.
Well observed, @mikov144. Thank you!
0
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