Commit Graph
14 Commits
Author SHA1 Message Date
john-okeefe bb5017b99b fix(reader): add unsafe-eval to CSP and improve formatting
- Add 'unsafe-eval' to Content-Security-Policy script-src directive
  to support dynamic module evaluation required by ES modules
- Standardize HTML formatting:
  - Use lowercase doctype declaration
  - Use double quotes consistently
  - Improve indentation for readability
- Format CSS properties (box-shadow, transition) across multiple lines
- Close void elements with / for consistency

The CSP change is necessary for the ES module system to function
correctly in the browser environment.
2026-04-13 20:14:08 -04:00
John Factotum 1e952102bd PDF: rerender when scale changes
The fixed-layout renderer now accepts an object for the return value of
`load()` (on the `book.sections` items). If it's an object, the `src`
is the URL of the section, and `onZoom`, if present, will be called
when the viewport is zoomed. With this you can scale the page yourself
rather than relying on the renderer's own scaling with CSS transform.

Also upgraded to PDF.js 4.6.82. And now internal links are broken...
Don't know how to fix that yet.
2024-09-28 12:12:59 +08:00
John Factotum a63a68eda0 Add PDF support 2023-10-08 21:27:06 +08:00
John Factotum 6f6f6b4969 Remove nonexistent scripts
Should have been removed after 9949000a9e
2023-05-15 14:50:54 +08:00
John Factotum 514cb81fe6 Reader: allow loading files from URL parameter
Fixes #3
2023-03-15 11:00:21 +08:00
John Factotum 2c452719d0 Paginator: add option for maximum number of columns
Also: allow it to be positioned relative to the parent
2023-03-09 23:36:20 +08:00
John Factotum 602c8381c2 Add support for <object>
It's sometimes used for SVGs
2022-10-27 18:11:21 +00:00
John Factotum 21bf6499a4 Reader: add progress slider 2022-10-22 18:29:52 +00:00
John Factotum 3c05d0a957 Reader: add footnote popovers
Lacks a "go to" button, but at least shows something instead of nothing
2022-10-21 18:57:26 +00:00
John Factotum f39d74f932 Reader: add layout option 2022-10-21 09:53:00 +00:00
John Factotum fea239a111 Reader: show cover, title, and author in sidebar 2022-10-20 18:16:44 +00:00
John Factotum 84691787fa Reader: add title and file chooser button 2022-10-20 14:28:42 +00:00
John Factotum 9a2bb558fd Reader: add sidebar and TOC 2022-10-20 12:50:37 +00:00
John Factotum d0cd085a22 Add sample reader 2022-10-19 11:04:43 +00:00