Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: On New post page, hotkeys register even when text input are not focused on #703

Open
sonngdev opened this issue Jan 26, 2024 · 1 comment

Comments

@sonngdev
Copy link
Contributor

Context

On New post page (/create), try pressing ctrl/cmd + 1 (or 2, 3, 4, etc).

Expected Behavior

If Post body input (markdown-supported text area) is not in focus, browser should switch to the respective tab number 1, 2, 3, 4, etc. (default browser behavior).

If Post body input is in focus, then the respective hotkeys can register (e.g. ctrl/cmd + 1 creates a level 1 heading in markdown (#). For the full list, see /markdoc/editor/hotkeys/hotkeys.markdoc.ts.

Current Behavior

Hotkeys always register, regardless of the focus state of the Post body text input.

Screenshots

Image of said bug

Steps to reproduce

See above.

Additional info

N/A

@NiallJoeMaher
Copy link
Contributor

What a strange one. I really need to finish the new editor so we can kill this one anyway 😂

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

No branches or pull requests

2 participants