mirror of
https://github.com/openai/codex.git
synced 2026-11-19 23:05:23 +00:00
Add a TUI user verification prompt component (#43702)
## What changed Add a presentation-only `UserVerificationView` with explicit verify and cancel choices, request details, and a waiting state. Report decisions through a callback, suppress duplicate approvals while waiting, and allow cancellation before or during verification. Dismiss the view when its matching MCP elicitation request resolves. Add a full-screen request details overlay that can be opened without making a decision. Wrap prompt text and long URLs for narrow terminals. The view is not yet connected to incoming verification requests. ## Testing Add tests and snapshots covering prompt and waiting rendering, narrow layouts, long URLs, duplicate approval suppression, cancellation, matching request dismissal, and full-screen inspection and scrolling. GitOrigin-RevId: de1ff80d0defb3707b641e9bfccff9e2b91255ec
This commit is contained in:
1 parent
6b6fdc3572
commit
54e04f25db
10 files changed
+618
No files matched your search
@@ -2983,6 +2983,14 @@ impl App {
|
||||
AppEvent::ManageSkillsClosed => {
|
||||
self.chat_widget.handle_manage_skills_closed();
|
||||
}
|
||||
AppEvent::FullScreenUserVerificationRequest(request) => {
|
||||
let _ = tui.enter_alt_screen();
|
||||
self.overlay = Some(Overlay::new_static_with_renderables(
|
||||
vec![crate::bottom_pane::user_verification::prompt_header(&request)],
|
||||
"U S E R V E R I F I C A T I O N".to_string(),
|
||||
self.keymap.pager.clone(),
|
||||
));
|
||||
}
|
||||
AppEvent::FullScreenApprovalRequest(request) => match request {
|
||||
ApprovalRequest::ApplyPatch(request) => {
|
||||
let _ = tui.enter_alt_screen();
|
||||
|
||||
Reference in new issue
Block a user