6 min read #OpenCloud#UX

OpenCloud · Trash bin

Deleting without risk

When you clean up, you delete quickly, and sometimes you hit the wrong file. Since OpenCloud 3.7.0, the notification after deleting has an “Undo” button, and for a few seconds Ctrl+Z (⌘+Z on a Mac) brings the files back as well. Since 3.0.0 you can delete right in the image preview and in the editor, and since 3.2.0 the trash bin overview shows where anything is actually lying around and empties bins one at a time if you want. Something is only gone for good once you empty the trash bin and confirm it a second time.

Sorting vacation photos means clicking through hundreds of pictures and keeping the best ones. Cleaning up a project folder means throwing out old drafts. Either way you work fast, and that is exactly when the wrong photo disappears, or the folder a colleague still needs. In OpenCloud, deleted files do go to the trash bin and can be restored from there, but only after a detour: open “Deleted files” in the sidebar, pick the right space, find the file, restore it and go back to the folder. After doing that a few times, people delete more carefully. They click more slowly, ask first, or just leave old files where they are.

  1. The “Deleted files” page with a list of all trash bins: Personal and the project spaces Accounting through Support.
    Open “Deleted files” in the sidebar: every space has its own trash bin.
  2. Trash bin of the Marketing space with the deleted file Draft-old.jpg.
    Pick the right space, here “Marketing”, and find the file.
  3. Context menu of the deleted file with the entries “Delete” and “Restore”.
    Choose “Restore” in the context menu.
  4. Empty trash bin “This trash bin is empty” and the notification “Draft-old.jpg was restored successfully”.
    The file is back, and you have to navigate to the folder yourself (OpenCloud 4.1.0).

Since 3.0.0, several rolling releases have improved the conditions for deleting. If you make a mistake, you should be able to take it back immediately and without a detour, so you don't hesitate in the first place.

Delete from the preview and apps

Up to version 3.0.0, deleting an open file meant closing it, finding it again in the file list and deleting it there. When you sort photos, you lose the comparison with the previous picture, and in a long list it is easy to hit the neighboring file. The suggestion to delete directly in the preview came from the community. Since 3.0.0, “Delete” is available in the context menu of every app's top bar, in the actions of the right sidebar, and as a button in the control bar of the image preview. There the keyboard is enough: Delete, Ctrl+Backspace or ⌘+Backspace on a Mac moves the displayed image to the trash bin, and the preview shows the next one. You do need permission to delete the file. Without it, the button doesn't appear.

Control bar of the image preview: paging, “5 of 12”, view and zoom buttons, rotate, and on the right the trash icon, outlined in red.

In the image preview, “Delete” sits on the right of the control bar as a trash icon (outline added afterwards).

In the preview, Delete removes the displayed image and the next one appears right away. The key overlay was added for the video (OpenCloud 4.1.0).

There is one exception: documents currently open in Collabora. They are locked, and trying to delete them used to fail with an error message. Since 3.7.0, “Delete” is grayed out for a single locked file, and a tooltip explains why: the file can't be deleted because it is currently locked. A user had reported this after trying to delete from Collabora's tab menu.

Undo after deleting

After deleting, OpenCloud reports that, say, “Vacation-017.jpg” was moved to the trash bin. Since 3.7.0, this notification contains an “Undo” button. One click restores the files to their old location, and they show up in the open folder without a reload. As long as the notification is visible, which is seven seconds, Ctrl+Z or ⌘+Z works too. That also applies when you deleted several files at once. OpenCloud now behaves like the file manager on your own computer. The request came from everyday use: if you go through photos and delete one too many, you don't want to navigate to the trash bin first. Version 4.1.0 added two fixes. The same deletion can no longer be undone twice, and in project spaces the restored file now reappears in the list immediately as well.

Select and delete “Vacation-017.jpg”, click “Undo” in the notification: the file is back in the list without a reload. The click targets are highlighted in red for the video (OpenCloud 4.1.0).
Delete three photos, then press ⌘+Z while the notification “3 items were moved to trash bin” is visible: all three are back (OpenCloud 4.1.0).

The feature has limits. It is available in your personal space and in project spaces, but not in folders others have shared with you. It is also missing on servers without a trash bin. Once the notification is gone, the files are still in their space's trash bin and can be brought back through “Deleted files” and “Restore”.

Overview of all trash bins

Under “Deleted files”, every space has its own trash bin. Up to 3.2.0, anyone working in many spaces saw a long list there and had to open each entry to find out whether anything was in it. With 3.2.0, the server reports for every space whether its trash bin contains deleted items, and the overview shows it. Above the list it says how many trash bins there are in total and how many of them are empty. In the view options you can turn off “Show empty trash bins” so that only those with content remain. The option is on by default. In 4.1.0, an empty trash bin also got its own icon, because the small color difference used before was barely noticeable.

OpenCloud 3.1.0: list of the trash bins Personal, Accounting, Engineering, Events, HR, Legal, Marketing, Sales, Support with no hint about their content, below it “9 trashes in total”.

Before (3.1.0): nine trash bins, all looking the same whether they contain anything or not.

OpenCloud 3.2.0: the same list with trash icons in the “Actions” column, dark for Events, Marketing and Sales, below it “9 trash bins in total (including 6 empty)”.

After (3.2.0): full trash bins are recognizable, and below the list it says “9 trash bins in total (including 6 empty)”.

  1. Open view options above the list of trash bins with the “Show empty trash bins” switch turned on.
    The gear icon opens the view options with the “Show empty trash bins” switch.
  2. List with only two trash bins left, Events and Sales, below it “9 trash bins in total (including 7 empty)”.
    Switched off, only the trash bins with content remain. Since 4.1.0, empty ones have their own light icon (OpenCloud 4.1.0).

Also since 3.2.0, you can clean up directly from the overview: a space's context menu offers “Empty trash bin” without opening the trash bin first. For an empty trash bin the entry is grayed out. From 3.6.0 on, the trash bin can also be shown as tiles with thumbnails, which makes deleted photos easier to find.

Context menu of the Marketing space in the overview with “Open trash bin” and “Empty trash bin”.

A space's context menu offers “Empty trash bin” right in the overview.

Context menu of the Legal space with “Open trash bin” and a grayed-out “Empty trash bin”.

For an empty trash bin, “Empty trash bin” is grayed out (OpenCloud 4.1.0).

Only deleting inside the trash bin itself is final, meaning removing individual items there or emptying a trash bin. Both ask first, for example with “Permanently delete file »Vacation-017.jpg«” and a note that this can't be undone. Everything before that can be recovered. How long deleted files stay in the trash bin is up to the operator. OpenCloud doesn't empty it on its own. Only when an administrator runs opencloud storage-users trash-bin purge-expired, for example regularly as a cron job, does OpenCloud remove everything that has been in the trash bin for more than 30 days. You can change that period separately for personal spaces and project spaces with STORAGE_USERS_PURGE_TRASH_BIN_PERSONAL_DELETE_BEFORE and STORAGE_USERS_PURGE_TRASH_BIN_PROJECT_DELETE_BEFORE.

Dialog “Permanently delete file »Vacation-015.jpg«” with a note that this can't be undone, and the buttons “Cancel” and “Delete”.

Permanent deletion asks first and warns that it can't be undone (OpenCloud 4.1.0).

Sources