doc
This commit is contained in:
1 parent
bd99acdb5b
commit
907508614c
3 files changed
+7
-21
No files matched your search
+3
-2
@@ -23,8 +23,9 @@ See the full schema for more details: [`packages/contracts/src/keybindings.ts`](
|
||||
{ "key": "mod+d", "command": "terminal.split", "when": "terminalFocus" },
|
||||
{ "key": "mod+n", "command": "terminal.new", "when": "terminalFocus" },
|
||||
{ "key": "mod+w", "command": "terminal.close", "when": "terminalFocus" },
|
||||
{ "key": "mod+shift+o", "command": "chat.new" },
|
||||
{ "key": "mod+shift+n", "command": "chat.newLocal" },
|
||||
{ "key": "mod+n", "command": "chat.new", "when": "!terminalFocus" },
|
||||
{ "key": "mod+shift+o", "command": "chat.new", "when": "!terminalFocus" },
|
||||
{ "key": "mod+shift+n", "command": "chat.newLocal", "when": "!terminalFocus" },
|
||||
{ "key": "mod+o", "command": "editor.openFavorite" }
|
||||
]
|
||||
```
|
||||
|
||||
@@ -1,10 +1,6 @@
|
||||
import { assert, describe, it } from "vitest";
|
||||
|
||||
import {
|
||||
DEFAULT_KEYBINDINGS,
|
||||
compileResolvedKeybindingRule,
|
||||
parseKeybindingShortcut,
|
||||
} from "./keybindings";
|
||||
import { compileResolvedKeybindingRule, parseKeybindingShortcut } from "./keybindings";
|
||||
|
||||
describe("server keybindings", () => {
|
||||
it("parses shortcuts including plus key", () => {
|
||||
@@ -70,16 +66,4 @@ describe("server keybindings", () => {
|
||||
}),
|
||||
);
|
||||
});
|
||||
|
||||
it("defines defaults for terminal.close and chat.newLocal", () => {
|
||||
assert.deepInclude(DEFAULT_KEYBINDINGS, {
|
||||
key: "mod+w",
|
||||
command: "terminal.close",
|
||||
when: "terminalFocus",
|
||||
});
|
||||
assert.deepInclude(DEFAULT_KEYBINDINGS, {
|
||||
key: "mod+shift+n",
|
||||
command: "chat.newLocal",
|
||||
});
|
||||
});
|
||||
});
|
||||
@@ -29,8 +29,9 @@ export const DEFAULT_KEYBINDINGS: ReadonlyArray<KeybindingRule> = [
|
||||
{ key: "mod+d", command: "terminal.split", when: "terminalFocus" },
|
||||
{ key: "mod+n", command: "terminal.new", when: "terminalFocus" },
|
||||
{ key: "mod+w", command: "terminal.close", when: "terminalFocus" },
|
||||
{ key: "mod+shift+o", command: "chat.new" },
|
||||
{ key: "mod+shift+n", command: "chat.newLocal" },
|
||||
{ key: "mod+n", command: "chat.new", when: "!terminalFocus" },
|
||||
{ key: "mod+shift+o", command: "chat.new", when: "!terminalFocus" },
|
||||
{ key: "mod+shift+n", command: "chat.newLocal", when: "!terminalFocus" },
|
||||
{ key: "mod+o", command: "editor.openFavorite" },
|
||||
];
|
||||
|
||||
|
||||
Reference in new issue
Block a user