moved themes to separate folder

This commit is contained in:
Art Lowel
2019-05-28 13:24:30 +02:00
parent cfcf496cc1
commit 11d06e34b1
34 changed files with 228 additions and 178 deletions

View File

@@ -1,6 +1,7 @@
const {
join,
resolve,
normalize,
} = require('path');
@@ -8,8 +9,10 @@ function root(path) {
return resolve(__dirname, '..', path);
}
const theme = '';
// const theme = 'mantis';
// const theme = '';
const theme = 'mantis';
const themePath = normalize(join(__dirname, '..', 'themes', theme));
const globalCSSImports = [
resolve(__dirname, '..', 'src/styles/_variables.scss'),
@@ -19,24 +22,10 @@ const globalCSSImports = [
const themeReplaceOptions =
{
multiple: [
{
search: '$theme$.',
replace: theme + (theme.length ? '.' : ''),
},
{
search: '$themePath$/',
replace: (theme.length ? 'themes/' : ''),
replace: (themePath.length ? themePath + '/' : ''),
},
{
search: '$theme$.',
replace: (theme.length ? theme + '.' : ''),
},
{
search: '$themePath$/',
replace: (theme.length ? 'themes/' : ''),
}
]
};
@@ -45,6 +34,7 @@ module.exports = {
root: root,
join: join,
theme: theme,
themePath: themePath,
globalCSSImports: globalCSSImports,
themeReplaceOptions: themeReplaceOptions
};