mirror of
https://github.com/penpot/penpot.git
synced 2025-07-21 21:37:12 +02:00
💄 Add cosmetic changes to duplicate-page function
This commit is contained in:
parent
64cef9bb7d
commit
541a372f01
1 changed files with 7 additions and 5 deletions
|
@ -449,10 +449,12 @@
|
||||||
page (get-in state [:workspace-data :pages-index page-id])
|
page (get-in state [:workspace-data :pages-index page-id])
|
||||||
name (cp/generate-unique-name unames (:name page))
|
name (cp/generate-unique-name unames (:name page))
|
||||||
|
|
||||||
no_thumbnails_objects (->> (:objects page)
|
page (-> page
|
||||||
(d/mapm (fn [_ val] (dissoc val :use-for-thumbnail?))))
|
(assoc :name name)
|
||||||
|
(assoc :id id)
|
||||||
page (-> page (assoc :name name :id id :objects no_thumbnails_objects))
|
(assoc :objects
|
||||||
|
(->> (:objects page)
|
||||||
|
(d/mapm (fn [_ val] (dissoc val :use-for-thumbnail?))))))
|
||||||
|
|
||||||
changes (-> (pcb/empty-changes it)
|
changes (-> (pcb/empty-changes it)
|
||||||
(pcb/add-page id page))]
|
(pcb/add-page id page))]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue