mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2026-07-07 18:01:42 +00:00
feat: Add Series and Sequence number to the playlist view for items when applicable
This commit is contained in:
parent
88667d00a1
commit
b266828b45
1 changed files with 14 additions and 0 deletions
|
|
@ -19,6 +19,9 @@
|
|||
<div class="truncate max-w-48 md:max-w-md">
|
||||
<nuxt-link :to="`/item/${libraryItem.id}`" class="truncate hover:underline text-sm md:text-base">{{ itemTitle }}</nuxt-link>
|
||||
</div>
|
||||
<div v-if="seriesList.length" class="truncate max-w-48 md:max-w-md text-xs md:text-sm text-gray-300">
|
||||
<nuxt-link v-for="_series in seriesList" :key="_series.id" :to="`/library/${libraryItem.libraryId}/series/${_series.id}`" class="hover:underline font-sans text-gray-300"> {{ _series.text }}</nuxt-link>
|
||||
</div>
|
||||
<div class="truncate max-w-48 md:max-w-md text-xs md:text-sm text-gray-300">
|
||||
<template v-for="(author, index) in bookAuthors">
|
||||
<nuxt-link :key="author.id" :to="`/author/${author.id}`" class="truncate hover:underline">{{ author.name }}</nuxt-link
|
||||
|
|
@ -105,6 +108,17 @@ export default {
|
|||
if (this.episode) return []
|
||||
return this.mediaMetadata.authors || []
|
||||
},
|
||||
series() {
|
||||
if (this.episode) return []
|
||||
return this.mediaMetadata.series || []
|
||||
},
|
||||
seriesList() {
|
||||
return this.series.map((se) => {
|
||||
let text = se.name
|
||||
if (se.sequence) text += ` #${se.sequence}`
|
||||
return { ...se, text }
|
||||
})
|
||||
},
|
||||
itemDuration() {
|
||||
if (this.episode) return this.$elapsedPretty(this.episode.duration)
|
||||
return this.$elapsedPretty(this.media.duration)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue