Skip to content

Commit

Permalink
fix: don't send message on enter if isComposing is true
Browse files Browse the repository at this point in the history
  • Loading branch information
szuperaz committed Sep 5, 2024
1 parent 70922af commit faf6d21
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 2 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,13 @@ on:
- master
- beta
- 4.x.x
- 4.x.x-beta
pull_request:
branches:
- master
- beta
- 4.x.x
- 4.x.x-beta
jobs:
workflow:
runs-on: ubuntu-latest
Expand Down
6 changes: 6 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,12 @@
"branches": [
"master",
"4.x.x",
{
"name": "4.x.x-beta",
"prerelease": true,
"channel": "beta",
"range": "4.x.x"
},
{
"name": "beta",
"prerelease": true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,7 @@ export class AutocompleteTextareaComponent
}

enterHit(event: Event) {
if (this.inputMode === 'desktop') {
if (this.inputMode === 'desktop' && !(event as KeyboardEvent).isComposing) {
event.preventDefault();
this.updateMentionedUsersFromText();
this.send.next();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ export class TextareaComponent
}

enterHit(event: Event) {
if (this.inputMode === 'desktop') {
if (this.inputMode === 'desktop' && !(event as KeyboardEvent).isComposing) {
event.preventDefault();
this.send.next();
}
Expand Down

0 comments on commit faf6d21

Please sign in to comment.