diff --git a/CHANGES.md b/CHANGES.md index d8fda19d1..eb71385b7 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -38,6 +38,7 @@ - Font-Kerning does not work on Artboard Export to PNG/JPG/PDF [#3029](https://github.com/penpot/penpot/issues/3029) - Fix manipulate duplicated project (delete, duplicate, rename, pin/unpin...) [Taiga #5027](https://tree.taiga.io/project/penpot/issue/5027) - Fix deleted files appear in search results [Taiga #5002](https://tree.taiga.io/project/penpot/issue/5002) +- Fix problem with selected colors and texts [Taiga #5051](https://tree.taiga.io/project/penpot/issue/5051) ### :heart: Community contributions by (Thank you!) - To @ondrejkonec: for contributing to the code with: diff --git a/frontend/src/app/main/data/workspace/colors.cljs b/frontend/src/app/main/data/workspace/colors.cljs index b80654cae..4514ffebc 100644 --- a/frontend/src/app/main/data/workspace/colors.cljs +++ b/frontend/src/app/main/data/workspace/colors.cljs @@ -339,7 +339,8 @@ (defn change-text-color [old-color new-color index node] (let [fills (map #(dissoc % :fill-color-ref-id :fill-color-ref-file) (:fills node)) - parsed-color (d/without-nils (color-att->text old-color)) + parsed-color (-> (d/without-nils (color-att->text old-color)) + (dissoc :fill-color-ref-id :fill-color-ref-file)) parsed-new-color (d/without-nils (color-att->text new-color)) has-color? (d/index-of fills parsed-color)] (cond-> node