recover autofocusing behavior

This commit is contained in:
taehoon 2019-09-19 13:52:54 -04:00
parent a9f33272a8
commit 0c8038d4f6

View File

@ -15,6 +15,13 @@ const PostStatusModal = {
return this.$store.state.postStatus.params return this.$store.state.postStatus.params
} }
}, },
watch: {
isOpen (val) {
if (val) {
this.$nextTick(() => this.$el.querySelector('textarea').focus())
}
}
},
methods: { methods: {
closeModal () { closeModal () {
this.$store.dispatch('closePostStatusModal') this.$store.dispatch('closePostStatusModal')