Permalink
Browse files

update to vue-loader v15 - remove vector component

  • Loading branch information...
aaroniker committed May 6, 2018
1 parent a69269e commit 5f0195d9eed3e5ad94188fdb643524d35e5f8110
@@ -1,8 +1,6 @@
<template>
<div v-bind:class="{ messages: true, active: messages.length, multiple: messages.length > 1, open: open }" ref="messageList">
<a @click.prevent="toggle()" href="">
<vector src="../img/bell.svg"></vector>
</a>
<a @click.prevent="toggle()" href="" v-html="bell"></a>
<div v-bind:class="{ list: true, open: open, showAll: showAll }">
<ul v-if="messages.length">
<li v-for="(item, index) in listMessages" :class="item.type">
@@ -16,9 +14,7 @@
<input type="checkbox" v-model="showAll">
<div></div>
</label>
<div class="remove" @click="remove(-1)">
<vector src="../img/trash.svg"></vector>
</div>
<div class="remove" @click="remove(-1)" v-html="trash"></div>
</div>
<div v-if="messages.length < 1" class="noMessages">
{{ 'No messages' | lang }}
@@ -39,6 +35,8 @@ module.exports = {
warning: '<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 24 24" xml:space="preserve" width="24" height="24"><g class="nc-icon-wrapper fill" transform="translate(0.5, 0.5)"><circle fill="none" stroke-width="2" stroke-linecap="square" stroke-miterlimit="10" cx="12" cy="12" r="11" stroke-linejoin="miter"></circle><line data-color="color-2" fill="none" stroke-width="2" stroke-linecap="square" stroke-miterlimit="10" x1="12" y1="7" x2="12" y2="13" stroke-linejoin="miter"></line><circle data-color="color-2" class="fill" data-stroke="none" cx="12" cy="17" r="1" stroke-linejoin="miter" stroke-linecap="square"></circle></g></svg>',
close: '<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" class="fill" viewBox="0 0 24 24" xml:space="preserve" width="24" height="24"><g class="nc-icon-wrapper"><path class="fill" d="M16.7,7.3c-0.4-0.4-1-0.4-1.4,0L12,10.6L8.7,7.3c-0.4-0.4-1-0.4-1.4,0s-0.4,1,0,1.4l3.3,3.3l-3.3,3.3 c-0.4,0.4-0.4,1,0,1.4C7.5,16.9,7.7,17,8,17s0.5-0.1,0.7-0.3l3.3-3.3l3.3,3.3c0.2,0.2,0.5,0.3,0.7,0.3s0.5-0.1,0.7-0.3 c0.4-0.4,0.4-1,0-1.4L13.4,12l3.3-3.3C17.1,8.3,17.1,7.7,16.7,7.3z"></path></g></svg>'
},
trash: require('../img/trash.svg'),
bell: require('../img/bell.svg'),
showAll: false
}
},
@@ -1,5 +1,3 @@
var assets = __dirname + "/../../../assets";

module.exports = [
{
entry: {
@@ -1,5 +1,3 @@
import vector from './vector.vue'

function install(Vue) {

var gear = window.$gear;
@@ -46,8 +44,6 @@ function install(Vue) {

Vue.prototype.$visibility = require('visibilityjs');

Vue.component('vector', vector);

new Vue({
el: '#gear'
});

This file was deleted.

Oops, something went wrong.
@@ -25,7 +25,7 @@
"sass-resources-loader": "^1.3.1",
"svg-inline-loader": "^0.8.0",
"vue-html-loader": "^1.2.4",
"vue-loader": "^14.2.2",
"vue-loader": "^15.0.9",
"vue-style-loader": "^4.1.0",
"vue-template-compiler": "^2.5.16",
"webpack": "^4.2.0",
@@ -2,6 +2,7 @@ var _ = require('lodash');
var webpack = require('webpack');
var path = require('path');
var glob = require('glob');
const { VueLoaderPlugin } = require('vue-loader');
var exports = [];

glob.sync('{gear/modules/**,gear/installer/**,gear/system/**,extensions/**,themes/**}/webpack.config.js', {
@@ -18,36 +19,46 @@ glob.sync('{gear/modules/**,gear/installer/**,gear/system/**,extensions/**,theme
rules: [
{
test: /\.vue$/,
loader: 'vue-loader',
options: {
transformToRequire: {
vector: 'src',
img: 'src',
image: 'xlink:href'
use: [
'vue-loader'
]
},
{
test: /\.css$/,
use: [
'vue-style-loader',
'css-loader'
]
},
{
test: /\.scss/,
use: [
'vue-style-loader',
{
loader: 'css-loader'
},
loaders: {
scss: [
'vue-style-loader',
'css-loader',
'sass-loader',
{
loader: 'sass-resources-loader',
options: {
resources: [
path.resolve(__dirname, 'gear/system/modules/theme/styles/preload.scss'),
]
}
}
]
'sass-loader',
{
loader: 'sass-resources-loader',
options: {
resources: [
path.resolve(__dirname, 'gear/system/modules/theme/styles/preload.scss'),
]
}
}
}
]
},
{
test: /\.svg$/,
loader: 'svg-inline-loader'
use: [
'svg-inline-loader'
]
}
]
}
},
plugins: [
new VueLoaderPlugin()
]
}, config);
}));
});

0 comments on commit 5f0195d

Please sign in to comment.