Skip to content

[#570] Reading mode — full-screen immersive story reader#575

Merged
realproject7 merged 2 commits intomainfrom
task/570-reading-mode
Mar 26, 2026
Merged

[#570] Reading mode — full-screen immersive story reader#575
realproject7 merged 2 commits intomainfrom
task/570-reading-mode

Conversation

@realproject7
Copy link
Copy Markdown
Owner

Summary

  • ReadingMode component: full-screen overlay with paper background, centered 720px content column, clean Lora typography
  • Bottom navigation: Prev / Contents / Next with chapter progress (e.g. "3 / 12")
  • Table of Contents: slide-up overlay listing all chapters, click to navigate (stays in reading mode)
  • Exit: Esc key, X button, or arrow keys for prev/next navigation
  • Body scroll lock while overlay is active
  • ReadingModeWrapper: bridges server/client boundary, manages active state
  • "Reading Mode" button on both genesis story page and chapter detail pages
  • Plot detail page now fetches title+content for all chapters (enables full reading mode navigation without additional API calls)
  • Mobile responsive: thumb-friendly bottom nav bar

Fixes #570

Test plan

  • Click "Reading Mode" on genesis page → full-screen overlay with genesis content
  • Navigate Prev/Next through chapters within reading mode
  • Open ToC, click a chapter → navigates within reading mode
  • Esc key exits reading mode
  • Arrow keys navigate prev/next
  • Mobile: bottom nav is thumb-friendly
  • Build passes (npm run build)

🤖 Generated with Claude Code

- ReadingMode component: full-screen overlay with paper background,
  centered content column (max 720px), clean typography
- Bottom nav: Prev / Contents / Next with chapter progress indicator
- Table of Contents slide-up overlay listing all chapters
- Esc key or X button to exit, arrow keys for prev/next
- Body scroll lock while overlay is active
- ReadingModeWrapper bridges server/client boundary
- "Reading Mode" button on both genesis and chapter pages
- Plot detail page now fetches title+content for all chapters
  (enables full reading mode navigation)
- Mobile responsive with thumb-friendly bottom nav

Fixes #570

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown

vercel Bot commented Mar 26, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
plotlink Ignored Ignored Mar 26, 2026 5:13pm

Request Review

Copy link
Copy Markdown
Collaborator

@project7-interns project7-interns left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

T2b approves. Clean architecture with ReadingModeWrapper bridging server/client boundary. Keyboard navigation (Esc, arrows), body scroll lock with proper cleanup, ToC reuses existing plot data without extra API calls. Bottom nav is thumb-friendly. No issues found.

Copy link
Copy Markdown
Collaborator

@project7-interns project7-interns left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verdict: REQUEST CHANGES

Summary

The reading-mode overlay is close, but chapter navigation does not reset the reader to the top correctly and it also breaks the page-scroll preservation requirement.

Findings

  • [medium] ReadingMode scrolls the browser window on chapter changes instead of the overlay's own scroll container. The reader content lives inside the inner div at src/components/ReadingMode.tsx:101, but goPrev, goNext, and goToChapter all call window.scrollTo(0, 0) at src/components/ReadingMode.tsx:37, src/components/ReadingMode.tsx:44, and src/components/ReadingMode.tsx:51. In practice, navigating chapters after reading partway down leaves the overlay scrolled midway through the new chapter, while also resetting the underlying page scroll position, so exiting reading mode drops the user back at the top instead of preserving their place.
    • File: src/components/ReadingMode.tsx:37
    • Suggestion: keep a ref to the overlay's overflow-y-auto content container and reset that element's scrollTop, rather than calling window.scrollTo.

Decision

Requesting changes because chapter navigation currently breaks the core reading flow and violates the scroll-preservation requirement.

Prev/Next/ToC navigation now scrolls the overlay's overflow-y-auto
container instead of window.scrollTo. Preserves underlying page scroll
position when exiting reading mode.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Copy link
Copy Markdown
Collaborator

@project7-interns project7-interns left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verdict: APPROVE

Summary

The reading-mode overlay now handles chapter transitions correctly. Navigation resets the overlay's own scroll container instead of the page, so the immersive reader flow works and exiting preserves the underlying page position.

Findings

  • No remaining blocking issues found.

Decision

Approving because the reading-mode navigation now behaves correctly and satisfies the prior review finding.

@realproject7 realproject7 merged commit 28e40fd into main Mar 26, 2026
5 checks passed
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.

Reading mode — full-screen immersive story reader

2 participants