feat: internal PDF viewer with consistent UI (#40) #49

Closed
mik-tf wants to merge 0 commits from development_issue_40 into development
Owner

Summary

Add an in-app PDF viewer that keeps the standard navbar, breadcrumbs, and theme — instead of opening raw PDFs in a new browser tab.

Changes

  • New template pdf_viewer.html extending base.html with iframe-based PDF display
  • New function render_pdf_viewer() with PdfViewerTemplate Askama struct
  • New routes /book/{name}/pdf/viewer and /book/{name}/page/{page}/pdf/viewer
  • Updated templates book.html, books.html, library.html, page.html — all View PDF links now use the internal viewer
  • Viewer toolbar: breadcrumb navigation, Back, Download, New Tab buttons

Testing

  • All clippy checks pass
  • All 136 unit tests pass
  • Manually tested on all pages: library list, book detail, page view, All Books

Closes #40

## Summary Add an in-app PDF viewer that keeps the standard navbar, breadcrumbs, and theme — instead of opening raw PDFs in a new browser tab. ## Changes - **New template** `pdf_viewer.html` extending `base.html` with iframe-based PDF display - **New function** `render_pdf_viewer()` with `PdfViewerTemplate` Askama struct - **New routes** `/book/{name}/pdf/viewer` and `/book/{name}/page/{page}/pdf/viewer` - **Updated templates** `book.html`, `books.html`, `library.html`, `page.html` — all View PDF links now use the internal viewer - Viewer toolbar: breadcrumb navigation, Back, Download, New Tab buttons ## Testing - All clippy checks pass - All 136 unit tests pass - Manually tested on all pages: library list, book detail, page view, All Books Closes #40
feat: internal PDF viewer with consistent UI (#40)
All checks were successful
Test / test (pull_request) Successful in 3m34s
Test / integration (pull_request) Successful in 6m19s
8610f01684
Add an in-app PDF viewer that uses base.html for uniform navbar,
breadcrumbs, and theme support. All View PDF links across templates
(book, page, books list, library) now open the internal viewer
instead of raw PDF in a new tab.

- Add PdfViewerTemplate struct and render_pdf_viewer function
- Add /pdf/viewer routes for both book-level and page-level PDFs
- Create templates/pdf_viewer.html extending base.html
- Viewer includes breadcrumb navigation, Back, Download, New Tab buttons
- Update all templates to use /pdf/viewer links

Closes #40
Author
Owner

Closing: all changes from this PR are already present in development branch (verified via git merge-base --is-ancestor). Work consolidated into a new PR covering build system alignment and remaining features.

Closing: all changes from this PR are already present in `development` branch (verified via `git merge-base --is-ancestor`). Work consolidated into a new PR covering build system alignment and remaining features.
mik-tf closed this pull request 2026-02-19 01:10:50 +00:00
All checks were successful
Test / test (pull_request) Successful in 3m34s
Test / integration (pull_request) Successful in 6m19s

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
lhumina_code/hero_books!49
No description provided.