2017-05-16 18:00:56 +03:00
|
|
|
/**
|
|
|
|
* Theme color provider
|
|
|
|
*/
|
|
|
|
|
|
|
|
const constants = require('../../../src/const.json');
|
|
|
|
|
|
|
|
export default () => ({
|
|
|
|
enforce: 'pre',
|
2018-02-10 07:56:33 +02:00
|
|
|
test: /\.vue$/,
|
2017-05-16 18:00:56 +03:00
|
|
|
exclude: /node_modules/,
|
2018-02-15 13:00:23 +02:00
|
|
|
use: [{
|
2018-02-15 12:59:07 +02:00
|
|
|
loader: 'replace-string-loader',
|
|
|
|
options: {
|
2018-02-15 13:00:23 +02:00
|
|
|
search: '$theme-color-foreground',
|
|
|
|
replace: constants.themeColorForeground,
|
|
|
|
flags: 'g'
|
2018-02-15 12:59:07 +02:00
|
|
|
}
|
2018-02-15 13:00:23 +02:00
|
|
|
}, {
|
2018-02-15 12:59:07 +02:00
|
|
|
loader: 'replace-string-loader',
|
|
|
|
options: {
|
|
|
|
search: '$theme-color',
|
|
|
|
replace: constants.themeColor,
|
|
|
|
flags: 'g'
|
|
|
|
}
|
|
|
|
}]
|
2017-05-16 18:00:56 +03:00
|
|
|
});
|