[System Pop Up] Add setting to disable version update notifications (#4388)

This commit is contained in:
bmcomfy
2025-07-08 14:43:11 -07:00
committed by Terry Jia
parent fc35d2227c
commit 6e8a9ae41f
7 changed files with 441 additions and 5 deletions

View File

@@ -54,7 +54,7 @@
</Teleport>
<!-- What's New Section -->
<section class="whats-new-section">
<section v-if="showVersionUpdates" class="whats-new-section">
<h3 class="section-description">{{ $t('helpCenter.whatsNew') }}</h3>
<!-- Release Items -->
@@ -126,6 +126,7 @@ import { useI18n } from 'vue-i18n'
import { type ReleaseNote } from '@/services/releaseService'
import { useCommandStore } from '@/stores/commandStore'
import { useReleaseStore } from '@/stores/releaseStore'
import { useSettingStore } from '@/stores/settingStore'
import { electronAPI, isElectron } from '@/utils/envUtil'
import { formatVersionAnchor } from '@/utils/formatUtil'
@@ -168,6 +169,7 @@ const SUBMENU_CONFIG = {
const { t, locale } = useI18n()
const releaseStore = useReleaseStore()
const commandStore = useCommandStore()
const settingStore = useSettingStore()
// Emits
const emit = defineEmits<{
@@ -182,6 +184,9 @@ let hoverTimeout: number | null = null
// Computed
const hasReleases = computed(() => releaseStore.releases.length > 0)
const showVersionUpdates = computed(() =>
settingStore.get('Comfy.Notification.ShowVersionUpdates')
)
const moreMenuItem = computed(() =>
menuItems.value.find((item) => item.key === 'more')