2
0
mirror of https://github.com/tenrok/vue2-datepicker.git synced 2026-06-24 21:30:40 +03:00

fix: input event work with slot input (#546)

This commit is contained in:
mengxiong10
2020-11-26 09:51:57 +08:00
parent b7cbc0d2f1
commit ef1a748867
+2 -1
View File
@@ -406,7 +406,8 @@ export default {
} }
}, },
handleInputInput(evt) { handleInputInput(evt) {
this.userInput = evt.target.value; // slot input v-model
this.userInput = typeof evt === 'string' ? evt : evt.target.value;
}, },
handleInputKeydown(evt) { handleInputKeydown(evt) {
const { keyCode } = evt; const { keyCode } = evt;