-
-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(upload): handle uploading folders and multiple files #44
base: master
Are you sure you want to change the base?
Conversation
This branch #45 adds support for uploading folders from the menu. Hopefully it can be merged after this. |
If there's anything I can do to help make this easier to review, please let me know (e.g. breaking this PR into smaller ones) |
This looks pretty good @Dorosty! Haven't had a chance to fully very everything because I started a new job last week and been insanely busy. Things are now finally cooling down though, so I'll take a closer look and get back to you ASAP. |
Another contributor brought up a relevant issue recently: os-js/OS.js#847 |
Congratulations & TYSM 🙏 |
This would require a change in the system vfs adapter in osjs-client, which would require multiple PRs. May I suggest we merge this one first & then I will add the cancellability feature in separate PRs. |
Hmm. I kinda feel like cancellation should be added first, but there's nothing really in the way to take this one first. |
|
This is done BTW |
Finally found some time to test this out (on various platforms). Seems to be working great! I just have one final comment that came to mind while testing. It would be really nice if this feature could be set via a configuration that defaults to true (like |
Would this be a good config schema? filemanager: {
uploadMethod: 'single' | 'multiple',
} |
Just a simple boolean would suffice: |
Done! 🎉 please note that os-js/osjs-client#216 should also be merged for |
@@ -48,6 +48,14 @@ import { | |||
listView | |||
} from '@osjs/gui'; | |||
|
|||
|
|||
/** | |||
* flag indicating whether uploading folders is supported |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you capitalize this comment? Other than that, looks great!
dataTransferProperty
todroppable
osjs-client#213progressDialog
has been changed to take a string instead of a file, so that when we are uploading multiple files, the title of the dialog would be 'Uploading multiple files...'uploadBrowserFiles
has been completely re-implemented to allow uploading multiple files, and also recursively handling folders and their content.