From cc13fd7eef9b945f3a91c2358de505994b714877 Mon Sep 17 00:00:00 2001 From: Brennan Benson <79079362+brennanb2025@users.noreply.github.com> Date: Sun, 8 Nov 2026 16:54:30 -0800 Subject: [PATCH] Show agent speed as one button instead of a Standard/Fast switcher Codex's Speed row used a segmented Standard | Fast switcher while Claude and Cursor used a single Fast chip. Speed is now always one button: one faster tier toggles it, several (Fast and Ultrafast, or a configured Flex) open a list from the button. --- .../AgentLaunchSetupPanel.prompt.test.tsx | 6 +- .../controls/NativeChatSessionOptionRows.tsx | 27 ++++++ .../controls/NativeChatSessionSpeedButton.tsx | 95 +++++++++++++++++++ 3 files changed, 123 insertions(+), 5 deletions(-) create mode 100644 src/renderer/src/components/native-chat/session/options/controls/NativeChatSessionSpeedButton.tsx diff --git a/src/renderer/src/components/agent/AgentLaunchSetupPanel.prompt.test.tsx b/src/renderer/src/components/agent/AgentLaunchSetupPanel.prompt.test.tsx index 12f62eb21f7..7b314f5c2a9 100644 --- a/src/renderer/src/components/agent/AgentLaunchSetupPanel.prompt.test.tsx +++ b/src/renderer/src/components/agent/AgentLaunchSetupPanel.prompt.test.tsx @@ -71,11 +71,7 @@ it.each(['claude', 'codex'] as const)( fireEvent.click(panel().querySelector('[cmdk-item]')!) fireEvent.click(getByRole(document.body, 'radio', { name: 'High' })) // A speed edit copies the current Arguments into the draft; later settings must still win. - fireEvent.click( - agent === 'claude' - ? getByRole(document.body, 'button', { name: 'Fast' }) - : getByRole(document.body, 'radio', { name: 'Fast' }) - ) + fireEvent.click(getByRole(document.body, 'button', { name: 'Fast' })) changePrompt( panel().querySelector('[contenteditable]')!, 'keep @/repo/exact-file.ts' diff --git a/src/renderer/src/components/native-chat/session/options/controls/NativeChatSessionOptionRows.tsx b/src/renderer/src/components/native-chat/session/options/controls/NativeChatSessionOptionRows.tsx index 67b99859a4b..7a78a28dc85 100644 --- a/src/renderer/src/components/native-chat/session/options/controls/NativeChatSessionOptionRows.tsx +++ b/src/renderer/src/components/native-chat/session/options/controls/NativeChatSessionOptionRows.tsx @@ -22,6 +22,7 @@ import { } from '../../../../../../../shared/native-chat/input/native-chat-session-option-labels' import { sayNativeChatSessionOptionTranslated as say } from './native-chat-session-option-labels-text' import { NativeChatSessionOptionWriteGroup } from './NativeChatSessionOptionWriteGroup' +import { NativeChatSessionSpeedButton, speedButtonTiers } from './NativeChatSessionSpeedButton' type NativeChatSessionOptionRowsProps = { /** The current model's options, in display order. */ @@ -138,6 +139,32 @@ function OptionRow(props: { ) } + const speed = speedButtonTiers(descriptor) + if (speed && descriptor.kind.type === 'select') { + const button = ( + + ) + return layout === 'inline' ? ( + button + ) : ( +
+ {label} + {button} +
+ ) + } if (descriptor.kind.type === 'boolean') { return (