webui: switch to hash-based routing (alternative of #16079) (#16157)

* Switched web UI to hash-based routing

* Added hash to missed goto function call

* Removed outdated SPA handling code

* Fixed broken sidebar home link
This commit is contained in:
Isaac McFadyen
2025-09-26 11:36:48 -04:00
committed by GitHub
parent 5d0a40f390
commit e0539eb6ae
14 changed files with 22 additions and 57 deletions

View File

@@ -100,7 +100,7 @@ class ChatStore {
this.maxContextError = null;
await goto(`/chat/${conversation.id}`);
await goto(`#/chat/${conversation.id}`);
return conversation.id;
}
@@ -910,7 +910,7 @@ class ChatStore {
if (this.activeConversation?.id === convId) {
this.activeConversation = null;
this.activeMessages = [];
await goto('/?new_chat=true');
await goto(`?new_chat=true#/`);
}
} catch (error) {
console.error('Failed to delete conversation:', error);