feat: Shortcut key for nerd stats (#3552)
* added alt+/ as the shortcut key for nerd stats Signed-off-by: gurkiran_singh <gurkiransinghk@gmail.com> * added shortcut info in HelpDialog.ts Signed-off-by: gurkiran_singh <gurkiransinghk@gmail.com> * resolved conflicts Signed-off-by: gurkiran_singh <gurkiransinghk@gmail.com> * added shortcut info in HelpDialog.ts Signed-off-by: gurkiran_singh <gurkiransinghk@gmail.com>
This commit is contained in:
@ -1,4 +1,5 @@
|
||||
import { register } from "./register";
|
||||
import { CODES, KEYS } from "../keys";
|
||||
|
||||
export const actionToggleStats = register({
|
||||
name: "stats",
|
||||
@ -13,4 +14,6 @@ export const actionToggleStats = register({
|
||||
},
|
||||
checked: (appState) => appState.showStats,
|
||||
contextItemLabel: "stats.title",
|
||||
keyTest: (event) =>
|
||||
!event[KEYS.CTRL_OR_CMD] && event.altKey && event.code === CODES.SLASH,
|
||||
});
|
||||
|
@ -57,7 +57,7 @@ const shortcutMap: Record<ShortcutName, string[]> = {
|
||||
ungroup: [getShortcutKey("CtrlOrCmd+Shift+G")],
|
||||
gridMode: [getShortcutKey("CtrlOrCmd+'")],
|
||||
zenMode: [getShortcutKey("Alt+Z")],
|
||||
stats: [],
|
||||
stats: [getShortcutKey("Alt+/")],
|
||||
addToLibrary: [],
|
||||
flipHorizontal: [getShortcutKey("Shift+H")],
|
||||
flipVertical: [getShortcutKey("Shift+V")],
|
||||
|
Reference in New Issue
Block a user