Fix the cleanup of event handlers (#2298)
We probably don't want to add the listener here. ### Change Type - [x] `patch` — Bug fix - [ ] `minor` — New feature - [ ] `major` — Breaking change - [ ] `dependencies` — Changes to package dependencies[^1] - [ ] `documentation` — Changes to the documentation only[^2] - [ ] `tests` — Changes to any test code only[^2] - [ ] `internal` — Any other changes that don't affect the published package[^2] - [ ] I don't know [^1]: publishes a `patch` release, for devDependencies use `internal` [^2]: will not publish a new version
This commit is contained in:
parent
49f0f7f200
commit
ea83e45942
1 changed files with 1 additions and 1 deletions
|
@ -38,7 +38,7 @@ export function useFixSafariDoubleTapZoomPencilEvents(ref: React.RefObject<HTMLE
|
|||
elm.addEventListener('touchend', handleEvent)
|
||||
return () => {
|
||||
elm.removeEventListener('touchstart', handleEvent)
|
||||
elm.addEventListener('touchend', handleEvent)
|
||||
elm.removeEventListener('touchend', handleEvent)
|
||||
}
|
||||
}, [editor, ref])
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue