0
0
Fork 0
mirror of https://github.com/VueTubeApp/VueTube synced 2024-11-12 14:35:06 +00:00
VueTube/NUXT/components/Player/playpause.vue
2022-06-08 14:05:00 -04:00

31 lines
547 B
Vue

<template>
<v-btn
fab
text
large
style="position: absolute; top: calc(50% - 2rem); left: calc(50% - 2rem)"
color="white"
@click.stop="
(paused = !video.paused), video.paused ? $emit('play') : $emit('pause')
"
>
<v-icon size="3.5rem">
{{ paused ? "mdi-play" : "mdi-pause" }}
</v-icon>
</v-btn>
</template>
<script>
export default {
props: {
video: {
type: Object,
required: true,
},
},
emits: ["play", "pause"],
data: () => ({
paused: false,
}),
};
</script>