| author | |
| committer | |
| log | 014016a62344ab03dbccdb73c3c1861bc4f7e349 |
| tree | b81d147843211ae0e19e8f6b9738d5f05719467b |
| parent | 9a49d6d5a656254d7079d463aa6ead5d62f4a3e6 |
| signature | Signed by PGP key B5690EEEBB952194 |
3 files changed, 11 insertions(+), 8 deletions(-)
apps/web/src/components/settings/KeybindingsSettings.logic.test.ts+9-6| ... | ... | @@ -37,12 +37,15 @@ describe("KeybindingsSettings.logic", () => { |
| 37 | 37 | }); |
| 38 | 38 | } |
| 39 | 39 | }); |
| 40 | it("finds the existing URL shortcut in Settings", () => { | |
| 41 | const rows = buildKeybindingRows(DEFAULT_RESOLVED_KEYBINDINGS, "PR URL"); | |
| 42 | expect(rows).toEqual([ | |
| 43 | expect.objectContaining({ command: "thread.copyReference", key: "mod+shift+c" }), | |
| 44 | ]); | |
| 45 | }); | |
| 40 | it.each(["pu", "pull request", "copy link", "thread id"])( | |
| 41 | "finds the copy link shortcut with %s", | |
| 42 | (query) => { | |
| 43 | const rows = buildKeybindingRows(DEFAULT_RESOLVED_KEYBINDINGS, query); | |
| 44 | expect(rows).toContainEqual( | |
| 45 | expect.objectContaining({ command: "thread.copyReference", key: "mod+shift+c" }), | |
| 46 | ); | |
| 47 | }, | |
| 48 | ); | |
| 46 | 49 | it("builds searchable rows with readable key and when values", () => { |
| 47 | 50 | const rows = buildKeybindingRows( |
| 48 | 51 | [ |
apps/web/src/components/settings/KeybindingsSettings.logic.ts+1-1| ... | ... | @@ -276,7 +276,7 @@ export function buildKeybindingCommandOptions( |
| 276 | 276 | } |
| 277 | 277 | |
| 278 | 278 | export function commandLabel(command: KeybindingCommand): string { |
| 279 | if (command === "thread.copyReference") return "Thread: Copy PR URL or Thread ID"; | |
| 279 | if (command === "thread.copyReference") return "Pull Request: Copy Link or Thread ID"; | |
| 280 | 280 | const raw = String(command); |
| 281 | 281 | if (raw.startsWith("script.") && raw.endsWith(".run")) { |
| 282 | 282 | return `Run Script: ${titleCaseCommandSegment(raw.slice("script.".length, -".run".length))}`; |
docs/user/keybindings.md+1-1| ... | ... | @@ -25,7 +25,7 @@ in Settings. |
| 25 | 25 | |
| 26 | 26 | With a PR open in the right panel or on the Pull Requests page, use `mod+shift+c` |
| 27 | 27 | to copy its URL and `mod+shift+k` to copy its number with a `#` prefix. |
| 28 | Both shortcuts can be changed in Settings. Search for “Copy PR URL or Thread ID” | |
| 28 | Both shortcuts can be changed in Settings. Search for “Copy Link or Thread ID” | |
| 29 | 29 | or “Copy Number”. They copy the selected PR and leave terminal input alone. |
| 30 | 30 | |
| 31 | 31 | ## Edit the configuration file |