fix: 修复新建项目无响应问题
- 替换 prompt() 为 InputDialog Vue 模态组件 - 替换 alert()/confirm() 为 Electron showMessageBox IPC - 添加 dialog:showMessage / dialog:showConfirm IPC 通道
This commit is contained in:
@@ -74,7 +74,11 @@ async function importFromFiles() {
|
||||
}
|
||||
|
||||
async function handleDelete(relativePath) {
|
||||
if (confirm(`确定删除 "${relativePath}"?`)) {
|
||||
const ok = await window.api.dialog.showConfirm({
|
||||
title: '删除确认',
|
||||
message: `确定要删除 "${relativePath}" 吗?`
|
||||
})
|
||||
if (ok) {
|
||||
await store.removeFile(relativePath)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user