microsoft / microsoft/pxt-microbit
Fields in 'plot' can be detached but not reattached
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 804
- Forks
- 721
- Avg merge
- 2d 9h
- Merged PRs (30d)
- 2
Description
Describe the bug
If you have a 'plot x,y' block you can detach it with the shortcut key 'x'. Pressing 'undo' moves it back to approximately the original position but does not reconnect it. Ctrl+C to copy it claims success, but you can't paste it back in the original connection. Once detached, you can't actually delete it at all.
To Reproduce
- New project
- Turn on keyboard controls
- Add 'plot x,y' block
- Edit x and y fields to whatever numbers (optional - same behaviour either way)
- Press 'x' to detach
- Press Ctrl+Z to undo
- OBSERVE: it moves back but doesn't reconnect
- Use arrows to select the orphaned block and Ctrl+C
- Use arrows and Ctrl+V to try to paste it back
- OBSERVE: you can't put it back
- Use arrows and Del to try to delete it
- OBSERVE: you can't delete it
Expected behavior
You should either not be able to detach it, or should be able to undo the operation and copy/paste it.
Screenshots
micro:bit version (please complete the following information):
not relevant
Desktop (please complete the following information):
- OS: win 11
- Browser: Chrome and Firefox
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the issue in a new project with keyboard controls enabled, following the listed detach, undo, copy/paste, and delete steps. Trace the editor entry points handling the 'plot x,y' block and these keyboard operations; done means the block can either not be detached or can be reconnected, copied, pasted, and deleted after detaching.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100