0
Fork 0
mirror of https://github.com/penpot/penpot.git synced 2025-02-25 16:25:56 -05:00

🐛 Fix problem when reorder layers removes show in viewer

This commit is contained in:
alonso.torres 2023-03-30 16:15:19 +02:00
parent 532caea169
commit 64c0273554

View file

@ -664,7 +664,8 @@
(pcb/update-shapes ordered-indexes ctl/remove-layout-item-data))
;; Remove the hide in viewer flag
(pcb/update-shapes ordered-indexes #(cond-> % (cph/frame-shape? %) (assoc :hide-in-viewer true)))
(cond-> (and (not= uuid/zero parent-id) (cph/frame-shape? objects parent-id))
(pcb/update-shapes ordered-indexes #(cond-> % (cph/frame-shape? %) (assoc :hide-in-viewer true))))
;; Move the shapes
(pcb/change-parent parent-id