Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New --number-sections behavior from 3.1.12 increments counter in numbering even when .unnumbered class is used #9516

Closed
cderv opened this issue Feb 26, 2024 Discussed in #9513 · 0 comments

Comments

@cderv
Copy link
Contributor

cderv commented Feb 26, 2024

Initially opened as a discussion at #9513

Pandoc 3.1.12 is changing the behavior of MakeSections (03bb426) and now .unnumbered section behaves differently. They are correctly not numbered, but they now increment the section number counter.

# pandoc 3.1.12
> pandoc --number-sections -t html
# One {-}

# Two

# Three {-}

# Four
^Z
<h1 class="unnumbered" id="one">One</h1>
<h1 data-number="2" id="two"><span
class="header-section-number">2</span> Two</h1>
<h1 class="unnumbered" id="three">Three</h1>
<h1 data-number="4" id="four"><span
class="header-section-number">4</span> Four</h1>

Previous behavior with 3.1.11.1 : Header with unnumbered class did not increment the section number and were skipped

# pandoc 3.1.11.1
> pandoc --number-sections -t html
# One {-}

# Two

# Three {-}

# Four
^Z
<h1 class="unnumbered" id="one">One</h1>
<h1 data-number="1" id="two"><span
class="header-section-number">1</span> Two</h1>
<h1 class="unnumbered" id="three">Three</h1>
<h1 data-number="2" id="four"><span
class="header-section-number">2</span> Four</h1>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant