mirror of
https://github.com/penpot/penpot.git
synced 2025-07-27 09:07:26 +02:00
✨ Improved mouse collision detection for groups and text shapes
This commit is contained in:
parent
0d48c758df
commit
c5c0b36f28
5 changed files with 44 additions and 4 deletions
|
@ -257,6 +257,13 @@
|
|||
:width (.-width ^js rect)
|
||||
:height (.-height ^js rect)}))
|
||||
|
||||
(defn bounding-rect->rect
|
||||
[{:keys [left top width height]}]
|
||||
{:x left
|
||||
:y top
|
||||
:width width
|
||||
:height height})
|
||||
|
||||
(defn get-window-size
|
||||
[]
|
||||
{:width (.-innerWidth ^js js/window)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue