Commit graph

1192 commits

Author SHA1 Message Date
Artur Paikin
07e9909bfc Release 2020-02-12 12:24:41 +01:00
Ifedapo .A. Olarewaju
6d4272f4b0
Merge pull request #2053 from transloadit/provider-errors
companion: return  more accurate error status codes
2020-02-12 12:04:39 +01:00
Artur Paikin
77ef346cb0 Release 2020-02-11 21:17:04 +01:00
Artur Paikin
856243a149
core, transloadit: Allow new uploads when retrying; improve error handling (#1960)
* Set `allowNewUpload: true` when an error occurs to allow retryAll

* Add assembly error message and assembly_id

* Pass debug option to Robodog

* Add forceAllowNewUpload to use in retry and retryAll, improve calls to _showOrLogErrorAndThrow

* Capitalize Create Assembly message

* don’t throw error from 'upload-error' event,  improved error message structure

* handle errors better

* check if error.details exists

* Doc tweaks: added error.assembly
2020-02-11 17:06:33 +01:00
Artur Paikin
d0f181caeb
core: Add noNewAlreadyUploading and noDuplicates (#2057)
* Add noNewAlreadyUploading and noDuplicates

* Update en_US.js

* fix test

* Update index.js

* Update en_US.js
2020-02-10 14:54:40 +01:00
Artur Paikin
013f5958d2 add tsv and tab (#2056) 2020-02-08 16:25:47 +03:00
Artur Paikin
44cc071471
informer, status-bar: Display a browser alert when an error question mark button is clicked (#2031)
* Display a browser alrert when an error question mark button is clicked

Informer can dissappear, while the alert dialog will stay on screen indefinitely. Plus it’s easier to copy/paste from the alert, than the bubble (virtually impossible).

* Keep displaying Informer when the message ? bubble is hovered

* Tweak line-height
2020-02-05 15:54:56 +03:00
ifedapoolarewaju
a032f96e85
companion: return more accurate error status codes 2020-02-05 12:32:33 +01:00
Mohammed Shahim
6bef0a0314
Fix mime type checking bug (#2004)
* fix for mimetype issue #1988

* core: disregard mime parameters

Co-authored-by: Renée Kooi <renee@kooi.me>
2020-02-05 12:17:34 +01:00
Ifedapo .A. Olarewaju
a8917d5062
Merge pull request #2047 from transloadit/put-remote-xhr
companion,xhr-upload: add option to set http method for remote multipart uploads
2020-02-03 12:49:16 +01:00
Artur Paikin
d385d2c84e
Clear state error after the last file is removed (#2041) 2020-02-03 13:07:47 +03:00
ifedapoolarewaju
4ed7508f78
companion,xhr-upload: option to set multipart http method
fixes #2019 (we can all go one year backwards once this is merged)
2020-01-31 15:51:15 +01:00
ifedapoolarewaju
83ec63efb2
providers: remove redundant use of options 2020-01-31 14:54:13 +01:00
ifedapoolarewaju
d34a67f9fd
add todo 2020-01-31 12:13:58 +01:00
Michael Kabatek
ff5714ebc3 fix: remove conditonal to replace google with drive
* Google drive callback url now uses 'google' and not 'drive'
* Fixes callback url by removing the conditional for google providerName
2020-01-31 02:06:01 -07:00
Artur Paikin
1ea950d5d2
core: Always log errors (#2029)
* Show errors in logs always. nullLogger --> justErrorsLogger

Reasoning: too often we ended up showing errors in the Informer bubble, but not in the console, which is wrong and annoying. Devs still have an option to silence logs or direct them elsewhere by setting a custom logger

* Hide pause/resume buttons when error occures

* Update tests

* Update website/src/docs/uppy.md

Co-Authored-By: Renée Kooi <renee@kooi.me>

Co-authored-by: Renée Kooi <renee@kooi.me>
2020-01-28 18:45:23 +03:00
Eduardo Flores
285ac9a9d0 Changed aria-level attribute to correct syntax. (#2032)
* Changed aria-level attribute to correct syntax.

Changed the aria-level attribute to the correct syntax. Changes were also made to meet ADA compliance.

* update a few more aria-level attributes

Co-authored-by: Renée Kooi <renee@kooi.me>
2020-01-22 13:06:53 +01:00
yoann-hellopret
0640a1a56a remove encodeURIComponent to avoid encoding characters twice (#2033) 2020-01-22 12:39:52 +01:00
Ifedapo .A. Olarewaju
15cd6fd781
Merge pull request #2034 from transloadit/fix-onedrive
companion,website: make encryption shorter + enable onedrive on website
2020-01-22 12:36:18 +01:00
Ifedapo .A. Olarewaju
cb75538fcd
Merge pull request #1966 from transloadit/instagram-graph
companion: support new Instagram Graph API
2020-01-21 13:45:36 +01:00
ifedapoolarewaju
61edba36b3
companion,website: make encryption shorter + enable onedrive on website example 2020-01-21 13:14:17 +01:00
ifedapoolarewaju
a54274f645
debug: make tests pass 2020-01-20 15:10:37 +01:00
ifedapoolarewaju
aeb3d12d7f
debug: fix base64 escaping 2020-01-20 14:25:23 +01:00
ifedapoolarewaju
4b4ff2eccd
Merge branch 'master' of github.com:transloadit/uppy 2020-01-20 13:42:53 +01:00
ifedapoolarewaju
1971117ee3
debug: encode companion auth token as base64 2020-01-20 13:40:48 +01:00
Artur Paikin
7eda2346a8
core: setState(modifiedFiles) in onBeforeUpload (#2028)
* Updating files in state, too, because uploader plugins receive file IDs only, not actual files

* Update doc examples with simpler spread syntax
2020-01-20 15:33:38 +03:00
ifedapoolarewaju
0b4c22dddb
Revert "debug: see if excluding cookies for onedrive fixes large header issue"
This reverts commit c6fbae5a9d.
2020-01-19 23:02:27 +01:00
ifedapoolarewaju
c6fbae5a9d
debug: see if excluding cookies for onedrive fixes large header issue 2020-01-19 22:32:36 +01:00
Artur Paikin
41af1995c2
Dashboard: Add image and archive icons (#2027)
* Add image and archive icons

* Refactor archiveTypes
2020-01-17 17:14:20 +03:00
Renée Kooi
2b91a96c95
Release 2020-01-15 16:39:45 +01:00
Olivier Le Moign
fc5321ef24 Update french translations (#2023)
* Update fr_FR.js

Add missing keys + fix translations (French native here).

* Small revert

* Remove dangling comma
2020-01-15 15:05:51 +01:00
Renée Kooi
c63d01bf07
companion: also pass metadata to getKey for multipart S3 uploads (#2022) 2020-01-15 15:04:57 +01:00
Renée Kooi
fec7d7db3a
companion: rename S3 upload functions to clarify which type of upload they do
cc @ifedapoolarewaju
2020-01-13 12:59:00 +01:00
Renée Kooi
1463ee79ce
Improve performance of adding and removing files (#1949)
* core: add an addFiles() method that only updates state once

Previously, adding 1300-ish files took around 260ms, and looked like
this in Firefox's performance tab:

![Flamegraph](https://i.imgur.com/08veuoU.png)

All of the downward peaks are `setState()` calls and GC.

Now it takes around 60ms, and looks like this:

![Flamegraph](https://i.imgur.com/xFdwVBV.png)

Here, most of the time is spent generating file IDs and guessing file
types. Those would be areas to look at next.

* dashboard: prevent frequent state update if nothing changed

After the last commit, `addFiles()` still spends a lot of time in
`emit()` and `hideAllPanels()`. The reason is that `addFiles()` still
emits all the hundreds of file-added events, and the Dashboard responds
to each with `hideAllPanels()`, which does a state update. But this all
happens synchronously, and the state almost certainly did not change
since the last `file-added` event that fired a millisecond ago.

This adds a check to avoid the state update if it is not necessary.

![Flamegraph](https://i.imgur.com/KhuD035.png)

Adding 1300 files takes about 40ms now.

With this change, the `addFiles()` call is no longer the slowest
part—now preact rendering all the items is!

* utils: optimize generateFileID and getFileNameAndExtension

Replaces some clever things with more mundane and faster things!

Now, generateFileID is a bunch of string concatenations.
Now, getFileNameAndExtension uses `lastIndexOf()` instead of a regex.

![Flamegraph](https://i.imgur.com/ZQ1IhxI.png)

Adding 1300 files takes about 25ms.

* dashboard: use preact-virtual-list

* thumbnail-generator: add `lazy` option

* dashboard: request thumbnails once file item renders the first time

* dashboard: fork preact-virtual-list

* core: add removeFiles() to remove files in bulk

* Implement removeFile() in terms of removeFiles()

* thumbnail-generator: only queue files that can be previewed

* rename size constants to accommodate WIDTH/HEIGHT

* Use new uppy.addFiles in DragDrop and FileInput

* utils: fix getFileNameAndExtension() type

* Rip out the lazy thumbnail generation

* Rip out virtualization.

* Remove virtualization leftovers

* tell future people that this is intentionally verbose

* Update package-lock.json

* henlo i am spell

* Make `addFiles()` respect maxNumberOfFiles

* core: show an informer error if some files fail in bulk add

* locales: fix quotes to make build:locale-pack happy

Co-authored-by: Artur Paikin <artur@arturpaikin.com>
2020-01-13 12:29:08 +01:00
rtaieb
bdc8862d76 Free rate limit queue when upload times out (#2016) (#2018) 2020-01-10 13:50:18 +01:00
Renée Kooi
2b7df61111
Merge branch 'master' into instagram-graph 2020-01-08 14:39:06 +01:00
Artur Paikin
6642f32e4a fix vi_VN: rename en_US --> vi_VN 2020-01-07 16:54:00 +01:00
Artur Paikin
1d7a58481d ProviderViews: Improve Instagram’s “video thumbnail” 2020-01-07 16:51:16 +01:00
Renée Kooi
a7e4e12fe2
Companion dependency updates (#1983)
* companion: upgrade deps with updtr

* companion: downgrade stuff for node 6 compat

* Update packages/@uppy/companion/package.json
2020-01-06 15:24:35 +01:00
Renée Kooi
e1f25a4beb
locales: lint fix 2020-01-06 14:56:17 +01:00
Gerd R
72210adee7 Fix #2011 (#2012)
* fix #2011

The isXml() method will return false if the Content-Type header is not set in the S3 response

* aws-s3: fix lint

Co-authored-by: Renée Kooi <renee@kooi.me>
2020-01-06 14:49:56 +01:00
Pankaj Kumar
627b2e4df9 componentWillReceiveProps logic moved to componentDidUpdate (#1999) 2020-01-06 14:48:50 +01:00
thanhthot
53ef2fd862 Create vi_VN;js (#2010)
* Create vi_VN;js

* Update vi_VN.js
2020-01-06 14:27:12 +01:00
Renée Kooi
3c1a2afb09
xhr-upload: do not emit limit warning if an existing rate limit queue was passed 2020-01-06 13:24:08 +01:00
rlebosse
a6eef8c6c5 @uppy/thumbnail-generator : Fix code crashing in strict mode wi… (#1995)
* Fix code crashing in strict mode by using Number constructor

* Remove useless set of numerator and denominator
2019-12-18 16:15:54 +01:00
Corentin Ardeois
178343d264 feat(s3-multipart): add optional headers for signed url (#1985)
Update `prepareUploadPart` contract to accept an optional `headers` property in the returned value.
If `headers` are present, they will be sent along the S3 presigned URL

Fixes #1984
2019-12-16 16:07:26 +01:00
Jaedong Kim
56ceb559f5 add Korean Locale (#1986)
* add Korean Locale

* eslint --fix
2019-12-16 14:27:54 +01:00
darthf1
19e31d098b Correct Tus.TusOptions typings based on docs (#1989)
* Correct Tus.TusOptions typings based on docs

From: https://uppy.io/docs/tus/

* Update index.d.ts

* Update packages/@uppy/tus/types/index.d.ts

Co-Authored-By: Renée Kooi <renee@kooi.me>
2019-12-16 14:05:39 +01:00
Renée Kooi
18180d5778
Release 2019-12-16 12:53:23 +01:00
Ifedapo .A. Olarewaju
2194638eb4
Merge pull request #1975 from transloadit/enable-onedrive
website: enable onedrive on the website example
2019-12-13 11:24:31 +01:00