mirror of
https://github.com/penpot/penpot.git
synced 2026-05-03 07:08:44 +00:00
Merge pull request #6954 from penpot/alotor-fix-gradient-stroke
🐛 Fix opacity on stroke gradients
This commit is contained in:
commit
3f9a1525ca
@ -48,6 +48,8 @@
|
||||
- Fix "Copy as SVG" generates different code from the Inspect panel [Taiga #11519](https://tree.taiga.io/project/penpot/issue/11519)
|
||||
- Fix overriden tokens in text copies are not preserved [Taiga #11486](https://tree.taiga.io/project/penpot/issue/11486)
|
||||
- Fix problem when changing between flex/grid layout [Taiga #11625](https://tree.taiga.io/project/penpot/issue/11625)
|
||||
- Fix opacity on stroke gradients [Taiga #11646](https://tree.taiga.io/project/penpot/issue/11646)
|
||||
- Fix change from gradient to solid color [Taiga #11648](https://tree.taiga.io/project/penpot/issue/11648)
|
||||
|
||||
## 2.8.1 (Unreleased)
|
||||
|
||||
|
||||
@ -1080,7 +1080,11 @@
|
||||
(fn [state]
|
||||
(-> state
|
||||
(assoc :type :color)
|
||||
(dissoc :editing-stop :stops :gradient)))))))
|
||||
(dissoc :editing-stop :stops :gradient)))))
|
||||
|
||||
ptk/WatchEvent
|
||||
(watch [_ _ _]
|
||||
(rx/of (update-colorpicker-color {} false)))))
|
||||
|
||||
(defn activate-colorpicker-gradient
|
||||
[type]
|
||||
|
||||
@ -103,15 +103,15 @@
|
||||
|
||||
(obj/set! attrs "strokeWidth" width)
|
||||
|
||||
(when (some? gradient)
|
||||
(if (some? gradient)
|
||||
(let [gradient-id (dm/str "stroke-color-gradient-" render-id "-" index)]
|
||||
(obj/set! attrs "stroke" (str/ffmt "url(#%)" gradient-id))))
|
||||
(obj/set! attrs "stroke" (str/ffmt "url(#%)" gradient-id)))
|
||||
|
||||
(when-not (some? gradient)
|
||||
(when (some? color)
|
||||
(obj/set! attrs "stroke" color))
|
||||
(when (some? opacity)
|
||||
(obj/set! attrs "strokeOpacity" opacity)))
|
||||
(obj/set! attrs "stroke" color)))
|
||||
|
||||
(when (some? opacity)
|
||||
(obj/set! attrs "strokeOpacity" opacity))
|
||||
|
||||
(when (not= style :svg)
|
||||
(obj/set! attrs "strokeDasharray" (calculate-dasharray style width)))
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user