fix: clearing the search box for setting node icons deletes nodes

fixes https://github.com/logseq/db-test/issues/62
This commit is contained in:
Tienson Qin
2024-09-10 00:30:18 +08:00
parent 8455c9419c
commit 1e70ed0ae5

View File

@@ -3118,13 +3118,15 @@
(defn shortcut-cut-selection
[e]
(util/stop e)
(cut-blocks-and-clear-selections! true))
(when-not (util/input? (.-target e))
(util/stop e)
(cut-blocks-and-clear-selections! true)))
(defn shortcut-delete-selection
[e]
(util/stop e)
(cut-blocks-and-clear-selections! false))
(when-not (util/input? (.-target e))
(util/stop e)
(cut-blocks-and-clear-selections! false)))
(defn- copy-current-block-ref
[format]