diff --git a/static/player.ts b/static/player.ts index 480e7af..1541b19 100644 --- a/static/player.ts +++ b/static/player.ts @@ -858,6 +858,11 @@ const loadNextEpisodeInPlace = async (animeID: number, nextEpisode: number): Pro const nextUrl = `/watch/${animeID}/${nextEpisode}` window.history.replaceState(null, '', nextUrl) + + const episodesList = document.getElementById('episodes-list') + if (episodesList) { + htmx.ajax('GET', `/api/anime/${animeID}/episodes?current=${nextEpisode}`, episodesList) + } } const completeAnime = async (episodeNumber: number): Promise => { diff --git a/web/templates/watch.templ b/web/templates/watch.templ index 1d665fb..965222d 100644 --- a/web/templates/watch.templ +++ b/web/templates/watch.templ @@ -23,6 +23,7 @@ templ WatchPage(anime jikan.Anime, data shared.WatchPageData) {

Episodes