We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2ce2a23 commit a4c935cCopy full SHA for a4c935c
src/ChatWindow/MessagesList.vue
@@ -204,11 +204,11 @@ export default {
204
}
205
},
206
207
- // mounted() {
208
- // window.addEventListener('keypress', e => {
209
- // if (e.keyCode === 13) this.sendMessage()
210
- // })
211
- // },
+ mounted() {
+ window.addEventListener('keypress', e => {
+ if (e.keyCode === 13 && !e.shiftKey) this.sendMessage()
+ })
+ },
212
213
watch: {
214
loadingMessages(val) {
0 commit comments