It's crazy to me that CSS has these built in properties like the caret property, yet its not possible to change the style of an ul bullet point🤔 CSS is weird!
Aanand is a full-stack web developer experienced with JS, Python, Kotlin, Java, and Rust. He is interested in the interpretability and deployment of machine learning systems.
The color of the list marker will be whatever the computed color of the element is (set via the color property)
So there's no intuitive "list-style-color" property that would allow a different colored bullet to the font color, the common workaround has been to use spans inside list items and styling the spans with a different color value.
Mozilla have recently introduced a ::marker pseudo-element to allow this more easily, but support outside of Firefox isn't there yet. One to keep an eye on.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
It's crazy to me that CSS has these built in properties like the caret property, yet its not possible to change the style of an ul bullet point🤔 CSS is weird!
Great article!
You can apply bullet styles or images even: w3schools.com/cssref/pr_list-style...
I believe it does, list-style-type does the trick if I remember correctly.
Hey all, thanks for the tips! I actually already use pseudo elements in my CSS to style my lists!
I was instead just commenting about the qwerks of CSS, it's an interesting language to say the least.
CSS is ... interesting
It tries to be a lot of things and is not particularly good at most of them
This made me laugh a little too hard because it's so true. Thanks for that!
You can still customize it using list images
Don't forget about CSS Counters!
developer.mozilla.org/en-US/docs/W...
A while ago I’ve learned about list-style, is this what you’re looking for? 🌟
css-tricks.com/almanac/properties/...
So there's no intuitive "list-style-color" property that would allow a different colored bullet to the font color, the common workaround has been to use spans inside list items and styling the spans with a different color value.
Mozilla have recently introduced a ::marker pseudo-element to allow this more easily, but support outside of Firefox isn't there yet. One to keep an eye on.