mirror of
https://github.com/penpot/penpot.git
synced 2025-06-14 14:21:37 +02:00
🐛 Fix snap imprecission.
This commit is contained in:
parent
1dfc604cf0
commit
d3951f7f8f
12 changed files with 108 additions and 86 deletions
|
@ -28,6 +28,8 @@
|
|||
[shape]
|
||||
(let [shape (gsh/transform-shape shape)
|
||||
shape-center (gsh/center shape)]
|
||||
(case (:type shape)
|
||||
:frame (-> shape gsh/shape->rect-shape frame-snap-points)
|
||||
(into #{shape-center} (-> shape :points)))))
|
||||
(if (= :frame (:type shape))
|
||||
(-> shape
|
||||
(gsh/shape->rect-shape)
|
||||
(frame-snap-points))
|
||||
(into #{shape-center} (:points shape)))))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue