Rework scan screen, make lookups non-blocking, fix review findings

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This commit is contained in:
swaitsandClaude Fable 5.2 committed 2026-11-18 10:19:32 -07:00
1 parent 468cafc6db
commit b5defb4e4f
46 files changed
+1957 -406

No files matched your search

+44 -4
View File
@@ -40,11 +40,25 @@ label small { display: block; margin-top: 4px; }
.scan { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; }
.scan .forms { grid-column: 1 / -1; }
@media (max-width: 760px) { .scan { grid-template-columns: 1fr; } main { padding: 14px 12px; } }
.video-wrap { position: relative; aspect-ratio: 16 / 9; background: #000; border-radius: 12px; overflow: hidden; border: 3px solid transparent; }
.video-wrap.flash { border-color: var(--flash); }
.video-wrap { position: relative; width: 100%; background: #0b0c0e; border-radius: 12px; overflow: hidden; border: 3px solid var(--line); transition: border-color .15s; }
.video-wrap.flash { border-color: var(--flash); transition: none; }
video { width: 100%; height: 100%; object-fit: cover; display: block; }
video.mirror { transform: scaleX(-1); }
.video-empty { position: absolute; inset: 0; display: grid; place-items: center; color: #aaa; }
.video-empty { position: absolute; inset: 0; display: grid; place-items: center; }
button.big { font-size: 1.1rem; padding: 12px 26px; }
.target { position: absolute; border: 2px solid rgba(255,255,255,.92); border-radius: 10px; box-shadow: 0 0 0 100vmax rgba(0,0,0,.38); pointer-events: none; transition: border-color .15s; }
.video-wrap.flash .target { border-color: var(--flash); box-shadow: 0 0 0 100vmax rgba(0,0,0,.38), 0 0 0 3px var(--flash); }
.hint { position: absolute; left: 50%; bottom: 5%; transform: translateX(-50%); max-width: 92%; padding: 4px 12px; border-radius: 999px; background: rgba(0,0,0,.72); color: #fff; font-size: .9rem; white-space: nowrap; pointer-events: none; }
.scanning { position: absolute; top: 10px; right: 10px; display: flex; align-items: center; gap: 7px; padding: 3px 11px 3px 9px; border-radius: 999px; background: rgba(0,0,0,.72); color: #fff; font-size: .82rem; pointer-events: none; }
.pulse { width: 9px; height: 9px; border-radius: 50%; background: #52c586; animation: pulse 1.2s ease-in-out infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: .35; transform: scale(.7); } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes rowflash { from { opacity: .35; } to { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .pulse { animation: none; } .spinner { animation-duration: 3s; } .flashbar { animation-duration: .01s; } }
.status { margin: 10px 0; padding: 8px 12px; border-radius: 8px; border-left: 4px solid var(--line); background: var(--panel); font-weight: 500; min-height: 2.6em; }
.status.ok { border-left-color: var(--ok); color: var(--ok); }
.status.warn { border-left-color: var(--warn); color: var(--warn); }
.small { font-size: .85rem; }
.summary { font-weight: 600; margin: 0 0 6px; }
.isbn-form input { font-size: 1.1rem; }
.list { list-style: none; margin: 0; padding: 0; }
@@ -76,3 +90,29 @@ legend { color: var(--muted); font-size: .9rem; padding: 0; margin-bottom: 6px;
.slot.on { background: var(--accent); color: var(--accent-text); border-color: var(--accent); }
.slot.used { opacity: .45; }
.confirm { border-color: var(--accent); }
/* Books: one row each, one state each. */
.book { position: relative; display: grid; gap: 8px; padding: 12px 12px 12px 14px; border-bottom: 1px solid var(--line); border-left: 4px solid var(--line); overflow: hidden; }
.book.looking { border-left-color: var(--accent); }
.book.ready { border-left-color: var(--ok); }
.book.attention { border-left-color: var(--warn); background: color-mix(in srgb, var(--warn) 8%, transparent); }
.book-head { display: flex; gap: 12px; justify-content: space-between; align-items: flex-start; }
.book-head .item-main { flex: 1; }
.earlier { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; text-align: right; }
.book-state { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
.state-label { display: inline-flex; align-items: center; gap: 7px; font-weight: 600; white-space: nowrap; }
.book.looking .state-label, .item[data-state=looking] .state-label { color: var(--accent); }
.book.ready .state-label, .item .state-label { color: var(--ok); }
.book.attention .state-label { color: var(--warn); }
.item[data-state=looking] .state-label { color: var(--accent); }
.elapsed { font-weight: 400; font-variant-numeric: tabular-nums; color: var(--muted); }
.icon { width: 16px; height: 16px; flex: none; }
.spinner { width: 14px; height: 14px; border-radius: 50%; border: 2px solid color-mix(in srgb, var(--accent) 30%, transparent); border-top-color: var(--accent); animation: spin .8s linear infinite; flex: none; }
.reason { color: var(--text); overflow-wrap: anywhere; }
.note { overflow-wrap: anywhere; }
.flashbar { position: absolute; inset: 0; background: var(--flash); opacity: 0; animation: rowflash 1.4s ease-out; pointer-events: none; }
.item { align-items: center; }
.item > .state-label { margin-left: auto; }
.item.dim .title { color: var(--muted); }
.callno-slot { min-width: 9.5em; }
.queue-head { font-weight: 600; }