From 6917cc840787f5b131b766b10fce738c5c051982 Mon Sep 17 00:00:00 2001 From: ilia Date: Tue, 4 Aug 2026 21:48:43 -0400 Subject: [PATCH] Docs: Sprint A UX (match-all, slim payloads, deploy-viewer). --- ROADMAP.md | 9 +++++++++ e2e/README.md | 2 +- scripts/README.md | 16 ++++++++++++++++ 3 files changed, 26 insertions(+), 1 deletion(-) diff --git a/ROADMAP.md b/ROADMAP.md index 506738b..b93d686 100644 --- a/ROADMAP.md +++ b/ROADMAP.md @@ -33,6 +33,7 @@ Living plan for product quality, auth/email reliability, and automation. - [x] **Person contact fields** — optional email/phone on identify (viewer + admin), pending approve UI, Modify person - [x] **Approve Identified bulk select** — Select All Approve/Deny + Approve Next 10 - [x] **Admin pending-queue digest email** — `ADMIN_NOTIFY_EMAIL` via `noreply@levkine.ca` SMTP (throttled) +- [x] **UX Sprint A — match-all filters, slim search payloads, DEV `next start`** — see [UX sprint](#ux-sprint--trust-mobile-admin-throughput-2026-08) ## Next (near-term) @@ -65,6 +66,14 @@ Living plan for product quality, auth/email reliability, and automation. - [ ] **Burn-in / deploy-smoke CLI** (playkit ROADMAP v0.4/v0.5+) — playkit's own ROADMAP has an explicit "adoption pause" until the `v0.3.1` network helpers + release job soak for a few days in this repo's CI; revisit once that settles rather than adding more moving parts at once. +### UX sprint — trust, mobile, admin throughput (2026-08) + +#### Sprint A — quick trust + speed (shipped) + +- [x] **Match-all people/tags filters** — `/api/search` raw SQL uses `GROUP BY` + `HAVING COUNT(DISTINCT …)` when `peopleMode=all` / `tagsMode=all` (`lib/search-filter-sql.ts` + Vitest) +- [x] **Slim gallery face payloads** — home SSR + search API return id, photo_id, person_id, location, person names only +- [x] **DEV viewer `next start`** — `scripts/deploy-viewer.sh`; `ecosystem.config.js.example` uses `next start -p 3001` + ## Later - [x] Proper DEV deploy (`next start` + CI image) instead of long-lived `next dev` — `scripts/deploy-viewer.sh`, `ecosystem.config.js.example` uses `next start -p 3001` diff --git a/e2e/README.md b/e2e/README.md index 9e888d2..94aedf3 100644 --- a/e2e/README.md +++ b/e2e/README.md @@ -56,7 +56,7 @@ not enabled in this CI job yet. 10. API catalog: people/tags lists, login 422/401, users/roles 401, missing photo 404|401 11. Viewer `/api/auth/session` returns email when storageState is loaded 12. FastAPI role-permission write gates: viewer 403 vs admin 200 on users, role-permissions, bulk-delete -13. Public gallery search (`/api/search`): tag filter, person filter, and combined-filter narrowing return correct subsets; UI tag-filter interaction updates URL + result count +13. Public gallery search (`/api/search`): tag filter, person filter, **match-all** (`peopleMode=all` / `tagsMode=all`) combined narrowing, and UI tag-filter interaction updates URL + result count 14. Logged-in-only filters: Favorites checkbox toggles `favoritesOnly` URL param; People filter UI selection updates URL + result count (uses storageState) 15. Silent-failure network monitor (`startNetworkErrorMonitor`): gallery home, search+filter, upload, and Manage Users overlay all stay free of background 4xx/5xx while the UI loads/interacts 16. `interceptNetworkCall` spies on the real upload POST (status + `{ message, photos }` shape) and the filtered `/api/search?tags=` GET (status + Zod-validated shape) instead of brittle `waitForResponse`/text scraping diff --git a/scripts/README.md b/scripts/README.md index 3c41676..c791ea4 100644 --- a/scripts/README.md +++ b/scripts/README.md @@ -41,6 +41,22 @@ Project-specific scripts remain in the repository root: - `stop_backend.sh` - Stop backend server - `run_worker.sh` - Run RQ worker - `demo.sh` - Demo helper script +- `deploy-viewer.sh` - Build viewer (`next build`) and recreate PM2 `punimtag-viewer` with `next start` (use after viewer deploys; `pm2 restart` alone does not pick up script-arg changes) + +### Viewer deploy (DEV / prod-like) + +```bash +cd /opt/punimtag +git pull +bash scripts/deploy-viewer.sh --skip-install # when node_modules already current +``` + +Admin static build (served by Caddy or `pm2 serve`): + +```bash +cd /opt/punimtag/admin-frontend && npm run build +# restart API if backend changed: pm2 restart punimtag-api +``` ## Database Shell Scripts