
To use this, spawn `weclome: toggle base keymap selector` from the command palette. <img width="589" alt="Screenshot 2025-05-29 at 14 07 35" src="https://github.com/user-attachments/assets/0d4c4eff-6a3b-40f4-9032-5d8ca7664d20" /> MacOS is well tested to match Cursor. The [curors keymap documentation](https://docs.cursor.com/kbd) is does not explicitly state windows/linux keymap entries only "All Cmd keys can be replaced with Ctrl on Windows." so that is what we've done. We welcome feedback / refinements. Note, because this provides a mapping for `cmd-k` (macos) and `ctrl-k` (linux/windows) using this keymap will disable all of the default chorded keymap entries which have `cmd-k` / `ctrl-k` as a prefix. For example `cmd-k cmd-s` for open keymap will no longer function. Release Notes: - Added Cursor compatibility keymap --------- Co-authored-by: Joseph Lyons <joseph@zed.dev>
85 lines
2.7 KiB
JSON
85 lines
2.7 KiB
JSON
[
|
|
// Cursor for MacOS. See: https://docs.cursor.com/kbd
|
|
{
|
|
"context": "Workspace",
|
|
"use_key_equivalents": true,
|
|
"bindings": {
|
|
"cmd-i": "agent::ToggleFocus",
|
|
"cmd-shift-i": "agent::ToggleFocus",
|
|
"cmd-l": "agent::ToggleFocus",
|
|
"cmd-shift-l": "agent::ToggleFocus",
|
|
"cmd-alt-b": "agent::ToggleFocus",
|
|
"cmd-shift-j": "agent::OpenConfiguration"
|
|
}
|
|
},
|
|
{
|
|
"context": "Editor && mode == full",
|
|
"use_key_equivalents": true,
|
|
"bindings": {
|
|
"cmd-i": "agent::ToggleFocus",
|
|
"cmd-shift-i": "agent::ToggleFocus",
|
|
"cmd-shift-l": "assistant::QuoteSelection", // In cursor uses "Ask" mode
|
|
"cmd-l": "assistant::QuoteSelection", // In cursor uses "Agent" mode
|
|
"cmd-k": "assistant::InlineAssist",
|
|
"cmd-shift-k": "assistant::InsertIntoEditor"
|
|
}
|
|
},
|
|
{
|
|
"context": "InlineAssistEditor",
|
|
"use_key_equivalents": true,
|
|
"bindings": {
|
|
"cmd-shift-backspace": "editor::Cancel"
|
|
// "alt-enter": // Quick Question
|
|
// "cmd-shift-enter": // Full File Context
|
|
// "cmd-shift-k": // Toggle input focus (editor <> inline assist)
|
|
}
|
|
},
|
|
{
|
|
"context": "AgentPanel || ContextEditor || (MessageEditor > Editor)",
|
|
"use_key_equivalents": true,
|
|
"bindings": {
|
|
"cmd-i": "workspace::ToggleRightDock",
|
|
"cmd-shift-i": "workspace::ToggleRightDock",
|
|
"cmd-l": "workspace::ToggleRightDock",
|
|
"cmd-shift-l": "workspace::ToggleRightDock",
|
|
"cmd-alt-b": "workspace::ToggleRightDock",
|
|
"cmd-w": "workspace::ToggleRightDock", // technically should close chat
|
|
"cmd-.": "agent::ToggleProfileSelector",
|
|
"cmd-/": "agent::ToggleModelSelector",
|
|
"cmd-shift-backspace": "editor::Cancel",
|
|
"cmd-r": "agent::NewThread",
|
|
"cmd-shift-v": "editor::Paste",
|
|
"cmd-shift-k": "assistant::InsertIntoEditor"
|
|
// "escape": "agent::ToggleFocus"
|
|
///// Enable when Zed supports multiple thread tabs
|
|
// "cmd-t": // new thread tab
|
|
// "cmd-[": // next thread tab
|
|
// "cmd-]": // next thread tab
|
|
///// Enable if Zed adds support for keyboard navigation of thread elements
|
|
// "tab": // cycle to next message
|
|
// "shift-tab": // cycle to previous message
|
|
}
|
|
},
|
|
{
|
|
"context": "Editor && editor_agent_diff",
|
|
"use_key_equivalents": true,
|
|
"bindings": {
|
|
"cmd-enter": "agent::KeepAll",
|
|
"cmd-backspace": "agent::RejectAll"
|
|
}
|
|
},
|
|
{
|
|
"context": "Editor && mode == full && edit_prediction",
|
|
"use_key_equivalents": true,
|
|
"bindings": {
|
|
"cmd-right": "editor::AcceptPartialEditPrediction"
|
|
}
|
|
},
|
|
{
|
|
"context": "Terminal",
|
|
"use_key_equivalents": true,
|
|
"bindings": {
|
|
"cmd-k": "assistant::InlineAssist"
|
|
}
|
|
}
|
|
]
|