Skip to content

change CSS rule from body to html in header/footer example#41

Merged
gulien merged 1 commit intogotenberg:mainfrom
aa-ndrej:patch-1
Mar 4, 2026
Merged

change CSS rule from body to html in header/footer example#41
gulien merged 1 commit intogotenberg:mainfrom
aa-ndrej:patch-1

Conversation

@aa-ndrej
Copy link
Copy Markdown
Contributor

@aa-ndrej aa-ndrej commented Mar 4, 2026

Hey 👋🏼

As I just commented here: gotenberg/gotenberg#70 (comment)

I found that the root cause of the tiny text in the header and footer parts of a generated PDF is that Chromium does not set a font-size on the html tag (it appears to default to 1px).

So if we instead set the example styles in the docs on the html tag instead, units like rem also work as in the main content part of the PDF. 🙏🏼

@aa-ndrej aa-ndrej changed the title change CSS rule from body to html in header/footer change CSS rule from body to html in header/footer example Mar 4, 2026
@gulien
Copy link
Copy Markdown
Contributor

gulien commented Mar 4, 2026

Thanks for taking the time for updating the documentation 🙏

@gulien gulien merged commit 50ed177 into gotenberg:main Mar 4, 2026
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

Successfully merging this pull request may close these issues.

2 participants