Skip to content

Commit

Permalink
fix double-send bug when using keyboard
Browse files Browse the repository at this point in the history
  • Loading branch information
dlqqq committed Jul 29, 2024
1 parent 3433e62 commit dd2cc80
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,11 @@ export function SendButton(props: SendButtonProps): JSX.Element {
}}
>
<MenuItem
onClick={() => sendWithSelection()}
onClick={e => {
sendWithSelection();
// prevent sending second message with no selection
e.stopPropagation();
}}
disabled={includeSelectionDisabled}
>
<includeSelectionIcon.react />
Expand Down

0 comments on commit dd2cc80

Please sign in to comment.