nextcloud-libraries / nextcloud-upload

Nextcloud Upload helpers for Nextcloud apps https://npmjs.org/@nextcloud/upload
https://nextcloud-libraries.github.io/nextcloud-upload
GNU Affero General Public License v3.0
8 stars 3 forks source link

Show loading indicator on file assembling #1458

Open Koc opened 3 weeks ago

Koc commented 3 weeks ago

Background: We've started using s3 storage instead of local files. And it performs much slower comparing to local filesystem. Now when we upload large file it can took up to 30 seconds for merging chunks into a single file. The problem is there is no any indicator of this activity and users can't understand what happening between progress bar hide and file appears in list.

You can observe how it works after the patch on the video below:

https://github.com/user-attachments/assets/7d8632f5-e06e-4f7c-9409-61cc34c67b29

codecov[bot] commented 3 weeks ago

Bundle Report

Changes will increase total bundle size by 1.47kB (0.19%) :arrow_up:. This is within the configured threshold :white_check_mark:

Detailed changes | Bundle name | Size | Change | | ----------- | ---- | ------ | | @nextcloud/upload-esm | 382.87kB | 694 bytes (0.18%) :arrow_up: | | @nextcloud/upload-esm-cjs | 386.32kB | 780 bytes (0.2%) :arrow_up: |
codecov[bot] commented 3 weeks ago

Codecov Report

Attention: Patch coverage is 72.72727% with 6 lines in your changes missing coverage. Please review.

Please upload report for BASE (main@19aa6bd). Learn more about missing BASE report. Report is 4 commits behind head on main.

Files with missing lines Patch % Lines
lib/uploader.ts 70.58% 5 Missing :warning:
lib/components/UploadPicker.vue 80.00% 1 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #1458 +/- ## ======================================= Coverage ? 28.94% ======================================= Files ? 14 Lines ? 1513 Branches ? 49 ======================================= Hits ? 438 Misses ? 1075 Partials ? 0 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

skjnldsv commented 2 weeks ago

Hey, thanks for the PR! Unfortunately, design wise, adding some text to tell the user about the assembly is not acceptable.

Imho, to simplify this, we should :