From f5437dae4a253b73e2f7f49da8e5af35bd813bbd Mon Sep 17 00:00:00 2001 From: Timothy Jaeryang Baek Date: Fri, 17 Jan 2025 17:05:52 -0800 Subject: [PATCH] refac: electron app --- src/lib/stores/index.ts | 2 +- src/routes/+layout.svelte | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/lib/stores/index.ts b/src/lib/stores/index.ts index 88999afbf..15592ee09 100644 --- a/src/lib/stores/index.ts +++ b/src/lib/stores/index.ts @@ -13,7 +13,7 @@ export const user: Writable = writable(undefined); // Electron App export const isApp = writable(false); -export const appVersion = writable(null); +export const appInfo = writable(null); // Frontend export const MODEL_DOWNLOAD_POOL = writable({}); diff --git a/src/routes/+layout.svelte b/src/routes/+layout.svelte index bbf473541..862e0b077 100644 --- a/src/routes/+layout.svelte +++ b/src/routes/+layout.svelte @@ -24,7 +24,7 @@ temporaryChatEnabled, isLastActiveTab, isApp, - appVersion + appInfo } from '$lib/stores'; import { goto } from '$app/navigation'; import { page } from '$app/stores'; @@ -203,12 +203,12 @@ onMount(async () => { if (window?.electronAPI) { const res = await window.electronAPI.send({ - type: 'version' + type: 'info' }); if (res) { isApp.set(true); - appVersion.set(res.version); + appInfo.set(res); } }