Hey there, I'm currently in the process of uploading a folder. However, I encountered an issue when trying to upload the same folder again. It seems that the data was empty when I attempted to set it to null.
const uploadFolders = [];
let uploadFolderTemplate = ``;
function upload(e) {
const files = e.target.files;
if (files.length > 0) {
uploadFolders.push(files);
uploadFolderTemplate = `
<div class="card folder-list-info">
<div class="card-header" style="display: inline-flex;">
<span>${files[0].path}</span>
<button type="button" class="close" aria-label="Close" style="margin-left: auto">
<span aria-hidden="true">×</span>
</button>
</div>
<div class="card-body">
<div class="ext-box">
</div>
<div class="colum-box">
</div>
<div class="exports-data-file-box">
</div>
</div>
</div>`;
}
}
const folderUploadInput = document.querySelector('.folder-upload-input');
folderUploadInput.addEventListener('click', function (e) {
e.target.value = null;
});
folderUploadInput.addEventListener('change', upload)