mirror of
https://github.com/drawdb-io/drawdb.git
synced 2025-08-29 10:43:56 +00:00
Merge pull request #156 from FelixZY/fzy/scroll-x/1
feat: support horizontal scrolling
This commit is contained in:
@@ -468,7 +468,7 @@ export default function Canvas() {
|
|||||||
setTransform((prev) => ({
|
setTransform((prev) => ({
|
||||||
...prev,
|
...prev,
|
||||||
pan: {
|
pan: {
|
||||||
...prev.pan,
|
x: prev.pan.x + e.deltaX / prev.zoom,
|
||||||
y: prev.pan.y + e.deltaY / prev.zoom,
|
y: prev.pan.y + e.deltaY / prev.zoom,
|
||||||
},
|
},
|
||||||
}));
|
}));
|
||||||
|
Reference in New Issue
Block a user