Skip to content

Commit 912d795

Browse files
hassoncsChris Hasson
andauthored
fix(chat): Cancel auto-approve timer when editing follow-up suggestion (#6226)
Co-authored-by: Chris Hasson <[email protected]>
1 parent 490538f commit 912d795

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

.changeset/kind-horses-sniff.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"kilo-code": patch
3+
---
4+
5+
Cancel auto-approve timer when editing follow-up suggestion

webview-ui/src/components/chat/FollowUpSuggest.tsx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -134,6 +134,9 @@ export const FollowUpSuggest = ({
134134
className="absolute top-0 right-0 opacity-0 group-hover:opacity-100 transition-opacity"
135135
onClick={(e) => {
136136
e.stopPropagation()
137+
// Cancel the auto-approve timer when edit button is clicked
138+
setSuggestionSelected(true)
139+
onCancelAutoApproval?.()
137140
// Simulate shift-click by directly calling the handler with shiftKey=true.
138141
onSuggestionClick?.(suggestion, { ...e, shiftKey: true })
139142
}}>

0 commit comments

Comments
 (0)