From 5dceeb5860181d1df9183e3730e4f33de275427a Mon Sep 17 00:00:00 2001 From: Zaldimmar Date: Tue, 29 Sep 2026 15:34:43 -0500 Subject: [PATCH] Let a blog post be downloaded as a PDF Download PDF beside the byline opens the browser's print dialog (Save as PDF) with a print layout: the site's header, footer and notices hidden, the contents column dropped, the light palette whatever the screen shows, and at the bottom the post's link and a QR code of it. Co-Authored-By: Claude Opus 5.5 --- src/components/Layout.tsx | 6 +++--- src/components/PostContents.tsx | 4 ++-- src/index.css | 31 +++++++++++++++++++++++++++++++ src/pages/BlogPost.tsx | 27 +++++++++++++++++++++++++-- 4 files changed, 61 insertions(+), 7 deletions(-) diff --git a/src/components/Layout.tsx b/src/components/Layout.tsx index 0cff43e..cc32c18 100644 --- a/src/components/Layout.tsx +++ b/src/components/Layout.tsx @@ -175,7 +175,7 @@ export default function Layout() { {/* ── NAV ─────────────────────────────────────────────── */}
@@ -273,7 +273,7 @@ export default function Layout() {
{/* Keeps page content clear of the fixed header */} -
+
{/* Page content */}
@@ -283,7 +283,7 @@ export default function Layout() {
{/*Site Footer applied to every page*/} -
+
diff --git a/src/components/PostContents.tsx b/src/components/PostContents.tsx index 0ad8f4d..71ef0af 100644 --- a/src/components/PostContents.tsx +++ b/src/components/PostContents.tsx @@ -74,7 +74,7 @@ export default function PostContents({ entries }: { entries: ContentsEntry[] }) const lit = useLit(entries) return ( <> -
+
On this page
@@ -82,7 +82,7 @@ export default function PostContents({ entries }: { entries: ContentsEntry[] })