cryptee / web-client

Cryptee's web client source code for all platforms.
https://crypt.ee
Other
444 stars 22 forks source link

[Feature Request] add "select all item(s)" to the document selection menu #112

Closed BasilTomato closed 3 years ago

BasilTomato commented 3 years ago

Is your feature request related to a problem? Please describe. On mobile devices it is rather tiresome to select all documents in a given folder without a "select all" function. On a laptop it is possible to simply hit Ctrl-A and select all documents, but on mobile it is possible only by selecting each and every document one by one.

Describe the solution you'd like The document selection menu already contains "de-select all item(s)", please add "select all item(s)" also.

Additional context image

johnozbay commented 3 years ago

So this one's a little more tricky than it seems, and that's why I decided not to add it to prevent confusion.

1 – Selections are view-independent. So you can actually select a bunch of stuff in Folder A, then open your Recents select a bunch more files, then open Folder B, continue selecting, and have selections from both Folder A and Folder B, and from Recents. This way you can easily select a bunch of files in and out of multiple folders and move all of them to a new folder etc.

But this creates a mini UI/UX conundrum. If you have selections from Folder A, then add selections from Folder B, then enter Folder C, and press "select all": – Are we now talking about selecting all inside the current folder (Folder C), or should it select all from Folder A & B as well, where you've made selections too?

Logically, it should be "select all" from the current folder you're in (so only Folder C)

But all other buttons in that dropdown (i.e. move, download, delete etc) are applicable globally, to selected items from all folders, Folder A, B & C, and not just Folder C.

So as a user, you could take very dangerous actions like, thinking you're deleting all your selections from Folder C alone, while you end up deleting stuff from A / B as well or vice versa.

To prevent this, I decided not to include "Select All" in that pop-up.

2 – We intentionally disallow ctrl + a (or select all) in "Recents". For some accounts, this could result in selecting thousands of stuff in one click, and could be very destructive (i.e. this would be Cryptee's equivalent of rm -rf in the root directory for the lack of a better word, since recents span across all folders and their subfolders) or less dangerously so, slow the device down to a halt by selecting literally gigabytes of content.

Due to this, you can use "Ctrl + A" or shift + click inside a folder or inside search, but not while you're in "Recents".

And since the "selections" box on the top shows in search, recents, root/folders, and inside folders themselves, we'd have to make sure that "select all" is available only inside "folders" but not while you're in "Recents" or "Folders" to avoid rm -rf -alike catastrophes 😅


So to summarize, I'm not sure what's the best way to proceed here. This could cause great damage especially on mobile, where an accidental tap while cooking dinner could be incredibly destructive.

As someone who spends an unhealthy 8+ hours using Cryptee daily, I also personally hate that it's a bit inconvenient right now, especially on mobile / without a keyboard. But I can also see how it could cause confusion / pose a great risk for some users, so I'm not 100% sure, and figured I'll stay on the safe side however inconvenient this may be.

Hoping this makes sense!

I'm open for ideas here, but unless there's a really good reason why this is necessary that somehow offsets the dangerous potential for confusion I listed above, we likely won't ship this.

BasilTomato commented 3 years ago

Thank you for the detailed explanation. I had no idea about these UI/UX problems, because I am using the default "Inbox" folder to store everything. It is more convenient to scroll up/down in that list than constantly switch folders... This may be a different example of "lazy user" use case :-) Anyway I get the idea why this may be dangerous in mobile environment and can live without this function.