搭配 CSS 內 content 自訂項目符號

ol { counter-reset: my-badass-counter; }
ol > li { list-style: none; position:relative; padding-left: 45px; }
ol > li:before {
content: “(“ counter(my-badass-counter, cjk-ideographic) “)”;
counter-increment: my-badass-counter;
display: block; position: absolute; left: 2px;
}

參考 https://css-tricks.com/numbering-in-style/

發佈留言