BrightspaceUILabs / file-uploader

Polymer-based web component for D2L file uploader
Apache License 2.0
4 stars 6 forks source link

Reset the input value so that the user can re-upload the same file an… #71

Closed TomMichielsD2L closed 4 years ago

TomMichielsD2L commented 4 years ago

…d the event will fire

The browse for file logic is inconsistent with the drag and drop logic, as well as the logic on the MVC version of this. The inconsistency is that we do not fire the d2l-file-uploader-files-added event if the user attempts to upload the same file twice in a row.

This change resets the value of the input after we handle its on change event. This allows us to receive events if the user repeatedly uploads the same file.