From 2dc569256c32190291e949d5772da797cb8da3d7 Mon Sep 17 00:00:00 2001 From: Brian Hursey Date: Sat, 28 Nov 2026 06:45:37 +0000 Subject: [PATCH] Give Auto tone and Auto WB the raw's thumbnail URL. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Raw records keep their pixels in `thumbUrl` and leave `thumb` empty, so the analysis was handed an empty string, failed to decode, and returned neutral values — which made Auto WB look identical to As shot. 🤖 Generated with Codebuff Co-Authored-By: Codebuff --- src/components/Panels.tsx | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/components/Panels.tsx b/src/components/Panels.tsx index 5fa197c..7dfe996 100644 --- a/src/components/Panels.tsx +++ b/src/components/Panels.tsx @@ -94,10 +94,15 @@ export function BasicPanel({ const [autoBusy, setAutoBusy] = useState(false); const [wbBusy, setWbBusy] = useState(false); + // Raws carry their pixels as a URL, with `thumb` empty; handing the empty + // string to the analysis made the decode fail and both Auto buttons quietly + // come back with neutral values, so Auto WB matched As shot exactly. + const thumbSrc = photo.thumbUrl ?? photo.thumb; + const auto = async () => { setAutoBusy(true); try { - const partial = await computeAutoEdits(photo.thumb); + const partial = await computeAutoEdits(thumbSrc); set(partial, 'Auto tone'); } finally { setAutoBusy(false); @@ -107,7 +112,7 @@ export function BasicPanel({ const autoWb = async () => { setWbBusy(true); try { - set(await computeAutoWhiteBalance(photo.thumb), 'Auto white balance'); + set(await computeAutoWhiteBalance(thumbSrc), 'Auto white balance'); } finally { setWbBusy(false); }