Commit graph

15 commits

Author SHA1 Message Date
8295894b32 Show add-page indicator as a bar and palm-check its taps
The add-page ghost is now a thin bar along the active page's free edge
instead of a full page-sized block. Pointer taps on it go through the
stage gesture handling, so touches are evaluated by the palm rejector
with the same 'draw' policy as writing, including being cut off if the
pen shows up mid-tap. The native click only handles keyboard activation.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-27 17:54:29 +00:00
138b797506 Size the canvas grid to the active page
Each grid cell is now the active page's size, aligned to its edges, so
the grid marks where neighbouring pages would sit. Falls back to A4 at
the origin when no page is active.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-27 17:34:28 +00:00
4acb3a614c Replace page glow with a flat outline and add a canvas grid
Pages now get a crisp 1 screen-px outline instead of a blurred shadow,
and the canvas background shows faint world-anchored grid lines that
pan and zoom with the pages (spacing steps up ×4 when zoomed out).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-27 17:27:39 +00:00
964b3b1cdd Merge pull request 'Fix PDFs still failing on browsers that used the old build' (#5) from sw-bypass-http-cache into main
Reviewed-on: https://git.srazka.com/reudy-net/Papure/pulls/5
2026-09-27 12:18:03 +02:00
01624c6efa Bypass the HTTP cache when the service worker caches assets
Hashed assets are served as immutable for a year. Before the nginx MIME
fix, the pdf.js worker was served as application/octet-stream, and the
browser kept that response. Each new service worker then copied it from
the HTTP cache into its offline cache, so PDFs still failed to render
after the server was fixed. Fetching with cache: 'reload' always takes
the current response from the server.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VsorPV3JeJRoZ1mD1pdvtL
2026-09-27 10:17:21 +00:00
cb4d3bfc79 Merge pull request 'Place pages edge to edge with no gap' (#4) from zero-gap into main
Reviewed-on: https://git.srazka.com/reudy-net/Papure/pulls/4
2026-09-27 12:01:00 +02:00
df1f3c27f7 Merge pull request 'Fix imported PDFs not rendering in the Docker image' (#3) from fix-pdf-worker into main
Reviewed-on: https://git.srazka.com/reudy-net/Papure/pulls/3
2026-09-27 12:00:37 +02:00
308d6fc846 Place pages edge to edge with no gap
Neighbouring pages now touch, so the tree reads like a grid. Rows with
pages of different sizes are still centred, so it isn't a strict grid.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VsorPV3JeJRoZ1mD1pdvtL
2026-09-27 09:58:43 +00:00
5d5d86c533 Fix imported PDFs not rendering in the Docker image
nginx has no MIME type for .mjs, so the pdf.js worker was served as
application/octet-stream and browsers refused to load it. Every imported
PDF page then showed "Source PDF ... is not available", which looked like
missing files. Serve .mjs as text/javascript.

The page background now also tells the two failures apart: "not stored on
this device" when the source bytes are missing, and "could not display"
(with the error logged) when pdf.js fails.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VsorPV3JeJRoZ1mD1pdvtL
2026-09-27 09:37:15 +00:00
24ebbd9056 Merge pull request 'Add Dockerfile and compose setup for self-hosting' (#2) from docker into main
Reviewed-on: https://git.srazka.com/reudy-net/Papure/pulls/2
Reviewed-by: reudy <jakubadorfman@proton.me>
2026-09-27 00:35:21 +02:00
23d0c29e0b Add Dockerfile and compose setup for self-hosting
Multi-stage build: Node builds the static PWA, nginx serves it with an SPA
fallback, long-lived caching for hashed assets, no-cache for the app shell
and service worker, and the correct type for the web manifest.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VsorPV3JeJRoZ1mD1pdvtL
2026-09-26 22:33:08 +00:00
08a530c78f Merge pull request 'Keep finger pan/zoom working after using the pen' (#1) from agent/fix-finger-navigation into main
Reviewed-on: https://git.srazka.com/reudy-net/Papure/pulls/1
2026-09-26 23:40:46 +02:00
besbara
bca1a6a407 Keep finger pan/zoom working after using the pen
After writing with the pen, fingers could no longer navigate:
- every touch was ignored for 5 s after any pen activity (and for as long
  as a hover-capable pen stayed near the screen),
- after that, a one-finger drag on a page drew ink instead of panning,
- a one-finger drag on the background did nothing while an ink tool was on.

Once a pen has been used, fingers now only pan and zoom. The 5 s session
and hover lockouts only block finger ink; touches are still rejected while
the pen is down, for palm-sized contacts and within 150 ms of pen activity.
A finger drag off the page always pans.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VsorPV3JeJRoZ1mD1pdvtL
2026-09-26 20:09:53 +00:00
besbara
fa2f491161 New pages inherit the size of the page they are created from
Blank pages added next to an existing page (via the "+" tile, Alt+Arrow
or the page menu) now copy that page's width and height, including
imported PDF pages, instead of always falling back to A4. The "+" preview
tile uses the same size so it matches the page it will create.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VsorPV3JeJRoZ1mD1pdvtL
2026-09-26 19:55:24 +00:00
0ad405c26e Init 2026-09-26 19:13:02 +02:00