Point in direction block stuck to pointer after using angle picker and deleting

Open
#547 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
68/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Quiet
Tech stack
javascript
Domain
frontend

Research direction

Start by reproducing the issue in the block editor with the point in direction block, angle picker, and blocks menu. Use the reported console error, "Cannot read properties of undefined (reading '2')", as the first debugging entry point while tracing angle-picker cleanup and block deletion. Done means the block is removed normally, does not remain attached to the pointer, and the error no longer appears.

Written by the indexing model from the issue text.

Description

spork

Expected Behavior

Blocks should conveniently not become permanently attached to your cursor. As I write this, it is hard to see my screen because I now have hundreds of blocks stuck to my cursor (just kidding).

Actual Behavior

The point in direction block can become stuck to your mouse cursor after using the angle picker and then attempting to delete the block.

Steps to Reproduce

  • Drag the "point in direction" block onto the workspace
  • Click the angle input field to open the angle picker
  • Drag the angle picker to change the value
  • Click outside to close the angle picker
  • Drag the block back to the blocks menu
  • It is now stuck to you forever, maybe give it a name and think about what you will need to feed it
  • Also note that there is an error in the console (Uncaught TypeError: Cannot read properties of undefined (reading '2'))

System Details

Mac OS 26.2 Chrome 147.0.7727.56

Dominant language
JavaScript
Stars
310
Forks
299
Avg merge
19h 41m
Merged PRs (30d)
14

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from scratchfoundation/scratch-editor

All issues in scratchfoundation/scratch-editor

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.