cypht-org / cypht

Cypht: Lightweight Open Source webmail aggregator [PHP, JS]. Supports IMAP/SMTP, JMAP and soon EWS
http://cypht.org
GNU Lesser General Public License v2.1
1.01k stars 163 forks source link

File uploads: more features, and online storage (pick/save file from/to web app) #351

Open marclaporte opened 5 years ago

marclaporte commented 5 years ago

For the Cypht-Tiki integration, I envisage some file management enhancements

1- More features for file uploading, such as these: https://github.com/blueimp/jQuery-File-Upload#features

2- To be able to pick files and save to an existing virtual disk. In Kolab, this is called Chwala https://kolabian.wordpress.com/2018/10/17/folder-sharing-in-files/ https://git.kolab.org/diffusion/C/ https://docs.kolab.org/howtos/use-seafile-with-chwala.html

How do you feel about this use case?

Thanks!

dumblob commented 5 years ago

1- More features for file uploading, such as these: https://github.com/blueimp/jQuery-File-Upload#features

Overall it feels kind of "bulky". Furthermore I think the following features might be out of Cypht scope:

2- To be able to pick files and save to an existing virtual disk. In Kolab, this is called Chwala. https://kolabian.wordpress.com/2018/10/17/folder-sharing-in-files/ , https://git.kolab.org/diffusion/C/ , https://docs.kolab.org/howtos/use-seafile-with-chwala.html

How is this related to an email client? For this to work a NextCloud-like application/module would need to be developed for Cypht, which would 100% duplicate e.g. the mentioned NextCloud. Or am I missing something?

marclaporte commented 5 years ago

1- Yeah, there are lots of features. It's important that it doesn't add a lot of extra complexity for the Cypht community. We use this lib in Tiki. No issues to report.

2- All major webmail services are offering this. Gmail, Office 365, etc. 2019-07-01_180818 2019-07-01_180702

From the point of view of Tiki Wiki CMS Groupware and WikiSuite, we will build the best possible feature-rich mail solution, and contribute as much as possible to Cypht. Users will be able to pick/save files from/to https://doc.tiki.org/File-Gallery

There is another strategic question: To which point does Cypht want to make an effort to make it somewhat easy to be integrated in an application which manages files? Ex.: There are at least 3 webmail apps for NextCloud: https://apps.nextcloud.com/apps/mail https://apps.nextcloud.com/apps/rainloop https://apps.nextcloud.com/apps/afterlogic

So Cypht could be on that list (and the first one to support JMAP)

There are many other popular PHP applications. Having developers easily integrate Cypht will bring some more developers and use cases.

We are already at 5700 installs (no. 3 for webmails) on Packagist. I predict that we'll soon be in the tens of thousands. https://packagist.org/packages/jason-munro/cypht

jasonmunro commented 5 years ago

I like this idea. Personally I don't use any online based file storage solutions, but if I did, it would be super handy to pick a file out of Dropbox or whatever and attach it directly to an outbound E-mail.

Adding this to Cypht without cluttering up the core functionality can be achieved with the module set system (WOOT!). We should be able to abstract the attachment selection process, then module sets can be created to fetch the target files from different sources than the local filesystem. Everything else downstream WRT sending attachments will just work.

It's not trivial but totally do-able and worth keeping an open issue for. Thanks for the feedback!

marclaporte commented 4 years ago

As of now, Cypht doesn't let me upload more than one file at once. blueimp/jQuery-File-Upload would solve this.

dumblob commented 4 years ago

blueimp/jQuery-File-Upload would solve this.

As I noted above, I actually don't think it's a good fit - it does much more than Cypht needs and is unnecessarily bulky.

marclaporte commented 4 years ago

@dumblob: what do you propose?

I suggest you look at the list of blueimp/jQuery-File-Upload features, choose the ones you feel worthwhile, and propose an alternative strategy. Maybe there is a lighter lib? or things can be done without a lib nowadays?

For Tiki webmail needs, we can just swap in blueimp/jQuery-File-Upload, so our needs our covered. But I feel that standalone Cypht should be able to do more. Uploading two files in 2020 is a reasonable feature request.

dumblob commented 4 years ago

In terms of an email client (i.e. something which is basically a pure document-oriented database with simple API - POP3/IMAP & SMTP) everything is either one document or its part. There is nothing like a disk, storage, file operations (please don't confuse it with pruning), hierarchy, relational structure, nothing).

So I think I fail to understand what the use cases actually are. Sure, we could create a file manager with email integration (and call the file manager Cypht). Though I'm not sure whether that is the goal of Cypht :wink:.

The only think which I see missing in Cypht seems to be batch upload. But that's a very minor modification (maybe few lines in total!) - see multiple and it's perfect browser compatibility (all browsers had it 10 years ago except for Edge which got it 5 years ago). Note though, that native support for multiple selection on Android seems missing in general (at least in the web browser), but I'd expect Android to gracefully "downgrade" to a single-selection mechanism automatically.

Anything else (please carefully review before copy & pasting from https://github.com/blueimp/jQuery-File-Upload#features )?

I don't think we need resumable uploads etc. for email attachments (for a file manager this would be the other way around - especially for chunking tus seems to be a better approach than e.g. blueimp/jQuery-File-Upload ).

marclaporte commented 4 years ago

Thank you @dumblob

It (tus) looks very interesting indeed.