From 6eaee06bfd19da68030d12dfbe17a26f07719528 Mon Sep 17 00:00:00 2001
From: Fuwn <contact@fuwn.net>
Date: Sat, 28 Mar 2026 08:49:52 +0000
Subject: fix(filters): apply list filter changes immediately

---
 src/lib/List/Anime/CleanAnimeList.svelte | 12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)

(limited to 'src/lib/List/Anime/CleanAnimeList.svelte')

diff --git a/src/lib/List/Anime/CleanAnimeList.svelte b/src/lib/List/Anime/CleanAnimeList.svelte
index 683e54b4..808a8e5b 100644
--- a/src/lib/List/Anime/CleanAnimeList.svelte
+++ b/src/lib/List/Anime/CleanAnimeList.svelte
@@ -95,9 +95,13 @@ $: filteredMedia =
 		? media
 		: media.filter((m) => m.mediaListEntry?.customLists?.[selectedList]);
 
-const updateSelectedList = () => {
-	if (!disableFilter && $stateBin[filterKey] !== selectedList)
-		$stateBin[filterKey] = selectedList;
+const updateSelectedList = (event: Event) => {
+	const nextSelectedList = (event.currentTarget as HTMLSelectElement).value;
+
+	selectedList = nextSelectedList;
+
+	if (!disableFilter && $stateBin[filterKey] !== nextSelectedList)
+		$stateBin[filterKey] = nextSelectedList;
 };
 
 const clearAiringRefreshTimeout = () => {
@@ -238,7 +242,7 @@ const increment = (anime: Media, progress: number) => {
     Force refresh
   </button>
 {:else if $settings.displayMediaListFilter && !disableFilter}
-  <select bind:value={selectedList} onchange={updateSelectedList}>
+  <select value={selectedList} onchange={updateSelectedList}>
     <option value="All">All</option>
 
     {#each lists as list}
-- 
cgit v1.2.3

