tailwindcss/jit/corePlugins/letterSpacing.js

16 lines
384 B
JavaScript
Raw Normal View History

const { asLength, nameClass } = require('../pluginUtils')
2021-04-02 14:12:47 -04:00
module.exports = function ({ matchUtilities }) {
matchUtilities({
tracking: (modifier, { theme }) => {
let value = asLength(modifier, theme['letterSpacing'])
if (value === undefined) {
return []
}
return { [nameClass('tracking', modifier)]: { 'letter-spacing': value } }
},
})
}