mirror of
https://github.com/VueTubeApp/VueTube
synced 2024-11-26 13:13:03 +00:00
seekbar more clean
This commit is contained in:
parent
67e3ff1f31
commit
2a028606a8
2 changed files with 7 additions and 4 deletions
|
@ -271,6 +271,11 @@
|
||||||
:sources="sources"
|
:sources="sources"
|
||||||
:seeking="seeking"
|
:seeking="seeking"
|
||||||
@seeking="seeking = !seeking"
|
@seeking="seeking = !seeking"
|
||||||
|
@scrub="
|
||||||
|
(e) => {
|
||||||
|
$refs.player.currentTime = e;
|
||||||
|
}
|
||||||
|
"
|
||||||
/>
|
/>
|
||||||
<sponsorblock
|
<sponsorblock
|
||||||
v-if="$refs.player && blocks.length > 0"
|
v-if="$refs.player && blocks.length > 0"
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
:value="currentTime"
|
:value="currentTime"
|
||||||
@start="$emit('seeking')"
|
@start="$emit('seeking')"
|
||||||
@end="$emit('seeking')"
|
@end="$emit('seeking')"
|
||||||
@change="scrub($event)"
|
@change="$emit('scrub', $event)"
|
||||||
@input="seeking ? seek($event) : null"
|
@input="seeking ? seek($event) : null"
|
||||||
>
|
>
|
||||||
<template #thumb-label="{ value }">
|
<template #thumb-label="{ value }">
|
||||||
|
@ -86,6 +86,7 @@ export default {
|
||||||
required: true,
|
required: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
emits: ["scrub", "seeking"],
|
||||||
data: () => ({
|
data: () => ({
|
||||||
vidWrs: "",
|
vidWrs: "",
|
||||||
}),
|
}),
|
||||||
|
@ -108,9 +109,6 @@ export default {
|
||||||
this.video.clientHeight / 3
|
this.video.clientHeight / 3
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
scrub(e) {
|
|
||||||
this.video.currentTime = e;
|
|
||||||
},
|
|
||||||
// TODO: better scrubbing preview (don't delet ples 🙏)
|
// TODO: better scrubbing preview (don't delet ples 🙏)
|
||||||
// loadVideoFrames() {
|
// loadVideoFrames() {
|
||||||
// // Exit loop if desired number of frames have been extracted
|
// // Exit loop if desired number of frames have been extracted
|
||||||
|
|
Loading…
Reference in a new issue