Skip to content

fix "working" spinner animation (#1054) - #1259

Merged
adamdotdevin merged 1 commit into
anomalyco:devfrom
tobias-walle:fix-spinner-animation
Jul 23, 2025
Merged

adamdotdevin merged 1 commit into
anomalyco:devfrom
tobias-walle:fix-spinner-animation

Conversation

@tobias-walle

Copy link
Copy Markdown
Contributor

This fixed #1054 for me.

The dialog.ThemeSelectedMsg creates a new spinner but never triggers the m.spinner.Tick event to restart the animation.

On my terminal, the dialog.ThemeSelectedMsg is always triggered at the start of the session, as the tea.BackgroundColorMsg is triggered when it detects the dark theme.

@tobias-walle tobias-walle mentioned this pull request Jul 23, 2025
@adamdotdevin
adamdotdevin merged commit 12bf5f6 into anomalyco:dev Jul 23, 2025
thdxr pushed a commit that referenced this pull request Jul 24, 2025
@tobias-walle
tobias-walle deleted the fix-spinner-animation branch July 24, 2025 03:34
pepperpepperpepper pushed a commit to pepperpepperpepper/opencode that referenced this pull request Jul 29, 2025
@TheMorpheus407

Copy link
Copy Markdown

Research Summary

Issue: Fix "working" spinner animation (#1054) - Already MERGED

Root Cause

In packages/tui/internal/components/chat/editor.go, when dialog.ThemeSelectedMsg was received:

  1. A new spinner was created via createSpinner()
  2. But only m.textarea.Focus() was returned as the command
  3. The m.spinner.Tick event was never triggered, so the spinner animation never started

The Fix

// Before
return m, m.textarea.Focus()

// After  
return m, tea.Batch(m.textarea.Focus(), m.spinner.Tick)

Using tea.Batch() ensures both commands execute, restarting the spinner animation.

Verification

The fix can be verified by starting a session with dark theme detection, which triggers tea.BackgroundColorMsg → dialog.ThemeSelectedMsg.

Note

The current workspace is a Flutter/Dart frontend. The TUI Go code is in the anomalyco/opencode repository where the fix was applied.

@TheMorpheus407

Copy link
Copy Markdown

Research posted for issue #1259

AIALRA-0 pushed a commit to AIALRA-0/opencode-turn-engine that referenced this pull request Jun 10, 2026
meSingh pushed a commit to meSingh/opencode that referenced this pull request Sep 6, 2026
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.

Loading Animation

4 participants