diff --git a/components/updates/update-viewer.tsx b/components/updates/update-viewer.tsx new file mode 100644 index 0000000..cc9f2f0 --- /dev/null +++ b/components/updates/update-viewer.tsx @@ -0,0 +1,53 @@ +"use client" + +import { ReadingProgressBar } from "./reading-progress-bar" +import { ChapterNav } from "./chapter-nav" +import type { UpdateContent } from "@/lib/updates" + +export function UpdateViewer({ + update, +}: { + update: UpdateContent +}) { + const formattedDate = new Date(update.meta.date).toLocaleDateString("en-US", { + year: "numeric", + month: "long", + day: "numeric", + }) + + return ( + <> + +
+ {/* Main content */} +
+
+
+ + v{update.meta.version} + + +
+

{update.meta.title}

+
+
+
+ + {/* Chapter navigation sidebar (desktop) */} + +
+ + {/* Mobile chapter nav (rendered inside viewer for context) */} +
+ +
+ + ) +}