How to set a prefix to the pagination? #485
Answered
by
yhatt
freenandes
asked this question in
Q&A
-
Right now it renders "X", the page number. How do i customize the template to set "Page X of 20", or "X-20", or "X of 20 pages", and similar variations? |
Beta Was this translation helpful? Give feedback.
Answered by
yhatt
Nov 17, 2023
Replies: 1 comment 1 reply
-
👉 https://marpit.marp.app/theme-css?id=customize-content <style>
section::after {
/* Add "Page" prefix, and total page number */
content: 'Page ' attr(data-marpit-pagination) ' of ' attr(data-marpit-pagination-total);
}
</style> Variants:
|
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
freenandes
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
👉 https://marpit.marp.app/theme-css?id=customize-content
Variants:
X-20
:content: attr(data-marpit-pagination) '-' attr(data-marpit-pagination-total);
X of 20 pages
:content: attr(data-marpit-pagination) ' of ' attr(data-marpit-pagination-total) ' pages';