Skip to content

Conversation

@roomote
Copy link
Contributor

@roomote roomote bot commented Jan 15, 2026

This PR attempts to address Issue #10745. Feedback and guidance are welcome.

Summary

This PR fixes the inconsistent behavior where toggling the "Auto-Approval Enabled" checkbox in the Auto-Approve settings tab did not enable the Save button, making it behave differently from other checkboxes in the settings.

Changes

  • AutoApproveSettings.tsx:

    • Added autoApprovalEnabled prop from cached state
    • Updated checkbox onChange to call setCachedStateField("autoApprovalEnabled", newValue) to enable Save button activation
    • Kept setAutoApprovalEnabled(newValue) call for immediate timer cancellation (hybrid approach)
  • SettingsView.tsx:

    • Added autoApprovalEnabled to the destructured cachedState
    • Pass autoApprovalEnabled prop to AutoApproveSettings component
    • Added autoApprovalEnabled to handleSubmit for persistence when Save is clicked

Hybrid Approach

This implementation uses a hybrid approach that:

  1. Enables the Save button when the checkbox is toggled (consistent with other settings)
  2. Immediately stops countdown timers when auto-approval is disabled (preserves current UX for safety)

The setting is persisted when the user clicks the Save button.

Testing

  • TypeScript type checking passes
  • All SettingsView tests pass (20 tests)
  • All FollowUpSuggest tests pass (18 tests)

Closes #10745


Important

Fixes issue with 'Auto-Approval Enabled' checkbox not enabling Save button by updating state management in AutoApproveSettings.tsx and SettingsView.tsx.

  • Behavior:
    • Fixes issue where toggling Auto-Approval Enabled checkbox did not enable Save button in AutoApproveSettings.tsx.
    • Implements hybrid approach to enable Save button and stop timers immediately.
  • State Management:
    • Adds autoApprovalEnabled to cachedState in SettingsView.tsx.
    • Updates handleSubmit in SettingsView.tsx to persist autoApprovalEnabled.
  • Testing:
    • TypeScript type checking passes.
    • All SettingsView and FollowUpSuggest tests pass.

This description was created by Ellipsis for 18f86e7. You can customize this summary. It will automatically update as commits are pushed.

- Add autoApprovalEnabled prop to AutoApproveSettings component
- Update checkbox onChange to call setCachedStateField for Save button activation
- Keep setAutoApprovalEnabled call for immediate timer cancellation (hybrid approach)
- Include autoApprovalEnabled in SettingsView handleSubmit for persistence

This fixes Issue #10745 where toggling the Auto-Approval Enabled checkbox
did not activate the Save button, making its behavior inconsistent with
other settings checkboxes.

The hybrid approach preserves the current UX where unchecking the box
immediately stops any active countdown timers, while also enabling the
Save button so users can confirm their changes.
@roomote
Copy link
Contributor Author

roomote bot commented Jan 15, 2026

Rooviewer Clock   See task on Roo Cloud

Review complete. No issues found.

The implementation correctly addresses issue #10745 by enabling the Save button when the "Auto-Approval Enabled" checkbox is toggled. The hybrid approach (updating both cached state and context state) is a reasonable design decision that preserves the safety behavior where disabling auto-approval immediately stops any active countdown timers.

Mention @roomote in a comment to request specific changes to this pull request or fix all unresolved issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Triage

Development

Successfully merging this pull request may close these issues.

[BUG] Auto-Approval Enabled checkbox located in the Auto-Approve settings tab

2 participants