Support configuring a single list of variants to apply to all relevant plugins
This commit is contained in:
parent
43f63bf2e5
commit
f0bc35a896
71 changed files with 255 additions and 128 deletions
|
|
@ -2,7 +2,7 @@ import _ from 'lodash'
|
|||
import flattenColorPalette from '../util/flattenColorPalette'
|
||||
|
||||
export default function() {
|
||||
return function({ addUtilities, e, config }) {
|
||||
return function({ addUtilities, e, config, variants }) {
|
||||
const utilities = _.fromPairs(
|
||||
_.map(flattenColorPalette(config('theme.backgroundColor')), (value, modifier) => {
|
||||
return [
|
||||
|
|
@ -14,6 +14,6 @@ export default function() {
|
|||
})
|
||||
)
|
||||
|
||||
addUtilities(utilities, config('variants.backgroundColor'))
|
||||
addUtilities(utilities, variants('backgroundColor'))
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue