mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-03-05 05:00:03 +00:00
[Electron] Use electronAPI to get ComfyUI core version (#1804)
This commit is contained in:
@@ -3,6 +3,7 @@ import { defineStore } from 'pinia'
|
||||
import { computed } from 'vue'
|
||||
import { useSystemStatsStore } from './systemStatsStore'
|
||||
import { useExtensionStore } from './extensionStore'
|
||||
import { electronAPI, isElectron } from '@/utils/envUtil'
|
||||
|
||||
export const useAboutPanelStore = defineStore('aboutPanel', () => {
|
||||
const frontendVersion = __COMFYUI_FRONTEND_VERSION__
|
||||
@@ -13,8 +14,14 @@ export const useAboutPanelStore = defineStore('aboutPanel', () => {
|
||||
)
|
||||
|
||||
const coreBadges = computed<AboutPageBadge[]>(() => [
|
||||
// In electron, the ComfyUI is packaged without the git repo,
|
||||
// so the python server's API doesn't have the version info.
|
||||
{
|
||||
label: `ComfyUI ${coreVersion.value}`,
|
||||
label: `ComfyUI ${
|
||||
isElectron()
|
||||
? 'v' + electronAPI().getComfyUIVersion()
|
||||
: coreVersion.value
|
||||
}`,
|
||||
url: 'https://github.com/comfyanonymous/ComfyUI',
|
||||
icon: 'pi pi-github'
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user