I am currently working on a template that has some template content after the users content. This leads to the max page number to be “wrong” in the content section when using “1 / 1” or similar as numbering format.
// content
#set page(numbering: "1 / 1")
#counter(page).update(1)
#lorem(9999)
// appendix
#set page(numbering: "i")
#counter(page).update(1)
#lorem(999)
This is a minimal version showing this problem: lorem(999) produces two pages, leading to the footer in the content section showing “x / 2”, even though the content section has 15 pages.
The easy solution would probably to use a label selector to find the last page of the content section and built the “1 / 1” numbering with a custom function. This is not viable in my situation, as the numbering should be customizable by the user. The user should be able to set the numbering to their liking with a single parameter (numbering-content).
How do I fix the wrong max page in “1 / 1” numbering styles, without receiving additional information from a template user?
The user should be able to set numbering-content to “1 / 1”, “I”, or whatever they want.