mirror of
https://github.com/penpot/penpot.git
synced 2025-02-12 18:18:24 -05:00
✨ Navigate automatically to new created file
This commit is contained in:
parent
87fc2db78a
commit
e4afda08d7
1 changed files with 7 additions and 1 deletions
|
@ -364,7 +364,13 @@
|
|||
recent-project-files (get-in state [:recent-file-ids project-id] [])]
|
||||
(-> state
|
||||
(assoc-in [:files file-id] data)
|
||||
(assoc-in [:recent-file-ids project-id] (conj recent-project-files file-id)))))))
|
||||
(assoc-in [:recent-file-ids project-id] (conj recent-project-files file-id)))))
|
||||
|
||||
ptk/WatchEvent
|
||||
(watch [_ state stream]
|
||||
(rx/of (rt/nav :workspace {:project-id (:project-id data)
|
||||
:file-id (:id data)}
|
||||
{:page-id (first (:pages data))})))))
|
||||
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
|
|
Loading…
Add table
Reference in a new issue