23 / resumable.js

A JavaScript library for providing multiple simultaneous, stable, fault-tolerant and resumable/restartable uploads via the HTML5 File API.
MIT License
4.65k stars 611 forks source link

Add alternative for assignbrowse/assigndrop that can be called from outside #609

Closed UniquePanda closed 1 year ago

UniquePanda commented 1 year ago

There actually already were two functions for exactly that purpose.
handleDropEvent can be called with an external DragEvent when a file was dropped somewhere.
handleChangeEvent can be called with an external InputEvent when files were added to an input element.

The only thing I had to change was to move some CSS handling from handleDropEvent into an own function, so that this can still be done when assignDrop was used, but is not always done when handleDropEvent is called from the outside.

Additionally I also did some minor changes tot he test.html. This file is very barebones but maybe we can use it in the future and now it at least works again. 😄

UniquePanda commented 1 year ago

Damn, wrong base Repo^^

steffentchr commented 1 year ago

@UniquePanda :D