Skip to content

feat(composer): use cmd/ctrl+enter send and add shortcut tooltip#88

Closed
fihaaade wants to merge 6 commits intoDimillian:mainfrom
fihaaade:feat/cmd-enter-send
Closed

feat(composer): use cmd/ctrl+enter send and add shortcut tooltip#88
fihaaade wants to merge 6 commits intoDimillian:mainfrom
fihaaade:feat/cmd-enter-send

Conversation

@fihaaade
Copy link
Contributor

  • Use Cmd+Enter on macOS (Ctrl+Enter elsewhere) to send; Enter now inserts a newline.
  • Show a hover tooltip on the send button with the shortcut key.

@Dimillian
Copy link
Owner

FYI we already have CMD+SHIFT to have a new line

@Dimillian
Copy link
Owner

@codex review, does it conflict with CMD+SHIFT? Any other issues?

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 4b67d4e4c4

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines 272 to 276
onKeyDown={(event) => {
if (event.key === "Enter" && event.shiftKey) {
const isEnter = event.key === "Enter";
const isSendShortcut = isMac ? event.metaKey : event.ctrlKey;
if (isEnter && !isSendShortcut) {
event.preventDefault();

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Preserve Enter to accept autocomplete

When autocomplete is open, useComposerAutocompleteState.handleInputKeyDown uses Enter to apply the highlighted suggestion. The new early branch for isEnter && !isSendShortcut runs before handleInputKeyDown and returns after inserting a newline, so Enter never reaches the autocomplete handler; users can no longer accept suggestions with Enter (only Tab works). Consider skipping the newline path when isAutocompleteOpen (or deferring Enter handling until after handleInputKeyDown) so the existing suggestion behavior remains intact.

Useful? React with 👍 / 👎.

@Dimillian Dimillian closed this Jan 18, 2026
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.

2 participants