akkoma-fe/src/components/user_finder/user_finder.js

20 lines
382 B
JavaScript
Raw Normal View History

2017-05-12 16:54:12 +00:00
const UserFinder = {
data: () => ({
username: undefined,
2017-09-10 17:46:42 +00:00
hidden: true,
error: false,
loading: false
2017-05-12 16:54:12 +00:00
}),
methods: {
findUser (username) {
2018-11-14 19:29:45 +00:00
this.$router.push({ name: 'user-search', query: { query: username } })
},
toggleHidden () {
this.hidden = !this.hidden
this.$emit('toggled', this.hidden)
2017-05-12 16:54:12 +00:00
}
}
}
export default UserFinder