mirror of
https://github.com/penpot/penpot.git
synced 2025-06-09 16:11:38 +02:00
Merge pull request #2749 from penpot/hiru-fix-ghost-sync
🐛 Fix ghost shapes after sync groups in components
This commit is contained in:
commit
35aa391129
2 changed files with 24 additions and 19 deletions
|
@ -39,6 +39,7 @@
|
||||||
- Fix group/ungroup shapes inside a component [Taiga #4052](https://tree.taiga.io/project/penpot/issue/4052)
|
- Fix group/ungroup shapes inside a component [Taiga #4052](https://tree.taiga.io/project/penpot/issue/4052)
|
||||||
- Fix wrong update of text in components [Taiga #4646](https://tree.taiga.io/project/penpot/issue/4646)
|
- Fix wrong update of text in components [Taiga #4646](https://tree.taiga.io/project/penpot/issue/4646)
|
||||||
- Fix problem with SVG imports with style [#2605](https://github.com/penpot/penpot/issues/2605)
|
- Fix problem with SVG imports with style [#2605](https://github.com/penpot/penpot/issues/2605)
|
||||||
|
- Fix ghost shapes after sync groups in components [Taiga #4649](https://tree.taiga.io/project/penpot/issue/4649)
|
||||||
|
|
||||||
## 1.16.2-beta
|
## 1.16.2-beta
|
||||||
|
|
||||||
|
|
|
@ -915,6 +915,15 @@
|
||||||
parents (cph/get-parent-ids objects (:id shape))
|
parents (cph/get-parent-ids objects (:id shape))
|
||||||
parent (first parents)
|
parent (first parents)
|
||||||
children (cph/get-children-ids objects (:id shape))
|
children (cph/get-children-ids objects (:id shape))
|
||||||
|
ids (into [(:id shape)] children)
|
||||||
|
|
||||||
|
add-redo-change (fn [changes id]
|
||||||
|
(update changes :redo-changes conj
|
||||||
|
(make-change
|
||||||
|
container
|
||||||
|
{:type :del-obj
|
||||||
|
:id id
|
||||||
|
:ignore-touched true})))
|
||||||
|
|
||||||
add-undo-change (fn [changes id]
|
add-undo-change (fn [changes id]
|
||||||
(let [shape' (get objects id)]
|
(let [shape' (get objects id)]
|
||||||
|
@ -931,12 +940,7 @@
|
||||||
(:frame-id shape')
|
(:frame-id shape')
|
||||||
(assoc :frame-id (:frame-id shape'))))))))
|
(assoc :frame-id (:frame-id shape'))))))))
|
||||||
|
|
||||||
changes' (-> changes
|
changes' (-> (reduce add-redo-change changes ids)
|
||||||
(update :redo-changes conj (make-change
|
|
||||||
container
|
|
||||||
{:type :del-obj
|
|
||||||
:id (:id shape)
|
|
||||||
:ignore-touched true}))
|
|
||||||
(update :redo-changes conj (make-change
|
(update :redo-changes conj (make-change
|
||||||
container
|
container
|
||||||
{:type :reg-objects
|
{:type :reg-objects
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue