Skip to content

Conversation

@roomote
Copy link
Contributor

@roomote roomote bot commented Jul 22, 2025

This PR fixes a critical safety issue where the auto-approve checkbox becomes unresponsive when the dropdown menu is expanded, preventing users from disabling auto-approval during model responses.

Fixes #6060

Changes

  • Removed isExpanded from the checkbox disabled condition to allow toggling while menu is open
  • Wrapped onChange handler in useCallback to prevent unnecessary re-renders
  • Added tests to verify checkbox remains responsive when menu is expanded
  • Added test to verify no flickering during rapid state changes

Safety Impact

This fix ensures users can always disable auto-approval when needed, which is critical for preventing unintended actions during model responses.


Important

Fixes unresponsive auto-approve checkbox in AutoApproveMenu.tsx when menu is expanded, ensuring it remains responsive and prevents unintended actions.

  • Behavior:
    • Fixes unresponsive auto-approve checkbox in AutoApproveMenu.tsx when dropdown is expanded by removing isExpanded from disabled condition.
    • Wraps onChange handler in useCallback to prevent unnecessary re-renders.
  • Tests:
    • Adds tests in AutoApproveMenu.spec.tsx to verify checkbox remains responsive when menu is expanded.
    • Adds test to ensure no flickering during rapid state changes.

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

- Remove isExpanded from checkbox disabled condition to allow toggling while menu is open
- Wrap onChange handler in useCallback to prevent unnecessary re-renders
- Add tests to verify checkbox remains responsive when menu is expanded
- Add test to verify no flickering during rapid state changes

This fixes the critical safety issue where users could not disable auto-approval
during model responses when they realized unintended actions were about to occur.

Fixes #6060
@roomote roomote bot requested review from cte, jr and mrubens as code owners July 22, 2025 09:30
@hannesrudolph hannesrudolph added the Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels. label Jul 22, 2025
@dosubot dosubot bot added size:L This PR changes 100-499 lines, ignoring generated files. bug Something isn't working labels Jul 22, 2025
@daniel-lxs
Copy link
Member

Closing, handled by #6061

@daniel-lxs daniel-lxs closed this Jul 23, 2025
@github-project-automation github-project-automation bot moved this from Triage to Done in Roo Code Roadmap Jul 23, 2025
@github-project-automation github-project-automation bot moved this from New to Done in Roo Code Roadmap Jul 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels. size:L This PR changes 100-499 lines, ignoring generated files.

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

Regression: Auto-approve checkbox becomes unresponsive and flickers during model responses

4 participants