mirror of
https://github.com/penpot/penpot.git
synced 2025-05-19 17:36:10 +02:00
🐛 Fix middle button panning can drag guides
This commit is contained in:
parent
8e35ad0f7f
commit
d49e1f1641
3 changed files with 6 additions and 5 deletions
|
@ -4,6 +4,7 @@
|
||||||
|
|
||||||
### :bug: Bugs fixed
|
### :bug: Bugs fixed
|
||||||
- Fix paste board inside itself [Taiga #4775](https://tree.taiga.io/project/penpot/issue/4775)
|
- Fix paste board inside itself [Taiga #4775](https://tree.taiga.io/project/penpot/issue/4775)
|
||||||
|
- Fix middle button panning can drag guides [Taiga #4266](https://tree.taiga.io/project/penpot/issue/4266)
|
||||||
|
|
||||||
## 1.17.1
|
## 1.17.1
|
||||||
|
|
||||||
|
|
|
@ -7,7 +7,6 @@
|
||||||
(ns app.rpc
|
(ns app.rpc
|
||||||
(:require
|
(:require
|
||||||
[app.auth.ldap :as-alias ldap]
|
[app.auth.ldap :as-alias ldap]
|
||||||
[app.common.data :as d]
|
|
||||||
[app.common.exceptions :as ex]
|
[app.common.exceptions :as ex]
|
||||||
[app.common.logging :as l]
|
[app.common.logging :as l]
|
||||||
[app.common.spec :as us]
|
[app.common.spec :as us]
|
||||||
|
|
|
@ -69,10 +69,11 @@
|
||||||
on-pointer-down
|
on-pointer-down
|
||||||
(mf/use-callback
|
(mf/use-callback
|
||||||
(fn [event]
|
(fn [event]
|
||||||
|
(when (= 0 (.-button event))
|
||||||
(dom/capture-pointer event)
|
(dom/capture-pointer event)
|
||||||
(mf/set-ref-val! dragging-ref true)
|
(mf/set-ref-val! dragging-ref true)
|
||||||
(mf/set-ref-val! start-ref (dom/get-client-position event))
|
(mf/set-ref-val! start-ref (dom/get-client-position event))
|
||||||
(mf/set-ref-val! start-pos-ref (get @ms/mouse-position axis))))
|
(mf/set-ref-val! start-pos-ref (get @ms/mouse-position axis)))))
|
||||||
|
|
||||||
on-pointer-up
|
on-pointer-up
|
||||||
(mf/use-callback
|
(mf/use-callback
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue