Add Podcast match tab and find covers

This commit is contained in:
advplyr 2022-04-13 18:13:39 -05:00
parent 4edba20e9e
commit 3f6ed6dbf9
10 changed files with 113 additions and 20 deletions

View file

@ -116,19 +116,16 @@ export default {
userCanDownload() {
return this.$store.getters['user/getUserCanDownload']
},
showExperimentalFeatures() {
return this.$store.state.showExperimentalFeatures
},
availableTabs() {
if (!this.userCanUpdate && !this.userCanDownload) return []
return this.tabs.filter((tab) => {
if (tab.id === 'download' && this.isMissing) return false
if (this.mediaType == 'podcast' && (tab.id == 'match' || tab.id == 'chapters')) return false
if (this.mediaType == 'podcast' && tab.id == 'chapters') return false
if (this.mediaType == 'book' && tab.id == 'episodes') return false
if ((tab.id === 'download' || tab.id === 'files') && this.userCanDownload) return true
if (tab.id !== 'download' && tab.id !== 'files' && this.userCanUpdate) return true
if (tab.id === 'match' && this.userCanUpdate && this.showExperimentalFeatures) return true
if (tab.id === 'match' && this.userCanUpdate) return true
return false
})
},