Repository navigation
Book details helper and finding free books online - #6
Merged
Merged
Conversation
Book details (About this book → pencil): - Edit title, authors, series, description, publisher, date, ISBN and language. Edits are stored per field with their own timestamps in the book's record in .readlet/, so they sync and merge field by field; the book file is never touched. They're applied in Rust, so every screen sees them. A reset drops all edits on every device. - Choose a cover from a file, or none. The thumbnail goes in this device's .readlet/devices/<id>/covers/ and the cover:// scheme serves it; its palette is kept in the record. - Find details online: searches Open Library (by ISBN when the book has one), lets the reader pick an edition and tick which fields (and the cover) to use. Only blanks start ticked; nothing is saved until Save. Find books online (library search → "Search online for …"): - Searches Project Gutenberg's OPDS catalogue and downloads EPUBs into the books folder through Library::add_books. Books already in the library are marked. Links to DRM-free stores when there's no free edition. All requests go through src-tauri/src/net.rs (ureq with rustls), which follows redirects by hand and only to Open Library, the Internet Archive's cover servers and www.gutenberg.org, and only on an explicit action. img-src allows the same hosts for result thumbnails. README and the Settings hint say what goes online; docs/ONLINE.md records what was built and decided. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The two online features planned in
docs/ONLINE.md, plus editing details by hand.Book details (About this book → pencil)
.readlet/(details,detailsResetAt), merged field by field across devices; the book file is never touched. Applied in Rust (BookEntry::with_edits), so the reader title, read-aloud language, series grouping and export all see them. Synced edits refresh via a newget_books..readlet/devices/<id>/covers/<fp>-<t>.jpg; the record points at it with its palette;cover://serves it. Paths from records are validated, since they sync from other devices.Find books online (library search → "Search online for …")
/ebooks/<id>.epub3.images, checks it's an EPUB, and adds it viaLibrary::add_books(no overwrites, duplicates skipped). Books already in the library are marked.Network
src-tauri/src/net.rs(ureq + rustls, no OpenSSL): redirects followed by hand, allowlist of openlibrary.org, covers.openlibrary.org, archive.org,*.us.archive.org, www.gutenberg.org; size caps; downloads streamed to disk. Requests happen only on an explicit action.img-srcallows the same hosts for result thumbnails. README and the Settings hint now say what goes online.Test plan
bun run check: typecheck, lint, format, 102 testscommands.rs,protocol.rsand wiring couldn't be compiled locally)<input type=file>), find details online, download a Gutenberg book🤖 Generated with Claude Code