Skip to content

Conversation

@ammar-agent
Copy link
Collaborator

@ammar-agent ammar-agent commented Dec 9, 2025

Summary

Caps the shimmer animation at 30fps to reduce repaints on high-refresh displays.

Changes

  • Uses steps(42, end) timing function to limit animation to ~30fps
  • On 240hz monitors, this reduces repaints by 8x (240 → 30)
  • Still smooth enough for a loading indicator

Why?

background-position isn't compositor-only, so each frame triggers a main thread repaint. On high-refresh displays this was causing noticeable frame drops during streaming.


Generated with mux

@chatgpt-codex-connector
Copy link

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.
Repo admins can enable using credits for code reviews in their settings.

@ammar-agent ammar-agent force-pushed the fix-shimmer-frame-drops-thinking branch from e056910 to 0bd550b Compare December 9, 2025 02:34
@ammario ammario merged commit c3a6641 into main Dec 9, 2025
19 checks passed
@ammario ammario deleted the fix-shimmer-frame-drops-thinking branch December 9, 2025 02:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants