fix(pdf-viewer): use static worker + lazy page rendering

Worker copied to public/ via prebuild script (avoids Vite resolution issues).
IntersectionObserver renders only visible pages (+200px ahead) instead of all
at once, fixing performance for large PDFs.
This commit is contained in:
Hibryda 2026-03-11 01:27:54 +01:00
parent 199873781b
commit a74d3a74d3
3 changed files with 97 additions and 50 deletions

1
v2/.gitignore vendored
View file

@ -9,6 +9,7 @@ lerna-debug.log*
node_modules
dist
public/pdf.worker.min.mjs
dist-ssr
*.local
sidecar/dist