mirror of
https://github.com/penpot/penpot.git
synced 2026-08-30 00:29:17 +00:00
🐛 Run post-font text relayout after pending fetches finish
Move relayout-after-fonts! from rx/subs! on-next to on-complete so font and image callbacks are not relayouted on every concat emission.
This commit is contained in:
parent
b0223ac0e5
commit
30e700a07e
@ -1706,11 +1706,12 @@
|
||||
(rx/reduce conj [])
|
||||
(rx/catch #(rx/empty))))
|
||||
(rx/subs!
|
||||
(fn [_]
|
||||
(relayout-after-fonts! shapes font-pending-ids)
|
||||
(request-render "images-loaded"))
|
||||
noop-fn
|
||||
(fn [] (when (fn? on-complete) (on-complete)))))
|
||||
noop-fn
|
||||
(fn []
|
||||
(relayout-after-fonts! shapes font-pending-ids)
|
||||
(request-render "images-loaded")
|
||||
(when (fn? on-complete) (on-complete)))))
|
||||
;; No pending images — complete immediately.
|
||||
(when on-complete (on-complete)))))
|
||||
|
||||
@ -1857,11 +1858,11 @@
|
||||
(if (fn? callback) (callback) (rx/empty))))
|
||||
(rx/reduce conj [])))
|
||||
(rx/subs!
|
||||
(fn [_]
|
||||
(relayout-after-fonts! shapes font-pending-acc)
|
||||
(request-render "images-loaded"))
|
||||
noop-fn
|
||||
noop-fn)))))))))]
|
||||
noop-fn
|
||||
(fn []
|
||||
(relayout-after-fonts! shapes font-pending-acc)
|
||||
(request-render "images-loaded")))))))))))]
|
||||
(process-next-chunk 0 [] [] []))))))
|
||||
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user