FIX: We should include resumable.js in the admin bundle (#13049)

Normally we'd use `ember-auto-import` for this, but it's not run on
our admin tree due to the quirky way we load it conditionally.
Instead we'll append it at the bottom like our Rails app does.
This commit is contained in:
Robin Ward 2021-05-12 13:44:24 -04:00 committed by GitHub
parent 2cf063dc7e
commit 3d7abad949
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 1 deletions

View File

@ -36,6 +36,10 @@ module.exports = function (defaults) {
app.import(vendorJs + "jquery.fileupload.js");
app.import(vendorJs + "jquery.autoellipsis-1.0.10.js");
let adminVendor = funnel(vendorJs, {
files: ["resumable.js"],
});
return mergeTrees([
discourseScss(`${discourseRoot}/app/assets/stylesheets`, "testem.scss"),
createI18nTree(discourseRoot, vendorJs),
@ -46,7 +50,7 @@ module.exports = function (defaults) {
destDir: "assets/highlightjs",
}),
digest(
concat(app.options.adminTree, {
concat(mergeTrees([app.options.adminTree, adminVendor]), {
outputFile: `assets/admin.js`,
})
),