mirror of
https://github.com/logseq/logseq.git
synced 2026-05-03 10:26:35 +00:00
fix: delete blocks when zoom in doesn't work
This commit is contained in:
@@ -1053,7 +1053,7 @@
|
||||
(defn copy-selection-blocks
|
||||
[]
|
||||
(when-let [blocks (seq (get-selected-blocks-with-children))]
|
||||
(let [repo (dom/attr (first blocks) "repo")
|
||||
(let [repo (state/get-current-repo)
|
||||
ids (->> (distinct (map #(when-let [id (dom/attr % "blockid")]
|
||||
(uuid id)) blocks))
|
||||
(remove nil?))
|
||||
@@ -1070,7 +1070,7 @@
|
||||
;; remove embeds and references
|
||||
(let [blocks (remove (fn [block] (= "true" (dom/attr block "data-transclude"))) blocks)]
|
||||
(when (seq blocks)
|
||||
(let [repo (dom/attr (first blocks) "repo")
|
||||
(let [repo (state/get-current-repo)
|
||||
ids (distinct (map #(uuid (dom/attr % "blockid")) blocks))]
|
||||
(delete-blocks! repo ids))))))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user