0
Fork 0
mirror of https://github.com/penpot/penpot.git synced 2025-01-23 06:58:58 -05:00

🐛 Fix dragging path points by returning closest point instead of only the distance

This commit is contained in:
Eero Pitkänen 2024-10-10 10:09:53 +03:00 committed by Alonso Torres
parent 5dd14b929a
commit 0c8678eb87

View file

@ -160,7 +160,7 @@
selected-points (dm/get-in state [:workspace-local :edit-path id :selected-points] #{}) selected-points (dm/get-in state [:workspace-local :edit-path id :selected-points] #{})
start-position (apply min #(gpt/distance start-position %) selected-points) start-position (apply min-key #(gpt/distance start-position %) selected-points)
content (st/get-path state :content) content (st/get-path state :content)
points (upg/content->points content)] points (upg/content->points content)]