Vim shortcut (#279)
* Allow VIM navigation shortcuts without VIM mode enabled in Obsidian * Default value for vim navigation keys --------- Co-authored-by: Neil-Chen <v009008777@hotmail.com>
This commit is contained in:
@@ -38,7 +38,7 @@ abstract class OmnisearchModal extends Modal {
|
||||
] as const) {
|
||||
for (const modifier of ['Ctrl', 'Mod'] as const) {
|
||||
this.scope.register([modifier], key.k, _e => {
|
||||
if (this.app.vault.getConfig('vimMode')) {
|
||||
if (settings.vimLikeNavigationShortcut) {
|
||||
// e.preventDefault()
|
||||
eventBus.emit('arrow-' + key.dir)
|
||||
}
|
||||
@@ -53,7 +53,7 @@ abstract class OmnisearchModal extends Modal {
|
||||
] as const) {
|
||||
for (const modifier of ['Ctrl', 'Mod'] as const) {
|
||||
this.scope.register([modifier], key.k, _e => {
|
||||
if (this.app.vault.getConfig('vimMode')) {
|
||||
if (settings.vimLikeNavigationShortcut) {
|
||||
// e.preventDefault()
|
||||
eventBus.emit('arrow-' + key.dir)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user