mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-05-03 10:00:07 -04:00
fix pinch zoom (#885)
This commit is contained in:
parent
9de3716324
commit
463854e42a
1 changed files with 2 additions and 1 deletions
|
@ -1769,7 +1769,8 @@ export class App extends React.Component<any, AppState> {
|
|||
event.preventDefault();
|
||||
const { deltaX, deltaY } = event;
|
||||
|
||||
if (event[KEYS.CTRL_OR_CMD]) {
|
||||
// note that event.ctrlKey is necessary to handle pinch zooming
|
||||
if (event.metaKey || event.ctrlKey) {
|
||||
const sign = Math.sign(deltaY);
|
||||
const MAX_STEP = 10;
|
||||
let delta = Math.abs(deltaY);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue