0
Fork 0
mirror of https://github.com/penpot/penpot.git synced 2025-03-15 17:21:17 -05:00

🐛 Preserve root shape position on parent when create component

This commit is contained in:
Andrés Moya 2023-06-02 17:57:21 +02:00
parent 8c3f90fe36
commit bca90c54e9

View file

@ -90,7 +90,7 @@
(cond-> (nil? index)
(pcb/add-object shape))
(cond-> (some? (:parent-id attrs))
(pcb/change-parent (:parent-id attrs) [shape]))
(pcb/change-parent (:parent-id attrs) [shape] index))
(cond-> (ctl/grid-layout? objects (:parent-id shape))
(pcb/update-shapes [(:parent-id shape)] ctl/assign-cells)))]