mirror of
https://github.com/penpot/penpot.git
synced 2025-05-31 20:16:11 +02:00
🐛 Fix linecap SVG path property (#6163)
This commit is contained in:
parent
416e9e8e1d
commit
2e41bd7607
1 changed files with 4 additions and 6 deletions
|
@ -435,16 +435,12 @@
|
|||
|
||||
attrs
|
||||
(-> attrs
|
||||
(cond-> linecap
|
||||
(dissoc :strokeLinecap))
|
||||
(cond-> (some? color)
|
||||
(dissoc :stroke :strokeWidth :strokeOpacity))
|
||||
(update
|
||||
:style
|
||||
(fn [style]
|
||||
(-> style
|
||||
(cond-> linecap
|
||||
(dissoc :strokeLinecap))
|
||||
(cond-> (some? color)
|
||||
(dissoc :stroke :strokeWidth :strokeOpacity)))))
|
||||
(d/without-nils))]
|
||||
|
@ -461,12 +457,14 @@
|
|||
|
||||
(and (some? linecap) (cfh/path-shape? shape)
|
||||
(or (= linecap :round) (= linecap :square)))
|
||||
|
||||
(assoc :stroke-cap-start linecap
|
||||
:stroke-cap-end linecap)
|
||||
:stroke-cap-end linecap
|
||||
:stroke-linecap linecap)
|
||||
|
||||
(d/any-key? (dm/get-in shape [:strokes 0])
|
||||
:strokeColor :strokeOpacity :strokeWidth
|
||||
:strokeCapStart :strokeCapEnd)
|
||||
:strokeLinecap :strokeCapStart :strokeCapEnd)
|
||||
(assoc-in [:strokes 0 :stroke-style] :svg))))
|
||||
|
||||
(defn setup-opacity [shape]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue