refactor(editor): fix on-key-down mixin

Add both explicit options:
1. :not-match-handler
2. :all-handler
This commit is contained in:
Tienson Qin
2020-12-02 11:08:50 +08:00
parent eb651cfe81
commit 8b165c89a5
5 changed files with 104 additions and 116 deletions

View File

@@ -294,9 +294,7 @@
(when-let [repo-url (state/get-current-repo)]
(when-not (state/get-edit-input-id)
(util/stop e)
(state/set-modal! commit/add-commit-message)))))}
(fn [e key-code]
nil))))
(state/set-modal! commit/add-commit-message)))))})))
{:did-mount (fn [state]
(keyboards/bind-shortcuts!)
state)}
@@ -359,4 +357,4 @@
;; :on-click (fn []
;; (state/set-left-sidebar-open! (not (state/get-left-sidebar-open?))))}
;; (if (state/sub :ui/left-sidebar-open?) "<" ">")]
)])))
)])))