mirror of
https://github.com/openai/codex.git
synced 2026-11-25 15:24:26 +00:00
Sync collaboration mode naming across Default prompt, tools, and TUI (#10666)
## Summary
- add shared `ModeKind` helpers for display names, TUI visibility, and
`request_user_input` availability
- derive TUI mode filtering/labels from shared `ModeKind` metadata
instead of local hardcoded matches
- derive `request_user_input` availability text and unavailable error
mode names from shared mode metadata
- replace hardcoded known mode names in the Default collaboration-mode
template with `{{KNOWN_MODE_NAMES}}` and fill it from
`TUI_VISIBLE_COLLABORATION_MODES`
- add regression tests for mode metadata sync and placeholder
replacement
## Notes
- `cargo test -p codex-core` integration target (`tests/all`) still
shows pre-existing env-specific failures in this environment due missing
`test_stdio_server` binary resolution; core unit tests are green.
## Codex author
`codex resume 019c26ff-dfe7-7173-bc04-c9e1fff1e447`
This commit is contained in:
1 parent
e482978261
commit
41b4962b0a
6 files changed
+125
-55
No files matched your search
@@ -5490,11 +5490,10 @@ impl ChatWidget {
|
||||
if !self.collaboration_modes_enabled() {
|
||||
return None;
|
||||
}
|
||||
match self.active_mode_kind() {
|
||||
ModeKind::Plan => Some("Plan"),
|
||||
ModeKind::Default => Some("Default"),
|
||||
ModeKind::PairProgramming | ModeKind::Execute => None,
|
||||
}
|
||||
let active_mode = self.active_mode_kind();
|
||||
active_mode
|
||||
.is_tui_visible()
|
||||
.then_some(active_mode.display_name())
|
||||
}
|
||||
|
||||
fn collaboration_mode_indicator(&self) -> Option<CollaborationModeIndicator> {
|
||||
|
||||
Reference in new issue
Block a user