Skip to content

Conversation

@vikas-sharma123
Copy link

This PR fixes a bug where typing inside an input field (like the “Set Pen Size” block) caused other blocks in the workspace to duplicate or glitch.

The issue happened because workspace keyboard events were still active while typing in input fields.

I’ve added a simple check in activity.js to stop keydown events from propagating when the event target is an input box.

Tested locally — the duplication no longer happens and other keyboard shortcuts still work fine.

Fixes #4788

@github-actions
Copy link
Contributor

github-actions bot commented Nov 9, 2025

✅ All Jest tests passed! This PR is ready to merge.

@github-actions
Copy link
Contributor

✅ All Jest tests passed! This PR is ready to merge.

@harshrajsoni
Copy link

Hyy @vikas-sharma123
I tested your code but the issue still persists...
image

Screen.Recording.2025-11-12.085843.mp4

@vikas-sharma123
Copy link
Author

vikas-sharma123 commented Nov 13, 2025

hi @harshrajsoni it works fine on my system but thanks for the heads-up

@walterbender
Copy link
Member

I am not able to reproduce the issue as described. Can you provide detailed instructions on reproducing the problem with the set pen size block?

@vikas-sharma123
Copy link
Author

vikas-sharma123 commented Nov 17, 2025

@walterbender Hey, here are the exact steps to see the issue:

  1. Open Music Blocks (local build).
  2. Go to Pen → drag “Set pen size” into the workspace.
  3. Click on the input at the top of that block.
  4. Type any numbers.

Before the fix, the workspace duplicates/glitches blocks when typing.
After my change, typing stays inside the input field and nothing duplicates.

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 this pull request may close these issues.

Typing in “Width” Block Input Causes Duplicate Blocks

3 participants