From 7cefd9bf0456c44bbb5b13f669af0b3b216feada Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Felix=20F=C3=B6rtsch?= Date: Fri, 27 Mar 2026 01:53:29 +0100 Subject: [PATCH] wire scan completion to pipeline page MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit After a scan completes, show a "Review in Pipeline →" link next to the status label. Nav already included the Pipeline entry from a prior task. Co-Authored-By: Claude Sonnet 4.6 --- src/features/scan/ScanPage.tsx | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/features/scan/ScanPage.tsx b/src/features/scan/ScanPage.tsx index 16e64bf..69abb94 100644 --- a/src/features/scan/ScanPage.tsx +++ b/src/features/scan/ScanPage.tsx @@ -1,4 +1,5 @@ import { useEffect, useRef, useState, useCallback } from 'react'; +import { Link } from '@tanstack/react-router'; import { api } from '~/shared/lib/api'; import { Button } from '~/shared/components/ui/button'; import { Badge } from '~/shared/components/ui/badge'; @@ -29,6 +30,7 @@ export function ScanPage() { const [limit, setLimit] = useState(''); const [log, setLog] = useState([]); const [statusLabel, setStatusLabel] = useState(''); + const [scanComplete, setScanComplete] = useState(false); const [currentItem, setCurrentItem] = useState(''); const [progressScanned, setProgressScanned] = useState(0); const [progressTotal, setProgressTotal] = useState(0); @@ -58,6 +60,7 @@ export function ScanPage() { const d = b.complete; b.complete = null; setStatusLabel(`Scan complete — ${d.scanned ?? '?'} items, ${d.errors ?? 0} errors`); + setScanComplete(true); setStatus((prev) => prev ? { ...prev, running: false } : prev); stopFlushing(); } @@ -150,6 +153,7 @@ export function ScanPage() { setErrors(0); setCurrentItem(''); setStatusLabel('Scan in progress…'); + setScanComplete(false); setStatus((prev) => prev ? { ...prev, running: true } : prev); bufRef.current = freshBuf(); @@ -179,6 +183,11 @@ export function ScanPage() {
{statusLabel || (running ? 'Scan in progress…' : 'Scan idle')} + {scanComplete && ( + + Review in Pipeline → + + )} {running ? ( ) : (