diff options
| author | 2026-01-16 14:16:42 +0800 | |
|---|---|---|
| committer | 2026-01-16 14:18:21 +0800 | |
| commit | d0e7da7ec7745be3d34efe3949c0592f6723136a (patch) | |
| tree | 78fcd73118f5f001d70670cb30b87d973ab7cee4 /ui/src/stores/logs.svelte.ts | |
| parent | f1eaa8fcc90c3fec0bcedc1ce060f1dcfea5bcd6 (diff) | |
| download | DropOut-d0e7da7ec7745be3d34efe3949c0592f6723136a.tar.gz DropOut-d0e7da7ec7745be3d34efe3949c0592f6723136a.zip | |
feat: implement assistant state management and messaging functionality
Added a new module for managing the assistant's state, including message handling, health checks, and streaming responses. Introduced interfaces for message structure and generation statistics. Enhanced the logs state by removing unnecessary listener setup during initialization. Updated the types to include assistant configuration options.
Diffstat (limited to 'ui/src/stores/logs.svelte.ts')
| -rw-r--r-- | ui/src/stores/logs.svelte.ts | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/ui/src/stores/logs.svelte.ts b/ui/src/stores/logs.svelte.ts index 5df9abc..c9d4acc 100644 --- a/ui/src/stores/logs.svelte.ts +++ b/ui/src/stores/logs.svelte.ts @@ -39,7 +39,6 @@ export class LogsState { constructor() { this.addLog("info", "Launcher", "Logs initialized"); - this.setupListeners(); } addLog(level: LogEntry["level"], source: string, message: string) { @@ -95,7 +94,12 @@ export class LogsState { .join("\n"); } - private async setupListeners() { + private initialized = false; + + async init() { + if (this.initialized) return; + this.initialized = true; + // General Launcher Logs await listen<string>("launcher-log", (e) => { this.addLog("info", "Launcher", e.payload); |