mirror of
https://github.com/penpot/penpot.git
synced 2025-03-12 07:41:43 -05:00
🐛 Fix dotted style in strokes
This commit is contained in:
parent
6354883a6f
commit
6334520c66
2 changed files with 8 additions and 2 deletions
|
@ -34,6 +34,7 @@
|
||||||
- Fix lock/hide elements in context menu when multiples shapes selected [Taiga #2340](https://tree.taiga.io/project/penpot/issue/2340)
|
- Fix lock/hide elements in context menu when multiples shapes selected [Taiga #2340](https://tree.taiga.io/project/penpot/issue/2340)
|
||||||
- Fix problem with booleans [Taiga #2356](https://tree.taiga.io/project/penpot/issue/2356)
|
- Fix problem with booleans [Taiga #2356](https://tree.taiga.io/project/penpot/issue/2356)
|
||||||
- Fix line-height/letter-spacing inputs behaviour [Taiga #2331](https://tree.taiga.io/project/penpot/issue/2331)
|
- Fix line-height/letter-spacing inputs behaviour [Taiga #2331](https://tree.taiga.io/project/penpot/issue/2331)
|
||||||
|
- Fix dotted style in strokes [Taiga #2312](https://tree.taiga.io/project/penpot/issue/2312)
|
||||||
|
|
||||||
### :arrow_up: Deps updates
|
### :arrow_up: Deps updates
|
||||||
### :heart: Community contributions by (Thank you!)
|
### :heart: Community contributions by (Thank you!)
|
||||||
|
|
|
@ -18,7 +18,8 @@
|
||||||
[width style]
|
[width style]
|
||||||
(let [values (case style
|
(let [values (case style
|
||||||
:mixed [5 5 1 5]
|
:mixed [5 5 1 5]
|
||||||
:dotted [5 5]
|
;; We want 0 so they are circles
|
||||||
|
:dotted [(- width) 5]
|
||||||
:dashed [10 10]
|
:dashed [10 10]
|
||||||
nil)]
|
nil)]
|
||||||
|
|
||||||
|
@ -132,9 +133,13 @@
|
||||||
;; for inner or outer strokes.
|
;; for inner or outer strokes.
|
||||||
(and (spec/stroke-caps-line (:stroke-cap-start shape))
|
(and (spec/stroke-caps-line (:stroke-cap-start shape))
|
||||||
(= (:stroke-cap-start shape) (:stroke-cap-end shape))
|
(= (:stroke-cap-start shape) (:stroke-cap-end shape))
|
||||||
(not (#{:inner :outer} (:stroke-alignment shape))))
|
(not (#{:inner :outer} (:stroke-alignment shape)))
|
||||||
|
(not= :dotted stroke-style))
|
||||||
(assoc :strokeLinecap (:stroke-cap-start shape))
|
(assoc :strokeLinecap (:stroke-cap-start shape))
|
||||||
|
|
||||||
|
(= :dotted stroke-style)
|
||||||
|
(assoc :strokeLinecap "round")
|
||||||
|
|
||||||
;; For other cap types we use markers.
|
;; For other cap types we use markers.
|
||||||
(and (or (spec/stroke-caps-marker (:stroke-cap-start shape))
|
(and (or (spec/stroke-caps-marker (:stroke-cap-start shape))
|
||||||
(and (spec/stroke-caps-line (:stroke-cap-start shape))
|
(and (spec/stroke-caps-line (:stroke-cap-start shape))
|
||||||
|
|
Loading…
Add table
Reference in a new issue