tui: retire /approvals and rename /autoreview to /approve (#21034)

## Why

The TUI currently exposes overlapping command names for the same
permissions flow: `/permissions` and the older `/approvals` alias. It
also uses `/autoreview` for the manual retry flow, even though the
action users take there is approving one denied auto-review request.

This change makes the command surface consistent with the hard rebrand:
- `/permissions` is the only command for permission settings.
- `/approve` is the command for approving a recent auto-review denial.

## What changed

- Removed the legacy `/approvals` slash command and its dispatch path.
- Kept `/permissions` as the single permissions command shown and
accepted by the TUI.
- Renamed the auto-review denial command from `/autoreview` to
`/approve`.
- Updated nearby comments so they refer to `/permissions` rather than
the retired `/approvals` name.

## Verification

- Updated the slash-command unit test to assert that `AutoReview` now
renders and parses as `approve`.
This commit is contained in:
Won Park authored and GitHub committed 2026-05-04 17:50:34 +00:00
1 parent 94800ecbbf
commit 5c1ec8f4fd
6 files changed
+12 -20

No files matched your search

+3 -3
View File
@@ -8120,7 +8120,7 @@ impl ChatWidget {
.send(AppEvent::PersistModelSelection { model, effort });
}
/// Open the permissions popup (alias for /permissions).
/// Open the permissions popup.
pub(crate) fn open_approvals_popup(&mut self) {
self.open_permissions_popup();
}
@@ -8693,8 +8693,8 @@ impl ChatWidget {
// new permission profile, so downstream policy-change hooks don't
// re-trigger the warning.
let mut accept_actions: Vec<SelectionAction> = Vec::new();
// Suppress the immediate re-scan only when a preset will be applied (i.e., via /approvals or
// /permissions), to avoid duplicate warnings from the ensuing policy change.
// Suppress the immediate re-scan only when a preset will be applied via
// /permissions, to avoid duplicate warnings from the ensuing policy change.
if preset.is_some() {
accept_actions.push(Box::new(|tx| {
tx.send(AppEvent::SkipNextWorldWritableScan);