feat: 新增应用更新功能和关于页面
- 集成 Tauri updater 实现应用版本检查与更新 - 添加关于页面,展示项目介绍、使用流程和版本信息 - 新增顶部栏检查更新和 GitHub 入口 - 完善国际化文案和更新弹窗组件
This commit is contained in:
@@ -12,17 +12,28 @@
|
||||
<router-view />
|
||||
</main>
|
||||
</div>
|
||||
|
||||
<!-- 全局更新弹窗 -->
|
||||
<UpdateModal />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import Header from "./header/Header.vue"
|
||||
import Aside from "./aside/Aside.vue"
|
||||
import UpdateModal from "@/components/UpdateModal.vue"
|
||||
import { useUpdateStore } from "@/stores/update"
|
||||
|
||||
const router = useRouter()
|
||||
const updateStore = useUpdateStore()
|
||||
|
||||
/** 点击标题栏“设置”按钮 → 跳转设置页 */
|
||||
function goToSetting() {
|
||||
router.push("/setting")
|
||||
}
|
||||
|
||||
// 应用启动后静默检查一次更新(已忽略的版本不会打扰用户)
|
||||
onMounted(() => {
|
||||
updateStore.checkForUpdate(true)
|
||||
})
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user