Add bulk (multi-photo) upload to the web form

The /upload page now takes several photos at once, mirroring the Android and Qt
apps: a card per photo with its own preview, EXIF-prefilled date, caption and
tag-autocompleting tags field, a remove button, and per-photo status. "Post
photos" uploads them sequentially with an x/N progress line; failures can be
retried by pressing Post again, successes link straight to the new photo page.

No server change — each photo is still a separate POST /upload, exactly as the
apps' per-photo queue does it, so slugs come from filenames as before.
This commit is contained in:
puttaalu committed 2026-10-18 23:29:04 +02:00
1 parent 225bdc9b4f
commit c21ddc5b7e
3 files changed
+198 -216

No files matched your search

+3 -1
View File
@@ -19,7 +19,9 @@ The binary does three things at once:
- Serves a multipart upload API at `POST /upload`
- In dev mode (`--serve`), also serves `public/` as static files
Routes: `GET /upload` (HTML upload form), `POST /upload` (multipart),
Routes: `GET /upload` (HTML upload form — multi-photo: the page posts one
`POST /upload` per selected photo, each with its own caption/date/tags),
`POST /upload` (multipart, one image per request),
`GET /manage` (edit/delete UI), the manage API under `/api/` (see Manage),
`GET /health`. Every route except `/health` is gated by HTTP Basic auth when
`-htpasswd` is set (see Auth).