perf(site): cut rendering cost of long-lived UI animations - #28188
Draft
tracyjohnsonux wants to merge 1 commit into
Draft
perf(site): cut rendering cost of long-lived UI animations#28188tracyjohnsonux wants to merge 1 commit into
tracyjohnsonux wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Long-lived infinite animations in the Agents UI keep Chrome rendering at display refresh rate even when the page is otherwise idle. This is a broader pass over the same problem as #28182, replacing each hot animation with a technique that is cheap by construction rather than stepping the existing smooth arc, so nothing reads as choppy.
Spinnernow uses a singlesteps(8)rotation over a static opacity gradient (10 updates/s, one animation) instead of eight per-leaf opacity animations running at refresh rate. Long-lived Agents spinners (sidebar running status, running tool calls, subagents, build logs, plan/question submits) switch from smooth lucideanimate-spinarcs to this Spinner; discrete stepping on 8-leaf geometry is the classic activity-indicator look, so nothing appears janky. Globalanimate-spinis untouched for transient uses.backgroundPositionloop (JS work every frame, one loop per active tool) with a pure CSS keyframe that sweeps for 60% of a 3.5s cycle and holds for the rest, so the browser runs no per-frame JS and can skip repaints between sweeps. Reduced motion now parks the highlight off the text.left(layout each frame) with four stacked large-blur box-shadows; now a compositor-friendlytranslateXsweep (via an inline-size container and100cqw) with a gradient trail instead of blurred shadows.left/rightkeyframes totranslateX+scaleXso they composite instead of triggering layout every frame.Story assertions that matched the
.animate-spinclass now query the spinner's accessible title. The pre-existingMCP Tool Completedstory failure reproduces onmainand is unrelated.Refs #28182
This pull request was generated by Coder Agents on behalf of @tracyjohnsonux.
Audit notes: remaining animation inventory
loadingkeyframe (opacity pulse) is compositor-friendly and left as is.spin-once(GitPanel refresh) and dialoganimate-in/outare one-shot and left as is.SmoothTextstreaming reveal and scroller rAF loops are bounded and stop when idle.zip-rightanimatesleft/widthbut is one-shot (1s, non-infinite), so it was left alone.