-
Notifications
You must be signed in to change notification settings - Fork 36.8k
add a command to toggle between todos and chat input #283134
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR adds a command to toggle focus between the agent TODOs view and the chat input, addressing issue #281597. The implementation adds new methods across multiple layers of the chat widget architecture to support focusing and checking the state of the TODO list widget.
Key Changes
- Added a new F1 command "Agent TODOs: Focus on Todos View" that toggles focus between the TODOs view and chat input
- Implemented focus management methods across ChatTodoListWidget, ChatInputPart, and ChatWidget
- Added comprehensive tests for the new focus and visibility checking functionality
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| src/vs/workbench/contrib/chat/browser/chat.ts | Added focusTodosView() and toggleTodosViewFocus() methods to IChatWidget interface |
| src/vs/workbench/contrib/chat/browser/chatWidget.ts | Implemented the new interface methods to delegate todo list focus operations to the input part |
| src/vs/workbench/contrib/chat/browser/chatInputPart.ts | Added helper methods to check and control todo list focus and visibility state |
| src/vs/workbench/contrib/chat/browser/chatContentParts/chatTodoListWidget.ts | Implemented core focus management: hasTodos(), hasFocus(), and focus() methods |
| src/vs/workbench/contrib/chat/browser/actions/chatActions.ts | Registered new command with preconditions for agent chat mode and imported aria alert utility |
| src/vs/workbench/contrib/chat/browser/actions/chatAccessibilityHelp.ts | Added accessibility help text explaining the new toggle focus command |
| src/vs/workbench/contrib/chat/test/browser/chatTodoListWidget.test.ts | Added tests for focus expansion behavior and hasTodos() visibility reporting |
src/vs/workbench/contrib/chat/browser/actions/chatAccessibilityHelp.ts
Outdated
Show resolved
Hide resolved
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…yHelp.ts Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
fixes #281597
todos.mov