mirror of
https://github.com/penpot/penpot.git
synced 2026-04-26 19:58:09 +00:00
🐛 Remove qualified keyword keys from colors
This commit is contained in:
parent
82bedda604
commit
787c066357
@ -1468,14 +1468,21 @@
|
||||
(update :pages-index d/update-vals update-container)
|
||||
(d/update-when :components d/update-vals update-container))))
|
||||
|
||||
(defmethod migrate-data "0008-fix-library-colors-opacity"
|
||||
(defmethod migrate-data "0008-fix-library-colors"
|
||||
[data _]
|
||||
(letfn [(update-color [color]
|
||||
(letfn [(clear-color-opacity [color]
|
||||
(if (and (contains? color :opacity)
|
||||
(nil? (get color :opacity)))
|
||||
(assoc color :opacity 1)
|
||||
color))]
|
||||
(d/update-when data :colors d/update-vals update-color)))
|
||||
color))
|
||||
|
||||
(clear-color [color]
|
||||
(-> color
|
||||
(d/without-nils)
|
||||
(d/without-qualified)
|
||||
(clear-color-opacity)))]
|
||||
|
||||
(d/update-when data :colors d/update-vals clear-color)))
|
||||
|
||||
(def available-migrations
|
||||
(into (d/ordered-set)
|
||||
@ -1540,4 +1547,4 @@
|
||||
"0005-deprecate-image-type"
|
||||
"0006-fix-old-texts-fills"
|
||||
"0007-clear-invalid-strokes-and-fills-v2"
|
||||
"0008-fix-library-colors-opacity"]))
|
||||
"0008-fix-library-colors"]))
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user