feat(ui): add auto-refresh after upload and inline file preview
- Auto-refresh files table after successful uploads using custom event - Add inline preview support for PDFs, images, and text files - Set Content-Disposition header to inline for preview endpoint - Add download button as secondary action in file details view Co-authored-by: christianlouis <361235+christianlouis@users.noreply.github.com>
This commit is contained in:
@@ -195,6 +195,12 @@ function updateOverallStatus(statusMessage) {
|
||||
|
||||
if (completed === total) {
|
||||
statusMessage.textContent = `All uploads completed (${completed}/${total})`;
|
||||
|
||||
// Trigger a custom event when all uploads are complete
|
||||
const allUploadsComplete = new CustomEvent('allUploadsComplete', {
|
||||
detail: { total: total, completed: completed }
|
||||
});
|
||||
window.dispatchEvent(allUploadsComplete);
|
||||
} else {
|
||||
statusMessage.textContent = `Uploading files (${completed}/${total})`;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user