mirror of
https://github.com/RooVetGit/Roo-Code.git
synced 2026-09-06 08:18:39 +00:00
Merge pull request #1090 from RooVetGit/fix_settings_done_button_with_unsaved_changes
Fix settings done button with unsaved changes
This commit is contained in:
commit
d327c21828
2 changed files with 10 additions and 2 deletions
5
.changeset/twenty-rice-own.md
Normal file
5
.changeset/twenty-rice-own.md
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
"roo-cline": patch
|
||||
---
|
||||
|
||||
Fix settings done button with unsaved changes
|
||||
|
|
@ -173,7 +173,6 @@ const SettingsView = forwardRef<SettingsViewRef, SettingsViewProps>(({ onDone },
|
|||
text: currentApiConfigName,
|
||||
apiConfiguration,
|
||||
})
|
||||
// onDone()
|
||||
setChangeDetected(false)
|
||||
}
|
||||
}
|
||||
|
|
@ -217,7 +216,11 @@ const SettingsView = forwardRef<SettingsViewRef, SettingsViewProps>(({ onDone },
|
|||
|
||||
const onConfirmDialogResult = useCallback((confirm: boolean) => {
|
||||
if (confirm) {
|
||||
confirmDialogHandler.current?.()
|
||||
setChangeDetected(false)
|
||||
// Wait for the change detection to be updated
|
||||
setTimeout(() => {
|
||||
confirmDialogHandler.current?.()
|
||||
}, 100)
|
||||
}
|
||||
}, [])
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue