Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The hand tool is still following the cursor when moving outside the canvas #2112

Closed
St-Permiakov opened this issue Jan 20, 2023 · 0 comments · Fixed by #2118
Closed

The hand tool is still following the cursor when moving outside the canvas #2112

St-Permiakov opened this issue Jan 20, 2023 · 0 comments · Fixed by #2118
Assignees

Comments

@St-Permiakov
Copy link
Collaborator

The hand tool is still following the cursor when moving outside the canvas.

ketcher-paste-bug-09

I'm not sure if it's caused by that line of code, but I guess it's because the mouseleave event is not triggered. The following code in ketcher-react/src/script/ui/views/components/StructEditor/StructEditor.jsx may help.

case 'leave':
  this.editorRef.current.classList.remove(classes.enableCursor)
  this.setState({
    enableCursor: false
  })
  break

Originally posted by @yuleicul in #2071 (comment)

@St-Permiakov St-Permiakov self-assigned this Jan 20, 2023
@St-Permiakov St-Permiakov changed the title The hand tool is still following the cursor when moving outside the canvas. The hand tool is still following the cursor when moving outside the canvas Jan 20, 2023
@Nitvex Nitvex added this to the Release Candidate 2.8.0-rc.1 milestone Jan 23, 2023
St-Permiakov added a commit that referenced this issue Jan 25, 2023
…wing-the-cursor-when-moving-outside-the-canvas

#2112: The hand tool is still following the cursor when moving outside the canvas
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants