Skip to content

feat: tap-to-turn-page for comics/PDF; theme the EPUB chrome to the reading theme - #64

Merged
schmitzkr merged 1 commit into
mainfrom
worktree-page-reader-tap-nav
Sep 8, 2026
Merged

schmitzkr merged 1 commit into
mainfrom
worktree-page-reader-tap-nav

Conversation

@schmitzkr

Copy link
Copy Markdown
Owner

Two related reader-UX fixes:

Tap-to-turn-page for comics/PDF

PageReaderScreen (comics/PDF) only had swipe navigation and a tap
anywhere to toggle the chrome. Brought it in line with the EPUB reader's
own gesture handling (reader.js's x<0.3/x>0.7/else split): the outer
30% on each side turns the page (left back, right forward), the middle
third toggles the chrome. Disabled while zoomed in, same as the pager's
own swipe-disabled-while-zoomed behavior.

ZoomableBox's onTap callback now reports the horizontal fraction a
tap landed at instead of a bare signal, since it's the only caller and
this is what a reader needs to distinguish edge taps from a middle tap.

Theme the EPUB chrome to the actual reading theme

The EPUB reader's top/bottom bars and progress slider were following the
app's global light/dark setting — completely independent of which
reading theme (light/sepia/dark/black/forest) is actually selected. A
light-colored bar sitting on a black page reads as broken, which is what
prompted: "the progress control looks weird when page is black theme."

The chrome now derives its own light/dark Material color scheme from the
selected reading theme instead (keeping the app's own accent color), so
the bar and slider always sit on a scheme that actually matches the page
behind them.

Dark mode itself for EPUB already existed (light/sepia/dark/black/forest
swatches in the Display sheet) — this just fixes the chrome not matching
it, not the theming feature itself.

🤖 Generated with Claude Code

…eading theme

Comics/PDF now match the EPUB reader's own left/right tap-to-turn-page
gesture: ZoomableBox reports the fraction across the width a tap landed
at instead of a bare signal, and the reader treats the outer 30 percent
on each side as previous/next (left back, right forward, same split
reader.js already uses), the middle third as the chrome toggle. Disabled
while zoomed in, matching the pager's own swipe-disabled-while-zoomed
behavior.

Separately, the EPUB reader's own top/bottom bars and progress slider
were following the app's global light/dark setting, completely
independent of which reading theme (light/sepia/dark/black/forest) is
actually selected -- a light bar sitting on a black page reads as
broken, which is what prompted this: 'the progress control looks weird
when page is black theme.' The chrome now derives its own light/dark
Material scheme from the selected reading theme instead (keeping the
app's own accent color), so the bar and slider always sit on a scheme
that actually matches the page behind them.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01M421Z8byhEsWKMq7eWWqDN
@schmitzkr
schmitzkr merged commit 3696099 into main Sep 8, 2026
4 checks passed
@schmitzkr
schmitzkr deleted the worktree-page-reader-tap-nav branch September 8, 2026 00:21
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.

1 participant