Bolt: Optimized GradientBlinds resize performance #50

Closed
ragusa-it wants to merge 1 commits from bolt-performance-gradient-blinds-resize-5528101139476827014 into main

1 Commits

Author SHA1 Message Date
google-labs-jules[bot]
7ecfd04f35 perf(GradientBlinds): defer getBoundingClientRect to rAF on resize
Optimizes `GradientBlinds` layout performance by using `ResizeObserverEntry.contentRect` for immediate renderer resizing and deferring the expensive `getBoundingClientRect()` call (required for mouse interaction mapping) to the next animation frame. This prevents synchronous layout thrashing inside the `ResizeObserver` callback.

- Updates `resize` to accept `ResizeObserverEntry[]`
- Uses `contentRect` for `renderer.setSize`
- Defers `rectRef` update to `requestAnimationFrame`

Co-authored-by: ragusa-it <196988693+ragusa-it@users.noreply.github.com>
2026-02-03 01:47:43 +00:00