Revert "remove unnecessary shit"

This reverts commit 3623d8b265.
pull/200/head
Aevann 2023-09-06 17:17:05 +03:00
parent b4823b1509
commit 47f099bf36
1 changed files with 7 additions and 0 deletions

View File

@ -351,9 +351,16 @@ document.addEventListener('click', function (e) {
const input = document.getElementById('file')
function handle_files() {
if (!input.files.length) return
input.previousElementSibling.textContent = input.files[0].name.substr(0, 50);
}
input.onchange = handle_files
document.onpaste = function(event) {
input.files = structuredClone(event.clipboardData.files);
handle_files()
}
box.scrollTo(0, box.scrollHeight)