diff --git a/src/lib/components/layout/Sidebar.svelte b/src/lib/components/layout/Sidebar.svelte index a14855dc..73b6e8b3 100644 --- a/src/lib/components/layout/Sidebar.svelte +++ b/src/lib/components/layout/Sidebar.svelte @@ -15,6 +15,7 @@ let importFiles; let title: string = 'Ollama Web UI'; + let search = ''; let chatTitleEditIdx = null; let chatTitle = ''; @@ -82,7 +83,7 @@
+
+ +
+ +
+ +
+
+
+ + + +
+ + +
-
- {#each $chats as chat, i} +
+ {#each $chats.filter((chat) => { + if (search === '') { + return true; + } else { + let title = chat.title.toLowerCase(); + + if (title.includes(search)) { + return true; + } else { + return false; + } + } + }) as chat, i}