mirror of
https://github.com/penpot/penpot.git
synced 2026-05-02 22:58:35 +00:00
🐛 Fix libraries dashboard view
This commit is contained in:
parent
1a831eddc5
commit
18acc7c7c8
@ -256,13 +256,14 @@
|
||||
(update :dashboard-files d/merge files))))))
|
||||
|
||||
(defn fetch-shared-files
|
||||
[]
|
||||
(ptk/reify ::fetch-shared-files
|
||||
ptk/WatchEvent
|
||||
(watch [_ state _]
|
||||
(let [team-id (:current-team-id state)]
|
||||
(->> (rp/cmd! :get-team-shared-files {:team-id team-id})
|
||||
(rx/map shared-files-fetched))))))
|
||||
([] (fetch-shared-files nil))
|
||||
([team-id]
|
||||
(ptk/reify ::fetch-shared-files
|
||||
ptk/WatchEvent
|
||||
(watch [_ state _]
|
||||
(let [team-id (or team-id (:current-team-id state))]
|
||||
(->> (rp/cmd! :get-team-shared-files {:team-id team-id})
|
||||
(rx/map shared-files-fetched)))))))
|
||||
|
||||
;; --- EVENT: recent-files
|
||||
|
||||
|
||||
@ -46,7 +46,7 @@
|
||||
(dom/set-html-title (tr "title.dashboard.shared-libraries" tname)))))
|
||||
|
||||
(mf/with-effect []
|
||||
(st/emit! (dd/fetch-shared-files)
|
||||
(st/emit! (dd/fetch-shared-files (:id team))
|
||||
(dd/clear-selected-files)))
|
||||
|
||||
(if new-css-system
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user