mirror of
https://github.com/penpot/penpot.git
synced 2025-03-10 06:41:40 -05:00
♻️ Components refactor: generator for sync head
This commit is contained in:
parent
37e68249aa
commit
f3220fa985
2 changed files with 10 additions and 3 deletions
|
@ -2046,3 +2046,12 @@
|
|||
(-> changes
|
||||
(generate-new-shape-for-swap shape file page libraries id-new-component index target-cell keep-props-values))]
|
||||
[new-shape all-parents changes]))
|
||||
|
||||
(defn generate-sync-head
|
||||
[changes file-full libraries container head components-v2]
|
||||
(let [changes
|
||||
(-> changes
|
||||
(pcb/with-container container)
|
||||
(pcb/with-objects (:objects container))
|
||||
(generate-sync-shape-direct file-full libraries container (:id head) false components-v2))]
|
||||
changes))
|
|
@ -695,9 +695,7 @@
|
|||
|
||||
changes
|
||||
(-> (pcb/empty-changes it)
|
||||
(pcb/with-container container)
|
||||
(pcb/with-objects (:objects container))
|
||||
(cflh/generate-sync-shape-direct file-full libraries container (:id head) false components-v2))]
|
||||
(cflh/generate-sync-head file-full libraries container head components-v2))]
|
||||
|
||||
(log/debug :msg "SYNC-head finished" :js/rchanges (log-changes
|
||||
(:redo-changes changes)
|
||||
|
|
Loading…
Add table
Reference in a new issue