Add caption download links when Invidious API is enabled

This commit is contained in:
Preston 2020-10-19 15:16:56 -04:00
parent 1086d7b516
commit c7ac9a8415
1 changed files with 9 additions and 1 deletions

View File

@ -547,7 +547,15 @@ export default Vue.extend({
} }
return object return object
}).reverse() }).reverse().concat(result.captions.map((caption) => {
const label = `${caption.label} (${caption.languageCode}) - text/vtt`
const object = {
url: caption.url,
label: label
}
return object
}))
this.audioSourceList = result.adaptiveFormats.filter((format) => { this.audioSourceList = result.adaptiveFormats.filter((format) => {
return format.type.includes('audio') return format.type.includes('audio')