Design comparison
Solution retrospective
I am most proud of the progress I have made in HTML and CSS.
What challenges did you encounter, and how did you overcome them?This challenge at first glance seems simple, but I found myself faced with the challenge of giving styles to the lists, specifically giving color only to the bullets and the numbered list. Investigating the CSS for the lists I only have the following properties:
- list-style
- list-style-image
- list-style-position -list-style-type
None of these properties serve to give it color.
To solve the challenge use the ::before pseudo-element. Here is an example:
.section__options {
position: relative;
list-style: none;
padding-left: 3rem;
line-height: 2;
}
.item::before {
content:"" ;
width: 5px;
height: 5px;
border-radius: 50%;
background-color: var(--color-preparation);
position: absolute;
left: 0;
transform: translateY(15px)
}
What specific areas of your project would you like help with?
I think that by using the ::before pseudo-element I found the solution to the challenge with lists. I would like to know if there is another way to solve it.
Community feedback
- @mbalali63Posted 8 months ago
Hi Roraima Your work is very good. it looks very similar to the target design. And about styling list bullets, I think it may simplify if you use marker. here you can find details.
Marked as helpful0@roraima1986Posted 8 months ago@mbalali63 Thank you very much for your help.
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