fix: adding check for link length to prevent early return (#4982)

Co-authored-by: Connor Hanafee <connorp@Connors-MacBook-Pro.local>
Co-authored-by: dwelle <luzar.david@gmail.com>
This commit is contained in:
connorhanafee 2022-03-27 22:50:41 +01:00 committed by GitHub
parent 127af9db23
commit 580e719580
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 4 deletions

View file

@ -337,6 +337,9 @@ export const isPointHittingLinkIcon = (
[x, y]: Point,
isMobile: boolean,
) => {
if (!element.link || appState.selectedElementIds[element.id]) {
return false;
}
const threshold = 4 / appState.zoom.value;
if (
!isMobile &&