Skip to content

Commit

Permalink
fix: Include page numbers in the TOC when generating PDF. (#993)
Browse files Browse the repository at this point in the history
Add page numbers to the table of contents in the generated PDF.
  • Loading branch information
teythoon authored Jul 10, 2023
1 parent 4971ae2 commit 656a6ba
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions xml2rfc/writers/pdf.py
Original file line number Diff line number Diff line change
Expand Up @@ -215,6 +215,12 @@ def flatten_unicode_spans(self, html):
margin-top: 1em;
}}
}}
#toc nav ul li p a:nth-child(2)::after {{
content: target-counter(attr(href), page);
position: absolute;
right: 0px;
text-indent: 0px;
}}
}}
"""

Expand Down

0 comments on commit 656a6ba

Please sign in to comment.