We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9df740c commit 33e34abCopy full SHA for 33e34ab
1 file changed
src/main/frontend/handler/editor.cljs
@@ -3853,10 +3853,11 @@
3853
3854
(defn toggle-open-block-children! [block-id]
3855
(p/let [blocks (<all-blocks-with-level {:incremental? false
3856
- :collapse? true
+ :expanded? true
3857
:root-block block-id})
3858
- all-expanded? (empty? blocks)]
3859
- (if all-expanded?
+ children-blocks (remove #(= block-id (:block/uuid %)) blocks)
+ any-expanded? (seq (filter (complement util/collapsed?) children-blocks))]
3860
+ (if any-expanded?
3861
(collapse-all! block-id {:collapse-self? false})
3862
(expand-all! block-id))))
3863
0 commit comments