Special list-item counter starts from an incorrect number for ::before and ::after
Reported by
kizm...@gmail.com,
Dec 21 2017
|
|||
Issue descriptionUserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/61.0.3163.100 YaBrowser/17.10.0.2052 Yowser/2.5 Safari/537.36 Steps to reproduce the problem: 1. Go to https://codepen.io/kizu/pen/QaKjmJ 2. Look at the custom counters Or 1. Create an ordered list, optionally with a `start` attribute. 2. Add custom styles for the list items by using `counter(list-item)`. What is the expected behavior? This counter should start from either the `1` or from the number set by `start` attribute. What went wrong? The number the counters start from are wrong by one. However, when the `value` attribute is used, the value is correct. Did this work before? N/A Does this work in other browsers? N/A Chrome version: 61.0.3163.100 Channel: n/a OS Version: OS X 10.13.1 Flash Version: Edge browser renders everything in a correct way. There is a hacky fix/workaround for this issue: ol.fix:not(*:root) > li:first-child:not([value]) { counter-increment: list-item 0; }
,
Dec 28 2017
Not a recent regression.
,
Jan 2 2018
Redirecting to Layout as most of the counters logic is there (especially the numbering logic).
,
Oct 26
Just wanted to mention that this was fixed in webkit, and already landed in Safari: https://bugs.webkit.org/show_bug.cgi?id=181084, so probably the fix could be ported. |
|||
►
Sign in to add a comment |
|||
Comment 1 by lgrey@chromium.org
, Dec 21 2017