mirror of
https://github.com/stablyai/orca.git
synced 2026-10-13 08:02:52 +00:00
@@ -14,21 +14,20 @@ export function AgentAwakeSetting({
|
||||
return (
|
||||
<section className="space-y-3">
|
||||
<SearchableSetting
|
||||
title="Keep computer awake when Orca sees agents running"
|
||||
description="Prevents this computer from sleeping while Orca sees an agent working. The display can still turn off."
|
||||
keywords={['awake', 'sleep', 'power', 'agent', 'running']}
|
||||
title="Keep computer awake while agents are working"
|
||||
description="Keeps this computer awake while agents are working. The display can still turn off."
|
||||
keywords={['awake', 'sleep', 'power', 'agent', 'running', 'working']}
|
||||
className="flex items-start justify-between gap-4 px-1 py-2"
|
||||
>
|
||||
<div className="min-w-0 shrink space-y-0.5">
|
||||
<Label>Keep computer awake when Orca sees agents running</Label>
|
||||
<Label>Keep computer awake while agents are working</Label>
|
||||
<p className="text-xs text-muted-foreground">
|
||||
Prevents this computer from sleeping while Orca sees an agent working. The display can
|
||||
still turn off.
|
||||
Keeps this computer awake while agents are working. The display can still turn off.
|
||||
</p>
|
||||
</div>
|
||||
<button
|
||||
role="switch"
|
||||
aria-label="Keep computer awake when Orca sees agents running"
|
||||
aria-label="Keep computer awake while agents are working"
|
||||
aria-checked={settings.keepComputerAwakeWhileAgentsRun}
|
||||
onClick={() =>
|
||||
updateSettings({
|
||||
|
||||
@@ -63,9 +63,9 @@ describe('AgentsPane', () => {
|
||||
it('renders the keep-awake toggle from settings', () => {
|
||||
const markup = renderPane(getDefaultSettings('/tmp'))
|
||||
|
||||
expect(markup).toContain('Keep computer awake when Orca sees agents running')
|
||||
expect(markup).toContain('Keep computer awake while agents are working')
|
||||
expect(markup).toContain(
|
||||
'Prevents this computer from sleeping while Orca sees an agent working. The display can still turn off.'
|
||||
'Keeps this computer awake while agents are working. The display can still turn off.'
|
||||
)
|
||||
expect(markup).toContain('aria-checked="false"')
|
||||
})
|
||||
@@ -81,9 +81,7 @@ describe('AgentsPane', () => {
|
||||
})
|
||||
|
||||
const keepAwakeSwitch = findSwitch(element)
|
||||
expect(keepAwakeSwitch.props['aria-label']).toBe(
|
||||
'Keep computer awake when Orca sees agents running'
|
||||
)
|
||||
expect(keepAwakeSwitch.props['aria-label']).toBe('Keep computer awake while agents are working')
|
||||
expect(keepAwakeSwitch.props['aria-checked']).toBe(false)
|
||||
|
||||
const onClick = keepAwakeSwitch.props.onClick as () => void
|
||||
|
||||
@@ -41,9 +41,9 @@ export const AGENTS_PANE_SEARCH_ENTRIES: SettingsSearchEntry[] = [
|
||||
]
|
||||
},
|
||||
{
|
||||
title: 'Keep computer awake when Orca sees agents running',
|
||||
title: 'Keep computer awake while agents are working',
|
||||
description:
|
||||
'Prevents this computer from sleeping while Orca sees an agent working. The display can still turn off.',
|
||||
keywords: ['awake', 'sleep', 'power', 'agent', 'running']
|
||||
'Keeps this computer awake while agents are working. The display can still turn off.',
|
||||
keywords: ['awake', 'sleep', 'power', 'agent', 'running', 'working']
|
||||
}
|
||||
]
|
||||
|
||||
@@ -25,11 +25,11 @@ test.describe('Agent awake setting', () => {
|
||||
await orcaPage.getByPlaceholder('Search settings').fill('awake')
|
||||
|
||||
await expect(
|
||||
orcaPage.getByText('Keep computer awake when Orca sees agents running').first()
|
||||
orcaPage.getByText('Keep computer awake while agents are working').first()
|
||||
).toBeVisible()
|
||||
|
||||
const keepAwakeSwitch = orcaPage.getByRole('switch', {
|
||||
name: 'Keep computer awake when Orca sees agents running'
|
||||
name: 'Keep computer awake while agents are working'
|
||||
})
|
||||
|
||||
await expect(keepAwakeSwitch).toHaveAttribute('aria-checked', 'false')
|
||||
|
||||
Reference in New Issue
Block a user