0
0
Fork 0
mirror of https://github.com/VueTubeApp/VueTube synced 2024-11-23 11:45:15 +00:00
VueTube/NUXT/components/Player/progressbar.vue

53 lines
1,012 B
Vue
Raw Normal View History

<template>
<v-progress-linear
2022-06-07 17:16:26 +00:00
style="
z-index: 2;
position: absolute;
background: #ffffff22;
transform: translateY(50%);
"
background-opacity="0.5"
2022-06-07 17:16:26 +00:00
background-color="white"
:buffer-value="buffered"
2022-06-08 16:34:52 +00:00
:value="(currentTime / duration) * 100"
2022-06-01 19:02:02 +00:00
:class="!fullscreen || controls ? '' : 'invisible'"
color="primary"
2022-06-07 17:16:26 +00:00
:height="seeking ? 4 : 2"
:style="
fullscreen
2022-06-08 20:15:15 +00:00
? 'width: calc(100% - 2rem); left: 1rem; bottom: 3.5rem;'
2022-06-07 17:16:26 +00:00
: 'width: 100%; left: 0; bottom: 1px;'
"
/>
</template>
<script>
export default {
props: {
2022-06-08 16:34:52 +00:00
duration: {
type: Object,
required: true,
},
2022-06-07 17:16:26 +00:00
seeking: {
type: Boolean,
required: true,
},
fullscreen: {
type: Boolean,
required: true,
},
currentTime: {
type: Number,
required: true,
},
2022-06-01 19:05:19 +00:00
controls: {
type: Boolean,
required: true,
},
2022-06-08 15:59:43 +00:00
buffered: {
type: Number,
required: true,
},
},
};
</script>