Adds a player setting to use chapter duration in the player Chapter modal.

Allows users to view chapter duration instead of start time in the player chapter list.
This commit is contained in:
sir-wilhelm
2025-11-04 19:37:31 -06:00
parent 072f19e157
commit 9b8536a581
3 changed files with 15 additions and 3 deletions
+3 -2
View File
@@ -14,7 +14,7 @@
<div class="relative flex items-center pl-3 pr-20">
<p class="font-normal block truncate text-sm text-fg/80">{{ chapter.title }}</p>
<div class="absolute top-0 right-3 -mt-0.5">
<span class="font-mono text-fg-muted leading-3 text-sm" style="letter-spacing: -0.5px">{{ $secondsToTimestamp(chapter.start / _playbackRate) }}</span>
<span class="font-mono text-fg-muted leading-3 text-sm" style="letter-spacing: -0.5px">{{ $secondsToTimestamp(((useChapterDuration ? Math.max(0, chapter.end - chapter.start) : chapter.start) / _playbackRate)) }}</span>
</div>
</div>
@@ -39,7 +39,8 @@ export default {
type: Object,
default: () => null
},
playbackRate: Number
playbackRate: Number,
useChapterDuration: Boolean
},
data() {
return {}