mirror of
https://github.com/penpot/penpot.git
synced 2025-06-07 01:41:38 +02:00
✨ Integration with library new colors
This commit is contained in:
parent
7d7008d405
commit
245c39b1f6
11 changed files with 64 additions and 38 deletions
|
@ -25,7 +25,7 @@
|
|||
:ry (:ry shape)}))
|
||||
|
||||
(defn add-fill [attrs shape]
|
||||
(let [fill-color-gradient-id (str "fill-color-gradient_" (:id shape))]
|
||||
(let [fill-color-gradient-id (str "fill-color-gradient_" (:render-id shape))]
|
||||
(if (:fill-color-gradient shape)
|
||||
(obj/merge! attrs #js {:fill (str/format "url(#%s)" fill-color-gradient-id)})
|
||||
(obj/merge! attrs #js {:fill (or (:fill-color shape) "transparent")
|
||||
|
@ -33,7 +33,7 @@
|
|||
|
||||
(defn add-stroke [attrs shape]
|
||||
(let [stroke-style (:stroke-style shape :none)
|
||||
stroke-color-gradient-id (str "stroke-color-gradient_" (:id shape))]
|
||||
stroke-color-gradient-id (str "stroke-color-gradient_" (:render-id shape))]
|
||||
(if (not= stroke-style :none)
|
||||
(if (:stroke-color-gradient shape)
|
||||
(obj/merge! attrs
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue