fix: exclude enableReasoningEffort from initial sync to enable Save button

When the user clicks the "Enable reasoning" checkbox, the Save button should
become enabled. Previously, the transition from undefined to true was treated
as an initial sync, preventing the button from enabling.

This fix explicitly excludes enableReasoningEffort from the initial sync logic
since it is a user-controlled checkbox that should always trigger changes.

Fixes #7099
This commit is contained in:
Roo Code 2025-08-14 14:56:53 +00:00
parent e5d93f2bca
commit 5d8e66788e

View file

@ -229,7 +229,9 @@ const SettingsView = forwardRef<SettingsViewRef, SettingsViewProps>(({ onDone, t
// Don't treat initial sync from undefined to a defined value as a user change
// This prevents the dirty state when the component initializes and auto-syncs the model ID
const isInitialSync = previousValue === undefined && value !== undefined
// Exception: enableReasoningEffort is a user-controlled checkbox that should always trigger changes
const isInitialSync =
previousValue === undefined && value !== undefined && field !== "enableReasoningEffort"
if (!isInitialSync) {
setChangeDetected(true)