enhance(ux): render blocks by their orders (#11948)

* enhance: render nested children when rendering its parent

except that for long pages (500+ blocks).

* refactor: rename :block.temp/fully-loaded? to :block.temp/load-status

* fix: tests

* enhance: define keyword :block.temp/load-status

* update to :self

* chore: remove buggy parent cycle detect

* enhance(ux): don't delay rendering block properties

---------

Co-authored-by: rcmerci <rcmerci@gmail.com>
This commit is contained in:
Tienson Qin
2025-06-17 19:41:13 +08:00
committed by GitHub
parent ace71b2b25
commit 3b718f70c8
18 changed files with 128 additions and 149 deletions

View File

@@ -178,8 +178,7 @@
(util/mobile-keep-keyboard-open)
(let [repo (state/get-current-repo)]
(p/do!
(when-not (:block.temp/fully-loaded? (db/entity (:db/id block)))
(db-async/<get-block repo (:db/id block) {:children? false}))
(db-async/<get-block repo (:db/id block) {:children? false})
(when save-code-editor? (state/pub-event! [:editor/save-code-editor]))
(when (not= (:block/uuid block) (:block/uuid (state/get-edit-block)))
(state/clear-edit! {:clear-editing-block? false}))