This commit is contained in:
Lance Borden 2025-04-19 05:56:01 +00:00 committed by GitHub
commit b03d915213
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 36 additions and 5 deletions

View file

@ -30,6 +30,28 @@ function hideUploadProgress() {
$('#uploadingOverlay').css('display', 'none')
}
function showMovingProgress() {
$('#movingOverlay').css('display', 'block');
}
function hideMovingProgress() {
$('#movingOverlay').css('display', 'none');
}
function moveFileToFolder(event, folderName) {
event.preventDefault();
event.stopPropagation();
const fullUrl = event.dataTransfer.getData('text/uri-list');
const url = new URL(fullUrl);
let fileName = url.pathname;
$('#moveCurrentPath').val(fileName.slice(1));
fileName = fileName.split('/').pop();
$('#moveNewPath').val(folderName + '/' + fileName);
$('#moveFileForm').submit();
}
$('#createDir').on('shown', function () {
$('#newDirInput').focus();
})