fix: calculate actual progress percentage for continue watching

This commit is contained in:
2026-05-02 20:09:13 +02:00
parent 594c2859ea
commit 248f234f73
9 changed files with 145 additions and 58 deletions

View File

@@ -21,10 +21,9 @@
</div>
</div>
{{if .CurrentTimeSeconds}}
<!-- Progress calculation would go here if total duration was available -->
{{if and .CurrentTimeSeconds .AnimeDurationSeconds.Valid}}
<div class="bg-foreground-muted/60 absolute bottom-0 left-0 h-1.5 w-full z-20">
<div class="shadow-background/20 bg-accent h-full shadow-[0_-2px_5px_0]" style="width: 50%"></div>
<div class="shadow-background/20 bg-accent h-full shadow-[0_-2px_5px_0]" style="width: {{percent .CurrentTimeSeconds .AnimeDurationSeconds.Float64}}%"></div>
</div>
{{end}}
</div>