mirror of
https://github.com/hoppscotch/hoppscotch.git
synced 2026-04-26 01:06:00 +03:00
[PR #5811] [MERGED] fix(common): prevent support menu from triggering in editors #5363
Labels
No labels
CodeDay
a11y
browser limited
bug
bug fix
cli
core
critical
design
desktop
discussion
docker
documentation
duplicate
enterprise
feature
feature
fosshack
future
good first issue
hacktoberfest
help wanted
i18n
invalid
major
minor
need information
need testing
not applicable to hoppscotch
not reproducible
pull-request
question
refactor
resolved
sandbox
self-host
spam
stale
testmu
wip
wont fix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/hoppscotch#5363
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/hoppscotch/hoppscotch/pull/5811
Author: @Leon-Luu
Created: 1/29/2026
Status: ✅ Merged
Merged: 2/3/2026
Merged by: @jamesgeorge007
Base:
patch← Head:fix/shift_to_block_support_menu_codemirror📝 Commits (3)
832c828fix: shift not trigger on codemirrors1b1b0e8Merge branch 'main' into fix/shift_to_block_support_menu_codemirrorc042452Merge branch 'main' into fix/shift_to_block_support_menu_codemirror📊 Changes
1 file changed (+16 additions, -0 deletions)
View changed files
📝
packages/hoppscotch-common/src/helpers/keybindings.ts(+16 -0)📄 Description
What the fix does:
Prevents the Support menu (triggered by Shift+/) from opening when typing "/" in CodeMirror or Monaco editors. The fix adds a defensive check at the action execution level to ensure that when you're typing in an editor, the keystroke is treated as text input rather than a keyboard shortcut.
Why both fixes are needed:
Old fix (
65046526f, line 280): Attempts to prevent the binding string generation early in the event flow. When it works, it's more efficient - avoids unnecessary lookups and checks.New fix : Catches cases where the old fix fails due to event capture phase timing issues. With capture: true (
973572d06), events are intercepted very early, sometimes before CodeMirror's focus handlers complete. This causes the early check to miss some cases.Together they provide "defense in depth" where The old fix handles most cases efficiently, while the new fix acts as a safety net for edge cases caused by the capture phase event handling. Both are needed because the capture phase can cause timing-dependent detection failures that neither fix alone can handle reliably.
Closes #
https://github.com/hoppscotch/hoppscotch/issues/5777
What's changed
Notes to reviewers
Summary by cubic
Prevents the Support menu (Shift+/) from opening when typing "/" in CodeMirror, Monaco, or input fields. Typing now behaves normally without accidental shortcut triggers.
Written for commit
c042452677. Summary will update on new commits.🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.