Merge pull request #3468 from kawamataryo/main

Prevent add label if press enter in composition session
This commit is contained in:
Jackson Harper 2024-02-01 09:41:27 +08:00 committed by GitHub
commit 95bdc893d9
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -575,7 +575,7 @@
}
case 'enter': {
if (event.target.id == 'omnivore-edit-label-input') {
if (event.target.value) {
if (event.target.value && !event.isComposing) {
const labelList = event.target.form.querySelector('#label-list')
addLabel(labelList, event.target, event.target.value)
}