Has the Firefox desktop v84 update broken the CSS counter-reset: functionality? Chrome and Edge render ok but not Firefox Can anybody confirm?
Below is a sample of the code that I'm using:
body
{
counter-reset: section subsection;
}
p.section
{
counter-reset: subsection;
}
p.section:before
{
counter-increment: section;
content: "" counter(section) ".0" ": ";
counter-reset: subsection;
}
p.subsection:before
{
counter-increment: subsection;
content: "" counter(section) "." counter(subsection) ": ";
}
<p class="section">Paragraph should be 1.0</p>
<p class="section">Paragraph should be 2.0</p>
<p class="subsection">Paragraph should be 2.1</p>
<p class="subsection">Paragraph should be 2.2</p>
<p class="section">Paragraph should be 3.0</p>
<p class="section">Paragraph should be 4.0</p>
<p class="subsection">Paragraph should be 4.1</p>
Can you please check the below code? Hope it will work for you. No need to reset the subsection in the
body, because we need to reset the counter after everysection. so we have kept the counter reset subsection in thesectionas it is.Please refer to this link https://jsfiddle.net/yudizsolutions/baqnzf39/6/