Move of files_versions to webpack
* Move CSS into bundle * Old merged.json no longer needed! * No need to load the style still Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
This commit is contained in:
parent
53e8957a55
commit
7f88654147
|
@ -3,6 +3,8 @@
|
|||
|
||||
/apps/accessibility/js/accessibility.js binary
|
||||
/apps/accessibility/js/accessibility.js.map binary
|
||||
/apps/files_versions/js/files_versions.js binary
|
||||
/apps/files_versions/js/files_versions.js.map binary
|
||||
/apps/oauth2/js/oauth2.js binary
|
||||
/apps/oauth2/js/oauth2.js.map binary
|
||||
/apps/twofactor_backupcodes/js/*.js binary
|
||||
|
|
|
@ -1,2 +1,3 @@
|
|||
# compiled vue templates
|
||||
js/templates.js
|
||||
js/files_versions.js
|
||||
src/templates.js
|
||||
|
|
|
@ -22,6 +22,4 @@
|
|||
*
|
||||
*/
|
||||
|
||||
\OCP\Util::addStyle('files_versions', 'versions');
|
||||
|
||||
\OCA\Files_Versions\Hooks::connectHooks();
|
||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -1,7 +0,0 @@
|
|||
[
|
||||
"versionmodel.js",
|
||||
"templates.js",
|
||||
"versioncollection.js",
|
||||
"versionstabview.js",
|
||||
"filesplugin.js"
|
||||
]
|
|
@ -149,6 +149,6 @@ class Hooks {
|
|||
* Load additional scripts when the files app is visible
|
||||
*/
|
||||
public static function onLoadFilesAppScripts() {
|
||||
\OCP\Util::addScript('files_versions', 'merged');
|
||||
\OCP\Util::addScript('files_versions', 'files_versions');
|
||||
}
|
||||
}
|
||||
|
|
|
@ -0,0 +1,8 @@
|
|||
import './versionmodel'
|
||||
import './templates'
|
||||
import './versioncollection'
|
||||
import './versionstabview'
|
||||
import './filesplugin'
|
||||
import './css/versions.css'
|
||||
|
||||
window.OCA.Versions = OCA.Versions
|
|
@ -0,0 +1,37 @@
|
|||
const path = require('path');
|
||||
|
||||
module.exports = {
|
||||
entry: path.join(__dirname, 'src', 'files_versions.js'),
|
||||
output: {
|
||||
path: path.resolve(__dirname, 'js'),
|
||||
publicPath: '/js/',
|
||||
filename: 'files_versions.js'
|
||||
},
|
||||
module: {
|
||||
rules: [
|
||||
{
|
||||
test: /\.css$/,
|
||||
use: ['style-loader', 'css-loader']
|
||||
},
|
||||
{
|
||||
test: /\.scss$/,
|
||||
use: ['style-loader', 'css-loader', 'sass-loader']
|
||||
},
|
||||
{
|
||||
test: /\.js$/,
|
||||
loader: 'babel-loader',
|
||||
exclude: /node_modules/
|
||||
},
|
||||
{
|
||||
test: /\.(png|jpg|gif|svg)$/,
|
||||
loader: 'file-loader',
|
||||
options: {
|
||||
name: '[name].[ext]?[hash]'
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
resolve: {
|
||||
extensions: ['*', '.js']
|
||||
}
|
||||
};
|
|
@ -13,9 +13,7 @@
|
|||
"sharedialoglinkshareview.js",
|
||||
"sharedialogresharerinfoview.js",
|
||||
"sharedialogshareelistview.js",
|
||||
"contactsmenu_templates.js",
|
||||
"public/publicpage.js",
|
||||
"multiselect.js",
|
||||
"oc-requesttoken.js",
|
||||
"setupchecks.js",
|
||||
"../search/js/search.js",
|
||||
|
|
|
@ -45,6 +45,7 @@ module.exports = function(config) {
|
|||
return [
|
||||
'files',
|
||||
'files_trashbin',
|
||||
'files_versions',
|
||||
{
|
||||
name: 'files_sharing',
|
||||
srcFiles: [
|
||||
|
@ -74,17 +75,6 @@ module.exports = function(config) {
|
|||
],
|
||||
testFiles: ['apps/files_external/tests/js/*.js']
|
||||
},
|
||||
{
|
||||
name: 'files_versions',
|
||||
srcFiles: [
|
||||
// need to enforce loading order...
|
||||
'apps/files_versions/js/versionmodel.js',
|
||||
'apps/files_versions/js/templates.js',
|
||||
'apps/files_versions/js/versioncollection.js',
|
||||
'apps/files_versions/js/versionstabview.js'
|
||||
],
|
||||
testFiles: ['apps/files_versions/tests/js/**/*.js']
|
||||
},
|
||||
{
|
||||
name: 'comments',
|
||||
srcFiles: [
|
||||
|
@ -117,8 +107,7 @@ module.exports = function(config) {
|
|||
{
|
||||
name: 'settings',
|
||||
srcFiles: [
|
||||
'settings/js/apps.js',
|
||||
'core/vendor/marked/marked.min.js'
|
||||
'settings/js/apps.js'
|
||||
]
|
||||
}
|
||||
];
|
||||
|
|
|
@ -1,5 +1,10 @@
|
|||
const core = require('./core/webpack');
|
||||
const files_trashbin = require('./apps/files_trashbin/webpack')
|
||||
const files_versions = require('./apps/files_versions/webpack');
|
||||
const oauth2 = require('./apps/oauth2/webpack')
|
||||
|
||||
module.exports = [].concat(core, files_trashbin, oauth2);
|
||||
module.exports = [].concat(
|
||||
core,
|
||||
files_trashbin,
|
||||
files_versions,
|
||||
oauth2);
|
||||
|
|
Loading…
Reference in New Issue