mirror of
https://github.com/discourse/discourse.git
synced 2024-11-25 05:02:24 +08:00
b626373b31
Adds uppy upload functionality behind a enable_experimental_composer_uploader site setting (default false, and hidden). When enabled this site setting will make the composer-editor-uppy component be used within composer.hbs, which in turn points to a ComposerUploadUppy mixin which overrides the relevant functions from ComposerUpload. This uppy uploader has parity with all the features of jQuery file uploader in the original composer-editor, including: progress tracking error handling number of files validation pasting files dragging and dropping files updating upload placeholders upload markdown resolvers processing actions (the only one we have so far is the media optimization worker by falco, this works) cancelling uploads For now all uploads still go via the /uploads.json endpoint, direct S3 support will be added later. Also included in this PR are some changes to the media optimization service, to support uppy's different file data structures, and also to make the promise tracking and resolving more robust. Currently it uses the file name to track promises, we can switch to something more unique later if needed. Does not include custom upload handlers, that will come in a later PR, it is a tricky problem to handle. Also, this new functionality will not be used in encrypted PMs because encrypted PM uploads rely on custom upload handlers. |
||
---|---|---|
.. | ||
admin | ||
confirm-new-email | ||
discourse | ||
discourse-common | ||
discourse-hbr | ||
discourse-widget-hbs | ||
docs | ||
ember-addons | ||
locales | ||
pretty-text | ||
select-kit | ||
truth-helpers | ||
wizard | ||
.npmrc | ||
activate-account.js | ||
admin.js.erb | ||
app-boot.js | ||
application.js | ||
auto-redirect.js | ||
browser-detect.js | ||
browser-update.js | ||
discourse-loader.js | ||
discourse-shims.js | ||
embed-application.js | ||
ember_include.js.erb | ||
ember_jquery.js | ||
env.js | ||
google-tag-manager.js | ||
google-universal-analytics-v3.js | ||
google-universal-analytics-v4.js | ||
handlebars-shim.js | ||
main_include_admin.js | ||
markdown-it-bundle.js | ||
onpopstate-handler.js | ||
package.json | ||
polyfills.js | ||
pretty-text-bundle.js | ||
print-page.js | ||
service-worker.js.erb | ||
set-prototype-polyfill.js | ||
start-discourse.js | ||
template_include.js | ||
test-shims.js | ||
vendor.js | ||
widget-runtime.js | ||
wizard-application.js | ||
wizard-shims.js | ||
wizard-start.js | ||
wizard-vendor.js | ||
yarn.lock |