From 27a2596830fba11083a7977314b063262d0644cc Mon Sep 17 00:00:00 2001 From: Baobhan Sith <80159437+Heavrnl@users.noreply.github.com> Date: Tue, 29 Apr 2025 20:06:06 +0800 Subject: [PATCH] Update SettingsView.vue --- packages/frontend/src/views/SettingsView.vue | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/packages/frontend/src/views/SettingsView.vue b/packages/frontend/src/views/SettingsView.vue index 9415346..451703d 100644 --- a/packages/frontend/src/views/SettingsView.vue +++ b/packages/frontend/src/views/SettingsView.vue @@ -528,8 +528,12 @@ -
- Version: 0.1.0 | Heavrnl/nexus-terminal +
+
+ Version: {{ appVersion }} + | + Heavrnl/nexus-terminal +
@@ -546,6 +550,7 @@ interface UpdateCaptchaSettingsDto { recaptchaSecretKey?: string; } import { ref, onMounted, computed, reactive, watch } from 'vue'; +import pkg from '../../package.json'; // 导入 package.json import { useAuthStore } from '../stores/auth.store'; import { useSettingsStore } from '../stores/settings.store'; import { useAppearanceStore } from '../stores/appearance.store'; // 导入外观 store @@ -561,8 +566,9 @@ const authStore = useAuthStore(); const settingsStore = useSettingsStore(); const appearanceStore = useAppearanceStore(); // 实例化外观 store const { t } = useI18n(); - -// --- Reactive state from store --- +const appVersion = ref(pkg.version); // 获取版本号 + + // --- Reactive state from store --- // 使用 storeToRefs 获取响应式 getter,包括 language const { settings,