From b19f7ca228188afe16c412d37dab5c731cec7f38 Mon Sep 17 00:00:00 2001 From: Chenlei Hu Date: Sun, 29 Dec 2024 18:07:22 -0500 Subject: [PATCH] Add BaseViewTemplate (#2094) --- src/router.ts | 6 ++++++ src/views/DownloadGitView.vue | 7 +++---- src/views/InstallView.vue | 8 +++----- src/views/ManualConfigurationView.vue | 7 +++---- src/views/NotSupportedView.vue | 7 +++---- src/views/ServerStartView.vue | 7 +++---- src/views/UserSelectView.vue | 9 ++++----- src/views/WelcomeView.vue | 7 +++---- src/views/templates/BaseViewTemplate.vue | 23 +++++++++++++++++++++++ vite.electron.config.mts | 3 ++- 10 files changed, 53 insertions(+), 31 deletions(-) create mode 100644 src/views/templates/BaseViewTemplate.vue diff --git a/src/router.ts b/src/router.ts index 39bad89b3..7c70bc9b1 100644 --- a/src/router.ts +++ b/src/router.ts @@ -84,6 +84,12 @@ const router = createRouter({ name: 'DownloadGitView', component: () => import('@/views/DownloadGitView.vue'), beforeEnter: guardElectronAccess + }, + { + path: 'manual-configuration', + name: 'ManualConfigurationView', + component: () => import('@/views/ManualConfigurationView.vue'), + beforeEnter: guardElectronAccess } ] } diff --git a/src/views/DownloadGitView.vue b/src/views/DownloadGitView.vue index 720eaeb27..56b67ef38 100644 --- a/src/views/DownloadGitView.vue +++ b/src/views/DownloadGitView.vue @@ -1,7 +1,5 @@ diff --git a/vite.electron.config.mts b/vite.electron.config.mts index 5b767af27..a2ec411b1 100644 --- a/vite.electron.config.mts +++ b/vite.electron.config.mts @@ -51,7 +51,8 @@ const mockElectronAPI: Plugin = { onDownloadProgress: () => {} }, getElectronVersion: () => Promise.resolve('1.0.0'), - getComfyUIVersion: () => '9.9.9' + getComfyUIVersion: () => '9.9.9', + getPlatform: () => 'win32' };` } ]