Update fixtures and code style
This commit is contained in:
parent
02ed29e3e9
commit
2ae6ee6c12
6 changed files with 7052 additions and 16 deletions
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
|
|
@ -10,7 +10,8 @@ function buildDistFile(filename) {
|
|||
fs.readFile(`./${filename}.css`, (err, css) => {
|
||||
if (err) throw err
|
||||
|
||||
return postcss([tailwind(), require('autoprefixer')])
|
||||
// return postcss([tailwind(), require('autoprefixer')])
|
||||
return postcss([tailwind()])
|
||||
.process(css, {
|
||||
from: `./${filename}.css`,
|
||||
to: `./dist/${filename}.css`,
|
||||
|
|
|
|||
|
|
@ -3,16 +3,8 @@ import createUtilityPlugin from '../util/createUtilityPlugin'
|
|||
export default function() {
|
||||
return function(...args) {
|
||||
;[
|
||||
createUtilityPlugin(
|
||||
'translate-x',
|
||||
'translate',
|
||||
'--transform-translate-x'
|
||||
),
|
||||
createUtilityPlugin(
|
||||
'translate-y',
|
||||
'translate',
|
||||
'--transform-translate-y'
|
||||
),
|
||||
createUtilityPlugin('translate-x', 'translate', '--transform-translate-x'),
|
||||
createUtilityPlugin('translate-y', 'translate', '--transform-translate-y'),
|
||||
].forEach(f => f(...args))
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -13,11 +13,7 @@ function className(classPrefix, key) {
|
|||
return `${classPrefix}-${key}`
|
||||
}
|
||||
|
||||
export default function createUtilityPlugin(
|
||||
classPrefix,
|
||||
themeKey,
|
||||
property = themeKey
|
||||
) {
|
||||
export default function createUtilityPlugin(classPrefix, themeKey, property = themeKey) {
|
||||
return function({ e, addUtilities, variants, theme }) {
|
||||
return addUtilities(
|
||||
fromPairs(
|
||||
|
|
|
|||
|
|
@ -3,3 +3,10 @@
|
|||
@tailwind components;
|
||||
|
||||
@tailwind utilities;
|
||||
|
||||
@responsive {
|
||||
.example {
|
||||
@apply .font-bold;
|
||||
color: theme('colors.red.500');
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue