mirror of
https://github.com/owntone/owntone-server.git
synced 2025-04-18 18:05:20 -04:00
26 lines
424 B
Vue
26 lines
424 B
Vue
<template>
|
|
<a :href="$router.resolve(to).href" @click.stop.prevent="open">
|
|
<slot />
|
|
</a>
|
|
</template>
|
|
|
|
<script>
|
|
import { useUIStore } from '@/stores/ui'
|
|
|
|
export default {
|
|
name: 'ControlLink',
|
|
props: {
|
|
to: { required: true, type: Object }
|
|
},
|
|
setup() {
|
|
return { uiStore: useUIStore() }
|
|
},
|
|
methods: {
|
|
open() {
|
|
this.uiStore.hideMenus()
|
|
this.$router.push(this.to)
|
|
}
|
|
}
|
|
}
|
|
</script>
|