Reading Books
Current PDF and EPUB reader behavior
Alex includes browser readers for PDF and EPUB books. Private and shared collections use the same reader components, with different progress storage.
PDF reader
PDFs open as one continuous vertical document. Alex renders all pages with PDF.js and tracks the page occupying the largest part of the reading viewport.
Navigation
- Scroll naturally through the document.
- Use the previous/next buttons to jump one page at a time.
- Enter a page number in the toolbar to jump directly.
- Press Left/Right Arrow for the previous/next page.
- Press Home or End for the first or last page.
Zoom and fit
- Alex automatically fits pages to the available width until you change zoom.
- Zoom uses 25% steps from 50% through 200%.
- Press
+or-for keyboard zoom. - The Fit button returns the page width to the reader viewport.
Zoom and search controls are hidden in the toolbar on very small screens, while scrolling and page navigation remain available.
Document search
Press Ctrl+F or Cmd+F to open Alex's search panel. Alex extracts text from every PDF page, counts matches across the document, highlights them, and jumps between results. Enter moves to the next result and Escape closes the panel.
EPUB reader
EPUBs use a web-native, single-column layout rather than simulated paper pages. Chapters flow vertically with no side-by-side spreads.
Layout and typography
- Continuous vertical scrolling
- Content constrained to an
80chmaximum reading width - IBM Plex Serif with a light text weight and 1.6 line height
- Four saved font sizes: S (18px), M (24px), L (32px), and XL (40px)
- Images, tables, code blocks, and other wide content constrained to the column
The EPUB automatically follows Alex's current light or dark application theme. There are no separate Light/Dark/Sepia presets inside the reader. Changing the app theme updates content already rendered inside the EPUB iframe.
Chapters
- Open the table of contents to jump to a chapter.
- Use the previous/next chapter buttons in the toolbar.
- The current chapter is highlighted when its EPUB navigation entry can be matched.
EPUB navigation is chapter-based; the left/right page-edge controls and swipe page turning used by older paged layouts are not part of the current continuous reader.
Position restoration
Alex records an EPUB CFI and a calculated percentage. It also caches a scroll fraction and viewport dimensions in the browser. When you reopen the book at the same viewport size, Alex can use that extra data to restore a more precise vertical position after fonts and images settle.
Progress tracking
For signed-in users, both readers save progress to SQLite through the Alex API:
- PDF: current page, total pages, percentage, status, and last-read time
- EPUB: CFI, percentage, status, and last-read time
A position below the end is marked reading; the final PDF page or 100% EPUB position is marked completed. The Now Reading shelf and book-card progress meter use this per-user data.
Public shared readers never create an anonymous server account. Their progress is stored only in that browser under a key scoped to the share token and book, so it does not sync to another browser or device.