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