Commit graph

327 commits

Author SHA1 Message Date
Murderlon
fe96096c3d
Merge branch 'master' into 2.0
* master: (23 commits)
  A bit of polish (#2986)
  Companion: Fix typescript error
  Companion: Fix invalid referrer crashing the process
  Publish 1.30 blog post
  Release
  Build: Companion needs to be built before locale-pack
  Release
  Fix build: locale-pack first, integrations second
  changelog for 1.30
  Release
  Update package.json
  Only log info if debug is true (#2855)
  build(deps): bump prismjs from 1.23.0 to 1.24.0 (#2971)
  Angular Integration (#2871)
  ci: don't run markdown tests in type tests
  Add types for `uppy.once` method (#2965)
  build: lint fixes in build scripts
  Fix typo in docs/progressbar.md (#2962)
  Document `uppy.once` in `docs/uppy.md` (#2960)
  Add `props` example to docs/vue.md (#2959)
  ...
2021-07-07 15:32:38 +02:00
Artur Paikin
8fb6889e26
Revert "Improve checkbox for screenreaders (#2930)" (#2979)
This reverts commit a2527c6ab5.
2021-07-01 06:40:01 +01:00
Artur Paikin
4b782ffbbb Release 2021-06-30 23:07:21 +01:00
Merlijn Vos
a2527c6ab5
Improve checkbox for screenreaders (#2930)
* Improve checkbox for screenreaders

* Remove redundant aria attributes

Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>

* Update French locale

* Fix order in English locale

Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
2021-06-30 13:18:44 +01:00
Artur Paikin
48c8d8b50d
core: onBeforeFileAdded: pass full file object with extension, detected type, meta, size, etc (#2941)
* pass full file object with extension, meta, size, etc

* Update packages/@uppy/core/src/index.js

Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>

* Update packages/@uppy/core/src/index.js

Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>

Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
2021-06-30 12:05:46 +01:00
Merlijn Vos
acb6566ec0
Always enable strict types and remove .run method (#2957)
* Always use strict types and remove `.run` method

* Remove accidental package-lock.json files

* Actually remove `.run` method
2021-06-30 12:05:10 +01:00
Andrew
8f4cc89a9e
Angular Integration (#2871)
* feature(integration): initial Angular framework implementation

* Package cleanup

* Actually add the components this time

* fix rendering bug

* Add documentation

* dependency fixes

* add broken example

* Make locales ignore angular

* dependency updates

* Update package-lock.json

* Fix broken example

* Make example consistent with docs

* angular: Update styling advice

* angular: Build system stuff

* angular: Escape dependency hell

* angular: Add dashboard-modal component

* angular: Update package.json/prepare for release

* angular: Fix styling bugs

* add Angular dependencies

* Update README.md

* lint fixes — those deps are in root

* Update README.md

Co-authored-by: Adam Medford <adammedford@gmail.com>
Co-authored-by: Artur Paikin <artur@arturpaikin.com>
2021-06-30 11:36:57 +01:00
Merlijn Vos
f0f1105ef0
Resolve or remove miscellaneous todos (#2967) 2021-06-29 12:54:19 +02:00
Antoine du Hamel
c315329399
Remove IE polyfills and special casing (#2947)
* Remove IE polyfills and special casing

* dashboard: remove `resize-observer-polyfill`

* deps: remove url-parse to use global `URL` instead

* Update documentation for browser support

* Add a migration guide

* Update e2e test platforms

* Remove polyfills from examples and add those missing in CDN bundle

* Use Node.js v16.x on CI because of `AbortController`

* Update bundle builder to produce two builds: `uppy.js` without polyfills, `uppy.legacy.js` with polyfills.

* Upgrade create-react-app deps

* remove null coalescing operator as it's not supported by the build chain

* disable Safari testing (for now)


Co-authored-by: Renée Kooi <renee@kooi.me>
2021-06-28 11:34:51 +02:00
a-kriya
3c8fbe8d87
Add types for uppy.once method (#2965)
Co-authored-by: Merlijn Vos <merlijn@soverin.net>
2021-06-28 09:26:04 +02:00
Merlijn Vos
a194865fe5
Create getObjectOfFilesPerState in core for plugins (#2961) 2021-06-25 10:58:42 +02:00
Antoine du Hamel
56c86e2f18
doc: use ESM syntax in code snippets (#2953)
In preparation for a future release of Uppy which drop support for
CommonJS, we should start nudging our users to use ESM syntax.

Fixes: https://github.com/transloadit/uppy/issues/2951
2021-06-22 10:30:24 +02:00
Merlijn Vos
da6c3e4098
Remove sync option from VirtualList & update UIPlugin render 2021-06-21 15:11:19 +02:00
Antoine du Hamel
9c26496a09
transloadit: fix unhandled promise rejections (#2948) 2021-06-21 13:53:16 +02:00
Antoine du Hamel
8b1b794b73
Add comments around empty setState calls (#2931) 2021-06-19 11:23:18 +01:00
Merlijn Vos
ecec3d3213
Split Plugin into BasePlugin and extended UIPlugin (#2944) 2021-06-18 13:23:16 +02:00
Merlijn Vos
3b3e8a440c
Upgrade Preact to latest (#2926) 2021-06-16 12:46:19 +02:00
Merlijn Vos
f2d30420f3
Mention the file name in exceedsSize error message (#2918)
* Mention the file name in exceedsSize error message

* Fix implementation and tests

* Undo accidental commited changes
2021-06-07 15:42:41 +01:00
Antoine du Hamel
1aa17533ee
core: enrich error event for use from postproocessor (#2909)
Fixes: https://github.com/transloadit/uppy/issues/2840
2021-05-31 12:43:18 +01:00
Artur Paikin
23e4a537a6 Release 2021-05-28 11:54:17 +01:00
Artur Paikin
12b7bd34e8 Release 2021-05-27 21:35:08 +01:00
Artur Paikin
7bdaba3021
types: Add logout, Translator.translate and Translator.translateArray (#2899)
* Add logout, Translator.translate and Translator.translateArray

* Update index.d.ts

* Update index.d.ts

* Update index.js
2021-05-26 16:26:16 +01:00
Artur Paikin
c4a637655d
Golden Retriever 2: Return of the Ghost (#2701)
* don’t store file.data on local files when we save to localStorage, add isGhost: true, additional event restore-confirmed

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

* Don’t double-emit upload-started for Golden Retriever-restored files that were already started

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

* removeFile: delete updatedUploads[uploadID] instead of calling _removeUpload to avoide excess state updates

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

* clear preview, throttle saving state

* add service message and ghost icons

* regenerate thumnails on restore properly

* allow replacing duplicate files if it’s a ghost

* re-generate thumbnails on componentDidUpdate

* tweak styles for ghosts

* Dashboard cleanup

* refactor: load IndexedDBStore and ServiceWorkerStore together, add uninstall, handle file-edit-complete

* recoveredState — show upload button as “restore”, hide progress pause/resume, handle abortRestore

* tweak serviceMsg mobile styles

* use i18n for strings

* Handle aborting, complete and last file removal with MetaDataStore.cleanup(instanceID)

* fix all the tests

* import .eslintrc from master

* autofix

* add lodash.throttle

* when re-selecting ghost files, only replace the blob, keeping progress, meta, etc

* Delete package-lock.json

* Update en_US locale

* add golden retriever support to darkmode styles

* add golden retriever to website example

* Update package-lock.json

Co-authored-by: Renée Kooi <github@kooi.me>
2021-05-12 16:30:30 +01:00
Artur Paikin
a87e8a8b80 Release 2021-05-11 23:15:55 +01:00
Artur Paikin
213c4a4de7 Merge branch 'master' of https://github.com/transloadit/uppy 2021-05-05 21:51:44 +01:00
Artur Paikin
209a0079d3 Release 2021-05-05 21:50:17 +01:00
Antoine du Hamel
a6bebda396
core: remove outdated comment (#2868)
Fixes: https://github.com/transloadit/uppy/issues/2787
2021-05-05 21:30:41 +01:00
Antoine du Hamel
a32870fe10
core: use AggregateError when available (#2869) 2021-05-04 23:35:32 +01:00
Artur Paikin
b760b0e918
add uppy.logout() (#2850) 2021-04-27 15:37:02 +01:00
Artur Paikin
1751241362 Release 2021-03-31 23:59:08 +01:00
Kevin van Zonneveld
764c2ccada
Update Linter (#2796)
* relocate .vscode

* Switch to transloadit linter

* Update .eslintrc.json

* autofix code

* unlink and install eslint-config-transloadit@1.1.1

* Change 0 to "off"

* Don't change 'use strict'

* Do not vertically align

* disable key-spacing

* add import/no-extraneous-dependencies per package

* add more react/a11y warnings

* Revert "autofix code"

This reverts commit 14c8a8cde8.

* add import/no-extraneous-dependencies per example and main package

* autofix code (2)

* Allow devDependencies in ./bin

* Change import/no-extraneous-dependencies to warn again

* upgrade linter

* Set import/no-extraneous-dependencies to warn
2021-03-15 16:25:17 +00:00
Renée Kooi
4bf1072363
Release 2021-03-10 13:11:28 +01:00
Artur Paikin
502a755458
Use Array.findIndex instead of Array.indexOf in uppy.removePlugin (#2793)
* move findIndex to @uppy/utils, add tests

* use Array.findIndex instead of Array.indexOf in uppy.removePlugin

because strict comparison started failing with Vue3 Proxies
2021-03-08 18:16:01 +00:00
Artur Paikin
2eabc33099 Release 2021-02-10 18:55:14 +00:00
Renée Kooi
bba2a2543a
transloadit: fix polling fallback bugs (#2759)
* transloadit: fix polling attempts after Assembly completed

* core: mark postprocessing completion if upload is complete
2021-02-10 12:29:53 +00:00
Artur Paikin
7c55bd855e Release 2021-01-28 16:08:14 +00:00
Renée Kooi
52760d2bb7
dashboard: improve support for right-to-left scripts (#2705)
* dashboard: fix modal position on rtl pages, fixes #2495

* Align text to the right on right-to-left pages

* core: fix default text alignment on right-to-left pages

* dashboard: fix margin in provider browser on right-to-left pages

* dashboard: use direction-aware offset properties

* provider-views: use logical offset CSS properties

* status-bar: use logical offset CSS properties

* dashboard: fix addMore icon margin on RTL pages

* dashboard: some more logical properties

* build: compile logical properties to old CSS

* dashboard: set dir attribute if page did not provide one

* status-bar: set fallback text direction if not provided

* support direction option for inline and modal dashboard

* use companion.uppy.io on deploy previews

* provider-views: fix RTL alignment of file icons

* put the dir attribute on a wrapper div

* fix icon alignment in RTL provider views

* informer: fix ? alignment in RTL mode
2021-01-27 17:13:38 +00:00
Artur Paikin
e1efe07927 Release 2021-01-27 16:22:43 +00:00
Renée Kooi
c81780230d
Add all the CI badges (#2725)
* Add all the CI badges

* flip the CI / npm version order

* add github actions tests badges to all package readmes

* remove |

Co-authored-by: Artur Paikin <artur@arturpaikin.com>
2021-01-13 00:30:59 +00:00
Artur Paikin
1493a807fe Release 2020-12-23 18:04:51 +00:00
Artur Paikin
a6a28eac67
dashboard: add autoopen for file editors (image-editor) (#2681)
* final-file-added event for when the last file in the batch has been added

* intoduce autoOpenFileEditor — open when the last file (image) from a batch has beed added

* make cropping box more visible

* add docs

* final-file-added --> files-added
2020-12-18 21:27:48 +00:00
Renée Kooi
38599e3aa2
Release 2020-12-11 21:17:27 +01:00
Artur Paikin
76366c3a92
addFile returns string, not void (#2685) 2020-12-08 19:08:41 +00:00
Artur Paikin
68a23d9ff1 Release 2020-11-25 23:33:54 +00:00
Artur Paikin
95e014f572
test: use DeepFrozenStore in one end to end test (#2607)
* use DeepFrozenStore in one end to end test

Follow up to #320

* add DeepFrozenStore to some Core unit tests
2020-11-25 21:19:32 +00:00
Artur Paikin
449798d964
pass files array to _checkRestrictions in _checkAndCreateFileStateObject via addFiles (#2655) 2020-11-25 11:55:36 +00:00
ifedapoolarewaju
3ff9ab042f
Release 2020-11-13 11:52:51 +01:00
Artur Paikin
3967e05fbc
Add uppy.passesRestrictions(file) and disallow selecting files that don’t pass restrictions in providers (#2602)
* add passesRestrictions(file) and utilize it in provider-views

* disallow selecting more than maxNumberOfFiles

* add restriction reason and include folders

* let’s leave folder out of this for now — otherwise not only you can’t select them, but navigate too

* disallow selecting if totalCurrentSelectionFileSize is over maxTotalFileSize

* handle maxNumberOfFiles not being set 🙈

* fix totalCurrentSelectionFileSize and handle no file.name

* support grid in restrictions

* refactor the restriction reason logic, rename to validateRestrictions, wrap icon in a container

* add uppyFileSizes 🙈

* get rid of canSelectMore in favor of validateRestrictions (file, files)

* handle shift key bulk selection

* remove unused props

* use infoTimeout
2020-11-11 21:41:16 +00:00
Artur Paikin
f169943664
add uppy.opts.infoTimeout (#2619) 2020-11-06 17:48:25 +00:00
Artur Paikin
84f7b4d37d Release 2020-10-30 03:27:41 +00:00