FEATURE: Uppy image uploader with UppyUploadMixin (#13656)

This PR adds the first use of Uppy in our codebase, hidden behind a enable_experimental_image_uploader site setting. When the setting is enabled only the user card background uploader will use the new uppy-image-uploader component added in this PR.

I've introduced an UppyUpload mixin that has feature parity with the existing Upload mixin, and improves it slightly to deal with multiple/single file distinctions and validations better. For now, this just supports the XHRUpload plugin for uppy, which keeps our existing POST to /uploads.json.
This commit is contained in:
Martin Brennan
2021-07-13 12:22:00 +10:00
committed by GitHub
parent e2d04a8592
commit 7911124d3d
17 changed files with 1071 additions and 87 deletions

View File

@ -45,10 +45,23 @@ define("@popperjs/core", ["exports"], function (__exports__) {
__exports__.popperGenerator = window.Popper.popperGenerator;
});
define("uppy", ["exports"], function (__exports__) {
define("@uppy/core", ["exports"], function (__exports__) {
__exports__.default = window.Uppy.Core;
__exports__.Plugin = window.Uppy.Plugin;
__exports__.XHRUpload = window.Uppy.XHRUpload;
__exports__.AwsS3 = window.Uppy.AwsS3;
__exports__.AwsS3Multipart = window.Uppy.AwsS3Multipart;
});
define("@uppy/aws-s3", ["exports"], function (__exports__) {
__exports__.default = window.Uppy.AwsS3;
});
define("@uppy/aws-s3-multipart", ["exports"], function (__exports__) {
__exports__.default = window.Uppy.AwsS3Multipart;
});
define("@uppy/xhr-upload", ["exports"], function (__exports__) {
__exports__.default = window.Uppy.XHRUpload;
});
define("@uppy/drop-target", ["exports"], function (__exports__) {
__exports__.default = window.Uppy.DropTarget;
});