mirror of
https://github.com/penpot/penpot.git
synced 2025-05-02 23:05:53 +02:00
💄 Small refactor
This commit is contained in:
parent
cf4ef426d7
commit
cb73ddc353
2 changed files with 18 additions and 36 deletions
|
@ -33,12 +33,10 @@
|
||||||
copy-child (ths/get-shape file :copy-child)
|
copy-child (ths/get-shape file :copy-child)
|
||||||
|
|
||||||
;; ==== Action
|
;; ==== Action
|
||||||
update-fn (fn [shape]
|
|
||||||
(assoc shape :fills (ths/sample-fills-color :fill-color "#fabada")))
|
|
||||||
|
|
||||||
changes (cls/generate-update-shapes (pcb/empty-changes nil (:id page))
|
changes (cls/generate-update-shapes (pcb/empty-changes nil (:id page))
|
||||||
#{(:id copy-child)}
|
#{(:id copy-child)}
|
||||||
update-fn
|
(fn [shape]
|
||||||
|
(assoc shape :fills (ths/sample-fills-color :fill-color "#fabada")))
|
||||||
(:objects page)
|
(:objects page)
|
||||||
{})
|
{})
|
||||||
|
|
||||||
|
@ -86,12 +84,10 @@
|
||||||
copy-child (ths/get-shape file :copy-child)
|
copy-child (ths/get-shape file :copy-child)
|
||||||
|
|
||||||
;; ==== Action
|
;; ==== Action
|
||||||
update-fn (fn [shape]
|
|
||||||
(assoc shape :fills (ths/sample-fills-color :fill-color "#fabada")))
|
|
||||||
|
|
||||||
changes (cls/generate-update-shapes (pcb/empty-changes nil (:id page))
|
changes (cls/generate-update-shapes (pcb/empty-changes nil (:id page))
|
||||||
#{(:id copy-child)}
|
#{(:id copy-child)}
|
||||||
update-fn
|
(fn [shape]
|
||||||
|
(assoc shape :fills (ths/sample-fills-color :fill-color "#fabada")))
|
||||||
(:objects page)
|
(:objects page)
|
||||||
{})
|
{})
|
||||||
|
|
||||||
|
@ -281,12 +277,10 @@
|
||||||
copy2-root (ths/get-shape file :copy2-root)
|
copy2-root (ths/get-shape file :copy2-root)
|
||||||
|
|
||||||
;; ==== Action
|
;; ==== Action
|
||||||
update-fn (fn [shape]
|
|
||||||
(assoc shape :fills (ths/sample-fills-color :fill-color "#fabada")))
|
|
||||||
|
|
||||||
changes (cls/generate-update-shapes (pcb/empty-changes nil (:id page))
|
changes (cls/generate-update-shapes (pcb/empty-changes nil (:id page))
|
||||||
#{(:id copy2-root)}
|
#{(:id copy2-root)}
|
||||||
update-fn
|
(fn [shape]
|
||||||
|
(assoc shape :fills (ths/sample-fills-color :fill-color "#fabada")))
|
||||||
(:objects page)
|
(:objects page)
|
||||||
{})
|
{})
|
||||||
|
|
||||||
|
@ -330,12 +324,10 @@
|
||||||
copy2-child (ths/get-shape file :copy2-child)
|
copy2-child (ths/get-shape file :copy2-child)
|
||||||
|
|
||||||
;; ==== Action
|
;; ==== Action
|
||||||
update-fn (fn [shape]
|
|
||||||
(assoc shape :fills (ths/sample-fills-color :fill-color "#fabada")))
|
|
||||||
|
|
||||||
changes (cls/generate-update-shapes (pcb/empty-changes nil (:id page))
|
changes (cls/generate-update-shapes (pcb/empty-changes nil (:id page))
|
||||||
#{(:id copy2-child)}
|
#{(:id copy2-child)}
|
||||||
update-fn
|
(fn [shape]
|
||||||
|
(assoc shape :fills (ths/sample-fills-color :fill-color "#fabada")))
|
||||||
(:objects page)
|
(:objects page)
|
||||||
{})
|
{})
|
||||||
|
|
||||||
|
|
|
@ -31,12 +31,10 @@
|
||||||
copy-child (ths/get-shape file :copy-child)
|
copy-child (ths/get-shape file :copy-child)
|
||||||
|
|
||||||
;; ==== Action
|
;; ==== Action
|
||||||
update-fn (fn [shape]
|
|
||||||
(assoc shape :fills (ths/sample-fills-color :fill-color "#fabada")))
|
|
||||||
|
|
||||||
changes (cls/generate-update-shapes (pcb/empty-changes nil (:id page))
|
changes (cls/generate-update-shapes (pcb/empty-changes nil (:id page))
|
||||||
#{(:id copy-child)}
|
#{(:id copy-child)}
|
||||||
update-fn
|
(fn [shape]
|
||||||
|
(assoc shape :fills (ths/sample-fills-color :fill-color "#fabada")))
|
||||||
(:objects page)
|
(:objects page)
|
||||||
{})
|
{})
|
||||||
|
|
||||||
|
@ -73,12 +71,10 @@
|
||||||
copy-child (ths/get-shape file :copy-child)
|
copy-child (ths/get-shape file :copy-child)
|
||||||
|
|
||||||
;; ==== Action
|
;; ==== Action
|
||||||
update-fn (fn [shape]
|
|
||||||
(assoc shape :fills (ths/sample-fills-color :fill-color "#fabada")))
|
|
||||||
|
|
||||||
changes (cls/generate-update-shapes (pcb/empty-changes nil (:id page))
|
changes (cls/generate-update-shapes (pcb/empty-changes nil (:id page))
|
||||||
#{(:id copy-child)}
|
#{(:id copy-child)}
|
||||||
update-fn
|
(fn [shape]
|
||||||
|
(assoc shape :fills (ths/sample-fills-color :fill-color "#fabada")))
|
||||||
(:objects page)
|
(:objects page)
|
||||||
{})
|
{})
|
||||||
|
|
||||||
|
@ -234,12 +230,10 @@
|
||||||
copy2-root (ths/get-shape file :copy2-root)
|
copy2-root (ths/get-shape file :copy2-root)
|
||||||
|
|
||||||
;; ==== Action
|
;; ==== Action
|
||||||
update-fn (fn [shape]
|
|
||||||
(assoc shape :fills (ths/sample-fills-color :fill-color "#fabada")))
|
|
||||||
|
|
||||||
changes (cls/generate-update-shapes (pcb/empty-changes nil (:id page))
|
changes (cls/generate-update-shapes (pcb/empty-changes nil (:id page))
|
||||||
#{(:id copy2-root)}
|
#{(:id copy2-root)}
|
||||||
update-fn
|
(fn [shape]
|
||||||
|
(assoc shape :fills (ths/sample-fills-color :fill-color "#fabada")))
|
||||||
(:objects page)
|
(:objects page)
|
||||||
{})
|
{})
|
||||||
|
|
||||||
|
@ -272,12 +266,10 @@
|
||||||
copy2-child (ths/get-shape file :copy2-child)
|
copy2-child (ths/get-shape file :copy2-child)
|
||||||
|
|
||||||
;; ==== Action
|
;; ==== Action
|
||||||
update-fn (fn [shape]
|
|
||||||
(assoc shape :fills (ths/sample-fills-color :fill-color "#fabada")))
|
|
||||||
|
|
||||||
changes (cls/generate-update-shapes (pcb/empty-changes nil (:id page))
|
changes (cls/generate-update-shapes (pcb/empty-changes nil (:id page))
|
||||||
#{(:id copy2-child)}
|
#{(:id copy2-child)}
|
||||||
update-fn
|
(fn [shape]
|
||||||
|
(assoc shape :fills (ths/sample-fills-color :fill-color "#fabada")))
|
||||||
(:objects page)
|
(:objects page)
|
||||||
{})
|
{})
|
||||||
|
|
||||||
|
@ -313,12 +305,10 @@
|
||||||
copy2-child (ths/get-shape file :copy2-child)
|
copy2-child (ths/get-shape file :copy2-child)
|
||||||
|
|
||||||
;; ==== Action
|
;; ==== Action
|
||||||
update-fn (fn [shape]
|
|
||||||
(assoc shape :fills (ths/sample-fills-color :fill-color "#fabada")))
|
|
||||||
|
|
||||||
changes (cls/generate-update-shapes (pcb/empty-changes nil (:id page))
|
changes (cls/generate-update-shapes (pcb/empty-changes nil (:id page))
|
||||||
#{(:id copy2-child)}
|
#{(:id copy2-child)}
|
||||||
update-fn
|
(fn [shape]
|
||||||
|
(assoc shape :fills (ths/sample-fills-color :fill-color "#fabada")))
|
||||||
(:objects page)
|
(:objects page)
|
||||||
{})
|
{})
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue