diff --git a/common/src/app/common/files/migrations.cljc b/common/src/app/common/files/migrations.cljc index 0c18ea7ad8..11a99507fb 100644 --- a/common/src/app/common/files/migrations.cljc +++ b/common/src/app/common/files/migrations.cljc @@ -1480,7 +1480,7 @@ (update :pages-index d/update-vals update-container) (d/update-when :components d/update-vals update-container)))) -(defmethod migrate-data "0008-fix-library-colors-v2" +(defmethod migrate-data "0008-fix-library-colors-v3" [data _] (letfn [(clear-color-opacity [color] (if (and (contains? color :opacity) @@ -1491,8 +1491,6 @@ (clear-color [color] (-> color (select-keys types.color/library-color-attrs) - (d/without-nils) - (d/without-qualified) (clear-color-opacity)))] (d/update-when data :colors d/update-vals clear-color))) @@ -1560,4 +1558,4 @@ "0005-deprecate-image-type" "0006-fix-old-texts-fills" "0007-clear-invalid-strokes-and-fills-v2" - "0008-fix-library-colors-v2"])) + "0008-fix-library-colors-v3"])) diff --git a/common/src/app/common/types/color.cljc b/common/src/app/common/types/color.cljc index 6b3893d3ef..7d55b99c19 100644 --- a/common/src/app/common/types/color.cljc +++ b/common/src/app/common/types/color.cljc @@ -151,7 +151,7 @@ [:fn has-valid-color-attrs?]]) (def library-color-attrs - (sm/keys schema:library-color-attrs)) + (into required-color-attrs (sm/keys schema:library-color-attrs))) (def valid-color? (sm/lazy-validator schema:color))