enhance: cycle todos support cmd+enter too

Also, it keeps the selection state after triggered
This commit is contained in:
Tienson Qin
2021-11-16 15:15:16 +08:00
parent 955648beeb
commit 1c78fdc245
2 changed files with 38 additions and 35 deletions

View File

@@ -117,10 +117,6 @@
{:desc "New line in current block"
:binding "shift+enter"
:fn editor-handler/keydown-new-line-handler}
:editor/cycle-todo
{:desc "Rotate the TODO state of the current item"
:binding "mod+enter"
:fn editor-handler/cycle-todo!}
:editor/follow-link
{:desc "Follow link under cursor"
:binding "mod+o"
@@ -196,7 +192,11 @@
:shortcut.handler/editor-global
^{:before m/enable-when-not-component-editing!}
{:editor/up
{:editor/cycle-todo
{:desc "Rotate the TODO state of the current item"
:binding "mod+enter"
:fn editor-handler/cycle-todo!}
:editor/up
{:desc "Move cursor up / Select up"
:binding "up"
:fn (editor-handler/shortcut-up-down :up)}