Autofocus search input in case no query is present

This commit is contained in:
Nachtalb 2021-05-06 03:24:20 +02:00
parent 24a738d521
commit cadcc4b97c
No known key found for this signature in database
GPG key ID: E48DF13C07055D92

View file

@ -104,6 +104,10 @@ export default {
mounted() {
this.searchInput = this.$route.query.q;
this.searchOpened = this.onSearchPage;
if (!this.searchInput) {
this.$refs.searchInputField.focus();
}
},
methods: {
closeSearch() {