DEV: Switch to using uppy uploads in composer by default (PR #15058)

This is a big change to change over to using the uppy upload mixin in the composer by default. This gets rid of the temporary composer-editor-uppy component, as well as removing the old ComposerUpload mixin and copying over any missing functions that were not yet implemented by ComposerUploadUppy. This has been working well on our hosting for some time now and has led us to several bug fixes.

This commit also deletes the old plugin API for adding preprocessors for the uploads. The accepted method of doing this now is via an uppy preprocessor plugin, which we have several examples of in the core codebase.

Leaving the enable_experimental_composer_uploader site setting intact for now because some plugins still rely on it, this will be removed at a later date.

One step closer to ending the jQuery file uploader saga…

GitHub

If we remove this straight away, wouldn’t it break plugins that are still relying on this API? I think we need to go through a proper deprecation cycle here.

There are no plugins using this API, we actually only introduced it fairly recently in FEATURE: New API hook to allow for client side upload transforms (#12… · discourse/discourse@2f60309 · GitHub and I’ve made sure to go through our all-the-* repos and replace the one or two things that did use it. Also this API is completely useless now that we are changing the composer to only use the uppy uploader. So I think we are fine to just remove it.

I’m not sure if I consider 6 months fairly recently so I personally would err on the safe side and go through a deprecation cycle for this. However, if we’re confident there are no external users of this API, we can take the risk and just remove without deprecation but it defeats the entire purpose of having a versioned API.

I’ve made sure to go through our all-the-* repos and replace the one or two things that did use it.

Did we replace it with another API call? We could in theory just make addComposerUploadPrecessor call the new API?

Opened an internal discussion about this.

Since DEV: Send multiple files in batches to composer upload handlers by martin-brennan · Pull Request #15124 · discourse/discourse · GitHub changes the addComposerUploadHandler behaviour from the uppy composer uploader, I updated the documentation for that in this PR (since it is making the uppy composer uploads the default) and added an entry to the changelog.

QUnit failure is completely unrelated…