mirror of https://github.com/jetkvm/kvm.git
add confirm prompt to delete file
This commit is contained in:
parent
3b83f4c7a1
commit
bdafce51aa
|
@ -839,7 +839,9 @@ function DeviceFileView({
|
|||
onDelete={() => {
|
||||
const selectedFile = onStorageFiles.find(f => f.name === file.name);
|
||||
if (!selectedFile) return;
|
||||
handleDeleteFile(selectedFile);
|
||||
if (window.confirm("Are you sure you want to delete " + selectedFile.name + "?")) {
|
||||
handleDeleteFile(selectedFile);
|
||||
}
|
||||
}}
|
||||
onSelect={() => handleOnSelectFile(file)}
|
||||
onContinueUpload={() => onNewImageClick(file.name)}
|
||||
|
|
Loading…
Reference in New Issue