优化。

pull/303/head
王良 2024-04-23 16:35:23 +08:00
parent ec1b90882a
commit f7bc297b40
1 changed files with 12 additions and 5 deletions

View File

@ -61,19 +61,26 @@ function install (app, api) {
updateParams.progress = value updateParams.progress = value
} }
function openGithubUrl () {
api.ipc.openExternal('https://github.com/docmirror/dev-sidecar/releases')
}
function goManualUpdate (value) { function goManualUpdate (value) {
updateParams.newVersion = false updateParams.newVersion = false
app.$confirm({ app.$confirm({
// title: '暂不支持自动升级', // title: '暂不支持自动升级',
title: '暂不提供自动升级', title: '暂不提供自动升级',
cancelText: '取消', cancelText: '取消',
okText: '确定', okText: '打开',
width: 420, width: 420,
content: h => { content: h => {
function openGithubUrl () { return <div>
api.ipc.openExternal('https://github.com/docmirror/dev-sidecar/releases') <div>请前往 <a onClick={openGithubUrl}>github项目release页面</a> </div>
} <div><a onClick={openGithubUrl}>https://github.com/docmirror/dev-sidecar/releases</a></div>
return <div>请前往 <a onClick={openGithubUrl}>github项目release页面</a> </div> </div>
},
onOk () {
openGithubUrl()
} }
}) })
} }