mirror of
https://github.com/Kilo-Org/kilocode.git
synced 2026-09-19 10:02:04 +08:00
fix(vscode): stop trimming edit mode fields on every keystroke
Removes .trim() from onChange handlers for description, prompt, and model fields so spaces can be typed without being stripped. The create mode form still trims on submit which is correct for one-shot actions.
This commit is contained in:
@@ -446,7 +446,7 @@ const AgentBehaviourTab: Component = () => {
|
||||
<TextField
|
||||
value={currentAgentConfig().description ?? ""}
|
||||
placeholder={language.t("settings.agentBehaviour.createMode.description.placeholder")}
|
||||
onChange={(val) => updateAgentConfig(name, { description: val.trim() || undefined })}
|
||||
onChange={(val) => updateAgentConfig(name, { description: val || undefined })}
|
||||
/>
|
||||
</Card>
|
||||
</Show>
|
||||
@@ -462,7 +462,7 @@ const AgentBehaviourTab: Component = () => {
|
||||
value={currentAgentConfig().prompt ?? ""}
|
||||
placeholder={language.t("settings.agentBehaviour.createMode.prompt.placeholder")}
|
||||
multiline
|
||||
onChange={(val) => updateAgentConfig(name, { prompt: val.trim() || undefined })}
|
||||
onChange={(val) => updateAgentConfig(name, { prompt: val || undefined })}
|
||||
/>
|
||||
</Card>
|
||||
|
||||
@@ -478,7 +478,7 @@ const AgentBehaviourTab: Component = () => {
|
||||
placeholder="e.g. anthropic/claude-sonnet-4-20250514"
|
||||
onChange={(val) =>
|
||||
updateAgentConfig(name, {
|
||||
model: val.trim() || undefined,
|
||||
model: val || undefined,
|
||||
})
|
||||
}
|
||||
/>
|
||||
|
||||
Reference in New Issue
Block a user