Cloud animation for Cloud Agent subagent - #1113
Conversation
Co-Authored-By: Kimchi <noreply@kimchi.dev>
|
📚 No documentation changes were needed for this PR. |
Kimchi Code Review
Summary📊 Review Score: 78/100 (overall code quality — 0 lowest, 100 highest) 🧪 Tests: no — No test files were added or modified in the diff. The change is mostly visual (animation frames and widget rendering), but there are no unit tests for 📝 Found 2 issue(s). See inline comments for details. What to expectKimchi will analyze the changes in this pull request and post:
The review typically completes within a few minutes. This comment will be updated once the review is ready. Interact with Kimchi
ConfigurationReviews are configured by your organization admin. Powered by Kimchi — AI-powered code review by CAST AI |
There was a problem hiding this comment.
📊 Review Score: 78/100 (overall code quality — 0 lowest, 100 highest)
⏱️ Estimated effort to review: 2/5 (1 = trivial, 5 = very complex)
🧪 Tests: no — No test files were added or modified in the diff. The change is mostly visual (animation frames and widget rendering), but there are no unit tests for getAgentSpinnerFrames, frame indexing, or the optional subagentType propagation paths.
📝 Found 2 issue(s). See inline comments for details.
| @@ -1320,7 +1324,8 @@ ${AGENT_TOOL_GUIDELINES}`, | |||
| } | |||
There was a problem hiding this comment.
getAgentSpinnerFrames(details.subagentType) is called with a value that may be undefined, because GetSubagentResultDetails.subagentType is declared as optional (subagentType?: string) while getAgentSpinnerFrames requires a non-optional string. Although the function happens to fall back to SPINNER when the type does not match, relying on this is brittle and may break under stricter TypeScript settings or future refactors. It is also inconsistent with getSubagentResultIcon, which explicitly guards the call with subagentType ? getAgentSpinnerFrames(subagentType) : SPINNER.
💡 Suggestion: Change getAgentSpinnerFrames in src/extensions/agents/ui/agent-widget.ts to accept type: string | undefined (returning SPINNER for undefined), or guard the call here: const frames = details.subagentType ? getAgentSpinnerFrames(details.subagentType) : SPINNER.
There was a problem hiding this comment.
this comment makes sense, it would be better to handle this possible null case in getAgentSpinnerFrames itself.
Linked issue
Closes #0
What does this PR do?
Adds a unique inline animation for the Cloud Agent (
Remote-Runner) subagent type, replacing the generic braille spinner it shared with all other agents. The Cloud Agent now shows a cloud glyph (☁) with a loading arc (◜◝◞◟) tracing around it, completing in a full circle before restarting — visually distinguishing remote execution from local agents at a glance.The animation works across all three TUI rendering surfaces:
get_subagent_resulticon (queued/running status)Other agent types are unaffected — they continue to use the standard braille spinner.
Checklist
pnpm run test)pnpm run check)