mirror of
https://github.com/logseq/logseq.git
synced 2026-05-04 10:56:32 +00:00
enhance: improve performance for rendering
Also, simplify the state for expand/collapse.
This commit is contained in:
@@ -1948,16 +1948,12 @@
|
||||
(defn expand!
|
||||
[]
|
||||
(when-let [current-block (state/get-edit-block)]
|
||||
(expand/expand! current-block)
|
||||
(state/set-collapsed-state! (:block/uuid current-block)
|
||||
false)))
|
||||
(expand/expand! current-block)))
|
||||
|
||||
(defn collapse!
|
||||
[]
|
||||
(when-let [current-block (state/get-edit-block)]
|
||||
(expand/collapse! current-block)
|
||||
(state/set-collapsed-state! (:block/uuid current-block)
|
||||
true)))
|
||||
(expand/collapse! current-block)))
|
||||
|
||||
(defn cycle-collapse!
|
||||
[e]
|
||||
|
||||
Reference in New Issue
Block a user