Commit graph

26 commits

Author SHA1 Message Date
Artur Paikin
bb1c615dc4 Merge conflict, Editor.js 2021-07-30 14:31:21 +01:00
Artur Paikin
172cc77f63 Merge master 2021-07-30 14:27:21 +01:00
Merlijn Vos
7db4ced76e
Add croppedCanvasOptions to image editor opts (#3037)
* Add `croppedCanvasOptions` & fix types

* Update website/src/docs/image-editor.md

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

* Update website/src/docs/image-editor.md

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

* Update website/src/docs/image-editor.md

Co-authored-by: Artur Paikin <artur@arturpaikin.com>
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
2021-07-30 14:27:56 +02:00
Artur Paikin
4ca78ab543
Set plugin titles from locale (#3023)
* What is happening "*"

* Instead of re-creating i18nInit, we could just make it part of the BasePlugin

* set plugin title and allow changing it from locale

* remove i18nInit method, since we now include it in BasePlugin

* All provider titles should come from locale

* Update en_US.js

* make translator private

//cc @aduh95

* init locale after calling setOptions

* Update en_US.js

* Update packages/@uppy/core/src/BasePlugin.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>

* Bind `i18n` functions

* Remove duplicate i18nInit — it’s in BasePlugin already

* fix formatting

* fix name

* Update en_US.js

Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
2021-07-30 13:02:32 +01:00
Artur Paikin
f20330aee9
Dashboard: rename Done to Cancel, add Save to Image Editor (#3033)
* Rename Done button to Cancel everywhere

* Add Save button to the top bar of the FileEditor

* Remove Save button from Image Editor toolbar

* fix locale
2021-07-21 14:07:42 +01:00
Merlijn Vos
f01538ba41
Resolve all type TODO's (#2963) 2021-07-20 14:40:31 +02:00
Antoine du Hamel
fe0f79e8c2
@uppy/image-editor: fix SASS deprecation warning (#3009) 2021-07-14 14:25:25 +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
Merlijn Vos
ecec3d3213
Split Plugin into BasePlugin and extended UIPlugin (#2944) 2021-06-18 13:23:16 +02:00
Antoine du Hamel
0c510ee799
add more granular image rotation control (#2838)
* add more granular image rotation control

Fixes: https://github.com/transloadit/uppy/issues/2636

* fixup! add more granular image rotation control

* fixup! add more granular image rotation control

* fixup! add more granular image rotation control

* fixup! add more granular image rotation control

* add input-range-scss dependency

* Modify the rotation slider

- Better visual styles for the slider
- Position a toggle in the center of the slider
- Make it work better on moblile
- 90° rotation: rotate counterclockwise
- 90° rotation: update icon

* Use black background for the canvas when rotating (instead of gray)

* Use smaller range for granular rotation input

* Optimize event listeners

* Fix styles and state unsyncronisation

* Update package-lock.json

Co-authored-by: Alexander Zaytsev <nqst@users.noreply.github.com>
Co-authored-by: Artur Paikin <artur@arturpaikin.com>
2021-06-13 14:31:19 +01:00
Stanislav Červeňák
5fafa7b7a9
image-editor: fix flipHorizontal string (#2815)
Co-authored-by: Renée Kooi <renee@kooi.me>
2021-03-17 14:37: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
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
Artur Paikin
ce92b6b919
Image editor zoom button and types fix (#2632)
* fix zoom button

* fix types
2020-11-14 13:59:38 +00:00
Konstantin Epishev
becf60208b
Image editor optional buttons (#2615)
* add types for image editor actions

* image editor actions customization

* add docs about image editor customization

* minor button code refactor

Co-authored-by: Artur Paikin <artur@arturpaikin.com>
2020-11-12 19:16:19 +00:00
Renée Kooi
335079d222
deps: upgrade ESLint to v7 (#2460) 2020-08-13 12:46:22 +02:00
Renée Kooi
857c0a30f1
Use latin c character
These two places were using a different character that looks a lot like
`c` but is not quite `c`.
2020-08-10 16:13:51 +02:00
Artur Paikin
96715d3260 image-editor: fix crop/rotate/zoom buttons on mobile 2020-07-19 18:44:30 +01:00
Artur Paikin
5b89211e2c Image Editor can’t edit remote files 2020-07-18 10:38:27 +01:00
Artur Paikin
5cf40d0f00 pass options and i18n 2020-07-16 18:21:17 +01:00
Artur Paikin
32e2e02102 refactor 2020-07-15 17:23:37 +01:00
Artur Paikin
4a2cff37a9 tweak styles and svg accessibility 2020-07-15 16:55:47 +01:00
Artur Paikin
916d7cb320 Editor component, сanEditFile() and conditional “edit file” button, based on 2020-07-10 23:41:56 +01:00
Artur Paikin
a831837773 Connect image-editor and Dashboard, try rotation 2020-06-30 17:24:59 +01:00
Artur Paikin
42552ba3a6 cleanup 2020-06-23 15:25:30 +01:00
Artur Paikin
25f4f405fe Move cropping to a standalone image-editor plugin 2020-06-20 16:10:16 +01:00