From 01cfedddcf2344ea9fe9b55dbbf5bcd3ea4ab078 Mon Sep 17 00:00:00 2001 From: Philipinho <16838612+Philipinho@users.noreply.github.com> Date: Sat, 5 Sep 2026 16:27:40 +0100 Subject: [PATCH] fix pdf-print for public pages --- .../components/docs/docs.module.css | 34 +++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/apps/client/src/features/public-space/components/docs/docs.module.css b/apps/client/src/features/public-space/components/docs/docs.module.css index 6f008a429..d4a4f697d 100644 --- a/apps/client/src/features/public-space/components/docs/docs.module.css +++ b/apps/client/src/features/public-space/components/docs/docs.module.css @@ -900,3 +900,37 @@ display: flex; flex-direction: column; } + +/* ---------- Print ---------- */ + +/* Only the article prints; the body grid collapses so it takes the page width. */ +@media print { + .header, + .sidebar, + .toc, + .articleActions, + .breadcrumbs, + .pageNav, + .footer { + display: none !important; + } + + .root { + --docs-bg: #fff; + --docs-fg: #1f1f1f; + --docs-content-fg: var(--docs-fg); + + min-height: 0; + background-color: #fff; + color: var(--docs-fg); + } + + .body { + display: block; + } + + .article { + max-width: none; + padding: 0; + } +}