Move comments to webpack
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
This commit is contained in:
parent
fc105d3bb0
commit
41ef3d860c
|
@ -3,6 +3,8 @@
|
||||||
|
|
||||||
/apps/accessibility/js/accessibility.js binary
|
/apps/accessibility/js/accessibility.js binary
|
||||||
/apps/accessibility/js/accessibility.js.map binary
|
/apps/accessibility/js/accessibility.js.map binary
|
||||||
|
/apps/comments/js/*.js binary
|
||||||
|
/apps/comments/js/*.js.map binary
|
||||||
/apps/files_sharing/js/additionalScripts.js binary
|
/apps/files_sharing/js/additionalScripts.js binary
|
||||||
/apps/files_sharing/js/additionalScripts.js.map binary
|
/apps/files_sharing/js/additionalScripts.js.map binary
|
||||||
/apps/files_versions/js/files_versions.js binary
|
/apps/files_versions/js/files_versions.js binary
|
||||||
|
|
|
@ -1,2 +1,3 @@
|
||||||
# compiled vue templates
|
# compiled vue templates
|
||||||
js/templates.js
|
src/templates.js
|
||||||
|
js/comments.js
|
||||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -1,14 +0,0 @@
|
||||||
[
|
|
||||||
"app.js",
|
|
||||||
"templates.js",
|
|
||||||
"commentmodel.js",
|
|
||||||
"commentcollection.js",
|
|
||||||
"commentsummarymodel.js",
|
|
||||||
"commentstabview.js",
|
|
||||||
"commentsmodifymenu.js",
|
|
||||||
"filesplugin.js",
|
|
||||||
"activitytabviewplugin.js",
|
|
||||||
"search.js",
|
|
||||||
"vendor/Caret.js/dist/jquery.caret.min.js",
|
|
||||||
"vendor/At.js/dist/js/jquery.atwho.min.js"
|
|
||||||
]
|
|
|
@ -61,9 +61,7 @@ class Application extends App {
|
||||||
$dispatcher->addListener(
|
$dispatcher->addListener(
|
||||||
'OCA\Files::loadAdditionalScripts',
|
'OCA\Files::loadAdditionalScripts',
|
||||||
function() {
|
function() {
|
||||||
Util::addScript('comments', 'merged');
|
Util::addScript('comments', 'comments');
|
||||||
Util::addStyle('comments', 'autocomplete');
|
|
||||||
Util::addStyle('comments', 'comments');
|
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,18 @@
|
||||||
|
import './app'
|
||||||
|
import './templates'
|
||||||
|
import './commentmodel'
|
||||||
|
import './commentcollection'
|
||||||
|
import './commentsummarymodel'
|
||||||
|
import './commentstabview'
|
||||||
|
import './commentsmodifymenu'
|
||||||
|
import './filesplugin'
|
||||||
|
import './activitytabviewplugin'
|
||||||
|
import './search'
|
||||||
|
|
||||||
|
import './vendor/Caret.js/dist/jquery.caret.min'
|
||||||
|
import './vendor/At.js/dist/js/jquery.atwho.min'
|
||||||
|
|
||||||
|
import './style/autocomplete.scss'
|
||||||
|
import './style/comments.scss'
|
||||||
|
|
||||||
|
window.OCA.Comments = OCA.Comments;
|
|
@ -0,0 +1,40 @@
|
||||||
|
const path = require('path');
|
||||||
|
|
||||||
|
module.exports = {
|
||||||
|
entry: path.join(__dirname, 'src', 'comments.js'),
|
||||||
|
output: {
|
||||||
|
path: path.resolve(__dirname, './js'),
|
||||||
|
publicPath: '/js/',
|
||||||
|
filename: 'comments.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]'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
externals: {
|
||||||
|
jquery: 'jQuery'
|
||||||
|
},
|
||||||
|
resolve: {
|
||||||
|
extensions: ['*', '.js']
|
||||||
|
}
|
||||||
|
};
|
|
@ -77,17 +77,7 @@ module.exports = function(config) {
|
||||||
{
|
{
|
||||||
name: 'comments',
|
name: 'comments',
|
||||||
srcFiles: [
|
srcFiles: [
|
||||||
// need to enforce loading order...
|
'apps/comments/js/comments.js'
|
||||||
'apps/comments/js/app.js',
|
|
||||||
'apps/comments/js/templates.js',
|
|
||||||
'apps/comments/js/vendor/Caret.js/dist/jquery.caret.min.js',
|
|
||||||
'apps/comments/js/vendor/At.js/dist/js/jquery.atwho.min.js',
|
|
||||||
'apps/comments/js/commentmodel.js',
|
|
||||||
'apps/comments/js/commentcollection.js',
|
|
||||||
'apps/comments/js/commentsummarymodel.js',
|
|
||||||
'apps/comments/js/commentsmodifymenu.js',
|
|
||||||
'apps/comments/js/commentstabview.js',
|
|
||||||
'apps/comments/js/filesplugin.js'
|
|
||||||
],
|
],
|
||||||
testFiles: ['apps/comments/tests/js/**/*.js']
|
testFiles: ['apps/comments/tests/js/**/*.js']
|
||||||
},
|
},
|
||||||
|
|
|
@ -2,6 +2,7 @@ const core = require('./core/webpack')
|
||||||
const settings = require('./settings/webpack')
|
const settings = require('./settings/webpack')
|
||||||
|
|
||||||
const accessibility = require('./apps/accessibility/webpack')
|
const accessibility = require('./apps/accessibility/webpack')
|
||||||
|
const comments = require('./apps/comments/webpack')
|
||||||
const files_sharing = require('./apps/files_sharing/webpack')
|
const files_sharing = require('./apps/files_sharing/webpack')
|
||||||
const files_trashbin = require('./apps/files_trashbin/webpack')
|
const files_trashbin = require('./apps/files_trashbin/webpack')
|
||||||
const files_versions = require('./apps/files_versions/webpack')
|
const files_versions = require('./apps/files_versions/webpack')
|
||||||
|
@ -14,6 +15,7 @@ module.exports = [].concat(
|
||||||
core,
|
core,
|
||||||
settings,
|
settings,
|
||||||
accessibility,
|
accessibility,
|
||||||
|
comments,
|
||||||
files_sharing,
|
files_sharing,
|
||||||
files_trashbin,
|
files_trashbin,
|
||||||
files_versions,
|
files_versions,
|
||||||
|
|
Loading…
Reference in New Issue