fix: TypeScript-Fehler im Frontend beheben

- AudioPlayer: findLast → reverse().find() (ES2022 Kompatibilität)
- ChapterList: findLastIndex → manuelles for-loop + implizit any behoben
- Library: searchDebounce Variable 't' undefined → korrekte Initialisierung

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Audiolib
2026-05-26 13:16:16 +02:00
parent 52c10a7518
commit c65b8ba5cf
3 changed files with 7 additions and 4 deletions

View File

@@ -50,8 +50,8 @@ export default function Library() {
const searchDebounce = useCallback(
(() => {
let t: ReturnType<typeof setTimeout>
return (v: string) => { clearTimeout(t); setSearch(v); setPage(0) }
let t: ReturnType<typeof setTimeout> | undefined
return (v: string) => { clearTimeout(t); t = setTimeout(() => { setSearch(v); setPage(0) }, 300) }
})(),
[]
)