-
Notifications
You must be signed in to change notification settings - Fork 348
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
feat(playground): hotkey to run the playground #6326
Conversation
3e76a79
to
c9829bc
Compare
// Reserve Mod-Enter for the submit button | ||
keymap.of([ | ||
...defaultKeymap.filter((binding) => binding.key !== "Mod-Enter"), | ||
]), | ||
]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
removes cmd enter from entering a newline
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is exciting. Will have to think of some way to control keymap sprawl in the future
}} | ||
trailingVisual={ | ||
<Keyboard> | ||
<VisuallyHidden>command</VisuallyHidden> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What about windows/Linux? Ctrl+Enter should be used there.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added useModifierKey to detect if Mac
resolves #6267
This adds a command enter hotkey to run the playground. Note that the default key bindings for certain JSON editors needed to be removed.