fix: browser screenshot flashing
3clyp50 committed
Jan 6, 2026 at 18:53 UTC
ea078afface422a3a835ee78d898ce08eec84ebd
1 file changed
+13
webui/js/messages.js
+13
@@ -1404,6 +1404,19 @@ function updateProcessStep(stepElement, id, type, heading, content, kvps, durati
1404
// Update detail content
1405
const detailContent = stepElement.querySelector(".process-step-detail-content");
1406
if (detailContent) {
1407
+ // For browser, update image src incrementally to avoid flashing
1408
+ if (type === "browser" && kvps?.screenshot) {
1409
+ const existingImg = detailContent.querySelector(".screenshot-img");
1410
+ const newSrc = kvps.screenshot.replace("img://", "/image_get?path=");
1411
+ if (existingImg) {
1412
+ // Only update if src actually changed
1413
+ if (!existingImg.src.endsWith(newSrc.split("?path=")[1])) {
1414
+ existingImg.src = newSrc;
1415
+ }
1416
+ // Skip full re-render to avoid flashing
1417
+ return;
1418
+ }
1419
+ }
1420
renderStepDetailContent(detailContent, content, kvps, type);
1421
}
1422