From ac0e66db0a5350e067716d6110670f3f43d0927b Mon Sep 17 00:00:00 2001 From: Ademiitura Date: Sat, 30 May 2026 20:38:03 +0100 Subject: [PATCH] perf(ui): offload progress bar to compositor thread via transform - Replace inline width animation with transform: scaleX() on TrickleBar - Add will-change: transform for explicit compositor layer promotion - Wrap bar in overflow: hidden container for correct scaleX clipping - Preserves aria-valuenow for accessibility Closes #238 --- src/app/components/TopLoadingBar.tsx | 32 ++++++++++++++++++++-------- 1 file changed, 23 insertions(+), 9 deletions(-) diff --git a/src/app/components/TopLoadingBar.tsx b/src/app/components/TopLoadingBar.tsx index e8d76d2..dfbfe09 100644 --- a/src/app/components/TopLoadingBar.tsx +++ b/src/app/components/TopLoadingBar.tsx @@ -21,24 +21,38 @@ export function useProgressBar() { // ─── Trickle bar — isolated so the RAF hook runs unconditionally ────────────── function TrickleBar({ width }: { width: number }) { + const scale = width / 100; + return (