-
Notifications
You must be signed in to change notification settings - Fork 634
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
feat: add command to switch mode #1120
base: main
Are you sure you want to change the base?
Conversation
|
"win": "ctrl+.", | ||
"linux": "ctrl+.", | ||
"mac": "cmd+.", | ||
"when": "true" |
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.
The new keybinding for 'roo-cline.cycleModes' is registered with a universal condition ('when': 'true'). Consider refining the condition (e.g. checking for an active editor or focused window) to avoid accidental triggering in contexts where switching modes isn’t applicable.
"when": "true" | |
"when": "editorTextFocus" |
c8985fe
to
71bdc7e
Compare
Thanks @aheizi! I fixed the conflicts and pushed a change to find the current mode in the list before cycling. Hope you don't mind! |
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.
Er, I just realized that this gets in the way of the previous cmd + . behavior when you have selected text in the editor. Do you know if there's a way to only apply this when the extension is in focus?
okey, I'll try it right now |
emmm, I tried some methods, but they didn't work, I'll try again later. |
|
Great! Thanks for digging in. |
Please take a look at this PR: #1270 |
Description
Feature: add command to switch mode
When I'm developing with roo-code, I often need to switch between different modes. Clicking the select box is somewhat inconvenient for me, and I hope there could be a better way to help me switch modes. When I learned that the new version of Cursor added a
Cmd + .
shortcut to switch modes, I was excited and wanted to add this functionality to roo-code as well.Type of change
How Has This Been Tested?
Manual testing
Checklist:
Additional context
roo-code-add-cmd-switch-mode.mov
Related Issues
Reviewers
Important
Add
cycleModes
command and keyboard shortcut to switch modes in Roo Code, integrating it with theChatView
component.cycleModes
command inpackage.json
to switch modes.cycleModes
command insrc/commands/mode-switching.ts
.cycleModes
inpackage.json
.src/extension.ts
.mode
messages inwebview-ui/src/App.tsx
to switch to chat tab and callswitchMode
.switchMode
method toChatView
inwebview-ui/src/components/chat/ChatView.tsx
to update mode and send message to VSCode.This description was created by
for 867d5e0. It will automatically update as commits are pushed.