Commit graph

1 commit

Author SHA1 Message Date
clawdbot
2245d7e9c6 fix: server-side comic page extraction with caching
Fixes #3505 - Large comic books (300+ MB) were unusable due to
client-side extraction.

Changes:
- Add ComicCacheManager for server-side page extraction and caching
- Add GET /api/items/:id/comic-pages endpoint for page metadata
- Add GET /api/items/:id/comic-page/:page endpoint for individual pages
- Update ComicReader.vue to fetch pages on-demand from server
- Add browser-side preloading for adjacent pages

Before: Client downloads entire comic file, extracts in browser
After: Server extracts pages on-demand, caches to disk, streams to client

Performance improvements:
- Initial load: Only metadata request (~1KB) instead of full file (300MB+)
- Page turns: Single image request (~100KB-2MB) with disk caching
- Memory: No longer loads entire archive in browser memory
- Subsequent views: Cached pages served instantly from disk
2026-02-21 11:28:30 -05:00