2021-04-02 11:16:15 -04:00
|
|
|
const { nameClass } = require('../pluginUtils')
|
|
|
|
|
|
2021-04-02 14:12:47 -04:00
|
|
|
module.exports = function ({ matchUtilities }) {
|
2021-04-02 11:16:15 -04:00
|
|
|
matchUtilities({
|
|
|
|
|
bg: (modifier, { theme }) => {
|
|
|
|
|
let value = theme.backgroundPosition[modifier]
|
|
|
|
|
|
|
|
|
|
if (value === undefined) {
|
|
|
|
|
return []
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return { [nameClass('bg', modifier)]: { 'background-position': value } }
|
|
|
|
|
},
|
|
|
|
|
})
|
|
|
|
|
}
|