enhance(pdf): UI lag for the case of large highlights data

This commit is contained in:
charlie
2023-03-06 17:51:39 +08:00
committed by Tienson Qin
parent e52bda80c9
commit 22dfa621e4
3 changed files with 9 additions and 6 deletions

View File

@@ -844,8 +844,10 @@
(when (= :completed (:status loader-state))
(p/catch
(when-not (:error hls-state)
(pdf-assets/persist-hls-data$
pdf-current (:latest-hls hls-state) (:extra hls-state)))
(p/do!
(p/delay 100)
(pdf-assets/persist-hls-data$
pdf-current (:latest-hls hls-state) (:extra hls-state))))
;; write hls file error
(fn [e]