Skip to content
This repository has been archived by the owner on Jan 15, 2024. It is now read-only.

Commit

Permalink
Hide the status message when the selected file changes (#381)
Browse files Browse the repository at this point in the history
  • Loading branch information
metadaddy committed Nov 1, 2023
1 parent 75c62f0 commit 31e58cb
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/index.js
Expand Up @@ -25,6 +25,12 @@ document.addEventListener("DOMContentLoaded", () => {
const uploadFileInput = document.getElementById("uploadFileInput");
const uploadFileButton = document.getElementById("uploadFileButton");

// When selected file changes, hide the status message
uploadFileInput.addEventListener("change", async () => {
const ref = document.getElementById('result-message-container');
ref.removeAttribute('class');
});

// When upload button clicked, get upload details and then perform file
// upload with AJAX.
uploadFileButton.addEventListener("click", async () => {
Expand Down

0 comments on commit 31e58cb

Please sign in to comment.