Skip to content

YC (S26) | Open Computer History | Continuously record your company computer work, map your workflows, help you find work worth automating, and power your agents' context

fix: white flash when scrolling timeline between frames

Louis Beaumont958e05ede7f9
diff --git a/apps/screenpipe-app-tauri/components/rewind/current-frame-timeline.tsx b/apps/screenpipe-app-tauri/components/rewind/current-frame-timeline.tsx
index aaaaf04d1..40d6307f9 100644
--- a/apps/screenpipe-app-tauri/components/rewind/current-frame-timeline.tsx
+++ b/apps/screenpipe-app-tauri/components/rewind/current-frame-timeline.tsx
@@ -168,10 +168,12 @@ export const CurrentFrameTimeline: FC<CurrentFrameTimelineProps> = ({
return lower.endsWith('.jpg') || lower.endsWith('.jpeg') || lower.endsWith('.png');
}, [debouncedFrame?.filePath]);
- // Reset snapshot state when frame changes
+ // Reset snapshot failure flag when frame changes.
+ // DON'T clear snapshotAssetUrl here — keep the old image visible until
+ // the new one finishes preloading (the snapshot effect sets the URL only
+ // after img.onload). Clearing it eagerly causes a white flash.
useEffect(() => {
setSnapshotFailed(false);
- setSnapshotAssetUrl(null);
}, [debouncedFrame?.filePath]);
// Convert file path to asset URL
@@ -647,7 +649,7 @@ export const CurrentFrameTimeline: FC<CurrentFrameTimelineProps> = ({
return (
<div
ref={containerRef}
- className="absolute inset-0 w-full h-full"
+ className="absolute inset-0 w-full h-full bg-black"
onContextMenu={handleContextMenu}
>
{/* Context menu - right-click */}