mirror of
https://github.com/logseq/logseq.git
synced 2026-05-28 14:39:48 +00:00
fix: adjust normalization
This commit is contained in:
@@ -25,7 +25,8 @@ export class PinchingState<
|
||||
const { camera } = this.app.viewport
|
||||
|
||||
// Normalize the value of deltaZ from raw WheelEvent
|
||||
const deltaZ = normalizeWheel(event)[2] * 0.05
|
||||
const deltaZ = normalizeWheel(event)[2] * 0.01
|
||||
if (deltaZ === 0) return;
|
||||
const zoom = camera.zoom - deltaZ * camera.zoom;
|
||||
this.app.viewport.pinchCamera(info.point, [0, 0], zoom)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user