1
0
Fork 0
mirror of https://github.com/lidarr/Lidarr synced 2025-01-18 12:54:53 +00:00
Lidarr/frontend/postcss.config.js
Qstick 6c9808fe56 New: Webpack 5, UI Package Updates
Co-Authored-By: Mark McDowall <markus101@users.noreply.github.com>
2021-06-27 01:43:54 -04:00

32 lines
801 B
JavaScript

const reload = require('require-nocache')(module);
const cssVarsFiles = [
'./src/Styles/Variables/colors',
'./src/Styles/Variables/dimensions',
'./src/Styles/Variables/fonts',
'./src/Styles/Variables/animations',
'./src/Styles/Variables/zIndexes'
].map(require.resolve);
const mixinsFiles = [
'frontend/src/Styles/Mixins/cover.css',
'frontend/src/Styles/Mixins/linkOverlay.css',
'frontend/src/Styles/Mixins/scroller.css',
'frontend/src/Styles/Mixins/truncate.css'
];
module.exports = {
plugins: [
['postcss-mixins', {
mixinsFiles
}],
['postcss-simple-vars', {
variables: () =>
cssVarsFiles.reduce((acc, vars) => {
return Object.assign(acc, reload(vars));
}, {})
}],
'postcss-color-function',
'postcss-nested'
]
};