Update all core plugins to use the same class name generation strategy
This commit is contained in:
parent
e897e40189
commit
11690b4c9b
48 changed files with 172 additions and 341 deletions
|
|
@ -1,18 +1,5 @@
|
|||
import _ from 'lodash'
|
||||
import createUtilityPlugin from '../util/createUtilityPlugin'
|
||||
|
||||
export default function() {
|
||||
return function({ addUtilities, e, theme, variants }) {
|
||||
const utilities = _.fromPairs(
|
||||
_.map(theme('width'), (value, modifier) => {
|
||||
return [
|
||||
`.${e(`w-${modifier}`)}`,
|
||||
{
|
||||
width: value,
|
||||
},
|
||||
]
|
||||
})
|
||||
)
|
||||
|
||||
addUtilities(utilities, variants('width'))
|
||||
}
|
||||
return createUtilityPlugin('width', [['w', ['width']]])
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue