diff --git a/app/d/[slug]/CommentsShell.tsx b/app/d/[slug]/CommentsShell.tsx index 56dde5f..0001521 100644 --- a/app/d/[slug]/CommentsShell.tsx +++ b/app/d/[slug]/CommentsShell.tsx @@ -93,6 +93,9 @@ type Props = { // Ordered heading list + stable fragment ids for section deeplinks (from // lib/docs/sections extractSections). Forwarded to the overlay as jh:sections. initialSections: Section[]; + // Estimated minutes to read the doc (lib/docs/reading-time). 0 = no prose to + // read, and the bar leaves the slot out entirely. + readMinutes: number; version: number; // Coarse SSR theme (from the stored HTML's unconditional html/body bg). Present // only when the server is confident the doc is dark — gives the shell a dark @@ -167,6 +170,7 @@ export default function CommentsShell(props: Props) { docId, me, initialSections, + readMinutes, } = props; const [bookmarked, setBookmarked] = useState(props.bookmarked); const bookmarkPending = useRef(false); @@ -924,6 +928,11 @@ export default function CommentsShell(props: Props) { {title} + {readMinutes > 0 ? ( + + {readMinutes} min read + + ) : null} {signedIn ? (