2
0

feat(editor): 💫 Can pan graph with mouse + click

This commit is contained in:
Baptiste Arnaud
2022-02-14 06:23:39 +01:00
parent f8a64151ef
commit 1033e42b60
2 changed files with 30 additions and 8 deletions

View File

@ -65,7 +65,8 @@ export const BlockNode = ({ block, blockIndex }: Props) => {
const handleTitleSubmit = (title: string) =>
updateBlock(blockIndex, { title })
const handleMouseDown = () => {
const handleMouseDown = (e: React.MouseEvent) => {
e.stopPropagation()
setIsMouseDown(true)
}
const handleMouseUp = () => {