audio only seek in listen mode

This patch fixes the following problem: when a user selects audio only option below the
video title, On clicking the video chapters, The video plays instead of audio.
This commit is contained in:
Sai Karthik 2022-02-24 11:34:01 +05:30
parent f93f52051c
commit 4669be059f
No known key found for this signature in database
GPG key ID: F5B9A961BF6EAF0E
2 changed files with 6 additions and 1 deletions

View file

@ -33,6 +33,10 @@ export default {
selectedAutoPlay: Boolean,
selectedAutoLoop: Boolean,
isEmbed: Boolean,
onlyAudio: {
type: Boolean,
default: false,
},
},
data() {
return {
@ -442,7 +446,7 @@ export default {
this.$player = player;
const disableVideo = this.getPreferenceBoolean("listen", false) && !this.video.livestream;
const disableVideo = this.getPreferenceBoolean("listen", this.onlyAudio) && !this.video.livestream;
this.$player.configure({
preferredVideoCodecs: this.preferredVideoCodecs,

View file

@ -20,6 +20,7 @@
:sponsors="sponsors"
:selected-auto-play="selectedAutoPlay"
:selected-auto-loop="selectedAutoLoop"
:only-audio="isListening"
/>
<div class="font-bold mt-2 text-2xl break-words" v-text="video.title" />