fix: make the reader's typography, width and arrow keys work

Typography was in the stylesheet foliate prepends, which the book overrides;
moved to the appended one. The window keydown handler was never bound.

Also: wider reading area, page on a card, arrows moved onto it, spread gutter,
and the sidebar stays open on chapter clicks.
This commit is contained in:
2026-08-11 22:45:14 -04:00
parent 6318115380
commit 9155129ccd
5 changed files with 135 additions and 62 deletions
+5 -2
View File
@@ -12,7 +12,10 @@ export const DEFAULT_READER_SETTINGS: ReaderSettings = {
letterSpacing: 0,
margin: 48,
gap: 6,
maxInlineSize: 720,
// foliate caps the reading area at this times the column count, so 1000 gives
// a 2000px spread — enough to fill a large display rather than leaving the
// book as a narrow strip. Its own default of 720 is noticeably tight.
maxInlineSize: 1000,
maxColumnCount: 2,
flow: 'paginated',
justify: true,
@@ -30,7 +33,7 @@ export const READER_BOUNDS = {
letterSpacing: { min: -0.05, max: 0.2, step: 0.01 },
margin: { min: 0, max: 120, step: 4 },
gap: { min: 0, max: 15, step: 1 },
maxInlineSize: { min: 480, max: 1400, step: 20 }
maxInlineSize: { min: 400, max: 2400, step: 20 }
} as const;
/**