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

🐛 Fix problem with zoom with wheel in Firefox

This commit is contained in:
alonso.torres 2022-04-20 10:40:07 +02:00
parent 31ec4092ed
commit cc046555a3

View file

@ -393,7 +393,7 @@
(* unit)
(/ zoom))]
(if (or ctrl? mod?)
(let [delta (* -1 (+ (.-deltaY ^js event) (.-deltaX ^js event)))
(let [delta (* -1 (+ delta-y delta-x))
scale (-> (+ 1 (/ delta 100)) (mth/clamp 0.77 1.3))]
(st/emit! (dw/set-zoom pt scale)))
(if (and (not (cfg/check-platform? :macos))