BlockNote icon indicating copy to clipboard operation
BlockNote copied to clipboard

Fix PageDown/PageUp scroll when slash menu is open

Open MDSAM05 opened this issue 1 month ago • 1 comments

Summary

Fix an issue where pressing PageDown / PageUp while the slash command typeahead menu is open causes the entire page to scroll instead of being handled by the suggestion menu.

Rationale

Restores expected keyboard behavior for the slash command suggestion menu.

Changes

  • Added handleKeyDown handling in the SuggestionMenu ProseMirror plugin
  • Prevented default behavior for PageDown / PageUp when the menu is open

Impact

  • No breaking changes
  • Improves keyboard navigation UX
  • Restores expected behavior for suggestion lists
  • Arrow key behavior remains unchanged

Testing

  • Manually tested by opening the slash menu and pressing:
  • ArrowUp / ArrowDown → selection moves correctly
  • PageDown / PageUp → page no longer scrolls
  • Verified menu remains open and focused

Screenshots/Video

https://github.com/user-attachments/assets/3c29bc33-b5b7-47bb-b73a-94107752473c

Checklist

  • [x] Code follows the project's coding standards.
  • [ ] Unit tests covering the new feature have been added.
  • [x] All existing tests pass.
  • [ ] The documentation has been updated to reflect the new feature

Additional Notes

MDSAM05 avatar Dec 24 '25 16:12 MDSAM05