Archived topic
Style Numbered List
5 replies · Started by Matias on September 21, 2021
Hello all.
I have some numbered list that I want to give some style.
How Can I add some margin-right and border-right to numbers from custon css?
All code that I have found doesnt work properly.
Thanks
Hi there,
there is very limited control over the styling of the automatic numbers from a list, particularly adding borders.
Do you have an example / mockup of how you want it to look and we can see whats possible.
I would like to do something like the link that I have add in private information area.
thank
Try adding this CSS:
.entry-content ol {
list-style: none;
margin-left: 0;
padding-left: 35px;
position: relative;
counter-reset: section;
}
.entry-content ol li:before {
content: "";
counter-increment: section;
content: counter(section);
padding-right: 10px;
border-right: 1px solid #ff0000;
position: absolute;
left: 0;
}
Great.
Works fine. Thank David
Glad to be of help!