Catch closing dialogs

This commit is contained in:
Natsumi
2025-10-17 11:27:19 +11:00
parent 529c6c2b04
commit 9e95e1734c
5 changed files with 99 additions and 85 deletions

View File

@@ -186,17 +186,18 @@
await updateRegistryBackupDialog();
}
async function promptVrcRegistryBackupName() {
try {
const { value } = await ElMessageBox.prompt('Enter a name for the backup', 'Backup Name', {
confirmButtonText: 'Confirm',
cancelButtonText: 'Cancel',
inputPattern: /\S+/,
inputErrorMessage: 'Name is required',
inputValue: 'Backup'
});
await handleBackupVrcRegistry(value);
} catch (error) {}
function promptVrcRegistryBackupName() {
ElMessageBox.prompt('Enter a name for the backup', 'Backup Name', {
confirmButtonText: 'Confirm',
cancelButtonText: 'Cancel',
inputPattern: /\S+/,
inputErrorMessage: 'Name is required',
inputValue: 'Backup'
})
.then(({ value }) => {
handleBackupVrcRegistry(value);
})
.catch(() => {});
}
async function openJsonFileSelectorDialogElectron() {

View File

@@ -1131,8 +1131,6 @@
});
}
})
.catch(() => {
// on cancel
});
.catch(() => {});
}
</script>