LCCN lookup & more #102

Merged
jfro merged 5 commits from feat/lccn-lookup into main 2026-10-26 02:05:08 +00:00
Owner
  • Tweaks to add book UI
  • Show all provider results in ISBN lookup
  • LCCN lookup
  • Move manual add book to a modal
  • Remove back to library buttons are they were useless
- Tweaks to add book UI - Show all provider results in ISBN lookup - LCCN lookup - Move manual add book to a modal - Remove back to library buttons are they were useless
The F8 change gave both batch pickers the provider picker's re-enable
line, but in changeMediaType `data` only exists inside the try block, so
it threw after saving. The buttons stayed disabled and, being disabled,
lost the highlight on the new media type.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Add Book ISBN lookup already asked every provider and ranked the
answers (F6), but showed only the best one and never said where it came
from. It now lists every provider's answer, best first and marked "Best
match", with its cover and provider, so a provider with better data can
be picked. The manual form is still filled from the best answer, and a
camera scan still marks whichever result is added as scanned.

lookup_by_isbn/1 now carries the :provider of its answer, so an ISBN
pasted into the Provider ID tab shows its provider too. The single-result
card had no other users, so it's gone.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Older books often have an LCCN but no ISBN. The Provider ID tab now
takes one as printed in the book, old or new ("65-22547", "a 53-1234",
"2001-012345"), with its label ("Library of Congress Catalog Card
Number: 65-22547", "lccn:65022547"), or as an lccn.loc.gov /
loc.gov/item link, and looks it up in the Library of Congress catalog,
which only matches the normalized form ("65022547"). A bare run of
digits is still an ISBN or a Hardcover ID; prefix it with "lccn:".
Books with no ISBN get Open Library's cover by LCCN.

Books now keep their LCCN (new lccn column, stored normalized) from
Library of Congress results and Open Library editions, through Add to
Library and the batch scanner. The add and edit forms take it as
printed, the book page links it to its catalog record, and imports and
exports carry it, with imports matching existing books by it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Add Book page showed the manual form under the lookups, though
lookups are how books get added. It's now in a modal opened from an
"Add manually" button in the page header. The modal reopens by itself
when a save comes back with errors, so they aren't hidden, and when the
page is opened with values to prefill.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
chore: drop the "Back to library" buttons
All checks were successful
CI / test (pull_request) Successful in 50s
4385d5c26c
The top nav's Library link already does this on every page. Removed
from the Add Book, book, series and author pages.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
jfro merged commit 64039def4d into main 2026-10-26 02:05:08 +00:00
jfro deleted branch feat/lccn-lookup 2026-10-26 02:05:08 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
jfro/fuzzy_catalog!102
No description provided.