diff --git a/components/tables/playlist/ItemTableRow.vue b/components/tables/playlist/ItemTableRow.vue index 2e054442..c2a46e7b 100644 --- a/components/tables/playlist/ItemTableRow.vue +++ b/components/tables/playlist/ItemTableRow.vue @@ -1,22 +1,25 @@ @@ -30,10 +33,7 @@ export default { } }, data() { - return { - isProcessingReadUpdate: false, - processingRemove: false - } + return {} }, computed: { libraryItem() { @@ -92,12 +92,6 @@ export default { coverWidth() { return 50 }, - isMissing() { - return this.libraryItem.isMissing - }, - isInvalid() { - return this.libraryItem.isInvalid - }, showPlayBtn() { return !this.isMissing && !this.isInvalid && (this.tracks.length || this.episode) }, @@ -107,6 +101,15 @@ export default { }, streamIsPlaying() { return this.$store.state.playerIsPlaying && this.isStreaming + }, + userItemProgress() { + return this.$store.getters['user/getUserMediaProgress'](this.libraryItem.id, this.episodeId) + }, + userIsFinished() { + return !!this.userItemProgress?.isFinished + }, + progressPercent() { + return this.userItemProgress ? Math.max(Math.min(1, this.userItemProgress.progress), 0) : 0 } }, methods: { diff --git a/components/tables/playlist/PlaylistItemsTable.vue b/components/tables/playlist/PlaylistItemsTable.vue index 9a2d5ce0..292fe270 100644 --- a/components/tables/playlist/PlaylistItemsTable.vue +++ b/components/tables/playlist/PlaylistItemsTable.vue @@ -1,7 +1,7 @@