Repository navigation
feat(agents): distinguish Claude background monitoring (takes over #14205) #16201
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
151cb5e
feat(agents): distinguish Claude background monitoring
nwparker 04f663e
fix(sidebar): keep monitoring status visible
nwparker 13f5afe
test(agents): cover Claude monitoring drain
nwparker 835dfc0
test(mobile): avoid unresolved renderer test type
nwparker 76f77bf
feat(agents): render Claude monitoring as a static turquoise dot
brennanb2025 e407944
revert(agents): restore the yellow Radio glyph for monitoring
brennanb2025 082b857
merge origin/main after #15202 and #15212 landed
brennanb2025 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,87 @@ | ||
| import { createElement } from 'react' | ||
| import { act, create } from 'react-test-renderer' | ||
| import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest' | ||
| import { AgentSpinner } from './AgentSpinner' | ||
| import { AgentStateDot } from './AgentStateDot' | ||
|
|
||
| const DESKTOP_WORKING_COLOR = '#eab308' | ||
|
|
||
| type MonitoringTestRenderer = { | ||
| readonly root: { | ||
| findByType(type: string): { props: Record<string, unknown> } | ||
| } | ||
| unmount(): void | ||
| } | ||
|
|
||
| const { animationLoop, animationTiming, setValue } = vi.hoisted(() => ({ | ||
| animationLoop: vi.fn(() => ({ start: vi.fn(), stop: vi.fn() })), | ||
| animationTiming: vi.fn(() => ({})), | ||
| setValue: vi.fn() | ||
| })) | ||
|
|
||
| vi.mock('lucide-react-native', () => ({ Radio: 'Radio' })) | ||
| vi.mock('react-native', () => ({ | ||
| Animated: { | ||
| Value: function Value() { | ||
| return { interpolate: vi.fn(() => 'rotation'), setValue } | ||
| }, | ||
| View: 'AnimatedView', | ||
| loop: animationLoop, | ||
| timing: animationTiming | ||
| }, | ||
| Easing: { linear: 'linear' }, | ||
| StyleSheet: { create: <T>(styles: T) => styles }, | ||
| View: 'View' | ||
| })) | ||
|
|
||
| describe('mobile monitoring indicators', () => { | ||
| let renderer: MonitoringTestRenderer | null = null | ||
|
|
||
| beforeEach(() => { | ||
| animationLoop.mockClear() | ||
| animationTiming.mockClear() | ||
| setValue.mockClear() | ||
| }) | ||
|
|
||
| afterEach(() => { | ||
| act(() => renderer?.unmount()) | ||
| renderer = null | ||
| }) | ||
|
|
||
| it('renders a static Radio for a monitoring agent', async () => { | ||
| await act(async () => { | ||
| renderer = create(createElement(AgentStateDot, { state: 'monitoring' })) | ||
| }) | ||
|
|
||
| expect(renderer?.root.findByType('Radio').props).toMatchObject({ | ||
| color: DESKTOP_WORKING_COLOR, | ||
| size: 10 | ||
| }) | ||
| expect(animationTiming).not.toHaveBeenCalled() | ||
| expect(animationLoop).not.toHaveBeenCalled() | ||
| }) | ||
|
|
||
| it('renders a static Radio for an all-monitoring workspace', async () => { | ||
| await act(async () => { | ||
| renderer = create( | ||
| createElement(AgentSpinner, { status: 'working', workingMode: 'monitoring' }) | ||
| ) | ||
| }) | ||
|
|
||
| expect(renderer?.root.findByType('Radio').props).toMatchObject({ | ||
| color: DESKTOP_WORKING_COLOR, | ||
| size: 12 | ||
| }) | ||
| expect(animationTiming).not.toHaveBeenCalled() | ||
| expect(animationLoop).not.toHaveBeenCalled() | ||
| }) | ||
|
|
||
| it('keeps the spinner fallback when workingMode is absent', async () => { | ||
| await act(async () => { | ||
| renderer = create(createElement(AgentSpinner, { status: 'working' })) | ||
| }) | ||
|
|
||
| expect(animationTiming).toHaveBeenCalledOnce() | ||
| expect(animationLoop).toHaveBeenCalledOnce() | ||
| }) | ||
| }) |
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
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
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
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
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
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win
🧩 Analysis chain
🏁 Script executed:
Repository: stablyai/orca
Length of output: 50370
🏁 Script executed:
Repository: stablyai/orca
Length of output: 5542
🌐 Web query:
React Native accessibility View accessibilityLabel accessible prop documentation💡 Result:
In React Native, the accessible and accessibilityLabel props are fundamental accessibility controls used to make components discoverable and understandable by assistive technologies like screen readers [1][2]. accessible Prop When set to true, this prop indicates that a view is an accessibility element, making it discoverable by assistive technologies such as screen readers and hardware keyboards [1][3]. - Default Behavior: By default, all touchable elements (such as TouchableOpacity) are accessible [1][4]. - Platform Mapping: On Android, this translates to native focusable; on iOS, it translates to isAccessibilityElement [1][5]. - Important Note: Setting accessible={true} does not guarantee that the element will be focused by VoiceOver or TalkBack, as assistive technologies may override this for various reasons, such as grouping or hierarchy management [1][6]. accessibilityLabel Prop This prop provides a custom string that screen readers will verbalize when the element is selected [1][5]. - Best Practice: It is considered good practice to set an accessibilityLabel on any element marked as accessible to ensure users understand the purpose of the element [1]. - Default Behavior: If no accessibilityLabel is provided, React Native automatically constructs one by traversing the element's children and concatenating all Text node children, separated by spaces [1][3]. Example Usage Press me! In this example, the accessibilityLabel explicitly provides the text "Tap me!" for the screen reader, overriding the default behavior that would have used the text "Press me!" [1][6].
Citations:
Mark monitoring indicators as accessible.
Set
accessible={true}on theAgentSpinnermonitoring wrapper andaccessible={state === 'monitoring'}on theAgentStateDotwrapper. Assert these props inagent-monitoring-indicators.test.ts.📍 Affects 2 files
mobile/src/components/AgentSpinner.tsx#L50-L57(this comment)mobile/src/components/AgentStateDot.tsx#L50-L56Source: MCP tools