From b3a8cbd582dd62c5e546268a8cdf4a93a86402d8 Mon Sep 17 00:00:00 2001 From: John O'Keefe Date: Mon, 2 Nov 2026 14:08:19 -0500 Subject: [PATCH] fix(admin): library row button renamed 'Scan' -> 'Force Rescan', per owner MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Owner ruling that closed the scan-semantics discussion: the code is correct (per-library scan IS a force scan — hx-vals force:true since 706be09d), but the label hid that. Now the naming invariant holds everywhere: anything with Force/Rescan in its name re-reads everything in its scope; plain 'Scan' only exists at folder scope ('Scan this folder', shallow) and in auto mode. Book-level Rescan verified as the per-item force path (extractMetadata re-reads sidecars/tags regardless of file size; recomputeHashInfo follows) — it is the documented answer to 'I changed this book's sidecar'. Glossary Scan entry replaced with Force Rescan (old label kept in also:), scanning.md table + prose pick up the new label. Generated file regenerated with the Dockerfile-pinned templ version from inside templates/ so the diff is exactly the label strings. --- docs/admin/scanning.md | 6 +++--- docs/developer/ui-controls.md | 6 ++++-- templates/admin_library.templ | 2 +- templates/admin_library_templ.go | 2 +- 4 files changed, 9 insertions(+), 7 deletions(-) diff --git a/docs/admin/scanning.md b/docs/admin/scanning.md index c4dd4c0f..7b605522 100644 --- a/docs/admin/scanning.md +++ b/docs/admin/scanning.md @@ -36,7 +36,7 @@ Every scan is one of two kinds: | Control | Where | Kind | Scope | | --- | --- | --- | --- | | **Force Rescan All Libraries** | Admin dashboard → Quick Actions | Force | Every library | -| **Scan** (library row) | Admin → Libraries | Force | That library | +| **Force Rescan** (library row) | Admin → Libraries | Force | That library | | **Scan this folder** (folder-row icon) | Admin → Libraries → a library's panel | Shallow | That folder's subtree | | **Auto-Scan** + **Scan Interval (seconds)** | Admin → Settings → Scanning | Shallow | Every library | | **Retry** / **Retry all** | Admin → Libraries → Processing Issues | Per-item | Failed items only | @@ -48,8 +48,8 @@ The details behind the table: force scan job for each. Libraries that already have a scan running are left alone — the button reports which libraries started and which were skipped because a scan was already in flight. -- **Scan** on a library row is the same force rescan, scoped to that one - library. It shares the dashboard button's semantics exactly. +- **Force Rescan** on a library row is the same force rescan, scoped to + that one library. It shares the dashboard button's semantics exactly. - **Scan this folder** is the only folder-sized scan, and the only shallow one an admin triggers by hand: unchanged files are skipped, and only that folder's subtree is walked. Because a partial scan can't vouch for diff --git a/docs/developer/ui-controls.md b/docs/developer/ui-controls.md index cc2ff846..a5415f75 100644 --- a/docs/developer/ui-controls.md +++ b/docs/developer/ui-controls.md @@ -218,9 +218,11 @@ does: Force-rescans every library — re-reads each file, re-extracts metadata w also: Scan All Libraries note: renamed 2026-11-02 — the old label under-promised a heavy operation -label: Scan +label: Force Rescan where: Admin → Libraries → a library's card row -does: Force-rescans that one library (same semantics as Force Rescan All Libraries, scoped to a single library). +does: Force-rescans that one library — re-reads and re-extracts every file in it. Same semantics as Force Rescan All Libraries, scoped to a single library. +also: Scan +note: renamed 2026-11-02 per owner — the label now carries the force semantics instead of hiding them label: Scan this folder where: Admin → Libraries → a library's panel → a folder row diff --git a/templates/admin_library.templ b/templates/admin_library.templ index 8ca5ce1d..d4b7c85f 100644 --- a/templates/admin_library.templ +++ b/templates/admin_library.templ @@ -236,7 +236,7 @@ templ LibraryList(user User, libraries []LibraryData, users []User) { class="btn btn-secondary text-xs px-3 py-1.5" > @Icon("refresh", "h-4 w-4") - Scan + Force Rescan